copilotkit 4.9.0 → 4.9.2

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 (46) hide show
  1. package/README.md +24 -0
  2. package/cli-build-info.json +7 -7
  3. package/index.js +559 -96
  4. package/onboarding/index.json +10 -0
  5. package/onboarding/prompts/authenticate/start.md +43 -17
  6. package/onboarding/prompts/credentials/finalize-plan.md +62 -14
  7. package/onboarding/prompts/credentials/plan.md +26 -20
  8. package/onboarding/prompts/fallback/best-effort.md +10 -3
  9. package/onboarding/prompts/framework/ag2.md +2 -2
  10. package/onboarding/prompts/framework/agno.md +2 -2
  11. package/onboarding/prompts/framework/built-in.md +2 -2
  12. package/onboarding/prompts/framework/claude-sdk-python.md +2 -2
  13. package/onboarding/prompts/framework/claude-sdk-typescript.md +2 -2
  14. package/onboarding/prompts/framework/crewai-flows.md +2 -2
  15. package/onboarding/prompts/framework/deep-agents.md +2 -2
  16. package/onboarding/prompts/framework/google-adk.md +2 -2
  17. package/onboarding/prompts/framework/langgraph-fastapi.md +2 -2
  18. package/onboarding/prompts/framework/langgraph-python.md +2 -2
  19. package/onboarding/prompts/framework/langgraph-typescript.md +2 -2
  20. package/onboarding/prompts/framework/llamaindex.md +2 -2
  21. package/onboarding/prompts/framework/mastra.md +2 -2
  22. package/onboarding/prompts/framework/ms-agent-dotnet.md +2 -2
  23. package/onboarding/prompts/framework/ms-agent-harness-dotnet.md +2 -2
  24. package/onboarding/prompts/framework/ms-agent-python.md +2 -2
  25. package/onboarding/prompts/framework/pydantic-ai.md +2 -2
  26. package/onboarding/prompts/framework/strands-python.md +2 -2
  27. package/onboarding/prompts/framework/strands-typescript.md +2 -2
  28. package/onboarding/prompts/frontend/angular.md +7 -2
  29. package/onboarding/prompts/frontend/nextjs.md +17 -2
  30. package/onboarding/prompts/frontend/plan.md +12 -6
  31. package/onboarding/prompts/frontend/react-native.md +2 -2
  32. package/onboarding/prompts/frontend/react-spa.md +2 -2
  33. package/onboarding/prompts/frontend/vue.md +2 -2
  34. package/onboarding/prompts/implementation/build-and-validate.md +19 -4
  35. package/onboarding/prompts/proof/complete.md +51 -15
  36. package/onboarding/prompts/proof/oss-baseline.md +3 -3
  37. package/onboarding/prompts/proof/round-trip.md +192 -60
  38. package/onboarding/prompts/starter/clone.md +67 -0
  39. package/onboarding/prompts/subagent/create-plan.md +22 -4
  40. package/onboarding/prompts/subagent/implement-and-validate.md +17 -2
  41. package/onboarding/prompts/subagent/inspect-repository.md +11 -1
  42. package/onboarding/prompts/subagent/prove-oss-baseline.md +1 -1
  43. package/onboarding/prompts/subagent/prove-round-trip.md +184 -58
  44. package/onboarding/prompts/unsupported/no-validated-path.md +6 -5
  45. package/package.json +1 -1
  46. package/release/release-tool.js +15 -1
@@ -3,6 +3,12 @@
3
3
  Use the repository findings to select the frontend. Ask the developer only for choices
4
4
  that the repository does not show. Do not change application code in this phase.
5
5
 
6
+ Use a gentle wizard. Ask one short question at a time. Do not combine separate choices in
7
+ one question. Put the recommendation first, give its evidence in one sentence, and keep
8
+ the alternatives short. When the frontend is unknown, ask only whether to use the
9
+ recommended frontend. If the developer declines it, ask one follow-up question that lists
10
+ the valid frontend choices. Do not ask about the model or project in this step.
11
+
6
12
  If the project has a frontend, preserve it and use the matching route below. If the project
7
13
  needs a frontend, show the valid choices and one recommendation based on repository
8
14
  evidence, then ask the developer to choose.
@@ -23,11 +29,11 @@ unavailable only after a second method also fails.
23
29
 
24
30
  Use exactly one matching internal route:
25
31
 
26
- 1. React SPA: `npx --yes copilotkit@4.9.0 onboard read frontend/react-spa`
27
- 2. Next.js: `npx --yes copilotkit@4.9.0 onboard read frontend/nextjs`
28
- 3. Angular: `npx --yes copilotkit@4.9.0 onboard read frontend/angular`
29
- 4. Vue 3: `npx --yes copilotkit@4.9.0 onboard read frontend/vue`
30
- 5. React Native: `npx --yes copilotkit@4.9.0 onboard read frontend/react-native`
32
+ 1. React SPA: `npx --yes copilotkit@4.9.2 onboard read frontend/react-spa`
33
+ 2. Next.js: `npx --yes copilotkit@4.9.2 onboard read frontend/nextjs`
34
+ 3. Angular: `npx --yes copilotkit@4.9.2 onboard read frontend/angular`
35
+ 4. Vue 3: `npx --yes copilotkit@4.9.2 onboard read frontend/vue`
36
+ 5. React Native: `npx --yes copilotkit@4.9.2 onboard read frontend/react-native`
31
37
 
