copilotkit 4.29.0 → 4.30.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 (97) hide show
  1. package/README.md +311 -33
  2. package/cli-build-info.json +7 -7
  3. package/exporters/claude-sdk/README.md +93 -0
  4. package/exporters/claude-sdk/export_session_store.py +39 -0
  5. package/exporters/claude-sdk/store-export.ts +61 -0
  6. package/index.js +212561 -109267
  7. package/onboarding/index.json +51 -5
  8. package/onboarding/prompts/authenticate/start.md +51 -49
  9. package/onboarding/prompts/conversion/plan.md +3 -3
  10. package/onboarding/prompts/credentials/finalize-plan.md +15 -15
  11. package/onboarding/prompts/credentials/plan.md +25 -29
  12. package/onboarding/prompts/credentials/settle-credentials.md +13 -8
  13. package/onboarding/prompts/credentials/write-plan.md +18 -16
  14. package/onboarding/prompts/deployment/choose-local.md +13 -12
  15. package/onboarding/prompts/deployment/local-evaluation.md +11 -11
  16. package/onboarding/prompts/fallback/best-effort.md +10 -11
  17. package/onboarding/prompts/feature/a2ui/implement.md +7 -5
  18. package/onboarding/prompts/feature/a2ui/plan.md +7 -3
  19. package/onboarding/prompts/feature/a2ui/proof.md +8 -6
  20. package/onboarding/prompts/feature/a2ui/start.md +10 -10
  21. package/onboarding/prompts/feature/channels/implement.md +10 -8
  22. package/onboarding/prompts/feature/channels/plan.md +9 -5
  23. package/onboarding/prompts/feature/channels/proof.md +8 -6
  24. package/onboarding/prompts/feature/channels/start.md +17 -13
  25. package/onboarding/prompts/feature/chat-suggestions/implement.md +7 -5
  26. package/onboarding/prompts/feature/chat-suggestions/plan.md +7 -3
  27. package/onboarding/prompts/feature/chat-suggestions/proof.md +8 -6
  28. package/onboarding/prompts/feature/chat-suggestions/start.md +10 -10
  29. package/onboarding/prompts/feature/complete.md +3 -3
  30. package/onboarding/prompts/feature/learning/implement.md +15 -13
  31. package/onboarding/prompts/feature/learning/plan.md +8 -4
  32. package/onboarding/prompts/feature/learning/proof.md +16 -14
  33. package/onboarding/prompts/feature/learning/start.md +10 -10
  34. package/onboarding/prompts/feature/open-generative-ui/implement.md +7 -5
  35. package/onboarding/prompts/feature/open-generative-ui/plan.md +7 -3
  36. package/onboarding/prompts/feature/open-generative-ui/proof.md +8 -6
  37. package/onboarding/prompts/feature/open-generative-ui/start.md +10 -10
  38. package/onboarding/prompts/feature/realtime-sync/implement.md +8 -6
  39. package/onboarding/prompts/feature/realtime-sync/plan.md +7 -3
  40. package/onboarding/prompts/feature/realtime-sync/proof.md +8 -6
  41. package/onboarding/prompts/feature/realtime-sync/start.md +9 -9
  42. package/onboarding/prompts/feature/rich-threads/implement.md +9 -7
  43. package/onboarding/prompts/feature/rich-threads/plan.md +7 -3
  44. package/onboarding/prompts/feature/rich-threads/proof.md +8 -6
  45. package/onboarding/prompts/feature/rich-threads/start.md +9 -9
  46. package/onboarding/prompts/feature/stop.md +4 -4
  47. package/onboarding/prompts/feature/voice/implement.md +7 -5
  48. package/onboarding/prompts/feature/voice/plan.md +8 -4
  49. package/onboarding/prompts/feature/voice/proof.md +8 -6
  50. package/onboarding/prompts/feature/voice/start.md +10 -10
  51. package/onboarding/prompts/framework/ag2.md +4 -11
  52. package/onboarding/prompts/framework/agno.md +4 -11
  53. package/onboarding/prompts/framework/built-in.md +3 -3
  54. package/onboarding/prompts/framework/claude-sdk-python.md +3 -3
  55. package/onboarding/prompts/framework/claude-sdk-typescript.md +3 -3
  56. package/onboarding/prompts/framework/crewai-flows.md +6 -12
  57. package/onboarding/prompts/framework/custom-ag-ui.md +5 -11
  58. package/onboarding/prompts/framework/deep-agents.md +5 -11
  59. package/onboarding/prompts/framework/google-adk.md +4 -8
  60. package/onboarding/prompts/framework/langgraph-fastapi.md +4 -10
  61. package/onboarding/prompts/framework/langgraph-python.md +4 -10
  62. package/onboarding/prompts/framework/langgraph-typescript.md +5 -11
  63. package/onboarding/prompts/framework/llamaindex.md +4 -10
  64. package/onboarding/prompts/framework/mastra.md +4 -10
  65. package/onboarding/prompts/framework/ms-agent-dotnet.md +6 -13
  66. package/onboarding/prompts/framework/ms-agent-harness-dotnet.md +7 -13
  67. package/onboarding/prompts/framework/ms-agent-python.md +5 -11
  68. package/onboarding/prompts/framework/pydantic-ai.md +4 -10
  69. package/onboarding/prompts/framework/strands-python.md +4 -10
  70. package/onboarding/prompts/framework/strands-typescript.md +4 -10
  71. package/onboarding/prompts/frontend/angular.md +4 -4
  72. package/onboarding/prompts/frontend/nextjs.md +4 -4
  73. package/onboarding/prompts/frontend/plan.md +10 -10
  74. package/onboarding/prompts/frontend/react-native.md +3 -3
  75. package/onboarding/prompts/frontend/react-spa.md +3 -3
  76. package/onboarding/prompts/frontend/vue.md +3 -3
  77. package/onboarding/prompts/implementation/build-and-validate.md +33 -16
  78. package/onboarding/prompts/proof/complete.md +22 -19
  79. package/onboarding/prompts/proof/oss-baseline.md +6 -6
  80. package/onboarding/prompts/proof/round-trip.md +34 -14
  81. package/onboarding/prompts/research/gather.md +15 -15
  82. package/onboarding/prompts/research/merge.md +6 -5
  83. package/onboarding/prompts/research/preflight.md +2 -2
  84. package/onboarding/prompts/research/route.md +4 -4
  85. package/onboarding/prompts/setup/questions.md +10 -8
  86. package/onboarding/prompts/starter/clone.md +77 -75
  87. package/onboarding/prompts/starter/setup.md +111 -0
  88. package/onboarding/prompts/stopped/declined.md +44 -0
  89. package/onboarding/prompts/stopped/run-failed.md +6 -6
  90. package/onboarding/prompts/subagent/create-plan.md +5 -5
  91. package/onboarding/prompts/subagent/implement-and-validate.md +4 -4
  92. package/onboarding/prompts/subagent/inspect-repository.md +1 -1
  93. package/onboarding/prompts/subagent/prove-oss-baseline.md +2 -2
  94. package/onboarding/prompts/subagent/prove-round-trip.md +21 -8
  95. package/onboarding/prompts/unsupported/no-validated-path.md +6 -6
  96. package/package.json +4 -1
  97. package/release/release-tool.js +383 -112
