-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Fix: Respect reasoning_effort config for GPT-5 models #2131
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
naorpeled
merged 5 commits into
qodo-ai:main
from
Tyler-Rak:fix/respect-reasoning-effort-config
Jan 31, 2026
+702
−13
Merged
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
8ac6c64
Fix GPT-5 models to respect reasoning_effort config setting
Tyler-Rak 8b5b8f4
Refactor reasoning_effort logic for better readability
Tyler-Rak 02fb0c3
Add comprehensive unit tests for GPT-5 reasoning_effort configuration
Tyler-Rak e023ffe
Simplify reasoning_effort logic and extend ReasoningEffort enum
Tyler-Rak e36f299
Add warning for invalid reasoning_effort in o3/o4 models
Tyler-Rak File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
1. Azure gpt-5 models skip reasoning configuration
🐞 Bug✓ Correctness• When using Azure-deployed GPT-5 models, the model name is transformed to 'azure/gpt-5-xxx' at line 272 BEFORE the GPT-5 check at line 294 • The condition model.startswith('gpt-5') will fail for Azure models since 'azure/gpt-5-xxx'.startswith('gpt-5') returns False • This causes Azure GPT-5 models to skip the reasoning_effort configuration entirely, resulting in API calls without the required reasoning_effort parameter • GPT-5 models require reasoning_effort to function properly, so this will likely cause API errors or unexpected behaviorAgent prompt
ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools