cayu.sessions.TerminalSessionEvidence
Part of cayu.sessions.base. Read the Python API overview and install the required extra.
from cayu.sessions import TerminalSessionEvidenceOne exact, bounded store snapshot through a terminal run.
Ordinary terminal-evidence reads remain completed/failed-only. A store may also return this model for an interrupted session through the narrower runner-owned operation, which requires an exact emitted sequence/type match inside the same snapshot.
Bases: BaseModel.
Fields and attributes
Section titled “Fields and attributes”Defaults below are source expressions; Field(...) includes schema/validation settings and default_factory creates a fresh value. Inherited declarations are included. Constructor behavior follows the model or dataclass shown in the bases/decorators.
| Name | Type | Default |
|---|---|---|
session |
Session |
required |
events |
tuple[EventRecord, ...] |
required |
transcript |
tuple[TranscriptRecord, ...] |
required |
terminal_publication_marker |
TerminalPublicationMarker | None |
None |
boundary |
TerminalSessionEvidenceBoundary |
required |
copy_session (method)
Section titled “copy_session (method)”TerminalSessionEvidence.copy_session(value: Session) -> Sessioncopy_events (method)
Section titled “copy_events (method)”TerminalSessionEvidence.copy_events(value) -> tuple[EventRecord, ...]copy_transcript (method)
Section titled “copy_transcript (method)”TerminalSessionEvidence.copy_transcript(value) -> tuple[TranscriptRecord, ...]validate_boundaries (method)
Section titled “validate_boundaries (method)”TerminalSessionEvidence.validate_boundaries() -> TerminalSessionEvidenceterminal_event (property)
Section titled “terminal_event (property)”TerminalSessionEvidence.terminal_event() -> EventRecordReturn the matching terminal event at the snapshot boundary.
lifecycle_events (property)
Section titled “lifecycle_events (property)”TerminalSessionEvidence.lifecycle_events() -> tuple[EventRecord, ...]Return invocation and interaction lifecycle records in durable order.
initial_interaction_id (property)
Section titled “initial_interaction_id (property)”TerminalSessionEvidence.initial_interaction_id() -> str | NoneReturn the first admitted interaction identity, when recorded.