copilotkit 4.9.60 → 4.10.1

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 (77) hide show
  1. package/README.md +10 -3
  2. package/cli-build-info.json +8 -8
  3. package/index.js +336 -172
  4. package/onboarding/index.json +106 -18
  5. package/onboarding/prompts/authenticate/start.md +41 -202
  6. package/onboarding/prompts/conversion/plan.md +3 -3
  7. package/onboarding/prompts/credentials/finalize-plan.md +15 -129
  8. package/onboarding/prompts/credentials/plan.md +20 -20
  9. package/onboarding/prompts/credentials/settle-credentials.md +153 -0
  10. package/onboarding/prompts/credentials/write-plan.md +93 -0
  11. package/onboarding/prompts/fallback/best-effort.md +12 -9
  12. package/onboarding/prompts/feature/a2ui/implement.md +35 -6
  13. package/onboarding/prompts/feature/a2ui/proof.md +30 -6
  14. package/onboarding/prompts/feature/a2ui/start.md +29 -6
  15. package/onboarding/prompts/feature/channels/implement.md +70 -0
  16. package/onboarding/prompts/feature/channels/proof.md +60 -0
  17. package/onboarding/prompts/feature/channels/start.md +87 -0
  18. package/onboarding/prompts/feature/chat-suggestions/implement.md +36 -6
  19. package/onboarding/prompts/feature/chat-suggestions/proof.md +30 -5
  20. package/onboarding/prompts/feature/chat-suggestions/start.md +29 -6
  21. package/onboarding/prompts/feature/complete.md +11 -0
  22. package/onboarding/prompts/feature/learning/implement.md +41 -12
  23. package/onboarding/prompts/feature/learning/proof.md +32 -6
  24. package/onboarding/prompts/feature/learning/start.md +28 -5
  25. package/onboarding/prompts/feature/open-generative-ui/implement.md +37 -6
  26. package/onboarding/prompts/feature/open-generative-ui/proof.md +30 -5
  27. package/onboarding/prompts/feature/open-generative-ui/start.md +29 -6
  28. package/onboarding/prompts/feature/realtime-sync/implement.md +36 -7
  29. package/onboarding/prompts/feature/realtime-sync/proof.md +29 -5
  30. package/onboarding/prompts/feature/realtime-sync/start.md +28 -5
  31. package/onboarding/prompts/feature/rich-threads/implement.md +37 -8
  32. package/onboarding/prompts/feature/rich-threads/proof.md +31 -5
  33. package/onboarding/prompts/feature/rich-threads/start.md +28 -5
  34. package/onboarding/prompts/feature/stop.md +17 -8
  35. package/onboarding/prompts/feature/voice/implement.md +35 -6
  36. package/onboarding/prompts/feature/voice/proof.md +30 -5
  37. package/onboarding/prompts/feature/voice/start.md +29 -6
  38. package/onboarding/prompts/framework/ag2.md +2 -2
  39. package/onboarding/prompts/framework/agno.md +2 -2
  40. package/onboarding/prompts/framework/built-in.md +2 -2
  41. package/onboarding/prompts/framework/claude-sdk-python.md +2 -2
  42. package/onboarding/prompts/framework/claude-sdk-typescript.md +2 -2
  43. package/onboarding/prompts/framework/crewai-flows.md +2 -2
  44. package/onboarding/prompts/framework/deep-agents.md +2 -2
  45. package/onboarding/prompts/framework/google-adk.md +2 -2
  46. package/onboarding/prompts/framework/langgraph-fastapi.md +2 -2
  47. package/onboarding/prompts/framework/langgraph-python.md +2 -2
  48. package/onboarding/prompts/framework/langgraph-typescript.md +2 -2
  49. package/onboarding/prompts/framework/llamaindex.md +2 -2
  50. package/onboarding/prompts/framework/mastra.md +2 -2
  51. package/onboarding/prompts/framework/ms-agent-dotnet.md +2 -2
  52. package/onboarding/prompts/framework/ms-agent-harness-dotnet.md +2 -2
  53. package/onboarding/prompts/framework/ms-agent-python.md +2 -2
  54. package/onboarding/prompts/framework/pydantic-ai.md +2 -2
  55. package/onboarding/prompts/framework/strands-python.md +2 -2
  56. package/onboarding/prompts/framework/strands-typescript.md +2 -2
  57. package/onboarding/prompts/frontend/angular.md +3 -3
  58. package/onboarding/prompts/frontend/nextjs.md +3 -3
  59. package/onboarding/prompts/frontend/plan.md +6 -6
  60. package/onboarding/prompts/frontend/react-native.md +2 -2
  61. package/onboarding/prompts/frontend/react-spa.md +2 -2
  62. package/onboarding/prompts/frontend/vue.md +2 -2
  63. package/onboarding/prompts/implementation/build-and-validate.md +75 -15
  64. package/onboarding/prompts/proof/complete.md +21 -8
  65. package/onboarding/prompts/proof/oss-baseline.md +6 -5
  66. package/onboarding/prompts/proof/round-trip.md +27 -14
  67. package/onboarding/prompts/research/gather.md +121 -0
  68. package/onboarding/prompts/research/route.md +81 -0
  69. package/onboarding/prompts/starter/clone.md +18 -9
  70. package/onboarding/prompts/stopped/run-failed.md +44 -0
  71. package/onboarding/prompts/subagent/create-plan.md +32 -1
  72. package/onboarding/prompts/subagent/implement-and-validate.md +9 -1
  73. package/onboarding/prompts/subagent/prove-oss-baseline.md +1 -1
  74. package/onboarding/prompts/subagent/prove-round-trip.md +52 -8
  75. package/onboarding/prompts/unsupported/no-validated-path.md +9 -6
  76. package/package.json +1 -1
  77. package/release/release-tool.js +39 -3
