copilotkit 4.9.47 → 4.9.60

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (67) hide show
  1. package/README.md +179 -9
  2. package/cli-build-info.json +8 -8
  3. package/index.js +13012 -8898
  4. package/onboarding/index.json +162 -1
  5. package/onboarding/prompts/authenticate/start.md +41 -14
  6. package/onboarding/prompts/conversion/plan.md +3 -3
  7. package/onboarding/prompts/credentials/finalize-plan.md +54 -13
  8. package/onboarding/prompts/credentials/plan.md +20 -20
  9. package/onboarding/prompts/fallback/best-effort.md +6 -6
  10. package/onboarding/prompts/feature/a2ui/implement.md +32 -0
  11. package/onboarding/prompts/feature/a2ui/proof.md +34 -0
  12. package/onboarding/prompts/feature/a2ui/start.md +55 -0
  13. package/onboarding/prompts/feature/chat-suggestions/implement.md +28 -0
  14. package/onboarding/prompts/feature/chat-suggestions/proof.md +26 -0
  15. package/onboarding/prompts/feature/chat-suggestions/start.md +46 -0
  16. package/onboarding/prompts/feature/learning/implement.md +106 -0
  17. package/onboarding/prompts/feature/learning/proof.md +45 -0
  18. package/onboarding/prompts/feature/learning/start.md +56 -0
  19. package/onboarding/prompts/feature/open-generative-ui/implement.md +28 -0
  20. package/onboarding/prompts/feature/open-generative-ui/proof.md +27 -0
  21. package/onboarding/prompts/feature/open-generative-ui/start.md +47 -0
  22. package/onboarding/prompts/feature/realtime-sync/implement.md +38 -0
  23. package/onboarding/prompts/feature/realtime-sync/proof.md +28 -0
  24. package/onboarding/prompts/feature/realtime-sync/start.md +50 -0
  25. package/onboarding/prompts/feature/rich-threads/implement.md +41 -0
  26. package/onboarding/prompts/feature/rich-threads/proof.md +27 -0
  27. package/onboarding/prompts/feature/rich-threads/start.md +52 -0
  28. package/onboarding/prompts/feature/stop.md +41 -0
  29. package/onboarding/prompts/feature/voice/implement.md +28 -0
  30. package/onboarding/prompts/feature/voice/proof.md +27 -0
  31. package/onboarding/prompts/feature/voice/start.md +45 -0
  32. package/onboarding/prompts/framework/ag2.md +2 -2
  33. package/onboarding/prompts/framework/agno.md +2 -2
  34. package/onboarding/prompts/framework/built-in.md +2 -2
  35. package/onboarding/prompts/framework/claude-sdk-python.md +2 -2
  36. package/onboarding/prompts/framework/claude-sdk-typescript.md +2 -2
  37. package/onboarding/prompts/framework/crewai-flows.md +2 -2
  38. package/onboarding/prompts/framework/deep-agents.md +2 -2
  39. package/onboarding/prompts/framework/google-adk.md +2 -2
  40. package/onboarding/prompts/framework/langgraph-fastapi.md +2 -2
  41. package/onboarding/prompts/framework/langgraph-python.md +2 -2
  42. package/onboarding/prompts/framework/langgraph-typescript.md +2 -2
  43. package/onboarding/prompts/framework/llamaindex.md +2 -2
  44. package/onboarding/prompts/framework/mastra.md +2 -2
  45. package/onboarding/prompts/framework/ms-agent-dotnet.md +2 -2
  46. package/onboarding/prompts/framework/ms-agent-harness-dotnet.md +2 -2
  47. package/onboarding/prompts/framework/ms-agent-python.md +2 -2
  48. package/onboarding/prompts/framework/pydantic-ai.md +2 -2
  49. package/onboarding/prompts/framework/strands-python.md +2 -2
  50. package/onboarding/prompts/framework/strands-typescript.md +2 -2
  51. package/onboarding/prompts/frontend/angular.md +3 -3
  52. package/onboarding/prompts/frontend/nextjs.md +3 -3
  53. package/onboarding/prompts/frontend/plan.md +6 -6
  54. package/onboarding/prompts/frontend/react-native.md +2 -2
  55. package/onboarding/prompts/frontend/react-spa.md +2 -2
  56. package/onboarding/prompts/frontend/vue.md +2 -2
  57. package/onboarding/prompts/implementation/build-and-validate.md +83 -13
  58. package/onboarding/prompts/proof/complete.md +10 -10
  59. package/onboarding/prompts/proof/oss-baseline.md +16 -7
  60. package/onboarding/prompts/proof/round-trip.md +16 -9
  61. package/onboarding/prompts/starter/clone.md +5 -5
  62. package/onboarding/prompts/subagent/create-plan.md +11 -3
  63. package/onboarding/prompts/subagent/prove-oss-baseline.md +1 -1
  64. package/onboarding/prompts/subagent/prove-round-trip.md +13 -10
  65. package/onboarding/prompts/unsupported/no-validated-path.md +4 -4
  66. package/package.json +1 -1
  67. package/release/release-tool.js +37 -11
