Repository navigation
·
92 commits
to main
since this release
- BREAKING CHANGE:
GenAIFileResolveris removed, along with the
FileResolverit extended ina2ui-agent-sdk.
#3731 - BREAKING CHANGE:
SendA2uiToClientToolset(a2ui_enabled, a2ui_processor)
takes the request'sA2uiRequestProcessor, or anA2uiProcessorProvider
that returns it per context, instead of catalogs and examples. The processor
holds the catalogs, the example turns, the inference format and, for a canvas
agent, the boundRendererState.A2uiCatalogsProviderand
A2uiExamplesProviderare removed; markdown examples are no longer accepted,
so pass example turns toA2uiGeneratororA2uiRequestProcessor. To
migrate, putgenerator.create_processor(capabilities)in an
A2uiProcessorStoreand passA2uiProcessorStore.getas the
provider. A canvas agent binds itsRendererStateto the processor it puts
there.
#3299 - BREAKING CHANGE: The tool reads its argument, renamed from
a2ui_jsonto
a2ui_payload, in the processor's inference format (Express by default)
instead of always reading JSON. It compiles the payload with the format's
parser, no longer withparse_and_fix, validates it against the processor's
bound state or, without one, withvalidate_payload, and still returns A2UI
JSON messages for the part converter. The prompt it adds comes from the
format's prompt generator, and it skips each section (rules, catalogs,
examples) that the agent's system instruction already holds, such as when the
instruction includesprocessor.prompt_snippet.
#3299 - BREAKING CHANGE:
A2uiPartConvertertakes the processor, plus the
keyword argumentsbypass_tool_checkandfallback_text, instead of
catalogs,parser,versionandstate. It reads text-based A2UI with the
processor's parser and checks it against the processor's bound state, as a
response that shows new UI when there is none, so a response that updates a
surface it does not create is then rejected and logged. Each part is labeled
with its message's protocol version.
#3299 - BREAKING CHANGE:
A2uiEventConvertertakes the request's processor, or
a provider that returns it or None, in the required keyword argument
a2ui_processor, instead of reading catalogs from session state. Its
catalogs_keyargument and thesystem:a2ui_catalogskey are removed. When
the processor's format can stream, it opens oneResponseStreamper
response, feeds it each partial ADK event, and closes it on the final event.
A response is keyed by its invocation and its event's branch or author, so
the sub-agents of aParallelAgentdon't share a stream. A stream that gets
no event forstream_idle_timeoutseconds (600 by default), as when a run is
cancelled, is dropped.
#3299 A2uiProcessorStorekeeps each session's request processor in memory, since
ADK's persistent session services save state as JSON and can't hold one. Its
getandis_enabledmethods are providers forSendA2uiToClientToolset
andA2uiEventConverter.
#3299SendA2uiToClientToolsetandA2uiEventConverterlog a warning when they
get one processor for every request with aRendererStatebound to it,
since every conversation would share that state.
#3299A2uiEventConverternow streams responses in the defaultExpressFormat
incrementally as statements and progressive strings arrive, rather than waiting
for the closing</a2ui>tag.
#3712- Tool and parse errors, which may quote the A2UI payload, are logged by type
at warning level and in full only at debug level.
#3299 - Add
A2uiInstruction, an ADK instruction provider for an agent that writes
A2UI in its text response. It appends the processor'sprompt_snippetto
the agent's own instruction. ADK reads{name}session state templates out
of a string instruction, and the A2UI prompt holds braces that are not state
keys, such as the${expression}in the basic catalog, so a string
instruction failed withKeyError: "Context variable not found: 'expression'."
underadk runandadk web. As a provider,A2uiInstructionis used as
it is, while the agent's own instruction keeps its templates.
#3763 SendA2uiToClientToolsetno longer adds the prompt's rules and catalog
schemas a second time when the system instruction already holds the
processor's wholeprompt_snippetin the Direct JSON format, whose snippet
lays the schemas out in one block rather than per section.
#3763
Published to PyPI: a2ui-adk 0.2.0
pip install a2ui-adk==0.2.0