This page uses LiveKit’s native OpenTelemetry pipeline. It does not require a LiveKit-specific OpenInference instrumentor.
Prerequisites
- Python 3.9+
- A LiveKit Agents application
- An Arize AX account (sign up)
- Your Arize AX Space ID and API Key
Launch Arize AX
- Sign in to your Arize AX account.
- From Space Settings, copy your Space ID and API Key.
Install
Configure credentials
Setup tracing
Create a shared tracer provider, attach an Arize OTLP exporter, and pass the provider to LiveKit before the session starts. LiveKit also lets you attach metadata to every span; use that for stable session or room attributes.Use the tracer provider in your agent
Configure tracing before the agent session starts, then flush spans during shutdown:Verify in Arize
- Run a LiveKit agent session.
- Open your Arize AX space and select project
livekit-agents-tracing-example. - You should see spans for the agent session and turn activity within ~30 seconds.
Check from the skill, CLI, or SDK
Confirm spans are actually reaching your Arize AX project. Use whichever fits your workflow — the skill and CLI work for any framework; the SDK check is shown for each language.- Arize skill (agent)
- AX CLI
- SDK
Install the Arize Skills plugin and let your coding agent check for you:Then prompt your agent:
Use the arize-trace skill to export and analyze recent traces from my project. Confirm spans are arriving, and summarize any errors or latency issues.
What Arize captures
LiveKit emits OpenTelemetry spans from its own agent runtime. Depending on your LiveKit version and plugins, those spans can include:- agent session and turn spans
- user and agent speaking spans
- lifecycle spans for agent activity
- model or realtime-model spans and metrics
- custom metadata you attach through LiveKit telemetry setup
Troubleshooting
- No spans in Arize. Confirm tracing is set before
AgentSession.start(...)and thatforce_flush()runs before the worker exits. - Spans are generic. LiveKit spans are native OpenTelemetry spans. Use OpenInference instrumentors for the LLM SDKs inside your agent if you also need rich LLM prompt, response, token, and tool metadata.
- Project name is missing. Make sure the tracer provider resource includes
openinference.project.name.