package/README.md CHANGED
@@ -72,6 +72,22 @@ copilotkit project select --create "My App" --json # create one and select it
72
72
  against the organization's real projects, so a typo fails with the available
73
73
  slugs instead of recording a selection that points at nothing.
74
74
 
75
+ A `--create` name that an existing project already uses is refused, and the
76
+ refusal names a free name computed from the list the CLI already holds, so a
77
+ caller retries once rather than guessing. Under `--json` the same name is
78
+ carried as `suggested_name`:
79
+
80
+ ```json
81
+ {
82
+ "error": "You already have a project named \"My App\". \"My App-2\" is free.",
83
+ "suggested_name": "My App-2",
84
+ "type": "failed"
85
+ }
86
+ ```
87
+
88
+ The interactive picker offers the same name and never applies it silently:
89
+ press Enter again to take it, or type a different one.
90
+
75
91
  `--json` emits one object on stdout:
76
92
 
77
93
  ```json
@@ -188,6 +204,44 @@ The bundled onboarding prompt gives one short explanation before it opens the
188
204
  page: sign-in lets the coding agent create a project and API key, and the user
189
205
  can remove the key later to disconnect the workspace.
190
206
 
207
+ ## Feature onboarding for existing apps
208
+
209
+ Use the optional `--intent` flag when an existing CopilotKit app needs one
210
+ specific feature. The CLI prints a feature-specific Markdown path; the coding
211
+ agent follows its inspection, plan, implementation, and visible-proof steps.
212
+ Without `--intent`, `onboard start` keeps the generic onboarding path unchanged.
213
+
214
+ ```bash
215
+ npx --yes copilotkit@latest onboard start \
216
+ --intent add-a2ui \
217
+ --run <12-character-id> \
218
+ --coding-agent <slug>
219
+ ```
220
+
221
+ `--intent` is a closed outcome, not free-form text. The supported values are:
222
+
223
+ | Intent | Outcome |
224
+ | ------------------------ | ----------------------------------------------------------- |
225
+ | `add-rich-threads` | Managed Rich Threads with durable thread UI/API proof |
226
+ | `add-learning` | Assign real runs to a selected Learning Container |
227
+ | `add-a2ui` | Render an A2UI surface in an existing OSS app |
228
+ | `add-open-generative-ui` | Render a sandboxed generated UI in chat |
229
+ | `add-chat-suggestions` | Configure and send visible chat suggestions |
230
+ | `add-voice` | Add documented voice transcription to the existing composer |
231
+ | `add-realtime-sync` | Prove managed thread changes sync between active clients |
232
+
233
+ The intent describes the developer's requested outcome, not a claim about the
234
+ current project state. Each path inspects the app first: it preserves a proven
235
+ existing configuration, stops rather than inventing credentials or identities,
236
+ and sends an app that lacks a CopilotKit baseline to generic onboarding first.
237
+ The CLI retains the selected intent with its repository-bound run, so every
238
+ onboarding event a later step reports carries the requested outcome.
239
+
240
+ Each path checks in at the steps where a run goes quiet: when the inspection
241
+ subagent returns, when the plan is approved, when implementation validation
242
+ passes, and on each proof attempt and repair cycle. A run that cannot go on
243
+ reads `feature/stop`, reports from there, and does not run `onboard complete`.
244
+
191
245
  The onboarding commands are:
192
246
 
193
247
  - `copilotkit init`
@@ -356,6 +410,104 @@ prompts, and never opens a browser. See
356
410
  [Managed Channel CLI contracts](../../docs/channels-cli-contracts.md) for the
357
411
  declared-Channels file, the envelope shape, and the credential resolution order.
358
412
 
413
+ ## Learning Containers
414
+
415
+ Run the Learning commands from a directory with a selected hosted project:
416
+
417
+ ```bash
418
+ copilotkit learning containers list
419
+ copilotkit learning containers get support-quality
420
+ copilotkit learning containers create
421
+ copilotkit learning containers select
422
+ copilotkit learning containers update support-quality
423
+ copilotkit learning containers delete support-quality
424
+ ```
425
+
426
+ The create and update commands prompt for missing fields in a human terminal.
427
+ The delete command shows the exact container and asks for approval. The CLI
428
+ cannot delete a container with bound Threads or Learning history.
429
+
430
+ `select` offers the containers this project already has and prints the one you
431
+ pick, and its create form opens on an id derived from the project slug, because
432
+ one container per project is the default scope. Route runs to different
433
+ containers per user or per tier from `getLearningContainerId` in your own
434
+ runtime, which receives the resolved application user; a container per user
435
+ rarely reaches the 15 distinct conversations a first Learning run needs. Choose `Create a new container` to make one instead. It reads the first
436
+ page before it draws the list and reads a later page only when you choose
437
+ `Show more`, so a project with one container costs one read. `select` needs a
438
+ terminal: with `--json`, or with no TTY, it refuses and names `list` and
439
+ `create` instead.
440
+
441
+ Pass flags for a script or coding agent:
442
+
443
+ ```bash
444
+ copilotkit learning containers list --json
445
+ copilotkit learning containers create --id support-quality --name "Support quality" --json
446
+ copilotkit learning containers update support-quality --prompt-context "Use approved answers." --json
447
+ copilotkit learning containers update support-quality --clear-prompt-context --json
448
+ copilotkit learning containers delete support-quality --yes --json
449
+ ```
450
+
451
+ `--json` emits one versioned JSON object on stdout and never prompts. Create
452
+ requires `--id` and `--name`. Update requires at least one change flag. Delete
453
+ requires `--yes`. Errors use the same JSON envelope and exit with a nonzero
454
+ status.
455
+
456
+ A container keeps its stable ID. The list command returns at most 500 containers.
457
+ If `nextCursor` is not null, pass it to `--cursor` to read the next page.
458
+
459
+ Writes are rate limited per organization, project, and caller: 10 creates, 30
460
+ updates, and 30 deletes each minute. Updates and deletes are counted separately,
461
+ so a cleanup loop does not spend its delete budget on the renames before it.
462
+ Each API replica counts on its own, so these are the lowest limits a script can
463
+ rely on. A call over the limit returns `RATE_LIMIT_EXCEEDED`. Wait one minute,
464
+ then retry.
465
+
466
+ ## Learning Insights and Skill review
467
+
468
+ Use the same selected project to inspect Learning output:
469
+
470
+ ```bash
471
+ copilotkit learning insights list support-quality
472
+ copilotkit learning candidates list support-quality
473
+ copilotkit learning candidates review support-quality <candidate-id>
474
+ copilotkit learning candidates approve support-quality <candidate-id>
475
+ copilotkit learning candidates reject support-quality <candidate-id>
476
+ copilotkit learning skills list support-quality
477
+ copilotkit learning skills list support-quality --full
478
+ ```
479
+
480
+ The `review` command is an alias of `candidates get`. Both commands show the
481
+ candidate reason, supporting Insights, and all proposed Skill files.
482
+
483
+ Approval and rejection show the full candidate before they ask for approval.
484
+ Approval publishes the proposed add, update, or removal. Rejection does not
485
+ change the published Skill Registry.
486
+
487
+ Agents and scripts must add `--json`. Add `--yes` to `approve` and `reject`.
488
+ Use `learning skills list --full` to include `SKILL.md` in human output. JSON
489
+ list output contains the full records, always includes `skillMd`, and sets
490
+ `resultLimit` to `500`. Insight, candidate, and Skill lists return at most 500
491
+ items and do not support a cursor.
492
+
493
+ Malformed Insight, candidate, or Skill command input returns
494
+ `LEARNING_INPUT_INVALID`. Malformed Container command input returns
495
+ `LEARNING_CONTAINER_INPUT_INVALID`. Reviewing a candidate that is already
496
+ approved or rejected returns `LEARNING_CANDIDATE_SETTLED` before any request is
497
+ sent. `LEARNING_CANDIDATE_CONFLICT` is different: the server refused because the
498
+ candidate changed during the review, so read it again and retry.
499
+
500
+ The CLI sends command telemetry such as `insights.list` and
501
+ `candidates.approve`. Human reviews also send bounded review-viewed and
502
+ review-decided events. The CLI does not send Container IDs, candidate IDs,
503
+ Insight text, or Skill content in these events.
504
+
505
+ Three properties describe a review. `review_mode` is `human` when the CLI showed
506
+ the proposal and waited for an answer, and `agent` when `--yes` skipped that
507
+ prompt. `review_action` is the command the caller ran, `approve` or `reject`.
508
+ `review_decision` is the answer a person gave at the prompt, `confirmed` or
509
+ `canceled`, and it is sent only in `human` mode.
510
+
359
511
  ## Skills And Agent-Assisted Onboarding
360
512
 
361
513
  Use `copilotkit create` to start a **new** project. Use `copilotkit skills onboard`
@@ -479,7 +631,7 @@ A real key exported in your shell environment satisfies the check too. An
479
631
  exported empty or whitespace value falls back to the `.env` value, while an
480
632
  exported placeholder-shaped value fails the gate outright.
481
633
 
482
- The Microsoft Agent Framework .NET template uses GitHub Models. Set its C# agent token with `dotnet user-secrets set GitHubToken "<your-token>"` from the generated `agent/` directory.
634
+ The Microsoft Agent Framework .NET template uses OpenAI by default. Set its API key with `dotnet user-secrets set OPENAI_API_KEY "<your-openai-api-key>"` from the generated `agent/` directory.
483
635
 
484
636
  Do not commit generated `.env` files or personal secrets.
485
637
 
@@ -559,7 +711,7 @@ anything else:
559
711
  copilotkit verify
560
712
  copilotkit verify --json # machine-readable output
561
713
  copilotkit verify --runtime-url http://localhost:8080/copilotkit
562
- copilotkit verify --frontend-url http://127.0.0.1:3000 # check that host's assets
714
+ copilotkit verify --frontend-url http://127.0.0.1:3000 # that host's assets and CORS
563
715
  copilotkit verify --round-trip # also run the agent
564
716
  copilotkit verify --expect-runtime oss --round-trip --agent incident_triage
565
717
  ```