@@ -46,6 +46,8 @@ The handoff must include:
46
46
  - The `@copilotkit/*` versions this conversion changed, and what they were before.
47
47
  - On a conversion, the criterion this run was judged against, in the words the run was
48
48
  given.
49
+ - The Learning Container this run settled, or the fact that Learning is not available to
50
+ this organization and no container was created.
49
51
  - Any path this run created that git does not ignore, and what to do with each.
50
52
  - Any protected path this run accepted as changed from outside it, and what changed. The
51
53
  command at the end of this prompt prints each one, so copy them from its output rather
@@ -64,11 +66,22 @@ Name the debugging surface this journey's frontend can reach, rather than the on
64
66
  of the documentation leads with. For a web frontend it is the CopilotKit Inspector. For
65
67
  React Native there is no Inspector: it is a browser overlay built on a DOM custom element,
66
68
  and `@copilotkit/react-native` does not ship it. Give a mobile developer
67
- `npx --yes copilotkit@4.9.60 verify --round-trip`, the runtime's own log, the AG-UI
69
+ `npx --yes copilotkit@4.10.1 verify --round-trip`, the runtime's own log, the AG-UI
68
70
  Event Inspector in the CopilotKit VS Code extension, and the Intelligence thread view
69
71
  instead. Naming the Inspector to a developer who cannot open it costs them the time it
70
72
  takes to conclude their own wiring is broken.
71
73
 
74
+ Where this run settled a Learning Container, tell the developer what happens next, because
75
+ a correct run looks like a broken one otherwise. Learning runs on its own: the first
76
+ automatic run needs new threads from 15 distinct conversations in this container, and only
77
+ the newest snapshot of each thread counts. A thread takes its container before its first
78
+ agent run, so threads that ran before this change are never pulled in. The container starts
79
+ empty on purpose.
80
+
81
+ Where the Learning step was skipped because this organization cannot use Learning, say so in
82
+ one line and name what was not created. A skip nobody names reads as a container that
83
+ exists, and the developer then waits for insights from a container this run never made.
84
+
72
85
  State that the servers remain running after proof.
73
86
 
74
87
  Report each thing that slowed this run down. Send at most four reports, worst first. Run
@@ -76,7 +89,7 @@ the friction commands without another developer question. The CLI telemetry gate
76
89
  whether the report is sent.
77
90
 
78
91
  ```text
79
- npx --yes copilotkit@4.9.60 onboard friction --category <slug> --cost-seconds <seconds>
92
+ npx --yes copilotkit@4.10.1 onboard friction --category <slug> --cost-seconds <seconds>
80
93
  ```
81
94
 
82
95
  Write one or two sentences on the command's standard input. Pick one category from
@@ -88,7 +101,7 @@ Pass --docs-path only for a docs-missing or docs-wrong report, naming the page t
88
101
  is about:
89
102
 
90
103
  ```text
91
- npx --yes copilotkit@4.9.60 onboard friction --category docs-wrong --cost-seconds 300 --docs-path /docs/threads/drawer
104
+ npx --yes copilotkit@4.10.1 onboard friction --category docs-wrong --cost-seconds 300 --docs-path /docs/threads/drawer
92
105
  ```
93
106
 
94
107
  Give the page's site-relative path or its full URL, with no spaces, query string, or
@@ -105,14 +118,14 @@ Tell the developer when you send a friction report. Do not quote or summarize th
105
118
  unless the developer asks. If the CLI says the report was not sent,
106
119
  state what it said and continue without another question.
107
120
 
108
- When the evidence is gathered, run `npx --yes copilotkit@4.9.60 onboard complete`, carrying
121
+ When the evidence is gathered, run `npx --yes copilotkit@4.10.1 onboard complete`, carrying
109
122
  the surface-check outcome the proof subagent returned. Pass exactly one flag, and pass the
110
123
  one that matches this journey's surface.
111
124
 
112
125
  For a web frontend -- React SPA, Next.js, Angular, Vue:
113
126
 
114
127
  ```text
115
- npx --yes copilotkit@4.9.60 onboard complete --visual-check <outcome>
128
+ npx --yes copilotkit@4.10.1 onboard complete --visual-check <outcome>
116
129
  ```
117
130
 
118
131
  The outcome is one of `performed`, `skipped-no-browser-tool`, or `failed`.
@@ -120,7 +133,7 @@ The outcome is one of `performed`, `skipped-no-browser-tool`, or `failed`.
120
133
  For React Native:
121
134
 
122
135
  ```text
123
- npx --yes copilotkit@4.9.60 onboard complete --device-check <outcome>
136
+ npx --yes copilotkit@4.10.1 onboard complete --device-check <outcome>
124
137
  ```
125
138
 
126
139
  The outcome is one of `performed`, `skipped-no-device`, or `failed`.
@@ -132,7 +145,7 @@ browser-origin CORS, so the flag you pass is how this run states which surface i
132
145
  For a web frontend, also pass the URL the browser opened:
