Repository navigation
Releases
Swift 0.12.0
- BREAKING CHANGE: Make
EnvironmentValues.a2uiCatalogs,
EnvironmentValues.a2uiDefaultCatalogID, andEnvironmentValues.a2uiSurfaceMetadataread-only
(public internal(set)) inA2UISwiftUI, and removeA2UICatalogsKeyand
A2UIDefaultCatalogIDKeyso catalogs and surface metadata are injected only bySurface.
Recommended migration: pass catalogs toSurface.init(viewModel:catalogs:defaultCatalogID:)or
Surface.makeWithBasicCatalogs(viewModel:), update surface metadata throughSurfaceViewModel
(metadata,setMetadata(_:),setExtension(_:value:),removeExtension(_:)), and read
\.a2uiCatalogs,\.a2uiDefaultCatalogID, and\.a2uiSurfaceMetadatafrom@Environment.
#4195,
#4275 - BREAKING CHANGE:
RegexSubset.analyze,RegexSubset.compileGuarded, and theregex
function inBasicCatalogreject a repetition of a group that can match the empty string in
more than one way, such as(a?){1000}a{1000}or(a{0,2})+b, withNESTED_QUANTIFIER. Such a
pattern madeNSRegularExpressionrun for seconds or longer on a value only a few characters
long. Recommended migration: rewrite the group so each repetition consumes at least one
character, for example(?:ab?){3}instead of(?:a?b?){3}.
#4236,
#4310 - Add optional
instructions(Markdown design guidelines for agents) toCatalogProtocoland
Catalog, with aninstructions:parameter onCatalog.initandCatalog.derive.derive
does not keep the source catalog's instructions, andMessageProcessor.getRendererCapabilities
writes them into v1.0 inline catalogs when set.
#3842,
#4312 - Add an
isUserActivatedparameter (defaultfalse) toMessageProcessor.processMessages(_:),
process(payload:),process(message:), andprocess(messages:). Passtruewhen the payload
is handled within a user gesture so a v1.0callRendererFunctionmay run functions that set
requiresUserActivation, such as a nested call in its arguments.
#4311 - Add
MessageProcessor.addCatalog(_:)to register a catalog after initialization.
createSurfacemessages, renderer function calls, andgetRendererCapabilities(options:)see
the added catalog, while existing surfaces keep their original catalogs; duplicate catalog IDs
throwA2UICatalogError. #3303,
#3304 - Generalize direct
DataBindingproperties toDataBinding<JSONValue>, resolve direct
FunctionCallproperties, and preserve typed resolution for inline dynamic unions in
NodeResolver. #3809 - Report a two-way binding write that the data model rejects, such as writing
/name/firstwhile
/nameis a string, as aDATA_ERRORto the surface'sActionHandlingand the
MessageProcessoroutbound listener instead of dropping it silently. The data model stays
unchanged. #4257 - Draw SVG elliptical arc commands (
Aanda) inSVGPathParser, soIconsvgPathvalues
with arcs render circles and rounded shapes instead of dropping those segments. Arc flags written
without separators (for examplea1 1 0 011 1) are also accepted.
#4260
a2ui-core 0.7.1
- Add
MessageProcessor.add_catalog(catalog), which adds a catalog to a
processor after it is built.createSurfacemessages, renderer function
calls andget_renderer_capabilitiessee the catalog from then on; surfaces
created before the call keep the catalogs they were created with. A catalog
whose ID the processor already holds is rejected withA2uiCatalogError.
MessageProcessor.catalogsis the processor's own list, whichadd_catalog
appends to; the sequence passed to the constructor is not changed
(#3303,
#3304).
Published to PyPI: a2ui-core 0.7.1
pip install a2ui-core==0.7.1a2ui-agent-sdk 0.12.1
DirectJsonParserrejects a number out of the range of a double, such as
1e400, withA2uiParseError, as the Dart SDK does. It used to read it as
inf, whichjson.dumpswrites asInfinity, a token JSON does not have
(#3847).
Published to PyPI: a2ui-agent-sdk 0.12.1
pip install a2ui-agent-sdk==0.12.1A2UI CLI v0.5.0
-
Breaking: Requires
a2ui_core^0.9.0(a2ui_cliexposesa2ui_core
types in its public API). -
Raises the minimum Dart SDK bound from
sdk: ">=3.10.0 <4.0.0"tosdk: ">=3.13.0 <4.0.0"for building from source (compiled CLI binaries are unaffected) (#4305).
Swift 0.11.0
- BREAKING CHANGE: Enforce object-level (
anyOf,additionalProperties: false) and
array-level (minItems,maxItems,prefixItems) JSON Schema constraints on function arguments
containing dynamic bindings inPayloadValidator, validate declaredreturnTypevalues on nested
function calls against the catalog function definition on pre-1.0 surfaces, disallow undeclared
arguments across allBasicCatalogfunctions, and enforce RFC 3986 scheme-prefixed URI syntax on
openUrl.args.url. Recommended migration: remove undeclared function arguments, supply at least
one bound onlengthandnumeric, pass a scheme-prefixed URI toopenUrl.url, and match or
omitreturnTypeon nested function calls.
#4173,
#4187 - BREAKING CHANGE: Gate component
metadataandcatalogIdenvelope handling in
MessageProcessorandPayloadValidatorto v1.0 and later surfaces so pre-1.0 surfaces treat
metadataandcatalogIdas ordinary component properties inComponentModel.properties(with
ComponentModel.metadataremainingnilandComponentModel.catalogIDset to the surface
default catalog). On v1.0 surfaces,MessageProcessor,PayloadValidator,
GraphTopologyValidator,NodeResolver, andNode.explicitAccessibilityAttributesaccept
@catalogId,@metadata,@accessibility, and@checks(ComponentModel.propertiesstores
the accessibility and checks mixins under@accessibilityand@checks), dual-read legacy bare
keys when undeclared by the component schema, validate@metadata.extensionskeys as UAX #31
identifiers, and reject components that specify both@-prefixed and bare forms of the same
mixin. Recommended migration: readmetadataandcatalogIdfromComponentModel.propertieson
pre-1.0 surfaces, and emit@catalogId,@metadata,@accessibility, and@checkson v1.0
components. #4140,
#4037,
#4044 - BREAKING CHANGE: Migrate
A2UIAudioPlayerModelandA2UIVideoPlayerModelin
BasicCatalogSwiftUIfromObservableObjectto@Observable, update
A2UIAudioPlayer.init(node:model:)andA2UIVideo.init(node:model:)to take a direct model
instance, skip redundantAVPlayerseeks duringA2UIAudioPlayerplayback, and adopt
ContentUnavailableViewand an accessibility label on the poster play button inA2UIVideo.
Recommended migration: hold customA2UIAudioPlayerModelorA2UIVideoPlayerModelinstances
with@Stateinstead of@StateObjector@ObservedObject.
#4022 - BREAKING CHANGE: Remove the default
= []argument on
Surface.init(viewModel:catalogs:defaultCatalogID:)so callers explicitly choose a catalog list
(or passcatalogs: []). Recommended migration: passBasicCatalogImplementation.allCatalogs,
useSurface.makeWithBasicCatalogs(viewModel:), or passcatalogs: []explicitly.
#4024 - Add
A2UICardStyle(.automatic,.elevated,.outlined),A2UIButtonStyle(.automatic),
View.a2uiCardStyle(_:),View.a2uiButtonStyle(_:), and
Surface.makeWithBasicCatalogs(viewModel:)inBasicCatalogSwiftUI.
#4024 - Report the component definition ID rather than the synthesized
:indexinstance ID as
sourceComponentIDon actions dispatched from template-expanded components.
#4043 - (v1.0) Inherit the enclosing function's resolved
catalogIdfor catalogless calls inside
FormatStringFunction${...}template expressions (keeping@-prefixed system calls such as
${@index()}catalogless), addDataContext.activeFunctionCatalogIDand
FunctionHandler.resolvedFunctionCatalogID(forCallCatalogID:), and scopeRPCHandler
callRendererFunctionargument and function evaluation to the target catalog.
#4030 - (v1.0) Include
$defs.anyComponentand$defs.anyFunctionunions in inline catalog schemas
emitted byMessageProcessor.getRendererCapabilities(options:)so v1.0 or later inline catalogs
conform tocatalog_definition.json. #4092 - Deprecate
A2UICatalogsKey,A2UIDefaultCatalogIDKey, andA2UIThemeKeyinA2UISwiftUIin
favor ofEnvironmentValues.a2uiCatalogs,EnvironmentValues.a2uiDefaultCatalogID, and
EnvironmentValues.a2uiTheme, and updateBasicCatalogSwiftUIcomponents (A2UIIconand
A2UIChoicePickerDynamic Type scaling, multi-lineTextField(axis: .vertical)forlongText
A2UITextField, and SVG path parsing improvements inSVGPathParser/SVGPathShape).
#4023 - Map
A2UIImagefitvalues (contain,cover,fill,none,scaleDown) to CSS
object-fitsemantics inBasicCatalogSwiftUI:fillstretches to the frame,nonerenders at
intrinsic size without scaling,scaleDownavoids upscaling small images, feature variants size
their frame from the image's aspect ratio without upscaling, andavatarandheadervariants
honor an explicitfitwhile defaulting tocover.
#4097 - (v1.0) Drop
themefromcreateSurfacepayloads inV10VersionAdapterandMessageProcessor
whenValidationConfig.allowUnknownElementsistrueinstead of rejecting the message, and add
allowUnknownElementsoverloads to
VersionAdapter.extractOperations(from:allowUnknownElements:),
VersionAdapter.adaptMessage(_:allowUnknownElements:), and
BaseVersionAdapter.preparePayloadForValidation(_:action:allowUnknownElements:).
#4099 - Send the message of an error thrown by a renderer function in the
rendererFunctionResponse
error, falling back to the generic execution-error text only when that message is empty.
#4105 - Announce visible text changes in
liveregions: a live component or container now announces its
explicitlabelfollowed by the text its subtree reports with the new.a2uiAccessibleText(_:)
modifier (collected throughA2UIAccessibleTextKey).A2UITextreports its text without
Markdown syntax, and custom components that render text can call the modifier too.
#4021
a2ui-core 0.7.0
- BREAKING CHANGE: Enforce basic catalog function argument and return-type validation across
StrictBaseModel,SchemaValidator, andPayloadValidator: rejectstrandboolvalues on pureint/floatfields (such aslength.min,length.max,numeric.min, andnumeric.max), enforceanyOfrequired-branch constraints (SchemaKeywords.required_any_of), enforce RFC 3986 scheme-prefixed URI syntax (^[A-Za-z][A-Za-z0-9+.-]*:\S*$) on"format": "uri"fields (such asopenUrl.args.url), and validate declaredreturnTypevalues on nested function calls against the catalog function definition on pre-1.0 surfaces. Recommended migration: pass numeric values tominandmax, supply at least one bound onlengthandnumeric, pass a scheme-prefixed URI toopenUrl.url, and match or omitreturnTypeon nested function calls (#4173, #4187). - BREAKING CHANGE: (v1_0) Update
ComponentCommonandCheckableschemas,Catalog.validation_schema, andComponentModel.component_treeto emit@catalogId,@metadata,@accessibility, and@checkson v1.0 surfaces (ComponentModel.component_treewrites envelope metadata under@metadata), whilePayloadValidatorandMessageProcessorgate componentmetadataandcatalogIdenvelope handling to v1.0+ surfaces (so pre-1.0 surfaces treat them as ordinary component properties), dual-read legacy barecatalogId,metadata,accessibility, andcheckswhen undeclared as custom properties by the component schema, validate@metadata.extensionskeys as UAX #31 identifiers, rejectnull@catalogId/ legacycatalogId, and reject components specifying both@-prefixed and bare forms of the same mixin (#1376, #3466, #3511, #4012, #4037, #4044). - Resolve component properties that reference
FunctionCalldirectly (includingallOf-constrained branches) inGenericBinderandNodeResolver(#3809). - (v1_0) Accept the
pathkey ofChildListtemplates inGenericBinder(#3809).
Published to PyPI: a2ui-core 0.7.0
pip install a2ui-core==0.7.0a2ui-agent-sdk 0.12.0
- BREAKING CHANGE: (v1_0) Emit
@catalogId,@metadata,@accessibility,
and@checkson v1.0 components acrossExpressCompiler,
AtomCompiler,ElementalCompiler,MacroExpander,RendererState, and the
v1.0 Pydantic builder models (a2ui.builder.v1_0), while keeping Python
builder keyword arguments (catalog_id=,accessibility=,extensions=,
checks=) and v0.9 wire keys unchanged.ExpressDecompiler,
AtomDecompiler, andElementalDecompilerread both@-prefixed and legacy
bare component envelope keys on v1.0 payloads when the component schema does
not declare a custom property with the same bare name
(#1376,
#3403,
#3466,
#3626,
#4012,
#4044). - Add
read_renderer_capabilities(metadata, version)ina2ui.utilsto extract
and validate version-keyed renderer capability dictionaries from transport
metadata (a2uiRendererCapabilitiesin v1.0 anda2uiClientCapabilitiesin
v0.8, v0.9, and v0.9.1).
#4013 - Package dependency updated to require
a2ui-core>=0.7.0,<0.8.0.
#4258
Published to PyPI: a2ui-agent-sdk 0.12.0
pip install a2ui-agent-sdk==0.12.0a2ui-a2a 0.4.0
- Add
renderer_capabilities_from_message(message, version)to read and
validate A2UI renderer capabilities from an inbound A2AMessageacross
message.metadata,DataPart.metadata, and legacyDataPart.data["metadata"].
#4013 - Package dependency updated to require
a2ui-agent-sdk>0.11.0.
#4258
Published to PyPI: a2ui-a2a 0.4.0
pip install a2ui-a2a==0.4.0A2UI CLI v0.4.0
-
Breaking: Requires
a2ui_core^0.8.0(a2ui_cliexposesa2ui_core
types in its public API). -
(v1_0) Filter
@catalogId,@metadata, and@accessibilityfrom component
builder properties inCatalogAnalyzer, detect checkable components from
@checks, and emitserialization_alias="@checks"and
validation_alias=AliasChoices("@checks", "checks")on generated Python v1.0
checkable component builders while preserving custom component properties
namedmetadata,catalogId,accessibility, orchecks
(#3466,
#4012,
#4044). -
Add explicit type annotations to internal local and pattern variables to satisfy the
specify_nonobvious_local_variable_typesanalyzer lint on Dart 3.15+ (#4233).
A2UI CLI v0.3.0
-
Breaking: Requires
a2ui_core^0.7.0(a2ui_cliexposesa2ui_core
types in its public API). -
Added
a2ui lint(LintCommand,lintCatalog,CatalogLintFinding, andLintSeverity) to validate catalog JSON schemas against deterministic protocol rules with JSON Pointer locations, including v1.0 Unicode UAX 31 identifiers, component and function discriminators, the reservedSurfacecomponent name, v1.0requiresUserActivationcaller constraints, and redundantComponentCommonorFunctionCommonwrapping (#3831).