Skip to content

fix(opencode): use Mistral SDK for Mistral Large 4 - #9200

Merged
fwang merged 1 commit into
devfrom
mistral-zen-sdk
Oct 9, 2026
Merged

fwang merged 1 commit into
devfrom
mistral-zen-sdk

Conversation

@rekram1-node

Copy link
Copy Markdown
Collaborator

Summary

Add a model-specific provider.npm = "@ai-sdk/mistral" override for opencode/mistral-large-4. Keep the inherited Zen base URL, model ID, pricing, limits, and reasoning options unchanged.

Mistral Chat uses /chat/completions, but delta.content can contain native thinking/text chunk arrays. The inherited OpenAI-compatible SDK expects strings and rejects those frames. Selecting the Mistral SDK allows native parsing and conversation replay rather than a lossy proxy transform.

Source: https://docs.mistral.ai/studio/conversations/reasoning

Companion Console PR: https://github.com/anomalyco/opencode-console/pull/3343 (preserves native content and recognizes chunk arrays during inspection).

Verification

  • bun validate passed.
  • git diff --check passed.
  • No live end-to-end provider test performed.

@github-actions

github-actions Bot commented Oct 9, 2026

Copy link
Copy Markdown
Contributor

No actionable findings.

@github-actions github-actions Bot added the reviewer: ready Automated review found no actionable items label Oct 9, 2026
@fwang
fwang merged commit a2413aa into dev Oct 9, 2026
2 checks passed
@fwang
fwang deleted the mistral-zen-sdk branch October 9, 2026 06:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

reviewer: ready Automated review found no actionable items

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants