end_of_turn message
The speaker finished their turn (end_of_turn): a voice agent may answer.
Delivery
Always on the WebSocket when its option is on; never to the callback.
Fields
-
type"end_of_turn" required -
session_idstring required -
dataobject required6 fields
-
channelinteger required -
probabilitynumber requiredProbability that the speaker finished.
-
reasonstring requiredmodel: the end-of-turn probability crossedthreshold;timeout: the silence reachedstop_s.one of:
model,timeout -
endnumber requiredWhen the turn ended, in seconds.
-
speech_durationnumber requiredSpeech in the turn, in seconds.
-
textstringWith
end_of_turn.speculation: the text of the turn as the engine saw it when the turn ended, the text to start a speculative LLM call on. Thespeculationmessage compares the final to it. Empty when the engine had nothing to show (no verdict follows). Absent withoutspeculation, and on a session that masks PII (piiin a mode other thantag): read the lastpartialthere.default:
null
-
Example
{ "type": "end_of_turn", "session_id": "string", "data": { "channel": 0, "probability": 0.5, "reason": "model", "end": 0.5, "speech_duration": 0.5, "text": "string" }}