@@ -86,10 +86,14 @@ about the failure it was spawned to clear.
86
86
 
87
87
  ## Steps 2 to 5 -- Run the proof checks
88
88
 
89
+ Where your handoff holds an `onboard proof-check` result, that is your first run of the
90
+ proof checks. Read it as the result of the command below. Run the command again only after
91
+ a repair, as the rules below say.
92
+
89
93
  Run this from the target app directory:
90
94
 
91
95
  ```text
92
- npx --prefer-offline --yes copilotkit@4.29.0 onboard proof-check --json
96
+ npx --prefer-offline --yes copilotkit@4.30.0 onboard proof-check --json
93
97
  ```
94
98
 
95
99
  It starts each app's `dev` script unless a server from that app already listens, and
@@ -145,7 +149,7 @@ Otherwise sort `firstFailure`, and run the command again after each repair:
145
149
  asking. Read the port from the log, not from the plan, and record it:
146
150
 
147
151
  ```text
148
- npx --prefer-offline --yes copilotkit@4.29.0 onboard runtime-url --url <runtime-url>
152
+ npx --prefer-offline --yes copilotkit@4.30.0 onboard runtime-url --url <runtime-url>
149
153
  ```
150
154
 
151
155
  `<runtime-url>` is the project's runtime URL, or the plan's, with its port replaced by the
