claude-quickstarts / copilot-kit-ag-ui
CLAUDE.md18k starsChanged 2 months agoMITView on GitHub
A finance assistant chat app wiring a Claude Managed Agent to CopilotKit's self-hosted runtime over the AG-UI protocol. This file is the technical map: architecture, where the code is, design notes, and how to walk a user through setup. Four pieces:
- Reads credentials
Trending
More talk lately.about the whole repository
Who's talking about anthropics/claude-quickstarts
- @github-trending-js.bsky.social“🚀 Skyrocketing! 🚀 (200+ new stars) 📦 anthropics / claude-quickstarts ⭐ 18,532 (+453) 🗒 TypeScript A …”Bluesky · Oct 18, 2026 · 2 likes
- phananhtuan09/ai-agent-workflow“[Feature] runtime-e2e-test: setup mode that detects, proves, and fills project-runtime.md”GitHub · Nov 2, 2026
- MoradDev/skills-unified“Upstream updates to review”GitHub · Nov 1, 2026
- melodic-software/claude-code-plugins“docs(playbooks): re-anchor skill-authoring and fable-5 verification to the claude.dev blog posts”GitHub · Oct 31, 2026
- totalolage/deskohub-site“Run agent task evals against previews”GitHub · Oct 17, 2026
The biggest 5 of 23 mentions linking to the repository that our crawl found. Each line is their own headline.
See all 23
Talked about on GitHub and Bluesky (23 times).
On GitHub · 22
- Nov 2, 2026[Feature] runtime-e2e-test: setup mode that detects, proves, and fills project-runtime.md — phananhtuan09/ai-agent-workflow0 reactions
- Nov 1, 2026Upstream updates to review — MoradDev/skills-unified0 reactions
- Oct 31, 2026docs(playbooks): re-anchor skill-authoring and fable-5 verification to the claude.dev blog posts — melodic-software/claude-code-plugins0 reactions · 4 comments
- Oct 17, 2026Run agent task evals against previews — totalolage/deskohub-site0 reactions · 1 comment
- Sep 25, 2026agent-skills.github.anthropics.claude-quickstarts: init at 0-unstable-2026-08-21 — sudosubin/agents.nix0 reactions
17 more on GitHub
- Sep 23, 2026docs(managed_agents): move the self-hosted sandbox variants to claude-quickstarts — anthropics/claude-cookbooks0 reactions · 2 comments
- Sep 21, 2026docs(managed_agents): move the Linear, road trip planner, and MCP server apps to claude-quickstarts — anthropics/claude-cookbooks0 reactions · 2 comments
- Sep 16, 2026docs(managed_agents): move the Slack and Sentry apps to claude-quickstarts — anthropics/claude-cookbooks0 reactions
- Sep 16, 2026docs(managed_agents): move the Slack and Sentry apps to claude-quickstarts — anthropics/claude-cookbooks0 reactions · 2 comments
- Sep 15, 2026Factory.ai 深度调研报告 — Pines-Cheng/blog0 reactions
- Sep 13, 2026/automations: real product widgets + trademark disclaimer — clancybooher/peak-view-windows0 reactions · 1 comment
- Aug 2, 2026goal-maker/bhag: adopt Anthropic's long-run harness (immutable feature_list.json + append-only progress file + fixed bootstrap drill) — jackneil/claude-jacked0 reactions
- Feb 17, 2026Closing the loop - Infrastructure for Agentic Engineering — schemalabz/opencouncil0 reactions
- Feb 3, 2026[Feature] Add Session Persistence, Security Model, and Progress Tracking (v2.2.0) — jnPiyush/AgentX0 reactions · 4 comments
- Jan 13, 2026feat: Add support for ANTHROPIC_API_KEY authentication — nirmalarya/claude-harness0 reactions
- Jan 2, 2026Meta-Library Architecture: Transform Any AI Workflow Knowledge into Executable FSMs — JulesGosnell/claij0 reactions
- Jan 2, 2026Learn from Anthropic's Long-Running Harness Pattern — JulesGosnell/claij0 reactions
- Jan 1, 2026Does this work with Anthropics new Harness for long running agent strategy? — rubycatco/claude-agent-sdk-ruby0 reactions · 2 comments
- Dec 23, 2025Add a think tool — byronxlg/polyagent0 reactions
- Dec 11, 2025feat: Add Autonomous Claude Code Builder system — krzemienski/shannon-framework0 reactions · 2 comments
- Dec 6, 2025Clone Anthropic computer-use-demo into repository — matheus-rech/comp-use0 reactions · 2 comments
- Nov 10, 2025File Editor Tool — strands-agents/sdk-typescript0 reactions · 7 comments
On Bluesky · 1
- Oct 18, 2026🚀 Skyrocketing! 🚀 (200+ new stars) 📦 anthropics / claude-quickstarts ⭐ 18,532 (+453) 🗒 TypeScript A collection of projects designed to… — @github-trending-js.bsky.social2 likes and reposts · 1 reply
In this repository22 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- managed-agents/assistant-ui/CLAUDE.mdCLAUDE.md
- managed-agents/chat-sdk/CLAUDE.mdCLAUDE.md
- managed-agents/daily-brief/CLAUDE.mdCLAUDE.md
- managed-agents/knowledge-wiki/CLAUDE.mdCLAUDE.md
- managed-agents/linear/CLAUDE.mdCLAUDE.md
- managed-agents/mcp-server-typescript/CLAUDE.mdCLAUDE.md
- managed-agents/roadtrip-planner/CLAUDE.mdCLAUDE.md
- managed-agents/self-hosted-sandboxes/CLAUDE.mdCLAUDE.md
- managed-agents/sentry/CLAUDE.mdCLAUDE.md
- managed-agents/slack/CLAUDE.mdCLAUDE.md
- first-runSkill
- verifySkill
- assistant-uiSkill
- chat-sdkSkill
- verifySkill
- knowledge-wikiSkill
- linearSkill
- mcp-server-typescriptSkill
- roadtrip-plannerSkill
- sentrySkill
- slackSkill
The file
We split this CLAUDE.md into the rules it gives an agent
1 rule. About 0 are common, 1 is distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 54
When the user asks to be walked through setting up this demo, go step by step, run the commands for them where possible, and check each …
≈ “Common” is an estimate: at least 1 in 5 of the 12,729 CLAUDE.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
CLAUDE.md
A finance assistant chat app wiring a Claude Managed Agent to CopilotKit's self-hosted runtime over the AG-UI protocol. This file is the technical map: architecture, where the code is, design notes, and how to walk a user through setup.
Architecture
browser (Vite + React) server (Express) Anthropic
┌────────────────────┐ runtime API ┌─────────────────┐ user.message ┌──────────────────┐
│ CopilotKitProvider │ ────────────▶ │ CopilotSse- │ ─────────────▶ │ Managed Agents │
│ └─ CopilotChat │ │ Runtime │ │ session │
│ │ AG-UI events │ └─ ManagedAgents│ SSE w/ live │ └─ financial- │
│ │ ◀──────────── │ Agent │ ◀───────────── │ assistant │
└────────────────────┘ └─────────────────┘ previews └──────────────────┘Four pieces:
- A Claude Managed Agent. One
financial-assistantagent onclaude-fable-5with the built-in toolset (bash, files, web search), so it can pull current rates and run real calculations in its own workspace. Anthropic hosts the agent loop and the container. Sessions keep the conversation state server-side, so each run only sends the newest user message. - The upstream AG-UI adapter.
@ag-ui/claude-managed-agentsdoes the whole Managed Agents ↔ AG-UI translation: one AG-UI thread per managed session, live text previews via event delta streaming, tool activity asTOOL_CALL_*events, thinking asREASONING_*events, interrupts on disconnect, and a per-turn time cap. This repo contains no bridge code of its own. - CopilotKit for the UI. The adapter's
ManagedAgentsAgentis a plain AG-UIAbstractAgent, registered in a self-hostedCopilotSseRuntimeand rendered with the stockCopilotChatcomponent. No custom chat code. - Generative UI. Four visual tools (payoff timeline, growth projection, budget breakdown, scenario comparison) are passed to the adapter as
backendTools; it registers them on each session, streams every call to the browser asTOOL_CALL_*events, and posts the handler's ack back so the turn keeps flowing. CopilotKit'suseRenderToolmounts an interactive React component inline in the chat, with sliders that recompute the charts client-side.
Where the interesting code is
| File | What it shows |
agents/financial-assistant.md, environments/financial-assistant.yaml | The agent (frontmatter is the configuration, prose is the system prompt) and its container, as files for ant apply |
server/src/resources.ts | loadAgentIds(): the agent (with version) and environment from claude-lock.json, or from ANTHROPIC_ENVIRONMENT_ID/ANTHROPIC_AGENT_ID/ANTHROPIC_AGENT_VERSION when the lockfile is absent |
server/src/index.ts | The whole integration: a ManagedAgentsAgent in a self-hosted CopilotSseRuntime on Express, CORS from ALLOWED_ORIGINS, static serving of web/dist when built |
server/src/vizTools.ts | The generative-UI tool contracts the agent sees, as the adapter's backendTools |
web/src/viz/renderers.tsx | useRenderTool registrations mapping tool calls to React components |
web/src/viz/ | The interactive visuals: SVG charts, sliders, client-side finance math |
web/src/App.tsx | The frontend: CopilotKitProvider + CopilotChat + viz renderers |
Commands
npm install, thenant apply --yes agents environmentsonce (ant 1.30 or later;--yesbecause you have no terminal for its confirmation prompt), thennpm run dev(server on :8787, web on :5173). After editingagents/financial-assistant.md, a bareant apply --yespublishes the new version; restart the server to pin it.npm run buildbuilds the frontend toweb/dist.npm startruns the server without watch and servesweb/distif present.npm run typecheckcovers both workspaces. There are no tests. Verify changes by running the app.
Design notes
package.jsonpins onerxjsversion viaoverridesso the whole workspace shares a single copy: the AG-UI client and the CopilotKit runtime exchange RxJS observables, and two copies in the tree can breakinstanceofchecks.- The visual tools are render-only: their result is the rendering itself, so each
backendToolshandler ignores its input and returns a "rendered to the user" ack. The agent supplies starting numbers, and the sliders recompute everything client-side without another agent turn. - The visual tools live only in
server/src/vizTools.ts—agents/financial-assistant.mddoes not put them on the agent. The adapter registers them on each session as tool overrides (merged with the agent's own toolset), so changing a tool contract never requires re-provisioning. - The adapter also emits
TOOL_CALL_*events for built-in tool use (web_search, bash, file ops). The wildcarduseRenderToolregistration inweb/src/viz/renderers.tsxrenders each as a compact expandable activity row (ToolActivity). - CopilotKit's runtime delivers tool args in version-dependent shapes: a typed object, an object with every number stringified, or one whose nested arrays arrive as JSON strings.
web/src/viz/renderers.tsxnormalizes the structure and parses args through coercing zod schemas before mounting a component — blind-spreadingprops.parametersbreaks silently when the wire format shifts. - The agent's system prompt tells it to call visual tools directly, never from inside repl scripts: a repl-wrapped custom tool call parks the session on the repl call itself, a state the adapter (0.0.1) reads as unanswerable and interrupts. Drop that prompt line once the adapter handles repl suspension.
- The thread-to-session store is the adapter's bounded in-memory default, wrapped in
index.tsonly to log each new session's Console trace URL. A server restart starts fresh sessions, and old ones are not deleted. Fine for a demo, not for production; the adapter accepts a persistentsessionStorewhen it matters.
Walking a user through setup
When the user asks to be walked through setting up this demo, go step by step, run the commands for them where possible, and check each result before moving on:
- Node version.
node --versionmust be 22 or newer. - Credentials. Either
ANTHROPIC_API_KEYis set or anant auth loginprofile exists. The account needs the Managed Agents beta, andclaude-fable-5needs 30-day data retention on the org (not available under zero data retention). - Install.
npm installfrom this directory (it is an npm workspace root). - Provision.
ant apply --yes agents environments. This creates the cloud environment and the agent fromenvironments/andagents/and writes their IDs toclaude-lock.json. Re-running changes nothing until a file changes. It needsant auth loginor an exportedANTHROPIC_API_KEY; it does not read.env. If it printsrefusing to apply, a resource was changed or archived in the Console: show the user the reason before reaching for--force. - Run.
npm run dev, then open http://localhost:5173 and suggest a first prompt, for example: "If I invest $500/month at a 7% annual return, what will I have in 20 years?" Point out the Console trace URL the server logs per session.
Common failures:
No agent configuredat server boot:ant apply agents environmentshas not run in this directory (noclaude-lock.jsonhere), and the threeANTHROPIC_*ID env vars are not set.- 403/404 from
ant apply: the org lacks Managed Agents beta access, or the model is unavailable under the org's data retention policy. A 409 on the environment meansquickstart-copilot-kit-financial-assistant-envalready exists in the workspace: changenameinenvironments/financial-assistant.yaml. instanceoferrors mentioning Observable: duplicaterxjscopies. Reinstall from the workspace root so theoverridespin applies.- Port conflicts: set
PORTfor the server, and in dev also update the proxy target inweb/vite.config.ts, which points at :8787. Vite picks the next free port on its own, but then the printed URL changes. - Chat errors in the browser with a healthy web server: check the server logs on :8787. The Vite dev proxy forwards
/api/copilotkitthere.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

