Learning resourcesReviewed · Anthropic

Thinking in tool and multi-turn workflows

Thinking in tool and multi-turn workflows is an Anthropic guide for developers connecting Claude to tools, with a strict requirement to preserve returned thinking blocks unchanged. It demonstrates a weather-tool round trip, explains reasoning between tool calls and documents differences between adaptive and manual thinking.

Researched 13 Nov 2026

In short.

This Anthropic tutorial helps developers build Claude assistants that use tools, but their code must preserve the returned assistant content unchanged during the tool-use turn. Its examples show how to request a tool call, retain thinking blocks and signatures, and return a tool result linked to the correct call. It also explains model-specific restrictions on forced tool use and how thinking can occur between calls. The weather result is simulated, SDK versions and operating costs are unspecified, and nothing was executed.

Researched and written by an AI model and checked by a second AI model. How it works

Coverage includes the complete supplied page at [https://platform.claude.com/docs/en/build-with-claude/thinking-tool-workflows.md], all language examples, both interleaving illustrations, the retention notice and the next-step link descriptions. Linked documentation pages are excluded. No code or API calls were executed. Live behavior, SDK compatibility, model availability, operating costs and reuse rights remain unverified where the page does not establish them.

The overview

Resource identity

Thinking in tool and multi-turn workflows is a documentation walkthrough on Anthropic's Claude developer platform. Its subject is conversation handling when Claude combines thinking with tools. The selected source is [https://platform.claude.com/docs/en/build-with-claude/thinking-tool-workflows.md]; the page metadata identifies [https://platform.claude.com/docs/en/build-with-claude/thinking-tool-workflows] as its URL.

Practical assessment

The guide is useful for implementing or debugging the boundary between a Claude response and application code that executes a tool. Its strongest contribution is the explicit instruction to return the complete assistant content array, including thinking blocks and signatures, instead of reconstructing a message from selected fields.

It provides a concrete integration pattern rather than evidence of improved answer quality. No execution results, reliability measurements, latency comparisons or benchmarks are established by the page.

Who it suits

The main audience is developers building Claude applications that call functions, APIs or databases. Beginners can follow the weather example to understand which messages the application must send. Experienced developers can use the preservation rules and model-specific restrictions when reviewing conversation storage and request construction.

Readers need some familiarity with API requests, structured messages and tool schemas. The page does not provide a complete introduction to authentication, SDK installation or running an external service.

What it teaches

The walkthrough covers defining get_weather, enabling adaptive thinking, locating a tool_use block, preserving the assistant response, returning a matching tool_result and reading the continuation. It also explains that adaptive thinking may omit thinking on simple requests.

Initial-request examples cover cURL, the ant CLI, Python, TypeScript, C#, Go, Java, PHP and Ruby. Continuation examples cover the seven SDK languages; the shell entries direct readers to an SDK for the additional logic.

A separate comparison illustrates a calculator followed by a database query, showing how interleaved thinking adds reasoning after intermediate tool results.

Using it

Requirements and compatibility

Following the example requires authenticated Claude API access, a compatible client, conversation state and application code that supplies tool results. The cURL sample reads an API key from ANTHROPIC_API_KEY. A real weather integration also needs an actual weather-data implementation.

The examples use claude-opus-5-5 with thinking type adaptive. For Claude Opus 4.5, Sonnet 4.5, Haiku 4.5 and earlier Claude 4 models, the page instructs readers to substitute manual thinking with type enabled and budget_tokens: N. It does not specify SDK versions, installation commands or a value for N.

How the message exchange works

Claude returns structured content blocks. A tool_use block asks the application to perform an operation; the application executes that operation and supplies its result. The follow-up conversation includes the original user request, the complete assistant content as received, and a user message containing a tool_result whose tool_use_id matches the requested call.

The page treats the entire tool-use loop as one assistant turn, even though it involves multiple API requests. The thinking configuration must remain consistent within that turn. It warns that dropping thinking blocks loses their reasoning context even when no error occurs.

Interleaved thinking allows new thinking blocks after tool results. It is automatic in adaptive mode. Tools can still chain without interleaved thinking; the difference is where additional thinking appears.

Implementation setup

The demonstrated setup defines get_weather with an object input schema requiring a location string, enables adaptive thinking and sends a weather question. The application retains response.content, extracts the requested tool's identifier and sends a continuation with the tool result.

The central implementation rule is to pass the returned assistant content through unchanged, including signatures and any additional blocks. Several language snippets omit imports or surrounding project setup, so the page alone does not establish a complete installation procedure.

Worked example and its boundaries

The user asks for the weather in Paris. The illustrated response requests get_weather with location Paris. Application code supplies a simulated temperature of 88°F, preserves the preceding assistant content and returns the temperature using the matching tool call identifier. The illustrated final answer reports 88°F, approximately 31°C.

The temperature is a placeholder, not a live observation. The shown response blocks describe expected behavior rather than an independently observed run. Nothing was executed.

Assessment & evidence

Constraints and missing coverage

With manual extended thinking, tool_choice must be auto or none; forced tool use returns an error. For adaptive thinking, the page says forced tool use returns a 400 error on Claude Opus 5.5, Sonnet 5.5, Fable 5.2, Mythos 5.2, Fable 5.1 and Mythos 5.1. It says other models accept forced tool use but skip thinking.

Visible thinking text is not guaranteed. The page says display: summarized is needed to see the illustrated thinking text on models whose display defaults to omitted, including Opus 5.5. Otherwise, the thinking text can be empty while the signature remains populated; preservation is still required.

The implemented example handles one requested weather tool. Several snippets assume a tool_use block is present, although TypeScript checks for one and Ruby explicitly raises if none exists. A complete strategy for repeated calls, tool failures, retries, streaming and parallel tool execution is not developed here.

Why the pattern matters

The preservation requirement matters because the assistant's returned message carries information needed for continuation, including signed thinking blocks. Returning only the tool request discards part of that message. The guide explicitly warns that this can lose reasoning without producing an error.

The calculator-and-database illustration suggests why reasoning between tools may help when later actions depend on earlier results. That is a conceptual explanation, not measured evidence that interleaving improves accuracy or speed.

Related approaches

Within the page, the main implementation choices are SDK language, model-compatible thinking mode and whether the workflow has interleaved thinking. Manual thinking is presented as the substitution for the listed older models, while adaptive thinking is used in the main example.

For broader explanations, the page links to Thinking [https://platform.claude.com/docs/en/build-with-claude/thinking] and Extended thinking [https://platform.claude.com/docs/en/build-with-claude/extended-thinking]. Their contents are outside this assessment. The selected page provides no comparison with other providers or agent frameworks.

Evidence and confidence

The evidence is the complete supplied text of this Anthropic documentation page, including its rules, language examples, illustrative outputs and interleaving comparison. It supports describing the documented request structure and constraints.

The examples are instructional evidence, not execution receipts. Successful SDK compilation, API acceptance, live model availability and real tool behavior are not established. Linked pages contribute no additional evidence beyond the descriptions and notices visible here.

Access & freshness

Costs and usage

Operating cost is unknown. The page supplies no API prices, thinking-token billing rules, external tool fees or worked cost estimates.

The examples set max_tokens to 16000. That configuration value does not establish actual token consumption, latency or the price of a completed exchange. The page links to further thinking guidance, but that linked content is outside the selected source.

Reuse rights and data retention

The supplied page text includes no explicit license or redistribution terms for its documentation or code examples. Permission to reuse or redistribute them is unknown from this source.

A notice directs readers to API and data retention information for zero data retention applicability [https://platform.claude.com/docs/en/manage-claude/api-and-data-retention]. The notice itself does not establish retention guarantees, eligibility or contractual terms.

Dates and version limits

The available documentation snapshot was captured at 2026-11-13T23:13:15.315Z. No publication date or last-updated date is supplied in the page text.

The cURL example specifies anthropic-version: 2026-10-21. That is the example's API header value, not a documentation publication date or SDK version. Current availability of the named models and compatibility of particular SDK releases are unknown beyond what this snapshot states.

Practical next steps

For an implementation, confirm the intended model's thinking mode and tool_choice behavior, preserve the entire returned assistant content, and match each tool result to its tool_use identifier. Handle responses without a tool request and replace the simulated weather value with an actual tool implementation.

Before estimating operating requirements, obtain the applicable SDK compatibility information, pricing and data-retention terms. These details are not established by this page.

Evidence for this report

selected-page.txtselected · checked 2026-11-13