Skip to content

feat(opencode-go): register 4 missing models from upstream catalog - #2790

Merged
diegosouzapw merged 2 commits into
cheaper-inference:release/v3.8.5from
jeferssonlemes:feat/opencode-go-missing-models
May 27, 2026
Merged

diegosouzapw merged 2 commits into
cheaper-inference:release/v3.8.5from
jeferssonlemes:feat/opencode-go-missing-models

Conversation

@jeferssonlemes

Copy link
Copy Markdown
Contributor

Summary

  • Add 4 missing models to the opencode-go provider: qwen3.7-max, mimo-v2-pro, mimo-v2-omni, hy3-preview.
  • Aligns the static registry with the live https://opencode.ai/zen/go/v1/models response (16 models). Previously, requests for any of these four IDs failed model resolution before reaching the executor.
  • Adds matching entries to src/shared/constants/modelSpecs.ts for the two models whose capabilities are well-documented (qwen3.7-max, mimo-v2-pro). mimo-v2-omni already had a spec upstream; hy3-preview falls back to __default__.

New Models

Model ID Name contextLength maxOutputTokens targetFormat Notes
qwen3.7-max Qwen3.7 Max 200000 (default) 8192 (default openai) Spec mirrors qwen3.6-plus (Bailian multimodal — thinking + tools + vision).
mimo-v2-pro MiMo-V2-Pro 200000 (default) 131072 (default openai) Spec mirrors mimo-v2-omni (262144 ctx, tools + vision).
mimo-v2-omni MiMo-V2-Omni 200000 (default) 131072 (default openai) Spec already present upstream.
hy3-preview Hunyuan3 Preview 200000 (default) (default 8192) (default openai) No spec entry — falls back to __default__. Conservative since no public capability docs.

All four models route to /chat/completions (default openai format), matching the existing opencode-go executor behavior. No executor/translator changes required.

Related Issues

  • Closes #
  • Related to #

Validation

  • npm run lint
  • npm run test:unit — opencode-executor.test.ts 32 pass / 0 fail; t31-t33-t34-t38-model-specs.test.ts 6 pass / 0 fail
  • npm run test:coverage
  • Coverage is still >= 60% for statements, lines, functions, and branches
  • SonarQube PR analysis is green or any remaining issues are explicitly documented below

Tests Added Or Updated

Coverage Notes

  • Changes touch open-sse/config/providerRegistry.ts (data-only registry entries) and src/shared/constants/modelSpecs.ts (data-only spec entries). Both are exercised by the new executor test (opencode-executor.test.ts) and the existing model-specs test suite (t31-t33-t34-t38-model-specs.test.ts).
  • No production logic changed; no executor or translator code was modified.

Reviewer Notes

  • Precedent: PR feat(opencode-go): register 6 missing models from upstream catalog #1510 (feat(opencode-go): register 6 missing models from upstream catalog) added the previous batch via the same gap. This PR follows the same structure (registry + matching executor test) and naming style (name field in PascalCase to match neighbors like MiMo-V2.5-Pro, Qwen3.6 Plus).
  • The live opencode-go catalog can be verified with curl https://opencode.ai/zen/go/v1/models — current response includes all 16 models. Before this PR, the registry only listed 12 of them.
  • hy3-preview (Tencent Hunyuan-3 preview) is intentionally added without a model spec — public capability docs are limited, so falling back to __default__ is the safest option. A follow-up PR can refine the spec once vision/tools support is confirmed by Tencent docs.
  • No Co-Authored-By trailer (Hard Rule fix(ci): fix npm publish auth — support vars.NPM_TOKEN #16).

Add qwen3.7-max, mimo-v2-pro, mimo-v2-omni, hy3-preview to the
opencode-go provider. Extend executor tests and model specs.

- Registry now matches live https://opencode.ai/zen/go/v1/models response
  (16 models). Previously, four models returned by the upstream API were
  absent from the static registry, so requests to them failed model
  resolution before reaching the executor.
- qwen3.7-max: inherits defaultContextLength 200000; model spec mirrors
  qwen3.6-plus (Bailian multimodal, thinking + tools + vision).
- mimo-v2-pro: spec mirrors mimo-v2-omni (262144 ctx, 131072 maxOut,
  tools + vision).
- mimo-v2-omni: registry entry only (spec already present upstream).
- hy3-preview: registry entry only; falls back to __default__ spec.
- All four route to /chat/completions (default openai format), matching
  the existing opencode-go executor behavior.
@kilo-code-bot

kilo-code-bot Bot commented May 27, 2026

Copy link
Copy Markdown

Kilo Code Review could not run — your account is out of credits.

Add credits or switch to a free model to enable reviews on this change.

@diegosouzapw
diegosouzapw changed the base branch from main to release/v3.8.5 May 27, 2026 13:39
@diegosouzapw
diegosouzapw merged commit 3c016ce into cheaper-inference:release/v3.8.5 May 27, 2026
1 of 2 checks passed
jeferssonlemes added a commit to jeferssonlemes/OmniRoute that referenced this pull request May 27, 2026
Upstream returns 401 "Model qwen3.x-* is not supported for format
oa-compat" when hitting /chat/completions for qwen3.5-plus / qwen3.6-plus /
qwen3.7-max on opencode-go. Same upstream behavior already documented for
opencode-zen via Issue cheaper-inference#2292.

- Adds `targetFormat: "claude"` to the three qwen entries in the
  opencode-go provider registry so requests route through /messages
  with the anthropic-version header.
- Replaces the previous `qwen3.5-plus` / `qwen3.6-plus` rows in the
  PR cheaper-inference#1510 executor test (they registered the models without
  targetFormat, which now conflicts with the registry default).
- Adds a new test asserting all three qwen ids route to
  /zen/go/v1/messages and carry the anthropic-version: 2023-06-01
  header.

Fork-only commit on chatlabel/patches — upstream PR cheaper-inference#2790
is still open and does not yet include this fix.
@diegosouzapw diegosouzapw mentioned this pull request May 29, 2026
HouMinXi pushed a commit to HouMinXi/OmniRoute that referenced this pull request Aug 2, 2026
…encode-go-missing-models

feat(opencode-go): register 4 missing models from upstream catalog
Poid-ZA pushed a commit to Poid-ZA/OmniRoute that referenced this pull request Aug 5, 2026
…encode-go-missing-models

feat(opencode-go): register 4 missing models from upstream catalog
muhamadgalihsaputra pushed a commit to niyatna/NiyatnaRoute that referenced this pull request Sep 27, 2026
…encode-go-missing-models

feat(opencode-go): register 4 missing models from upstream catalog
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.

2 participants