Agno Instrumentation
Learn how to instrument Agno agents and send traces to LangWatch using the Python SDK.
LangWatch supports seamless observability for Agno agents. You can instrument your Agno-based applications and send traces directly to LangWatch for monitoring and analysis.
This guide shows how to set up tracing for Agno agents using the LangWatch Python SDK. Unlike the default OpenTelemetry/OTLP setup, you only need to call langwatch.setup()
—no manual exporter or environment variable configuration is required.
Prerequisites
- Install the required packages:
- Get your LangWatch API key from your project settings and set it as an environment variable:
Instrumenting Agno with LangWatch
You can use the OpenInference Agno instrumentor to automatically capture traces from your Agno agents. Just pass the instrumentor to langwatch.setup()
.
That’s it! All Agno agent activity will now be traced and sent to your LangWatch dashboard.
Notes
- You do not need to set any OpenTelemetry environment variables or configure exporters manually—
langwatch.setup()
handles everything. - You can combine Agno instrumentation with other instrumentors (e.g., OpenAI, LangChain) by adding them to the
instrumentors
list. - For advanced configuration (custom attributes, endpoint, etc.), see the Python integration guide.
Troubleshooting
- Make sure your
LANGWATCH_API_KEY
is set in the environment. - If you see no traces in LangWatch, check that the instrumentor is included in
langwatch.setup()
and that your agent code is being executed.
For more details, see the LangWatch Python SDK reference and the Agno documentation.