Enum LiveEvent
pub enum LiveEvent {
Show 21 variants
Audio(Bytes),
TextDelta(String),
TextComplete(String),
InputTranscript {
text: String,
is_final: bool,
},
OutputTranscript {
text: String,
is_final: bool,
},
Thought(String),
VadStart,
VadEnd,
Extraction {
name: String,
value: Value,
},
ExtractionError {
name: String,
error: String,
},
StatePromotion {
extractor: String,
field: String,
state_key: String,
accepted: bool,
reason: String,
value: Value,
},
PhaseTransition {
from: String,
to: String,
reason: String,
},
ToolExecution {
name: String,
args: Value,
result: Value,
},
TurnComplete,
Interrupted,
Connected,
Disconnected {
reason: Option<String>,
},
Error(String),
GoAway {
time_left: Duration,
},
Telemetry(Value),
TurnMetrics {
turn: u32,
latency_ms: u32,
prompt_tokens: u32,
response_tokens: u32,
},
}Expand description
Semantic events emitted by the Live session processor.
The L1 equivalent of L0’s SessionEvent.
L0 events are wire-level; LiveEvents are semantic (extractions completed,
phases transitioned, tools executed).
Subscribe via LiveHandle::events().
Multiple independent subscribers supported. Zero-cost when no subscribers
exist (broadcast::send with 0 receivers is a no-op).
Variants§
Audio(Bytes)
Raw PCM audio from model. Uses Bytes (refcounted) — clone is
a pointer increment (~2ns), not a deep copy.
TextDelta(String)
Incremental text token from model.
TextComplete(String)
Complete text response (all deltas concatenated).
InputTranscript
User speech transcription.
Fields
OutputTranscript
Model speech transcription.
Fields
Thought(String)
Model reasoning/thinking content.
VadStart
Voice activity detected — user started speaking.
VadEnd
Voice activity ended — user stopped speaking.
Extraction
Extraction completed. Emitted for both the top-level result AND each flattened key (e.g., “order.items”, “order.phase”).
Fields
ExtractionError
Extraction failed.
Fields
StatePromotion
A raw extraction field was considered for promotion into authoritative state.
Fields
PhaseTransition
Phase machine transitioned.
Fields
ToolExecution
Tool dispatched and result obtained.
Fields
TurnComplete
Model completed a conversational turn.
Interrupted
Model output interrupted by user speech.
Connected
Session connected to Gemini.
Disconnected
Session disconnected.
Error(String)
Unrecoverable error.
GoAway
Server requesting session wind-down.
Telemetry(Value)
Aggregated session telemetry snapshot.
TurnMetrics
Per-turn latency and token metrics.