@@ -220,11 +224,20 @@ Never report a round trip proved unless `round-trip:agent_answers` passed.
220
224
 
221
225
  The checks leave every process they did not start running. If a repair needs a process
222
226
  stopped, stop a process only when its directory is inside this project, and stop its children
223
- before the parent. Never stop a process because its command line matches a name: one
227
+ before the parent. Wait for its listener to exit before rerunning the proof checks, so
228
+ the command starts only one replacement. Reuse a healthy project-owned frontend instead
229
+ of starting another copy. Never stop a process because its command line matches a name: one
224
230
  `pkill` pattern reaches every project on the machine. If a local request in Steps 5a and
225
231
  5b fails after 0 ms while the port listens, the sandbox blocked it. Request escalation
226
232
  with a prefix rule for `curl`, run it again, and do not record a failed predicate.
227
233
 
234
+ Next.js allows only one dev server per project directory. A second `next dev` can
235
+ announce port 3001 and print `Ready` before exiting with `Another next dev server is
236
+ already running` or a `.next/dev/lock` error. Changing ports does not fix that collision.
237
+ Do not delete a live server's lock. Identify the project-owned server and reuse it, or
238
+ stop it under the rule above before rerunning the proof checks. Confirm the replacement
239
+ stays running and serves the app before continuing. Leave other projects' processes alone.
240
+
228
241
  ### Step 5a -- Prove that the page's data reaches the model
229
242
 
230
243
  Where the proof checks needed `--thread`, the app refuses a run that Steps 5a and 5b send,
@@ -252,7 +265,7 @@ shows it. Send the same run
252
265
  body twice: once carrying the context entries the page
253
266
  publishes, and once carrying the same entries with one value changed. Use the step 1
254
267
  request both times. Write each body to a JSON file in `.copilotkit/proof/`, and send it with
255
- `npx --prefer-offline --yes copilotkit@4.29.0 verify --send-run <file> --agent <agent id> --json`.
268
+ `npx --prefer-offline --yes copilotkit@4.30.0 verify --send-run <file> --agent <agent id> --json`.
256
269
  The command sends the body to `<runtime>/agent/<agent id>/run` and reads the events the run
257
270
  streams. It writes them to `<file name>.events.jsonl` beside the body, and prints that path
258
271
  with the answer text and the tool calls. Do not send a run with `curl` and read its events
@@ -330,7 +343,7 @@ For a recorded `both-oss` starting state, this step has no component to render.
330
343
  same request the baseline recorded, require the same kind of user-visible result the
331
344
  baseline produced, and require that the thread for that request is listed in the drawer.
332
345
  Where this journey's frontend framework ships no threads drawer -- React Native --, prove
333
- that thread with `npx --prefer-offline --yes copilotkit@4.29.0 verify --round-trip`, which reads the
346
+ that thread with `npx --prefer-offline --yes copilotkit@4.30.0 verify --round-trip`, which reads the
334
347
  answer back off the thread and needs no browser. Where the proof checks needed `--thread`,
335
348
  prove the thread for this request with `verify --thread <id>` instead. Record which of the
336
349
  two you proved.
@@ -360,7 +373,7 @@ limit can be ten minutes. You cannot interrupt a call while it runs, so the limi
360
373
  what you do after one. If a browser call took longer than 60 seconds to return, the browser
361
374
  control is unresponsive. Do not call the browser again in this attempt. A second call to a
362
375
  hung tool waits as long as the first one did. Run
363
- `npx --prefer-offline --yes copilotkit@4.29.0 verify --frontend-url <the frontendUrl the proof checks resolved> --json` once,
376
+ `npx --prefer-offline --yes copilotkit@4.30.0 verify --frontend-url <the frontendUrl the proof checks resolved> --json` once,
364
377
  and record the `frontend_assets_served` result. Report the outcome `failed` with the cause
