GuardrailMode
When guardrails run relative to TTS streaming.
type GuardrailMode = "streaming" | "buffered";
Defined in: src/core/types/guardrails.ts:215
When guardrails run relative to TTS streaming.
Remarks
'streaming'— filter each segment as the LLM produces it and forward it to Live TTS immediately. Preserves streaming latency; a block can only suppress text not yet spoken.'buffered'— hold the entire response, filter it once, then hand it to TTS. Blocking is absolute, at the cost of waiting for generation to finish before any audio starts. Filtering happens at the'final'stage, so a guardrail restricted to['chunk']never runs in this mode.
Only affects Live (WebSocket) TTS. REST TTS always receives the complete response, so it is filtered at the 'final' stage either way.