Skip to content

[FEATURE]: Add missing --variant option for standard "opencode" command to start new session. #37925

Closed as not planned

Description

@colinmollenhour

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

For example, I'd like to:

alias oc-fast='OPENCODE_DISABLE_MODELS_FETCH=1 opencode --model openai/gpt-5.6-sol --variant low`

But currently, there is no way that I can find to specify the variant on the CLI for the normal start session mode – there is a --variant CLI flag already for the run command. This feature was suggested before but was auto-closed and not re-opened by the author: #7354 and he opened a PR here: #7358

Activity

  1. s-KaiNet commented on Sep 16, 2026

    @s-KaiNet

    Yeah, that particularly nice to have if you spawn session via herdr or something similar, you need interactive UI with the reasoning effort preconfigured. Strange that we have it for run but not for the normal opencode

  2. christiaan-janssen commented on Sep 25, 2026

    @christiaan-janssen

    I'm running into this when using worktrunk merge, it errors out with Unrecognized flag: --variant in command opencode run. The command work trunk runs is opencode run -m anthropic/claude-haiku-4.5 --variant fast

  3. opencodejr commented on Oct 28, 2026

    @opencodejr
    Contributor

    Thanks for the request, @colinmollenhour! From the alias (opencode --model ... on the root command) and run --variant, this looks like OpenCode v1 (0.x/1.x). v1 now only gets fixes for critical bugs, so new CLI flags like this are unlikely to be added there.

    We'd encourage upgrading to v2 (@opencode/cli). The CLI works differently there:

    Related:

    If you think this is critical, or you see a problem with this on v2, please reply here.

  4. opencodejr commented on Oct 29, 2026

    @opencodejr
    Contributor

    We haven't heard back, so I'm closing this as not planned. It's a feature request for OpenCode v1, and v1 now only gets fixes for critical bugs.

    In v2, opencode run and opencode mini take the variant as part of the model, for example --model openai/gpt-5.6-sol#low. Adding --model back to the root opencode command is tracked in #56218. If you run into this on v2, please comment there or open a new issue. Thanks, @colinmollenhour!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions