Applies to Claude Opus 5.5 / Sonnet 5.5 / Haiku 5.5 / Fable 5.1 / Fable 5 / Opus 5 / Sonnet 5 / Opus 4.8 / 4.7 / 4.6 / 4.5.
Parameters and defaults reflect Anthropic’s official documentation as of 2026-11-08 (UTC+8). If the provider changes them later, the official docs and the live response win.
Key takeaways
- Claude 5-generation and newer models think by default: Opus 5.5, Sonnet 5.5, Haiku 5.5, Fable 5.1, Fable 5, Opus 5 and Sonnet 5 all use adaptive thinking. Opus 4.8, 4.7, 4.6 and 4.5 do not think by default; you must pass
thinkingexplicitly. - Thinking tokens count toward
max_tokensand are billed as output tokens.max_tokensis the hard cap;effortis a soft steer. Lowering effort reduces overall spend, but it does not guarantee thinking stays under a specific number. - Some 5-generation models cannot turn thinking off:
thinking: {"type": "disabled"}returns 400 on Opus 5.5, Fable 5.1 and Fable 5. Sonnet 5.5 usesthinking: {"type": "between_tools"}to disable upfront thinking. Haiku 5.5 and Opus 5 acceptdisabledwhen effort ishighor lower. Sonnet 5 acceptsdisableddirectly. - When
effortis omitted, most models default tohigh; only Opus 5.5 and Haiku 5.5 default tomedium. - Read
usage.output_tokens_details.thinking_tokensfor the split.usage.output_tokensincludes thinking; if the two are equal, the visible text is zero.
Model quick reference
This table lists base models currently sold. Only models whose “turn thinking off” column says
disabled accept thinking: {"type": "disabled"}. Models marked 400 have no off switch; lower effort instead.effort: levels, defaults and selection
Five levels
Per-model availability
- Every effort-capable model supports
low/medium/high. xhigh: Fable 5.1, Fable 5, Opus 5.5, Opus 5, Opus 4.8, Opus 4.7, Sonnet 5.5, Sonnet 5 and Haiku 5.5. Opus 4.6 and Sonnet 4.6 do not supportxhigh.max: all of the above, plus Opus 4.6 and Sonnet 4.6.- Opus 4.5: supports
effort, but only alongsidebudget_tokens; Sonnet 4.5 and Haiku 4.5 do not supporteffort.
Defaults
- Opus 5.5 and Haiku 5.5 default to
medium. - Every other effort-capable model defaults to
high. - Setting
effortto the model default behaves exactly like omitting it.
How to choose
- Opus 5.5 coding / agents: start at
high; usexhighfor long-running, long-chain work; drop tomediumonly after evals show quality holds. - Sonnet 5.5: the provider suggests starting at
mediumfor well-scoped agent coding, then raising tohighfor harder tasks. - Haiku 5.5:
lowis enough for classification, extraction and routing; raise it when reasoning demands grow. - Cost first: dropping one level is usually gentler than switching models. But effort is a soft signal — hard problems may still think at
low. Do not treat it as a hard budget. - Never pass
adaptiveas an effort value:adaptiveis a thinking mode, not an effort level; putting it inoutput_config.effortreturns 400.
The thinking parameter: four forms
Omit thinking
The model default applies: 5-generation models think; 4.7 / 4.8 / 4.6 / 4.5 do not. For most 5-generation use cases you can simply omit it.
adaptive
{"type": "adaptive"} lets the model decide whether and how deeply to think, with effort steering overall spend. Opus 4.7 / 4.8 use it to turn thinking on; 4.6 also supports it; 5-generation models already think by default, so passing it just confirms the default.
disabled and between_tools
{"type": "disabled"}: only works on models where the table allows it. Opus 5.5, Fable 5.1 and Fable 5 return 400; Opus 5 and Haiku 5.5 accept it only when effort ishighor lower.{"type": "between_tools"}: Sonnet 5.5 only. It disables upfront thinking while keeping progress updates between tool calls; it accepts onlylow/medium/high, and cannot be combined withdisplay,budget_tokensor other fields.
Legacy enabled + budget_tokens
This is the extended-thinking form for 4.5 / 4.6:
adaptive + output_config.effort.
display: whether thinking text comes back
omitted(default): the thinking block still appears, but itsthinkingfield is empty. This is the default on 5-generation models, Fable 5.1 / 5, Opus 5, Sonnet 5, Opus 4.8 / 4.7 and Haiku 5.5.summarized: returns a thinking summary. Opus 4.6, Sonnet 4.6 and earlier default to this.omittedonly hides the text; thinking tokens are still billed at full length.- What you get is a summary, never raw chain-of-thought. Do not ask the model to dump internal reasoning into the response — on 5-generation and Fable models this can trigger a refusal (
stop_details.category: "reasoning_extraction").
Request examples
Opus 5.5: omitthinking, steer with effort.
display explicitly:
Response and streaming
content is an array of blocks; thinking blocks come before text blocks:
text_delta; it has its own event sequence:
Common
stop_reason values:
When
max_tokens is greater than 21,333, the official SDK requires streaming (a client-side check, not an API limit). If you do not need event-by-event handling, use client.messages.stream(...).get_final_message().max_tokens: thinking counts, empty text starts here
max_tokens caps thinking + text + tool calls, not text alone. Set it too low and thinking consumes the budget before any text is written.
A real shape: a code-change task with about 44k input tokens and max_tokens: 30000 spent all 30,000 on thinking, returned stop_reason: max_tokens, and produced zero text. Raising the cap above 64,000 gives the same effort room to write.
Guidance:
- For coding, long-form and agent work, start at 64,000; give it 128,000 when a single run must produce a lot of code.
max_tokensis a cap, not a reservation. Generation stops when done and you pay for actual tokens.- If input + cap exceeds the context window, 4.5 and newer models accept the request and stop at the window edge with
stop_reason: model_context_window_exceededinstead of erroring. - On HTTP 200 with empty text, check
stop_reasonandthinking_tokensbefore assuming an API fault. See Why a reasoning model returns an empty response.
Multi-turn and tools: replay thinking blocks verbatim
- Inside a tool loop, replay is mandatory: put the previous
thinkingblock back intomessagestogether with itstool_useblock,signatureincluded. Do not edit, reorder, or keep the text while dropping the signature. - Across turns, replay is recommended: Opus 4.5 and newer Opus, Sonnet 4.6 and newer Sonnet, Haiku 5.5 and Fable 5.1 / 5 retain previous turns by default; older models strip them automatically, so you do not need to prune by hand.
- Do not rely on cross-generation reasoning when switching models: a thinking block can only be read by the model that produced it and a fixed set of other models. Opus 5.5 can read Opus 5 and older Opus / Sonnet / Haiku blocks, but not Fable / Mythos; unreadable blocks are dropped without an error.
- History is append-only: changing
system,toolsor earlier messages breaks the prefix check; changing the thinking config oreffortmid-conversation also invalidates the prompt cache from that point. - For the classic invalid-signature error, see How to fix Claude’s invalid thinking signature.
Compatibility and common 400s
APIYI may silently ignore some deprecated parameters. A missing 400 does not prove the request never reached the provider model. Remove legacy parameters as the official docs require.
APIYI setup notes
- Anthropic native:
https://api.apiyi.comwith/v1/messages; use theClaudeCodegroup. - OpenAI-compatible:
https://api.apiyi.com/v1with/v1/chat/completions; use thedefault/svipgroups. - The gateway translates the native Anthropic format to the upstream format and does not add
thinking/effortfor you. Thinking is the model’s own default behavior. - On 5-generation models, thinking blocks are bound to the model and the conversation prefix. Design for append-only history; do not edit earlier messages between turns.
Official documentation
Anthropic’s docs, copy the URL into your browser. Parameters and the current model list follow the official source.Related
Claude API Basics
Endpoints, auth, groups and a minimal request
Claude Response Handling
Content blocks, SSE events and stop_reason
Claude Prompt Caching
Cache writes, reads and billing
Why a reasoning model returns an empty response
Three checks for HTTP 200 with empty text
How to fix an invalid thinking signature
Signature failures in multi-turn chats
Long-form output practices
max_tokens, timeouts and resuming