@cavelon/cli 0.2.16 → 0.2.18
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/dist/commands/init.js +3 -2
- package/dist/commands/limits-set.js +27 -5
- package/dist/commands/limits.js +16 -4
- package/dist/commands/setup.js +4 -1
- package/dist/commands/solution.js +3 -3
- package/dist/commands/work.js +84 -7
- package/dist/kit-codes.js +1 -0
- package/dist/limits.js +25 -2
- package/dist/mcp.js +2 -2
- package/dist/native-assets/THIRD-PARTY-NOTICES +3 -3
- package/dist/native-assets/kilo-server.mjs +74 -18
- package/dist/native-assets/kilo-tui.mjs +74 -18
- package/dist/native-assets/manifest.json +14 -14
- package/dist/native-assets/omp-extension.mjs +74 -18
- package/dist/native-assets/opencode-server.mjs +74 -18
- package/dist/native-assets/opencode-tui.mjs +74 -18
- package/dist/native-assets/pi-extension.mjs +74 -18
- package/dist/skills/cavelon-authoring/SKILL.md +11 -2
- package/dist/skills/cavelon-long-running/SKILL.md +7 -0
- package/dist/skills/cavelon-loop/SKILL.md +19 -5
- package/dist/skills/cavelon-loop/references/connection-readiness.md +48 -0
- package/dist/skills/cavelon-testing/SKILL.md +35 -14
- package/package.json +2 -2
|
@@ -13,6 +13,16 @@ use it when you parse the result.
|
|
|
13
13
|
|
|
14
14
|
## Before anything
|
|
15
15
|
|
|
16
|
+
- **Verify the connection before instance work.** Discover this session's
|
|
17
|
+
Cavelon tools (use the client's tool search if deferred), then call
|
|
18
|
+
`whoami` for the selected solution folder. Loaded skills do not establish
|
|
19
|
+
connectivity. Tell the person immediately if the tools are unavailable,
|
|
20
|
+
login is missing or the instance cannot be reached, with a repair step.
|
|
21
|
+
Announce CLI fallback explicitly and check its `whoami` too. See
|
|
22
|
+
[connection readiness](references/connection-readiness.md) for diagnosis,
|
|
23
|
+
recovery and when to repeat the check. An intentionally CLI-only client
|
|
24
|
+
starts with `cavelon whoami --json` instead, without a missing-MCP warning.
|
|
25
|
+
Local authoring may continue.
|
|
16
26
|
- **Select the local solution folder.** In a repository with several solutions,
|
|
17
27
|
pass `solution_dir`, such as `solutions/review`, on MCP calls. It resolves
|
|
18
28
|
inside the server's startup workspace and selects that folder's
|
|
@@ -39,10 +49,12 @@ use it when you parse the result.
|
|
|
39
49
|
person who does it (the description says who), as for a secret. Where the
|
|
40
50
|
instance does not say (an older one), try, and a refusal names what the
|
|
41
51
|
credential lacks.
|
|
42
|
-
- **Never handle a token.**
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
52
|
+
- **Never handle a token.** A missing, expired or revoked credential needs
|
|
53
|
+
`cavelon login --instance <url>`, run by the person in their own terminal
|
|
54
|
+
(or with a `!` prefix where the client offers one). Exit 7 can also mean a
|
|
55
|
+
permission or tenant refusal: follow its role/target guidance rather than
|
|
56
|
+
requesting another login. Never ask for a token or put one in a file or
|
|
57
|
+
an argument.
|
|
46
58
|
- **Secrets are set by a person.** When a preview or `cavelon secrets list`
|
|
47
59
|
names a secret that is not set, tell the person the exact command to run in
|
|
48
60
|
their terminal, `cavelon secrets set <name>` (as `apply` prints it, with its
|
|
@@ -200,7 +212,9 @@ in a pinned recovery snapshot and clears the draft; report its warnings.
|
|
|
200
212
|
agent alone leaves the Canvas debug entry incomplete. Follow the
|
|
201
213
|
authoring skill's Canvas entrypoints reference, including its Masterloop
|
|
202
214
|
iteration exceptions. This does not activate a trigger or run its demo.
|
|
203
|
-
3. **Validate**
|
|
215
|
+
3. **Validate** the package: `cavelon validate`. Use `--offline` when the
|
|
216
|
+
instance must not be contacted; it uses cached metadata and reports checks
|
|
217
|
+
it cannot make. Fix every error; `cavelon explain
|
|
204
218
|
<code>` says what a code means and how to fix it. Besides the schema it
|
|
205
219
|
finds duplicate slugs, handoffs and test assertions naming an agent the
|
|
206
220
|
package lacks, fields the schema does not have (with "did you mean"), and
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
# Check the connection before instance work
|
|
2
|
+
|
|
3
|
+
Loaded skills, a plugin marked installed, and a successful MCP handshake are
|
|
4
|
+
different from a working, authenticated instance connection. Before the first
|
|
5
|
+
instance operation for a selected solution folder in this session:
|
|
6
|
+
|
|
7
|
+
If this client intentionally uses CLI-only access, start with
|
|
8
|
+
`cavelon whoami --json` in the selected folder/target instead. Do not report
|
|
9
|
+
a missing MCP connection for a setup that does not use MCP. For native
|
|
10
|
+
Cavelon integrations, discover their `whoami` tool as you would an MCP tool.
|
|
11
|
+
|
|
12
|
+
1. For an MCP/native-tool integration, discover the Cavelon tools in the
|
|
13
|
+
**actual coding-agent session**. Use the
|
|
14
|
+
client's tool search where tools are deferred; not seeing an eagerly listed
|
|
15
|
+
tool does not establish that the server is absent. Find `whoami`, rather
|
|
16
|
+
than guessing a client-specific tool prefix.
|
|
17
|
+
2. Call that `whoami`, with the same `solution_dir` and tenant selection
|
|
18
|
+
the task will use. On success, briefly tell the person that Cavelon is
|
|
19
|
+
connected and authenticated and check the returned target and permissions.
|
|
20
|
+
A successful call does not grant permissions its credential lacks.
|
|
21
|
+
3. If discovery or the call fails, **tell the person before proceeding**:
|
|
22
|
+
|
|
23
|
+
| Observation | What to explain and how to recover |
|
|
24
|
+
|---|---|
|
|
25
|
+
| No usable Cavelon tools after discovery, or a transport failure | Cavelon's MCP connection is unavailable in this session. In Claude Code open `/mcp`, inspect the Cavelon server and reconnect it. Run `cavelon setup --check --agents claude` in a terminal for installation/start/login diagnostics; repair what it reports, then restart or reconnect the coding agent. Other clients use their own MCP/tools panel. |
|
|
26
|
+
| `no_instance` | No instance is selected for this folder. Check its `cavelon.yaml`/environment; for a new setup, a person runs `cavelon login --instance <url>` in their own terminal. |
|
|
27
|
+
| No token, expired/revoked token or an authentication refusal | Explain that Cavelon needs login again. A person runs `cavelon login --instance <url>` themselves. Never read, request or paste their token. |
|
|
28
|
+
| Network, TLS, DNS or instance failure | Explain that the instance cannot be reached and pass on the error's safe repair hint. Do not describe it as a missing plugin or ask for another token without an authentication error. |
|
|
29
|
+
| Permission or tenant refusal | The server is reachable, but this credential cannot perform that operation or enter that tenant. Follow the returned permission/target guidance. |
|
|
30
|
+
|
|
31
|
+
**Do not silently fall back.** A working CLI is a valid alternative, but say
|
|
32
|
+
"Cavelon MCP is unavailable; I am using the CLI instead" and check
|
|
33
|
+
`cavelon whoami --json` for the selected folder/target before using it. The
|
|
34
|
+
same permissions and confirmation rules apply. Offline authoring and
|
|
35
|
+
formatting may continue; do not claim instance validation, a test run, an
|
|
36
|
+
import or a deployment without a successful result from that operation.
|
|
37
|
+
|
|
38
|
+
Report a warning once while its cause stays the same. Check again after a
|
|
39
|
+
reconnect, login, selected-target change or subsequent connection failure,
|
|
40
|
+
and announce recovery once. Do not probe the connection before every tool.
|
|
41
|
+
|
|
42
|
+
Claude Code's plugin startup hook shows a notice in a Cavelon workspace,
|
|
43
|
+
including repositories with child solutions. It checks only whether `cavelon`
|
|
44
|
+
or `npx` is on PATH, without executing either, fetching packages, reading
|
|
45
|
+
credentials or contacting the instance. Its notice says the connection is
|
|
46
|
+
**not yet verified**, not failed. SessionStart runs before MCP is available;
|
|
47
|
+
the in-session check above supplies the actual evidence. A new-solution
|
|
48
|
+
request in an unrelated folder gets this check when the skill is first used.
|
|
@@ -6,10 +6,17 @@ license: Apache-2.0
|
|
|
6
6
|
|
|
7
7
|
# Testing and optimizing a Cavelon solution
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
package
|
|
9
|
+
Readiness comes from the instance's published test gate and other checks;
|
|
10
|
+
package validation alone does not establish it. Test against a draft solution or a test tenant
|
|
11
11
|
(`--env test`), never by trying things on an active solution.
|
|
12
12
|
|
|
13
|
+
Before instance tests, follow cavelon-loop's connection readiness check:
|
|
14
|
+
discover the actual session's Cavelon tools and call `whoami`. Tell the
|
|
15
|
+
person immediately if discovery, login or instance access fails. Announce
|
|
16
|
+
CLI fallback and check its `whoami` too; never claim tests ran without their
|
|
17
|
+
successful instance results. Loaded skills alone do not prove connectivity.
|
|
18
|
+
An intentionally CLI-only setup checks `cavelon whoami --json` directly.
|
|
19
|
+
|
|
13
20
|
## Canvas debug readiness
|
|
14
21
|
|
|
15
22
|
For a newly authored ordinary chat/trigger solution, check its connected
|
|
@@ -50,8 +57,11 @@ Write cases for:
|
|
|
50
57
|
|
|
51
58
|
A step's `evaluation_criteria` can hold, besides the judge's criteria (plain
|
|
52
59
|
sentences), **assertions**: objects with a `type` and a `value`, checked in
|
|
53
|
-
code before the judge runs. A failed assertion fails the step whatever
|
|
54
|
-
judge says, so use them for facts with one right answer
|
|
60
|
+
code before the judge runs. A failed gating assertion fails the step whatever
|
|
61
|
+
the judge says, so use them for facts with one right answer. Where the schema
|
|
62
|
+
offers `gate: false`, a report-only assertion is evaluated and shown without
|
|
63
|
+
failing the step; the plain-language reference in cavelon-authoring has an
|
|
64
|
+
example. Check the criterion schema before using that field.
|
|
55
65
|
|
|
56
66
|
| Type | Value | Passes when |
|
|
57
67
|
|---|---|---|
|
|
@@ -151,7 +161,9 @@ each call under your shell's time limit). `test run --wait --timeout 5m` does
|
|
|
151
161
|
both in one call where your client allows long commands; when its wait ends
|
|
152
162
|
first, its last line is the command that resumes, with the same timeout. Exit 1 after a run
|
|
153
163
|
means a case failed, even though the run itself finished; the output names the
|
|
154
|
-
cases that did not pass and why, and `cavelon trace <run>` shows each one.
|
|
164
|
+
cases that did not pass and why, and `cavelon trace <run>` shows each one.
|
|
165
|
+
This case-result exit code is separate from the instance's readiness verdict,
|
|
166
|
+
which can use a configured pass threshold, tag minimums and gate profile. Exit
|
|
155
167
|
1 also means the run measured nothing comparable (steps not run, technical
|
|
156
168
|
errors, no pass rate): it is no evidence the solution works, so do not go on to
|
|
157
169
|
`activate`; find the cause and run again. Exit 5 means answers wait for a
|
|
@@ -174,9 +186,16 @@ The case's own reason (which knowledge base, which value) is in the output of
|
|
|
174
186
|
Without `--suite`, `test run` runs every suite of the solution except those
|
|
175
187
|
that never vote in readiness: a campaign's question check (tagged `engagement`
|
|
176
188
|
and `rule:<id>`, made by the Admin's Engagement editor, and never part of the
|
|
177
|
-
package)
|
|
178
|
-
failed question there is a content
|
|
179
|
-
`--suite <name>` runs one when asked.
|
|
189
|
+
package), or a suite a person switched out of the vote. They are listed under
|
|
190
|
+
`skipped` and never change the exit code; a failed question there is a content
|
|
191
|
+
gap for the campaign's author. `--suite <name>` runs one when asked.
|
|
192
|
+
|
|
193
|
+
`--profile <key>` runs a suite's run profile (its `settings.profiles`, chosen
|
|
194
|
+
by tags) instead of the whole suite, for example a smoke profile before a
|
|
195
|
+
deploy; without `--suite`, every suite that has it, the others skipped as
|
|
196
|
+
`no_profile`. Where a suite's `gate.profile` names a profile, only a run of it
|
|
197
|
+
counts for publishing: run that one before asking for activation. `--tags`
|
|
198
|
+
runs the cases carrying one of the tags and never counts for publishing.
|
|
180
199
|
|
|
181
200
|
## Database query tools
|
|
182
201
|
|
|
@@ -279,8 +298,10 @@ the Admin. Then:
|
|
|
279
298
|
says how to fix it.
|
|
280
299
|
|
|
281
300
|
Unattended schedules, where offered by the instance, are enabled by a person in
|
|
282
|
-
the Admin. A schedule or automatic run is useful regression evidence
|
|
283
|
-
|
|
301
|
+
the Admin. A schedule or automatic run is useful regression evidence. Before
|
|
302
|
+
activation/publication, run the manual selection required by the instance's
|
|
303
|
+
published readiness policy: its gate profile when configured, otherwise the
|
|
304
|
+
whole suite. A whole-suite run does not substitute for a required gate profile.
|
|
284
305
|
Read the instance's current Graph Check errors and published catalog; fix the
|
|
285
306
|
named node/configuration before trying activation again.
|
|
286
307
|
|
|
@@ -412,7 +433,8 @@ previews first and is the person's decision: show the preview; over MCP the
|
|
|
412
433
|
client asks them when you confirm with its token, and from your shell they run
|
|
413
434
|
the confirm command in their own terminal. Do not add a separate chat approval
|
|
414
435
|
before that native dialog; an explicitly enabled YOLO mode still asks for this
|
|
415
|
-
critical change.
|
|
436
|
+
critical change. Review test failures and run the readiness selection required
|
|
437
|
+
by the instance; when its published readiness checks pass,
|
|
416
438
|
`cavelon activate --harness <name or slug>` goes through the readiness gate; if the
|
|
417
439
|
token may not activate, a person activates in the Admin. A solution that a
|
|
418
440
|
channel or an active trigger reaches goes live for them at once, so its
|
|
@@ -422,6 +444,5 @@ whose reach or route effect is unknown. It needs no confirm only when no
|
|
|
422
444
|
channel or active trigger reaches it and readiness explicitly says
|
|
423
445
|
`takes_default_route: false`. The preview reserves no route state; the
|
|
424
446
|
successful result's `took_default_route` fields report the actual effect.
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
the confirm command in their own terminal.
|
|
447
|
+
Where the preview requires a person, show it and use that single native
|
|
448
|
+
approval or the person's own-terminal command.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cavelon/cli",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.18",
|
|
4
4
|
"description": "The cavelon binary: CLI and local MCP server for building Cavelon solutions with a coding agent.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"homepage": "https://github.com/goodguys-gmbh/cavelon-dev-kit",
|
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
"@types/node": "^20.19.0",
|
|
47
47
|
"esbuild": "0.28.2",
|
|
48
48
|
"eslint": "^10.12.0",
|
|
49
|
-
"typebox": "1.4.
|
|
49
|
+
"typebox": "1.4.3",
|
|
50
50
|
"typescript": "~6.0.3",
|
|
51
51
|
"typescript-eslint": "^8.71.0",
|
|
52
52
|
"vitest": "^4.0.0",
|