copilotkit 4.15.0 → 4.17.0

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 (81) hide show
  1. package/README.md +118 -10
  2. package/cli-build-info.json +8 -8
  3. package/index.js +24194 -3483
  4. package/onboarding/index.json +1 -1
  5. package/onboarding/prompts/authenticate/start.md +17 -15
  6. package/onboarding/prompts/conversion/plan.md +3 -3
  7. package/onboarding/prompts/credentials/finalize-plan.md +20 -20
  8. package/onboarding/prompts/credentials/plan.md +21 -21
  9. package/onboarding/prompts/credentials/settle-credentials.md +46 -10
  10. package/onboarding/prompts/credentials/write-plan.md +35 -20
  11. package/onboarding/prompts/fallback/best-effort.md +23 -15
  12. package/onboarding/prompts/feature/a2ui/implement.md +40 -12
  13. package/onboarding/prompts/feature/a2ui/proof.md +29 -9
  14. package/onboarding/prompts/feature/a2ui/start.md +8 -10
  15. package/onboarding/prompts/feature/blocked-by-plan.md +4 -4
  16. package/onboarding/prompts/feature/channels/implement.md +41 -13
  17. package/onboarding/prompts/feature/channels/proof.md +30 -11
  18. package/onboarding/prompts/feature/channels/start.md +11 -9
  19. package/onboarding/prompts/feature/chat-suggestions/implement.md +40 -12
  20. package/onboarding/prompts/feature/chat-suggestions/proof.md +29 -9
  21. package/onboarding/prompts/feature/chat-suggestions/start.md +8 -10
  22. package/onboarding/prompts/feature/complete.md +2 -2
  23. package/onboarding/prompts/feature/learning/implement.md +58 -26
  24. package/onboarding/prompts/feature/learning/proof.md +30 -10
  25. package/onboarding/prompts/feature/learning/start.md +15 -12
  26. package/onboarding/prompts/feature/open-generative-ui/implement.md +41 -13
  27. package/onboarding/prompts/feature/open-generative-ui/proof.md +29 -9
  28. package/onboarding/prompts/feature/open-generative-ui/start.md +8 -10
  29. package/onboarding/prompts/feature/realtime-sync/implement.md +41 -13
  30. package/onboarding/prompts/feature/realtime-sync/proof.md +31 -10
  31. package/onboarding/prompts/feature/realtime-sync/start.md +8 -9
  32. package/onboarding/prompts/feature/rich-threads/implement.md +42 -14
  33. package/onboarding/prompts/feature/rich-threads/proof.md +31 -10
  34. package/onboarding/prompts/feature/rich-threads/start.md +8 -9
  35. package/onboarding/prompts/feature/stop.md +3 -3
  36. package/onboarding/prompts/feature/voice/implement.md +40 -12
  37. package/onboarding/prompts/feature/voice/proof.md +29 -9
  38. package/onboarding/prompts/feature/voice/start.md +8 -9
  39. package/onboarding/prompts/framework/ag2.md +2 -2
  40. package/onboarding/prompts/framework/agno.md +4 -4
  41. package/onboarding/prompts/framework/built-in.md +2 -2
  42. package/onboarding/prompts/framework/claude-sdk-python.md +8 -7
  43. package/onboarding/prompts/framework/claude-sdk-typescript.md +2 -2
  44. package/onboarding/prompts/framework/crewai-flows.md +15 -7
  45. package/onboarding/prompts/framework/deep-agents.md +4 -3
  46. package/onboarding/prompts/framework/google-adk.md +7 -7
  47. package/onboarding/prompts/framework/langgraph-fastapi.md +2 -2
  48. package/onboarding/prompts/framework/langgraph-python.md +2 -2
  49. package/onboarding/prompts/framework/langgraph-typescript.md +2 -2
  50. package/onboarding/prompts/framework/llamaindex.md +4 -4
  51. package/onboarding/prompts/framework/mastra.md +2 -2
  52. package/onboarding/prompts/framework/ms-agent-dotnet.md +2 -2
  53. package/onboarding/prompts/framework/ms-agent-harness-dotnet.md +2 -2
  54. package/onboarding/prompts/framework/ms-agent-python.md +6 -6
  55. package/onboarding/prompts/framework/pydantic-ai.md +2 -2
  56. package/onboarding/prompts/framework/strands-python.md +4 -4
  57. package/onboarding/prompts/framework/strands-typescript.md +4 -4
  58. package/onboarding/prompts/frontend/angular.md +3 -3
  59. package/onboarding/prompts/frontend/nextjs.md +16 -3
  60. package/onboarding/prompts/frontend/plan.md +7 -7
  61. package/onboarding/prompts/frontend/react-native.md +2 -2
  62. package/onboarding/prompts/frontend/react-spa.md +2 -2
  63. package/onboarding/prompts/frontend/vue.md +2 -2
  64. package/onboarding/prompts/implementation/build-and-validate.md +67 -28
  65. package/onboarding/prompts/proof/complete.md +21 -14
  66. package/onboarding/prompts/proof/oss-baseline.md +16 -12
  67. package/onboarding/prompts/proof/round-trip.md +33 -22
  68. package/onboarding/prompts/research/gather.md +8 -7
  69. package/onboarding/prompts/research/merge.md +3 -3
  70. package/onboarding/prompts/research/preflight.md +4 -4
  71. package/onboarding/prompts/research/route.md +6 -6
  72. package/onboarding/prompts/starter/clone.md +30 -20
  73. package/onboarding/prompts/stopped/run-failed.md +15 -9
  74. package/onboarding/prompts/subagent/create-plan.md +15 -10
  75. package/onboarding/prompts/subagent/implement-and-validate.md +25 -11
  76. package/onboarding/prompts/subagent/inspect-repository.md +14 -6
  77. package/onboarding/prompts/subagent/prove-oss-baseline.md +11 -4
  78. package/onboarding/prompts/subagent/prove-round-trip.md +48 -14
  79. package/onboarding/prompts/unsupported/no-validated-path.md +2 -2
  80. package/package.json +1 -5
  81. package/release/release-tool.js +222 -46
