@cavelon/cli 0.2.10 → 0.2.11
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 +2 -2
- package/dist/commands/tenants.js +3 -2
- package/dist/native-assets/THIRD-PARTY-NOTICES +2 -2
- package/dist/native-assets/kilo-server.mjs +50 -1
- package/dist/native-assets/kilo-tui.mjs +38 -1
- package/dist/native-assets/manifest.json +15 -15
- package/dist/native-assets/omp-extension.mjs +209 -281
- package/dist/native-assets/opencode-server.mjs +50 -1
- package/dist/native-assets/opencode-tui.mjs +38 -1
- package/dist/native-assets/pi-extension.mjs +209 -281
- package/dist/setup-agents.js +1 -0
- package/dist/skills/cavelon-authoring/SKILL.md +11 -0
- package/dist/skills/cavelon-authoring/references/canvas-entrypoints.md +83 -0
- package/dist/skills/cavelon-long-running/SKILL.md +6 -0
- package/dist/skills/cavelon-loop/SKILL.md +5 -0
- package/dist/skills/cavelon-testing/SKILL.md +38 -0
- package/package.json +3 -3
package/dist/setup-agents.js
CHANGED
|
@@ -584,6 +584,7 @@ async function removeSkills(record, skills, stillUsed) {
|
|
|
584
584
|
if (isGenerated(await readTextFile(full).catch(() => undefined))) {
|
|
585
585
|
await fs.rm(full, { force: true });
|
|
586
586
|
removed++;
|
|
587
|
+
await removeEmptyDirs(path.dirname(full), folder);
|
|
587
588
|
}
|
|
588
589
|
}
|
|
589
590
|
await fs.rmdir(folder).catch(() => undefined);
|
|
@@ -11,6 +11,17 @@ format as a JSON Schema; `cavelon` splits it along that schema's top-level
|
|
|
11
11
|
sections, so the files follow whatever the instance version defines. Do not
|
|
12
12
|
assume a section or field exists: check the schema or the docs first.
|
|
13
13
|
|
|
14
|
+
## New solutions: make the Canvas useful
|
|
15
|
+
|
|
16
|
+
For a new ordinary chat or trigger solution, include its connected **Chat
|
|
17
|
+
Start** (`chat_start`) or **Trigger Start** (`trigger_start`) and useful saved
|
|
18
|
+
demo input as part of authoring, even though start nodes are optional. An
|
|
19
|
+
agent marked `is_entrypoint: true` alone does not provide that Canvas debug
|
|
20
|
+
entry. See [Canvas entrypoints](references/canvas-entrypoints.md) for the
|
|
21
|
+
package shape, trigger demo defaults and Masterloop iteration exceptions.
|
|
22
|
+
Preserve an existing solution's entry design unless the requested work needs
|
|
23
|
+
it changed; do not add live triggers just to provide a demo.
|
|
24
|
+
|
|
14
25
|
## Before you plan: the instance's limits
|
|
15
26
|
|
|
16
27
|
Read `cavelon limits` (or the `limits` MCP tool) before you design or change a
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
# Canvas entrypoints and demo inputs
|
|
2
|
+
|
|
3
|
+
When creating an ordinary chat or trigger solution, leave it ready to inspect
|
|
4
|
+
and debug in the Canvas. Start nodes are optional in the platform, so schema
|
|
5
|
+
validation alone cannot establish this. Read the instance's schema for
|
|
6
|
+
`registry_entities.orchestration_nodes`, `registry_entities.graph_edges`,
|
|
7
|
+
`NodeConfig_chat_start` and `NodeConfig_trigger_start` before writing them;
|
|
8
|
+
`cavelon docs get reference/nodes-and-edges` explains the graph rules.
|
|
9
|
+
|
|
10
|
+
## Chat
|
|
11
|
+
|
|
12
|
+
Add one `chat_start` and a `pipeline` edge to the first agent or workflow node
|
|
13
|
+
in the same harness. Give `config.demo_message` a realistic question from
|
|
14
|
+
the solution's tests, rather than a placeholder. For example, alongside an
|
|
15
|
+
agent `faq-agent` in harness `support-faq`, `package/registry_entities.yaml`:
|
|
16
|
+
|
|
17
|
+
```yaml
|
|
18
|
+
orchestration_nodes:
|
|
19
|
+
- slug: chat
|
|
20
|
+
name: Chat
|
|
21
|
+
node_type: chat_start
|
|
22
|
+
harness_slug: support-faq
|
|
23
|
+
config:
|
|
24
|
+
demo_message: When can I reach your support team?
|
|
25
|
+
canvas_x: 0
|
|
26
|
+
canvas_y: 200
|
|
27
|
+
graph_edges:
|
|
28
|
+
- harness_slug: support-faq
|
|
29
|
+
from_node_ref: {kind: orchestration, slug: chat}
|
|
30
|
+
to_node_ref: {kind: agent, slug: faq-agent}
|
|
31
|
+
edge_type: pipeline
|
|
32
|
+
config: {}
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
Keep conversation history on the Chat Start-to-agent edge at its default.
|
|
36
|
+
There is at most one active Chat Start per harness. Starts have no incoming
|
|
37
|
+
edges and cannot connect directly to a Join.
|
|
38
|
+
|
|
39
|
+
## Triggers
|
|
40
|
+
|
|
41
|
+
For each intended trigger entry, add a `trigger_start` whose
|
|
42
|
+
`config.trigger_slug` names the actual trigger in the same harness, then
|
|
43
|
+
connect it to the intended first agent or workflow node with a `pipeline`
|
|
44
|
+
edge. There is at most one Trigger Start per trigger. A chat-and-trigger
|
|
45
|
+
solution can have both kinds of start; a trigger-only solution needs no
|
|
46
|
+
artificial chat route.
|
|
47
|
+
|
|
48
|
+
Suggest and save `config.demo_payload` with realistic, non-sensitive example
|
|
49
|
+
values derived from the trigger's actual `config.payload_schema` and
|
|
50
|
+
`config.sample_payload`. Include required fields, honor types, enums and
|
|
51
|
+
formats, and choose values that exercise a useful path. For a trigger whose
|
|
52
|
+
contract requires `order_id` (string) and `total` (number), an appropriate
|
|
53
|
+
node fragment is:
|
|
54
|
+
|
|
55
|
+
```yaml
|
|
56
|
+
node_type: trigger_start
|
|
57
|
+
config:
|
|
58
|
+
trigger_slug: order-received
|
|
59
|
+
demo_payload: {order_id: DEMO-1001, total: 49.9}
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
Keep the trigger's `config.sample_payload` coherent with that demo. On a
|
|
63
|
+
webhook, the **trigger's** `config.payload_schema` validates incoming
|
|
64
|
+
payloads. A start node's `sample_payload` or `payload_schema` does not replace
|
|
65
|
+
that runtime contract. Supply `demo_request_context` or
|
|
66
|
+
`demo_document_names` only when the scenario needs them and the schema offers
|
|
67
|
+
them. Demo input neither sets secrets nor grants execution identity; keep a
|
|
68
|
+
new trigger inactive until the intended activation is approved.
|
|
69
|
+
|
|
70
|
+
## Exceptions and completion
|
|
71
|
+
|
|
72
|
+
Masterloop **iteration** harnesses have constrained entrypoints. A native
|
|
73
|
+
iteration requires its agent to be the only root, marked `is_entrypoint`;
|
|
74
|
+
pure iterations must also retain their required unambiguous root. Follow
|
|
75
|
+
those rules rather than inserting a Chat Start or Trigger Start. Put the
|
|
76
|
+
external trigger entry on the parent where appropriate. Do not rewrite legacy or deliberately
|
|
77
|
+
headless harnesses solely to satisfy this recommendation.
|
|
78
|
+
|
|
79
|
+
Before handing over a new ordinary solution, check that its start references
|
|
80
|
+
the right harness/trigger, its outgoing edge resolves, and its saved demo
|
|
81
|
+
input is useful and schema-compatible. Validate and preview the whole
|
|
82
|
+
package, then use the cavelon-testing skill for suites and Canvas debugging.
|
|
83
|
+
Running a Canvas demo executes real tools; saved examples alone run nothing.
|
|
@@ -36,6 +36,12 @@ Do not work around it; use the other column.
|
|
|
36
36
|
skill). `cavelon validate`, then `cavelon apply --env test`: the preview shows
|
|
37
37
|
the loop's budget, Sandboxes that an active solution writes to, and triggers
|
|
38
38
|
whose execution identity is missing.
|
|
39
|
+
Give an externally triggered parent a connected Trigger Start with
|
|
40
|
+
`config.trigger_slug` and realistic `config.demo_payload` derived from
|
|
41
|
+
the trigger's schema/sample. See the authoring skill's Canvas entrypoints
|
|
42
|
+
reference. Do not add starts to constrained native/pure iteration
|
|
43
|
+
harnesses: preserve their required entrypoint rules. Saved
|
|
44
|
+
demo input neither binds an execution identity nor starts a loop.
|
|
39
45
|
2. **Bind the test Sandbox** in `env/test.yaml` (`runtime_bindings`), never the
|
|
40
46
|
live one: a loop test needs a Sandbox of its own, because only one writer at a
|
|
41
47
|
time may use it.
|
|
@@ -195,6 +195,11 @@ in a pinned recovery snapshot and clears the draft; report its warnings.
|
|
|
195
195
|
remove it unless the person wants it.
|
|
196
196
|
2. **Edit** the files in `package/` (one file per schema section) and `tests/`
|
|
197
197
|
(one file per test suite). See the cavelon-authoring skill.
|
|
198
|
+
For a new ordinary chat/trigger solution, also author the connected Chat
|
|
199
|
+
Start or Trigger Start with realistic saved demo input; an entrypoint
|
|
200
|
+
agent alone leaves the Canvas debug entry incomplete. Follow the
|
|
201
|
+
authoring skill's Canvas entrypoints reference, including its Masterloop
|
|
202
|
+
iteration exceptions. This does not activate a trigger or run its demo.
|
|
198
203
|
3. **Validate** offline: `cavelon validate`. Fix every error; `cavelon explain
|
|
199
204
|
<code>` says what a code means and how to fix it. Besides the schema it
|
|
200
205
|
finds duplicate slugs, handoffs and test assertions naming an agent the
|
|
@@ -10,6 +10,23 @@ A solution is ready when its test suites pass on the instance, not when the
|
|
|
10
10
|
package validates. Test against a draft solution or a test tenant
|
|
11
11
|
(`--env test`), never by trying things on an active solution.
|
|
12
12
|
|
|
13
|
+
## Canvas debug readiness
|
|
14
|
+
|
|
15
|
+
For a newly authored ordinary chat/trigger solution, check its connected
|
|
16
|
+
Chat Start or Trigger Start as well as its suites. The Chat Start should
|
|
17
|
+
have a useful `config.demo_message`; a Trigger Start should bind the right
|
|
18
|
+
`config.trigger_slug` and save `config.demo_payload` matching that trigger's
|
|
19
|
+
payload contract. Check a realistic happy path and a relevant edge case in
|
|
20
|
+
the suites. The cavelon-authoring skill's Canvas entrypoints reference covers
|
|
21
|
+
the package shapes and exceptions for Masterloop iteration harnesses.
|
|
22
|
+
|
|
23
|
+
After apply, inspect the saved input and route in the draft's Canvas when
|
|
24
|
+
the UI is available (`cavelon docs get concepts/playground-and-debugging`).
|
|
25
|
+
**Run demo executes real tools**, including external writes. Check the test
|
|
26
|
+
tenant, bindings and effects before running it; no secret belongs in demo
|
|
27
|
+
input. If you cannot inspect the UI, report that check as outstanding rather
|
|
28
|
+
than claiming a Canvas run from package validation alone.
|
|
29
|
+
|
|
13
30
|
## Test suites
|
|
14
31
|
|
|
15
32
|
Suites live in `tests/`, one YAML file per suite, and `apply` imports them with
|
|
@@ -85,6 +102,27 @@ it as a judge criterion instead of checking it, so read `cavelon docs get
|
|
|
85
102
|
concepts/regression-testing` for the types the instance knows before relying on
|
|
86
103
|
`answered_by` or `handoff_to`.
|
|
87
104
|
|
|
105
|
+
## Trigger output checks
|
|
106
|
+
|
|
107
|
+
Inspect a completed trigger's output before choosing its assertions. A text
|
|
108
|
+
agent returns text directly; it has no implicit `answer` JSON field. Omit
|
|
109
|
+
`json_path` for text and check the output itself, for example:
|
|
110
|
+
|
|
111
|
+
```yaml
|
|
112
|
+
type: trigger
|
|
113
|
+
trigger:
|
|
114
|
+
trigger_slug: stock-updated
|
|
115
|
+
input: {item_id: DEMO-SKU-0, quantity: 0, active: false}
|
|
116
|
+
expect_status: completed
|
|
117
|
+
output:
|
|
118
|
+
- contains: "quantity=0; active=false"
|
|
119
|
+
```
|
|
120
|
+
|
|
121
|
+
Use `json_path` only for structured JSON output and a path that the actual
|
|
122
|
+
output contains. Prefer `contains` or a bounded `matches` pattern when exact
|
|
123
|
+
punctuation is not part of the requirement. A completed run can still have
|
|
124
|
+
failed assertions; fix and rerun those before calling the suite passed.
|
|
125
|
+
|
|
88
126
|
## Testing an approval
|
|
89
127
|
|
|
90
128
|
A test run never waits for a person and never approves anything. A run that
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cavelon/cli",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.11",
|
|
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,10 +46,10 @@
|
|
|
46
46
|
"@types/node": "^20.19.0",
|
|
47
47
|
"esbuild": "0.28.2",
|
|
48
48
|
"eslint": "^10.12.0",
|
|
49
|
-
"typebox": "1.
|
|
49
|
+
"typebox": "1.4.2",
|
|
50
50
|
"typescript": "~6.0.3",
|
|
51
51
|
"typescript-eslint": "^8.71.0",
|
|
52
52
|
"vitest": "^4.0.0",
|
|
53
|
-
"zod": "4.6.
|
|
53
|
+
"zod": "4.6.7"
|
|
54
54
|
}
|
|
55
55
|
}
|