Skip to main content

Module projection

Module projection 

Source
Expand description

Controller-owned projection of the durable ACP relay stream.

Structs§

ProjectedRelayEvent
ProjectionIndex
Ephemeral lookup state for projecting a relay page. It is deliberately not part of the serialized session: the durable transcript remains canonical, while catch-up avoids rediscovering keyed items and open streams with a full transcript walk for every event.

Functions§

apply_committed_projection_event
Apply a mutation to the actor’s sole in-memory projection after the same mutation and frontier have committed atomically in SQLite. The mutation is consumed so its committed values move into the projection instead of being copied a second time.
apply_committed_projection_event_indexed
canonical_session_from_materialized
imported_materialized_session
Project the relay events a native importer synthesized into the canonical logical session it archives. Importers replay a harness transcript as prompts, turn boundaries, and agent or thought text; the entry building itself is crate::transcript’s, so an imported transcript reads exactly as the same events would in the chat view.
materialized_queued_prompts_from_canonical
Project archived queued commands onto the durable queue shape. Kept apart from the whole-projection build so a caller that only has to restore the queue does not have to rebuild the transcript with it.
materialized_session_from_canonical
materialized_session_from_entries
Convert a transcript projection into the controller’s canonical logical session. The chat view and the native importers both build ChatEntry values first and land here; live relay sessions are projected directly from relay events instead.
plan_proposal_item_id
Stable id of the captured plan proposal created by the relay event at ordinal. The ordinal keys it because the harness-side review id restarts with every harness process, while the ordinal is durable and replay-stable.
project_relay_event
Derive the minimal mutation for exactly the next relay event. This clones only logical items touched by the event; the actor-owned transcript is not copied.
project_relay_event_indexed