@@ -45,7 +45,7 @@ mechanism a later step uses for the CopilotKit documentation server.
45
45
 
46
46
  Some coding agents, Claude Code among them, load a newly registered MCP server only at the
47
47
  next session start. Tell the developer in one line to expect one restart, then restart and
48
- re-bind with `npx --prefer-offline --yes copilotkit@4.15.0 onboard start --run <onboarding_run_id>`. That
48
+ re-bind with `npx --prefer-offline --yes copilotkit@4.17.0 onboard start --run <onboarding_run_id>`. That
49
49
  restart is a step here, not an error.
50
50
 
51
51
  Do not add a browser or device driver to the project. A driver added there is a
@@ -62,14 +62,14 @@ whole finding.
62
62
  Report that the probe settled, whichever way it came out:
63
63
 
64
64
  ```text
65
- npx --prefer-offline --yes copilotkit@4.15.0 onboard checkpoint --phase surface-probed
65
+ npx --prefer-offline --yes copilotkit@4.17.0 onboard checkpoint --phase surface-probed
66
66
  ```
67
67
 
68
68
  Then merge the research:
69
69
 
70
70
  ```text
71
- npx --prefer-offline --yes copilotkit@4.15.0 onboard read research/merge
71
+ npx --prefer-offline --yes copilotkit@4.17.0 onboard read research/merge
72
72
  ```
73
73
 
74
74
  If inspection stops onboarding, run
75
- `npx --prefer-offline --yes copilotkit@4.15.0 onboard read stopped/run-failed`.
75
+ `npx --prefer-offline --yes copilotkit@4.17.0 onboard read stopped/run-failed`.
@@ -9,7 +9,7 @@ sends the run down one path.
9
9
  Before you route on, run this from the target app directory:
10
10
 
11
11
  ```text
12
- npx --prefer-offline --yes copilotkit@4.15.0 onboard protect
12
+ npx --prefer-offline --yes copilotkit@4.17.0 onboard protect
13
13
  ```
14
14
 
15
15
  It reads the working tree itself, records every changed or untracked path with a digest,
@@ -41,7 +41,7 @@ On either, run this before you read the three findings below, and without asking
41
41
  purpose question:
42
42
 
43
43
  ```text
44
- npx --prefer-offline --yes copilotkit@4.15.0 onboard read feature/channels/start
44
+ npx --prefer-offline --yes copilotkit@4.17.0 onboard read feature/channels/start
45
45
  ```
46
46
 
47
47
  Name the provider to that node so it does not ask again. A Slack page names Slack. A Teams
@@ -96,7 +96,7 @@ settle these three from your own reading of the project. Each one comes from the
96
96
  packets or it is not proved.
97
97
 
98
98
  If all three are proved, prove the live starting state before any project file changes. Run
99
- `npx --prefer-offline --yes copilotkit@4.15.0 onboard read proof/oss-baseline`.
99
+ `npx --prefer-offline --yes copilotkit@4.17.0 onboard read proof/oss-baseline`.
100
100
 
101
101
  Route there before you ask the developer anything else. The questions after this prompt
102
102
  select a framework and a frontend that the findings already name, so a developer who
@@ -109,7 +109,7 @@ developer nor the repository findings prove what the project is for, ask one gui
109
109
  question about the user outcome. This asks what the developer wants to build before you
110
110
  select a framework. Give two or three short examples. Record the answer and give it to
111
111
  each later subagent. Then run
112
- `npx --prefer-offline --yes copilotkit@4.15.0 onboard read credentials/plan`.
112
+ `npx --prefer-offline --yes copilotkit@4.17.0 onboard read credentials/plan`.
113
113
 
114
114
  Do not ask that question on the route above. A project carrying all three states its
115
115
  purpose in the application it already serves.
@@ -122,6 +122,6 @@ Slack and Microsoft Teams are choices at that step.
122
122
  A purpose question here names a domain before that choice.
123
123
  Take the same read named above without asking.
124
124
 
125
- If authentication or inspection stops onboarding, run
126
- `npx --prefer-offline --yes copilotkit@4.15.0 onboard read stopped/run-failed`. Neither says anything
125
+ If authentication, inspection, or the baseline capture stops onboarding, run
126
+ `npx --prefer-offline --yes copilotkit@4.17.0 onboard read stopped/run-failed`. None of them says anything
127
127
  about whether this project's stack is supported, which is not yet known at this point.
@@ -37,11 +37,14 @@ Each Framework ID selects a starter that the CLI ships with Intelligence. Do not
37
37
  different pair from a similar name. AG2 does not use this shortcut because its starter does
38
38
  not include Intelligence.
39
39
 
40
- Get the target directory name from its path. The project name must contain 1 to 30
41
- lowercase letters, numbers, or hyphens. It must not start or end with a hyphen. If the
40
+ Get the target directory name from its path. The name can contain 1 to 100 letters,
41
+ numbers, spaces, dots, underscores, or hyphens, in any case. It must not be `.` or `..`,
42
+ start or end with a space, or end with a dot. `init` accepts the name of an existing empty
43
+ directory as it is, so a name such as `MyApp` is valid. Do not rename the directory. If the
42
44
  selected pair is not in the table, or the directory name is not valid, stop the shortcut.
43
- Do not run `init`. Treat this result as a failed shortcut and follow the final failure
44
- instruction in this prompt.
45
+ Do not run `init`. No command ran, so this is not a failed shortcut. Go back to the
46
+ `## Documentation` section of the frontend prompt you read before this one, and build the
47
+ project from its pages.
45
48
 