32
38
  If no listed frontend fits, run
33
- `npx --yes copilotkit@4.9.0 onboard read unsupported/no-validated-path`.
39
+ `npx --yes copilotkit@4.9.2 onboard read unsupported/no-validated-path`.
@@ -17,8 +17,8 @@ not a fact about the page. Retrieve the same URL a second way before you judge i
17
17
  unavailable only after a second method also fails.
18
18
 
19
19
  If the page supports the selection, run
20
- `npx --yes copilotkit@4.9.0 onboard read credentials/finalize-plan`.
20
+ `npx --yes copilotkit@4.9.2 onboard read credentials/finalize-plan`.
21
21
 
22
22
  If a second method also fails, or the page that loads does not support the selection,
23
23
  run
24
- `npx --yes copilotkit@4.9.0 onboard read unsupported/no-validated-path`.
24
+ `npx --yes copilotkit@4.9.2 onboard read unsupported/no-validated-path`.
@@ -21,7 +21,7 @@ not a fact about the page. Retrieve the same URL a second way before you judge i
21
21
  unavailable only after a second method also fails.
22
22
 
23
23
  If the page supports the selection, run
24
- `npx --yes copilotkit@4.9.0 onboard read credentials/finalize-plan`.
24
+ `npx --yes copilotkit@4.9.2 onboard read credentials/finalize-plan`.
25
25
 
26
26
  If a second method also fails, or a page that loads does not support the selection, run
27
- `npx --yes copilotkit@4.9.0 onboard read unsupported/no-validated-path`.
27
+ `npx --yes copilotkit@4.9.2 onboard read unsupported/no-validated-path`.
@@ -17,8 +17,8 @@ not a fact about the page. Retrieve the same URL a second way before you judge i
17
17
  unavailable only after a second method also fails.
18
18
 
19
19
  If the page supports the selection, run
20
- `npx --yes copilotkit@4.9.0 onboard read credentials/finalize-plan`.
20
+ `npx --yes copilotkit@4.9.2 onboard read credentials/finalize-plan`.
21
21
 
22
22
  If a second method also fails, or the page that loads does not support the selection,
23
23
  run
24
- `npx --yes copilotkit@4.9.0 onboard read unsupported/no-validated-path`.
24
+ `npx --yes copilotkit@4.9.2 onboard read unsupported/no-validated-path`.
@@ -8,7 +8,7 @@ documentation URLs.
8
8
  Wait for the subagent to finish.
9
9
 
10
10
  If all implementation and validation steps pass, run
11
- `npx --yes copilotkit@4.9.0 onboard read proof/round-trip`.
11
+ `npx --yes copilotkit@4.9.2 onboard read proof/round-trip`.
12
12
 
13
13
  If a validation command fails, decide which kind of failure it is before you route.
14
14
 
@@ -20,7 +20,7 @@ Route out only when the failure is not yours to fix: the failure is in code this
20
20
  not write, or the fix requires changing the developer's existing agent or frontend,
21
21
  or the same command still fails after three repair attempts, or the documentation does not
22
22
  support the plan. In those cases run
23
- `npx --yes copilotkit@4.9.0 onboard read unsupported/no-validated-path`.
23
+ `npx --yes copilotkit@4.9.2 onboard read unsupported/no-validated-path`.
24
24
 
25
25
  ## Implementation subagent brief
26
26
 
@@ -57,8 +57,23 @@ for.
57
57
 
58
58
  For a recorded `both-oss` baseline, preserve the existing agent, frontend, CopilotKit
59
59
  integration, user-visible request, and runtime behavior. Do not replace the existing
60
- persistence. Change only the approved project selection and Intelligence runtime wiring.
61
- Run the recorded baseline checks after the change and report any regression.
60
+ persistence. Change only the approved project selection, the approved CopilotKit
61
+ dependency upgrade, and the Intelligence runtime wiring.
62
+ Run the recorded baseline checks again after the Intelligence wiring and report any
63
+ regression.
64
+
65
+ Apply the planned CopilotKit dependency upgrade before you wire Intelligence, as its own
66
+ step, and record each version it changed. Then re-run the recorded baseline checks. A
67
+ regression at this point can only be the upgrade, which is why it is checked here rather
68
+ than after the wiring.
69
+
70
+ If the baseline regresses, restore the manifest and lockfile to their recorded state,
71
+ leave Intelligence unwired, and report the regression with the failing check. A
72
+ half-upgraded project with no working chat is worse than the one this run was given, and
73
+ finishing the wiring on top of a broken baseline hides which change broke it.
74
+
75
+ Report each `@copilotkit/*` version before and after the upgrade. Where the plan named no
76
+ dependency change, say that the installed versions already met the floor.
62
77
 
