Repository navigation
Conversation
Signed-off-by: ump45nose <52391318+ump45nose@users.noreply.github.com>
ump45nose
force-pushed
the
fix_responses_sse_fragment_usage
branch
from
August 11, 2026 18:11
a655487 to
5320d3b
Compare
ump45nose
marked this pull request as ready for review
August 12, 2026 06:57
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.
Summary
response.completedfieldProblem
The existing merger starts buffering only after it sees
response.completedwithoutusage. Large Responses API events can placeresponse.completedin the final transport fragment, after the model and usage data have already arrived in incomplete fragments. Those earlier fragments are discarded, so token extraction either returns zero or reads a nested tool schema as the modelFix
The merger now retains an incomplete JSON object from its opening brace and appends later transport fragments until
json.Validconfirms a complete event. Complete JSON events and non-JSON chunks continue through immediatelyAddresses higress-group/higress#4424
Validation
Before the fix at
d677f6c, the focused regression failed with an empty model and zero usageAfter
5320d3b:Higress will still need to consume a wasm-go revision containing this change