Skip to main content

Module host_state

Module host_state 

Source
Expand description

Host session state the observe hook records for the rest of the engine.

The observe hook (hook_handlers::observe) learns which model and which transcript the host is running from its payloads and persists them in the data dir; the context radar, ledger, telemetry and conversation reader load them back. Both directions live here so the file formats have one owner and engine readers do not depend on the hook layer.

Functions§

load_active_transcript
load_detected_model
The model the host last reported, with its context window. None when nothing was recorded or the record is older than two hours.
persist_detected_model
Persist the host’s current model (skips background models) to detected_model.json.
persist_transcript_path
Persist the host’s active transcript path and session identity to active_transcript.json.