63
78
  When the documentation creates the frontend with the framework's own scaffolder,
64
79
  run that scaffolder rather than hand-authoring what it emits.
@@ -1,13 +1,20 @@
1
- # Complete onboarding
1
+ # Close out onboarding
2
2
 
3
3
  Report the selected framework, frontend, model, and complete round-trip evidence to the developer.
4
4
  Report the exact interaction, visible result, validation commands, and evidence locations.
5
5
 
6
6
  Do not complete onboarding without this evidence.
7
7
 
8
- Report whether the real UI was driven in a browser, using the outcome the proof subagent
8
+ Report whether the real UI was driven on this journey's own surface -- in a browser for a
9
+ web frontend, on a device for React Native -- using the outcome the proof subagent
9
10
  returned. Do not soften it and do not leave it out: a run that never drove the UI proved
10
- the agent, not the browser path, and the developer needs to know which they have.
11
+ the agent, not the surface, and the developer needs to know which they have.
12
+
13
+ **Whether this run is complete is decided by the command at the end of this prompt, not
14
+ here.** Run it before you write the summary, and let its output decide which summary you
15
+ write. A run whose surface was never driven is blocked, not complete: say so in the first
16
+ line, name the evidence the command lists as missing, and do not describe the run as
17
+ finished, working, or ready. Everything else below applies to either outcome.
11
18
 
12
19
  Report only the project this run worked in. The summary and every report below describe
13
20
  that project and nothing else. Do not name or describe a file outside the project
@@ -29,17 +36,28 @@ The handoff must include:
29
36
 
30
37
  - The URL of the running app.
31
38
  - The command that starts the app in the future.
32
- - How to use the CopilotKit Inspector.
39
+ - The debugging surface this journey's frontend can reach, named below.
33
40
  - How to use https://intelligence.copilotkit.ai to manage the Intelligence installation.
34
41
  - The process IDs and stop commands for the running agent and frontend.
42
+ - The `@copilotkit/*` versions this conversion changed, and what they were before.
43
+
44
+ Name the debugging surface this journey's frontend can reach, rather than the one the rest
45
+ of the documentation leads with. For a web frontend it is the CopilotKit Inspector. For
46
+ React Native there is no Inspector: it is a browser overlay built on a DOM custom element,
47
+ and `@copilotkit/react-native` does not ship it. Give a mobile developer
48
+ `npx --yes copilotkit@4.9.2 verify --round-trip`, the runtime's own log, the AG-UI
49
+ Event Inspector in the CopilotKit VS Code extension, and the Intelligence thread view
50
+ instead. Naming the Inspector to a developer who cannot open it costs them the time it
51
+ takes to conclude their own wiring is broken.
35
52
 
36
53
  State that the servers remain running after proof.
37
54
 
38
- If the developer permitted external feedback at the start, report each thing that slowed
39
- this run down. Send at most four reports, worst first:
55
+ Report each thing that slowed this run down. Send at most four reports, worst first. Run
56
+ the friction commands without another developer question. The CLI telemetry gate decides
57
+ whether the report is sent.
40
58
 
41
59
  ```text
42
- npx --yes copilotkit@4.9.0 onboard friction --category <slug> --cost-seconds <seconds>
60
+ npx --yes copilotkit@4.9.2 onboard friction --category <slug> --cost-seconds <seconds>
43
61
  ```
44
62
 
45
63
  Write one or two sentences on the command's standard input. Pick one category from
@@ -53,16 +71,34 @@ a failed step and not a failed onboarding run. Reword it and send it again, or m
53
71
  on. A run that proves a round trip is complete whether or not it reported friction.
54
72
 
55
73
  Tell the developer when you send a friction report. Do not quote or summarize the report
56
- unless the developer asks. If the developer did not permit feedback, do not run a friction
57
- command.
74
+ unless the developer asks. If the CLI says that telemetry is disabled or unavailable,
75
+ state that the report was not sent and continue without another question.
76
+
77
+ When the evidence is gathered, run `npx --yes copilotkit@4.9.2 onboard complete`, carrying
78
+ the surface-check outcome the proof subagent returned. Pass exactly one flag, and pass the
79
+ one that matches this journey's surface.
80
+
81
+ For a web frontend -- React SPA, Next.js, Angular, Vue:
82
+
83
+ ```text
84
+ npx --yes copilotkit@4.9.2 onboard complete --visual-check <outcome>
85
+ ```
86
+
87
+ The outcome is one of `performed`, `skipped-no-browser-tool`, or `failed`.
58
88
 
59
- When the evidence is complete, run `npx --yes copilotkit@4.9.0 onboard complete`, carrying
60
- the visual-check outcome the proof subagent returned:
89
+ For React Native:
61
90
 
