This integration is currently in beta. If you encounter any issues or unexpected behavior, please reach out for feedback and support.
Lunary supports Pydantic AI through OpenTelemetry instrumentation via Logfire.
To integrate Pydantic AI with Lunary, you only need to configure the OpenTelemetry exporter and instrument Pydantic AI:
Full Example
Here’s a complete example showing how to use Pydantic AI with Lunary:
This will automatically track:
- Agent calls and responses
- Model parameters and settings
- Output schema validation
- Performance metrics
- Errors and exceptions
All telemetry data will be sent to Lunary for monitoring and analysis.