Repository navigation
Conversation
…letions Some OpenAI-compatible providers repeat "name": "" on every streamed tool-call argument chunk. The parser overwrote the real tool name with that empty string, causing "Tool not found" and a provider HTTP 400 rejection on replay. Only non-empty names update the builder now (matching the Responses builder guard). Adds a regression test.
alejandro-ao
previously approved these changes
Oct 23, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Some OpenAI-compatible providers repeat
"name": ""on every streamedtool-call argument chunk instead of only sending the tool name on the
first chunk. The Chat Completions stream parser let that empty string
overwrite the tool name that had already been parsed, so Tau tried to run
an unnamed tool:
Tool not foundprovider with HTTP 400, ending the session
Fix
_ToolCallBuilder.add_deltanow only updates the tool name for non-emptystrings, matching the guard already present in
_ResponsesToolCallBuilder.The name from the first chunk is preserved when later chunks repeat
"name": "".Tests
test_openai_compatible_provider_keeps_tool_name_when_later_chunks_send_empty_namein
tests/test_tau_ai.py; the regression test streams later chunks withempty names and asserts the parsed tool call keeps its original name.
uv run pytest tests/test_tau_ai.py— 89 passeduv run ruff check .— passeduv run ruff format --check .— passed