Skip to content

[main] fix: recover tool json without false positives - #145

Merged
Tomlord1122 merged 2 commits into
mainfrom
fix/tool-json-recovery
Sep 13, 2026
Merged

Tomlord1122 merged 2 commits into
mainfrom
fix/tool-json-recovery

Conversation

@Tomlord1122

Copy link
Copy Markdown
Member

Background

A single model step still shares one output budget across assistant text and tool JSON. The previous 2048 default cut off medium job descriptions before the arguments were valid JSON. After that recovery landed, reading a file that mentioned the error marker could also look like a schema failure and skip later tools.

d38c627: New installs and unset maxTokens now default to 4096. Saved settings keep whatever the user already chose.

bb1fa41: Schema recovery now uses an explicit invalid-input flag instead of scanning tool output. Complete JSON objects in the same step still run after two truncated payloads.

New installs and unset maxTokens now allow 4k output per model step so
medium documents are less likely to truncate a write_file or run_command
payload. Existing saved settings are unchanged.

Signed-off-by: Tom Liu (Liu Hsiu-Chi) <0xtomlord1122@gmail.com>
Successful tool output that mentions the error marker no longer opens
the schema circuit. Only flagged unmarshal failures count, and a later
complete JSON object in the same step still runs.

Signed-off-by: Tom Liu (Liu Hsiu-Chi) <0xtomlord1122@gmail.com>
@Tomlord1122
Tomlord1122 merged commit 60c8344 into main Sep 13, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant