Skip to content

feat(examples/ag-ui): canonical demo toolbar parity (modes + knobs over input.state)#656

Merged
blove merged 10 commits into
mainfrom
worktree-ag-ui-demo-toolbar
Jun 12, 2026
Merged

feat(examples/ag-ui): canonical demo toolbar parity (modes + knobs over input.state)#656
blove merged 10 commits into
mainfrom
worktree-ag-ui-demo-toolbar

Conversation

@blove

@blove blove commented Jun 12, 2026

Copy link
Copy Markdown
Contributor

Summary

Phase 1 of the toolbar-parity + AG-UI capability-audit campaign (spec: docs/superpowers/specs/2026-06-11-ag-ui-demo-toolbar-design.md). The AG-UI example's static header is replaced with the canonical demo toolbar at functional parity.

  • Adapter (libs/ag-ui): submit() now forwards input.state onto the AG-UI run input (RunAgentInput.state) on both the normal and resume paths, with optimistic local state() reflection. 4 new unit tests; 128/128 green. A live spike proved the mechanism end-to-end (state.gen_ui_mode=json-render flipped the graph's tool to generate_json_render_spec).
  • AgUiShell (new): Embed/Popup/Sidebar segmented modes (new router; //embed keeps existing e2e untouched), Model/Effort/Gen-UI/Theme chat-selects with the canonical option lists, dark/light toggle in the toolbar, URL-knob (?model=&effort=&genui=&theme=&scheme=) + localStorage persistence (URL > stored > default), theme reflection onto <html>, and a submit wrapper merging {model, reasoning_effort, gen_ui_mode} into input.state — the same pattern the canonical demo uses. Interrupt panel moved into the shell unchanged.
  • Modes: canonical mode components + welcome-suggestion chips copied (standalone-example rule), agent shared via inject(AgUiShell).agent.
  • E2E: 13/13 (10 existing unchanged + modes / URL-knob / state-merge-smoke). The e2e caught and fixed a real init bug (URL knobs read before router init → now window.location.search).

Trimmed by design (no thread CRUD over AG-UI): threads sidenav, search palette, projects, subagents region.

Phase 2 follows merge: Chrome MCP capability audit of the full matrix (interrupt edit/respond/ignore, reasoning display, json-render, model knob, stop, regenerate…) — gaps get closed in scope per the spec.

Test Plan

  • CI: Library (ag-ui), examples/ag-ui — e2e, ag-ui demo → Vercel green.
  • Deployed demo shows the toolbar; knobs persist; modes switch.

🤖 Generated with Claude Code

blove and others added 8 commits June 11, 2026 14:58
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…ation matrix + gap protocol)

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Merges AgentSubmitInput.state into the AG-UI source agent's state before
each run (both the normal and resume paths), and reflects the patch
optimistically in the local state signal.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Add toolbar.spec.ts with 3 new tests (modes segmented control, effort
URL knob, toolbar submit smoke). Fix AgUiShell.urlKnob() to read from
window.location.search instead of ActivatedRoute/router.url (both
unavailable at bootstrap in a non-routed shell component). Raise
playwright.config.ts test timeout to 60s to cover the interrupt-approval
assertion. All 13 specs pass.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@blove blove enabled auto-merge (squash) June 12, 2026 01:34
@vercel

vercel Bot commented Jun 12, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
threadplane Ready Ready Preview, Comment Jun 12, 2026 2:21am

Request Review

blove and others added 2 commits June 11, 2026 19:07
Semantic merge — #655 landed on the pre-shell app, so its features relocate:
- ItineraryStore provider + router union in app.config.
- Itinerary panel hosted in the shell's new two-column body (toolbar-aware).
- clientTools built once in AgUiShell; all three modes bind <chat [clientTools]>.
- Welcome chips: #655's seven capability prompts presented via the canonical
  two-tier featured + 'More prompts' UI.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Capability gap caught by the toolbar-parity forcing function: only the
<chat> composition exposed [clientTools]; the popup and sidebar compositions
silently dropped it. Add the input + inner-<chat> forward in both, matching
their existing views/modelOptions pass-through pattern.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@blove blove merged commit 9147d70 into main Jun 12, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant