Bug Description
Using claude-opus-4-7 or claude-sonnet-4-6 via a third-party Anthropic-compatible provider (not official Anthropic) results in a 400 error:
API Error: 400 {"error":{"type":"<nil>","message":"\"..enabled\" is not supported for this model. Use \"..adaptive\" and \"output_config.effort\" to control thinking behavior."}}
After disabling thinking and continuing an existing conversation that previously had thinking blocks, a second error occurs:
API Error: 400 {"error":{"type":"<nil>","message":"\"..content.0: Invalid signature in thinking block\""}}
⚠️ Note: The Anthropic provider used here is a third-party relay/aggregator, not the official api.anthropic.com. However, the provider supports Claude 4.x models and follows the same Anthropic API spec.
Root Cause (traced via source code)
In getAnthropicReasoningParams() (v1.9.11), claude-opus-4-7 is not recognized by isSupportAdaptiveThinkingClaudeModel() or isClaude46SeriesModel(), so it falls through to the legacy branch:
// Falls through to this — WRONG for Claude 4.x
return { thinking: { type: "enabled", budgetTokens: ... } }
Claude 4.x API no longer accepts type: "enabled" and requires thinking: { type: "adaptive" } + output_config.effort instead.
Steps To Reproduce
- Configure a third-party Anthropic-compatible provider
- Select model
claude-opus-4-7 or claude-sonnet-4-6
- Enable any reasoning effort level (lightbulb icon in input bar)
- Send any message → first 400 error appears
- Disable thinking, continue existing conversation → second 400 error ("Invalid signature in thinking block")
Expected Behavior
Cherry Studio should send thinking: { type: "adaptive" } + output_config.effort for Claude 4.x models (claude-opus-4-7, etc.), consistent with the current Anthropic API spec.
Workaround
- Disable thinking (lightbulb icon → off / default)
- Use
Cmd+K to reset context in existing topics that previously had thinking blocks enabled
Platform
macOS
Version
v1.9.11
Bug Description
Using
claude-opus-4-7orclaude-sonnet-4-6via a third-party Anthropic-compatible provider (not official Anthropic) results in a 400 error:After disabling thinking and continuing an existing conversation that previously had thinking blocks, a second error occurs:
Root Cause (traced via source code)
In
getAnthropicReasoningParams()(v1.9.11),claude-opus-4-7is not recognized byisSupportAdaptiveThinkingClaudeModel()orisClaude46SeriesModel(), so it falls through to the legacy branch:Claude 4.x API no longer accepts
type: "enabled"and requiresthinking: { type: "adaptive" }+output_config.effortinstead.Steps To Reproduce
claude-opus-4-7orclaude-sonnet-4-6Expected Behavior
Cherry Studio should send
thinking: { type: "adaptive" }+output_config.effortfor Claude 4.x models (claude-opus-4-7, etc.), consistent with the current Anthropic API spec.Workaround
Cmd+Kto reset context in existing topics that previously had thinking blocks enabledPlatform
macOS
Version
v1.9.11