cayu.sessions.interactions
Public Cayu API. Definitions are grouped by their public source module, and definitions from private implementation modules appear on their package’s page; adding a symbol does not move existing links. The import shown at each entry is a supported public namespace. Read the Python API overview and install the required extra.
InteractionStatus
Section titled “InteractionStatus”from cayu.sessions import InteractionStatusBases: StrEnum.
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 |
|---|---|---|
ACTIVE |
class attribute |
'active' |
PAUSED |
class attribute |
'paused' |
COMPLETED |
class attribute |
'completed' |
FAILED |
class attribute |
'failed' |
INTERRUPTED |
class attribute |
'interrupted' |
Release source · Runtime guarantees · Capability guides
InteractionSummaryEvidence
Section titled “InteractionSummaryEvidence”from cayu.sessions import InteractionSummaryEvidenceValidated, durable projection carried by interaction lifecycle events.
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 |
|---|---|---|
model_policy |
dict[str, object] | None |
Field(default=None, exclude_if=lambda value: value is None) |
tool_completion |
ToolCompletionResult | None |
Field(default=None, exclude_if=lambda value: value is None) |
status |
InteractionStatus |
required |
start_event_id |
str |
required |
start_event_sequence |
StrictInt | None |
Field(default=None, ge=1) |
source_transcript_start |
StrictInt | None |
Field(default=None, ge=0) |
source_transcript_end |
StrictInt | None |
Field(default=None, ge=0) |
result_transcript_start |
StrictInt | None |
Field(default=None, ge=0) |
result_transcript_end |
StrictInt | None |
Field(default=None, ge=0) |
started_at |
datetime |
required |
completed_at |
datetime | None |
None |
active_duration_ms |
StrictInt |
Field(default=0, ge=0) |
wall_duration_ms |
StrictInt | None |
Field(default=None, ge=0) |
model_step_count |
StrictInt |
Field(default=0, ge=0) |
tool_call_count |
StrictInt |
Field(default=0, ge=0) |
token_usage |
AggregateUsageMetrics |
Field(default_factory=build_aggregate_usage_metrics) |
provider_names |
list[str] |
Field(default_factory=list) |
models |
list[str] |
Field(default_factory=list) |
pending_action_kind |
str | None |
None |
targeted_tool_grant_count |
StrictInt | None |
Field(default=None, ge=1, le=TARGETED_TOOL_GRANT_MAX_REQUESTS, exclude_if=lambda value: value is None) |
targeted_tool_grant_batch_fingerprint |
str | None |
Field(default=None, pattern='^sha256:[0-9a-f]{64}$', exclude_if=lambda value: value is None) |
queued_interaction_profile_handoff |
dict[str, str | int] | None |
Field(default=None, exclude_if=lambda value: value is None) |
validate_model_policy (method)
Section titled “validate_model_policy (method)”InteractionSummaryEvidence.validate_model_policy(value)validate_token_usage (method)
Section titled “validate_token_usage (method)”InteractionSummaryEvidence.validate_token_usage(value: object) -> AggregateUsageMetricsvalidate_optional_nonblank (method)
Section titled “validate_optional_nonblank (method)”InteractionSummaryEvidence.validate_optional_nonblank(value: str | None, info) -> str | Nonevalidate_names (method)
Section titled “validate_names (method)”InteractionSummaryEvidence.validate_names(value: list[str], info) -> list[str]normalize_timestamp (method)
Section titled “normalize_timestamp (method)”InteractionSummaryEvidence.normalize_timestamp(value: datetime | None, info) -> datetime | Nonevalidate_ranges_and_terminal_time (method)
Section titled “validate_ranges_and_terminal_time (method)”InteractionSummaryEvidence.validate_ranges_and_terminal_time() -> InteractionSummaryEvidence