46
49
  If the developer did not name a project, create one for the app being
47
50
  cloned. This directory is new, so no existing project is already its own: take the project
@@ -52,7 +55,7 @@ the derived name.
52
55
  Only if the developer asks for an existing project, or asks to see the projects they have,
53
56
  read the choices:
54
57
 
55
- `npx --prefer-offline --yes copilotkit@4.15.0 project list --json`
58
+ `npx --prefer-offline --yes copilotkit@4.17.0 project list --json`
56
59
 
57
60
  Then ask which one to use. Do not order the projects by creation time. If the developer
58
61
  already gave this answer, do not ask again. Do not read a secret value. Do not show or
@@ -77,9 +80,9 @@ way bills a project nobody chose.
77
80
 
78
81
  Run the command from the parent directory. Do not inspect another entry in the parent
79
82
  directory. Replace each placeholder with the recorded value. Do not run a placeholder as
80
- a shell argument.
83
+ a shell argument. If the directory name holds a space, put it in double quotes.
81
84
 
82
- `npx --prefer-offline --yes copilotkit@4.15.0 init --name <directory-name> --framework <framework-id> --channel none --no-banner --no-key-prompt --create <name> --install`
85
+ `npx --prefer-offline --yes copilotkit@4.17.0 init --name <directory-name> --framework <framework-id> --channel none --no-banner --no-key-prompt --create <name> --install`
83
86
 
84
87
  `--name` is always the target directory name derived above, because `init` creates the
85
88
  app at `<parent>/<name>`. Any other value puts the app in a new folder beside the target,
@@ -91,6 +94,13 @@ the dependency install, use
91
94
  answer as a flag. `--no-key-prompt` stops `init` from asking for a model key. The `init`
92
95
  output still names each missing key as `Set <VARIABLE> in .env`.
93
96
 
97
+ If the developer named a key file, add `--model-key-file <key-file>` with the path they gave.
98
+ `init` copies only the variable the starter needs into the starter's own env file,
99
+ including `agent/.env` for the Microsoft Agent Framework Python starter. It prints the
100
+ variable name and never the value. Do not read or copy the key file yourself. If `init`
101
+ reports that it cannot read the model key file, it stopped before it cloned anything. Ask
102
+ the developer for the right path, or run the command again without the flag.
103
+
94
104
  The command clones the starter into the empty target directory. It also connects the
95
105
  starter to the developer's Intelligence project. The earlier login phase supplies the
96
106
  account. The command does not need terminal input.
@@ -98,7 +108,7 @@ account. The command does not need terminal input.
98
108
  Report the clone before you inspect anything:
99
109
 
100
110
  ```text
101
- npx --prefer-offline --yes copilotkit@4.15.0 onboard checkpoint --phase starter-cloned
111
+ npx --prefer-offline --yes copilotkit@4.17.0 onboard checkpoint --phase starter-cloned
102
112
  ```
103
113
 
104
114
  This is its own step, not an aside. A run that clones and then goes quiet is
@@ -111,6 +121,10 @@ and validation commands.
111
121
 
112
122
  ## Settle the model credential
113
123
 
124
+ The `init` output names each key it copied from a key file as
125
+ `Copied <VARIABLE> from the model key file into <file>`. A copied key is in place, so do
126
+ not check it. If the key file did not hold a variable, the output warns by name.
127
+
114
128
  The `init` output names each missing credential as `Set <VARIABLE> in .env`. For each
115
129
  one, check the starter's own `.env` without reading the value:
116
130
 
@@ -121,19 +135,15 @@ grep -c '^<VARIABLE>=.' <target>/.env
121
135
  `1` means the variable holds a value. `0` means it is empty or absent. The command prints
122
136
  a count and never the value.
123
137
 
124
- If the developer named a key file, copy that one variable from it into `<target>/.env`,
125
- in place of the empty line. Do not print either file, and do not print the value. Then
126
- run the check again.
127
-
128
- If a variable is still empty, ask the developer to add it to `<target>/.env` themselves.
138
+ If a variable is empty, ask the developer to add it to `<target>/.env` themselves.
129
139
 
130
140
  The two Microsoft Agent Framework starters keep their key outside `<target>/.env`, so
131
141
  `init` prints no `Set` line for them. Settle the key from the Model key column instead:
132
142
 
133
- - For the Python starter, run the same check for `OPENAI_API_KEY` against
134
- `<target>/agent/.env`. A missing file counts as `0`. If the developer named a key file,
135
- copy the variable into `<target>/agent/.env` the same way. If it is still empty, ask the
136
- developer to add it there themselves.
143
+ - For the Python starter, a key file passed to `init` fills `<target>/agent/.env`, and the
144
+ output says so. Otherwise, run the same check for `OPENAI_API_KEY` against
145
+ `<target>/agent/.env`. A missing file counts as `0`. If it is empty, ask the developer to
146
+ add it there themselves.
137
147
  - For the .NET starter, the key lives in `dotnet user-secrets`, and no check can read it
138
148
  without printing the value. Ask the developer to run
139
149
  `cd <target>/agent && dotnet user-secrets set OPENAI_API_KEY "<key>"` themselves, even
@@ -142,7 +152,7 @@ The two Microsoft Agent Framework starters keep their key outside `<target>/.env
142
152
  Then report the pause and end your turn:
143
153
 
144
154
  ```text
