Open
Conversation
fbac3ea to
3a8764c
Compare
jacobsimionato
approved these changes
Mar 24, 2026
| const lines = buffer.split('\n\n'); | ||
| buffer = lines.pop() || ''; | ||
|
|
||
| for (const line of lines) { |
Collaborator
There was a problem hiding this comment.
This seems like a reasonable amount of boilerplate. It seems like one of the issues is that this client needs to speak "A2A" to an A2A server, but it isn't using the client library for A2A, so there's quite a lot of manual request handling and stream processing. I was hoping that on the client side it should be quite simple to just take A2UI data chunks and propagate them to the message processor. All the heavy stream processing has already been accomplished on the server side.
I filed #966 with some ideas on how to refactor this, but I think it makes sense to submit all your changes seeing as they work, and then we can look at refactoring to reduce boilerplate. WDYT?
By default, the Angular client uses the non-streaming API to communicate with the agent. To enable streaming, set the `ENABLE_STREAMIING` env var to `true. ```bash export ENABLE_STREAMING=true npm start -- restaurant ```
3a8764c to
8b7ebd0
Compare
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.
Description
Add streaming support for the restaurant finder sample.
This depends on changes in PR #905.
Demo:
streaming.demo.restaurant.finder.webm
Pre-launch Checklist
If you need help, consider asking for advice on the discussion board.