Files
next-ai-draw-io/app
dayuan.jiang d48fba304c fix: filter out messages with empty content arrays for Bedrock API
The convertToModelMessages function from AI SDK can produce messages with
empty content arrays when assistant messages have only tool call parts or
when tool results aren't properly converted. Bedrock API rejects these with
400 errors. This fix filters out invalid messages before sending to the API.
2025-12-01 00:59:50 +09:00
..