Skip to content

feat: add --variant flag to run command - #6805

Merged
rekram1-node merged 4 commits into
anomalyco:devfrom
shuv1337:feat/cli-run-variant-option
Jan 4, 2026
Merged

rekram1-node merged 4 commits into
anomalyco:devfrom
shuv1337:feat/cli-run-variant-option

Conversation

@shuv1337

@shuv1337 shuv1337 commented Jan 4, 2026 •

Copy link
Copy Markdown
Contributor

Added --variant CLI option to opencode run command to specify provider-specific model reasoning effort levels (e.g., high, max, minimal). The implementation passes variant through both command and prompt execution paths, storing it in user messages where it's later merged into model options during LLM streaming. Includes comprehensive unit tests covering both execution paths and backwards compatibility.

closes: #6706

shuv1337 and others added 4 commits January 3, 2026 20:29
Add --variant flag to specify model variant (provider-specific reasoning
effort like high, max, minimal). The variant is passed to both
sdk.session.command() and sdk.session.prompt() calls.
Test that variant is correctly passed to sdk.session.prompt() and
sdk.session.command() when using the --variant flag.
@rekram1-node rekram1-node changed the title Feat/cli run variant option feat: add --variant flag to run command Jan 4, 2026
@rekram1-node
rekram1-node merged commit 72cef0d into anomalyco:dev Jan 4, 2026
2 checks passed
triklozoid pushed a commit to triklozoid/opencode that referenced this pull request Feb 2, 2026
Co-authored-by: shuv <shuv@shuv.dev>
Co-authored-by: Aiden Cline <63023139+rekram1-node@users.noreply.github.com>
Rwanbt pushed a commit to Rwanbt/unifia that referenced this pull request May 5, 2026
Co-authored-by: shuv <shuv@shuv.dev>
Co-authored-by: Aiden Cline <63023139+rekram1-node@users.noreply.github.com>
AIALRA-0 pushed a commit to AIALRA-0/opencode-turn-engine that referenced this pull request Jun 10, 2026
Co-authored-by: shuv <shuv@shuv.dev>
Co-authored-by: Aiden Cline <63023139+rekram1-node@users.noreply.github.com>
Rwanbt pushed a commit to Rwanbt/unifia that referenced this pull request Jun 14, 2026
Co-authored-by: shuv <shuv@shuv.dev>
Co-authored-by: Aiden Cline <63023139+rekram1-node@users.noreply.github.com>
MarsQiu007 referenced this pull request in MarsQiu007/openNovel Jul 31, 2026
Co-authored-by: shuv <shuv@shuv.dev>
Co-authored-by: Aiden Cline <63023139+rekram1-node@users.noreply.github.com>
meSingh pushed a commit to meSingh/opencode that referenced this pull request Sep 6, 2026
Co-authored-by: shuv <shuv@shuv.dev>
Co-authored-by: Aiden Cline <63023139+rekram1-node@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEATURE]: cannot use GPT-5.2 high in CLI mode (aka opencode run)

2 participants