Skip to content

[codex] Route opencode chat models through Zen#638

Merged
jahooma merged 3 commits intomainfrom
jahooma/opencode-chat-routing
May 11, 2026
Merged

[codex] Route opencode chat models through Zen#638
jahooma merged 3 commits intomainfrom
jahooma/opencode-chat-routing

Conversation

@brandonkachen
Copy link
Copy Markdown
Collaborator

@brandonkachen brandonkachen commented May 10, 2026

Summary

Route chat completions for supported opencode/* models through the direct OpenCode Zen provider, while also aliasing moonshotai/kimi-k2.6 to Zen's kimi-k2.6 model for now. The adapter separates routing eligibility, upstream model mapping, and provider pricing, and now rejects unsupported opencode/* models with a 400 before calling the provider. This adds explicit OpenCode Zen support and pricing for opencode/minimax-m2.7, and updates the chat-completions provider tests to cover Kimi, Minimax M2.7, and unsupported OpenCode Zen model rejection.

Validation

  • bun test web/src/app/api/v1/chat/completions/__tests__/completions.test.ts
  • bun run --cwd web typecheck
  • bun run --cwd common typecheck

@jahooma jahooma merged commit 0203b7c into main May 11, 2026
35 checks passed
@jahooma jahooma deleted the jahooma/opencode-chat-routing branch May 11, 2026 00:26
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