@@ -568,9 +720,15 @@ It checks that a hosted project is selected, that a project API key is present,
568
720
  that the app's own process can load that key, that the key authenticates
569
721
  against Intelligence, that the CopilotKit runtime responds, that the runtime
570
722
  declares at least one agent, that the runtime is actually using the credential,
571
- and that it serves the thread routes the license pays for. It also reports the
572
- runtime version, the agent framework in use, the realtime gateway wiring, the
573
- plan, and the license state.
723
+ and that it serves the thread routes the license pays for. It also checks that
724
+ the runtime accepts the origin a browser opens -- same-origin projects are
725
+ decided from the two URLs, and a cross-origin runtime is asked with a real
726
+ preflight when `--frontend-url` names the origin -- and that the CopilotKit
727
+ packages installed here are on the same version the runtime reports. The
728
+ version check is skipped when the runtime being probed is not on this
729
+ machine, because a deployed runtime and this checkout are two installations. It also reports the runtime
730
+ version, the agent framework in use, whether transcription is wired, the
731
+ realtime gateway wiring, the plan, and the license state.
574
732
 
575
733
  The selected project is read from the nearest `.copilotkit/project.json` at or
576
734
  above the current directory, stopping at the repository root, so running from
@@ -592,7 +750,11 @@ present** says the credential exists somewhere in this repository, and **The app
592
750
  can load the project API key** says the directory the app runs in supplies it.
