Commit Graph

4543 Commits

Author SHA1 Message Date
Atai Barkai 1695b51bac fix(a2ui-hello-world): patch .d.ts and .d.mts in local-install
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-14 09:06:11 -07:00
Atai Barkai 99e1e1a1eb refactor(a2ui-hello-world): use streamingSurfaces array config
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-14 08:53:28 -07:00
Atai Barkai fed92b61a4 chore(a2ui-hello-world): remove unused streamingThrottleMs from route config
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-14 08:37:33 -07:00
Atai Barkai e2b44a96a5 feat(a2ui-hello-world): add streaming A2UI flight search example
New tool search_flights_streaming: schema is registered on the middleware
config and emitted at TOOL_CALL_START. As the LLM streams flight data
as tool args, the middleware partial-parses and emits dataModelUpdate
progressively — flight cards appear one by one.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-14 00:45:10 -07:00
Atai Barkai 3d4decbee9 fix(a2ui-hello-world): add List wrapper to flight schema for data binding
The Card schema's data paths (/flightNumber, /origin, etc.) need a
List root with dataBinding: /flights to scope each card's data context.
Without it, paths resolve at the root where data lives under /flights/0/.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-13 21:45:29 -07:00
Atai Barkai a57de4fe73 fix(a2ui-hello-world): patch monorepo middleware in local-install, add List to flight schema
local-install now copies locally built a2ui-middleware into the monorepo
node_modules so the runtime resolves the version with a2ui_operations
container support. Flight schema now wraps cards in a List with
dataBinding: /flights for proper data context scoping.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-13 21:40:44 -07:00
Atai Barkai 0dd826e8af fix(a2ui-hello-world): use A2UI_OPERATIONS_KEY constant across Python SDK and renderer
Restores a2ui.render() usage in search_flights. The constant
"a2ui_operations" is now defined in all three layers: Python SDK,
ag-ui middleware, and A2UIMessageRenderer.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-13 21:24:24 -07:00
Atai Barkai afa9f7ac73 feat(a2ui-hello-world): use uv.sources for local Python SDK linking
pyproject.toml [tool.uv.sources] points copilotkit at the local
sdk-python directory. Survives uv sync / LangGraph CLI restarts.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-13 20:34:19 -07:00
Atai Barkai 4e0d857146 feat(a2ui-hello-world): add copilotkit.a2ui Python SDK module and a2ui_operations container
- copilotkit/a2ui.py: load_schema(), surface_update(), data_model_update(),
  begin_rendering(), render() — canonical SDK for building A2UI operations
- A2UIMessageRenderer reads a2ui_operations (with operations fallback)
- local-install script now includes editable pip install of Python SDK
- search_flights uses `from copilotkit import a2ui` pattern

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-13 19:54:43 -07:00
Atai Barkai de222fb9e7 refactor(a2ui-hello-world): load A2UI schema from JSON file
Schema is now a plain .json file — paste-able directly from a schema
builder. load_schema() reads it, a2ui_surface() does the rest.
Updated Flight TypedDict to match new schema's data bindings.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-13 19:37:44 -07:00
Atai Barkai a58feaddd4 refactor(a2ui-hello-world): extract flight schema to dedicated file
Tool file is now just the TypedDict + one a2ui_surface() call.
Schema lives in a2ui_flight_schema.py.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-13 19:35:19 -07:00
Atai Barkai a3d63b6ed8 refactor(a2ui-hello-world): extract a2ui_surface helper, simplify search_flights
a2ui.py handles operations assembly, data typing, and normalization.
search_flights is now just schema + one a2ui_surface() call.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-13 19:28:24 -07:00
Atai Barkai 39890b533a refactor(a2ui-hello-world): clarify schema/data separation in search_flights
Make it explicit in code that the tool emits three separate A2UI
messages: schema (surfaceUpdate), data (dataModelUpdate), and
render trigger (beginRendering). The schema is fixed; only data
changes per invocation.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-13 19:17:12 -07:00
Atai Barkai 49197b9d67 feat(a2ui-hello-world): add fixed schema A2UI flight search example
Adds a data-bound declarative UI tool (search_flights) demonstrating the
full A2UI lifecycle: surfaceUpdate → dataModelUpdate → beginRendering.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-13 18:06:48 -07:00
Atai Barkai 62a2203123 fix(web-inspector): mock localStorage in tests for jsdom compatibility
jsdom doesn't provide a fully functional localStorage, causing
`localStorage.clear is not a function` and blocking all commits.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-13 18:06:21 -07:00
Atai Barkai 15904a53b8 feat(a2ui-hello-world): add AG-UI local linking to local-install
Extends .pnpmfile.cjs and local-install script to also build and link
AG-UI packages from a sibling ag-ui/ repo, enabling local development
across both CopilotKit and AG-UI.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-13 16:59:57 -07:00
Atai Barkai 567e134445 fix(a2ui-hello-world): remove pie chart streaming animation
The CSS transition on stroke-dasharray/dashoffset looked jarring
during streaming. Just render slices instantly instead.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-13 13:55:09 -07:00
Atai Barkai 79697e6a9d fix(a2ui-hello-world): rebalance demo data for better pie chart distribution
Adjust revenue figures so no single category exceeds ~35%, producing
a more visually balanced pie chart during demos.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-13 00:22:04 -07:00
Atai Barkai e202ec6f1a feat(a2ui-hello-world): redesign generative UI components
Custom SVG donut chart with CSS-transitioned streaming animations,
animated bar chart with slide-in entrance for new bars, polished
meeting time picker with Lucide icons and larger touch targets,
and refined tool rendering with monospace names and styled arg blocks.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-13 00:22:00 -07:00
Atai Barkai 36c2b86845 feat(a2ui-hello-world): set inspector default position to top-left
Use the new inspectorDefaultAnchor prop to place the inspector button
in the top-left corner, avoiding overlap with the Chat/App toggle.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 23:16:37 -07:00
Atai Barkai b642f6760d feat(web-inspector): add defaultAnchor prop to configure initial position
Add a `defaultAnchor` property to the web inspector that lets apps set
which corner the inspector button appears in on first load. When provided,
the default anchor takes precedence over persisted localStorage state
unless the user has manually dragged the inspector to a custom position.

Exposed as `inspectorDefaultAnchor` on CopilotKitProvider.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 23:16:25 -07:00
Atai Barkai 5e26c8d47b feat(a2ui-hello-world): add local-install for iterating on CopilotKit SDKs
Add .pnpmfile.cjs hook and `pnpm run local-install` script that builds
CopilotKit packages from the monorepo and symlinks them into the example
app via COPILOTKIT_LOCAL env var. Default `pnpm install` still pulls from
npm, preserving the template experience.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 22:49:42 -07:00
Tyler Slaton 55b5739ad5 fix(docs): remove CLI scaffolding from built-in-agent and agent-spec quickstarts
Neither built-in-agent nor agent-spec are valid CLI framework options.
Remove "Start from scratch" CLI paths, keep manual setup only.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 20:53:40 -04:00
Tyler Slaton 3051bd1ff1 fix(docs): correct quickstart errors and API examples across integrations
- Agent-spec: remove invalid CLI `-f agent-spec` option, link to manual setup
- A2A: fix env var (GEMINI_API_KEY) and port (10002) to match starter template
- AWS Strands: fix useRenderTool to use Zod schema and correct render props
- LangGraph: add auth guide cross-reference in configurable docs

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 20:53:40 -04:00
Tyler Slaton bb96398854 fix(cli): remove prepare script on install
Signed-off-by: Tyler Slaton <tyler@copilotkit.ai>
2026-03-12 20:44:56 -04:00
Tyler Slaton af77b019f1 feat(langgraph-python): better prompt, tasks -> todos
Signed-off-by: Tyler Slaton <tyler@copilotkit.ai>
2026-03-12 20:44:56 -04:00
Tyler Slaton c672be411d fix(langgraph-python): sync lockfiles
Signed-off-by: Tyler Slaton <tyler@copilotkit.ai>
2026-03-12 20:21:06 -04:00
Tyler Slaton ccd4cc4437 feat: improve UI, better a2ui example, faster model
Signed-off-by: Tyler Slaton <tyler@copilotkit.ai>
2026-03-12 20:09:51 -04:00
github-actions[bot] ea746d4629 chore(post-release): update version to 1.54.0 v1.54.0 2026-03-12 22:32:04 +00:00
Tyler Slaton a62a97a195 chore: release 1.54.0
Signed-off-by: Tyler Slaton <tyler@copilotkit.ai>
2026-03-12 18:27:53 -04:00
Jordan Ritter 13da6bde76 feat: consolidate 73 standalone demo repos into monorepo (#3418)
## Summary

Migrates 47 standalone demo repositories from the CopilotKit GitHub org
into the monorepo under `examples/`, organized by category
(integrations, showcases, canvas). History is intentionally dropped —
shallow clone + file copy only.

Also migrates the `copilotkit` CLI package from CopilotCloud into
`packages/v1/cli` (previously stacked as PR #3419, now merged into this
branch).

### Demo consolidation

- **47 demos** imported across 4 groups (A=22, B=21, C=2, D=2)
- **26 repos excluded** — all 13 experiments (old/irrelevant
prototypes), 6 showcases (autotale, agui, campaign-manager, chat-sso,
crewai-enterprise, crm), and 7 starters (textarea, todos-app,
coagents-langgraph, coagents-crewai-flows, llamaindex-hitl,
enterprise-runner, react-vite-agent) dropped to reduce consolidation
footprint
- **Git LFS** tracks binary assets (png, jpg, jpeg, gif, mp4, webm, pdf)
— svg removed from LFS (text-based, breaks `GIT_LFS_SKIP_SMUDGE=1` clone
instructions)
- **Image deduplication** via `examples/images/` with symlinks from
individual examples
- **Tutorial branches** imported as `start/` and `final/` subdirectories
- **Cross-link rewriting** — all standalone repo URLs in READMEs and
docs updated to monorepo paths
- **Doc updates** — 18 tutorial/doc files updated with new clone
instructions and paths
- **Renovate config** — `examples/**` dependencies grouped into weekly
Monday PRs, v1/v2 legacy dirs excluded
- **`examples/README.md`** — full index of all 47 demos by category
- **Archive script** — `scripts/archive-demo-repos.sh` ready to
deprecate+archive original repos post-merge
- **Prettier** — all example files formatted to match monorepo standards
- **Example bug fixes** — Gemini agents (unguarded variables, sync
blocking, dead OpenAI route), langgraph-python (debug print, docstring
placement), StackBlitz URLs

### CLI migration (from CopilotCloud)

- `TEMPLATE_REPOS` updated to use monorepo subdirectory sparse checkout
for all CopilotKit-owned templates
- Tarball download fallback preserved for external repos
(ag2ai/ag2-copilotkit-starter)
- Package metadata (bugs, homepage, repository) updated to point to
monorepo
- Removed stale tsconfig paths/references to non-existent
`@repo/trpc-cli`
- **Pre-existing bug fixes:**
  - `base-command.ts`: unguarded `fetch()` crashed CLI when offline
  - `init.ts`: dropped all user flags when delegating to `create`
- `detect-endpoint-type.utils.ts`: Promise.all destructuring mismatch (5
promises, 4 variables)
- `auth.service.ts`: OAuth state validated after analytics, Promise
never settled on mismatch

### Category breakdown

| Category | Count | Path |
|----------|-------|------|
| Integrations | 17 | `examples/integrations/` |
| Canvas | 7 | `examples/canvas/` |
| Showcases | 23 | `examples/showcases/` |

### What happens after merge
- Run `scripts/archive-demo-repos.sh` to deprecate+archive the 47
consolidated repos
- 26 excluded repos (experiments + 6 showcases + 7 starters) left as-is
on GitHub
- Community announcement (Slack draft prepared)
- Post-merge verification (README rendering, LFS quotas, CLI test)

## Test plan

- [ ] `examples/README.md` renders correctly on GitHub with all links
working
- [ ] LFS-tracked images render in GitHub READMEs
- [ ] Spot-check 3-5 examples can `npm install && npm run dev`
successfully
- [ ] Symlinks in `examples/images/` resolve correctly
- [ ] No `.git/`, `.github/`, `node_modules/`, or `.env` files in any
example
- [ ] Doc tutorial paths point to existing `start/`/`final/` directories
- [ ] No remaining standalone repo URLs in docs
- [ ] `nx run copilotkit:test` passes (46/46)
- [ ] `copilotkit create` scaffolds from monorepo subdirectory
- [ ] CLI works offline (version check doesn't crash)

🤖 Generated with [Claude Code](https://claude.com/claude-code)
2026-03-12 16:29:54 -04:00
Jordan Ritter 1d72b9ce1b chore: strip starters from consolidation, update metadata to 47 repos 2026-03-12 13:06:04 -07:00
Jordan Ritter fd34bbfbf6 style: format all example files with prettier
Run prettier on ~1,865 files across examples/ to match the monorepo's
formatting standards. These files were imported as-is from standalone
repos that used different prettier configs.
2026-03-12 13:06:04 -07:00
Jordan Ritter eab4855e67 fix: address review findings in consolidated examples
- gemini/stack_agent.py: initialize tool_calls/tool_msg before try
  block, guard usage with null check to prevent NameError on failure
- gemini/posts_generator_agent.py: use async generate_content to avoid
  blocking event loop, guard grounding_metadata access, replace bare
  except with explicit bounds check, remove dead router_function and
  redundant static edges
- gemini/app/api/chat/route.ts: remove dead OpenAI route from Gemini
  example (mislabeled as Gemini-powered, no frontend references it)
- gemini/package.json: remove unused @ai-sdk/openai, ai, zod deps
- langgraph-python/agent.py: remove debug print(state), move docstring
  to first position so chat_node.__doc__ works
- textarea tutorial: fix StackBlitz URLs pointing to use-tasks.tsx
  instead of use-emails.tsx
2026-03-12 13:06:04 -07:00
Jordan Ritter 34268b756a fix: remove SVG from LFS tracking
SVG files are text-based XML averaging ~218 bytes each. LFS tracking
adds per-file HTTP fetch overhead with no storage benefit, suppresses
git diff output, and breaks tutorial clone instructions that use
GIT_LFS_SKIP_SMUDGE=1 (users get LFS pointers instead of icons).
2026-03-12 13:06:03 -07:00
Jordan Ritter f36dcc708f fix: resolve pre-existing bugs in CLI package
- base-command: wrap checkCLIVersion() fetch in try-catch so CLI
  doesn't crash when offline (version check is non-critical)
- init: forward argv to Create instead of dropping all flags, remove
  misleading flag definitions (init is just a deprecated redirect)
- detect-endpoint-type: fix Promise.all destructuring (5 promises but
  only 4 variables caused isCopilot to receive the LangGraph FastAPI
  result), add missing isMCP branch, use isLangGraphFastAPI result
- auth.service: validate OAuth state parameter before tracking analytics
  with user data, add reject()+server.close() on state mismatch so the
  Promise settles instead of hanging the CLI forever
- create.test: fix quote-style assertion to match prettier output
2026-03-12 13:06:03 -07:00
Jordan Ritter ad81aaa524 fix: address review findings in migrated CLI package
- Remove copy-paste triplication in scaffoldAgent (LangSmith block
  duplicated twice, causing duplicate .env entries and redundant writes)
- Update AgentTemplates URLs to point to monorepo paths instead of
  archived standalone repos
- Fix flags.projectName → args.projectName in banner logic (projectName
  is an Args field, not Flags)
- Remove stale trpc-cli path mapping and project reference from
  tsconfig.json (package doesn't exist in this monorepo)
2026-03-12 13:06:03 -07:00
Jordan Ritter bee70690bb feat: move CLI package from CopilotCloud into monorepo
Migrate the copilotkit CLI (npx copilotkit create/init/dev) from
CopilotCloud into packages/v1/cli. TEMPLATE_REPOS updated to use
monorepo subdirectory sparse checkout for all CopilotKit-owned
templates, with tarball fallback for external repos (ag2).
2026-03-12 13:06:03 -07:00
Jordan Ritter 22f5d61396 chore: configure Renovate for consolidated examples
Add package rules to group examples/** dependency updates into weekly
Monday PRs. CopilotKit package bumps are tracked separately. Legacy
examples/v1/ and v2/ directories are excluded from both rules.
2026-03-12 13:06:03 -07:00
Jordan Ritter 79bdaddf0c docs: update tutorials and READMEs for consolidated demo paths
Rewrite all standalone repo URLs to monorepo paths across 18 doc files
and the root README. Tutorial clone instructions now use
GIT_LFS_SKIP_SMUDGE=1 and point to examples/ subdirectories. Fix
pre-existing copy-paste bug in textarea tutorial and stale branch refs.
2026-03-12 13:06:03 -07:00
Jordan Ritter 4b73c33d2f chore: add migration and archive scripts for demo repo consolidation
migrate-demos.sh: automates shallow clone + cleanup + copy for all 73
repos, with --group and --dry-run support.

archive-demo-repos.sh: updates each standalone repo's README with a
deprecation notice pointing to the monorepo location, then archives it.
Exits non-zero on any failures.
2026-03-12 13:06:02 -07:00
Jordan Ritter ec3a5ff114 feat: consolidate 47 demo repos into examples/ 2026-03-12 13:06:02 -07:00
github-actions[bot] 98890426e5 chore(post-release): update version to 1.54.0-next.9 2026-03-12 19:08:50 +00:00
Alem Tuzlak 3780c6ae74 chore: deprecate all @copilotkitnext/* packages
Mark all publishable @copilotkitnext/* packages as deprecated in
package.json, pointing users to the @copilotkit/* equivalents.
V2 features will be available under the /v2 subpath.

Affected packages: shared, core, agent, angular, react, runtime,
sqlite-runner, web-inspector.
2026-03-12 15:05:29 -04:00
github-actions[bot] b443706792 chore(post-release): update version to 1.54.0-next.8 2026-03-12 16:52:13 +00:00
Ran Shemtov 989dc26f56 fix: inject useCopilotReadable context into connectAgent (#3422) 2026-03-12 17:44:52 +01:00
Ran Shemtov f1571ef73e chore: add changeset 2026-03-12 16:43:01 +01:00
Ran Shem Tov ad85914b8c fix: inject useCopilotReadable context into connectAgent 2026-03-12 16:16:20 +01:00
github-actions[bot] ecd76256ed chore(post-release): update version to 1.54.0-next.7 2026-03-12 14:26:14 +00:00
Ran Shemtov d92adea27c fix(react): yield to React scheduler before follow-up agent run to pr… (#3421) 2026-03-12 15:22:30 +01:00