Conversation
…points reasoning_effort: none was injecting extra_body.think=false for every custom provider. Mistral (and other extra=forbid hosts) reject that field with HTTP 422. Keep think=false on Ollama URLs only; still send top-level reasoning_effort=none so /v1 thinking-off keeps working.
Cover the Mistral extra_forbidden case and keep the Ollama dual-emission contract (think=false + reasoning_effort=none) on port 11434 / ollama hosts.
Contributor
|
Merged via #98000 — your commits Right file (the profile plugin, where |
This was referenced Aug 29, 2026
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.
Summary
reasoning_effort: none) was stuffing Ollama'sthink: falseinto every custom OpenAI-compatible request. Strict hosts like Mistral reject unknown fields (extra_forbidden→ HTTP 422), so chat dies immediately.think=falsenow goes out only for Ollama URLs (port 11434 /ollamahost). Everyone else still gets top-levelreasoning_effort: "none"so Ollama/v1thinking-off keeps working.think=Falseincorrectly sent to allprovider=customendpoints, not just Ollama #11237; prior PRs (fix(agent): stop sending think=false to remote custom providers #11296, fix: only send think=false to Ollama, not all custom providers #11520, fix(agent): restrict think=False to Ollama/local endpoints only #11362, fix(providers): scope think to Ollama endpoints #64286) never landed.Test plan
scripts/run_tests.sh tests/plugins/model_providers/test_custom_profile.py tests/providers/test_transport_parity.py tests/agent/transports/test_chat_completions.py -qhttps://api.mistral.ai/v1+ Reasoning Off → request succeeds (nothinkin the body)http://127.0.0.1:11434/v1+ Reasoning Off → still sendsthink: falseandreasoning_effort: "none"