133
146
 
134
147
  ```text
135
- npx --yes copilotkit@4.9.60 onboard complete --visual-check <outcome> \
148
+ npx --yes copilotkit@4.10.1 onboard complete --visual-check <outcome> \
136
149
  --frontend-url <the url you opened>
137
150
  ```
138
151
 
@@ -151,7 +164,7 @@ If the round trip proved and something after it still blocked this run, add `--b
151
164
  to the same command:
152
165
 
153
166
  ```text
154
- npx --yes copilotkit@4.9.60 onboard complete --visual-check performed --blocked-by <cause>
167
+ npx --yes copilotkit@4.10.1 onboard complete --visual-check performed --blocked-by <cause>
155
168
  ```
156
169
 
157
170
  The cause is one of `inspector` for a debugging surface that did not open,
@@ -1,7 +1,7 @@
1
1
  # Prove the existing OSS baseline
2
2
 
3
3
  Do not prove the baseline yourself. Spawn one proof subagent. Tell it to run
4
- `npx --yes copilotkit@4.9.60 onboard read subagent/prove-oss-baseline` first and follow the
4
+ `npx --yes copilotkit@4.10.1 onboard read subagent/prove-oss-baseline` first and follow the
5
5
  prompt it returns. If that read fails because the subagent cannot use the shell, stop that
6
6
  subagent. Run the same command yourself, then spawn a fresh subagent with the returned prompt
7
7
  and the same handoff. Give it the repository findings and exact CLI package spec.
@@ -17,7 +17,7 @@ Wait for the subagent to finish.
17
17
  Record what that proof returned before you route on it:
18
18
 
19
19
  ```text
20
- npx --yes copilotkit@4.9.60 onboard proof --step oss-baseline --outcome <passed|failed|skipped> [--predicate <1-6>]
20
+ npx --yes copilotkit@4.10.1 onboard proof --step oss-baseline --outcome <passed|failed|skipped> [--predicate <1-6>]
21
21
  ```
22
22
 
23
23
  Report the gate whatever it returned. Pass `passed` when the subagent proved a predicate,
@@ -35,12 +35,12 @@ Do not change project files before this proof ends. Starting existing developmen
35
35
  processes and their ignored runtime files is allowed.
36
36
 
37
37
  If the subagent proves the `both-oss` predicate, keep its evidence with the plan and run
38
- `npx --yes copilotkit@4.9.60 onboard read conversion/plan`. That project already works.
38
+ `npx --yes copilotkit@4.10.1 onboard read conversion/plan`. That project already works.
39
39
  What it needs is the conversion, not a build.
40
40
 
41
41
  If the proof does not establish the baseline, record the starting state
42
42
  `both-copilotkit-unproved` and run
43
- `npx --yes copilotkit@4.9.60 onboard read credentials/plan`. This prompt is served
43
+ `npx --yes copilotkit@4.10.1 onboard read credentials/plan`. This prompt is served
44
44
  whenever a project looks like an OSS integration, so a baseline that did not prove is an
45
45
  ordinary starting state rather than a failure. Keep the failing predicate with the plan.
46
46
 
@@ -54,4 +54,5 @@ and the plan preserves it rather than repeating it.
54
54
 
55
55
  If it cannot identify the running process safely, exposes a secret, or finds a baseline
56
56
  failure that cannot be classified, run
57
- `npx --yes copilotkit@4.9.60 onboard read unsupported/no-validated-path`.
57
+ `npx --yes copilotkit@4.10.1 onboard read stopped/run-failed`. None of those mean the
58
+ project is unsupported: they mean this run did not establish what it needed to.
@@ -1,7 +1,7 @@
1
1
  # Prove the user journey
2
2
 
3
3
  Do not do the proof work yourself. Spawn one proof subagent. Tell it to run
4
- `npx --yes copilotkit@4.9.60 onboard read subagent/prove-round-trip` first and follow the
4
+ `npx --yes copilotkit@4.10.1 onboard read subagent/prove-round-trip` first and follow the
5
5
  prompt it returns. If that read fails because the subagent cannot use the shell, stop that
6
6
  subagent. Run the same command yourself, then spawn a fresh subagent with the returned prompt
7
7
  and the same handoff. Give it the selected framework, frontend, model, approved plan, selected
@@ -14,6 +14,15 @@ drives the surface and cannot see your environment, so without that finding it s
14
14
  step discovering what you already know. A subagent told it has no control for the surface
15
15
  this frontend needs reports the skip outcome rather than looking for a way around it.
16
16
 
17
+ A run that cloned a starter is the exception. Tell that subagent to stop after
18
+ `verify --round-trip` and to open no browser. The cloned code is what this repository's
19
+ starter smoke jobs already drive on every change, so opening a browser re-proves in the
20
+ developer's run what those jobs prove before the starter ships, and it is the most
21
+ expensive step in this setup. `verify --round-trip` reads the answer back off the thread,
22
+ so it holds for every runtime mount and needs no browser. Give that subagent no browser or
23
+ device control, and record the surface outcome as skipped for a cloned starter rather than
24
+ as a missing capability: nothing was unavailable, the run declined to spend it.
25
+
17
26
  Give the subagent this guide for continued-development tools:
18
27
  https://docs.copilotkit.ai/build-with-agents.md
19
28
 
@@ -23,13 +32,13 @@ pass the time.
23
32
  Report each attempt at the journey as it ends, counting from one:
24
33
 
25
34
  ```text