145
- npx --prefer-offline --yes copilotkit@4.15.0 onboard checkpoint --phase awaiting-developer
155
+ npx --prefer-offline --yes copilotkit@4.17.0 onboard checkpoint --phase awaiting-developer
146
156
  ```
147
157
 
148
158
  This is a pause, not a stop. Do not send a stop report, and do not take a stop route.
@@ -153,10 +163,10 @@ call.
153
163
 
154
164
  If no credential is missing, report no pause and continue.
155
165
 
156
- Then run `npx --prefer-offline --yes copilotkit@4.15.0 onboard read proof/round-trip`.
166
+ Then run `npx --prefer-offline --yes copilotkit@4.17.0 onboard read proof/round-trip`.
157
167
 
158
168
  If the command fails, report its exact error and do not claim that the starter is ready.
159
169
  Then run
160
- `npx --prefer-offline --yes copilotkit@4.15.0 onboard read stopped/run-failed`. The starter is one this
170
+ `npx --prefer-offline --yes copilotkit@4.17.0 onboard read stopped/run-failed`. The starter is one this
161
171
  graph ships and the stack was chosen from its own supported list, so a command that
162
172
  returned an error is a run that broke, not a setup this release does not support.
@@ -1,17 +1,17 @@
1
1
  # Stop because the run did not finish
2
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.
3
+ This is the ending for a run that broke. Something in this run stopped it, and that is
4
+ what the report has to say. This ending makes no judgment about the stack.
6
5
 
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.
6
+ Do not tell the developer their setup is unsupported. A run that says so sends them to
7
+ change a stack that was never shown to be the problem.
9
8
 
10
9
  Keep the developer's current agent, frontend, authentication, and package choices.
11
10
 
12
11
  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,
12
+ authentication, repository inspection, the protected-path baseline capture, the OSS baseline
13
+ proof, project selection, project credentials, the plan, the starter clone, the journey,
14
+ implementation, validation, or the round trip stopped it. Give the failure in the words the step printed,
15
15
  not a summary of them.
16
16
 
17
17
  If a protected path stopped this run, name that path and how it changed, in the words the
@@ -23,6 +23,12 @@ Say what the developer has now. Name the processes still running and the files t
23
23
  changed, so they can carry on by hand or start again from a known state. A run that stops
24
24
  without saying what it left behind leaves the developer to discover it.
25
25
 
26
+ A step can fail on a network error: `EAI_AGAIN`, `ECONNRESET`, `ETIMEDOUT`, a timeout,
27
+ or a message that names a proxy. The CLI has already tried that step again. Ask the
28
+ developer to check their network, VPN, or proxy setting. This fix needs no file changes.
29
+ When the network works, propose it as the one fix below, and come back with
30
+ `onboard resume`.
31
+
26
32
  ## If one scoped fix can finish this run
27
33
 
28
34
  Do not decide this yourself. This run refused to widen its own scope, and that refusal
@@ -35,7 +41,7 @@ put to them, stop here and send the report below.
35
41
  If they approve it, make that one fix and nothing else. Then come back into this run:
36
42
 
37
43
  ```text
38
- npx --prefer-offline --yes copilotkit@4.15.0 onboard resume --message "<approval>"
44
+ npx --prefer-offline --yes copilotkit@4.17.0 onboard resume --message "<approval>"
39
45
  ```
40
46
 
41
47
  Put the developer's approval in `--message`, in one or two sentences: the fix they
@@ -58,7 +64,7 @@ Send one short report. Run the friction command without another developer questi
58
64
  ask the developer about telemetry: the command applies the setting they already have.
59
65
 
60
66
  ```text
