Repository navigation
feat(agui): serialize data and file media sources on outbound - #4297
Merged
jujn merged 5 commits intoNov 21, 2026
Merged
Conversation
Preview approval requiredThis pull request comes from a fork, so Mintlify won't build a preview until someone with write access approves commit |
… into feat/agui-outbound-media-sources
jujn
force-pushed
the
feat/agui-outbound-media-sources
branch
from
November 21, 2026 07:02
f18bd69 to
eaf12ce
Compare
jujn
approved these changes
Nov 21, 2026
5 tasks done
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.
AgentScope-Java Version
2.1.0-SNAPSHOTDescription
The AG-UI protocol defines three source types for media parts —
url,data(inline Base64), andfile(provider-issued handle) — and the inbound direction accepts all three. The outbound path from #4003, however, serialized URL sources only: media blocks carrying aBase64SourceorFileIdSourcewere dropped silently, with no log or fallback. Media sent as inline data or a file handle therefore disappears fromMESSAGES_SNAPSHOThistory on reconnects, refreshes, and session switches.This change maps all three AgentScope source types on the outbound path, mirroring the document handling #3979 established in
toDocumentInputContent.Changes
ImageBlock/AudioBlock/VideoBlockserialize asurl/data/filesources through a sharedtoInputContentSourcemapping; inline Base64 keeps its data and media type, and a file handle keeps its provider.DataBlockkeeps MIME-type routing for URL sources, routes inline data by its declared media type, and carries a provider file handle as a document part — the protocol's generic carrier for opaque data.testConvertBase64MediaBlocksAreSkippedOnOutbound, which asserted the old skip behavior.