26
- npx --yes copilotkit@4.9.60 onboard checkpoint --phase journey-attempted --attempt 1
35
+ npx --yes copilotkit@4.10.1 onboard checkpoint --phase journey-attempted --attempt 1
27
36
  ```
28
37
 
29
38
  Record what that proof returned before you route on it:
30
39
 
31
40
  ```text
32
- npx --yes copilotkit@4.9.60 onboard proof --step round-trip --outcome <passed|failed|skipped>
41
+ npx --yes copilotkit@4.10.1 onboard proof --step round-trip --outcome <passed|failed|skipped>
33
42
  ```
34
43
 
35
44
  Report the gate whatever it returned. A proof that never ran is `skipped`, not failed. The
@@ -37,7 +46,7 @@ command prints one line and sends nothing else. Where a repair cycle runs the pr
37
46
  record each attempt as it ends.
38
47
 
39
48
  For every protected-path audit in this prompt, run
40
- `npx --yes copilotkit@4.9.60 onboard audit` from the target app directory. If its result
49
+ `npx --yes copilotkit@4.10.1 onboard audit` from the target app directory. If its result
41
50
  starts with `Status: blocked`, report the printed reason and use the route-out rules below.
42
51
  A blocked audit proved nothing changed and is not a preservation failure. If a
43
52
  protected-path audit reports a changed path, decide it the way the implementation prompt
@@ -46,7 +55,7 @@ returns none, so a finding with no Files changed section to test against routes
46
55
  path one of those sections names is this run's own change and routes out too. Accept a
47
56
  path only when a section this run collected covers the step that wrote it and does not
48
57
  name it:
49
- `npx --yes copilotkit@4.9.60 onboard protect --accept-external --path <path>`. Then run
58
+ `npx --yes copilotkit@4.10.1 onboard protect --accept-external --path <path>`. Then run
50
59
  the audit again and name the path in the closing summary. Never repair, reset, or revert a
51
60
  protected path.
52
61
 
@@ -54,12 +63,12 @@ That holds for a repair cycle too. When the fix for a failing check lands on a p
54
63
  path, the path is still the developer's, however right the diagnosis is and however small
55
64
  the fix. Reading the file never settles who wrote it. Ask the developer to allow the
56
65
  change, and record their answer with
57
- `npx --yes copilotkit@4.9.60 onboard protect --authorize --unplanned --path <path> --reason "<what the developer said>"`,
66
+ `npx --yes copilotkit@4.10.1 onboard protect --authorize --unplanned --path <path> --reason "<what the developer said>"`,
58
67
  or route out. Never repair it, and never send it to a repair worker.
59
68
 
60
69
  If the proof result starts with `Status: passed`, run the protected-path audit. Continue to
61
70
  `proof/complete` only if that audit passes. After the audit passes, run
62
- `npx --yes copilotkit@4.9.60 onboard read proof/complete`. A performed surface outcome with
71
+ `npx --yes copilotkit@4.10.1 onboard read proof/complete`. A performed surface outcome with
63
72
  the full round trip is core success even if a continued-development tool fails. A skipped
64
73
  surface outcome still enters `proof/complete` so the CLI records the blocked result. Do not
65
74
  describe a skipped surface as proved. Keep the Skills and MCP results separate from the proof
@@ -115,7 +124,7 @@ Restart each project-owned process changed by the repair. Report the cycle, coun
115
124
  one:
116
125
 
117
126
  ```text
118
- npx --yes copilotkit@4.9.60 onboard checkpoint --phase repair-attempted --attempt 1
127
+ npx --yes copilotkit@4.10.1 onboard checkpoint --phase repair-attempted --attempt 1
119
128
  ```
120
129
 
121
130
  Then spawn a fresh proof subagent
@@ -133,21 +142,25 @@ and proof cycles.
133
142
 
134
143
  Route out only when the failure is not yours to fix, when the same proof still fails after
135
144
  three attempts, or when no evidence of the round trip can be produced. In those cases run
136
- `npx --yes copilotkit@4.9.60 onboard read unsupported/no-validated-path`. All three are
145
+ `npx --yes copilotkit@4.10.1 onboard read stopped/run-failed`. The stack is supported:
146
+ this run did not finish, which is a different ending and a different report. All three are
137
147
  about the round trip itself. A round trip that proved is not one of them, whatever failed
138
148
  after it.
139
149
 
140
150
  If you stop here without taking that route -- a repair cycle you cannot finish, a limit in
141
151
  your own harness, a run that has run out -- send one short report before you stop.
142
- Run the feedback command without another developer question. The CLI telemetry gate decides
152
+ Run the friction command without another developer question. The CLI telemetry gate decides
143
153
  whether the report is sent.
144
154
 
145
155
  ```text
