@kindgi/cli 0.1.7-rc.0 → 0.1.8-rc.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 (222) hide show
  1. package/README.md +13 -13
  2. package/dist/api-address.d.ts +57 -0
  3. package/dist/api-address.d.ts.map +1 -0
  4. package/dist/api-address.js +144 -0
  5. package/dist/api-address.js.map +1 -0
  6. package/dist/build/defaults.d.ts +9 -0
  7. package/dist/build/defaults.d.ts.map +1 -1
  8. package/dist/build/defaults.js +132 -30
  9. package/dist/build/defaults.js.map +1 -1
  10. package/dist/build/hosted.d.ts +32 -0
  11. package/dist/build/hosted.d.ts.map +1 -0
  12. package/dist/build/hosted.js +62 -0
  13. package/dist/build/hosted.js.map +1 -0
  14. package/dist/build/runners.d.ts +10 -0
  15. package/dist/build/runners.d.ts.map +1 -1
  16. package/dist/commands/adapters.d.ts.map +1 -1
  17. package/dist/commands/adapters.js +5 -9
  18. package/dist/commands/adapters.js.map +1 -1
  19. package/dist/commands/agents.d.ts.map +1 -1
  20. package/dist/commands/agents.js +2 -1
  21. package/dist/commands/agents.js.map +1 -1
  22. package/dist/commands/artifacts.js +1 -1
  23. package/dist/commands/artifacts.js.map +1 -1
  24. package/dist/commands/auth.d.ts.map +1 -1
  25. package/dist/commands/auth.js +6 -5
  26. package/dist/commands/auth.js.map +1 -1
  27. package/dist/commands/blocks.d.ts.map +1 -1
  28. package/dist/commands/blocks.js +4 -3
  29. package/dist/commands/blocks.js.map +1 -1
  30. package/dist/commands/build.d.ts.map +1 -1
  31. package/dist/commands/build.js +191 -47
  32. package/dist/commands/build.js.map +1 -1
  33. package/dist/commands/conversations.js +1 -1
  34. package/dist/commands/conversations.js.map +1 -1
  35. package/dist/commands/deploy.d.ts.map +1 -1
  36. package/dist/commands/deploy.js +296 -36
  37. package/dist/commands/deploy.js.map +1 -1
  38. package/dist/commands/dev.d.ts +0 -2
  39. package/dist/commands/dev.d.ts.map +1 -1
  40. package/dist/commands/dev.js +74 -54
  41. package/dist/commands/dev.js.map +1 -1
  42. package/dist/commands/doctor.d.ts +1 -1
  43. package/dist/commands/doctor.d.ts.map +1 -1
  44. package/dist/commands/doctor.js +66 -3
  45. package/dist/commands/doctor.js.map +1 -1
  46. package/dist/commands/flows.d.ts.map +1 -1
  47. package/dist/commands/flows.js +2 -1
  48. package/dist/commands/flows.js.map +1 -1
  49. package/dist/commands/init.d.ts +1 -1
  50. package/dist/commands/init.js +13 -12
  51. package/dist/commands/init.js.map +1 -1
  52. package/dist/commands/license.d.ts.map +1 -1
  53. package/dist/commands/license.js +130 -5
  54. package/dist/commands/license.js.map +1 -1
  55. package/dist/commands/projects.d.ts.map +1 -1
  56. package/dist/commands/projects.js +67 -8
  57. package/dist/commands/projects.js.map +1 -1
  58. package/dist/commands/runs.d.ts.map +1 -1
  59. package/dist/commands/runs.js +2 -2
  60. package/dist/commands/runs.js.map +1 -1
  61. package/dist/commands/schedules.d.ts.map +1 -1
  62. package/dist/commands/schedules.js +30 -2
  63. package/dist/commands/schedules.js.map +1 -1
  64. package/dist/commands/secrets.js +1 -1
  65. package/dist/commands/secrets.js.map +1 -1
  66. package/dist/commands/skills.d.ts +42 -6
  67. package/dist/commands/skills.d.ts.map +1 -1
  68. package/dist/commands/skills.js +258 -158
  69. package/dist/commands/skills.js.map +1 -1
  70. package/dist/commands/sso.d.ts.map +1 -1
  71. package/dist/commands/sso.js +5 -2
  72. package/dist/commands/sso.js.map +1 -1
  73. package/dist/commands/webhooks.d.ts +0 -6
  74. package/dist/commands/webhooks.d.ts.map +1 -1
  75. package/dist/commands/webhooks.js +12 -85
  76. package/dist/commands/webhooks.js.map +1 -1
  77. package/dist/config.d.ts +34 -0
  78. package/dist/config.d.ts.map +1 -1
  79. package/dist/config.js +58 -20
  80. package/dist/config.js.map +1 -1
  81. package/dist/context.d.ts +8 -0
  82. package/dist/context.d.ts.map +1 -1
  83. package/dist/context.js +1 -0
  84. package/dist/context.js.map +1 -1
  85. package/dist/deploy/defaults.d.ts.map +1 -1
  86. package/dist/deploy/defaults.js +5 -1
  87. package/dist/deploy/defaults.js.map +1 -1
  88. package/dist/deploy/post.d.ts +9 -1
  89. package/dist/deploy/post.d.ts.map +1 -1
  90. package/dist/deploy/post.js +100 -2
  91. package/dist/deploy/post.js.map +1 -1
  92. package/dist/deploy/response.d.ts.map +1 -1
  93. package/dist/deploy/response.js +3 -0
  94. package/dist/deploy/response.js.map +1 -1
  95. package/dist/deploy/runners.d.ts +67 -0
  96. package/dist/deploy/runners.d.ts.map +1 -1
  97. package/dist/dev/blocked.d.ts +57 -0
  98. package/dist/dev/blocked.d.ts.map +1 -0
  99. package/dist/dev/blocked.js +127 -0
  100. package/dist/dev/blocked.js.map +1 -0
  101. package/dist/dev/defaults.d.ts +2 -1
  102. package/dist/dev/defaults.d.ts.map +1 -1
  103. package/dist/dev/defaults.js +20 -5
  104. package/dist/dev/defaults.js.map +1 -1
  105. package/dist/dev/port.d.ts +2 -1
  106. package/dist/dev/port.d.ts.map +1 -1
  107. package/dist/dev/port.js +11 -3
  108. package/dist/dev/port.js.map +1 -1
  109. package/dist/dev/preview-expiry.d.ts +35 -0
  110. package/dist/dev/preview-expiry.d.ts.map +1 -0
  111. package/dist/dev/preview-expiry.js +57 -0
  112. package/dist/dev/preview-expiry.js.map +1 -0
  113. package/dist/dev/runners.d.ts +6 -2
  114. package/dist/dev/runners.d.ts.map +1 -1
  115. package/dist/dev/runtime-container.d.ts +2 -0
  116. package/dist/dev/runtime-container.d.ts.map +1 -1
  117. package/dist/dev/runtime-container.js +18 -5
  118. package/dist/dev/runtime-container.js.map +1 -1
  119. package/dist/dev/runtime-image.d.ts +4 -3
  120. package/dist/dev/runtime-image.d.ts.map +1 -1
  121. package/dist/dev/runtime-image.js +4 -3
  122. package/dist/dev/runtime-image.js.map +1 -1
  123. package/dist/dev/runtime-registry.d.ts +6 -11
  124. package/dist/dev/runtime-registry.d.ts.map +1 -1
  125. package/dist/dev/runtime-registry.js +26 -17
  126. package/dist/dev/runtime-registry.js.map +1 -1
  127. package/dist/init/augment-scaffolder.d.ts +1 -1
  128. package/dist/init/augment-scaffolder.d.ts.map +1 -1
  129. package/dist/init/augment-scaffolder.js +5 -3
  130. package/dist/init/augment-scaffolder.js.map +1 -1
  131. package/dist/init/dependency-specs.d.ts +1 -1
  132. package/dist/init/dependency-specs.d.ts.map +1 -1
  133. package/dist/init/dependency-specs.js +1 -1
  134. package/dist/init/dependency-specs.js.map +1 -1
  135. package/dist/init/gitignore-patcher.d.ts +13 -3
  136. package/dist/init/gitignore-patcher.d.ts.map +1 -1
  137. package/dist/init/gitignore-patcher.js +8 -4
  138. package/dist/init/gitignore-patcher.js.map +1 -1
  139. package/dist/init/java-augment.js +1 -1
  140. package/dist/init/java-augment.js.map +1 -1
  141. package/dist/init/mode-detect.d.ts.map +1 -1
  142. package/dist/init/mode-detect.js +3 -2
  143. package/dist/init/mode-detect.js.map +1 -1
  144. package/dist/init/python-augment.d.ts.map +1 -1
  145. package/dist/init/python-augment.js +5 -4
  146. package/dist/init/python-augment.js.map +1 -1
  147. package/dist/init/scala-augment.js +2 -2
  148. package/dist/init/scala-augment.js.map +1 -1
  149. package/dist/license/expiry.d.ts +3 -1
  150. package/dist/license/expiry.d.ts.map +1 -1
  151. package/dist/license/expiry.js +4 -2
  152. package/dist/license/expiry.js.map +1 -1
  153. package/dist/license/license-key.d.ts.map +1 -1
  154. package/dist/license/license-key.js +2 -0
  155. package/dist/license/license-key.js.map +1 -1
  156. package/dist/license/protocol.d.ts +25 -0
  157. package/dist/license/protocol.d.ts.map +1 -1
  158. package/dist/license/protocol.js +65 -0
  159. package/dist/license/protocol.js.map +1 -1
  160. package/dist/license/renew.d.ts +18 -1
  161. package/dist/license/renew.d.ts.map +1 -1
  162. package/dist/license/renew.js +33 -4
  163. package/dist/license/renew.js.map +1 -1
  164. package/dist/license/stores.d.ts.map +1 -1
  165. package/dist/license/stores.js +2 -1
  166. package/dist/license/stores.js.map +1 -1
  167. package/dist/main.d.ts +3 -0
  168. package/dist/main.d.ts.map +1 -1
  169. package/dist/main.js +1 -0
  170. package/dist/main.js.map +1 -1
  171. package/dist/providers/models-guide.d.ts +7 -0
  172. package/dist/providers/models-guide.d.ts.map +1 -0
  173. package/dist/providers/models-guide.js +11 -0
  174. package/dist/providers/models-guide.js.map +1 -0
  175. package/dist/rate-limit-wait.d.ts +42 -0
  176. package/dist/rate-limit-wait.d.ts.map +1 -0
  177. package/dist/rate-limit-wait.js +104 -0
  178. package/dist/rate-limit-wait.js.map +1 -0
  179. package/dist/sdk-skills/kindgi-authoring-agents/SKILL.md +1 -1
  180. package/dist/sdk-skills/kindgi-authoring-flows/SKILL.md +1 -1
  181. package/dist/sdk-skills/kindgi-authoring-guardrails/SKILL.md +1 -1
  182. package/dist/sdk-skills/kindgi-authoring-mcp-servers/SKILL.md +1 -1
  183. package/dist/sdk-skills/kindgi-authoring-providers/SKILL.md +75 -5
  184. package/dist/sdk-skills/kindgi-authoring-tools/SKILL.md +4 -2
  185. package/dist/sdk-skills/kindgi-framework-feedback/SKILL.md +1 -1
  186. package/dist/sdk-skills/kindgi-getting-started/SKILL.md +37 -11
  187. package/dist/sdk-skills/kindgi-java-authoring-agents/SKILL.md +3 -3
  188. package/dist/sdk-skills/kindgi-java-authoring-flows/SKILL.md +9 -3
  189. package/dist/sdk-skills/kindgi-java-authoring-guardrails/SKILL.md +3 -3
  190. package/dist/sdk-skills/kindgi-java-authoring-tools/SKILL.md +9 -4
  191. package/dist/sdk-skills/kindgi-java-getting-started/SKILL.md +33 -8
  192. package/dist/sdk-skills/kindgi-python-authoring-agents/SKILL.md +1 -1
  193. package/dist/sdk-skills/kindgi-python-authoring-flows/SKILL.md +1 -1
  194. package/dist/sdk-skills/kindgi-python-authoring-guardrails/SKILL.md +1 -1
  195. package/dist/sdk-skills/kindgi-python-authoring-tools/SKILL.md +6 -2
  196. package/dist/sdk-skills/kindgi-python-getting-started/SKILL.md +33 -8
  197. package/dist/sdk-skills/kindgi-scala-authoring-agents/SKILL.md +3 -3
  198. package/dist/sdk-skills/kindgi-scala-authoring-flows/SKILL.md +9 -3
  199. package/dist/sdk-skills/kindgi-scala-authoring-guardrails/SKILL.md +3 -3
  200. package/dist/sdk-skills/kindgi-scala-authoring-tools/SKILL.md +9 -4
  201. package/dist/sdk-skills/kindgi-scala-getting-started/SKILL.md +33 -8
  202. package/dist/sdk-skills/kindgi-using/SKILL.md +1 -1
  203. package/dist/templates/drupal/AGENTS.md +40 -15
  204. package/dist/templates/drupal/README.md.tmpl +2 -3
  205. package/dist/templates/drupal/kindgi.config.ts.tmpl +23 -19
  206. package/dist/templates/java/AGENTS.md +32 -3
  207. package/dist/templates/java/README.md.tmpl +1 -1
  208. package/dist/templates/minimal/AGENTS.md +42 -17
  209. package/dist/templates/minimal/README.md.tmpl +11 -10
  210. package/dist/templates/minimal/kindgi.config.ts.tmpl +23 -22
  211. package/dist/templates/python/AGENTS.md +28 -8
  212. package/dist/templates/python/README.md.tmpl +1 -1
  213. package/dist/templates/python/pyproject.toml.tmpl +10 -6
  214. package/dist/templates/sample/AGENTS.md +42 -17
  215. package/dist/templates/sample/README.md.tmpl +1 -1
  216. package/dist/templates/sample/kindgi.config.ts.tmpl +23 -19
  217. package/dist/templates/scala/AGENTS.md +32 -3
  218. package/dist/templates/scala/README.md.tmpl +1 -1
  219. package/dist/templates/woocommerce/AGENTS.md +38 -13
  220. package/dist/templates/woocommerce/README.md.tmpl +28 -3
  221. package/dist/templates/woocommerce/kindgi.config.ts.tmpl +23 -19
  222. package/package.json +13 -13
