Language support
Choose a setup method
Start with one method for a call path. Combining SDK tracking with framework
OpenTelemetry on the same call can create duplicate interactions.
Recommended: Agnost AI skill
Recommended. Choose this path when you want your coding agent to inspect the
project, select a supported transport, make the smallest instrumentation change,
send a test event, and verify that it reached Agnost AI.
Manual setup: Agnost AI SDK
Manual setup: OpenTelemetry
Python: automatic instrumentation
Install
Setup
llm.input_messages.*, llm.output_messages.*, tool.name, tool.parameters, and llm.token_count.{prompt,completion}.
Alternative
The Traceloop alternative (opentelemetry-instrumentation-anthropic) emits gen_ai.* and traceloop.*: also recognized by Agnost AI.
Verify
Run oneclient.messages.create call, then open Events in Agnost AI. Confirm message and tool-use attributes appear as expected.
Troubleshooting
- Confirm
AnthropicInstrumentor().instrument(...)runs before Anthropic calls. - Confirm
OTEL_EXPORTER_OTLP_HEADERScontainsX-Agnost-Org-ID=<your-org-id>. - Confirm
using_attributeswraps the call you want grouped.
References
TypeScript: manual instrumentation
Install the OpenTelemetry packages alongside your existing Anthropic SDK:Next steps
- Conversations: review the complete Anthropic interaction.
- Events: inspect the SDK or OpenTelemetry records.
- Intents: organize production conversations by what users wanted.
