By Sagar Shankaran, Founder of CallSphere
Deep dive into Claude's extended thinking and the think tool for agentic workflows. Learn how explicit reasoning blocks improve multi-step decision making, tool use accuracy, and complex problem solving in production AI agents.
Key takeaways
When building AI agents that chain multiple tool calls, one of the most persistent failure modes is the model making premature decisions. It reads partial information, picks the first plausible action, and only realizes the mistake three steps later. Claude's think tool addresses this by giving the model a dedicated space to reason before acting.
The think tool is not the same as extended thinking (the thinking budget feature). Extended thinking happens automatically at the start of a response and is controlled via the thinking parameter. The think tool, by contrast, is a tool the model can invoke at any point during an agentic loop to pause and reason explicitly between tool calls.
| Feature | Extended Thinking | Think Tool |
|---|---|---|
| When it fires | Start of each response turn | Any point during agentic loop |
| Control mechanism | thinking.budget_tokens parameter |
Tool definition in tools array |
| Use case | Complex initial reasoning | Mid-workflow deliberation |
| Visibility | Thinking blocks in response | Tool call + result in conversation |
| Token cost | Counts toward thinking budget | Counts as regular tool use tokens |
The key insight is that in multi-turn agentic workflows, the model needs to reason not just at the beginning of its first response, but repeatedly throughout a long task as new information arrives from tool results.
The think tool is remarkably simple to define. You add it as a tool in your API request, and Claude will call it when it needs to deliberate.
flowchart TD
SPEC(["Task spec"])
SYSTEM["System prompt<br/>role plus rules"]
SHOTS["Few shot examples<br/>3 to 5"]
VARS["Variable injection<br/>Jinja or f-string"]
COT["Chain of thought<br/>or scratchpad"]
CONSTR["Output constraint<br/>JSON schema"]
LLM["LLM call"]
EVAL["Offline eval<br/>LLM as judge plus regex"]
GATE{"Score over<br/>threshold?"}
COMMIT(["Promote to prod<br/>version pinned"])
REVISE(["Revise prompt"])
SPEC --> SYSTEM --> SHOTS --> VARS --> COT --> CONSTR --> LLM --> EVAL --> GATE
GATE -->|Yes| COMMIT
GATE -->|No| REVISE --> SYSTEM
style LLM fill:#4f46e5,stroke:#4338ca,color:#fff
style EVAL fill:#f59e0b,stroke:#d97706,color:#1f2937
style COMMIT fill:#059669,stroke:#047857,color:#fff
import anthropic
client = anthropic.Anthropic()
# Define the think tool alongside your other tools
tools = [
{
"name": "think",
"description": (
"Use this tool to think through complex problems step-by-step. "
"Call this tool when you need to analyze information from previous "
"tool results, plan your next actions, or reason about edge cases "
"before making a decision. Your thinking will not be shown to the user."
),
"input_schema": {
"type": "object",
"properties": {
"reasoning": {
"type": "string",
"description": "Your step-by-step reasoning about the current situation."
}
},
"required": ["reasoning"]
}
},
{
"name": "search_codebase",
"description": "Search for files matching a pattern in the codebase.",
"input_schema": {
"type": "object",
"properties": {
"query": {"type": "string"},
"file_pattern": {"type": "string"}
},
"required": ["query"]
}
},
{
"name": "edit_file",
"description": "Apply an edit to a file.",
"input_schema": {
"type": "object",
"properties": {
"path": {"type": "string"},
"old_text": {"type": "string"},
"new_text": {"type": "string"}
},
"required": ["path", "old_text", "new_text"]
}
}
]
When Claude invokes the think tool, you simply return an acknowledgment. The value is in the reasoning the model wrote, not in any external action.
Hear it before you finish reading
Talk to a live CallSphere AI voice agent in your browser — 60 seconds, no signup.
def run_agent_loop(messages: list, tools: list) -> str:
"""Run the agentic loop with think tool support."""
while True:
response = client.messages.create(
model="claude-sonnet-4-20250514",
max_tokens=8096,
tools=tools,
messages=messages
)
# Check if we are done
if response.stop_reason == "end_turn":
# Extract final text response
for block in response.content:
if hasattr(block, "text"):
return block.text
return ""
# Process tool calls
tool_results = []
for block in response.content:
if block.type == "tool_use":
if block.name == "think":
# Think tool: just acknowledge it
# The reasoning is captured in block.input["reasoning"]
tool_results.append({
"type": "tool_result",
"tool_use_id": block.id,
"content": "Thinking complete. Proceed with your next action."
})
else:
# Execute real tools
result = execute_tool(block.name, block.input)
tool_results.append({
"type": "tool_result",
"tool_use_id": block.id,
"content": result
})
# Append assistant response and tool results
messages.append({"role": "assistant", "content": response.content})
messages.append({"role": "user", "content": tool_results})
Based on benchmarks and real-world usage, the think tool provides measurable improvements in three specific scenarios.
When the output of one tool call determines which tool to call next, the model benefits from pausing to analyze intermediate results.
Example pattern: An agent that searches a codebase, reads a file, then decides what edit to make. Without the think tool, the model sometimes edits based on assumptions from the search results alone, without fully processing the file contents.
Measured improvement: In internal evaluations of coding agents, adding the think tool reduced incorrect edits by 30-40% on tasks requiring three or more sequential tool calls.
When the agent must evaluate a user request against multiple constraints or business rules, explicit reasoning prevents the model from satisfying one constraint while violating another.
# System prompt that benefits from think tool usage
system_prompt = """You are a customer service agent for an insurance company.
Before taking any action, use the think tool to verify:
1. The customer's identity has been confirmed
2. The requested change is within policy limits
3. The change does not require supervisor approval
4. All regulatory disclosure requirements are met
Only proceed with the action after confirming all four conditions."""
When tool results contain contradictory data or when the user's request is ambiguous, the think tool gives the model space to resolve the ambiguity explicitly rather than picking an interpretation silently.
You can use both features simultaneously. Extended thinking handles the initial planning phase, while the think tool handles mid-execution deliberation.
Still reading? Stop comparing — try CallSphere live.
CallSphere ships complete AI voice agents per industry — 14 tools for healthcare, 10 agents for real estate, 4 specialists for salons. See how it actually handles a call before you book a demo.
response = client.messages.create(
model="claude-sonnet-4-20250514",
max_tokens=16000,
thinking={
"type": "enabled",
"budget_tokens": 5000 # For initial reasoning
},
tools=tools, # Includes think tool for mid-loop reasoning
messages=messages
)
When to use which:
Over-specifying when to think: If your system prompt says "use the think tool before every action," the model will think even when the next step is obvious, wasting tokens and adding latency.
Using think tool as a scratchpad for computation: The think tool is for reasoning about what to do, not for performing calculations. If you need computation, use a code execution tool.
Ignoring the reasoning content: While you return a simple acknowledgment, you should log the think tool's reasoning content. It is invaluable for debugging agent behavior and understanding why the agent made specific decisions.
if block.name == "think":
reasoning = block.input["reasoning"]
logger.info(f"Agent reasoning: {reasoning}")
# Store for debugging and evaluation
reasoning_trace.append({
"step": step_count,
"reasoning": reasoning,
"timestamp": datetime.utcnow().isoformat()
})
Teams deploying the think tool in production coding assistants and customer service agents have reported consistent improvements.
The think tool is not a silver bullet. For simple, single-tool tasks, it adds latency without benefit. But for any agent that chains three or more tool calls with decision points between them, it is one of the highest-impact improvements available today.
The think tool fills a critical gap in agentic AI: the ability to reason deliberately between actions. Extended thinking handles upfront planning, but agents need to think on their feet as new information arrives. By adding a simple tool definition and processing it in your agent loop, you give Claude the space to make better decisions throughout complex workflows. The implementation cost is minimal, but the impact on multi-step task accuracy is substantial.

