Open Protocols · Agent Infrastructure

AG-UI & A2UI

Two complementary open protocols for the agentic web. AG-UI connects agents to human interfaces via a real-time event stream. A2UI lets agents author rich UI components that users can interact with directly no hand-written JSX required.

AG-UI is HTTP for agents and UIs. A2UI is the component layer agents write.

AG-UI · Key Concepts
AgentCore

An AI process that reasons, decides, and acts across multiple steps not just answering a single question.

UI EventsProtocol

Structured messages emitted in real time: text deltas, tool calls, state updates. Your UI listens and renders.

RunLifecycle

A single end-to-end execution. One run spans many model turns, tool calls, and intermediate states.

Tool CallAction

When an agent invokes a function search, code exec, API call and waits for its result before continuing.

A2UI · Key Concepts
UI ComponentUnit

The atomic deliverable of A2UI. An agent returns a fully-formed UI fragment a card, form, or chart ready to mount.

Component SchemaContract

A typed manifest describing what props a UI component accepts, enabling agents to generate valid, renderable output.

Render TargetContext

The surface where agent-generated components land a chat thread, a dashboard slot, an inbox pane.

Action CallbackInteraction

How users interact with agent-generated UI. Button presses and form submits route back to the agent as new events.

How They Work Together
  1. 01

    User sends a message

    Your frontend posts the message to a backend that starts an agent run.

  2. 02

    Agent emits events

    As it works, the agent streams typed events: text tokens, tool calls, state snapshots.

  3. 03

    UI consumes the stream

    Each event type maps to a UI update no polling, no custom glue.

  4. 04

    Agent emits a UI component via A2UI

    When a response warrants rich UI, the agent returns a typed component payload. The frontend mounts it directly.

  5. 05

    Run completes

    A terminal event signals the end. The UI settles into its finished state.

Protocol Comparison
Aspect
AG-UI
A2UI
Connects
Agent ↔ UI (human in the loop)
Agent → UI component (agent drives layout)
Transport
SSE / HTTP streaming
HTTP / JSON component payloads
Events
Text delta, tool call, state snapshot
Component tree, prop patch, action callback
Auth
Handled by your backend
Inherited from the AG-UI session
Primary goal
Real-time rendering in a frontend
Agent-authored UI fragments users can interact with
Why It Matters

Without shared protocols, every team reinvents the same bridges: custom event formats between agent and UI, bespoke RPC schemes between agents, fragile one-off integrations that break when either side changes.

AG-UI standardises the event contract between an agent and any frontend. A2UI standardises how agents author and deliver UI components that users can interact with. Adopt one or both they compose cleanly.

The result: agents that don't just answer in plain text, but return rich, interactive interfaces charts, forms, summaries built at runtime, not hardcoded in your codebase.