593
751
  The second is `UNKNOWN` rather than `FAIL` wherever it cannot decide: no package
594
752
  declaring a `@copilotkit/*` dependency was found, more than one was, or a script
595
- in the app names an env file itself with `dotenv`, `env-cmd`, or `--env-file`.
753
+ in the app — or in any package above it, up to the project root — names an env
754
+ file itself with `dotenv`, `env-cmd`, or `--env-file`. It is also `UNKNOWN` when
755
+ a runtime answered and reported an Intelligence entitlement, because a runtime
756
+ cannot report one without having loaded a key: the report then names the
757
+ disagreement instead of claiming the app cannot load a key the runtime is using.
596
758
 
597
759
  That last check is the one a passing build cannot give you. A key in `.env`
598
760
  proves only that one was provisioned: the runtime reads no environment variable
@@ -688,9 +850,17 @@ closed.
688
850
  A runtime mounted `mode: "single-route"` refuses `GET /info`, so `verify` asks
689
851
  the same question again through the POST envelope that mount does answer.
690
852
  Reaching it that way counts as reachable, and the report says which shape
691
- answered. That mount carries no thread or memory route, though, so a licensed
692
- project on it fails the thread-route check with the mount named as the cause.
693
- Removing `mode: "single-route"` fixes it.
853
+ answered.
854
+
855
+ That mount serves its thread and memory routes too, inside the same envelope as
856
+ the `resource/request` method, and the client rewrites every such fetch into it.
857
+ So the thread-route check passes there and says the routes were served that way,
858
+ rather than as REST paths. It reads the `singleRoute` block of `/info` to decide,
859
+ because the top-level `threadEndpoints` block reports the routes absent on that
860
+ mount whatever it serves: the runtime resolves that block from whether the
861
+ request in hand is a `resource/request`, and an `info` call never is. A runtime
862
+ below `@copilotkit/runtime` 1.70.2 reports no `singleRoute` block and therefore
863
+ cannot say, so the check is `UNKNOWN` there and names the upgrade.
694
864
 
