Sentrial SDK
Best for new integrations, agent sessions, tool calls, prompt variants, costs, and
Sentrial-specific workflows.
OpenTelemetry
Best when your agents already emit OTel spans or you need vendor-neutral collection through an
existing collector.
Which Path Should I Use?
Use the Sentrial SDK when you want the most complete Sentrial experience with minimal mapping:begin()andfinish()sessions- automatic tool and LLM wrappers
convo_idgrouping- production prompt variant routing with
getVariant() - automatic run classification after completion
- existing OTel SDKs or collectors
- GenAI semantic convention spans
- multi-vendor observability pipelines
- gradual migration from another tracing tool
You can use both. For example, call
getVariant() from the Sentrial SDK to route a prompt
variant, then attach the returned assignment ID to your OTel root span as
sentrial.experiment.assignment_id.Data Model Mapping
| Concept | Sentrial SDK | OpenTelemetry |
|---|---|---|
| Run | Session created by begin() or create_session() | One trace becomes one Sentrial session |
| Timeline item | SDK event, tool call, or decision | Each span becomes a Sentrial event |
| Conversation grouping | convo_id / convoId | conversation.id, sentrial.convo_id, thread.id, or trace fallback |
| User grouping | user_id / userId | user.id, enduser.id, or sentrial.user_id |
| Prompt variants | getVariant() returns sticky assignment | Add assignment attributes to spans after routing |
| Classification | Runs are classified after terminal status | Imported traces are classified after ingest |
Recommendation
Start with the Sentrial SDK unless your application already has mature OpenTelemetry traces. Use OTel when you need interoperability, but keep Sentrial attributes on the root span so sessions, conversations, experiments, and classifications line up cleanly.Next Steps
Quickstart
Install the SDK and track your first agent run.
OpenTelemetry
Send OTLP HTTP JSON traces to Sentrial.

