You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Sonntet 4.5 thinking boxes are not showing despite thinking boxes enabled. #2919
I have been using sonnet 4.5 through OpenRouter and it doesnt seem like the thinking boxes are working despite thinking being enabled.
Model options also have correctly configured thinking with thinking budget set to 32k.
This is opencode:
Same prompt with Crush without any provider options:
So the opencode results are way more detailed and its taking more time than Crush because of my thinking settings, so i am certain its thinking but its not showing inside the tui.
Your issue with Sonnet 4.5 thinking boxes not displaying through OpenRouter appears very similar to these previous reports about thinking blocks visibility issues with Claude models.
Feel free to ignore if none of these address your specific case.
@Amansaxena001 that's because thinking isn't enabled by default, I know what the settings look like for most providers I haven't seeen what it is for openrouter tho it doesnt seem to work for them. SO I am guessing there is a setting naming difference that needs to be documented
@Amansaxena001 that's because thinking isn't enabled by default, I know what the settings look like for most providers I haven't seeen what it is for openrouter tho it doesnt seem to work for them. SO I am guessing there is a setting naming difference that needs to be documented
Ok i know the reason why, im blind.
Basically, i am switching between plan and build mode all the time, and for whatever reason the model keeps switching as well between official Claude Sonnet 4.5 model where extended thinking is disabled and my custom configured sonnet 4.5 model where thinking is working.
Here in build mode:
After switching to plan mode with tab model switches:
@XSIRIX when you switch models for a agent, we save the last used model, so when u are switching agents it also switches models to what u last used when uding that agent, unless ofc you hardcode the model in the agent definition
I don't have time to review atm, but confident it's how the AI SDK Provider for Anthropic is mapping the properties from OpenCode config, there's a missing piece
Activity
github-actions commentedon Oct 2, 2025
This issue might be a duplicate of existing issues. Please check:
thinkingorredacted_thinking, but foundtext." #2599: v0.8.0 introduced thinking block bugs with Claude Sonnet 4, causing API errors with thinking blocksYour issue with Sonnet 4.5 thinking boxes not displaying through OpenRouter appears very similar to these previous reports about thinking blocks visibility issues with Claude models.
Feel free to ignore if none of these address your specific case.
rekram1-node commentedon Oct 2, 2025
@XSIRIX can you show your opencode.json
XSIRIX commentedon Oct 2, 2025
@rekram1-node hey yea:
rekram1-node commentedon Oct 2, 2025
Hm I think when you are using openrouter the settings are different than they would be for an anthropic model ususally let me see
Amansaxena001 commentedon Oct 3, 2025
Im using all default still I dont see the thinking sections
rekram1-node commentedon Oct 3, 2025
@Amansaxena001 that's because thinking isn't enabled by default, I know what the settings look like for most providers I haven't seeen what it is for openrouter tho it doesnt seem to work for them. SO I am guessing there is a setting naming difference that needs to be documented
XSIRIX commentedon Oct 4, 2025
Ok i know the reason why, im blind.
Basically, i am switching between plan and build mode all the time, and for whatever reason the model keeps switching as well between official Claude Sonnet 4.5 model where extended thinking is disabled and my custom configured sonnet 4.5 model where thinking is working.
Here in build mode:
After switching to plan mode with tab model switches:
this looks like a bug to me
rekram1-node commentedon Oct 4, 2025
@XSIRIX when you switch models for a agent, we save the last used model, so when u are switching agents it also switches models to what u last used when uding that agent, unless ofc you hardcode the model in the agent definition
rekram1-node commentedon Oct 4, 2025
does this resolve issue? Or are you still having problems just wanna make sure I am following you correctly
numman-ali commentedon Oct 5, 2025
I haven't been able to enable thinking when using Claude with OAuth
I tried the config here:
https://opencode.ai/docs/models/#configure-models
{ "$schema": "https://opencode.ai/config.json", "provider": { "openai": { "models": { "gpt-5": { "options": { "reasoningEffort": "high", "textVerbosity": "low", "reasoningSummary": "auto", "include": ["reasoning.encrypted_content"], }, }, }, }, "anthropic": { "models": { "claude-sonnet-4-5-20250929": { "options": { "thinking": { "type": "enabled", "budgetTokens": 16000, }, }, }, }, }, }, }rekram1-node commentedon Oct 5, 2025
@numman-ali oh did you try
/thinkingin the tui?numman-ali commentedon Oct 5, 2025
Yes, I'm pretty confident there's an issue with how options may be passed to opencode, and no thinking ever occurs on the Sonnet 4.5 model
I made the OpenAI OAuth Plugin https://github.com/numman-ali/opencode-openai-codex-auth so I'm pretty familiar with how opencode works
I don't have time to review atm, but confident it's how the AI SDK Provider for Anthropic is mapping the properties from OpenCode config, there's a missing piece
rekram1-node commentedon Oct 5, 2025
@numman-ali if you are using anthropic then that config works:
Can you run
opencode debug configand show me output? And you are using anthropic right not openrouter or any other providerrekram1-node commentedon Oct 5, 2025
I copied your config verbatim and sent "hello" to claude sonnet 4.5, thinking shows as expected
F0x1d commentedon Oct 9, 2025
It seems that it works if i use
but if i use it with custom id, it does not
F0x1d commentedon Oct 10, 2025
@rekram1-node can you check it please?
rekram1-node commentedon Oct 10, 2025
yes I will, I managed to replicate, I know issue
Amansaxena001 commentedon Oct 13, 2025
There is
"alwaysThinkingEnabled": falseinsettings.jsonfile which works @rekram1-noderekram1-node commentedon Oct 17, 2025
this should be fixed