@kindgi/cli 0.1.5-rc.0 → 0.1.6-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.
- package/README.md +4 -1
- package/dist/build/bundle.d.ts +11 -3
- package/dist/build/bundle.d.ts.map +1 -1
- package/dist/build/bundle.js +17 -3
- package/dist/build/bundle.js.map +1 -1
- package/dist/build/defaults.d.ts.map +1 -1
- package/dist/build/defaults.js +6 -0
- package/dist/build/defaults.js.map +1 -1
- package/dist/build/java-image.d.ts +6 -0
- package/dist/build/java-image.d.ts.map +1 -1
- package/dist/build/java-image.js +4 -1
- package/dist/build/java-image.js.map +1 -1
- package/dist/build/runners.d.ts +2 -0
- package/dist/build/runners.d.ts.map +1 -1
- package/dist/build/scala-image.d.ts +6 -0
- package/dist/build/scala-image.d.ts.map +1 -1
- package/dist/build/scala-image.js +4 -1
- package/dist/build/scala-image.js.map +1 -1
- package/dist/commands/agents.d.ts.map +1 -1
- package/dist/commands/agents.js +23 -7
- package/dist/commands/agents.js.map +1 -1
- package/dist/commands/approvals.d.ts.map +1 -1
- package/dist/commands/approvals.js +23 -3
- package/dist/commands/approvals.js.map +1 -1
- package/dist/commands/build.d.ts.map +1 -1
- package/dist/commands/build.js +32 -3
- package/dist/commands/build.js.map +1 -1
- package/dist/commands/deploy.js +1 -1
- package/dist/commands/deploy.js.map +1 -1
- package/dist/commands/dev.d.ts.map +1 -1
- package/dist/commands/dev.js +129 -18
- package/dist/commands/dev.js.map +1 -1
- package/dist/commands/doctor.d.ts +4 -1
- package/dist/commands/doctor.d.ts.map +1 -1
- package/dist/commands/doctor.js +42 -7
- package/dist/commands/doctor.js.map +1 -1
- package/dist/commands/env.d.ts.map +1 -1
- package/dist/commands/env.js +53 -7
- package/dist/commands/env.js.map +1 -1
- package/dist/commands/eval-runs.d.ts.map +1 -1
- package/dist/commands/eval-runs.js +27 -2
- package/dist/commands/eval-runs.js.map +1 -1
- package/dist/commands/eval-suites.d.ts.map +1 -1
- package/dist/commands/eval-suites.js +16 -6
- package/dist/commands/eval-suites.js.map +1 -1
- package/dist/commands/flows.d.ts.map +1 -1
- package/dist/commands/flows.js +23 -5
- package/dist/commands/flows.js.map +1 -1
- package/dist/commands/helpers.d.ts +10 -0
- package/dist/commands/helpers.d.ts.map +1 -1
- package/dist/commands/helpers.js +35 -0
- package/dist/commands/helpers.js.map +1 -1
- package/dist/commands/init.d.ts.map +1 -1
- package/dist/commands/init.js +29 -0
- package/dist/commands/init.js.map +1 -1
- package/dist/commands/mcp.d.ts.map +1 -1
- package/dist/commands/mcp.js +8 -1
- package/dist/commands/mcp.js.map +1 -1
- package/dist/commands/memory.d.ts.map +1 -1
- package/dist/commands/memory.js +4 -4
- package/dist/commands/memory.js.map +1 -1
- package/dist/commands/proposals.d.ts.map +1 -1
- package/dist/commands/proposals.js +30 -10
- package/dist/commands/proposals.js.map +1 -1
- package/dist/commands/provenance.d.ts.map +1 -1
- package/dist/commands/provenance.js +3 -3
- package/dist/commands/provenance.js.map +1 -1
- package/dist/commands/providers.d.ts.map +1 -1
- package/dist/commands/providers.js +20 -2
- package/dist/commands/providers.js.map +1 -1
- package/dist/commands/run-waits.d.ts +28 -2
- package/dist/commands/run-waits.d.ts.map +1 -1
- package/dist/commands/run-waits.js +22 -3
- package/dist/commands/run-waits.js.map +1 -1
- package/dist/commands/runs.d.ts.map +1 -1
- package/dist/commands/runs.js +16 -2
- package/dist/commands/runs.js.map +1 -1
- package/dist/commands/schedules.d.ts.map +1 -1
- package/dist/commands/schedules.js +9 -4
- package/dist/commands/schedules.js.map +1 -1
- package/dist/commands/secrets-copy.d.ts +3 -0
- package/dist/commands/secrets-copy.d.ts.map +1 -0
- package/dist/commands/secrets-copy.js +164 -0
- package/dist/commands/secrets-copy.js.map +1 -0
- package/dist/commands/secrets.d.ts.map +1 -1
- package/dist/commands/secrets.js +19 -8
- package/dist/commands/secrets.js.map +1 -1
- package/dist/commands/service-accounts.d.ts.map +1 -1
- package/dist/commands/service-accounts.js +1 -1
- package/dist/commands/service-accounts.js.map +1 -1
- package/dist/commands/sso.d.ts +2 -1
- package/dist/commands/sso.d.ts.map +1 -1
- package/dist/commands/sso.js +11 -72
- package/dist/commands/sso.js.map +1 -1
- package/dist/commands/tokens.d.ts +1 -1
- package/dist/commands/tokens.d.ts.map +1 -1
- package/dist/commands/tokens.js +7 -6
- package/dist/commands/tokens.js.map +1 -1
- package/dist/commands/tools.d.ts.map +1 -1
- package/dist/commands/tools.js +10 -5
- package/dist/commands/tools.js.map +1 -1
- package/dist/dev/defaults.d.ts +10 -0
- package/dist/dev/defaults.d.ts.map +1 -1
- package/dist/dev/defaults.js +126 -16
- package/dist/dev/defaults.js.map +1 -1
- package/dist/dev/pack-env.d.ts +27 -1
- package/dist/dev/pack-env.d.ts.map +1 -1
- package/dist/dev/pack-env.js +27 -4
- package/dist/dev/pack-env.js.map +1 -1
- package/dist/dev/pack-service.d.ts +8 -0
- package/dist/dev/pack-service.d.ts.map +1 -1
- package/dist/dev/pack-service.js +2 -0
- package/dist/dev/pack-service.js.map +1 -1
- package/dist/dev/paths.d.ts +6 -0
- package/dist/dev/paths.d.ts.map +1 -1
- package/dist/dev/paths.js +8 -0
- package/dist/dev/paths.js.map +1 -1
- package/dist/dev/runners.d.ts +24 -0
- package/dist/dev/runners.d.ts.map +1 -1
- package/dist/dev/runtime-image.d.ts +1 -1
- package/dist/dev/runtime-image.js +1 -1
- package/dist/dev/sandbox/bwrap.d.ts +19 -0
- package/dist/dev/sandbox/bwrap.d.ts.map +1 -0
- package/dist/dev/sandbox/bwrap.js +164 -0
- package/dist/dev/sandbox/bwrap.js.map +1 -0
- package/dist/dev/sandbox/detect.d.ts +26 -0
- package/dist/dev/sandbox/detect.d.ts.map +1 -0
- package/dist/dev/sandbox/detect.js +84 -0
- package/dist/dev/sandbox/detect.js.map +1 -0
- package/dist/dev/sandbox/index.d.ts +44 -0
- package/dist/dev/sandbox/index.d.ts.map +1 -0
- package/dist/dev/sandbox/index.js +81 -0
- package/dist/dev/sandbox/index.js.map +1 -0
- package/dist/dev/sandbox/notices.d.ts +23 -0
- package/dist/dev/sandbox/notices.d.ts.map +1 -0
- package/dist/dev/sandbox/notices.js +95 -0
- package/dist/dev/sandbox/notices.js.map +1 -0
- package/dist/dev/sandbox/policy.d.ts +80 -0
- package/dist/dev/sandbox/policy.d.ts.map +1 -0
- package/dist/dev/sandbox/policy.js +313 -0
- package/dist/dev/sandbox/policy.js.map +1 -0
- package/dist/dev/sandbox/seatbelt.d.ts +3 -0
- package/dist/dev/sandbox/seatbelt.d.ts.map +1 -0
- package/dist/dev/sandbox/seatbelt.js +131 -0
- package/dist/dev/sandbox/seatbelt.js.map +1 -0
- package/dist/dev/sandbox/settings.d.ts +30 -0
- package/dist/dev/sandbox/settings.d.ts.map +1 -0
- package/dist/dev/sandbox/settings.js +97 -0
- package/dist/dev/sandbox/settings.js.map +1 -0
- package/dist/env/provider-keys.d.ts +35 -0
- package/dist/env/provider-keys.d.ts.map +1 -0
- package/dist/env/provider-keys.js +108 -0
- package/dist/env/provider-keys.js.map +1 -0
- package/dist/init/agent-access.d.ts +119 -0
- package/dist/init/agent-access.d.ts.map +1 -0
- package/dist/init/agent-access.js +339 -0
- package/dist/init/agent-access.js.map +1 -0
- package/dist/init/augment-scaffolder.d.ts +2 -0
- package/dist/init/augment-scaffolder.d.ts.map +1 -1
- package/dist/init/augment-scaffolder.js +12 -2
- package/dist/init/augment-scaffolder.js.map +1 -1
- package/dist/init/gitignore-patcher.d.ts.map +1 -1
- package/dist/init/gitignore-patcher.js +5 -3
- package/dist/init/gitignore-patcher.js.map +1 -1
- package/dist/init/java-augment.d.ts +2 -0
- package/dist/init/java-augment.d.ts.map +1 -1
- package/dist/init/java-augment.js +10 -0
- package/dist/init/java-augment.js.map +1 -1
- package/dist/init/python-augment.d.ts +2 -0
- package/dist/init/python-augment.d.ts.map +1 -1
- package/dist/init/python-augment.js +11 -1
- package/dist/init/python-augment.js.map +1 -1
- package/dist/init/scala-augment.d.ts +2 -0
- package/dist/init/scala-augment.d.ts.map +1 -1
- package/dist/init/scala-augment.js +12 -2
- package/dist/init/scala-augment.js.map +1 -1
- package/dist/sdk-skills/kindgi-authoring-agents/SKILL.md +5 -1
- package/dist/sdk-skills/kindgi-authoring-flows/SKILL.md +1 -1
- package/dist/sdk-skills/kindgi-authoring-guardrails/SKILL.md +1 -1
- package/dist/sdk-skills/kindgi-authoring-mcp-servers/SKILL.md +8 -7
- package/dist/sdk-skills/kindgi-authoring-providers/SKILL.md +22 -16
- package/dist/sdk-skills/kindgi-authoring-tools/SKILL.md +53 -4
- package/dist/sdk-skills/kindgi-framework-feedback/SKILL.md +1 -1
- package/dist/sdk-skills/kindgi-getting-started/SKILL.md +24 -2
- package/dist/sdk-skills/kindgi-java-authoring-agents/SKILL.md +3 -3
- package/dist/sdk-skills/kindgi-java-authoring-flows/SKILL.md +1 -1
- package/dist/sdk-skills/kindgi-java-authoring-guardrails/SKILL.md +1 -1
- package/dist/sdk-skills/kindgi-java-authoring-tools/SKILL.md +35 -12
- package/dist/sdk-skills/kindgi-java-getting-started/SKILL.md +29 -5
- package/dist/sdk-skills/kindgi-python-authoring-agents/SKILL.md +5 -1
- package/dist/sdk-skills/kindgi-python-authoring-flows/SKILL.md +1 -1
- package/dist/sdk-skills/kindgi-python-authoring-guardrails/SKILL.md +1 -1
- package/dist/sdk-skills/kindgi-python-authoring-tools/SKILL.md +44 -10
- package/dist/sdk-skills/kindgi-python-getting-started/SKILL.md +28 -4
- package/dist/sdk-skills/kindgi-scala-authoring-agents/SKILL.md +3 -3
- package/dist/sdk-skills/kindgi-scala-authoring-flows/SKILL.md +1 -1
- package/dist/sdk-skills/kindgi-scala-authoring-guardrails/SKILL.md +1 -1
- package/dist/sdk-skills/kindgi-scala-authoring-tools/SKILL.md +35 -12
- package/dist/sdk-skills/kindgi-scala-getting-started/SKILL.md +29 -5
- package/dist/templates/java/README.md.tmpl +1 -1
- package/dist/templates/minimal/README.md.tmpl +1 -1
- package/dist/templates/python/README.md.tmpl +1 -1
- package/dist/templates/sample/README.md.tmpl +1 -1
- package/dist/templates/sample/tools/fetch-httpbin/index.ts.tmpl +2 -1
- package/dist/templates/scala/README.md.tmpl +1 -1
- package/package.json +13 -13
|
@@ -15,7 +15,7 @@ description: >
|
|
|
15
15
|
type: core
|
|
16
16
|
library: "kindgi-pack (Java)"
|
|
17
17
|
version: "0.1.0"
|
|
18
|
-
sdk_version: "0.1.
|
|
18
|
+
sdk_version: "0.1.6-rc.0"
|
|
19
19
|
pack_languages: [java]
|
|
20
20
|
sources:
|
|
21
21
|
- sdks/java/kindgi-pack/README.md
|
|
@@ -161,8 +161,16 @@ final class Citator {
|
|
|
161
161
|
|
|
162
162
|
- `ctx.tenantId()`: the tenant the call is for. Key per-tenant state by it.
|
|
163
163
|
- `ctx.runId()`: the run (an agent turn or a flow step) the call belongs to.
|
|
164
|
-
- `ctx.requestId()`: this call, such as the model's tool-call id.
|
|
165
|
-
|
|
164
|
+
- `ctx.requestId()`: this call, such as the model's tool-call id. For logs:
|
|
165
|
+
a model's call id is only unique within one of its answers, so don't
|
|
166
|
+
dedupe on it.
|
|
167
|
+
- `ctx.idempotencyKey()`: the same every time this call runs (resumed,
|
|
168
|
+
retried, or run again after a crash), different for every other call. A
|
|
169
|
+
step can run more than once, so a tool that writes passes it to the system
|
|
170
|
+
it writes to (an `Idempotency-Key` header, a client reference, a unique
|
|
171
|
+
column) or looks for it there first: a refund never goes out twice. A
|
|
172
|
+
UUID; `null` outside a run and from a runtime before 0.1.6. Docs:
|
|
173
|
+
https://docs.kindgi.com/v0.1/guides/tools/write-a-tool/#make-a-side-effect-happen-once
|
|
166
174
|
- `ctx.projectId()`, `ctx.orgId()`: the run's project, and its org (`null`
|
|
167
175
|
when it has none). The runtime sets them from the run, never from the
|
|
168
176
|
input. To check an id the input names, compare it with these.
|
|
@@ -181,20 +189,28 @@ A secret that belongs to the tenant, such as an API key a customer gives
|
|
|
181
189
|
you, is declared with `set("needsSpec", …)` and read from `ctx.secrets()`, as
|
|
182
190
|
above. The runtime resolves every declared secret on every call, for the
|
|
183
191
|
call's tenant, in its env (`KINDGI_ENV`; under `kindgi dev`, `local`: the
|
|
184
|
-
pack's `.env` and `.env.local
|
|
185
|
-
|
|
186
|
-
|
|
192
|
+
pack's `.env` and `.env.local`, then Kindgi's own `.kindgi/secrets.env`, where
|
|
193
|
+
`./kindgiw secrets set` writes). It checks each against its schema, and fails
|
|
194
|
+
the call, naming the secret, when one is missing or doesn't match. A
|
|
195
|
+
declared secret is required, unless its schema names null
|
|
196
|
+
(`"type": ["string", "null"]`): an optional one the env doesn't have, or has
|
|
197
|
+
empty, is absent from `ctx.secrets`, and the call goes on (runtime 0.1.6 or
|
|
198
|
+
later; an older runtime requires it).
|
|
187
199
|
|
|
188
200
|
Everything else comes from the process environment: `System.getenv("CITATOR_URL")`.
|
|
189
201
|
Under `kindgi dev`, the pack service gets the pack's `.env` and `.env.local`,
|
|
190
202
|
and restarts when they change. Nothing else from your shell reaches it
|
|
191
203
|
except `PATH`, `HOME` and `TMPDIR`; `MAVEN_ARGS` and `MAVEN_OPTS` reach Maven
|
|
192
|
-
only. Put a
|
|
193
|
-
`./kindgiw secrets set NAME --env=local --scope=tenant` (a
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
204
|
+
only. Put a setting there by hand, and keep the env files out of git. A
|
|
205
|
+
secret stored with `./kindgiw secrets set NAME --env=local --scope=tenant` (a
|
|
206
|
+
no-echo prompt) never reaches the process environment: declare it and read it
|
|
207
|
+
from `ctx.secrets()`. A model provider's key reaches no tool at all: a tool
|
|
208
|
+
that calls a model declares a key of its own. A deployed service names the
|
|
209
|
+
variables it needs in `kindgi.config.json`: `"env": {"required": ["DATABASE_URL"],
|
|
210
|
+
"optional": ["SENTRY_DSN"]}`. Without a required one it isn't ready, and
|
|
211
|
+
every variable it doesn't declare is dropped before your code loads
|
|
212
|
+
(`kindgi dev` keeps them), so an undeclared one works locally and is unset
|
|
213
|
+
once deployed. `KINDGI_*` names are Kindgi's own: a pack can't declare one.
|
|
198
214
|
|
|
199
215
|
## Errors and output
|
|
200
216
|
|
|
@@ -327,6 +343,13 @@ removed field, a narrower type), not on every save.
|
|
|
327
343
|
`META-INF/services`. Declare it there, or the tool's input and schema
|
|
328
344
|
won't see it.
|
|
329
345
|
|
|
346
|
+
11. **Turning the dev sandbox off for a file the tool needs.** Under `kindgi dev`
|
|
347
|
+
the tool's code runs sandboxed: it can't read outside the app (the home
|
|
348
|
+
folder, `~/.aws`) or any `.env*` file, and gets `EPERM` there. A tool that
|
|
349
|
+
needs a path names it in `kindgi.config.json`: `"dev": {"sandbox": {"allowRead": ["~/.aws"]}}`.
|
|
350
|
+
Never set `KINDGI_DEV_SANDBOX=off` or `dev.sandbox: false` to get past it
|
|
351
|
+
(https://docs.kindgi.com/v0.1/guides/secrets/dev-sandbox/).
|
|
352
|
+
|
|
330
353
|
## When the framework itself is the problem
|
|
331
354
|
|
|
332
355
|
If the bug is in Kindgi or kindgi-pack (a schema derived wrong, a misleading
|
|
@@ -17,7 +17,7 @@ description: >
|
|
|
17
17
|
type: core
|
|
18
18
|
library: "kindgi-pack (Java)"
|
|
19
19
|
version: "0.1.0"
|
|
20
|
-
sdk_version: "0.1.
|
|
20
|
+
sdk_version: "0.1.6-rc.0"
|
|
21
21
|
pack_languages: [java]
|
|
22
22
|
sources:
|
|
23
23
|
- sdks/java/kindgi-pack/README.md
|
|
@@ -103,8 +103,10 @@ A tool there is a class in a `kindgi.tools` package under the app's own
|
|
|
103
103
|
(`com.acme.app.kindgi.tools`), and calls the app's code directly. A class a
|
|
104
104
|
tool uses must be on the runtime classpath (`compile` or `runtime` scope,
|
|
105
105
|
not `test` or `provided`): the image copies the runtime dependencies only.
|
|
106
|
-
`kindgi dev` reads the app's `.env` and `.env.local`:
|
|
107
|
-
reach the tools as environment variables.
|
|
106
|
+
`kindgi dev` reads the app's `.env` and `.env.local`: values already there
|
|
107
|
+
reach the tools as environment variables. A secret stored with `kindgi
|
|
108
|
+
secrets set` doesn't: a tool reads it from its context (`needsSpec.secrets`).
|
|
109
|
+
Nor does a model provider's key, which no tool gets.
|
|
108
110
|
|
|
109
111
|
## Layout of the template
|
|
110
112
|
|
|
@@ -146,7 +148,7 @@ key and register its preset (Anthropic below; `./kindgiw providers presets`
|
|
|
146
148
|
lists OpenAI, Gemini, Groq and OpenRouter too):
|
|
147
149
|
|
|
148
150
|
```sh
|
|
149
|
-
./kindgiw secrets set ANTHROPIC_API_KEY --env=local --scope=tenant # no-echo prompt; writes .env
|
|
151
|
+
./kindgiw secrets set ANTHROPIC_API_KEY --env=local --scope=tenant # no-echo prompt; writes .kindgi/secrets.env
|
|
150
152
|
./kindgiw providers register --preset=anthropic
|
|
151
153
|
```
|
|
152
154
|
|
|
@@ -240,7 +242,8 @@ image installs them: `"image": {"systemPackages": ["tesseract-ocr"]}`
|
|
|
240
242
|
(names, or `name=version`). So are the variables the code reads, names only:
|
|
241
243
|
`"env": {"required": ["DATABASE_URL"], "optional": ["SENTRY_DSN"]}`. A
|
|
242
244
|
deployed pack service missing a required one isn't ready, and its `/readyz`
|
|
243
|
-
names it
|
|
245
|
+
names it; one the pack doesn't declare is dropped before the code loads
|
|
246
|
+
(`kindgi dev` keeps it).
|
|
244
247
|
|
|
245
248
|
## Two things need the human
|
|
246
249
|
|
|
@@ -248,6 +251,27 @@ names it.
|
|
|
248
251
|
primitive (`<pack-id>.<name>`): pick it once.
|
|
249
252
|
- **Model credentials.** Ask for the key; never invent or hard-code one.
|
|
250
253
|
|
|
254
|
+
## Keys and tokens: hands off
|
|
255
|
+
|
|
256
|
+
Never open, read, grep, `cat`, copy or print the files that hold keys and
|
|
257
|
+
tokens, in any folder of the repository (not only the pack's), and never
|
|
258
|
+
print their values (`env`, `printenv`, or code that echoes the process
|
|
259
|
+
environment):
|
|
260
|
+
|
|
261
|
+
- `.env`, `.env.local` and any other `.env.*`: the app's settings, and any key
|
|
262
|
+
put there by hand;
|
|
263
|
+
- `.kindgi/secrets.env`: Kindgi's own secrets, where `./kindgiw secrets set` writes;
|
|
264
|
+
- `.kindgi/dev/runtime.env`: the dev runtime's token and database URL;
|
|
265
|
+
- a self-hosted deployment's `kindgi.env` or `pack.env`.
|
|
266
|
+
|
|
267
|
+
A value you read lands in your context and in every later request to the
|
|
268
|
+
model provider. To see which secrets exist, run
|
|
269
|
+
`./kindgiw secrets list --env=local --scope=tenant` (names only). To store one,
|
|
270
|
+
ask the person to run `./kindgiw secrets set NAME --env=local --scope=tenant`
|
|
271
|
+
themselves: it prompts without echoing. Never put a value on a command line.
|
|
272
|
+
`kindgi init` adds these files to the deny rules in `.claude/settings.json`;
|
|
273
|
+
in a monorepo, also to the repository root's, under the pack's path.
|
|
274
|
+
|
|
251
275
|
## Next
|
|
252
276
|
|
|
253
277
|
- A tool: `kindgi-java-authoring-tools`.
|
|
@@ -16,7 +16,7 @@ description: >
|
|
|
16
16
|
type: core
|
|
17
17
|
library: "kindgi (Python)"
|
|
18
18
|
version: "0.1.5"
|
|
19
|
-
sdk_version: "0.1.
|
|
19
|
+
sdk_version: "0.1.6-rc.0"
|
|
20
20
|
pack_languages: [python]
|
|
21
21
|
sources:
|
|
22
22
|
- sdks/python/src/kindgi/pack/define.py
|
|
@@ -169,6 +169,10 @@ brief_writer = Agent(
|
|
|
169
169
|
fails the turn (`semantic-unavailable`). `{"source": "conversations",
|
|
170
170
|
"scope": "same-user"}` recalls this agent's earlier conversations: the
|
|
171
171
|
people's own words only, unless `"roles": ["user", "agent"]`.
|
|
172
|
+
`same-user` memory (facts, recall or `remember`) is the run's end user's:
|
|
173
|
+
pass `participantId` on every run. A run without one reads and keeps
|
|
174
|
+
none (its result warns `memory-needs-participant`), never the memory of
|
|
175
|
+
the user a key acts for, who may serve many people.
|
|
172
176
|
- **`memory`** — `{"remember": {"types": ["acme.preference"], "scope":
|
|
173
177
|
"same-user", "keepDays": 30}}` gives the turn the built-in tool
|
|
174
178
|
`kindgi_remember` (name it exactly so in the instructions). The model
|
|
@@ -14,8 +14,8 @@ description: >
|
|
|
14
14
|
kindgi-python-getting-started.
|
|
15
15
|
type: core
|
|
16
16
|
library: "kindgi (Python)"
|
|
17
|
-
version: "0.1.
|
|
18
|
-
sdk_version: "0.1.
|
|
17
|
+
version: "0.1.3"
|
|
18
|
+
sdk_version: "0.1.6-rc.0"
|
|
19
19
|
pack_languages: [python]
|
|
20
20
|
sources:
|
|
21
21
|
- sdks/python/src/kindgi/pack/define.py
|
|
@@ -103,8 +103,16 @@ def verify_citation(citation: Citation, ctx: ToolContext) -> Verdict:
|
|
|
103
103
|
- `ctx.tenant_id` — the tenant the call is for. Key any per-tenant
|
|
104
104
|
state by it.
|
|
105
105
|
- `ctx.run_id` — the run (an agent turn or a flow step) the call belongs to.
|
|
106
|
-
- `ctx.request_id` — this call, e.g. the model's tool-call id;
|
|
107
|
-
|
|
106
|
+
- `ctx.request_id` — this call, e.g. the model's tool-call id; for logs.
|
|
107
|
+
A model's call id is only unique within one of its answers: don't
|
|
108
|
+
dedupe on it.
|
|
109
|
+
- `ctx.idempotency_key` — the same every time this call runs (resumed,
|
|
110
|
+
retried, or run again after a crash), different for every other call. A
|
|
111
|
+
step can run more than once, so a tool that writes passes it to the
|
|
112
|
+
system it writes to (an `Idempotency-Key` header, a client reference, a
|
|
113
|
+
unique column) or looks for it there first: a refund never goes out
|
|
114
|
+
twice. A UUID; `None` outside a run and from a runtime before 0.1.6.
|
|
115
|
+
Docs: https://docs.kindgi.com/v0.1/guides/tools/write-a-tool/#make-a-side-effect-happen-once
|
|
108
116
|
- `ctx.project_id`, `ctx.org_id` — the run's project, and that project's
|
|
109
117
|
org (`None` when it has none). The runtime sets them from the run, never
|
|
110
118
|
from the input: to check an org or project id the input names, compare
|
|
@@ -121,6 +129,14 @@ def verify_citation(citation: Citation, ctx: ToolContext) -> Verdict:
|
|
|
121
129
|
(`kindgi env set NAME <value> --scope=project:<id> --env=<env>`).
|
|
122
130
|
Strings, and not secret. Empty from an older runtime.
|
|
123
131
|
- `ctx.config` — **reserved, empty today**.
|
|
132
|
+
- `ctx.log` — a logger bound to the call (its records carry the run's ids,
|
|
133
|
+
the tool's id and the trace id): `ctx.log.info("refund issued",
|
|
134
|
+
{"orderId": order_id, "amountCents": amount_cents})`, or the fields as
|
|
135
|
+
keywords. Values go in the fields, never in the message. Log ids,
|
|
136
|
+
amounts and outcomes, never what a person typed (a refund's reason, a
|
|
137
|
+
message, an address): the log is read by whoever operates the runtime.
|
|
138
|
+
`ToolContext.for_test(…)` logs nothing unless you pass it `log=`. Docs:
|
|
139
|
+
https://docs.kindgi.com/v0.1/guides/tools/write-a-tool/#log-from-a-tool
|
|
124
140
|
|
|
125
141
|
## Configuration and secrets
|
|
126
142
|
|
|
@@ -139,9 +155,13 @@ def verify_citation(citation: Citation, ctx: ToolContext) -> Verdict:
|
|
|
139
155
|
|
|
140
156
|
The runtime resolves every declared secret on every call — for the
|
|
141
157
|
call's tenant, in its env (`KINDGI_ENV`; in `kindgi dev`, `local`: the
|
|
142
|
-
pack's `.env` and `.env.local
|
|
158
|
+
pack's `.env` and `.env.local`, then Kindgi's own `.kindgi/secrets.env`, where
|
|
159
|
+
`kindgi secrets set` writes) — checks it against its schema, and
|
|
143
160
|
fails the call, naming the secret, when it is missing or doesn't match.
|
|
144
|
-
|
|
161
|
+
A declared secret is required, unless its schema names null
|
|
162
|
+
(`{"type": ["string", "null"]}`): an optional one the env doesn't have, or
|
|
163
|
+
has empty, is absent from `ctx.secrets` (read it with `.get`), and the call
|
|
164
|
+
goes on (runtime 0.1.6 or later; an older runtime requires it). In a test, pass them:
|
|
145
165
|
`ToolContext.for_test(secrets={"CITATOR_KEY": "…"})`.
|
|
146
166
|
|
|
147
167
|
A value that differs per tenant, org or project but isn't secret (a base URL, a region, an account id) is an **env value**: declared in `needs_spec`, read from `ctx.env`:
|
|
@@ -175,10 +195,17 @@ Everything else comes from the process environment: `os.environ["CITATOR_URL"]`.
|
|
|
175
195
|
The pack service runs with the pack's environment — in `kindgi dev`
|
|
176
196
|
that is the pack's `.env` and `.env.local` (or `[tool.kindgi.dev]
|
|
177
197
|
envFiles`), restarted when they change; nothing else from your shell
|
|
178
|
-
reaches it except `PATH`, `HOME` and `TMPDIR`. Put a
|
|
179
|
-
hand
|
|
180
|
-
|
|
181
|
-
|
|
198
|
+
reaches it except `PATH`, `HOME` and `TMPDIR`. Put a setting there by
|
|
199
|
+
hand, and keep the env files out of git. A secret stored with `kindgi
|
|
200
|
+
secrets set NAME --env=local --scope=tenant` (a no-echo prompt) never
|
|
201
|
+
reaches the process environment: declare it and read it from
|
|
202
|
+
`ctx.secrets`. A model provider's key reaches no tool at all: a tool
|
|
203
|
+
that calls a model declares a key of its own. Declare every name the
|
|
204
|
+
code reads in `[tool.kindgi.env]` (`required`, `optional`): in an image
|
|
205
|
+
the pack service drops every other variable before your code loads
|
|
206
|
+
(`kindgi dev` keeps them), so an undeclared one works locally and is
|
|
207
|
+
unset once deployed. `KINDGI_*` names are Kindgi's own settings: a pack
|
|
208
|
+
can't declare one.
|
|
182
209
|
|
|
183
210
|
## Errors and output
|
|
184
211
|
|
|
@@ -334,6 +361,13 @@ removed field, a narrower type — not on every save.
|
|
|
334
361
|
Poetry 1 app, `[tool.poetry.dependencies]`); test and build tools stay
|
|
335
362
|
in dev groups.
|
|
336
363
|
|
|
364
|
+
12. **Turning the dev sandbox off for a file the tool needs.** Under `kindgi dev`
|
|
365
|
+
the tool's code runs sandboxed: it can't read outside the app (the home
|
|
366
|
+
folder, `~/.aws`) or any `.env*` file, and gets `EPERM` there. A tool that
|
|
367
|
+
needs a path names it in `pyproject.toml`: `[tool.kindgi.dev.sandbox]` `allowRead = ["~/.aws"]`.
|
|
368
|
+
Never set `KINDGI_DEV_SANDBOX=off` or `dev.sandbox: false` to get past it
|
|
369
|
+
(https://docs.kindgi.com/v0.1/guides/secrets/dev-sandbox/).
|
|
370
|
+
|
|
337
371
|
## When the framework itself is the problem
|
|
338
372
|
|
|
339
373
|
If the bug is in Kindgi or the `kindgi` package (a schema derived wrong,
|
|
@@ -15,7 +15,7 @@ description: >
|
|
|
15
15
|
type: core
|
|
16
16
|
library: "kindgi (Python)"
|
|
17
17
|
version: "0.1.7"
|
|
18
|
-
sdk_version: "0.1.
|
|
18
|
+
sdk_version: "0.1.6-rc.0"
|
|
19
19
|
pack_languages: [python]
|
|
20
20
|
sources:
|
|
21
21
|
- sdks/python/README.md
|
|
@@ -92,8 +92,10 @@ The pack root is on `sys.path`, so tools import the app's own packages by
|
|
|
92
92
|
name (`from acme.text import normalize`); inside `kindgi/`, import the pack's
|
|
93
93
|
modules relatively. Don't add an `__init__.py` to `kindgi/` — the folder
|
|
94
94
|
would then shadow the `kindgi` package. `kindgi dev` reads the app's `.env`
|
|
95
|
-
/ `.env.local` —
|
|
96
|
-
variables
|
|
95
|
+
/ `.env.local` — values already there reach the tools as environment
|
|
96
|
+
variables; a secret stored with `kindgi secrets set` doesn't (a tool reads
|
|
97
|
+
it from `ctx.secrets`), and neither does a model provider's key, which no tool
|
|
98
|
+
gets. A package a tool imports must be in the app's main dependencies,
|
|
97
99
|
not a dev group: the deployed pack installs without dev dependencies (see
|
|
98
100
|
`kindgi-python-authoring-tools`).
|
|
99
101
|
|
|
@@ -277,7 +279,8 @@ system-packages = ["tesseract-ocr", "poppler-utils"] # names, or name=version
|
|
|
277
279
|
|
|
278
280
|
The variables the code reads from `os.environ` (a database URL, a bucket)
|
|
279
281
|
are declared too, names only. A deployed pack service missing a `required`
|
|
280
|
-
one isn't ready, and its `/readyz` names it
|
|
282
|
+
one isn't ready, and its `/readyz` names it; one the pack doesn't declare is
|
|
283
|
+
dropped before the code loads (`kindgi dev` keeps it):
|
|
281
284
|
|
|
282
285
|
```toml
|
|
283
286
|
[tool.kindgi.env]
|
|
@@ -294,6 +297,27 @@ build before anything uploads, with the range to use.
|
|
|
294
297
|
every primitive (`<pack-id>.<name>`); pick it once.
|
|
295
298
|
- **Model credentials.** Ask for the key; never invent or hard-code one.
|
|
296
299
|
|
|
300
|
+
## Keys and tokens: hands off
|
|
301
|
+
|
|
302
|
+
Never open, read, grep, `cat`, copy or print the files that hold keys and
|
|
303
|
+
tokens, in any folder of the repository (not only the pack's), and never
|
|
304
|
+
print their values (`env`, `printenv`, or code that echoes the process
|
|
305
|
+
environment):
|
|
306
|
+
|
|
307
|
+
- `.env`, `.env.local` and any other `.env.*`: the app's settings, and any key
|
|
308
|
+
put there by hand;
|
|
309
|
+
- `.kindgi/secrets.env`: Kindgi's own secrets, where `kindgi secrets set` writes;
|
|
310
|
+
- `.kindgi/dev/runtime.env`: the dev runtime's token and database URL;
|
|
311
|
+
- a self-hosted deployment's `kindgi.env` or `pack.env`.
|
|
312
|
+
|
|
313
|
+
A value you read lands in your context and in every later request to the
|
|
314
|
+
model provider. To see which secrets exist, run
|
|
315
|
+
`kindgi secrets list --env=local --scope=tenant` (names only). To store one,
|
|
316
|
+
ask the person to run `kindgi secrets set NAME --env=local --scope=tenant`
|
|
317
|
+
themselves: it prompts without echoing. Never put a value on a command line.
|
|
318
|
+
`kindgi init` adds these files to the deny rules in `.claude/settings.json`;
|
|
319
|
+
in a monorepo, also to the repository root's, under the pack's path.
|
|
320
|
+
|
|
297
321
|
## Next
|
|
298
322
|
|
|
299
323
|
- A tool → `kindgi-python-authoring-tools`.
|
|
@@ -17,7 +17,7 @@ description: >
|
|
|
17
17
|
type: core
|
|
18
18
|
library: "kindgi-pack-scala"
|
|
19
19
|
version: "0.1.0"
|
|
20
|
-
sdk_version: "0.1.
|
|
20
|
+
sdk_version: "0.1.6-rc.0"
|
|
21
21
|
pack_languages: [scala]
|
|
22
22
|
sources:
|
|
23
23
|
- sdks/scala/README.md
|
|
@@ -138,10 +138,10 @@ object BriefWriter {
|
|
|
138
138
|
- **`set("parameters", List(Map("name" -> …, "type" -> …, "required" -> …)))`:**
|
|
139
139
|
inputs the caller supplies per run. They fill `{{ … }}` in the
|
|
140
140
|
instructions.
|
|
141
|
-
- **`set("preferredProvider", "anthropic")`, `set("preferredModel", "claude-haiku-
|
|
141
|
+
- **`set("preferredProvider", "anthropic")`, `set("preferredModel", "claude-haiku-5-5")`:**
|
|
142
142
|
soft hints. The router prefers them when they satisfy the capabilities.
|
|
143
143
|
To *require* a model, put it in the capability:
|
|
144
|
-
`Map("needs" -> List(Map("feature" -> "tool-use"), Map("models" -> Map("allow" -> List("claude-haiku-
|
|
144
|
+
`Map("needs" -> List(Map("feature" -> "tool-use"), Map("models" -> Map("allow" -> List("claude-haiku-5-5")))))`.
|
|
145
145
|
- **`set("conversationPolicy", …)`:** `historyLimit` caps the prior messages
|
|
146
146
|
loaded, and `hitl` configures approval gates. Absent, the turn loads the
|
|
147
147
|
full history with no gates. A tenant's `hitl` policy can tighten the gates
|
|
@@ -16,7 +16,7 @@ description: >
|
|
|
16
16
|
type: core
|
|
17
17
|
library: "kindgi-pack-scala"
|
|
18
18
|
version: "0.1.0"
|
|
19
|
-
sdk_version: "0.1.
|
|
19
|
+
sdk_version: "0.1.6-rc.0"
|
|
20
20
|
pack_languages: [scala]
|
|
21
21
|
sources:
|
|
22
22
|
- sdks/scala/README.md
|
|
@@ -147,8 +147,16 @@ object Citator {
|
|
|
147
147
|
|
|
148
148
|
- `ctx.tenantId`: the tenant the call is for. Key per-tenant state by it.
|
|
149
149
|
- `ctx.runId`: the run (an agent turn or a flow step) the call belongs to.
|
|
150
|
-
- `ctx.requestId`: this call, such as the model's tool-call id.
|
|
151
|
-
|
|
150
|
+
- `ctx.requestId`: this call, such as the model's tool-call id. For logs: a
|
|
151
|
+
model's call id is only unique within one of its answers, so don't dedupe
|
|
152
|
+
on it.
|
|
153
|
+
- `ctx.idempotencyKey`: the same every time this call runs (resumed,
|
|
154
|
+
retried, or run again after a crash), different for every other call. A
|
|
155
|
+
step can run more than once, so a tool that writes passes it to the system
|
|
156
|
+
it writes to (`Option(ctx.idempotencyKey).foreach(k => request.header("Idempotency-Key", k))`)
|
|
157
|
+
or looks for it there first: a refund never goes out twice. A UUID; `null`
|
|
158
|
+
outside a run and from a runtime before 0.1.6. Docs:
|
|
159
|
+
https://docs.kindgi.com/v0.1/guides/tools/write-a-tool/#make-a-side-effect-happen-once
|
|
152
160
|
- `ctx.projectId`, `ctx.orgId`: the run's project, and its org (`null` when
|
|
153
161
|
it has none). The runtime sets them from the run, never from the input.
|
|
154
162
|
To check an id the input names, compare it with these.
|
|
@@ -167,20 +175,28 @@ A secret that belongs to the tenant, such as an API key a customer gives
|
|
|
167
175
|
you, is declared with `set("needsSpec", …)` and read from `ctx.secrets`, as
|
|
168
176
|
above. The runtime resolves every declared secret on every call, for the
|
|
169
177
|
call's tenant, in its env (`KINDGI_ENV`; under `kindgi dev`, `local`: the
|
|
170
|
-
pack's `.env` and `.env.local
|
|
171
|
-
|
|
172
|
-
|
|
178
|
+
pack's `.env` and `.env.local`, then Kindgi's own `.kindgi/secrets.env`, where
|
|
179
|
+
`./kindgiw secrets set` writes). It checks each against its schema, and fails
|
|
180
|
+
the call, naming the secret, when one is missing or doesn't match. A
|
|
181
|
+
declared secret is required, unless its schema names null
|
|
182
|
+
(`"type": ["string", "null"]`): an optional one the env doesn't have, or has
|
|
183
|
+
empty, is absent from `ctx.secrets`, and the call goes on (runtime 0.1.6 or
|
|
184
|
+
later; an older runtime requires it).
|
|
173
185
|
|
|
174
186
|
Everything else comes from the process environment: `sys.env("CITATOR_URL")`.
|
|
175
187
|
Under `kindgi dev`, the pack service gets the pack's `.env` and `.env.local`,
|
|
176
188
|
and restarts when they change. Nothing else from your shell reaches it
|
|
177
|
-
except `PATH`, `HOME` and `TMPDIR`; `SBT_OPTS` reaches sbt only. Put a
|
|
178
|
-
there by hand,
|
|
179
|
-
(a no-echo prompt)
|
|
180
|
-
|
|
189
|
+
except `PATH`, `HOME` and `TMPDIR`; `SBT_OPTS` reaches sbt only. Put a setting
|
|
190
|
+
there by hand, and keep the env files out of git. A secret stored with
|
|
191
|
+
`./kindgiw secrets set NAME --env=local --scope=tenant` (a no-echo prompt)
|
|
192
|
+
never reaches the process environment: declare it and read it from
|
|
193
|
+
`ctx.secrets`. A model provider's key reaches no tool at all: a tool that calls
|
|
194
|
+
a model declares a key of its own. A deployed service names the variables it needs in `kindgi.config.json`:
|
|
181
195
|
`"env": {"required": ["DATABASE_URL"], "optional": ["SENTRY_DSN"]}`. Without
|
|
182
|
-
a required one it isn't ready
|
|
183
|
-
|
|
196
|
+
a required one it isn't ready, and every variable it doesn't declare is
|
|
197
|
+
dropped before your code loads (`kindgi dev` keeps them), so an undeclared
|
|
198
|
+
one works locally and is unset once deployed. `KINDGI_*` names are Kindgi's
|
|
199
|
+
own: a pack can't declare one.
|
|
184
200
|
|
|
185
201
|
## Errors and output
|
|
186
202
|
|
|
@@ -294,6 +310,13 @@ changes (a removed field, a narrower type), not on every save.
|
|
|
294
310
|
`jackson-databind` minor version.** It refuses to load: depend on the
|
|
295
311
|
matching one.
|
|
296
312
|
|
|
313
|
+
12. **Turning the dev sandbox off for a file the tool needs.** Under `kindgi dev`
|
|
314
|
+
the tool's code runs sandboxed: it can't read outside the app (the home
|
|
315
|
+
folder, `~/.aws`) or any `.env*` file, and gets `EPERM` there. A tool that
|
|
316
|
+
needs a path names it in `kindgi.config.json`: `"dev": {"sandbox": {"allowRead": ["~/.aws"]}}`.
|
|
317
|
+
Never set `KINDGI_DEV_SANDBOX=off` or `dev.sandbox: false` to get past it
|
|
318
|
+
(https://docs.kindgi.com/v0.1/guides/secrets/dev-sandbox/).
|
|
319
|
+
|
|
297
320
|
## When the framework itself is the problem
|
|
298
321
|
|
|
299
322
|
If the bug is in Kindgi, kindgi-pack or the Scala layer (a schema derived
|
|
@@ -17,7 +17,7 @@ description: >
|
|
|
17
17
|
type: core
|
|
18
18
|
library: "kindgi-pack-scala"
|
|
19
19
|
version: "0.1.0"
|
|
20
|
-
sdk_version: "0.1.
|
|
20
|
+
sdk_version: "0.1.6-rc.0"
|
|
21
21
|
pack_languages: [scala]
|
|
22
22
|
sources:
|
|
23
23
|
- sdks/scala/README.md
|
|
@@ -115,8 +115,10 @@ A tool there is a `val` of an object in a `kindgi.tools` package under the
|
|
|
115
115
|
app's own (`com.acme.app.kindgi.tools`), and calls the app's code directly. A
|
|
116
116
|
library a tool uses must be on the runtime classpath (not `% Test` or
|
|
117
117
|
`% Provided`): the image ships the runtime classpath only. `kindgi dev` reads
|
|
118
|
-
the app's `.env` and `.env.local`:
|
|
119
|
-
environment variables.
|
|
118
|
+
the app's `.env` and `.env.local`: values already there reach the tools as
|
|
119
|
+
environment variables. A secret stored with `kindgi secrets set` doesn't: a
|
|
120
|
+
tool reads it from its context (`needsSpec.secrets`). Nor does a model
|
|
121
|
+
provider's key, which no tool gets.
|
|
120
122
|
|
|
121
123
|
## Layout of the template
|
|
122
124
|
|
|
@@ -158,7 +160,7 @@ key and register its preset (Anthropic below; `./kindgiw providers presets`
|
|
|
158
160
|
lists OpenAI, Gemini, Groq and OpenRouter too):
|
|
159
161
|
|
|
160
162
|
```sh
|
|
161
|
-
./kindgiw secrets set ANTHROPIC_API_KEY --env=local --scope=tenant # no-echo prompt; writes .env
|
|
163
|
+
./kindgiw secrets set ANTHROPIC_API_KEY --env=local --scope=tenant # no-echo prompt; writes .kindgi/secrets.env
|
|
162
164
|
./kindgiw providers register --preset=anthropic
|
|
163
165
|
```
|
|
164
166
|
|
|
@@ -256,7 +258,8 @@ image installs them: `"image": {"systemPackages": ["tesseract-ocr"]}`
|
|
|
256
258
|
(names, or `name=version`). So are the variables the code reads, names only:
|
|
257
259
|
`"env": {"required": ["DATABASE_URL"], "optional": ["SENTRY_DSN"]}`. A
|
|
258
260
|
deployed pack service missing a required one isn't ready, and its `/readyz`
|
|
259
|
-
names it
|
|
261
|
+
names it; one the pack doesn't declare is dropped before the code loads
|
|
262
|
+
(`kindgi dev` keeps it).
|
|
260
263
|
|
|
261
264
|
## Known limits
|
|
262
265
|
|
|
@@ -279,6 +282,27 @@ names it.
|
|
|
279
282
|
primitive (`<pack-id>.<name>`): pick it once.
|
|
280
283
|
- **Model credentials.** Ask for the key; never invent or hard-code one.
|
|
281
284
|
|
|
285
|
+
## Keys and tokens: hands off
|
|
286
|
+
|
|
287
|
+
Never open, read, grep, `cat`, copy or print the files that hold keys and
|
|
288
|
+
tokens, in any folder of the repository (not only the pack's), and never
|
|
289
|
+
print their values (`env`, `printenv`, or code that echoes the process
|
|
290
|
+
environment):
|
|
291
|
+
|
|
292
|
+
- `.env`, `.env.local` and any other `.env.*`: the app's settings, and any key
|
|
293
|
+
put there by hand;
|
|
294
|
+
- `.kindgi/secrets.env`: Kindgi's own secrets, where `./kindgiw secrets set` writes;
|
|
295
|
+
- `.kindgi/dev/runtime.env`: the dev runtime's token and database URL;
|
|
296
|
+
- a self-hosted deployment's `kindgi.env` or `pack.env`.
|
|
297
|
+
|
|
298
|
+
A value you read lands in your context and in every later request to the
|
|
299
|
+
model provider. To see which secrets exist, run
|
|
300
|
+
`./kindgiw secrets list --env=local --scope=tenant` (names only). To store one,
|
|
301
|
+
ask the person to run `./kindgiw secrets set NAME --env=local --scope=tenant`
|
|
302
|
+
themselves: it prompts without echoing. Never put a value on a command line.
|
|
303
|
+
`kindgi init` adds these files to the deny rules in `.claude/settings.json`;
|
|
304
|
+
in a monorepo, also to the repository root's, under the pack's path.
|
|
305
|
+
|
|
282
306
|
## Next
|
|
283
307
|
|
|
284
308
|
- A tool: `kindgi-scala-authoring-tools`.
|
|
@@ -52,7 +52,7 @@ use a real model, set one LLM provider's key and register its preset, with
|
|
|
52
52
|
`kindgi dev` running, from another terminal. For Claude:
|
|
53
53
|
|
|
54
54
|
```sh
|
|
55
|
-
kindgi secrets set ANTHROPIC_API_KEY --env=local --scope=tenant # no-echo prompt; writes .env
|
|
55
|
+
kindgi secrets set ANTHROPIC_API_KEY --env=local --scope=tenant # no-echo prompt; writes .kindgi/secrets.env
|
|
56
56
|
kindgi providers register --preset=anthropic # Opus 5.5, Sonnet 5.5, Haiku 4.5
|
|
57
57
|
```
|
|
58
58
|
|
|
@@ -55,7 +55,7 @@ use a real model, set one LLM provider's key and register its preset, with
|
|
|
55
55
|
`kindgi dev` running, from another terminal. For Claude:
|
|
56
56
|
|
|
57
57
|
```sh
|
|
58
|
-
{{KINDGI}} secrets set ANTHROPIC_API_KEY --env=local --scope=tenant # no-echo prompt; writes .env
|
|
58
|
+
{{KINDGI}} secrets set ANTHROPIC_API_KEY --env=local --scope=tenant # no-echo prompt; writes .kindgi/secrets.env
|
|
59
59
|
{{KINDGI}} providers register --preset=anthropic # Opus 5.5, Sonnet 5.5 (default), Haiku 5.5, Haiku 4.5
|
|
60
60
|
```
|
|
61
61
|
|
|
@@ -42,7 +42,7 @@ use a real model, set one LLM provider's key and register its preset, with
|
|
|
42
42
|
`kindgi dev` running, from another terminal. For Claude:
|
|
43
43
|
|
|
44
44
|
```sh
|
|
45
|
-
{{KINDGI}} secrets set ANTHROPIC_API_KEY --env=local --scope=tenant # no-echo prompt; writes .env
|
|
45
|
+
{{KINDGI}} secrets set ANTHROPIC_API_KEY --env=local --scope=tenant # no-echo prompt; writes .kindgi/secrets.env
|
|
46
46
|
{{KINDGI}} providers register --preset=anthropic # Opus 5.5, Sonnet 5.5 (default), Haiku 5.5, Haiku 4.5
|
|
47
47
|
```
|
|
48
48
|
|
|
@@ -47,7 +47,7 @@ use a real model, set one LLM provider's key and register its preset, with
|
|
|
47
47
|
`kindgi dev` running, from another terminal. For Claude:
|
|
48
48
|
|
|
49
49
|
```sh
|
|
50
|
-
{{KINDGI}} secrets set ANTHROPIC_API_KEY --env=local --scope=tenant # no-echo prompt; writes .env
|
|
50
|
+
{{KINDGI}} secrets set ANTHROPIC_API_KEY --env=local --scope=tenant # no-echo prompt; writes .kindgi/secrets.env
|
|
51
51
|
{{KINDGI}} providers register --preset=anthropic # Opus 5.5, Sonnet 5.5 (default), Haiku 5.5, Haiku 4.5
|
|
52
52
|
```
|
|
53
53
|
|
|
@@ -16,7 +16,8 @@
|
|
|
16
16
|
//
|
|
17
17
|
// The runtime resolves the secret on every call from its secrets
|
|
18
18
|
// store, in the env the ref names — under `kindgi dev`, env `local`
|
|
19
|
-
// is your `.env` / `.env.local
|
|
19
|
+
// is your `.env` / `.env.local`, then Kindgi's own `.kindgi/secrets.env`
|
|
20
|
+
// (where `kindgi secrets set` writes). A secret it can't find fails the
|
|
20
21
|
// call with `secret-unavailable`, naming it.
|
|
21
22
|
|
|
22
23
|
import { defineTool } from '@kindgi/sdk/define';
|
|
@@ -58,7 +58,7 @@ use a real model, set one LLM provider's key and register its preset, with
|
|
|
58
58
|
`kindgi dev` running, from another terminal. For Claude:
|
|
59
59
|
|
|
60
60
|
```sh
|
|
61
|
-
./kindgiw secrets set ANTHROPIC_API_KEY --env=local --scope=tenant # no-echo prompt; writes .env
|
|
61
|
+
./kindgiw secrets set ANTHROPIC_API_KEY --env=local --scope=tenant # no-echo prompt; writes .kindgi/secrets.env
|
|
62
62
|
./kindgiw providers register --preset=anthropic # Opus 5.5, Sonnet 5.5, Haiku 4.5
|
|
63
63
|
```
|
|
64
64
|
|