Skip to content

fix(provider): add Merge Gateway reasoning variants - #41867

Open
MatthewFeroz wants to merge 1 commit into
anomalyco:devfrom
MatthewFeroz:merge-reasoning
Open

fix(provider): add Merge Gateway reasoning variants#41867
MatthewFeroz wants to merge 1 commit into
anomalyco:devfrom
MatthewFeroz:merge-reasoning

Conversation

@MatthewFeroz

@MatthewFeroz MatthewFeroz commented Aug 11, 2026

Copy link
Copy Markdown

Issue for this PR

Closes #41868

Type of change

  • Bug fix
  • New feature
  • Refactor / code improvement
  • Documentation

What does this PR do?

Merge Gateway models can declare reasoning effort choices through models.dev, but OpenCode did not recognize the adapter's mergeGateway provider-options key. As a result, reasoning variants were not selectable and selected efforts were not passed to the adapter correctly.

This adds provider-wide support for merge-gateway-ai-sdk-provider. It preserves the effort values declared by models.dev and passes the selected value through mergeGateway.reasoningEffort. The implementation does not hard-code individual model IDs.

How did you verify your code works?

  • Ran bun test test/provider/transform.test.ts test/provider/provider.test.ts from packages/opencode: 509 passed
  • Ran bun typecheck from packages/opencode
  • Connected MERGE Gateway in the local OpenCode web app
  • Selected GPT-5.6 Sol with the High reasoning variant
  • Confirmed the request completed successfully through Merge Gateway

Screenshots / recordings

image image

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR

If you do not follow this template your PR will be automatically rejected.

@github-actions github-actions Bot added needs:issue needs:compliance This means the issue will auto-close after 2 hours. labels Aug 11, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Thanks for your contribution!

This PR doesn't have a linked issue. All PRs must reference an existing issue.

Please:

  1. Open an issue describing the bug/feature (if one doesn't exist)
  2. Add Fixes #<number> or Closes #<number> to this PR description

See CONTRIBUTING.md for details.

@github-actions github-actions Bot removed needs:compliance This means the issue will auto-close after 2 hours. needs:issue labels Aug 11, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Thanks for updating your PR! It now meets our contributing guidelines. 👍

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.

Merge Gateway reasoning effort variants are not selectable

1 participant