62
91
  ```text
63
- npx --yes copilotkit@4.9.0 onboard complete --visual-check <outcome>
92
+ npx --yes copilotkit@4.9.2 onboard complete --device-check <outcome>
64
93
  ```
65
94
 
66
- The outcome is one of `performed`, `skipped-no-browser-tool`, or `failed`. The command
67
- prints what a skipped visual check leaves unverified, so pass the outcome you were given
68
- rather than the one you wanted.
95
+ The outcome is one of `performed`, `skipped-no-device`, or `failed`.
96
+
97
+ The two flags are not interchangeable and neither takes the other's outcomes. A browser
98
+ proves nothing about a React Native view tree, and a device capture proves nothing about
99
+ browser-origin CORS, so the flag you pass is how this run states which surface it proved.
100
+
101
+ Pass the outcome you were given rather than the one you wanted. Anything but `performed`
102
+ prints what the missing check leaves unverified and ends this run as blocked. That output
103
+ is the developer's finding, so carry it into the summary rather than restating it as a
104
+ smaller caveat.
@@ -10,11 +10,11 @@ processes and their ignored runtime files is allowed.
10
10
 
11
11
  If the subagent proves the `both-oss` predicate, keep its evidence with the plan. If it
12
12
  proves another supported starting state, record that state. In either case, run
13
- `npx --yes copilotkit@4.9.0 onboard read credentials/plan`.
13
+ `npx --yes copilotkit@4.9.2 onboard read credentials/plan`.
14
14
 
15
15
  If it cannot identify the running process safely, exposes a secret, or finds a baseline
16
16
  failure that cannot be classified, run
17
- `npx --yes copilotkit@4.9.0 onboard read unsupported/no-validated-path`.
17
+ `npx --yes copilotkit@4.9.2 onboard read unsupported/no-validated-path`.
18
18
 
19
19
  ## Baseline proof subagent brief
20
20
 
@@ -40,7 +40,7 @@ Prove the live runtime in this order:
40
40
  4. Confirm from project files that the runtime constructor passes a `runner` option rather
41
41
  than an `intelligence` option. A package, import, project file, or key is not use proof.
42
42
  5. Run
43
- `npx --yes copilotkit@4.9.0 verify --expect-runtime oss --round-trip --agent <expected-agent-id> --json`,
43
+ `npx --yes copilotkit@4.9.2 verify --expect-runtime oss --round-trip --agent <expected-agent-id> --json`,
44
44
  with the runtime URL or auth header options that this project needs. Require exit zero
45
45
  and the JSON `ok` field to be `true`.
46
46
  6. Drive one real request through the existing frontend, CopilotKit runtime, and expected
@@ -5,13 +5,19 @@ Do not do the proof work yourself. Spawn one proof subagent.
5
5
  Give the subagent the full text of the proof brief at the end of this prompt, the selected
6
6
  framework, frontend, model, approved plan, selected documentation URLs, and validation
7
7
  evidence.
8
+
9
+ Give it the browser or device control you recorded in the preflight as well. The subagent
10
+ drives the surface and cannot see your environment, so without that finding it spends the
11
+ step discovering what you already know. A subagent told it has no control for the surface
12
+ this frontend needs reports the skip outcome rather than looking for a way around it.
13
+
8
14
  Wait for the subagent to finish.
9
15
 
10
16
  Give the subagent this guide for continued-development tools:
11
17
  https://docs.copilotkit.ai/build-with-agents.md
12
18
 
13
19
  If the subagent proves the complete round trip, run
14
- `npx --yes copilotkit@4.9.0 onboard read proof/complete`. The round trip proves core success
20
+ `npx --yes copilotkit@4.9.2 onboard read proof/complete`. The round trip proves core success
15
21
  even if a continued-development tool fails. Keep the Skills and MCP results separate from
16
22
  the proof result.
17
23
 
@@ -21,7 +27,7 @@ the proof subagent to fix and prove again, at most three attempts.
21
27
 
22
28
  Route out only when the failure is not yours to fix, when the same proof still fails after
23
29
  three attempts, or when no evidence of the round trip can be produced. In those cases run
24
- `npx --yes copilotkit@4.9.0 onboard read unsupported/no-validated-path`.
30
+ `npx --yes copilotkit@4.9.2 onboard read unsupported/no-validated-path`.
25
31
 
26
32
  ## Proof subagent brief
27
33
 
@@ -35,63 +41,90 @@ Use the proof steps and documentation URLs from the approved plan. Fetch every s
35
41
  URL in one step before you start, rather than one after another.
36
42
  Do not use remembered CopilotKit instructions.
37
43
 
