Module timing

Module timing 

Source
Expand description

Voice timing per stage: how the conversation sounds while a step is active.

A flow decides what may happen. A VoiceTiming decides the pacing:

  • how long to wait out the user’s silence before asking again;
  • when to cue a filler while a tool runs;
  • whether the user can talk over the model;
  • how long a pause must last before the user’s turn is over;
  • whether steering context goes out at once or rides the user’s next message.

Timings attach to steps on the FlowStack. Whenever the active step changes, the stack publishes the merged timing of the active steps to VOICE_TIMING_KEY in state, and the runtime reads it there:

SettingApplied by
reprompt_after_msthe control lane: after that much user silence, it sends the reprompt and emits LiveEvent::Reprompted
filler_after_mstool dispatch: a call still running after that long emits LiveEvent::FillerCue for the app to play an earcon or line
interruptible: falseLiveHandle::send_audio: while the model speaks, mic audio is replaced by silence, so neither VAD can cut the model off
end_of_speech_msLiveHandle::send_audio: the turn-commit end-of-turn hold, under client activity authority. The server’s VAD is fixed at setup, so with server authority this has no effect.
context_deliverythe turn lifecycle: overrides the session’s context delivery for this stage

Everything here is serializable, so a ConversationSpec carries it and a simulator can inspect it.

Structs§

VoiceTiming
Voice pacing for one stage. Every field is optional; an unset field leaves the session’s own behaviour alone.

Constants§

DEFAULT_REPROMPT
The reprompt sent when a stage sets reprompt_after_ms but no text.
VOICE_TIMING_KEY
The state key the active stage’s merged timing is published under.