146
- npx --yes copilotkit@4.9.60 onboard feedback
156
+ npx --yes copilotkit@4.10.1 onboard friction --phase stop --category <slug>
147
157
  ```
148
158
 
149
- Write at most four lines to standard input: the step you stopped at and what stopped it.
159
+ Write one or two sentences to standard input: the step you stopped at and what stopped it.
160
+ Pick the category that fits from docs-missing, docs-wrong, docs-sequential, cli-gap,
161
+ sdk-gap, environment, port-collision, credential, validation-loop, and other. Leave
162
+ --cost-seconds off. A run that stopped cannot separate one papercut's cost from the cost
163
+ of the whole run, so the estimate is optional on a stop report and only there.
150
164
  Send no secrets, source code, logs, or command output. The command refuses a report that
151
165
  carries any of those, prints the reason, and exits zero. A refused report is not a failed
152
- step. Report friction only from a run that finished, never from a stop. A run that dies in
153
- this phase is the one this graph most needs to hear about and the one it hears from least.
166
+ step. A run that dies in this phase is the one this graph most needs to hear about and the one it hears from least.
@@ -0,0 +1,121 @@
1
+ # Gather the evidence this run routes on
2
+
3
+ Sign-in is settled. This phase inspects the project and proves what this environment can
4
+ drive. Do not change application code here, and do not ask the developer a setup question
5
+ yet: every read-only investigation finishes first.
6
+
7
+ ## How to wait for a subagent
8
+
9
+ This rule covers every subagent this run spawns, here and in every later prompt.
10
+
11
+ Spawning a subagent returns almost at once. That return is the dispatch succeeding, not the
12
+ work finishing: the subagent runs in the background, and its result reaches you as a
13
+ notification. Where your own harness hands you the report from the dispatch itself instead,
14
+ you already hold the result. Either way there is nothing to poll.
15
+
16
+ After you dispatch, do the work that does not depend on the result -- dispatch the other
17
+ subagent, run the preflight below -- and then stop and wait. Wherever a prompt in this graph
18
+ says to wait for a subagent to finish, that is what it means.
19
+
20
+ Do not sleep to pass the time. Not `sleep`, not `/bin/sleep`, not a timer under another
21
+ name, and not a loop that re-checks whether a result has arrived. Sleeping tells you nothing
22
+ that waiting for the result does not, and it spends wall clock, which is one of the things
23
+ this journey is measured on. One recorded run spent most of two hours asleep between
24
+ dispatches that had all returned in seconds.
25
+
26
+ Before you ask the developer any setup question, finish every read-only investigation and
27
+ preflight check in this section.
28
+
29
+ Prepare two research assignments. Give each research subagent one assignment. Tell it to run
30
+ `npx --yes copilotkit@4.10.1 onboard read subagent/inspect-repository` first and follow the
31
+ prompt it returns. If that read fails because the subagent cannot use the shell, stop that
32
+ subagent. Run the same command yourself, then spawn a fresh subagent with the returned prompt
33
+ and the same handoff. Require only its assigned packet.
34
+
35
+ Start both research subagents in parallel:
36
+
37
+ 1. Spawn one research subagent. Assign it the project evidence packet.
38
+ 2. Spawn a second research subagent. Assign it the environment evidence packet.
39
+ 3. Start both research subagents. Then continue.
40
+
41
+ Continue to the surface-control preflight.
42
+
43
+ Prove whether your coding-agent environment has browser or device control. Do not assume it
44
+ either way, and do not report what you expect to be true: a run that guesses here records a
45
+ capability every later step then trusts. Use a browser or device tool already
46
+ configured for the coding agent you are running as, the same way a later step uses the
47
+ CopilotKit documentation server. With a browser tool, open one inert page such as
48
+ `about:blank` and read its title. With a device tool and no browser, list the booted devices
49
+ in one command: `adb devices -l`. Record the outcome of that attempt: `available` when the
50
+ tool answered, `unavailable` when there was none to call or the page did not open. Use
51
+ the control that matches the selected surface later.
52
+
53
+ Where the browser probe answered, register nothing. The harness came equipped and the run
54
+ owes it no setup.
55
+
56
+ Where no browser tool answered, register one for the coding agent you are running as, then
57
+ run the same probe again and record what the second attempt did. Register this server:
58
+
59
+ ```text
60
+ npx --yes @playwright/mcp@latest --browser chrome --isolated --output-dir <project>/.copilotkit/proof/browser
61
+ ```
62
+
63
+ Replace `<project>` with the absolute path of the target project directory. The server is
64
+ registered against the coding agent rather than against a directory, so a relative path here
65
+ resolves wherever that server happens to start.
66
+
67
+ `--browser chrome` drives the Google Chrome the developer already has, so this downloads no
68
+ browser. `--isolated` keeps the profile in memory, so it never touches their own Chrome
69
+ profile. `--output-dir` is what keeps the snapshots and screenshots out of the developer's
70
+ repository root: without it this server writes them to `.playwright-mcp/` beside their code,
71
+ which a project that never asked for a browser has no reason to carry, and which this setup's
72
+ own evidence rule already has a place for. Register it the way your own harness registers a
73
+ server, which is the mechanism a later step uses for the CopilotKit documentation server.
74
+
75
+ Tell the developer in one line what you registered, that it drives their installed Chrome,
76
+ and that it lives in this coding agent's configuration rather than in their repository. Do
77
+ not ask them to approve it, and do not ask a second question about it.
78
+
79
+ Do not add a browser or device driver to the project. A driver added there is a
80
+ devDependency and a browser download in the diff of a repository that never asked for one,
81
+ which is a different thing from a server registered against the coding agent.
82
+
83
+ Where the second probe still does not answer -- no Chrome to drive, no network, or a
84
+ harness that cannot register a server -- record `unavailable` and carry it. Do not keep
85
+ trying, and do not ask the developer about this tool limit.
86
+
87
+ Registering a server does not boot a device. Where the device probe found none, that is the
88
+ whole finding, and a browser is not a substitute for a device.
89
+
90
+ Wait for both research subagents to finish.
91
+
92
+ Then report that the research came back:
93
+
94
+ ```text
95
+ npx --yes copilotkit@4.10.1 onboard checkpoint --phase research-returned
96
+ ```
97
+
98
+ A refused checkpoint prints its reason and leaves onboarding unaffected. It is not a
99
+ failed step.
100
+
101
+ Continue only if both research results start with `Status: passed`. For `Status: failed`,
102
+ retry only that packet with its failed items, up to three attempts. For `Status: blocked`,
103
+ or a third failed result, use the stop route at the end of this prompt.
104
+
105
+ Merge both evidence packets by item. On a conflict, spawn one fresh read-only verifier with
106
+ the item, both cited findings, and the research limits. Require its result to start with
107
+ `Status: passed`, `Status: failed`, or `Status: blocked`. Use only a passed cited result. Do
108
+ not inspect the project to settle the conflict yourself. Use the stop route for a non-pass
109
+ verifier result.
110
+
111
+ Match environment evidence to the target app directory from the project packet. Require one
112
+ target app directory and one matching environment row. If either packet gives no match or
113
+ more than one match, send each research worker a focused directory check. Continue only when
114
+ both workers return the same one target app directory. Both results must start with
115
+ `Status: passed`. Otherwise, use the stop route.
116
+
117
+ When both research results are merged, run
118
+ `npx --yes copilotkit@4.10.1 onboard read research/route`.
119
+
120
+ If inspection stops onboarding, run
121
+ `npx --yes copilotkit@4.10.1 onboard read stopped/run-failed`.
@@ -0,0 +1,81 @@
1
+ # Capture the baseline and route on the findings
2
+
3
+ The merged research findings are in hand. This phase captures the protected-path baseline
4
+ before anything is written, checks that the findings answer what the route needs, and
5
+ sends the run down one path.
6
+
7
+ ## Capture the protected-path baseline
8
+
9
+ Before you route on, run this from the target app directory:
10
+
11
+ ```text
12
+ npx --yes copilotkit@4.10.1 onboard protect
13
+ ```
14
+
15
+ It reads the working tree itself, records every changed or untracked path with a digest,
16
+ and prints the list. Require its result to start with `Status: passed`.
17
+
18
+ Use the printed list as the protected path list for the rest of the run. Do not assemble
19
+ that list yourself, and do not ask a subagent to hold it: every later audit reads the
20
+ captured baseline back from the CLI, so no step depends on a subagent that has since
21
+ finished.
22
+
23
+ Paths printed as `deferred` are the ones onboarding itself writes, `.env` and
24
+ `.copilotkit/project.json`. Every audit reports them and none fails on them until the step
25
+ that writes them re-captures them, so a run whose only untracked files are the two this
26
+ graph exists to create is never stopped by them.
27
+
28
+ If the result starts with `Status: blocked`, report the printed reason and use the stop
29
+ route at the end of this prompt.
30
+
31
+ ## What the merged findings must contain
32
+
33
+ If a repository file exists, each finding must cite it. For an empty project, the subagents
34
+ must cite the directory check and report absent parts.
35
+
36
+ The findings must cover what the project is for, the agent, frontend, CopilotKit setup,
37
+ authentication, credential names, and validation path. Do not ask the developer for facts
38
+ that the repository answers.
39
+
40
+ ## Route on the merged findings
41
+
42
+ Read the route off the merged findings. Three of them decide it, and you already hold all
43
+ three:
44
+
45
+ 1. an agent is present,
46
+ 2. a frontend is present,
47
+ 3. a CopilotKit integration is present.
48
+
49
+ Do not infer a working OSS path from packages, imports, project files, or keys, and do not
50
+ settle these three from your own reading of the project. Each one comes from the merged
51
+ packets or it is not proved.
52
+
53
+ If all three are proved, prove the live starting state before any project file changes. Run
54
+ `npx --yes copilotkit@4.10.1 onboard read proof/oss-baseline`.
55
+
56
+ Route there before you ask the developer anything else. The questions after this prompt
57
+ select a framework and a frontend that the findings already name, so a developer who
58
+ answers them has answered for work the next node exists to check. Their existing
59
+ application is what that node protects. Whether it works is what the proof decides, not
60
+ these three findings.
61
+
62
+ For every other combination of the three, take one more step first. If neither the
63
+ developer nor the repository findings prove what the project is for, ask one guided
64
+ question about the user outcome. This asks what the developer wants to build before you
65
+ select a framework. Give two or three short examples and offer a minimal starter. Record
66
+ the answer and give it to each later subagent. Then run
67
+ `npx --yes copilotkit@4.10.1 onboard read credentials/plan`.
68
+
69
+ Do not ask that question on the route above. A project carrying all three states its
70
+ purpose in the application it already serves.
71
+
72
+ Do not ask it when the target directory holds no project either. A greenfield run clones a starter
73
+ the CLI ships, and that starter arrives carrying a working application of its own. The
74
+ answer cannot change which starter lands, because the starter follows from the framework
75
+ and frontend the developer selects next. Asking spends a turn on a decision the run has
76
+ already made, and then names a purpose the cloned code does not serve. Take the same read
77
+ named above without asking, and let the starter state the domain.
78
+
79
+ If authentication or inspection stops onboarding, run
80
+ `npx --yes copilotkit@4.10.1 onboard read stopped/run-failed`. Neither says anything
81
+ about whether this project's stack is supported, which is not yet known at this point.
@@ -1,8 +1,11 @@
1
1
  # Clone a starter
2
2
 
3
3
  Use this shortcut only when the repository findings prove that the target project
4
- directory contains no entries. If the directory contains a file or directory, do not use
5
- this shortcut.
4
+ directory holds no project yet: no source directory such as `src/`, `app/`, `agent/` or
5
+ `web/`, no dependency manifest such as `package.json` or `pyproject.toml`, and no `.env`.
6
+ A directory that holds only a Git repository, a coding agent's own configuration, editor
7
+ settings or scratch notes still qualifies. Those are not a project, and `git init` is the
8
+ marker this CLI anchors a run on, so it cannot also be the thing that disqualifies one.
6
9
 
7
10
  Match the selected agent framework and frontend to this table:
8
11
 
@@ -43,7 +46,7 @@ the derived name.
43
46
  Only if the developer asks for an existing project, or asks to see the projects they have,
44
47
  read the choices:
45
48
 
46
- `npx --yes copilotkit@4.9.60 project list --json`
49
+ `npx --yes copilotkit@4.10.1 project list --json`
47
50
 
48
51
  Then ask which one to use. Do not order the projects by creation time. If the developer
49
52
  already gave this answer, do not ask again. Do not read a secret value. Do not show or
@@ -53,7 +56,7 @@ Run the command from the parent directory. Do not inspect another entry in the p
53
56
  directory. Replace each placeholder with the recorded value. Do not run a placeholder as
54
57
  a shell argument.
55
58
 
56
- `npx --yes copilotkit@4.9.60 init --name <project-name> --framework <framework-id> --channel none --no-banner --create <name> --install`
59
+ `npx --yes copilotkit@4.10.1 init --name <project-name> --framework <framework-id> --channel none --no-banner --create <name> --install`
57
60
 
58
61
  Pass the confirmed name to both `--name` and `--create`: the app directory and its
59
62
  Intelligence project take the same name here. If the developer names an existing project,
@@ -66,17 +69,23 @@ The command clones the starter into the empty target directory. It also connects
66
69
  starter to the developer's Intelligence project. The earlier login phase supplies the
67
70
  account. The command does not need terminal input.
68
71
 
69
- If the command succeeds, do not rebuild the starter by hand. Report the clone first:
72
+ Report the clone before you inspect anything:
70
73
 
71
74
  ```text
