Class ExecutionContext
Ambient execution context that flows through all operations via AsyncLocal<T>. Carries W3C trace IDs, session IDs, and turn metadata for end-to-end traceability.
public sealed class ExecutionContext
- Inheritance
-
ExecutionContext
- Inherited Members
Properties
Empty
Sentinel empty context.
public static ExecutionContext Empty { get; }
Property Value
ParentAgentId
Parent agent ID for multi-agent tracing.
public string? ParentAgentId { get; set; }
Property Value
ParentSpanId
Parent span ID for hierarchical tracing.
public string? ParentSpanId { get; set; }
Property Value
SessionId
Current session ID.
public string? SessionId { get; init; }
Property Value
SpanId
Current span ID (16 hex chars).
public string SpanId { get; set; }
Property Value
Timeline
The execution timeline recording all operations in this turn.
public ExecutionTimeline Timeline { get; }
Property Value
TraceId
W3C trace ID (32 hex chars).
public string TraceId { get; init; }
Property Value
TurnIndex
Current turn index.
public int TurnIndex { get; init; }