44
+ Run the steps below in the order they appear. They are the proof. Do not design a
45
+ different sequence of your own, and do not drop a step because an earlier one looked
46
+ convincing. Step 6 has a web form and a React Native form: run the one that matches this
47
+ journey's frontend, and run only that one.
48
+
49
+ Record the result of every step as you go. A step with nothing recorded did not happen.
50
+ Write each captured file to `.copilotkit/proof/` inside the project and name the path in
51
+ the record. That directory holds regenerable evidence rather than application code. Where
52
+ a browser or device tool writes to a location of its own, keep that location and record
53
+ it instead.
54
+
38
55
  A fetch tool that refuses a URL, or fails to reach it, reports a limit of the tool and
39
56
  not a fact about the page. Retrieve the same URL a second way before you judge it. Run
40
57
  `curl -fsSL <url>`, or read the same page without the `.md` suffix. Report a
41
58
  documentation gap only after a second method also fails.
42
59
 
43
- Read the port the developer's agent already serves from this project's own
44
- configuration. Do not assume a default, and do not start a second copy of an agent this
45
- project is already running. Before you bind any new server, check that the port is free
46
- and pick another one if it is not. Record every port you used.
60
+ Gather what you need in as few commands as possible. Combine independent reads into one
61
+ command rather than running them one at a time. Split a command only when its result decides
62
+ what you run next.
47
63
 
48
- Start the agent and the selected frontend.
64
+ ## Step 1 -- Read what the proof needs
49
65
 
50
- Leave the agent and frontend servers running after proof. Record each process ID and a
51
- safe command that stops that process. Record the frontend URL and the commands that start
52
- both servers again.
66
+ Read all of this from the approved plan in one pass, before you start anything:
53
67
 
54
- With both running, check the wiring in one command before you open a browser:
55
- `npx --yes copilotkit@4.9.0 verify --json`. Add `--runtime-url` when the runtime is not at
56
- `http://localhost:3000/api/copilotkit`. Read the individual checks rather than the summary
57
- alone: a check reported `undetermined` did not run, and that is not a pass. Fix anything
58
- that is not a pass before the browser, because a browser failure stacked on broken wiring
59
- costs a round of debugging to reach an answer this command already gave.
68
+ - the exact request to send through the frontend, in the words the plan gave it,
69
+ - the user-visible result that request has to produce,
70
+ - the expected agent id,
71
+ - where the project's own data lives, and which entities the answer has to name,
72
+ - the start command for the agent and for the frontend, from the plan where it named
73
+ one and from the project's own scripts otherwise,
74
+ - the runtime URL.
60
75
 
61
- Treat `intelligence_consumed` as the check that matters most here. A journey that finishes
62
- with the Intelligence credential never read looks complete and proves nothing about the
63
- paid surface. `api_key_authenticates` passing beside it says the key is real and the
64
- runtime never used it.
76
+ Where the plan named no request, write one that produces the outcome the plan named, and
77
+ record the request you wrote. Every later step uses these words unchanged, so that the
78
+ browser, the device, and the grounding check all speak about one request.
65
79
 
66
- `intelligence_thread_routes` fails when the runtime reports a license but serves no
67
- thread routes, which means saved Threads cannot load in a browser. The usual cause is a
68
- handler mounted `mode: "single-route"`: remove that option so the handler serves its full
69
- route set, and mount it at a catch-all route. If instead that check is `undetermined`
70
- because the runtime reports no thread-endpoint state, the runtime predates the field.
71
- Record that and move on — there is nothing to repair.
80
+ ## Step 2 -- Start the agent and the frontend
72
81
 
73
- Then prove that the agent actually runs, which is the gate for this node:
74
- `npx --yes copilotkit@4.9.0 verify --round-trip --json`. It sends one request through the
75
- runtime and reads the answer back from the thread, so it separates an agent that is
76
- configured from an agent that works. Use `--agent <id>` when the runtime declares more
77
- than one. If it reports `user-not-identified`, this project's `identifyUser` reads a
78
- session the CLI does not carry: pass what it reads with `--header "Name: value"` and run
79
- it again, because an auth-gated app refusing an unauthenticated caller is that app
80
- working. Do not continue until this passes, and never report a round trip proven without
81
- it.
82
+ Read the port the developer's agent already serves from this project's own configuration.
83
+ Do not assume a default, and do not start a second copy of an agent this project is
84
+ already running. Before you bind any new server, check that the port is free and pick
85
+ another one if it is not. Record every port you used.
86
+
87
+ The table names what each frontend's own scaffolder writes, for recognizing a port in a
88
+ started process's output. The project's configuration wins over the table.
89
+
90
+ | Frontend | Dev server the scaffolder writes |
91
+ | ------------ | -------------------------------- |
92
+ | Next.js | `next dev`, port 3000 |
93
+ | React SPA | Vite, port 5173 |
94
+ | Vue 3 | Vite, port 5173 |
95
+ | Angular | `ng serve`, port 4200 |
96
+ | React Native | Metro, port 8081 |
97
+
98
+ Where this project's runtime runs as a process of its own, the frontend documentation
99
+ puts it on port 8200. Use the runtime URL from step 1 rather than that number.
100
+
101
+ Start each server in the background with the project's own script. Then wait for it to
102
+ answer rather than for a fixed number of seconds:
82
103
 
