[FEATURE]: Configurable model-specific agent prompts, reminders, and transitions #14210
Copy link
Copy link
Closed
Closed
Copy link
Labels
coreAnything pertaining to core functionality of the application (opencode server stuff)Anything pertaining to core functionality of the application (opencode server stuff)discussionUsed for feature requests, proposals, ideas, etc. Open discussionUsed for feature requests, proposals, ideas, etc. Open discussion
Description
Feature hasn't been suggested before.
- I have verified this feature I'm about to request hasn't been suggested before.
Describe the enhancement you want to request
The system prompts for Plan and Build agents are hardcoded in source. The per-model prompt routing (anthropic.txt, beast.txt, etc.) only works for native agents and can't be replicated via config. The plan mode reminder (plan.txt) and build-switch transition (build-switch.txt) are also hardcoded with agent.name === "plan" checks.
This makes it currently impossible to fully customize agent behavior from opencode.json at parity with the main two included agents. You can't override the base prompt per model, inject a recurring reminder while an agent is active, or define transition text when switching between agents.
Proposed approach:
- Extend the prompt field to accept string | Record<string, string> for per-model glob pattern matching
- Add reminder field (string, injected every turn while agent is active)
- Add transition field (string, injected once when switching to this agent from a different agent)
All three can support the existing {file:...} syntax.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
coreAnything pertaining to core functionality of the application (opencode server stuff)Anything pertaining to core functionality of the application (opencode server stuff)discussionUsed for feature requests, proposals, ideas, etc. Open discussionUsed for feature requests, proposals, ideas, etc. Open discussion
Activity
github-actions commentedon Feb 18, 2026
This issue might be a duplicate of existing issues. Please check:
on_exit/on_entertransition fields and per-agent reminder injection, which directly overlaps with this issue'sreminderandtransitionfields.Please review those issues and consider whether this is already captured there, or if your proposal adds meaningfully distinct scope.
nleve commentedon Feb 18, 2026
This partly duplicates #12498 but perhaps smaller in scope. I have what I described working quite trivially so will submit a PR as discussion-fodder if nothing else.
github-actions commentedon Apr 20, 2026
To stay organized issues are automatically closed after 60 days of no activity. If the issue is still relevant please open a new one.