61
- npx --prefer-offline --yes copilotkit@4.15.0 onboard friction --phase stop --category <slug> --message "<sentences>"
67
+ npx --prefer-offline --yes copilotkit@4.17.0 onboard friction --phase stop --category <slug> --message "<sentences>"
62
68
  ```
63
69
 
64
70
  `--message` takes one or two sentences: the step you stopped at and what stopped
@@ -37,8 +37,9 @@ Plan the runtime to consume the Intelligence credential. The runtime takes an
37
37
  `runner` option instead is the OSS runtime. It never reads the Intelligence key, and the
38
38
  Inspector reads the project as locked. The default in-memory OSS runner is ephemeral.
39
39
  SQLite, custom, or framework persistence can be durable. The two options cannot be
40
- combined. Take the constructor from the connect-your-runtime page. Where a framework
41
- quickstart shows a `runner` option instead, the connect-your-runtime page wins.
40
+ combined. Take the constructor from the Intelligence quickstart
41
+ (https://docs.copilotkit.ai/intelligence/quickstart.md). Where a framework quickstart
42
+ shows a `runner` option instead, the Intelligence quickstart wins.
42
43
 
43
44
  ## Plan the Learning Container and its selector
44
45
 
@@ -106,12 +107,14 @@ The intersection includes what a `@copilotkit/*` package on its own version line
106
107
  about the `1.x` line. `@copilotkit/angular` is the one that has this, and its declaration
107
108
  is materialized at publish time rather than written in the repository, so read it from the
108
109
  registry rather than from any checkout. Where it cannot be satisfied by the version the
109
- floor requires, there is no upgrade to plan: that is `unsupported/no-validated-path`.
110
+ floor requires, there is no upgrade to plan: return `Status: blocked` and name
111
+ `unsupported/no-validated-path` as the outcome.
110
112
 
111
113
  An exact pin is usually deliberate. Naming the move here is what makes it a step the
112
114
  developer approved rather than a repair the run invents halfway through. Do not move a pin
113
- the developer did not approve moving. Where the developer needs one held, that is
114
- `unsupported/no-validated-path`, and the upgrade step's revert is the way back.
115
+ the developer did not approve moving. Where the developer needs one held, return
116
+ `Status: blocked` and name `unsupported/no-validated-path` as the outcome. The upgrade
117
+ step's revert is the way back.
115
118
 
116
119
  Name the exact version the target requires. A caret does not stand in for it below `0.1.0`:
117
120
  `^0.0.59` admits only `0.0.59`, so a pin rewritten that way is the same pin under a
@@ -136,8 +139,9 @@ If the value of the journey depends on data the project already holds, name that
136
139
  name where it lives, and name how it reaches the agent. Rendering a list in the DOM does
137
140
  not give the agent access to it. An agent wired without the page's data answers from
138
141
  entities it invents, and the answer looks correct. Take the frontend-context step from
139
- the selected documentation. Where no selected page documents it for this framework or
140
- frontend, record that as a documentation gap rather than guessing the API.
142
+ the selected documentation, and never guess the API. Where no selected page documents it
143
+ for this framework or frontend, the data has no documented way to reach the agent: return
144
+ `Status: blocked` and name `unsupported/no-validated-path` as the outcome.
141
145
 
142
146
  Where that data exists, name the entities the proof compares against: the ids, names, or
143
147
  records the project holds and the answer has to reference. Where the outcome references
@@ -170,7 +174,7 @@ here is work the developer did not ask for.
170
174
  Plan the threads drawer itself: add it from the selected drawer page, where this frontend
171
175
  does not already render one. Where this journey's frontend framework ships no threads
172
176
  drawer -- React Native --, plan that the thread is proved by
173
- `npx --prefer-offline --yes copilotkit@4.15.0 verify --round-trip`, which needs no browser. Do not plan a
177
+ `npx --prefer-offline --yes copilotkit@4.17.0 verify --round-trip`, which needs no browser. Do not plan a
174
178
  step that opens the managed Intelligence dashboard.
175
179
 
176
180
  ## Order the plan into steps
@@ -193,8 +197,9 @@ feature to an app the developer already built is the case this exists for: the o
193
197
  in a file they wrote, and on an app whose work was never committed that file is in the
194
198
  baseline. List every such path under `Authorization requested`, one line each, with the path
195
199
  and one sentence saying what the step changes there and why no other file will do. Keep the
196
- step in the plan. Return `Status: blocked` only when the plan needs a protected path you
197
- cannot justify in that sentence.
200
+ step in the plan. Where a protected path you can justify is the only obstacle, the step
201
+ stays. Where the plan needs a protected path you cannot justify in that sentence, return
202
+ `Status: blocked`.
198
203
 
199
204
  Authorization covers changing a protected path, not removing it. Do not plan the deletion
200
205
  of a protected path, and do not plan a step that moves or renames one, which removes it
@@ -3,15 +3,26 @@
3
3
  Implement every step of the approved plan in plan order, and run the full validation list.
4
4
  Do not repeat the full repository inspection.
5
5
 
6
- Do not change a protected path. Do not delete, move, or rename one either, whatever the
7
- plan says: a protected path that is gone fails the audit and no command clears that.
8
- Do not change a path that overlaps a protected path. Paths overlap when they are equal or
6
+ Do not change a protected path unless it is on the authorized list the main coding agent
7
+ gave you. That list comes from the CLI, which recorded the developer's consent for each
8
+ path on it. An authorization covers that exact path only, not an ancestor directory and not
9
+ a file inside it. Never delete, move, or rename a protected path, authorized or not,
10
+ whatever the plan says: a protected path that is gone fails the audit and no command
11
+ clears that. Do not change a path that overlaps a protected path. An authorized path
12
+ itself is the one exception. Paths overlap when they are equal or
9
13
  either path is an ancestor directory on a path-segment boundary. `apps/a` overlaps
10
14
  `apps/a/src`, but not `apps/ab`. `app.ts` does not overlap `app.tsx`.
11
15
 
12
- Change only the files and directories the approved plan names as changeable. If the work
13
- requires a file the plan does not name, return the blocker and end your turn. Do not run a
14
- repository-wide formatter.
16
+ Change only the files and directories the approved plan names as changeable. A path on
17
+ the authorized list counts as one the plan names, and so does a path the main coding agent
18
+ adds to your handoff as one the developer approved. Two kinds of file outside that list are
19
+ departures, not blockers. The first is a file that has the same role as a planned file at a
20
+ different path, for example `app/page.tsx` for a planned `src/app/page.tsx`. The second is
21
+ the documentation file this prompt tells you to write. Mark each departure in Files
22
+ changed: the path the plan named, if any, the path you changed, and why. Neither kind
23
+ covers a protected path. If the work requires any other file the plan does not name, return
24
+ `Status: blocked`, name the file and why the work needs it under Blockers, and end your
25
+ turn. Do not run a repository-wide formatter.
15
26
 
16
27
  All implementation work happens in the run root's own working tree: the target app
17
28
  directory the main coding agent named. Never work in a separate worktree, a branch
@@ -21,10 +32,12 @@ completion step verifies that the changed files exist in this project, so work l
21
32
  another tree ends the run with nothing in the developer's hands.
22
33
 
23
34
  Before validation, read the protected path list. Inspect the current changed and untracked
24
- paths. Keep protected paths out of the run path set. Compare every changed path with the
35
+ paths. Keep protected paths out of the run path set, except the authorized paths, which
36
+ belong in it. Compare every changed path with the
25
37
  paths the plan named. Here, a changed path means one in the run path set. If a changed path
26
- is outside them, return `Status: blocked` before validation. Run the approved validation
27
- commands one at a time. Fix validation and proof defects only in the paths the plan named.
38
+ is outside them and is not a departure you marked, return `Status: blocked` before
39
+ validation. Run the approved validation commands one at a time. Fix validation and proof
40
+ defects only in the paths the plan named and the departures you marked.
28
41
 
29
42
  Use only the approved plan and the selected documentation URLs. Follow the documentation
30
43
  policy the main coding agent gives you before you change the project.
@@ -61,7 +74,7 @@ to bypass this rule.
61
74
 
62
75
  If the scaffolder cannot preserve a protected file, generate into a temporary directory
63
76
  inside the project only when the approved plan permits it. Copy only approved paths that
64
- do not overlap a protected path. Otherwise, return the conflict and end your turn before
77
+ do not overlap a protected path. A path on the authorized list is the one exception. Otherwise, return the conflict and end your turn before
65
78
  running the scaffolder. Ask the main coding agent to revise credential setup when a
66
79
  required variable is missing. Do not provision another key to repair a scaffold overwrite.
67
80
 
@@ -83,7 +96,8 @@ change, and the check that asked for it. Do not edit the agent's prompt to make
83
96
  component render.
84
97
 
85
98
  An existing `README.md` is the developer's, not this run's. Leave it exactly as you found
86
- it: not the title, not a section, not a line. Where this run has documentation to write,
99
+ it: not the title, not a section, not a line. The one exception is a README on the
100
+ authorized list. Where this run has documentation to write,
87
101
  write it to a new file and name that file when you report the result. On an empty project
88
102
  the README is the whole of the brief -- the only place the developer said what they
89
103
  wanted, and the thing they read this run's result against -- so the rule binds hardest
@@ -7,15 +7,21 @@ Work only on the packet you were assigned. Inspect the repository without changi
7
7
  Run this first, from the target project directory:
8
8
 
9
9
  ```text
10
- npx --prefer-offline --yes copilotkit@4.15.0 onboard inspect --json
10
+ npx --prefer-offline --yes copilotkit@4.17.0 onboard inspect --json
11
11
  ```
12
12
 
13
13
  It answers the deterministic half of both packets exactly, from the same code
14
14
  `copilotkit verify` uses: the project record by presence, and, for each app or runtime
15
15
  directory on its own, the env files, which variable carries the Intelligence key and which
16
16
  file it came from, whether that directory's own process can load it, the package manager
17
- its lockfile proves, the port it declares, and the exact installed version of every
18
- `@copilotkit/*` dependency. It reads only and prints no secret value.
17
+ its lockfile proves, the port it declares, the exact installed version of every
18
+ `@copilotkit/*` dependency, and every provider base URL its process will read. It reads
19
+ only and prints no secret value.
20
+
21
+ Report each `providerEndpoints` entry with the variable, its origin, and where it came
22
+ from. A `null` `source` means the process environment supplied it. A coding agent's shell
23
+ passes that value on to every dev server it starts, so it decides where the model calls
24
+ go before any project file does. Carry its `warning` as it came back.
19
25
 
20
26
  Carry those readings into your findings as they came back. Do not work one of them out
21
27
  again by reading files. The directory that owns `.env` is the hard case and the CLI holds
@@ -43,7 +49,7 @@ Find evidence for:
43
49
  Return the initial changed and untracked paths as paths only. Do not return their
44
50
  contents. Do not retain a before-state for them. The CLI captures the baseline that the
45
51
  protected-path audit compares against, so nothing later in the run depends on this
46
- subagent still existing, and a path that can hold secrets is captured as a digest you
52
+ subagent still holding its state, and a path that can hold secrets is captured as a digest you
47
53
  never read.
48
54
 
49
55
  Take the target app or runtime directory from the CLI packet rather than working it out
@@ -53,7 +59,8 @@ reading of the files will not reproduce.
53
59
  ## Environment evidence packet
54
60
 
55
61
  - names of required credential variables, beyond the Intelligence key the CLI reported
56
- - retain the `.env` modification time for a later comparison without returning it
62
+ - the `.env` modification time, or that no `.env` exists, for a later comparison. It is a
63
+ timestamp, not a value from the file
57
64
  - required toolchains and their installed versions
58
65
  - whether each port the CLI reported as declared is free
59
66
  - whether the runtime constructor uses a `runner` option, an `intelligence` option, or
@@ -85,6 +92,7 @@ access or an environment limit prevents the inspection.
85
92
  Return one row for each assigned item with its status, evidence path, and a short finding.
86
93
  Use only `proved`, `absent`, or `unproved` for the status. State each absent or unproved item.
87
94
  Do not read, print, or return secret values. For `.env` and `.copilotkit/project.json`
88
- checks, return only paths, presence checks, and missing field names. Do not read a file
95
+ checks, return only paths, presence checks, missing field names, and the one `.env`
96
+ modification time named above. Do not read a file
89
97
  outside the project directory. Do not run or return an onboarding command other than
90
98
  `onboard inspect`. End your turn after returning the findings to the main coding agent.
@@ -7,6 +7,12 @@ Find the expected agent id from the project. Start the existing agent and fronte
7
7
  when they are not already running. Before using a port, identify its process and working
8
8
  directory. Do not stop a process outside this project.
9
9
 
10
+ `next dev` locks its build directory, not its port. Next 16 writes `.next/dev/lock`. A
11
+ second `next dev` in the same app exits with `Unable to acquire lock at ..., is another
12
+ instance of next dev running?`. A free port does not help. If a `next dev` process already
13
+ runs from this app, reuse that server. Prove against its port. If a start still fails with
14
+ that message, name the process that holds the lock. Give its PID and working directory.
15
+
10
16
  If your harness runs commands in a sandbox, a sandboxed command cannot listen on a port or
11
17
  connect to localhost. Before the first server start, request escalation with a prefix rule
12
18
  for the project's own dev script. Before the first request to a local server, request
@@ -26,7 +32,7 @@ Prove the live runtime in this order:
26
32
  4. Confirm from project files that the runtime constructor passes a `runner` option rather
27
33
  than an `intelligence` option. A package, import, project file, or key is not use proof.
28
34
  5. Run
29
- `npx --prefer-offline --yes copilotkit@4.15.0 verify --expect-runtime oss --round-trip --agent <expected-agent-id> --json`,
35
+ `npx --prefer-offline --yes copilotkit@4.17.0 verify --expect-runtime oss --round-trip --agent <expected-agent-id> --json`,
30
36
  with the runtime URL or auth header options that this project needs. Require exit zero
31
37
  and the JSON `ok` field to be `true`.
32
38
  6. Drive one real request through the existing frontend, CopilotKit runtime, and expected
@@ -40,9 +46,10 @@ asked for one, which is a different thing from a server registered against the c
40
46
  Where the recorded control is `unavailable`, record predicate 6 as skipped, with that as the
41
47
  reason, and prove the rest.
42
48
 
43
- Classify the state as `both-oss` when predicates 1 to 5 are all true. Predicate 5 proves the
44
- CopilotKit round trip from a shell, so those five settle the starting state on their own.
45
- Predicate 6 adds the user-visible surface on top of a state already proved: record it as
49
+ Classify the state as `both-oss` when predicates 1 to 5 are all true and predicate 6 did
50
+ not fail. Predicate 5 proves the
51
+ CopilotKit round trip from a shell, so a skipped predicate 6 leaves those five to settle
52
+ the starting state. Predicate 6 adds the user-visible surface on top of a state already proved: record it as
46
53
  passed, failed, or skipped, and do not withhold `both-oss` for a skip. A failed predicate 6
47
54
  on an available surface is a baseline failure and is not a skip. Return each predicate and
48
55
  its secret-safe evidence.
@@ -5,7 +5,8 @@ policy the main coding agent gives you before you start.
5
5
 
6
6
  During Steps 1 through 8, do not edit source files, configuration files, dependencies, or
7
7
  tracked files.
8
- You can make only operational repairs to project-owned processes, ports, and request options.
8
+ You can make only operational repairs to project-owned processes, ports, and request options,
9
+ and the credential write that Step 4 names for `api_key_loadable_by_app`.
9
10
  Do not write a path that overlaps a protected path. If a required proof or tool path
10
11
  overlaps one, return `Status: blocked` before writing it.
11
12
 
@@ -24,8 +25,13 @@ different sequence of your own, and do not drop a step because an earlier one lo
24
25
  convincing. Step 6 has a web form and a React Native form: run the one that matches this
25
26
  journey's frontend, and run only that one.
26
27
 
28
+ A run that cloned a starter is the one exception. When the main coding agent tells you
29
+ that this run cloned a starter, run Steps 1 through 5 up to and including the
30
+ `verify --round-trip` command, then go to Step 10. Skip Steps 5a through 9, open no browser
31
+ or device, and report `skipped-cloned-starter` as the surface-check outcome.
32
+
27
33
  Where this is a second attempt after a repair, run every step from Step 2 through Step 7
28
- again. The repair changed tracked files and restarted processes, so the wiring, the agent
34
+ again, or through the Step 5 `verify --round-trip` command for a cloned-starter run. The repair changed tracked files and restarted processes, so the wiring, the agent
29
35
  identity, and both preconditions are stale. Step 1 is the exception, and it is carried
30
36
  rather than derived a second time. Compare the Step 5a and Step 5b results against the
31
37
  failed attempt's before you drive the surface. A repair that leaves the failed precondition
@@ -89,6 +95,16 @@ agent and the frontend from one `dev` script, which runs them under
89
95
  other. A second start against a project already running that script collides with a server
90
96
  that is up.
91
97
 
98
+ `next dev` locks its build directory, not its port. Next 16 writes `.next/dev/lock`. A
99
+ second `next dev` in the same app exits with `Unable to acquire lock at ..., is another
100
+ instance of next dev running?`. A free port does not help.
101
+
102
+ Before you start a Next.js frontend, look for a `next dev` process that runs from this app.
103
+ If one runs, reuse that server. Read its port from its command line or its listener, and
104
+ prove against that port. If a start still fails with that message, name the process that
105
+ holds the lock. Give its PID and working directory. Do not stop it unless it belongs to
106
+ this project.
107
+
92
108
  If your harness runs commands in a sandbox, a sandboxed command cannot listen on a port or
93
109
  connect to localhost. Before the first server start, request escalation with a prefix rule
94
110
  for the project's own dev script. Before the first request to a local server, request
@@ -147,7 +163,7 @@ IPv6 only, so an IPv4 literal fails against the correct port.
147
163
  ## Step 4 -- Check the wiring
148
164
 
149
165
  With both running, check the wiring in one command before you open a browser:
150
- `npx --prefer-offline --yes copilotkit@4.15.0 verify --json`. It reads the port from this project, so a
166
+ `npx --prefer-offline --yes copilotkit@4.17.0 verify --json`. It reads the port from this project, so a
151
167
  non-default port needs no flag. The payload reports `runtimeUrl` and `runtimeUrlSource`. A
152
168
  `runtimeUrlSource` of `default` means nothing in the project named a port, so pass
153
169
  `--runtime-url` with the URL from step 1 in that case. Read the individual checks rather than
@@ -181,7 +197,7 @@ named no port the CLI can read: keep step 2's URL, and rewrite its host as `loca
181
197
  before you use it.
182
198
 
183
199
  Then run the command once more with the URL you are about to open:
184
- `npx --prefer-offline --yes copilotkit@4.15.0 verify --frontend-url <that url> --json`. The
200
+ `npx --prefer-offline --yes copilotkit@4.17.0 verify --frontend-url <that url> --json`. The
185
201
  `frontend_assets_served` check asks that server for its page and for one of the page's own
186
202
  assets, on that exact host. A `fail` there means the dev server refuses its own static
187
203
  assets on the host you were about to use, and the check names the URL to use instead. This
@@ -189,7 +205,7 @@ is the cheapest step that can save the most expensive one, so run it before the
189
205
 
190
206
  ## Step 5 -- Prove that the agent runs
191
207
 
192
- Run `npx --prefer-offline --yes copilotkit@4.15.0 verify --round-trip --json`. It sends one request through
208
+ Run `npx --prefer-offline --yes copilotkit@4.17.0 verify --round-trip --json`. It sends one request through
193
209
  the runtime and reads the answer back from the thread, so it separates an agent that is
194
210
  configured from an agent that works. Use `--agent <id>` when the runtime declares more
195
211
  than one. If it reports `user-not-identified`, this project's `identifyUser` reads a
@@ -202,7 +218,7 @@ Where this run settled a Learning Container, add the flag to the call above rath
202
218
  running a second round trip:
203
219
 
204
220
  ```text
205
- npx --prefer-offline --yes copilotkit@4.15.0 verify --round-trip --expect-learning-container <container id> --json
221
+ npx --prefer-offline --yes copilotkit@4.17.0 verify --round-trip --expect-learning-container <container id> --json
206
222
  ```
207
223
 
208
224
  The check reads the thread that this run created, so a second round trip proves a second
@@ -236,7 +252,7 @@ the credential was written holds an empty key while the file beside it carries t
236
252
  one. Run this from the target app directory:
237
253
 
238
254
  ```text
239
- npx --prefer-offline --yes copilotkit@4.15.0 onboard env-staleness
255
+ npx --prefer-offline --yes copilotkit@4.17.0 onboard env-staleness
240
256
  ```
241
257
 
242
258
  A `stale` line names the env file and how long after launch it was written. Report that,
@@ -246,6 +262,21 @@ process and never its owner, and one project's dev script often serves the agent
246
262
  frontend together. Editing a file to answer a 401 that a restart clears changes the project
247
263
  for a fault it does not have.
248
264
 
265
+ Where the runtime answers with a 404 from the model provider, check the base URLs the
266
+ processes inherited before you change anything. A coding agent's shell passes its own
267
+ environment on to every process it starts, so a provider base URL exported for the agent
268
+ reaches the dev servers. Run this from the target app directory:
269
+
270
+ ```text
271
+ npx --prefer-offline --yes copilotkit@4.17.0 onboard inspect --json
272
+ ```
273
+
274
+ Read `providerEndpoints` for the app directory. An entry with a `null` `source` came from
275
+ the process environment rather than from a project file. A `warning` names why that value
276
+ fails. Report the variable, where it came from, and the warning, and say that the server
277
+ has to start from an environment without that value before the 404 means anything. Do not
278
+ edit a project file to answer it: the value lives in the shell, not in the project.
279
+
249
280
  ### Step 5a -- Prove that the page's data reaches the model
250
281
 
251
282
  `verify --round-trip` sends `context: []` and asks a question that needs no context. It
@@ -308,13 +339,14 @@ holds. Streamed text alone is not this step's outcome, whatever it says.
308
339
  This is the step that covers realtime delivery, the frontend provider being wired to this
309
340
  runtime, and the component actually rendering, and no command-line check reaches any of
310
341
  them. It is not optional polish: a run that skips it has proven the agent and not the
311
- journey, and such a run ends as blocked rather than complete.
342
+ journey, and such a run ends as blocked rather than complete. The cloned-starter skip is
343
+ the one exception, and it completes the run.
312
344
 
313
345
  For a recorded `both-oss` starting state, this step has no component to render. Send the
314
346
  same request the baseline recorded, require the same kind of user-visible result the
315
347
  baseline produced, and require that the thread for that request is listed in the drawer.
316
348
  Where this journey's frontend framework ships no threads drawer -- React Native --, prove
317
- that thread with `npx --prefer-offline --yes copilotkit@4.15.0 verify --round-trip`, which reads the
349
+ that thread with `npx --prefer-offline --yes copilotkit@4.17.0 verify --round-trip`, which reads the
318
350
  answer back off the thread and needs no browser. Record which of the two you proved.
319
351
 
320
352
  Use the surface control the main coding agent recorded for your environment. It either had
@@ -342,7 +374,7 @@ request never exercises. Drive it with the browser control step 6 named.
342
374
  the page to finish loading. Do not retype the host, and do not substitute a URL a tool
343
375
  offers you by default. Where the page loads but its styling is missing or the chat
344
376
  control is dead, run
345
- `npx --prefer-offline --yes copilotkit@4.15.0 verify --frontend-url <the url you opened> --json`
377
+ `npx --prefer-offline --yes copilotkit@4.17.0 verify --frontend-url <the url you opened> --json`
346
378
  before you diagnose anything else. A dev server can serve its page and refuse every
347
379
  static chunk behind it, and on screen that is indistinguishable from a broken
348
380
  integration. The `frontend_assets_served` check tells the two apart.
@@ -367,8 +399,9 @@ request never exercises. Drive it with the browser control step 6 named.
367
399
  the answer from, and what that element showed.
368
400
 
369
401
  Report exactly one of `performed`, `skipped-no-browser-tool`, `skipped-cloned-starter`, or
370
- `failed` for a web frontend. Report `skipped-cloned-starter` when this prompt told you to
371
- open no browser because the run cloned a starter.
402
+ `failed` for a web frontend. Report `skipped-cloned-starter` when the main coding agent told
403
+ you to open no browser because the run cloned a starter. The cloned-starter exception above
404
+ Step 1 says which steps to run.
372
405
 
373
406
  ### Step 6b -- React Native
374
407
 
@@ -485,8 +518,9 @@ whatever these two tools did.
485
518
 
486
519
  Start with `Status: passed`, `Status: failed`, or `Status: blocked`.
487
520
  Use `Status: passed` when the proof attempt completed with `performed`,
488
- `skipped-no-browser-tool`, or `skipped-no-device`. The parent records a skip through the
489
- standard blocked completion route. Use `Status: failed` for a failed proof step. Use
521
+ `skipped-no-browser-tool`, `skipped-no-device`, or `skipped-cloned-starter`. The parent
522
+ records a skip through the standard completion route, which ends every skip but
523
+ `skipped-cloned-starter` as blocked. Use `Status: failed` for a failed proof step. Use
490
524
  `Status: blocked` when a safety or access limit stops the attempt before a surface outcome.
491
525
  Return the proof or the exact failed step to the main coding agent, together with the
492
526
  input, the visible result, the relevant process status, the evidence locations, the