Written by
Sagar Shankaran· Founder, CallSphere
LinkedInSagar Shankaran is the founder of CallSphere, where he builds production AI voice and chat agents deployed across healthcare, hospitality, real estate, and home services. He writes about agentic AI, LLM engineering, and shipping voice agents that handle real calls in production.
See how AI voice agents work for your industry. Live demo available -- no signup required.
The 2026 desktop AI agent landscape — ServiceNow Project Arc, Anthropic Claude offerings, OpenAI agents, and Google Mariner. A buyer's map.
An agentic-AI perspective on Anthropic Skills system, covering orchestration patterns, tool use, and how agent tooling fits production agent stacks.
Enterprise CIO Guide perspective on Comet's general-availability launch put an agentic browser in front of millions of consumers, and it works better than the demos suggested.
Enterprise CIO Guide perspective on Harvey AI's enterprise rollout numbers show legal agents have moved past the pilot stage at AmLaw 100 firms.
Enterprise CIO Guide perspective on Hippocratic AI's deployment numbers show healthcare voice agents are moving from pilot to production across major US health systems.
An agentic-AI perspective on Claude Agent SDK loops, covering orchestration patterns, tool use, and how agent orchestration fits production agent stacks.
© 2026 CallSphere Inc. All rights reserved.
Made within San Francisco
Watch how CallSphere handles real customer calls, schedules appointments, and processes payments — live.
Try Live DemoBook a DemoCalculate Your ROI