Skip to content

Support emitting session.id on LLM spans in Envoy AI Gateway’s OpenTelemetry export for Phoenix session grouping #1221

@using-system

Description

@using-system

Hello,

Is session.id support for trace OpenTelemetry export is already available behind a flag or in a newer build ? (https://opentelemetry.io/docs/specs/semconv/general/session/)

Or it's possible to include the session.id semantic attribute
on LLM-related spans emitted by Envoy AI Gateway’s OpenTelemetry exporter, so Arize Phoenix can interpret and group traces by session in its “Session” tab.

Proposed implementation sketch

Accept a configurable source for session identity (priority order), for example: HTTP header (e.g., x-session-id)
OR
Get it from BaggageItem key "session.id" if exists on the current span (https://opentelemetry.io/docs/specs/otel/baggage/api/) ?

Many thanks.

Matthieu

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions