refactor: extract stream parsing into its own protocol module - #14
Merged
TheGreatAxios merged 1 commit intoSep 27, 2026
Conversation
TheGreatAxios
commented
Sep 25, 2026
TheGreatAxios
left a comment
Contributor
Author
There was a problem hiding this comment.
Reviewed the full diff against #13: event schemas, stream/JSON parsing and the block indexer move verbatim; responses.ts keeps only quirks, header extractors and wiring. Public exports from src/index.ts are unchanged. Check and build pass locally.
TheGreatAxios
force-pushed
the
cl-9317-openai-responses-extract-stream-parsing-into
branch
from
September 25, 2026 06:01
3139a49 to
bce7a6e
Compare
Contributor
Author
|
Independent review findings addressed and force-pushed: commit message reworded. check passes. |
TheGreatAxios
force-pushed
the
cl-9317-openai-responses-extract-stream-parsing-into
branch
2 times, most recently
from
September 25, 2026 22:48
5bbfe2c to
445d930
Compare
Moves the event schemas, SSE streaming parse, non-streaming JSON parse, block indexing and terminal-event detection out of the adapter module, which now holds only the quirks resolver, header extractors and the factory wiring body and iterator together. No behavior change.
TheGreatAxios
force-pushed
the
cl-9317-openai-responses-extract-stream-parsing-into
branch
from
September 26, 2026 01:33
445d930 to
1951d30
Compare
TheGreatAxios
added this pull request to stack #19
September 26, 2026 01:58
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
src/responses.tsintosrc/protocol/iterator.ts.src/responses.tsnow holds the quirks resolver, header extractors and the factory that wires body and iterator together.tagSignaturestays inbody.tsnext to its untag/replay counterpart;iterator.tsimports it.src/index.tsimportsisResponsesStreamTerminalfrom its new location; the export list is unchanged.Verification
bun run check(typecheck, lint, format:check, test): 39 pass, 2 skip, 0 failbun run buildemitsdist/protocol/iterator.jsCloses CL-9317