@@ -10,12 +10,12 @@ Agents answer through a model provider. `kindgi dev` gives a new pack
10
10
  `dev-echo`, a fallback that isn't a model: it calls the first tool and
11
11
  replies "Tool responded: …" after a warning line, while no other provider
12
12
  fits. For a real model, put one LLM provider's key in `.env`
13
- (`ANTHROPIC_API_KEY`, `OPENAI_API_KEY`, `GEMINI_API_KEY`, `GROQ_API_KEY` or
14
- `OPENROUTER_API_KEY`) and declare its preset (`{ preset: 'anthropic' }`,
15
- `'openai'`, `'gemini-api'`, `'groq'` or `'openrouter'`) in
16
- `kindgi.config.ts`'s `providers`: `kindgi dev` then registers it on every
17
- boot, in every worktree. Other providers and per-agent model choice:
18
- `.claude/skills/kindgi-authoring-providers/SKILL.md`.
13
+ (`ANTHROPIC_API_KEY`, `OPENAI_API_KEY`, `GEMINI_API_KEY`, `GROQ_API_KEY`
14
+ or `OPENROUTER_API_KEY`) and declare its preset
15
+ (`{ preset: 'anthropic' }`, `'openai'`, `'gemini-api'`, `'groq'` or
16
+ `'openrouter'`) in `kindgi.config.ts`'s `providers`: `kindgi dev` then
17
+ registers it on every boot, in every worktree. Other providers and
18
+ per-agent model choice: the `kindgi-authoring-providers` skill.
19
19
 
