Skip to content

OpenCode: refresh Zen catalog and emit --variant from per-model variants #744

Closed

Description

@currentbits

Parent: #738
Needs: per-model effort lists (#739)

User-visible bug

The OpenCode picker is a stale Zen snapshot. Live opencode models (1.17.12, 2026-08-28) and electron/providers.js disagree:

In the snapshot, gone live Live, missing from the snapshot
opencode/ling-3.0-tiny-free opencode/hy3-free
opencode/longcat-2.0-free opencode/nemotron-3.5-lightning-free
opencode/north-mini-code-free (currently recommended)

Still present on both sides: big-pickle, deepseek-v4-flash-free, laguna-s-2.1-free, mimo-v2.5-free, nemotron-3-ultra-free.

Custom... can type the new ids today (setProvider is not an allowlist). The recommended row is a dead id. Tests currently pin the dead recommended id:

  • electron/test/providers.test.js
  • electron/test/opencode.test.js
  • test/composer.test.tsx

Effort is worse: opencode run --help lists --variant (provider-specific reasoning effort). Solenta leaves efforts: [] and maybeEmitEffort never emits --variant, so the effort pill is hidden for every OpenCode model.

Live --variant values (opencode models --verbose)

Model variants context
big-pickle (empty) 200000
deepseek-v4-flash-free low, medium, high, max 200000
hy3-free low, medium, high 190000
laguna-s-2.1-free low, medium, high 256000
mimo-v2.5-free low, medium, high 200000
nemotron-3-ultra-free low, medium, high 1000000
nemotron-3.5-lightning-free low, medium, high 262144

Do not put max on the OpenCode provider-wide list. That is the #739 contract: advertise only what the selected model honours. big-pickle must keep an empty effort pill.

--variant also mentions minimal. None of the current Zen models list it. Do not add minimal to ReasoningEffort unless a live model actually advertises it (the union already excludes none/minimal for Codex).

What to ship

  1. Replace the OpenCode models / modelInfo snapshot with the live 1.17.12 Zen list. Copy labels, descriptions, vendors, and contextTokens from opencode models --verbose / ~/.cache/opencode/models.json. Pick a new recommended from an id that still exists (north-mini-code-free is gone).
  2. After Per-model effort lists so advertised levels match the selected model #739, set modelInfo[].efforts from each model's variants keys that intersect ReasoningEffort. Keep provider efforts: [] as the fallback so a model with empty variants still hides the pill.
  3. OpenCode buildArgs: emit --variant <level> via maybeEmitEffort using the selected model's list, not a provider-wide one.
  4. Retarget tests that pin opencode/north-mini-code-free. Assert the rule (snapshot matches live Zen ids; --variant is emitted only for listed levels), not a magic recommended id.

Verify live before merge

  • opencode models on the machine doing the PR; the Zen free list moves.
  • opencode run -m opencode/deepseek-v4-flash-free --variant max --format json ping is accepted (auth/quota failures are fine; unknown-variant rejection is not).
  • opencode run -m opencode/big-pickle --variant high --format json ping is rejected or ignored. We must not advertise high on big-pickle.

Do not

  • Do not add paid / non-Zen providers from a logged-in OpenCode account into the default snapshot. The current snapshot is the free Zen list on purpose.
  • Do not treat --variant minimal as in scope without a live model that lists it.

Files

electron/providers.js (OpenCode entry + buildArgs), src/shared/ipc.ts (ModelInfo.efforts from #739), electron/test/providers.test.js, electron/test/opencode.test.js, test/composer.test.tsx, electron/test/reasoning-effort.test.js.

Activity

  1. added
    enhancement
    on Aug 28, 2026
  2. currentbits commented on Aug 28, 2026

    @currentbits
    OwnerAuthor

    Zen snapshot now matches live opencode models 1.17.12: drop ling/longcat/north-mini; add hy3-free + nemotron-3.5-lightning-free. Recommended is laguna-s-2.1-free (coding model that still exists). --variant is emitted from per-model variants; big-pickle keeps an empty pill. Live opencode run -m opencode/big-pickle --variant high exited 0 (ignored, not rejected) so we still must not advertise it.

  3. added
    plan:done
    and removed
    plan:todo
    on Aug 28, 2026
  4. currentbits commented on Aug 28, 2026

    @currentbits
    OwnerAuthor

    Shipped on this thread as part of #738.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementplan:done

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions