Preserve thinking content for providers that require it#8857
Preserve thinking content for providers that require it#8857
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: a02a417871
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 81da1fb0e5
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: fd13ad1937
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 95a5facfa1
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| model_doc_link: None, | ||
| setup_steps: vec![], | ||
| fast_model: None, | ||
| preserves_thinking: false, |
There was a problem hiding this comment.
Allow custom providers to opt into preserved thinking
Fresh evidence after the earlier custom_deepseek concern: this commit marks built-in JSONs as preserves_thinking: true, but newly created custom providers are now hardcoded to preserves_thinking: false here, and the create/update request types still expose no way to set it. Since format_messages_with_options in providers/formats/openai.rs now sends reasoning_content only when that flag is enabled, custom OpenAI-compatible providers that depend on reasoning replay can silently lose tool-call continuation context unless users manually edit provider JSON.
Useful? React with 👍 / 👎.
Summary
clear_thinking: falsein OpenAI-compatible providerspreserves_thinkingflag for Anthropic-compatible providersTesting
Fixes #7363