Agno
Learn how to use Langtrace with Agno for building multi-modal agents and tracing
Agno is a lightweight library for building multi-modal agents, designed with simplicity, speed, and flexibility in mind. It avoids complex graphs and chains, offering a pure Python experience for effortless development. Optimized for performance, Agno enables blazing-fast agents with minimal memory usage.
With Langtrace, you can gain deep visibility into your agents’ operations, including tool calls, memory operations, reasoning steps, and model interactions.
Setup
- Install the Langtrace’s SDK and initialize the SDK in your code.
- Install the Agno Library.
- Setup environment variables:
Usage
Initialize Langtrace before creating your Phidata agent:
Create and run the agent:
What’s being traced?
With Langtrace, the following operations are automatically traced:
-
Agent Run Operations:
- Input/output content
- Run duration and timestamps
- Stream events for streaming responses
-
Tool Calls:
- Function name and parameters
- Execution time
- Return values and errors
-
Memory Operations:
- Memory updates
- Chat history retrievals
- User memory creation
View all these trace details in the Langtrace dashboard: