BedrockGuardrailConfig
Defined in: src/models/bedrock.ts:212
Configuration for Bedrock guardrails.
https://docs.aws.amazon.com/bedrock/latest/userguide/guardrails.html
Properties
Section titled “Properties”guardrailIdentifier
Section titled “guardrailIdentifier”guardrailIdentifier: string;Defined in: src/models/bedrock.ts:214
Guardrail identifier
guardrailVersion
Section titled “guardrailVersion”guardrailVersion: string;Defined in: src/models/bedrock.ts:217
Guardrail version (e.g., “1”, “DRAFT”)
trace?
Section titled “trace?”trace?: "enabled" | "disabled" | "enabled_full";Defined in: src/models/bedrock.ts:220
Trace mode for evaluation.
Default Value
Section titled “Default Value”'enabled'streamProcessingMode?
Section titled “streamProcessingMode?”streamProcessingMode?: "sync" | "async";Defined in: src/models/bedrock.ts:223
Stream processing mode
redaction?
Section titled “redaction?”redaction?: BedrockGuardrailRedactionConfig;Defined in: src/models/bedrock.ts:226
Redaction behavior when content is blocked
guardLatestUserMessage?
Section titled “guardLatestUserMessage?”guardLatestUserMessage?: boolean;Defined in: src/models/bedrock.ts:240
Only evaluate the latest user message with guardrails. When true, wraps the latest user message’s text/image content in guardContent blocks. This can improve performance and reduce costs in multi-turn conversations.
Remarks
Section titled “Remarks”The implementation finds the last user message containing text or image content (not just the last message), ensuring correct behavior during tool execution cycles where toolResult messages may follow the user’s actual input.
Default Value
Section titled “Default Value”false