83
- Then send one real request through the frontend. Make sure that the request passes through
84
- CopilotKit and reaches the selected agent.
104
+ ```bash
105
+ ready=
106
+ for _ in $(seq 90); do
107
+ curl -fs -o /dev/null "<url>" && ready=1 && break
108
+ sleep 1
109
+ done
110
+ [ "$ready" = 1 ] && echo "up" || echo "no answer from <url> after 90 seconds"
111
+ ```
85
112
 
86
- For a recorded `both-oss` starting state: Compare the final round trip with the recorded
87
- OSS baseline. The same frontend request must still reach the same agent and produce the
88
- same kind of user-visible result. The runtime must now report `licenseStatus`, and the
89
- authenticated Intelligence checks must pass. Record both before and after evidence.
113
+ Read the loop's own last line rather than assuming it ended because the server answered.
114
+ A server that never answered has written the reason to its own output, and reading that
115
+ output is faster than starting it again.
116
+
117
+ Leave the agent and frontend servers running after proof. Record each process ID and a
118
+ safe command that stops that process. Record the frontend URL and the commands that start
119
+ both servers again.
120
+
121
+ ## Step 3 -- Identify the process that answered
90
122
 
91
123
  Before you trust the agent, confirm that the process answering is the one in this
92
124
  repository. `verify` reports which agents the runtime declares and has nothing to compare
93
125
  them against, and `--round-trip` proves an agent answers under the declared id without
94
- proving which deployment did, so this comparison is yours. A health endpoint that returns success proves only that something listens on
126
+ proving which deployment did, so this comparison is yours. A health endpoint that returns
127
+ success proves only that something listens on
95
128
  that port. An agent from earlier work often still holds it, and a stale process answers
96
129
  as though it were the new one. Ask the running agent which graph or agent id it serves
97
130
  and compare that with the id declared in this project.
@@ -109,23 +142,112 @@ by one.
109
142
  Address a local agent by host name rather than by an IP literal. Some local agents bind
110
143
  IPv6 only, so an IPv4 literal fails against the correct port.
111
144
 
112
- Drive the real UI in a browser whenever your environment can, and make sure that the
113
- frontend receives working generative UI from the agent. Prefer this: it is the only step
114
- that covers realtime delivery to a browser, browser-origin CORS and CSP, the frontend
115
- provider being wired to this runtime, and a generative UI component actually rendering,
116
- and no command-line check reaches any of them.
145
+ ## Step 4 -- Check the wiring
146
+
147
+ With both running, check the wiring in one command before you open a browser:
148
+ `npx --yes copilotkit@4.9.2 verify --json`. Add `--runtime-url` when the runtime is not at
149
+ `http://localhost:3000/api/copilotkit`. Read the individual checks rather than the summary
150
+ alone: a check reported `undetermined` did not run, and that is not a pass. Fix anything
151
+ that is not a pass before the browser, because a browser failure stacked on broken wiring
152
+ costs a round of debugging to reach an answer this command already gave.
153
+
154
+ Treat `intelligence_consumed` as the check that matters most here. A journey that finishes
155
+ with the Intelligence credential never read looks complete and proves nothing about the
156
+ paid surface. `api_key_authenticates` passing beside it says the key is real and the
157
+ runtime never used it.
158
+
159
+ `intelligence_thread_routes` fails when the runtime reports a license but serves no
160
+ thread routes, which means saved Threads cannot load in a browser. The usual cause is a
161
+ handler mounted `mode: "single-route"`: remove that option so the handler serves its full
162
+ route set, and mount it at a catch-all route. If instead that check is `undetermined`
163
+ because the runtime reports no thread-endpoint state, the runtime predates the field.
164
+ Record that and move on -- there is nothing to repair.
117
165
 
118
- Use a browser MCP server already configured for the coding agent you are running as, the
119
- same way the CopilotKit documentation MCP server below is configured. Do not add a browser
120
- driver to this project: a devDependency and a browser download land in the diff and tax a
121
- repository that never asked for one. If nothing in your environment can drive a
122
- browser, skip this step rather than installing one, and never report a visual result you
123
- did not see.
166
+ ## Step 5 -- Prove that the agent runs
124
167
 
125
- Report exactly one of `performed`, `skipped-no-browser-tool`, or `failed` for this step.
168
+ Run `npx --yes copilotkit@4.9.2 verify --round-trip --json`. It sends one request through
169
+ the runtime and reads the answer back from the thread, so it separates an agent that is
170
+ configured from an agent that works. Use `--agent <id>` when the runtime declares more
171
+ than one. If it reports `user-not-identified`, this project's `identifyUser` reads a
172
+ session the CLI does not carry: pass what it reads with `--header "Name: value"` and run
173
+ it again, because an auth-gated app refusing an unauthenticated caller is that app
174
+ working. Do not continue until this passes, and never report a round trip proven without
175
+ it.
126
176
 
