Skip to content

Unable to Display Model Reasoning: Claude Code Proxy

Quick fix

Upgrade to cc-switch 4.0.13 and retest. If the issue persists, ignore late reasoning deltas after the response body begins.

Error output
无法显示模型的思考过程
English translation

Unable to display the model's reasoning process

When using `apiFormat: "openai_chat"` with reasoning models, providers may use different fields and streaming sequences for reasoning content, such as `reasoning`, `reasoning_content`, or other formats. If the proxy does not recognize the relevant field, Claude Code will not display the reasoning process.

Qwen-compatible streams may continue sending reasoning deltas interleaved after visible `content` begins. `create_anthropic_sse_stream` closes and reopens Anthropic content blocks whenever the type changes, splitting the response into multiple `thinking` and `text` blocks and causing Claude Code to display many fragments. The two issues respectively show missing reasoning and fragmented response text. The former was closed after a long period without updates, with the maintainer only recommending an upgrade and retest; the latter remains open.

  1. Upgrade cc-switch to the maintainer-recommended 4.0.13 and retest with the original OpenAI-compatible provider. No user has yet confirmed that this resolves the issue.

  2. If the issue remains reproducible, run `claude -p --verbose --output-format stream-json --include-partial-messages "What model are you?"` and check whether `reasoning_content` and `content` appear interleaved in the response.

  3. The proxy must preserve reasoning before the first visible text. Once the response body begins, ignore subsequent late reasoning deltas to avoid repeatedly creating `thinking` and `text` blocks. The local response normalizer in the issue produced only one continuous text block after applying this rule.

  4. Add regression tests for alternating reasoning/content chunks. Verify that there is at most one `thinking` block and one `text` block, that the response body is fully joined, and that no reasoning is emitted after the response body begins.

ToolClaude Code
Versioncc-switch 3.11.1 - 3.18.0(报告受影响)
PlatformsWindows

(No FAQ yet)

This is an unofficial community wiki with no affiliation to the cc-switch authors or the project itself. Its content is compiled from the project's public GitHub issues. This site distributes no software.