Guardrails supports Asynchronous and Synchronous streaming that determine how guardrails are applied to the model response. This feature is currently not supported by the Bedrock classes. Feature is highlighted here in the Bedrock documentation and requires amazon-bedrock-guardrailConfig to be passed in the API call while using streaming and using InvokeModelWithResponseStream.
Guardrails supports Asynchronous and Synchronous streaming that determine how guardrails are applied to the model response. This feature is currently not supported by the Bedrock classes. Feature is highlighted here in the Bedrock documentation and requires
amazon-bedrock-guardrailConfig
to be passed in the API call while using streaming and usingInvokeModelWithResponseStream
.boto3 supports this in the invoke_model_with_response_stream method as a part of the
body
.