You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Proposal: model-tier-specific system prompt variant behind an opt-in option #32315
I'd like to propose an opt-in promptVariant provider/model option that selects an alternate system prompt for frontier-class models, while keeping the current prompt as the unchanged default.
Hypothesis
packages/opencode/src/session/prompt/*.txt is currently a "works for any model" baseline. On frontier models (GPT-5.4, Claude Opus/Sonnet 4), that baseline appears to under-use the model's capability — it leans toward shallow, "looks fine" conclusions rather than driving the model to reason to root cause.
Measurement
I ran a within-session controlled comparison on a public code-review task (planetiler, reviewing its last 10 commits for known seeded regressions). Same model, same agent prompt, same session — only the system prompt was swapped between the baseline and a frontier-tuned variant. Recall of public-API silent-semantic-change bugs:
bug
baseline
frontier
reservoir polygon dropped
16.7%
62.5%
signed→unsigned comparison
16.7%
87.5%
compareTo ordering change
0%
50%
false positives
0
0
The frontier variant improved recall by ~45–71pp at the same (zero) false-positive rate.
Proposal
Add a promptVariant option (provider- or model-level). The only value would be "frontier", which routes GPT (non-codex) and Claude families to a frontier-tuned prompt; every other family falls back to the baseline. Unset is the default and means baseline, so the change is non-breaking and fully opt-in — existing users see no difference unless they enable it.
I have a branch ready (mechanism + the two prompt files + unit tests + attribution). The implementation is small: the mechanism is ~30 lines; the prompt files are text.
Attribution
The frontier prompts paraphrase selected operating principles from the Codex CLI prompts (Apache-2.0); no source is copied verbatim. A repo-root NOTICE documents the adapted scope and the clauses added independently.
Question
Does a system-layer, opt-in prompt variant fit the project's scope? If it sounds reasonable I'll open the PR.
This appears to be a feature request, but it does not use the required Feature Request template. Feature request titles must start with [FEATURE]:, and the template requires a verification checkbox confirming the feature hasn't been suggested before, along with a description of the enhancement.
Please edit this issue to address the above within 2 hours, or it will be automatically closed.
This issue might be a duplicate of existing issues. Please check:
[FEATURE]: System prompt mode switcher (Default/Light) #15457: [FEATURE]: System prompt mode switcher (Default/Light) — proposes a similar opt-in mechanism for selecting alternate system prompts based on model type/tier, with a non-breaking default and extensible design
If you believe this was flagged incorrectly, please let a maintainer know.
Closing as a duplicate of #15457 (same opt-in system-prompt-selector mechanism). Continuing the discussion there with measurement data and a working branch.
Activity
github-actions commentedon Jun 14, 2026
This issue doesn't fully meet our contributing guidelines.
What needs to be fixed:
[FEATURE]:, and the template requires a verification checkbox confirming the feature hasn't been suggested before, along with a description of the enhancement.Please edit this issue to address the above within 2 hours, or it will be automatically closed.
This issue might be a duplicate of existing issues. Please check:
If you believe this was flagged incorrectly, please let a maintainer know.
okuyam2y commentedon Jun 14, 2026
Closing as a duplicate of #15457 (same opt-in system-prompt-selector mechanism). Continuing the discussion there with measurement data and a working branch.