mirror of
https://github.com/CopilotKit/CopilotKit.git
synced 2026-09-14 16:26:20 +08:00
5693a60625
Adds /a2ui-catalog page and a runtime endpoint with NO a2ui config, so A2UI switches on purely from the provider's a2ui.catalog (the #5774 path). Also fixes DemoButtonAgent, which never actually rendered: it emitted the wrong activity content key (operations -> a2ui_operations) and a non-canonical operation/component format. Rewritten to the A2UI v0.9 wire format (createSurface/updateComponents, flat components, root id "root") so the surface paints and the Confirm round-trip works.
Vue Demo (Nuxt)
Nuxt SSR demo for @copilotkit/vue with strict parity intent against the React demo.
Parity policy
- Canonical reference:
examples/v2/react/demo. - Match React route set, endpoint contracts, and interaction semantics before adding anything else.
- Mirror React page/file scaffolding as closely as Nuxt allows so route-level diffs stay easy to track.
- No Vue-only workflows or features in this app.
- Temporary gaps are allowed only when Vue package primitives are still being ported.
Scaffolding rules
- Keep route ownership in
pages/*.vue, mirroring React's page-level structure. - Avoid shared wrapper components unless React has an equivalent abstraction.
- When a React primitive is missing in Vue (for example sidebar/popup containers), keep the page scaffold explicit and temporary.
Current status
- App and server endpoint scaffolding are in place.
- Route skeletons are present for:
//single/mcp-apps/sidebar/popup/a2ui-demo(A2UI confirm-button route, parity with React)
- Endpoint routes are present for:
GET/POST /api/copilotkit/**POST /api/copilotkit-singleGET/POST /api/copilotkit-mcp/**
Local setup
- Add required env vars in
.env(same as React demo), for example:
OPENAI_API_KEY=sk-...
- Install deps from repo root:
pnpm install
- Start the demo:
pnpm -C examples/v2/vue/demo dev