72
- npx --yes copilotkit@4.9.60 onboard checkpoint --phase starter-cloned
75
+ npx --yes copilotkit@4.10.1 onboard checkpoint --phase starter-cloned
73
76
  ```
74
77
 
75
- Then inspect only the generated
78
+ This is its own step, not an aside. A run that clones and then goes quiet is
79
+ indistinguishable from a run that never cloned, and the checkpoint is the only thing that
80
+ separates them.
81
+
82
+ Do not rebuild the starter by hand. Then inspect only the generated
76
83
  paths inside the target directory. Record the files, install result, project connection,
77
84
  and validation commands. Then run
78
- `npx --yes copilotkit@4.9.60 onboard read proof/round-trip`.
85
+ `npx --yes copilotkit@4.10.1 onboard read proof/round-trip`.
79
86
 
80
87
  If the command fails, report its exact error and do not claim that the starter is ready.
81
88
  Then run
82
- `npx --yes copilotkit@4.9.60 onboard read unsupported/no-validated-path`.
89
+ `npx --yes copilotkit@4.10.1 onboard read stopped/run-failed`. The starter is one this
90
+ graph ships and the stack was chosen from its own supported list, so a command that
91
+ returned an error is a run that broke, not a setup this release does not support.
@@ -0,0 +1,44 @@
1
+ # Stop because the run did not finish
2
+
3
+ This is the ending for a run that broke. The developer's agent, frontend and package
4
+ choices are supported. Something in this run stopped it, and that is what the report has
5
+ to say.
6
+
7
+ Do not tell the developer their setup is unsupported. It is not, and a run that says so
8
+ sends them to change a stack that was never the problem.
9
+
10
+ Keep the developer's current agent, frontend, authentication, and package choices.
11
+
12
+ Name the exact step that stopped the run, and what it returned. State whether
13
+ authentication, project selection, project credentials, the journey, implementation,
14
+ validation, or the round trip stopped it. Give the failure in the words the step printed,
15
+ not a summary of them.
16
+
17
+ If a protected path stopped this run, name that path and how it changed, in the words the
18
+ audit printed. A report that says only that protected files changed cannot be acted on:
19
+ nobody reading it can tell which file moved, or whether this run or the developer moved
20
+ it.
21
+
22
+ Say what the developer has now. Name the processes still running and the files this run
23
+ changed, so they can carry on by hand or start again from a known state. A run that stops
24
+ without saying what it left behind leaves the developer to discover it.
25
+
26
+ Stop onboarding without making more repository changes.
27
+
28
+ Send one short report. Run the friction command without another developer question. The
29
+ CLI telemetry gate decides whether the report is sent.
30
+
31
+ ```text
32
+ npx --yes copilotkit@4.10.1 onboard friction --phase stop --category <slug>
33
+ ```
34
+
35
+ Write one or two sentences to standard input: the step you stopped at and what stopped
36
+ it. Pick the category that fits from docs-missing, docs-wrong, docs-sequential, cli-gap,
37
+ sdk-gap, environment, port-collision, credential, validation-loop, and other. Leave
38
+ --cost-seconds off. A run that stopped cannot separate one papercut's cost from the cost
39
+ of the whole run, so the estimate is optional on a stop report and only there.
40
+ Send no secrets, source code, logs, or command output. The command refuses a report that
41
+ carries any of those, prints the reason, and exits zero. A refused report is not a failed
42
+ step. Reword it and send it again, or stop without a report. The command prints what it
43
+ sent. This is the channel for a stop. If the CLI says the report was not sent, state what
44
+ it said and stop without another question.
@@ -23,6 +23,37 @@ SQLite, custom, or framework persistence can be durable. The two options cannot
23
23
  combined. Take the constructor from the connect-your-runtime page. Where a framework
24
24
  quickstart shows a `runner` option instead, the connect-your-runtime page wins.
25
25
 
26
+ ## Plan the Learning Container and its selector
27
+
28
+ The main coding agent gives you a Learning Container id, or tells you the Learning step was
29
+ skipped for this organization.
30
+
31
+ Where it gives you an id, plan two things and name both in the plan the developer approves:
32
+ the container id itself, and a `getLearningContainerId` callback returning that id on the
33
+ `CopilotKitIntelligence` instance. Take the callback from the Learning page, and fetch it
34
+ here rather than expecting the run to have handed it over:
35
+
36
+ ```text
37
+ https://docs.copilotkit.ai/learning.md
38
+ ```
39
+
40
+ Put the callback in the same runtime edit that connects Intelligence rather than in a step
41
+ of its own: it is one option on the same constructor, so a separate step names a second
42
+ change to a file the first step already changes.
43
+
44
+ Name the container before the selector, and name the id in both. A container nothing routes
45
+ to stays empty forever, so it buys a name and no learning. A selector pointing at an id the
46
+ platform does not hold answers `LEARNING_CONTAINER_NOT_FOUND` on every thread create, which
47
+ breaks a working chat on the next message.
48
+
49
+ Per-user routing is the developer's own selector logic rather than more containers. Do not
50
+ plan one container per end user: a project holds at most 500, the first automatic Learning
51
+ run needs threads from 15 distinct conversations in one container, and a container per
52
+ person needs those 15 conversations from that one person.
53
+
54
+ Where the Learning step was skipped, plan no container and no selector, and say in the plan
55
+ that Learning is not available to this organization.
56
+
26
57
  When the starting state is `both-oss`, use its recorded live baseline evidence. Preserve
27
58
  the working agent, frontend, CopilotKit integration, and OSS behavior. Plan the project
28
59
  selection, the CopilotKit dependency upgrade below, the Intelligence runtime
@@ -122,7 +153,7 @@ here is work the developer did not ask for.
122
153
  Plan the threads drawer itself: add it from the selected drawer page, where this frontend
123
154
  does not already render one. Where this journey's frontend framework ships no threads
124
155
  drawer -- React Native --, plan that the thread is proved by
125
- `npx --yes copilotkit@4.9.60 verify --round-trip`, which needs no browser. Do not plan a
156
+ `npx --yes copilotkit@4.10.1 verify --round-trip`, which needs no browser. Do not plan a
126
157
  step that opens the managed Intelligence dashboard.
127
158
 
128
159
  ## Order the plan into steps
@@ -110,8 +110,16 @@ project does not hold, and the rendered result looks the same either way.
110
110
  Run the full validation list. Record changed files, command results, and errors. Do not
111
111
  claim that the real user journey works in this phase.
112
112
 
113
+ Where the plan names a Learning Container id, set `getLearningContainerId` on the
114
+ `CopilotKitIntelligence` instance in the same edit that constructs the runtime with
115
+ `intelligence`. Return that one id for every run. Do not add a file, a step, or a second
116
+ constructor for it, and never write an id the plan does not name: a selector pointing at an
117
+ id the platform does not hold answers `LEARNING_CONTAINER_NOT_FOUND` on every thread create.
118
+ Where the plan names no container, write no selector.
119
+
113
120
  Report the runtime constructor you wrote. Name whether it passes `intelligence` or
114
- `runner`. A runtime built with `runner` is the SSE runtime and never reads the credential,
121
+ `runner`, and whether it carries `getLearningContainerId`, with the id it returns.
122
+ A runtime built with `runner` is the SSE runtime and never reads the credential,
115
123
  whatever the browser shows.
116
124
 
117
125
  Gather what you need in as few commands as possible. Combine independent reads into one
@@ -19,7 +19,7 @@ Prove the live runtime in this order:
19
19
  4. Confirm from project files that the runtime constructor passes a `runner` option rather
20
20
  than an `intelligence` option. A package, import, project file, or key is not use proof.
21
21
  5. Run
22
- `npx --yes copilotkit@4.9.60 verify --expect-runtime oss --round-trip --agent <expected-agent-id> --json`,
22
+ `npx --yes copilotkit@4.10.1 verify --expect-runtime oss --round-trip --agent <expected-agent-id> --json`,
23
23
  with the runtime URL or auth header options that this project needs. Require exit zero
24
24
  and the JSON `ok` field to be `true`.
25
25
  6. Drive one real request through the existing frontend, CopilotKit runtime, and expected