mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
Labels
No labels
needs-format
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Niko1221/Strata#4137
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/Niko1221/Strata/pull/2572
Author: @qiuzan2001
Created: 10/15/2026
Status: ❌ Closed
Base:
main← Head:chief-serve/tool-param-name-attr📝 Commits (1)
5972f0ftool_call_recovery: a parameter written or as one JSON keeps its value (#2451)📊 Changes
4 files changed (+305 additions, -1 deletions)
View changed files
📝
docs/DETAILS.md(+5 -1)📝
serve/frontend.py(+135 -0)📝
serve/server.py(+3 -0)➕
serve/test_param_forms.py(+162 -0)📄 Description
Fixes the recoverable part of #2451 (forms 1-3 of the report), based on the patch and tests @mbaaku posted there
(credited as co-author). Form 4 (no value generated at all) and the
<arg_value>form are left out.What it changes.
parse_tool_callreads only<parameter=NAME>. Coder IQ1_M with a coding agent's 21 toolswrote
<parameter name="command">,<parameter name=command>or a nameless<parameter>holding every argument asJSON; those calls reached the client with empty arguments (19 of 35 broken
Bashcalls in one session on 0.1.44.1).With
"tool_call_recovery": trueand tools declared, a small filter (ParamForms) in front ofOutputParserrewrites those forms into
<parameter=NAME>(the JSON one into one parameter per key), so the streamedtool_argsand the final call agree. Changes from the posted patch, after two reviews:
<function=NAME>tag or a</parameter>), never inside avalue: a file that documents the call format (#210) keeps its text, and prose that mentions
<function=is nottouched;
</function>inside a value is the value's text, asparam_endalready treats it;<parameter name=...is held at most 512 characters;finish()keeps its name and flushes thefilter first; the server logs
[strata] tool_call_recovery: N parameter tag(s) in another form read as <parameter=NAME> (#2451); one paragraph in docs/DETAILS.md ("Tool calls in other forms").What it leaves alone. Everything without the switch (the filter is not created;
feed/finishrun as before),and the template's own form with it (byte-identical through the filter in the reviewer's 20,000-case fuzz). One
ambiguity stays: inside a value,
</parameter>followed by<parameter name="y">reads as the next parameter,because that is exactly what a real call in this form looks like.
How it was checked.
serve/test_param_forms.py(13 tests): the report's raw samples in each form, streamed in 1/3/7-characterpieces and whole, after and inside the thinking; the streamed
tool_argsequal the final arguments; the templateform unchanged; a value that shows the forms (#210) and a value holding
</function>(steps 1-7) kept; proseuntouched; off without the switch; the rewrite count. On
mainmost fail (no filter).regex):serve.test_param_forms,test_tool_name_space,test_parser_track,test_reasoning_rescue,test_reasoning_tools,test_responses,test_server: OK.🤖 Generated with Claude Code
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.