btlqql opened a new pull request, #438:
URL: https://github.com/apache/rocketmq-dashboard/pull/438

   ## Summary
   
   - buffer AI chat stream bytes until a complete SSE event is available
   - handle fragmented, coalesced, CRLF, multiline, raw, and end-of-stream 
event data
   - accept both the existing `content` payload and the server stub's `text` 
payload
   - add focused regression coverage for SSE framing and the `[DONE]` sentinel
   
   ## Root cause
   
   `chatStream` split every network chunk on newlines and parsed it 
immediately. `ReadableStream` chunks do not preserve SSE event boundaries, so 
JSON split between chunks was treated as malformed raw text. The client also 
ignored the `text` field emitted by `LlmGatewayStub`.
   
   ## Impact
   
   AI responses are no longer lost or corrupted when an event is split or 
combined by the network, and the bundled backend stub now matches the frontend 
stream consumer.
   
   ## Validation
   
   - `cd web && npm test` — 9 tests passed
   - `cd web && npm run build` — passed
   - `cd web && npm run lint` — 0 errors; 3 pre-existing warnings in unrelated 
files
   - pre-commit ESLint and Prettier checks — passed
   
   Fixes #437
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to