Skip to content

GuardrailResult

What a guardrail decided about the text it was given.

Defined in: src/core/types/guardrails.ts:98

What a guardrail decided about the text it was given.

Remarks

Returning undefined (or nothing) is equivalent to {} — the text passes through unchanged.

Properties

PropertyTypeDescriptionDefined in
block?booleanSuppress the text instead of speaking it. Remarks At the 'final' stage nothing is synthesized at all. At the 'chunk' stage the current segment and every later segment of the same utterance are suppressed — text already handed to the TTS provider cannot be recalled. Use mode: 'buffered' when a block must be absolute.src/core/types/guardrails.ts:117
metadata?Record<string, unknown>Arbitrary detail (matched categories, scores) surfaced on the same events.src/core/types/guardrails.ts:123
reason?stringHuman-readable explanation, surfaced on guardrail.applied / guardrail.blocked.src/core/types/guardrails.ts:120
text?stringReplacement text to pass downstream. Remarks Omit to keep the input unchanged. Set to '' to drop this text silently without blocking the rest of the utterance.src/core/types/guardrails.ts:106

© 2026 CompositeVoice. All rights reserved.

Font size
Contrast
Motion
Transparency