695
865
  ### Proving the agent runs, not just that it is configured
696
866
 
@@ -2,20 +2,20 @@
2
2
  "schemaVersion": 1,
3
3
  "package": {
4
4
  "name": "copilotkit",
5
- "version": "4.9.47"
5
+ "version": "4.9.60"
6
6
  },
7
7
  "intelligence": {
8
- "commit": "85f6b2eb2b4c8fef747bbfb0e3f5991b196ecc43"
8
+ "commit": "5f0f9a7cf15492544f1341f562fa5cd55387099c"
9
9
  },
10
10
  "copilotKit": {
11
- "submittedInput": "380ad1220a7bc78104baedc469c4d086c8910494",
12
- "commit": "380ad1220a7bc78104baedc469c4d086c8910494"
11
+ "submittedInput": "d1584b840f904674b470be5d2b16c4ccca99c4f4",
12
+ "commit": "d1584b840f904674b470be5d2b16c4ccca99c4f4"
13
13
  },
14
14
  "channel": "production",
15
- "triggeringActor": "MikeRyanDev",
15
+ "triggeringActor": "BenTaylorDev",
16
16
  "workflow": {
17
- "runId": "34279600219",
18
- "runUrl": "https://github.com/CopilotKit/Intelligence/actions/runs/34279600219"
17
+ "runId": "34616405214",
18
+ "runUrl": "https://github.com/CopilotKit/Intelligence/actions/runs/34616405214"
19
19
  },
20
20
  "validationResult": "passed",
21
21
  "ag2": {
@@ -24,5 +24,5 @@
24
24
  "revision": "main",
25
25
  "pinned": false
26
26
  },
27
- "builtAt": "2026-09-08T21:17:26Z"
27
+ "builtAt": "2026-09-11T15:30:58Z"
28
28
  }