svelte-a2ui — a Svelte 5 renderer for A2UI #2291
ChaliceForAuri
started this conversation in
Show and tell
Replies: 1 comment
|
Update: the "custom catalogs are where I'm heading next" line above is now real — auri ships agent-facing catalogs (ops dashboards, approvals, charts) as contract + prompt-pack + Svelte implementation. The playground replays unedited GPT-5.6 emissions into live surfaces — a nice demo of what the protocol looks like when a model speaks a richer vocabulary cold. |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
svelte-a2ui — a Svelte 5 renderer for A2UI
Hi all — the roadmap has listed "Svelte/Kit — Community interest" for a while, so I built it: svelte-a2ui, a Svelte 5 renderer for A2UI.
Live demo (30 seconds, watch it stream): https://chaliceforauri.github.io/a2ui-svelte/
GitHub: https://github.com/ChaliceForAuri/a2ui-svelte · npm:
npm install svelte-a2uiThe whole integration is one component:
A few things I tried to get right:
reduce(state, message) → { state, outbound }) with structural sharing; the client holds it in$state.rawand every node reads its spec through$derived— so a data-model patch re-renders only the components it touched. The protocol layer has zero Svelte imports and runs its 83 tests onnode --testwith no build step.createSurface, null-deletes,a2uiRendererDataModel, capability advertisement on every outbound message), all 18 Basic Catalog components with v0.9/v1.0 property names, the full 59-name Icon enum +{svgPath}, and a test that replays the spec's owncontact_form_example.jsonlend to end.on*keys and function values stripped unconditionally, prototype-pollution refusal on JSON Pointer writes, escape-then-markup for Text markdown, bounded recursion on both rendering and expression evaluation,callableFromenforced for remote calls.application/a2ui+jsonDataParts with metadata lifting), and AG-UI activities including the middleware'sa2ui-surfacetype. A transport is a 4-method interface — the demo's static build runs on a ~25-line replay transport.Listing PR: #2290. Feedback very welcome — especially from anyone running A2UI over A2A or AG-UI in production, since I'd love to validate the bindings against more real backends. Custom catalogs are where I'm heading next.
— Hugo Pretorius
svelte-a2ui-demo.webm
All reactions