For the complete documentation index, see llms.txt. This page is also available as Markdown.

Sessions

A Session groups multiple traces that belong to the same logical interaction under a shared session_id. Sessions let you replay entire conversations end-to-end, analyze them as a unit, annotate outcomes, and manage related traces together. You can explore sessions for filtering, cohort analysis, debugging, and evaluation at the conversation level.

In a customer support scenario, each time a user sends a message and receives a response, that exchange generates its own trace. When the user follows up with clarifying questions or the conversation escalates to a different topic, each of those exchanges creates additional traces. The session ties all of these traces together under a single identifier, capturing the full support ticket from the customer's first message to resolution.

The sessionId can be any US-ASCII character string less than 200 characters, if it exceeds it will be dropped.

Why Sessions Matter

LLM-powered applications often span multiple requests. A single user conversation might generate dozens of traces across different turns. Without sessions, these traces appear as disconnected events. Sessions provide the logical grouping needed to:

  • Replay entire conversations from start to finish

  • Analyze multi-turn interactions as a unit

  • Annotate outcomes at the conversation level

  • Compare session-level metrics across cohorts

  • Debug issues that only appear across multiple turns

Click on any session to open the detail view, which displays the complete list of traces in chronological order, session-level scores and annotations, total duration, cost, token usage, and user information.


Creating a Session

To create a session, assign the same session_id to multiple traces. There is no separate "create session" call — the session is automatically created the first time a trace references a given session_id.


Translating Content

Click the translate icon in the session detail header to enable translation mode. Content is not translated all at once, each trace is translated individually when expanded. Click the icon again to revert all content to the original language.


Properties of a Session

Property
Description

Id

Unique session identifier

Created At

Timestamp when the first trace was added to the session

Duration

Total time span from first to last trace in the session

Environment

Deployment context like production, staging, or development

User IDs

End-users associated with traces in this session

Traces

Number of traces grouped under this session

Input/Output Cost

Cost of input/output tokens across all traces in the session

Total Cost

Accumulated cost (input + output) across all traces

Input/Output tokens

Number of input/output tokens consumed across all traces

Total Tokens

Total token count (input + output) across all traces

Usage

Breakdown of token consumption by model

Trace Tags

Aggregated tags from all traces in the session.

Last updated

Was this helpful?