fix: accept valid citation deltas in Amazon Bedrock streams (#18250)
## Background Valid Bedrock citation-enabled streams emitted AI_TypeValidationError events instead of accepting the provider's documented citation deltas. ## Root Cause AmazonBedrockStreamSchema omitted citation from its contentBlockDelta union. The live reproduction produced six citation validation errors, and the focused schema-validation regression test failed before the schema change. ## Summary Added citation objects to the Bedrock stream schema, added regression coverage, removed reproduction-only artifacts, and added a patch changeset for @ai-sdk/amazon-bedrock. ## Testing Added a streaming regression test that validates a representative citation delta through AmazonBedrockStreamSchema and asserts that no error part is emitted. ## End-to-end Validation - `pnpm -C examples/ai-functions exec tsx -e '<live Bedrock citation stream>'` — observed six live citation deltas and no type-validation errors. ## Related Issues Fixes #9101 Closes #18243 --------- Co-authored-by: ai-sdk-factory <308175966+ai-sdk-factory@users.noreply.github.com> Co-authored-by: Lars Grammel <205036+lgrammel@users.noreply.github.com> Co-authored-by: kamilKamilson <49162755+kamilKamilson@users.noreply.github.com>
A
ai-sdk-factory[bot] committed
b2eb6085417eaace13aa12da4f061c0aeafa3d85
Parent: ebf0bd5
Committed by GitHub <noreply@github.com>
on 8/27/2026, 10:28:48 PM