You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[BUG] Bedrock streaming tool calls receive empty arguments ({}) — accumulated input is never folded back at contentBlockStop #7243
Streaming tool calls through the native Bedrock provider hand the tool empty arguments ({}). Non-streaming works.
contentBlockDelta accumulates the tool input JSON fragments, but at contentBlockStop the accumulated string is never parsed back into the tool-call payload, so the call is emitted with empty arguments. Both the sync and async streaming handlers are affected. The non-streaming path already folds the arguments back, which is why only stream=True breaks.
Reproduced on current main (92eb5f91 merged into the branch under test):
# streaming, before fix
assert {} == {'city': 'Paris'}
# same input, non-streaming
{'city': 'Paris'}
Steps to Reproduce
Configure an LLM with a Bedrock model (bedrock/anthropic.claude-...) and stream=True.
Give the agent a tool that takes an argument, e.g. a weather tool with city.
Ask a question that triggers the tool.
The tool receives {}; with stream=False it receives {'city': 'Paris'}.
Expected behavior
Streaming tool calls carry the same arguments as non-streaming ones.
Context
This re-files #6149, which the stale bot auto-closed on 2026-07-20 while PR #6150 (approved 2026-06-23) was still waiting to be merged. With the issue closed, the first-time-contributor check auto-closed the PR today, so the fix had no open issue to attach to. Filing this so the approved PR can be reopened against an open issue. Same root cause family as #4972 / #5415, but on the streaming path.
fold-back + 3 regression tests (sync/async); re-verified on main before this filing
They all patch the same two handlers, so only one is needed. #5739 came first; #6150 is the one that carries regression tests and a maintainer approval. Happy to defer to whichever you prefer — if it's not mine, feel free to close #6150 for good.
Per .github/CONTRIBUTING.md, this needs the llm-generated label — I can't add labels myself, so could a maintainer apply it here (and on #6150)? The PR was approved on 2026-06-23 and is re-verified against current main.
Activity
kimnamu commentedon Sep 3, 2026
Per
.github/CONTRIBUTING.md, this needs thellm-generatedlabel — I can't add labels myself, so could a maintainer apply it here (and on #6150)? The PR was approved on 2026-06-23 and is re-verified against currentmain.linear commentedon Sep 4, 2026
OSS-147