fix(opencode): expose max reasoning effort for GPT-5.6+ models#36136
Closed
javargasm wants to merge 1 commit into
Closed
fix(opencode): expose max reasoning effort for GPT-5.6+ models#36136javargasm wants to merge 1 commit into
javargasm wants to merge 1 commit into
Conversation
OpenAI reasoning_options for GPT-5.6 family models include "max" but OpenCode was capping at "xhigh". Add a dedicated effort constant for version >= 6 and update versionedGpt5ReasoningEfforts to use it.
Contributor
|
Thanks for your contribution! This PR doesn't have a linked issue. All PRs must reference an existing issue. Please:
See CONTRIBUTING.md for details. |
Contributor
|
Thanks for updating your PR! It now meets our contributing guidelines. 👍 |
Author
|
this is the correct fix: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Issue for this PR
Closes #36141
Type of change
What does this PR do?
OpenAI's
reasoning_optionsfor GPT-5.6 family models (gpt-5.6, gpt-5.6-terra, gpt-5.6-luna, gpt-5.6-sol) includemaxas a valid reasoning effort, butversionedGpt5ReasoningEffortsintransform.tsreturnsOPENAI_GPT5_2_PLUS_EFFORTSfor all versions >= 2, which caps atxhigh.The fix adds a dedicated
OPENAI_GPT5_6_PLUS_EFFORTSconstant that extends the 2+ set withmax, and aversion >= 6check inversionedGpt5ReasoningEffortsto use it. Only GPT-5.6+ models are affected — earlier versions keep their existing effort sets unchanged.How did you verify your code works?
bun test test/provider/transform.test.ts— 295 tests pass (0 failures)gpt-5.6andgpt-5.6-terrathat assert the full effort set["none", "low", "medium", "high", "xhigh", "max"]Screenshots / recordings
N/A — no UI change.
Checklist