Python: Add max reasoning effort option - #8857
Open
Brian Caswell (demoray) wants to merge 1 commit into
Open
Brian Caswell (demoray) wants to merge 1 commit into
Brian Caswell (demoray) wants to merge 1 commit into
Conversation
Brian Caswell (demoray)
deployed
to
github-app-auth
September 29, 2026 16:54 — with
GitHub Actions
Active
Brian Caswell (demoray)
deployed
to
github-app-auth
September 29, 2026 16:54 — with
GitHub Actions
Active
Copilot started reviewing on behalf of
Brian Caswell (demoray)
September 29, 2026 16:55
View session
Contributor
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
The linked issue also requires publicly exporting ReasoningOptions, which remains unavailable from the package API.
Review effort: Balanced
Findings: 1
Open (1)
What changed in this PR
Adds OpenAI’s max reasoning-effort value to Python type checking.
Changes:
- Extends
ReasoningOptions.effortwith"max".
| File | Description |
|---|---|
python/packages/openai/agent_framework_openai/_chat_client.py |
Adds the max effort literal. |
💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.
| """ | ||
|
|
||
| effort: Literal["none", "low", "medium", "high", "xhigh"] | ||
| effort: Literal["none", "low", "medium", "high", "xhigh", "max"] |
There was a problem hiding this comment.
As the issue creator, I decided that I would not implement that change as this is a larger change to the AI than what is specifically needed.
Brian Caswell (demoray)
marked this pull request as ready for review
September 29, 2026 17:31
Brian Caswell (demoray)
deployed
to
github-app-auth
September 29, 2026 17:31 — with
GitHub Actions
Active
This branch was successfully deployed
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.

Motivation & Context
Current OpenAI reasoning models support
maxas a distinct reasoning-effort value, butReasoningOptionsrejects it during static type checking. This prevents callers from using the provider-supported value without weakening or duplicating the options type.Description & Review Guide
maxto theReasoningOptions.effortliteral.reasoning.effort="max". Request forwarding is unchanged and already preserves the value.Related Issue
Fixes #8856
Contribution Checklist
breaking changelabel (or add "[BREAKING]" to the title prefix, before or after any language prefix) — a workflow keeps the label and title prefix in sync automatically.