repo
stringlengths
7
90
file_url
stringlengths
81
315
file_path
stringlengths
4
228
content
stringlengths
0
32.8k
language
stringclasses
1 value
license
stringclasses
7 values
commit_sha
stringlengths
40
40
retrieved_at
stringdate
2026-01-04 14:38:15
2026-01-05 02:33:18
truncated
bool
2 classes
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_10_other/workflow_with_image_input.py
cookbook/05_workflows/_06_advanced_concepts/_10_other/workflow_with_image_input.py
from agno.agent import Agent from agno.db.sqlite import SqliteDb from agno.media import Image from agno.models.openai import OpenAIChat from agno.tools.duckduckgo import DuckDuckGoTools from agno.workflow.step import Step from agno.workflow.workflow import Workflow # Define agents image_analyzer = Agent( name="Ima...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_10_other/workflow_tools.py
cookbook/05_workflows/_06_advanced_concepts/_10_other/workflow_tools.py
""" Here is a tool with reasoning capabilities to allow agents to run workflows. 1. Run: `pip install openai agno lancedb tantivy sqlalchemy` to install the dependencies 2. Export your OPENAI_API_KEY 3. Run: `python cookbook/workflows/_06_advanced_concepts/_06_other/workflow_tools.py` to run the agent """ import asyn...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_10_other/stream_executor_events.py
cookbook/05_workflows/_06_advanced_concepts/_10_other/stream_executor_events.py
""" Example: Using stream_executor_events=False for cleaner workflow streaming. This filters out internal executor events (AgentRunEvent, ToolCallEvent, etc.) while keeping high-level workflow and step events. """ from agno.agent import Agent from agno.models.openai import OpenAIChat from agno.workflow.step import St...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_10_other/workflow_metrics_on_run_response.py
cookbook/05_workflows/_06_advanced_concepts/_10_other/workflow_metrics_on_run_response.py
import json from agno.agent import Agent from agno.db.sqlite import SqliteDb from agno.models.openai import OpenAIChat from agno.run.workflow import WorkflowRunOutput from agno.team import Team from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.hackernews import HackerNewsTools from agno.workflow.step i...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_10_other/store_events_and_events_to_skip_in_a_workflow.py
cookbook/05_workflows/_06_advanced_concepts/_10_other/store_events_and_events_to_skip_in_a_workflow.py
from agno.agent import Agent from agno.db.sqlite import SqliteDb from agno.models.openai import OpenAIChat from agno.run.agent import ( RunContentEvent, RunEvent, ToolCallCompletedEvent, ToolCallStartedEvent, ) from agno.run.workflow import WorkflowRunEvent, WorkflowRunOutput from agno.tools.hackernews ...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_10_other/workflow_with_file_input.py
cookbook/05_workflows/_06_advanced_concepts/_10_other/workflow_with_file_input.py
from agno.agent import Agent from agno.db.sqlite import SqliteDb from agno.media import File from agno.models.openai import OpenAIChat from agno.workflow.step import Step from agno.workflow.workflow import Workflow # Define agents pdf_analyzer = Agent( name="PDF Analyzer", model=OpenAIChat(id="gpt-4o"), in...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_10_other/workflow_cancel_a_run.py
cookbook/05_workflows/_06_advanced_concepts/_10_other/workflow_cancel_a_run.py
""" Example demonstrating how to cancel a running workflow execution. This example shows how to: 1. Start a workflow run in a separate thread 2. Cancel the run from another thread 3. Handle the cancelled response """ import threading import time from agno.agent import Agent from agno.models.openai import OpenAIChat ...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_02_early_stopping/early_stop_workflow_with_agents.py
cookbook/05_workflows/_06_advanced_concepts/_02_early_stopping/early_stop_workflow_with_agents.py
from agno.agent import Agent from agno.models.openai import OpenAIChat from agno.workflow import Workflow from agno.workflow.types import StepInput, StepOutput # Create agents with more specific validation criteria data_validator = Agent( name="Data Validator", model=OpenAIChat(id="gpt-4o-mini"), instructi...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_02_early_stopping/early_stop_workflow_with_condition.py
cookbook/05_workflows/_06_advanced_concepts/_02_early_stopping/early_stop_workflow_with_condition.py
from agno.agent import Agent from agno.tools.duckduckgo import DuckDuckGoTools from agno.workflow import Step, Workflow from agno.workflow.condition import Condition from agno.workflow.types import StepInput, StepOutput # Create agents researcher = Agent( name="Researcher", instructions="Research the given top...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_02_early_stopping/early_stop_workflow_with_parallel.py
cookbook/05_workflows/_06_advanced_concepts/_02_early_stopping/early_stop_workflow_with_parallel.py
from agno.agent import Agent from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.hackernews import HackerNewsTools from agno.workflow import Step, Workflow from agno.workflow.parallel import Parallel from agno.workflow.types import StepInput, StepOutput # Create agents researcher = Agent(name="Researcher...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_02_early_stopping/early_stop_workflow_with_loop.py
cookbook/05_workflows/_06_advanced_concepts/_02_early_stopping/early_stop_workflow_with_loop.py
from typing import List from agno.agent import Agent from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.hackernews import HackerNewsTools from agno.workflow import Loop, Step, Workflow from agno.workflow.types import StepInput, StepOutput # Create agents for research research_agent = Agent( name="R...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_02_early_stopping/early_stop_workflow_with_router.py
cookbook/05_workflows/_06_advanced_concepts/_02_early_stopping/early_stop_workflow_with_router.py
from typing import List from agno.agent.agent import Agent from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.hackernews import HackerNewsTools from agno.workflow.router import Router from agno.workflow.step import Step from agno.workflow.types import StepInput, StepOutput from agno.workflow.workflow im...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_02_early_stopping/early_stop_workflow_with_step.py
cookbook/05_workflows/_06_advanced_concepts/_02_early_stopping/early_stop_workflow_with_step.py
from agno.agent import Agent from agno.models.openai import OpenAIChat from agno.workflow import Step, Workflow from agno.workflow.types import StepInput, StepOutput # Create agents security_scanner = Agent( name="Security Scanner", model=OpenAIChat(id="gpt-4o-mini"), instructions=[ "You are a secu...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_02_early_stopping/early_stop_workflow_with_steps.py
cookbook/05_workflows/_06_advanced_concepts/_02_early_stopping/early_stop_workflow_with_steps.py
from agno.agent import Agent from agno.models.openai import OpenAIChat from agno.tools.duckduckgo import DuckDuckGoTools from agno.workflow.step import Step from agno.workflow.steps import Steps from agno.workflow.types import StepInput, StepOutput from agno.workflow.workflow import Workflow # Create agents content_cr...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_03_access_previous_step_outputs/access_multiple_previous_steps_output_stream.py
cookbook/05_workflows/_06_advanced_concepts/_03_access_previous_step_outputs/access_multiple_previous_steps_output_stream.py
from agno.agent.agent import Agent from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.hackernews import HackerNewsTools from agno.workflow.step import Step from agno.workflow.types import StepInput, StepOutput from agno.workflow.workflow import Workflow # Define the research agents hackernews_agent = Ag...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_03_access_previous_step_outputs/access_multiple_previous_steps_output_stream_1.py
cookbook/05_workflows/_06_advanced_concepts/_03_access_previous_step_outputs/access_multiple_previous_steps_output_stream_1.py
""" This example shows how to access the output of multiple previous steps in a workflow. The workflow is defined as a list of Step objects. Where each Step is an agent or a function. """ from agno.agent.agent import Agent from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.hackernews import HackerNewsT...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_03_access_previous_step_outputs/access_multiple_previous_step_output_stream_2.py
cookbook/05_workflows/_06_advanced_concepts/_03_access_previous_step_outputs/access_multiple_previous_step_output_stream_2.py
""" This example shows how to access the output of multiple previous steps in a workflow. The workflow is defined as a list of steps, where each step is directly an agent or a function. We dont use Step objects in this example. """ from agno.agent.agent import Agent from agno.tools.duckduckgo import DuckDuckGoTools f...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_05_background_execution/background_execution_poll.py
cookbook/05_workflows/_06_advanced_concepts/_05_background_execution/background_execution_poll.py
import asyncio from agno.agent import Agent from agno.db.sqlite import SqliteDb from agno.models.openai import OpenAIChat from agno.team import Team from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.hackernews import HackerNewsTools from agno.utils.pprint import pprint_run_response from agno.workflow.s...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_05_background_execution/background_execution_using_websocket/websocket_server.py
cookbook/05_workflows/_06_advanced_concepts/_05_background_execution/background_execution_using_websocket/websocket_server.py
import json import os from typing import Dict import uvicorn from agno.agent import Agent from agno.db.sqlite import SqliteDb from agno.models.openai import OpenAIChat from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.hackernews import HackerNewsTools from agno.workflow.step import Step from agno.workf...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_05_background_execution/background_execution_using_websocket/websocket_client.py
cookbook/05_workflows/_06_advanced_concepts/_05_background_execution/background_execution_using_websocket/websocket_client.py
import asyncio import json import sys from datetime import datetime from typing import Optional import websockets from rich.align import Align from rich.console import Console from rich.panel import Panel from rich.text import Text class WorkflowWebSocketClient: def __init__( self, server_url: st...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_06_guardrails/prompt_injection_workflow.py
cookbook/05_workflows/_06_advanced_concepts/_06_guardrails/prompt_injection_workflow.py
""" Example demonstrating how to use prompt injection guardrails in an async workflow. This example shows: 1. An async workflow with a guardrail-protected agent as the first step 2. How prompt injection attempts are blocked before processing 3. A second agent that processes validated content """ import asyncio from ...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_06_guardrails/__init__.py
cookbook/05_workflows/_06_advanced_concepts/_06_guardrails/__init__.py
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_04_shared_session_state/session_state_with_router_workflow.py
cookbook/05_workflows/_06_advanced_concepts/_04_shared_session_state/session_state_with_router_workflow.py
from typing import List from agno.agent.agent import Agent from agno.db.sqlite import SqliteDb from agno.models.openai.chat import OpenAIChat from agno.run import RunContext from agno.workflow.router import Router from agno.workflow.step import Step from agno.workflow.types import StepInput from agno.workflow.workflow...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_04_shared_session_state/condition_with_session_state_in_evaluator_function.py
cookbook/05_workflows/_06_advanced_concepts/_04_shared_session_state/condition_with_session_state_in_evaluator_function.py
""" Example demonstrating how to access session_state in Condition evaluators. This example shows: 1. Using session_state in a Condition evaluator function 2. Reading and modifying session_state based on condition logic 3. Accessing user_id and session_id from session_state 4. Making conditional decisions based on ses...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_04_shared_session_state/shared_session_state_with_team.py
cookbook/05_workflows/_06_advanced_concepts/_04_shared_session_state/shared_session_state_with_team.py
from agno.agent.agent import Agent from agno.db.sqlite import SqliteDb from agno.models.openai.chat import OpenAIChat from agno.run import RunContext from agno.team.team import Team from agno.workflow.step import Step from agno.workflow.workflow import Workflow db = SqliteDb(db_file="tmp/workflow.db") # === TEAM TOO...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_04_shared_session_state/shared_session_state_with_agent.py
cookbook/05_workflows/_06_advanced_concepts/_04_shared_session_state/shared_session_state_with_agent.py
from agno.agent.agent import Agent from agno.db.sqlite import SqliteDb from agno.models.openai.chat import OpenAIChat from agno.run import RunContext from agno.workflow.step import Step from agno.workflow.workflow import Workflow db = SqliteDb(db_file="tmp/workflow.db") # Define tools to manage a shopping list in wo...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_04_shared_session_state/access_session_state_in_custom_python_function_step.py
cookbook/05_workflows/_06_advanced_concepts/_04_shared_session_state/access_session_state_in_custom_python_function_step.py
from agno.agent import Agent from agno.db.sqlite import SqliteDb from agno.models.openai import OpenAIChat from agno.team import Team from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.hackernews import HackerNewsTools from agno.workflow.step import Step, StepInput, StepOutput from agno.workflow.workflow...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_04_shared_session_state/access_session_state_in_custom_function_step_stream.py
cookbook/05_workflows/_06_advanced_concepts/_04_shared_session_state/access_session_state_in_custom_function_step_stream.py
from typing import Iterator, Union from agno.agent import Agent from agno.db.in_memory import InMemoryDb from agno.db.sqlite import SqliteDb from agno.models.openai import OpenAIChat from agno.run.workflow import WorkflowRunOutputEvent from agno.team import Team from agno.tools.duckduckgo import DuckDuckGoTools from a...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_06_advanced_concepts/_04_shared_session_state/router_with_session_state_in_selector_function.py
cookbook/05_workflows/_06_advanced_concepts/_04_shared_session_state/router_with_session_state_in_selector_function.py
""" Example demonstrating how to access session_state in Router selectors. This example shows: 1. Using session_state in a Router selector function 2. Making routing decisions based on session state data 3. Accessing user preferences and history from session_state 4. Dynamically selecting different agents based on use...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_04_workflows_parallel_execution/__init__.py
cookbook/05_workflows/_04_workflows_parallel_execution/__init__.py
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_04_workflows_parallel_execution/async/parallel_steps_workflow.py
cookbook/05_workflows/_04_workflows_parallel_execution/async/parallel_steps_workflow.py
import asyncio from agno.agent import Agent from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.hackernews import HackerNewsTools from agno.workflow import Step, Workflow from agno.workflow.parallel import Parallel # Create agents researcher = Agent(name="Researcher", tools=[HackerNewsTools(), DuckDuckG...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_04_workflows_parallel_execution/async/parallel_and_condition_steps_stream.py
cookbook/05_workflows/_04_workflows_parallel_execution/async/parallel_and_condition_steps_stream.py
import asyncio from agno.agent.agent import Agent from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.exa import ExaTools from agno.tools.hackernews import HackerNewsTools from agno.workflow.condition import Condition from agno.workflow.parallel import Parallel from agno.workflow.step import Step from ag...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_04_workflows_parallel_execution/async/__init__.py
cookbook/05_workflows/_04_workflows_parallel_execution/async/__init__.py
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_04_workflows_parallel_execution/async/parallel_steps_workflow_stream.py
cookbook/05_workflows/_04_workflows_parallel_execution/async/parallel_steps_workflow_stream.py
import asyncio from agno.agent import Agent from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.hackernews import HackerNewsTools from agno.workflow import Step, Workflow from agno.workflow.parallel import Parallel # Create agents researcher = Agent(name="Researcher", tools=[HackerNewsTools(), DuckDuckG...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_04_workflows_parallel_execution/sync/parallel_steps_workflow.py
cookbook/05_workflows/_04_workflows_parallel_execution/sync/parallel_steps_workflow.py
from agno.agent import Agent from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.hackernews import HackerNewsTools from agno.workflow import Step, Workflow from agno.workflow.parallel import Parallel # Create agents researcher = Agent(name="Researcher", tools=[HackerNewsTools(), DuckDuckGoTools()]) write...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_04_workflows_parallel_execution/sync/parallel_and_condition_steps_stream.py
cookbook/05_workflows/_04_workflows_parallel_execution/sync/parallel_and_condition_steps_stream.py
from agno.agent import Agent from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.exa import ExaTools from agno.tools.hackernews import HackerNewsTools from agno.workflow.condition import Condition from agno.workflow.parallel import Parallel from agno.workflow.step import Step from agno.workflow.types impo...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_04_workflows_parallel_execution/sync/__init__.py
cookbook/05_workflows/_04_workflows_parallel_execution/sync/__init__.py
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_04_workflows_parallel_execution/sync/parallel_steps_workflow_stream.py
cookbook/05_workflows/_04_workflows_parallel_execution/sync/parallel_steps_workflow_stream.py
from agno.agent import Agent from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.hackernews import HackerNewsTools from agno.workflow import Step, Workflow from agno.workflow.parallel import Parallel # Create agents researcher = Agent(name="Researcher", tools=[HackerNewsTools(), DuckDuckGoTools()]) write...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_05_workflows_conditional_branching/__init__.py
cookbook/05_workflows/_05_workflows_conditional_branching/__init__.py
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_05_workflows_conditional_branching/async/router_steps_workflow_stream.py
cookbook/05_workflows/_05_workflows_conditional_branching/async/router_steps_workflow_stream.py
import asyncio from typing import List from agno.agent.agent import Agent from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.hackernews import HackerNewsTools from agno.workflow.router import Router from agno.workflow.step import Step from agno.workflow.types import StepInput from agno.workflow.workflow...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_05_workflows_conditional_branching/async/router_steps_workflow.py
cookbook/05_workflows/_05_workflows_conditional_branching/async/router_steps_workflow.py
import asyncio from typing import List from agno.agent.agent import Agent from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.hackernews import HackerNewsTools from agno.workflow.router import Router from agno.workflow.step import Step from agno.workflow.types import StepInput from agno.workflow.workflow...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_05_workflows_conditional_branching/async/router_with_loop_steps.py
cookbook/05_workflows/_05_workflows_conditional_branching/async/router_with_loop_steps.py
import asyncio from typing import List from agno.agent.agent import Agent from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.hackernews import HackerNewsTools from agno.workflow.loop import Loop from agno.workflow.router import Router from agno.workflow.step import Step from agno.workflow.types import S...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_05_workflows_conditional_branching/async/selector_for_image_video_generation_pipeline.py
cookbook/05_workflows/_05_workflows_conditional_branching/async/selector_for_image_video_generation_pipeline.py
import asyncio from typing import List, Optional from agno.agent import Agent from agno.models.openai import OpenAIChat from agno.tools.models.gemini import GeminiTools from agno.tools.openai import OpenAITools from agno.workflow.router import Router from agno.workflow.step import Step from agno.workflow.steps import ...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_05_workflows_conditional_branching/sync/router_steps_workflow_stream.py
cookbook/05_workflows/_05_workflows_conditional_branching/sync/router_steps_workflow_stream.py
from typing import List from agno.agent.agent import Agent from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.hackernews import HackerNewsTools from agno.workflow.router import Router from agno.workflow.step import Step from agno.workflow.types import StepInput from agno.workflow.workflow import Workflo...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_05_workflows_conditional_branching/sync/router_steps_workflow.py
cookbook/05_workflows/_05_workflows_conditional_branching/sync/router_steps_workflow.py
from typing import List from agno.agent.agent import Agent from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.hackernews import HackerNewsTools from agno.workflow.router import Router from agno.workflow.step import Step from agno.workflow.types import StepInput from agno.workflow.workflow import Workflo...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_05_workflows_conditional_branching/sync/router_with_loop_steps.py
cookbook/05_workflows/_05_workflows_conditional_branching/sync/router_with_loop_steps.py
from typing import List from agno.agent.agent import Agent from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.hackernews import HackerNewsTools from agno.workflow.loop import Loop from agno.workflow.router import Router from agno.workflow.step import Step from agno.workflow.types import StepInput, StepO...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/05_workflows/_05_workflows_conditional_branching/sync/selector_for_image_video_generation_pipelines.py
cookbook/05_workflows/_05_workflows_conditional_branching/sync/selector_for_image_video_generation_pipelines.py
from typing import List, Optional from agno.agent import Agent from agno.models.openai import OpenAIChat from agno.tools.models.gemini import GeminiTools from agno.tools.openai import OpenAITools from agno.workflow.router import Router from agno.workflow.step import Step from agno.workflow.steps import Steps from agno...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/__init__.py
cookbook/10_reasoning/__init__.py
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/tools/ibm_watsonx_reasoning_tools.py
cookbook/10_reasoning/tools/ibm_watsonx_reasoning_tools.py
from textwrap import dedent from agno.agent import Agent, RunOutput # noqa from agno.models.ibm import WatsonX from agno.tools.reasoning import ReasoningTools """🧠 Problem-Solving Reasoning Agent This example shows how to create an agent that uses the ReasoningTools to solve complex problems through step-by-step r...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/tools/gemini_reasoning_tools.py
cookbook/10_reasoning/tools/gemini_reasoning_tools.py
from agno.agent import Agent from agno.models.google import Gemini from agno.tools.reasoning import ReasoningTools from agno.tools.yfinance import YFinanceTools reasoning_agent = Agent( model=Gemini(id="gemini-2.5-pro"), tools=[ ReasoningTools( enable_think=True, enable_analyze=...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/tools/workflow_tools.py
cookbook/10_reasoning/tools/workflow_tools.py
""" 1. Run: `pip install openai agno lancedb tantivy sqlalchemy` to install the dependencies 2. Export your OPENAI_API_KEY 3. Run: `python cookbook/reasoning/tools/knowledge_tools.py` to run the agent """ from textwrap import dedent from agno.agent import Agent from agno.db.sqlite import SqliteDb from agno.models.ope...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/tools/reasoning_tools.py
cookbook/10_reasoning/tools/reasoning_tools.py
"""🧠 Problem-Solving Reasoning Agent This example shows how to create an agent that uses the ReasoningTools to solve complex problems through step-by-step reasoning. The agent breaks down questions, analyzes intermediate results, and builds structured reasoning paths to arrive at well-justified conclusions. Example ...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/tools/llama_reasoning_tools.py
cookbook/10_reasoning/tools/llama_reasoning_tools.py
from agno.agent import Agent from agno.models.meta import Llama from agno.tools.reasoning import ReasoningTools from agno.tools.yfinance import YFinanceTools reasoning_agent = Agent( model=Llama(id="Llama-4-Maverick-17B-128E-Instruct-FP8"), tools=[ ReasoningTools( enable_think=True, ...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/tools/memory_tools.py
cookbook/10_reasoning/tools/memory_tools.py
""" 1. Run: `pip install openai agno lancedb tantivy sqlalchemy` to install the dependencies 2. Export your OPENAI_API_KEY 3. Run: `python cookbook/reasoning/tools/knowledge_tools.py` to run the agent """ import asyncio from agno.agent import Agent from agno.db.sqlite import SqliteDb from agno.models.openai import Op...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/tools/capture_reasoning_content_reasoning_tools.py
cookbook/10_reasoning/tools/capture_reasoning_content_reasoning_tools.py
"""Test for reasoning_content generation This script tests whether reasoning_content is properly populated in the RunOutput when using ReasoningTools. It tests both streaming and non-streaming modes. """ from textwrap import dedent from agno.agent import Agent from agno.models.openai import OpenAIChat from agno.tool...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/tools/claude_reasoning_tools.py
cookbook/10_reasoning/tools/claude_reasoning_tools.py
from agno.agent import Agent from agno.models.anthropic import Claude from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.reasoning import ReasoningTools reasoning_agent = Agent( model=Claude(id="claude-sonnet-4-20250514"), tools=[ ReasoningTools(add_instructions=True), DuckDuckGo...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/tools/gemini_finance_agent.py
cookbook/10_reasoning/tools/gemini_finance_agent.py
# -*- coding: utf-8 -*- """gemini_finance_agent.ipynb Automatically generated by Colab. Original file is located at https://colab.research.google.com/drive/1XYnlyi_LFuvtR0qSHDLOWMRGMmgi60RQ """ # ! pip install -U agno from agno.agent import Agent from agno.models.google import Gemini from agno.tools.reasoning i...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/tools/capture_reasoning_content_knowledge_tools.py
cookbook/10_reasoning/tools/capture_reasoning_content_knowledge_tools.py
""" Cookbook: Capturing reasoning_content with KnowledgeTools This example demonstrates how to access and print the reasoning_content when using KnowledgeTools with URL knowledge, in both streaming and non-streaming modes. """ import asyncio from textwrap import dedent from agno.agent import Agent from agno.knowledg...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/tools/groq_llama_finance_agent.py
cookbook/10_reasoning/tools/groq_llama_finance_agent.py
from textwrap import dedent from agno.agent import Agent from agno.models.groq import Groq from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.reasoning import ReasoningTools thinking_llama = Agent( model=Groq(id="meta-llama/llama-4-scout-17b-16e-instruct"), tools=[ ReasoningTools(), ...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/tools/cerebras_llama_reasoning_tools.py
cookbook/10_reasoning/tools/cerebras_llama_reasoning_tools.py
"""🧠 Problem-Solving Reasoning Agent This example shows how to create an agent that uses the ReasoningTools to solve complex problems through step-by-step reasoning. The agent breaks down questions, analyzes intermediate results, and builds structured reasoning paths to arrive at well-justified conclusions. Example ...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/tools/ollama_reasoning_tools.py
cookbook/10_reasoning/tools/ollama_reasoning_tools.py
from agno.agent import Agent from agno.models.ollama.chat import Ollama from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.reasoning import ReasoningTools reasoning_agent = Agent( model=Ollama(id="llama3.2:latest"), tools=[ ReasoningTools( enable_think=True, enabl...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/tools/azure_openai_reasoning_tools.py
cookbook/10_reasoning/tools/azure_openai_reasoning_tools.py
from agno.agent import Agent from agno.models.azure.openai_chat import AzureOpenAI from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.reasoning import ReasoningTools reasoning_agent = Agent( model=AzureOpenAI(id="gpt-4o-mini"), tools=[ DuckDuckGoTools(), ReasoningTools( ...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/tools/__init__.py
cookbook/10_reasoning/tools/__init__.py
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/tools/openai_reasoning_tools.py
cookbook/10_reasoning/tools/openai_reasoning_tools.py
from agno.agent import Agent from agno.models.openai import OpenAIChat from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.reasoning import ReasoningTools reasoning_agent = Agent( model=OpenAIChat(id="gpt-4o"), tools=[ ReasoningTools( enable_think=True, enable_anal...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/tools/knowledge_tools.py
cookbook/10_reasoning/tools/knowledge_tools.py
""" 1. Run: `pip install openai agno lancedb tantivy sqlalchemy` to install the dependencies 2. Export your OPENAI_API_KEY 3. Run: `python cookbook/reasoning/tools/knowledge_tools.py` to run the agent """ from agno.agent import Agent from agno.knowledge.embedder.openai import OpenAIEmbedder from agno.knowledge.knowled...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/tools/vercel_reasoning_tools.py
cookbook/10_reasoning/tools/vercel_reasoning_tools.py
from agno.agent import Agent from agno.models.vercel import v0 from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.reasoning import ReasoningTools reasoning_agent = Agent( model=v0(id="v0-1.0-md"), tools=[ ReasoningTools(add_instructions=True, add_few_shot=True), DuckDuckGoTools()...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/teams/finance_team_chain_of_thought.py
cookbook/10_reasoning/teams/finance_team_chain_of_thought.py
import asyncio from textwrap import dedent from agno.agent import Agent from agno.models.openai import OpenAIChat from agno.team.team import Team from agno.tools.duckduckgo import DuckDuckGoTools web_agent = Agent( name="Web Search Agent", role="Handle web search requests", model=OpenAIChat(id="gpt-4o-min...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/teams/knowledge_tool_team.py
cookbook/10_reasoning/teams/knowledge_tool_team.py
from agno.agent import Agent from agno.knowledge.knowledge import Knowledge from agno.models.openai import OpenAIChat from agno.team.team import Team from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.knowledge import KnowledgeTools from agno.vectordb.lancedb import LanceDb, SearchType agno_docs = Knowl...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/teams/reasoning_finance_team.py
cookbook/10_reasoning/teams/reasoning_finance_team.py
from textwrap import dedent from agno.agent import Agent from agno.models.anthropic import Claude from agno.models.openai import OpenAIChat from agno.team.team import Team from agno.tools.duckduckgo import DuckDuckGoTools from agno.tools.reasoning import ReasoningTools web_agent = Agent( name="Web Search Agent", ...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/teams/__init__.py
cookbook/10_reasoning/teams/__init__.py
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/agents/capture_reasoning_content_default_COT.py
cookbook/10_reasoning/agents/capture_reasoning_content_default_COT.py
""" Cookbook: Working with reasoning_content in Agents This example demonstrates how to access and print the reasoning_content when using either reasoning=True or setting a specific reasoning_model. """ from agno.agent import Agent from agno.models.openai import OpenAIChat print("\n=== Example 1: Using reasoning=Tru...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/agents/finance_agent.py
cookbook/10_reasoning/agents/finance_agent.py
from agno.agent import Agent from agno.models.openai import OpenAIChat from agno.tools.yfinance import YFinanceTools reasoning_agent = Agent( model=OpenAIChat(id="gpt-4o"), tools=[YFinanceTools()], instructions="Use tables to display data", use_json_mode=True, reasoning=True, markdown=True, ) r...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/agents/fibonacci.py
cookbook/10_reasoning/agents/fibonacci.py
from agno.agent import Agent from agno.models.openai import OpenAIChat task = "Give me steps to write a python script for fibonacci series" reasoning_agent = Agent( model=OpenAIChat(id="gpt-4o"), reasoning=True, markdown=True, ) reasoning_agent.print_response(task, stream=True, show_full_reasoning=True)
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/agents/analyse_treaty_of_versailles.py
cookbook/10_reasoning/agents/analyse_treaty_of_versailles.py
from agno.agent import Agent from agno.models.openai import OpenAIChat task = ( "Analyze the key factors that led to the signing of the Treaty of Versailles in 1919. " "Discuss the political, economic, and social impacts of the treaty on Germany and how it " "contributed to the onset of World War II. Provi...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/agents/ibm_watsonx_default_COT.py
cookbook/10_reasoning/agents/ibm_watsonx_default_COT.py
from agno.agent import Agent, RunOutput # noqa from agno.models.ibm import WatsonX """ This example demonstrates how it works when you pass a non-reasoning model as a reasoning model. It defaults to using the default OpenAI reasoning model. We recommend using the appropriate reasoning model or passing reasoning=True ...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/agents/mistral_reasoning_cot.py
cookbook/10_reasoning/agents/mistral_reasoning_cot.py
from agno.agent import Agent from agno.models.mistral import MistralChat # It uses the default model of the Agent reasoning_agent = Agent( model=MistralChat(id="mistral-large-latest"), reasoning=True, markdown=True, use_json_mode=True, ) reasoning_agent.print_response( "Give me steps to write a pyt...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/agents/ship_of_theseus.py
cookbook/10_reasoning/agents/ship_of_theseus.py
from agno.agent import Agent from agno.models.openai import OpenAIChat task = ( "Discuss the concept of 'The Ship of Theseus' and its implications on the notions of identity and change. " "Present arguments for and against the idea that an object that has had all of its components replaced remains " "funda...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/agents/python_101_curriculum.py
cookbook/10_reasoning/agents/python_101_curriculum.py
from agno.agent import Agent from agno.models.openai import OpenAIChat task = "Craft a curriculum for Python 101" reasoning_agent = Agent( model=OpenAIChat(id="gpt-4o"), reasoning=True, markdown=True, ) reasoning_agent.print_response(task, stream=True, show_full_reasoning=True)
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/agents/strawberry.py
cookbook/10_reasoning/agents/strawberry.py
import asyncio from agno.agent import Agent from agno.cli.console import console from agno.models.openai import OpenAIChat task = "How many 'r' are in the word 'strawberry'?" regular_agent = Agent(model=OpenAIChat(id="gpt-4o"), markdown=True) reasoning_agent = Agent( model=OpenAIChat(id="gpt-4o"), reasoning=...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/agents/trolley_problem.py
cookbook/10_reasoning/agents/trolley_problem.py
from agno.agent import Agent from agno.models.openai import OpenAIChat agent = Agent( model=OpenAIChat(id="gpt-4o"), reasoning=True, markdown=True, ) agent.print_response( "Solve the trolley problem. Evaluate multiple ethical frameworks. " "Include an ASCII diagram of your solution.", stream=Tr...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/agents/logical_puzzle.py
cookbook/10_reasoning/agents/logical_puzzle.py
from agno.agent import Agent from agno.models.openai import OpenAIChat task = ( "Three missionaries and three cannibals need to cross a river. " "They have a boat that can carry up to two people at a time. " "If, at any time, the cannibals outnumber the missionaries on either side of the river, the canniba...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/agents/scientific_research.py
cookbook/10_reasoning/agents/scientific_research.py
from agno.agent import Agent from agno.models.openai import OpenAIChat task = ( "Read the following abstract of a scientific paper and provide a critical evaluation of its methodology," "results, conclusions, and any potential biases or flaws:\n\n" "Abstract: This study examines the effect of a new teachin...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/agents/life_in_500000_years.py
cookbook/10_reasoning/agents/life_in_500000_years.py
from agno.agent import Agent from agno.models.openai import OpenAIChat task = "Write a short story about life in 500000 years" reasoning_agent = Agent( model=OpenAIChat(id="gpt-4o"), reasoning=True, markdown=True, ) reasoning_agent.print_response(task, stream=True, show_full_reasoning=True)
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/agents/__init__.py
cookbook/10_reasoning/agents/__init__.py
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/agents/is_9_11_bigger_than_9_9.py
cookbook/10_reasoning/agents/is_9_11_bigger_than_9_9.py
from agno.agent import Agent from agno.cli.console import console from agno.models.openai import OpenAIChat task = "9.11 and 9.9 -- which is bigger?" regular_agent = Agent(model=OpenAIChat(id="gpt-4o"), markdown=True) reasoning_agent = Agent( model=OpenAIChat(id="gpt-4o"), reasoning=True, markdown=True, )...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/agents/default_chain_of_thought.py
cookbook/10_reasoning/agents/default_chain_of_thought.py
""" This example demonstrates how it works when you pass a non-reasoning model as a reasoning model. It defaults to using the default OpenAI reasoning model. We recommend using the appropriate reasoning model or passing reasoning=True for the default COT. """ from agno.agent import Agent from agno.models.openai import...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/agents/mathematical_proof.py
cookbook/10_reasoning/agents/mathematical_proof.py
from agno.agent import Agent from agno.models.openai import OpenAIChat task = "Prove that for any positive integer n, the sum of the first n odd numbers is equal to n squared. Provide a detailed proof." reasoning_agent = Agent( model=OpenAIChat(id="gpt-4o"), reasoning=True, markdown=True, ) reasoning_agen...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/agents/plan_itenerary.py
cookbook/10_reasoning/agents/plan_itenerary.py
from agno.agent import Agent from agno.models.openai import OpenAIChat task = "Plan an itinerary from Los Angeles to Las Vegas" reasoning_agent = Agent( model=OpenAIChat(id="gpt-4o"), reasoning=True, markdown=True, ) reasoning_agent.print_response(task, stream=True, show_full_reasoning=True)
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/agents/cerebras_llama_default_COT.py
cookbook/10_reasoning/agents/cerebras_llama_default_COT.py
from agno.agent import Agent, RunOutput # noqa from agno.models.cerebras import Cerebras """ This example demonstrates how it works when you pass a non-reasoning model as a reasoning model. It defaults to using the default OpenAI reasoning model. We recommend using the appropriate reasoning model or passing reasoning...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/models/__init__.py
cookbook/10_reasoning/models/__init__.py
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/models/openai/o1_pro.py
cookbook/10_reasoning/models/openai/o1_pro.py
from agno.agent import Agent from agno.models.openai import OpenAIResponses agent = Agent(model=OpenAIResponses(id="o1-pro")) agent.print_response( "Solve the trolley problem. Evaluate multiple ethical frameworks. " "Include an ASCII diagram of your solution.", stream=True, )
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/models/openai/reasoning_effort.py
cookbook/10_reasoning/models/openai/reasoning_effort.py
from agno.agent import Agent from agno.models.openai import OpenAIChat from agno.tools.duckduckgo import DuckDuckGoTools agent = Agent( model=OpenAIChat(id="o3-mini", reasoning_effort="high"), tools=[DuckDuckGoTools(enable_search=True)], instructions="Use tables to display data.", markdown=True, ) age...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/models/openai/o3_mini.py
cookbook/10_reasoning/models/openai/o3_mini.py
from agno.agent import Agent from agno.models.openai import OpenAIChat agent = Agent( model=OpenAIChat(id="o3-mini"), ) agent.print_response( "Solve the trolley problem. Evaluate multiple ethical frameworks. " "Include an ASCII diagram of your solution.", stream=True, )
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/models/openai/o3_mini_with_tools.py
cookbook/10_reasoning/models/openai/o3_mini_with_tools.py
from agno.agent import Agent from agno.models.openai import OpenAIChat from agno.tools.duckduckgo import DuckDuckGoTools agent = Agent( model=OpenAIChat(id="o3-mini"), tools=[DuckDuckGoTools(enable_search=True)], instructions="Use tables to display data.", markdown=True, ) agent.print_response("Write ...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/models/openai/reasoning_model_gpt_4_1.py
cookbook/10_reasoning/models/openai/reasoning_model_gpt_4_1.py
from agno.agent import Agent from agno.models.openai.responses import OpenAIResponses agent = Agent( model=OpenAIResponses(id="gpt-4o-mini"), reasoning_model=OpenAIResponses(id="gpt-4.1"), ) agent.print_response( "Solve the trolley problem. Evaluate multiple ethical frameworks. " "Include an ASCII diag...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/models/openai/o4_mini.py
cookbook/10_reasoning/models/openai/o4_mini.py
from agno.agent import Agent from agno.models.openai.responses import OpenAIResponses agent = Agent(model=OpenAIResponses(id="o4-mini")) agent.print_response( "Solve the trolley problem. Evaluate multiple ethical frameworks. " "Include an ASCII diagram of your solution.", stream=True, )
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/models/openai/__init__.py
cookbook/10_reasoning/models/openai/__init__.py
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/models/openai/reasoning_summary.py
cookbook/10_reasoning/models/openai/reasoning_summary.py
"""This example shows how to get reasoning summaries with our OpenAIResponses model. Useful for contexts where a long reasoning process is relevant and directly relevant to the user.""" from agno.agent import Agent from agno.models.openai import OpenAIResponses from agno.tools.duckduckgo import DuckDuckGoTools # Setu...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/models/openai/reasoning_stream.py
cookbook/10_reasoning/models/openai/reasoning_stream.py
from agno.agent import Agent from agno.models.openai import OpenAIResponses from agno.run.agent import RunEvent # noqa # Create an agent with reasoning enabled agent = Agent( reasoning_model=OpenAIResponses( id="o3-mini", reasoning_effort="low", ), reasoning=True, instructions="Think s...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false
agno-agi/agno
https://github.com/agno-agi/agno/blob/26b9daa0fb760c3ad8384e1ba9218b1bce854535/cookbook/10_reasoning/models/vertex_ai/basic_reasoning_stream.py
cookbook/10_reasoning/models/vertex_ai/basic_reasoning_stream.py
import asyncio from agno.agent import Agent from agno.models.google import Gemini from agno.run.agent import RunEvent # noqa async def streaming_reasoning(): """Test streaming reasoning with a VertexAI with Gemini model.""" # Create an agent with reasoning enabled agent = Agent( reasoning_model=...
python
Apache-2.0
26b9daa0fb760c3ad8384e1ba9218b1bce854535
2026-01-04T14:41:49.609528Z
false