Skip to main content
Thinking capabilities enable your agent to plan and orchestrate multiple tool calls in a structured, step-by-step manner. This feature is essential when tasks require coordinating several tools to reach a comprehensive conclusion.

Why Use Thinking?

Thinking is most valuable when your agent has multiple tools and needs to:
  • Create an execution plan before acting
  • Call tools in a specific sequence
  • Synthesize results from multiple sources
Without thinking, agents make ad-hoc tool calls. With thinking, agents strategically plan their approach first.

Enabling Thinking

To enable thinking capabilities, set enable_thinking_tool=True when creating your agent:

How Thinking Works

When thinking is enabled, the agent follows a structured “blueprint” approach:
  1. Strategic Planning: The agent creates a complete, sequential plan of tool calls
  2. Orchestrated Execution: Tools are executed step-by-step according to the plan
  3. Final Synthesis: Results from all tools are combined into a comprehensive answer

Thinking vs. Basic Mode

FeatureBasic ModeThinking Mode
PlanningAd-hoc tool callsStructured blueprint creation
ExecutionDirect tool executionOrchestrated step-by-step execution
Best ForSingle tool tasksMulti-tool coordination

Thinking Configuration

Agent-Level Thinking

Task-Level Thinking

Mixed Configuration

When to Use Thinking

Thinking is ideal for:
  • Multi-source Research: Gathering data from multiple tools and synthesizing
  • Step-by-Step Analysis: Tasks requiring sequential tool execution
  • Complex Workflows: When tool outputs feed into subsequent tool calls
  • Data Aggregation: Combining results from several sources

Example: Financial Analysis with Multiple Tools

Example: Multi-City Research

Thinking Output Structure

When thinking is enabled, the agent provides:
  1. Reasoning: Detailed strategy for approaching the task
  2. Execution Plan: Step-by-step tool call sequence
  3. Criticism: Self-assessment identifying potential issues
  4. Final Synthesis: Comprehensive answer combining all tool results

Performance Considerations

Important: Thinking capabilities consume more tokens and processing time than basic mode due to the planning and synthesis steps. Use thinking when the orchestration value outweighs the cost.

Best Practices

  1. Use for Multi-Tool Tasks: Enable thinking when you have 2+ tools that need coordination
  2. Disable for Simple Queries: Use basic mode for single-tool or no-tool tasks
  3. Provide Clear Instructions: Help the agent plan by being specific about what you need
  4. Include Multiple Tools: Thinking shines when there are tools to orchestrate
  5. Monitor with Debug Mode: Use debug=True to understand the planning process
Thinking provides a powerful way to handle complex scenarios that require multiple tools working together, making it essential for sophisticated multi-step analysis and research tasks.