Code
cookbook/agent_concepts/user_control_flows/external_tool_execution_async.py
Usage
Key Features
- Uses
agent.arun()for asynchronous agent execution - Implements
agent.acontinue_run()for async continuation - Maintains the same external tool execution flow as synchronous version
- Demonstrates how to handle async execution with external tools
Use Cases
- Non-blocking external tool execution
- High-performance applications requiring async execution
- Web applications with external service calls
- Long-running operations with external tools