20
20
  ## This pack: a Drupal site
21
21
 
@@ -46,17 +46,42 @@ README.md explains the whole design; keep it true when you change the pack.
46
46
  - **The client secret is a secret** (`DRUPAL_CLIENT_SECRET`, set with
47
47
  `kindgi secrets set`): never write it in a file, a test or the chat.
48
48
 
49
- ## For Claude Code sessions
49
+ ## Skills
50
50
 
51
- When you diagnose a framework bug (something in Kindgi itself, not in
52
- this pack's code), append an entry to `FEEDBACK.md` at the pack root
53
- via `kindgi feedback write` — see
54
- `.claude/skills/kindgi-framework-feedback/SKILL.md`. Mark items fixed
55
- by adding a `> **Fixed:** <note>` line right after their header; the
56
- file is a plain markdown list you edit directly.
51
+ `.claude/skills/` and `.agents/skills/` hold the same Kindgi skills: getting
52
+ started, tools, guardrails, agents and flows, model providers, MCP servers,
53
+ framework feedback, and guiding the person in using what you built
54
+ (`kindgi-using`). Claude Code loads `.claude/skills/` on its own; Codex and
55
+ Gemini CLI look in `.agents/skills/`; any other coding agent can read
56
+ either. `kindgi skills sync` refreshes both.
57
+
58
+ When you diagnose a framework bug (something in Kindgi itself, not in this
59
+ pack's code), append an entry to `FEEDBACK.md` at the pack root via
60
+ `kindgi feedback write` — see the `kindgi-framework-feedback` skill. Mark
61
+ items fixed by adding a `> **Fixed:** <note>` line right after their
62
+ header; the file is a plain markdown list you edit directly.
57
63
 
58
64
  When the person asks how to use what you built (where something is in
59
65
  Kindgi's console, what an agent did, what it cost, who has access), answer
60
66
  from `kindgi`'s read-only commands and give the console link beside it —
61
- see `.claude/skills/kindgi-using/SKILL.md`. Deciding approvals, erasing,
62
- adding people and rating answers stay with the person.
67
+ see the `kindgi-using` skill. Deciding approvals, erasing, adding people
68
+ and rating answers stay with the person.
69
+
70
+ ## Commands for the person's own terminal
71
+
72
+ Two commands are always the person's to run, in their own terminal, since
73
+ they ask for a secret: `kindgi secrets set` and `kindgi auth registry`.
74
+ Others need what a coding agent's sandbox often blocks: `kindgi dev` and any
75
+ dev server (they keep running), and `kindgi build` or anything else that
76
+ needs Docker. When your sandbox blocks a command (a process it can't start,
77
+ `spawn EPERM`; Docker's socket denied; `localhost` refused; a folder it
78
+ keeps read-only, as Codex's keeps `.agents/`, which `kindgi skills sync`
79
+ writes), don't work around it: don't turn your sandbox off, and don't start
80
+ the command in the background. Give the person the exact command, the folder
81
+ to run it in and what they'll see, then wait for them. Once they say
82
+ `kindgi dev` is running, starting it yourself exits 3 and says where theirs
83
+ runs: use that one.
84
+
85
+ A tool's own `EPERM` while it runs under `kindgi dev` is something else:
86
+ Kindgi's dev sandbox, which the tools skill covers. Never turn that one off
87
+ either.
@@ -218,8 +218,7 @@ calls the first tool. For Claude, with `kindgi dev` running:
218
218
  {{KINDGI}} providers register --preset=anthropic
219
219
  ```
220
220
 
221
- `.claude/skills/kindgi-authoring-providers/SKILL.md` has the other
222
- providers.
221
+ The `kindgi-authoring-providers` skill has the other providers.
223
222
 
224
223
  Ask the content agent something:
225
224
 
@@ -286,7 +285,7 @@ starts a run:
286
285
  ```sh
287
286
  composer require drupal/webhooks:^3.0@rc && drush en webhooks
288
287
  {{KINDGI}} webhooks register --flow={{PACK_ID}}.content-review --flow-version={{PACK_VERSION}} \
289
- --preset=drupal-webhooks --generate-secret --secret=DRUPAL_WEBHOOK_SECRET --env=local \
288
+ --preset=drupal-webhooks --generate-secret --secret=DRUPAL_WEBHOOK_SECRET \
290
289
  --label="Drupal articles"
291
290
  ```
292
291
 
@@ -13,28 +13,32 @@ const config = {
13
13
  flows: 'flows/**/*.ts',
14
14
  },
15
15
  // ---------------------------------------------------------------
16
- // Environments — one entry per deploy target. `kindgi build`
17
- // reads `.build`, `.registry`, `.signingKey`, `.tenantId` for the
18
- // chosen env; `kindgi deploy` reads `.endpoint`.
16
+ // Environments: one entry per place you deploy to, picked with
17
+ // `--env <name>` (default `staging`). `kindgi build` reads `build`,
18
+ // `registry`, `signingKey` and `tenantId`; `kindgi deploy` reads
19
+ // `endpoint`. Local `kindgi dev` doesn't read this block.
19
20
  //
20
- // Fill these in when you're ready to push a build. Local
21
- // `kindgi dev` does NOT read this block.
21
+ // Your API key goes only to the address you signed in to
22
+ // (`kindgi auth login --url <url>`), so an `endpoint` here must be
23
+ // that address. Builds are signed with a key of yours: make it with
24
+ // `kindgi key create <id>`, and let the runtime trust it with
25
+ // `kindgi key trust <id>` (once).
22
26
  // ---------------------------------------------------------------
23
27
  environments: {
24
- staging: {
25
- endpoint: 'https://api.staging.example.com',
26
- build: 'http://localhost:8787', // your Kindgi build server
27
- registry: 'ghcr.io/your-org',
28
- signingKey: '~/.kindgi/keys/staging.pem',
29
- tenantId: 'tenant-your-org-staging',
30
- },
31
- production: {
32
- endpoint: 'https://api.example.com',
33
- build: 'https://build.example.com',
34
- registry: 'ghcr.io/your-org',
35
- signingKey: '~/.kindgi/keys/production.pem',
36
- tenantId: 'tenant-your-org-production',
37
- },
28
+ // Kindgi Cloud: `kindgi deploy --env=prod` builds there and deploys.
29
+ // prod: {
30
+ // build: 'hosted',
31
+ // signingKey: '~/.kindgi/keys/<id>.pem',
32
+ // },
33
+ //
34
+ // A runtime of your own:
35
+ // production: {
36
+ // endpoint: 'https://kindgi.your-company.example', // the address you signed in to
37
+ // build: 'https://build.your-company.example', // your Kindgi build server
38
+ // registry: 'ghcr.io/your-org',
39
+ // signingKey: '~/.kindgi/keys/<id>.pem',
40
+ // tenantId: '<your tenant id>',
41
+ // },
38
42
  },
39
43
  } as const;
40
44
 
@@ -26,12 +26,41 @@ The config is `kindgi.config.json`.
26
26
  `"openrouter"`) to `kindgi.config.json`: `kindgi dev` then registers it on
27
27
  every boot, in every worktree.
28
28
 
29
+ ## Skills
30
+
31
+ `.claude/skills/` and `.agents/skills/` hold the same Kindgi skills for Java
32
+ packs: getting started, tools, guardrails, agents and flows in Java
33
+ (`kindgi-java-*`), model providers, MCP servers, framework feedback, and
34
+ guiding the person in using what you built (`kindgi-using`). Claude Code
35
+ loads `.claude/skills/` on its own; Codex and Gemini CLI look in
36
+ `.agents/skills/`; any other coding agent can read either.
37
+ `kindgi skills sync` refreshes both.
38
+
29
39
  When you diagnose a framework bug (something in Kindgi itself, not in this
30
40
  pack's code), append an entry to `FEEDBACK.md` at the pack root with
31
41
  `kindgi feedback write`.
32
42
 
33
43
  When the person asks how to use what you built (where something is in
34
44
  Kindgi's console, what an agent did, what it cost, who has access), answer
35
- from `kindgi`'s read-only commands and give the console link beside it: see
36
- `.claude/skills/kindgi-using/SKILL.md`. Deciding approvals, erasing, adding
37
- people and rating answers stay with the person.
45
+ from `kindgi`'s read-only commands and give the console link beside it:
46
+ see the `kindgi-using` skill. Deciding approvals, erasing, adding people
47
+ and rating answers stay with the person.
48
+
49
+ ## Commands for the person's own terminal
50
+
51
+ Two commands are always the person's to run, in their own terminal, since
52
+ they ask for a secret: `./kindgiw secrets set` and
53
+ `./kindgiw auth registry`. Others need what a coding agent's sandbox often
54
+ blocks: `./kindgiw dev` and any dev server (they keep running), and
55
+ `./kindgiw build` or anything else that needs Docker. When your sandbox
56
+ blocks a command (a process it can't start, `spawn EPERM`; Docker's socket
57
+ denied; `localhost` refused; a folder it keeps read-only, as Codex's keeps
58
+ `.agents/`, which `./kindgiw skills sync` writes), don't work around it:
59
+ don't turn your sandbox off, and don't start the command in the background.
60
+ Give the person the exact command, the folder to run it in and what they'll
61
+ see, then wait for them. Once they say `./kindgiw dev` is running, starting
62
+ it yourself exits 3 and says where theirs runs: use that one.
63
+
64
+ A tool's own `EPERM` while it runs under `./kindgiw dev` is something else:
65
+ Kindgi's dev sandbox, which the tools skill covers. Never turn that one off
66
+ either.
@@ -6,7 +6,7 @@ Two tools (`echo`, `greet`), one guardrail (`response-not-empty`), one agent
6
6
  that uses both tools and the guardrail, and one flow that runs the echo tool.
7
7
 
8
8
  Java and Scala support is in preview: tested and supported, but the API may
9
- still change in 0.1.6 without the usual deprecation period.
9
+ still change in a later release without the usual deprecation period.
10
10
 
11
11
  ## Layout
12
12
 
@@ -10,24 +10,49 @@ Agents answer through a model provider. `kindgi dev` gives a new pack
10
10
  `dev-echo`, a fallback that isn't a model: it calls the first tool and
11
11
  replies "Tool responded: …" after a warning line, while no other provider
12
12
  fits. For a real model, put one LLM provider's key in `.env`
13
- (`ANTHROPIC_API_KEY`, `OPENAI_API_KEY`, `GEMINI_API_KEY`, `GROQ_API_KEY` or
14
- `OPENROUTER_API_KEY`) and declare its preset (`{ preset: 'anthropic' }`,
15
- `'openai'`, `'gemini-api'`, `'groq'` or `'openrouter'`) in
16
- `kindgi.config.ts`'s `providers`: `kindgi dev` then registers it on every
17
- boot, in every worktree. Other providers and per-agent model choice:
18
- `.claude/skills/kindgi-authoring-providers/SKILL.md`.
19
-
20
- ## For Claude Code sessions
21
-
22
- When you diagnose a framework bug (something in Kindgi itself, not in
23
- this pack's code), append an entry to `FEEDBACK.md` at the pack root
24
- via `kindgi feedback write` — see
25
- `.claude/skills/kindgi-framework-feedback/SKILL.md`. Mark items fixed
26
- by adding a `> **Fixed:** <note>` line right after their header; the
27
- file is a plain markdown list you edit directly.
13
+ (`ANTHROPIC_API_KEY`, `OPENAI_API_KEY`, `GEMINI_API_KEY`, `GROQ_API_KEY`
14
+ or `OPENROUTER_API_KEY`) and declare its preset
15
+ (`{ preset: 'anthropic' }`, `'openai'`, `'gemini-api'`, `'groq'` or
16
+ `'openrouter'`) in `kindgi.config.ts`'s `providers`: `kindgi dev` then
17
+ registers it on every boot, in every worktree. Other providers and
18
+ per-agent model choice: the `kindgi-authoring-providers` skill.
19
+
20
+ ## Skills
21
+
22
+ `.claude/skills/` and `.agents/skills/` hold the same Kindgi skills: getting
23
+ started, tools, guardrails, agents and flows, model providers, MCP servers,
24
+ framework feedback, and guiding the person in using what you built
25
+ (`kindgi-using`). Claude Code loads `.claude/skills/` on its own; Codex and
26
+ Gemini CLI look in `.agents/skills/`; any other coding agent can read
27
+ either. `kindgi skills sync` refreshes both.
28
+
29
+ When you diagnose a framework bug (something in Kindgi itself, not in this
30
+ pack's code), append an entry to `FEEDBACK.md` at the pack root via
31
+ `kindgi feedback write` — see the `kindgi-framework-feedback` skill. Mark
32
+ items fixed by adding a `> **Fixed:** <note>` line right after their
33
+ header; the file is a plain markdown list you edit directly.
28
34
 
29
35
  When the person asks how to use what you built (where something is in
30
36
  Kindgi's console, what an agent did, what it cost, who has access), answer
31
37
  from `kindgi`'s read-only commands and give the console link beside it —
32
- see `.claude/skills/kindgi-using/SKILL.md`. Deciding approvals, erasing,
33
- adding people and rating answers stay with the person.
38
+ see the `kindgi-using` skill. Deciding approvals, erasing, adding people
39
+ and rating answers stay with the person.
40
+
41
+ ## Commands for the person's own terminal
42
+
43
+ Two commands are always the person's to run, in their own terminal, since
44
+ they ask for a secret: `kindgi secrets set` and `kindgi auth registry`.
45
+ Others need what a coding agent's sandbox often blocks: `kindgi dev` and any
46
+ dev server (they keep running), and `kindgi build` or anything else that
47
+ needs Docker. When your sandbox blocks a command (a process it can't start,
48
+ `spawn EPERM`; Docker's socket denied; `localhost` refused; a folder it
49
+ keeps read-only, as Codex's keeps `.agents/`, which `kindgi skills sync`
50
+ writes), don't work around it: don't turn your sandbox off, and don't start
51
+ the command in the background. Give the person the exact command, the folder
52
+ to run it in and what they'll see, then wait for them. Once they say
53
+ `kindgi dev` is running, starting it yourself exits 3 and says where theirs
54
+ runs: use that one.
55
+
56
+ A tool's own `EPERM` while it runs under `kindgi dev` is something else:
57
+ Kindgi's dev sandbox, which the tools skill covers. Never turn that one off
58
+ either.
@@ -14,6 +14,7 @@ Author your first via `defineTool` / `defineAgent` / `defineCheck` /
14
14
  ├── package.json # depends on @kindgi/sdk + zod
15
15
  ├── tsconfig.json
16
16
  ├── .claude/skills/ # SDK skills — Claude Code auto-loads per task
17
+ ├── .agents/skills/ # the same skills, where Codex and Gemini CLI look
17
18
  ├── tools/ # place `<name>/index.ts` per tool
18
19
  ├── agents/ # place `<name>/index.ts` per agent
19
20
  ├── guardrails/ # place `<name>/index.ts` per check
@@ -22,15 +23,15 @@ Author your first via `defineTool` / `defineAgent` / `defineCheck` /
22
23
 
23
24
  ## AI coding assistants
24
25
 
25
- `.claude/skills/` is auto-populated at `kindgi init` with per-primitive
26
- guides: `kindgi-authoring-tools`, `kindgi-authoring-agents`,
27
- `kindgi-authoring-guardrails`, `kindgi-getting-started` — plus
28
- `kindgi-authoring-providers` (a real model), `kindgi-authoring-mcp-servers`,
29
- `kindgi-framework-feedback` and `kindgi-using` (guiding you in using what
30
- you built). Claude Code
31
- loads them on-demand based on what you're editing — no configuration
32
- needed. Read them directly if you want the mental model without an
33
- assistant in the loop.
26
+ `.claude/skills/` and `.agents/skills/` are auto-populated at `kindgi init`
27
+ with the same per-primitive guides: `kindgi-authoring-tools`,
28
+ `kindgi-authoring-agents`, `kindgi-authoring-guardrails`,
29
+ `kindgi-getting-started` — plus `kindgi-authoring-providers` (a real model),
30
+ `kindgi-authoring-mcp-servers`, `kindgi-framework-feedback` and
31
+ `kindgi-using` (guiding you in using what you built). Claude Code loads
32
+ `.claude/skills/` on demand, based on what you're editing; Codex and Gemini
33
+ CLI look in `.agents/skills/`. No configuration needed. Read them directly
34
+ if you want the mental model without an assistant in the loop.
34
35
 
35
36
  ## Run
36
37
 
@@ -67,4 +68,4 @@ Claude takes over from dev-echo on the next turn; nothing to restart.
67
68
  OpenRouter, a hosted service your prompts pass through (`OPENROUTER_API_KEY`,
68
69
  `--preset=openrouter`), work the same way; `kindgi providers presets` lists
69
70
  the presets (Gemini on Vertex AI too). Picking a model per
70
- agent, and other providers: `.claude/skills/kindgi-authoring-providers/SKILL.md`.
71
+ agent, and other providers: the `kindgi-authoring-providers` skill.
@@ -13,31 +13,32 @@ const config = {
13
13
  flows: 'flows/**/*.ts',
14
14
  },
15
15
  // ---------------------------------------------------------------
16
- // Environments — one entry per deploy target (staging / production
17
- // / preview / custom). Each names the build server endpoint, the
18
- // signing key path (Ed25519 PEM, never leaves the developer's
19
- // machine), the target registry (build server pushes here on your
20
- // behalf), and the tenantId the Kindgi runtime scopes the
21
- // deployment to. Consumed by `kindgi build` + `kindgi deploy`.
16
+ // Environments: one entry per place you deploy to, picked with
17
+ // `--env <name>` (default `staging`). `kindgi build` reads `build`,
18
+ // `registry`, `signingKey` and `tenantId`; `kindgi deploy` reads
19
+ // `endpoint`. Local `kindgi dev` doesn't read this block.
22
20
  //
23
- // Fill these in when you're ready to push a build off the laptop.
24
- // Local `kindgi dev` does NOT read this block.
21
+ // Your API key goes only to the address you signed in to
22
+ // (`kindgi auth login --url <url>`), so an `endpoint` here must be
23
+ // that address. Builds are signed with a key of yours: make it with
24
+ // `kindgi key create <id>`, and let the runtime trust it with
25
+ // `kindgi key trust <id>` (once).
25
26
  // ---------------------------------------------------------------
26
27
  environments: {
27
- staging: {
28
- endpoint: 'https://api.staging.example.com',
29
- build: 'http://localhost:8787', // your Kindgi build server
30
- registry: 'ghcr.io/your-org',
31
- signingKey: '~/.kindgi/keys/staging.pem',
32
- tenantId: 'tenant-your-org-staging',
33
- },
34
- production: {
35
- endpoint: 'https://api.example.com',
36
- build: 'https://build.example.com',
37
- registry: 'ghcr.io/your-org',
38
- signingKey: '~/.kindgi/keys/production.pem',
39
- tenantId: 'tenant-your-org-production',
40
- },
28
+ // Kindgi Cloud: `kindgi deploy --env=prod` builds there and deploys.
29
+ // prod: {
30
+ // build: 'hosted',
31
+ // signingKey: '~/.kindgi/keys/<id>.pem',
32
+ // },
33
+ //
34
+ // A runtime of your own:
35
+ // production: {
36
+ // endpoint: 'https://kindgi.your-company.example', // the address you signed in to
37
+ // build: 'https://build.your-company.example', // your Kindgi build server
38
+ // registry: 'ghcr.io/your-org',
39
+ // signingKey: '~/.kindgi/keys/<id>.pem',
40
+ // tenantId: '<your tenant id>',
41
+ // },
41
42
  },
42
43
  } as const;
43
44
 
@@ -19,17 +19,37 @@ starts with `_`. The config is `[tool.kindgi]` in `pyproject.toml`.
19
19
  preset (`preset = "anthropic"`, `"openai"`, `"gemini-api"`, `"groq"` or
20
20
  `"openrouter"`) to `pyproject.toml`: `kindgi dev` then registers it
21
21
  on every boot, in every worktree. Other providers and per-agent model
22
- choice: `.claude/skills/kindgi-authoring-providers/SKILL.md`.
22
+ choice: the `kindgi-authoring-providers` skill.
23
23
 
24
24
  ## Skills
25
25
 
26
- `.claude/skills/` holds Kindgi's skills for Python packs: getting started,
27
- tools, guardrails and agents in Python (`kindgi-python-*`), model providers,
28
- MCP servers, framework feedback, and guiding the person in using what you
29
- built (`kindgi-using`). Claude Code loads them on its own; other coding
30
- agents can read them. `kindgi skills sync` refreshes them.
26
+ `.claude/skills/` and `.agents/skills/` hold the same Kindgi skills for
27
+ Python packs: getting started, tools, guardrails and agents in Python
28
+ (`kindgi-python-*`), model providers, MCP servers, framework feedback, and
29
+ guiding the person in using what you built (`kindgi-using`). Claude Code
30
+ loads `.claude/skills/` on its own; Codex and Gemini CLI look in
31
+ `.agents/skills/`; any other coding agent can read either.
32
+ `kindgi skills sync` refreshes both.
31
33
 
32
34
  When you diagnose a framework bug (something in Kindgi itself, not in this
33
35
  pack's code), append an entry to `FEEDBACK.md` at the pack root via
34
- `kindgi feedback write` — see
35
- `.claude/skills/kindgi-framework-feedback/SKILL.md`.
36
+ `kindgi feedback write` — see the `kindgi-framework-feedback` skill.
37
+
38
+ ## Commands for the person's own terminal
39
+
40
+ Two commands are always the person's to run, in their own terminal, since
41
+ they ask for a secret: `kindgi secrets set` and `kindgi auth registry`.
42
+ Others need what a coding agent's sandbox often blocks: `kindgi dev` and any
43
+ dev server (they keep running), and `kindgi build` or anything else that
44
+ needs Docker. When your sandbox blocks a command (a process it can't start,
45
+ `spawn EPERM`; Docker's socket denied; `localhost` refused; a folder it
46
+ keeps read-only, as Codex's keeps `.agents/`, which `kindgi skills sync`
47
+ writes), don't work around it: don't turn your sandbox off, and don't start
48
+ the command in the background. Give the person the exact command, the folder
49
+ to run it in and what they'll see, then wait for them. Once they say
50
+ `kindgi dev` is running, starting it yourself exits 3 and says where theirs
51
+ runs: use that one.
52
+
53
+ A tool's own `EPERM` while it runs under `kindgi dev` is something else:
54
+ Kindgi's dev sandbox, which the tools skill covers. Never turn that one off
55
+ either.
@@ -53,7 +53,7 @@ Claude takes over from dev-echo on the next turn; nothing to restart.
53
53
  OpenRouter, a hosted service your prompts pass through (`OPENROUTER_API_KEY`,
54
54
  `--preset=openrouter`), work the same way; `kindgi providers presets` lists
55
55
  the presets (Gemini on Vertex AI too). Picking a model per
56
- agent, and other providers: `.claude/skills/kindgi-authoring-providers/SKILL.md`.
56
+ agent, and other providers: the `kindgi-authoring-providers` skill.
57
57
 
58
58
  ## Build
59
59
 
@@ -30,12 +30,16 @@ description = "A sample Kindgi pack in Python — two tools, one guardrail, one
30
30
  # python = ["uv", "run", "python"] # default: .venv/bin/python, else python3
31
31
  # envFiles = [".env", ".env.local"]
32
32
 
33
- # One block per deploy target; `kindgi build --env=<name>` reads it.
34
- # [tool.kindgi.environments.staging]
35
- # endpoint = "https://api.staging.example.com"
36
- # build = "http://localhost:4001"
37
- # tenantId = "tenant-your-org-staging"
38
- # signingKey = "~/.kindgi/keys/staging.pem"
33
+ # One block per place you deploy to; `kindgi build --env=<name>` reads it.
34
+ # Your API key goes only to the address you signed in to
35
+ # (`kindgi auth login --url <url>`), so an `endpoint` must be that address.
36
+ # Builds are signed with a key of yours: make it with `kindgi key create <id>`,
37
+ # and let the runtime trust it with `kindgi key trust <id>` (once).
38
+ # [tool.kindgi.environments.production]
39
+ # endpoint = "https://kindgi.your-company.example" # the address you signed in to
40
+ # build = "https://build.your-company.example" # your Kindgi build server
41
+ # tenantId = "<your tenant id>"
42
+ # signingKey = "~/.kindgi/keys/<id>.pem"
39
43
 
40
44
  [tool.pytest.ini_options]
41
45
  testpaths = ["tests"]
@@ -10,24 +10,49 @@ Agents answer through a model provider. `kindgi dev` gives a new pack
10
10
  `dev-echo`, a fallback that isn't a model: it calls the first tool and
11
11
  replies "Tool responded: …" after a warning line, while no other provider
12
12
  fits. For a real model, put one LLM provider's key in `.env`
13
- (`ANTHROPIC_API_KEY`, `OPENAI_API_KEY`, `GEMINI_API_KEY`, `GROQ_API_KEY` or
14
- `OPENROUTER_API_KEY`) and declare its preset (`{ preset: 'anthropic' }`,
15
- `'openai'`, `'gemini-api'`, `'groq'` or `'openrouter'`) in
16
- `kindgi.config.ts`'s `providers`: `kindgi dev` then registers it on every
17
- boot, in every worktree. Other providers and per-agent model choice:
18
- `.claude/skills/kindgi-authoring-providers/SKILL.md`.
19
-
20
- ## For Claude Code sessions
21
-
22
- When you diagnose a framework bug (something in Kindgi itself, not in
23
- this pack's code), append an entry to `FEEDBACK.md` at the pack root
24
- via `kindgi feedback write` — see
25
- `.claude/skills/kindgi-framework-feedback/SKILL.md`. Mark items fixed
26
- by adding a `> **Fixed:** <note>` line right after their header; the
27
- file is a plain markdown list you edit directly.
13
+ (`ANTHROPIC_API_KEY`, `OPENAI_API_KEY`, `GEMINI_API_KEY`, `GROQ_API_KEY`
14
+ or `OPENROUTER_API_KEY`) and declare its preset
15
+ (`{ preset: 'anthropic' }`, `'openai'`, `'gemini-api'`, `'groq'` or
16
+ `'openrouter'`) in `kindgi.config.ts`'s `providers`: `kindgi dev` then
17
+ registers it on every boot, in every worktree. Other providers and
18
+ per-agent model choice: the `kindgi-authoring-providers` skill.
19
+
20
+ ## Skills
21
+
22
+ `.claude/skills/` and `.agents/skills/` hold the same Kindgi skills: getting
23
+ started, tools, guardrails, agents and flows, model providers, MCP servers,
24
+ framework feedback, and guiding the person in using what you built
25
+ (`kindgi-using`). Claude Code loads `.claude/skills/` on its own; Codex and
26
+ Gemini CLI look in `.agents/skills/`; any other coding agent can read
27
+ either. `kindgi skills sync` refreshes both.
28
+
29
+ When you diagnose a framework bug (something in Kindgi itself, not in this
30
+ pack's code), append an entry to `FEEDBACK.md` at the pack root via
31
+ `kindgi feedback write` — see the `kindgi-framework-feedback` skill. Mark
32
+ items fixed by adding a `> **Fixed:** <note>` line right after their
33
+ header; the file is a plain markdown list you edit directly.
28
34
 
29
35
  When the person asks how to use what you built (where something is in
30
36
  Kindgi's console, what an agent did, what it cost, who has access), answer
31
37
  from `kindgi`'s read-only commands and give the console link beside it —
32
- see `.claude/skills/kindgi-using/SKILL.md`. Deciding approvals, erasing,
33
- adding people and rating answers stay with the person.
38
+ see the `kindgi-using` skill. Deciding approvals, erasing, adding people
39
+ and rating answers stay with the person.
40
+
41
+ ## Commands for the person's own terminal
42
+
43
+ Two commands are always the person's to run, in their own terminal, since
44
+ they ask for a secret: `kindgi secrets set` and `kindgi auth registry`.
45
+ Others need what a coding agent's sandbox often blocks: `kindgi dev` and any
46
+ dev server (they keep running), and `kindgi build` or anything else that
47
+ needs Docker. When your sandbox blocks a command (a process it can't start,
48
+ `spawn EPERM`; Docker's socket denied; `localhost` refused; a folder it
49
+ keeps read-only, as Codex's keeps `.agents/`, which `kindgi skills sync`
50
+ writes), don't work around it: don't turn your sandbox off, and don't start
51
+ the command in the background. Give the person the exact command, the folder
52
+ to run it in and what they'll see, then wait for them. Once they say
53
+ `kindgi dev` is running, starting it yourself exits 3 and says where theirs
54
+ runs: use that one.
55
+
56
+ A tool's own `EPERM` while it runs under `kindgi dev` is something else:
57
+ Kindgi's dev sandbox, which the tools skill covers. Never turn that one off
58
+ either.
@@ -58,7 +58,7 @@ Claude takes over from dev-echo on the next turn; nothing to restart.
58
58
  OpenRouter, a hosted service your prompts pass through (`OPENROUTER_API_KEY`,
59
59
  `--preset=openrouter`), work the same way; `kindgi providers presets` lists
60
60
  the presets (Gemini on Vertex AI too). Picking a model per
61
- agent, and other providers: `.claude/skills/kindgi-authoring-providers/SKILL.md`.
61
+ agent, and other providers: the `kindgi-authoring-providers` skill.
62
62
 
63
63
  ## The four primitives (one file each)
64
64
 
@@ -13,28 +13,32 @@ const config = {
13
13
  flows: 'flows/**/*.ts',
14
14
  },
15
15
  // ---------------------------------------------------------------
16
- // Environments — one entry per deploy target. `kindgi build`
17
- // reads `.build`, `.registry`, `.signingKey`, `.tenantId` for the
18
- // chosen env; `kindgi deploy` reads `.endpoint`.
16
+ // Environments: one entry per place you deploy to, picked with
17
+ // `--env <name>` (default `staging`). `kindgi build` reads `build`,
18
+ // `registry`, `signingKey` and `tenantId`; `kindgi deploy` reads
19
+ // `endpoint`. Local `kindgi dev` doesn't read this block.
19
20
  //
20
- // Fill these in when you're ready to push a build. Local
21
- // `kindgi dev` does NOT read this block.
21
+ // Your API key goes only to the address you signed in to
22
+ // (`kindgi auth login --url <url>`), so an `endpoint` here must be
23
+ // that address. Builds are signed with a key of yours: make it with
24
+ // `kindgi key create <id>`, and let the runtime trust it with
25
+ // `kindgi key trust <id>` (once).
22
26
  // ---------------------------------------------------------------
23
27
  environments: {
24
- staging: {
25
- endpoint: 'https://api.staging.example.com',
26
- build: 'http://localhost:8787', // your Kindgi build server
27
- registry: 'ghcr.io/your-org',
28
- signingKey: '~/.kindgi/keys/staging.pem',
29
- tenantId: 'tenant-your-org-staging',
30
- },
31
- production: {
32
- endpoint: 'https://api.example.com',
33
- build: 'https://build.example.com',
34
- registry: 'ghcr.io/your-org',
35
- signingKey: '~/.kindgi/keys/production.pem',
36
- tenantId: 'tenant-your-org-production',
37
- },
28
+ // Kindgi Cloud: `kindgi deploy --env=prod` builds there and deploys.
29
+ // prod: {
30
+ // build: 'hosted',
31
+ // signingKey: '~/.kindgi/keys/<id>.pem',
32
+ // },
33
+ //
34
+ // A runtime of your own:
35
+ // production: {
36
+ // endpoint: 'https://kindgi.your-company.example', // the address you signed in to
37
+ // build: 'https://build.your-company.example', // your Kindgi build server
38
+ // registry: 'ghcr.io/your-org',
39
+ // signingKey: '~/.kindgi/keys/<id>.pem',
40
+ // tenantId: '<your tenant id>',
41
+ // },
38
42
  },
39
43
  } as const;
40
44