127
- Record the input, visible result, relevant process status, and evidence locations. Do not
128
- return secret values.
177
+ ## Step 6 -- Drive the surface
178
+
179
+ Now send one real request through the running frontend, on this journey's own surface.
180
+ Make sure that the request passes through CopilotKit and reaches the selected agent, and
181
+ that the frontend receives working generative UI from the agent. This is the step that
182
+ covers realtime delivery, the frontend provider being wired to this runtime, and a
183
+ generative UI component actually rendering, and no command-line check reaches any of them.
184
+ It is not optional polish: a run that skips it has proven the agent and not the journey,
185
+ and the graph ends such a run as blocked rather than complete.
186
+
187
+ Use the surface control the main coding agent recorded for your environment. Do not add a
188
+ browser driver or a device tool to this project: a devDependency and a browser download
189
+ land in the diff and tax a repository that never asked for one. If nothing in your
190
+ environment can drive the surface this journey needs, skip this step rather than
191
+ installing one, and report the skip outcome named below.
192
+
193
+ Never report a result you did not see, on either surface.
194
+
195
+ ### Step 6a -- Web frontends: React SPA, Next.js, Angular, Vue 3
196
+
197
+ The surface is a browser, and it also covers browser-origin CORS and CSP, which a CLI
198
+ request never exercises. Use a browser MCP server already configured for the coding agent
199
+ you are running as, the same way step 9 configures the CopilotKit documentation MCP
200
+ server.
201
+
202
+ 1. Open the frontend URL from step 2 and wait for the page to finish loading.
203
+ 2. Take one page snapshot. Record whether the CopilotKit surface is on the page. A page
204
+ that renders without it is a wiring failure rather than a proof to retry.
205
+ 3. Read the browser console before you type anything, and record every error already
206
+ there. An error at this point belongs to page load rather than to the request.
207
+ 4. Enter the step 1 request into the CopilotKit input, in the words step 1 recorded, and
208
+ submit it.
209
+ 5. Wait for the assistant turn to finish rather than for a fixed number of seconds. The
210
+ turn is finished when the streamed text stops growing and the generative UI component
211
+ has rendered.
212
+ 6. Take one screenshot of the finished turn and record where you wrote it.
213
+ 7. Read the browser console a second time, and record every error that step 3 did not
214
+ already list. Those belong to the request.
215
+ 8. Read the network requests. Record every request the page made to the runtime endpoint
216
+ and the status each returned. An answer on the page with no successful request to this
217
+ runtime behind it came from something else, and that is a failed proof rather than a
218
+ passing one.
219
+ 9. Record one line for the finished turn: the time, the page URL, the element you read
220
+ the answer from, and what that element showed.
221
+
222
+ Report exactly one of `performed`, `skipped-no-browser-tool`, or `failed` for a web
223
+ frontend.
224
+
225
+ ### Step 6b -- React Native
226
+
227
+ The surface is a device or emulator, and a browser cannot stand in for it.
228
+
229
+ 1. List the booted devices in one command: `adb devices -l`. With no booted device this
230
+ step is `skipped-no-device`. Do not substitute a browser.
231
+ 2. Build and install the app on the booted device with the project's own script, which
232
+ an Expo or React Native CLI project names in `package.json`.
233
+ 3. Clear the log buffer before the request: `adb logcat -c`.
234
+ 4. Open the CopilotKit surface in the running app and enter the step 1 request, in the
235
+ words step 1 recorded.
236
+ 5. Wait for the assistant turn to finish rather than for a fixed number of seconds.
237
+ 6. Capture the terminal state with
238
+ `adb exec-out screencap -p > .copilotkit/proof/surface.png`, and record that path.
239
+ 7. Read the log for the request with `adb logcat -d -t 500`. A redbox is a runtime failure
240
+ the terminal state never shows.
241
+ 8. Record one line for the finished turn: the time, the platform, the device id, the
242
+ screen you were on, and what that screen showed.
243
+
244
+ An Android emulator reaches a runtime on the host machine at `10.0.2.2` rather than at
245
+ `localhost`. A request that fails against the runtime with nothing in the runtime's own
246
+ log is that, rather than a broken runtime.
247
+
248
+ Report exactly one of `performed`, `skipped-no-device`, or `failed` for React Native.
249
+
250
+ ## Step 7 -- Check the answer against the project's data
129
251
 
130
252
  Where the answer is meant to be about data the project holds, check it against that data.
131
253
  Read the entities the project holds -- the ids, names, or records the answer claims to
@@ -141,6 +263,16 @@ project's data never reaches the agent, the agent receives it and its instructio
141
263
  it, the page loads its data after the context was registered, or the run wired a different
142
264
  source than the page renders. Fix that cause, then prove again.
143
265
 
