LLM tracing and observability conceptual guide
thread_id
Think of a Thread as the entire journey a user takes in a single session. It’s the complete chat with your AI travel buddy, from “Where should I go?” to booking the flight. For the blog post generator, a thread_id
bundles up the whole session – from brainstorming headlines to polishing the final SEO-optimized draft. It groups all the back-and-forth interactions (Traces) for a specific task or conversation.
trace_id
trace_id
, we now generate it for you automatically, and provide no way to pass in your own.trace_id
captures an entire end-to-end generation, no matter how many internal steps (Spans) it takes.
span_id
span_id
, we now generate it for you automatically, and provide no way to pass in your own.span_id
pinpoints a specific action taken by your system or an LLM call.
user_id
Simple but crucial: The User ID identifies the actual end-user interacting with your product. Whether they’re planning trips or writing posts, this user_id
(usually their account ID in your system) links the activity back to a real person, helping you see how different users experience your AI features.
customer_id
Are you building a platform for other companies to create their own LLM apps? That’s where the Customer ID shines. If you’re providing the tools for others (your customers) to build AI assistants for their users, the customer_id
lets you (and them!) track usage and performance per customer account. It’s perfect for offering custom analytics dashboards, showing your customers how their AI implementations are doing.
labels
Think of Labels as flexible tags you can slap onto Traces to organize, filter, and compare anything you want! They’re your secret weapon for slicing and dicing your data.
blogpost_title
or blogpost_keywords
.version:v1.0.0
, then deploy an improved prompt and label new traces version:v1.0.1
.experiment:prompt_a
vs. experiment:prompt_b
.