365
378
  `browser-control-unresponsive`. The application is not at fault on this evidence: every
366
379
  step before the browser proved the runtime without one, and no repair to the project can
@@ -370,7 +383,7 @@ reach the tool.
370
383
  the page to finish loading. Do not retype the host, and do not substitute a URL a tool
371
384
  offers you by default. Where the page loads but its styling is missing or the chat
372
385
  control is dead, run
373
- `npx --prefer-offline --yes copilotkit@4.29.0 verify --frontend-url <the url you opened> --json`
386
+ `npx --prefer-offline --yes copilotkit@4.30.0 verify --frontend-url <the url you opened> --json`
374
387
  before you diagnose anything else. A dev server can serve its page and refuse every
375
388
  static chunk behind it, and on screen that is indistinguishable from a broken
376
389
  integration. The `frontend_assets_served` check tells the two apart.
@@ -482,7 +495,7 @@ For every other starting state, record Step 8 as not applicable.
482
495
  Before you return, record that you are returning:
483
496
 
484
497
  ```text
485
- npx --prefer-offline --yes copilotkit@4.29.0 onboard checkpoint --phase subagent-returned --brief prove-round-trip --result <ok|failed>
498
+ npx --prefer-offline --yes copilotkit@4.30.0 onboard checkpoint --phase subagent-returned --brief prove-round-trip --result <ok|failed>
486
499
  ```
487
500
 
488
501
  The Status line of your result decides the value. Pass `ok` only for `Status: passed`.
@@ -9,9 +9,9 @@ trip caused the route change. Do not say a path works when this release does not
9
9
  If the CLI stopped this run with `## Stop: this run deleted or moved the developer's work`,
10
10
  name each path and change it listed, in the words it printed. A report that says only that
11
11
  files changed cannot be acted on: nobody reading it can tell which file moved.
12
- This step prints `## The developer's files` below: relay that report as printed, with its
13
- restore command. When the report says the run started in an empty folder, relay that one
14
- line alone: list no files and offer no restore.
12
+ This step prints `## Your files` below: relay that report as printed, with its restore
13
+ command. A run that started in an empty folder prints no such section: list no files and
14
+ offer no restore.
15
15
 
16
16
  Stop onboarding without making more repository changes by default.
17
17
 
@@ -36,17 +36,17 @@ Before you show the best-effort plan, require this complete packet:
36
36
  Before you end your turn to wait for the developer, report the pause:
37
37
 
38
38
  ```text
39
- npx --prefer-offline --yes copilotkit@4.29.0 onboard checkpoint --phase awaiting-plan-approval
39
+ npx --prefer-offline --yes copilotkit@4.30.0 onboard checkpoint --phase awaiting-plan-approval
40
40
  ```
41
41
 
42
42
  After the developer approves the best-effort plan, run
43
- `npx --prefer-offline --yes copilotkit@4.29.0 onboard read fallback/best-effort`.
43
+ `npx --prefer-offline --yes copilotkit@4.30.0 onboard read fallback/best-effort`.
44
44
 
45
45
  Send one short report. The friction command follows the telemetry setting the developer
46
46
  already chose, so it needs no separate question.
47
47
 
48
48
  ```text
49
- npx --prefer-offline --yes copilotkit@4.29.0 onboard friction --phase stop --category <slug> --message "<sentences>"
49
+ npx --prefer-offline --yes copilotkit@4.30.0 onboard friction --phase stop --category <slug> --message "<sentences>"
50
50
  ```
51
51
 
52
52
  `--message` takes one or two sentences: the step you stopped at and what stopped it.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "copilotkit",
3
- "version": "4.29.0",
3
+ "version": "4.30.0",
4
4
  "type": "module",
5
5
  "engines": {
6
6
  "node": ">=20.9.0"
@@ -19,5 +19,8 @@
19
19
  "dependencies": {
20
20
  "oidc-provider": "9.12.2"
21
21
  },
22
+ "devDependencies": {
23
+ "@ag-ui/client": "0.0.57"
24
+ },
22
25
  "license": "SEE LICENSE IN LICENSE"
23
26
  }