266
+ ## Step 8 -- Compare with the recorded OSS baseline
267
+
268
+ Run this step only for a recorded `both-oss` starting state. Compare the final round trip
269
+ with the recorded OSS baseline. The same frontend request must still reach the same agent
270
+ and produce the same kind of user-visible result. The runtime must now report
271
+ `licenseStatus`, and the authenticated Intelligence checks must pass. Record both before
272
+ and after evidence.
273
+
274
+ ## Step 9 -- Set up the continued-development tools
275
+
144
276
  Fetch the continued-development guide from the main coding agent with the proof
145
277
  documentation. Try the continued-development tools after the application passes proof.
146
278
  Use it to install the project-scoped CopilotKit Skills.
@@ -150,9 +282,9 @@ Do not validate whether the Skills or MCP server installed correctly. Record the
150
282
  result for each attempt. Report each tool result separately. A tool error does not change
151
283
  the proof result.
152
284
 
153
- Gather what you need in as few commands as possible. Combine independent reads into one
154
- command rather than running them one at a time. Split a command only when its result decides
155
- what you run next.
285
+ ## Step 10 -- Return the result
156
286
 
157
287
  Return the proof or the exact failed step to the main coding agent, together with the
158
- visual-check outcome. Stop after you return the result.
288
+ input, the visible result, the relevant process status, the evidence locations, the
289
+ surface-check outcome, and which surface that outcome speaks for. Do not return secret
290
+ values. Stop after you return the result.
@@ -0,0 +1,67 @@
1
+ # Clone a starter
2
+
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.
6
+
7
+ Match the selected agent framework and frontend to this table:
8
+
9
+ | Agent framework | Frontend | Framework ID |
10
+ | -------------------------------- | -------- | ---------------------------------- |
11
+ | Agno | Next.js | `agno` |
12
+ | Claude Agent SDK Python | Next.js | `claude-sdk-python` |
13
+ | Claude Agent SDK TypeScript | Next.js | `claude-sdk-typescript` |
14
+ | CrewAI Flows | Next.js | `flows` |
15
+ | LangGraph Python | Next.js | `langgraph-py` |
16
+ | LangGraph TypeScript | Next.js | `langgraph-js` |
17
+ | LlamaIndex | Next.js | `llamaindex` |
18
+ | ADK | Next.js | `adk` |
19
+ | ADK | Angular | `adk-angular` |
20
+ | Microsoft Agent Framework Python | Next.js | `microsoft-agent-framework-py` |
21
+ | Microsoft Agent Framework .NET | Next.js | `microsoft-agent-framework-dotnet` |
22
+ | Mastra | Next.js | `mastra` |
23
+ | Pydantic AI | Next.js | `pydantic-ai` |
24
+ | Strands Agents Python | Next.js | `aws-strands-py` |
25
+ | Strands Agents TypeScript | Next.js | `aws-strands-ts` |
26
+
27
+ Each Framework ID selects a starter that the CLI ships with Intelligence. Do not infer a
28
+ different pair from a similar name. AG2 does not use this shortcut because its starter does
29
+ not include Intelligence.
30
+
31
+ Get the target directory name from its path. The project name must contain 1 to 30
32
+ lowercase letters, numbers, or hyphens. It must not start or end with a hyphen. If the
33
+ selected pair is not in the table, or the directory name is not valid, stop the shortcut.
34
+ Do not run `init`. Treat this result as a failed shortcut and follow the final failure
35
+ instruction in this prompt.
36
+
37
+ If the developer did not name an Intelligence project, list the available projects:
38
+
39
+ `npx --yes copilotkit@4.9.2 project list --json`
40
+
41
+ Ask the developer to select a project or give a name for a new project. If the developer
42
+ already gave this answer, do not ask again. Do not read a secret value. Do not show or
43
+ store a secret value.
44
+
45
+ Run the command from the parent directory. Do not inspect another entry in the parent
46
+ directory. Replace each placeholder with the recorded value. Do not run a placeholder as
47
+ a shell argument.
48
+
49
+ `npx --yes copilotkit@4.9.2 init --name <project-name> --framework <framework-id> --channel none --no-banner --project <slug-or-id> --install`
50
+
51
+ If the developer wants a new project, use `--create <name>` instead of
52
+ `--project <slug-or-id>`. If the developer asked to skip the dependency install, use
53
+ `--no-install` instead of `--install`. Do not wait for an interactive prompt. Pass every
54
+ answer as a flag.
55
+
56
+ The command clones the starter into the empty target directory. It also connects the
57
+ starter to the developer's Intelligence project. The earlier login phase supplies the
58
+ account. The command does not need terminal input.
59
+
60
+ If the command succeeds, do not rebuild the starter by hand. Inspect only the generated
61
+ paths inside the target directory. Record the files, install result, project connection,
62
+ and validation commands. Then run
63
+ `npx --yes copilotkit@4.9.2 onboard read proof/round-trip`.
64
+
65
+ If the command fails, report its exact error and do not claim that the starter is ready.
66
+ Then run
67
+ `npx --yes copilotkit@4.9.2 onboard read unsupported/no-validated-path`.