mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[PR #1314] [CLOSED] serve: keep unfinished tool calls visible as content #3375
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#3375
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/1314
Author: @Arthur031221
Created: 10/7/2026
Status: ❌ Closed
Base:
main← Head:serve-unfinished-call-text-20261007-reply3📝 Commits (1)
53890f9serve: keep unfinished tool calls visible as content📊 Changes
4 files changed (+105 additions, -4 deletions)
View changed files
📝
serve/frontend.py(+4 -2)📝
serve/responses.py(+2 -0)📝
serve/test_responses.py(+43 -0)📝
serve/test_server.py(+56 -2)📄 Description
Replaces #572 after the history cleanup. The original commit was cherry-picked onto the new main, with a follow-up for the Responses API.
When generation ends partway through an announced tool call, its buffered text is discarded. Return that text as content so clients can see the truncated call. Keep its streamed arguments incomplete. The Responses adapter also keeps function and custom calls marked incomplete when returning this text.
Added parser and HTTP regression tests for natural EOF and token limits.
python -m unittest serve.test_server.UnfinishedToolCall serve.test_responses.ToolRoundTrip -qpasses.I used Claude/Codex to assist with preparing, checking and double-checking this change.
Co-authored-by: beatcollector 179996382+beatcollector@users.noreply.github.com
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.