CallID of the most recently started, still-running delegation (anchors the live note).
Display name used for new delegation cards (set by the overlay's AgentName input).
All delegation cards of the session, NEWEST first — the activity rail's list.
ReadonlyChanged$Emits after every state change so views can mark themselves for check.
The merged, chronological thread (captions + delegation cards), oldest first.
Latest ephemeral narration text, or null when none should be shown.
True while at least one delegation is still running.
Subscribes to the session streams. Call once from the owning overlay shell.
Clears all merged state and notifies subscribers (e.g. leaving session review).
Unsubscribes from all session streams. Call from the owning shell's ngOnDestroy.
SESSION REVIEW population path: replaces ALL merged state with a pre-built
HISTORICAL thread (caption turns + done delegation cards, oldest first — see
BuildReviewThreadItems). Resets the live-stream bookkeeping first, so a later
live session starts from a clean merge baseline; delegation cards are indexed by
CallID so the rail's Cards list and ActiveCallId derive normally.
REVIEW→LIVE continuation path: KEEPS the historical thread (and its delegation cards in the rail) and appends a "Resumed live session" RealtimeThreadDividerItem, then resets only the LIVE-merge bookkeeping so the new session's captions and cards append cleanly AFTER the divider:
placedCaptionCount → 0 (the fresh session's caption stream starts empty, so the
start-of-session [] emission is a no-op rather than a reset);ActiveCallId recomputes normally.
SINGLE SOURCE of merged live-session state, owned by the overlay shell (
RealtimeSessionOverlayComponent) and passed via@Input()to BOTH the session thread and the activity rail — so the per-CallID card bookkeeping and subscription logic exists exactly once.Merges FOUR reactive streams from RealtimeSessionService:
Captions$— growing user/assistant caption list → appended to Items.DelegationProgress$— first event perCallIDinserts a working card at the thread tail; later events REPLACE the card immutably (new object + new arrays) so change detection always fires.DelegationResult$— flips the card to Done/Failed with the real result text.DelegationNarration$— the EPHEMERAL spoken progress note (latest only, never accumulated), cleared when no delegation is running anymore.Consumers subscribe to Changed$ and
markForCheck(); all exposed collections are replaced (never mutated) on change.