Documentation Index
Fetch the complete documentation index at: https://spacesail.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
This example shows how to create a reasoning team that can handle complex queries involving web search and financial data using the coordinate mode with reasoning capabilities.
Code
cookbook/examples/teams/coordinate_mode/reasoning_team.py
from agno.agent import Agent
from agno.models.anthropic import Claude
from agno.models.openai import OpenAIChat
from agno.team import Team
from agno.tools.duckduckgo import DuckDuckGoTools
from agno.tools.reasoning import ReasoningTools
from agno.tools.exa import ExaTools
web_agent = Agent(
name="Web Search Agent",
role="Handle web search requests",
model=OpenAIChat(id="gpt-5-mini"),
tools=[DuckDuckGoTools()],
instructions=["Always include sources"],
)
finance_agent = Agent(
name="Finance Agent",
role="Handle financial data requests",
model=OpenAIChat(id="gpt-5-mini"),
tools=[
ExaTools(
include_domains=["cnbc.com", "reuters.com", "bloomberg.com", "wsj.com"],
show_results=True,
text=False,
highlights=False,
)
],
instructions=["Use tables to display data"],
)
team_leader = Team(
name="Reasoning Team Leader",
model=Claude(id="claude-3-7-sonnet-latest"),
members=[
web_agent,
finance_agent,
],
tools=[ReasoningTools(add_instructions=True)],
markdown=True,
show_members_responses=True,
)
team_leader.print_response(
"Tell me 1 company in New York, 1 in San Francisco and 1 in Chicago and the stock price of each",
stream=True,
stream_events=True,
show_full_reasoning=True,
)
Usage
Create a virtual environment
Open the Terminal and create a python virtual environment.python3 -m venv .venv
source .venv/bin/activate
Install required libraries
pip install agno ddgs exa anthropic
Set environment variables
export OPENAI_API_KEY=****
export ANTHROPIC_API_KEY=****
export EXA_API_KEY=****
Run the agent
python cookbook/examples/teams/reasoning_team.py