pub struct AgentSession {
pub session_id: Uuid,
pub stream_id: StreamId,
pub spawned_by: Option<SpawnContext>,
pub start_time: DateTime<Utc>,
pub end_time: Option<DateTime<Utc>>,
pub turns: Vec<AgentTurn>,
pub stats: SessionStats,
}Expand description
Complete agent conversation session assembled from normalized events.
Represents a full conversation timeline with the agent, containing all user interactions (turns) and their corresponding agent responses. The session is the highest-level construct for analyzing agent behavior.
Fields§
§session_id: UuidUnique session identifier.
stream_id: StreamIdStream identifier for multi-stream sessions. Indicates whether this is the main conversation, a sidechain, or a subagent.
spawned_by: Option<SpawnContext>For sidechain sessions: context about where this was spawned from in the parent session. None for main stream sessions or sidechains without identifiable parent context.
start_time: DateTime<Utc>When the session started (first event timestamp).
end_time: Option<DateTime<Utc>>When the session ended (last event timestamp), if completed.
turns: Vec<AgentTurn>All user-initiated turns in chronological order.
stats: SessionStatsAggregated session statistics.
Trait Implementations§
Source§impl Clone for AgentSession
impl Clone for AgentSession
Source§fn clone(&self) -> AgentSession
fn clone(&self) -> AgentSession
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more