Skip to content

a2ui generative-UI surfaces don't render over the AG-UI transport #616

Description

@blove

Summary

In examples/ag-ui (the standalone ag-ui chat example), a2ui / generative-UI surfaces do not render over the AG-UI transport. The chat message/streaming/markdown/error paths all work over ag-ui (8/9 e2e specs pass), but the a2ui surface does not.

Reproduction

examples/ag-ui/angular/e2e/a2ui-single-bubble.spec.ts (currently test.fixme):

  • Prompt: "Demo: render a feedback form"
  • Expected: an <a2ui-surface> rendered in a single assistant bubble.
  • Actual: the render_a2ui_surface tool call is surfaced as a tool-call chip ("render_a2ui_surface Completed") — it never becomes an <a2ui-surface>.

The same graph + same aimock fixtures render the surface correctly over the LangGraph transport (examples/chat), so the graph emits the a2ui data correctly; the gap is in how the chat a2ui render path consumes it over ag-ui.

What we already did

Hypotheses to investigate (one or more)

  1. tool-views registry interception (feat(ag-ui): tool views — render frontend components for tool calls via the views registry #600/feat(cockpit): ag-ui/json-render — AG-UI shared-state generative UI #608): the new "ag-ui tool views" feature renders tool calls as components via a views registry. render_a2ui_surface may be caught as a generic tool-view chip, pre-empting the a2ui surface path.
  2. wrapped-content emission: the chat a2ui "wrapped-content" classifier (libs/chat/.../content-classifier.ts, the ---a2ui_JSON--- path) expects the final surface in the assistant message content; over ag-ui that wrapper may not be produced.
  3. partial-args bridge engagement: the live a2ui-partial custom-event path (now wired via customEvents) may not fire / reconstruct the surface over the uvicorn ag-ui-langgraph stream.

Scope

Likely a focused fix in libs/chat (a2ui render path) and/or libs/ag-ui, not an examples/ag-ui tweak. When fixed, flip test.fixmetest in a2ui-single-bubble.spec.ts.

Found during the examples/ag-ui Part 2b e2e port. Spec/design: docs/superpowers/specs/2026-06-06-examples-ag-ui-standalone-design.md.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions