cool-workflow 0.1.82 → 0.1.84
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/.claude-plugin/plugin.json +2 -2
- package/.codex-plugin/plugin.json +4 -4
- package/README.md +128 -120
- package/apps/architecture-review/app.json +1 -1
- package/apps/architecture-review-fast/app.json +1 -1
- package/apps/end-to-end-golden-path/app.json +1 -1
- package/apps/pr-review-fix-ci/app.json +1 -1
- package/apps/release-cut/app.json +1 -1
- package/apps/research-synthesis/app.json +1 -1
- package/dist/capability-core.js +16 -8
- package/dist/capability-registry.js +270 -0
- package/dist/cli/command-surface.js +1320 -0
- package/dist/cli.js +2 -1307
- package/dist/commit.js +5 -1
- package/dist/doctor.js +153 -0
- package/dist/mcp-server.js +15 -1451
- package/dist/mcp-surface.js +1441 -0
- package/dist/orchestrator.js +13 -0
- package/dist/reclamation/hash.js +72 -0
- package/dist/reclamation.js +25 -78
- package/dist/run-registry/queue.js +6 -7
- package/dist/run-registry.js +35 -24
- package/dist/scheduler.js +78 -53
- package/dist/version.js +1 -1
- package/dist/worker-accept/acceptance.js +114 -0
- package/dist/worker-accept/blackboard-fanout.js +80 -0
- package/dist/worker-accept/blackboard-linkage.js +19 -0
- package/dist/worker-accept/context.js +2 -0
- package/dist/worker-accept/telemetry-ledger.js +116 -0
- package/dist/worker-accept/validation.js +77 -0
- package/dist/worker-accept/verifier-completion.js +73 -0
- package/dist/worker-isolation.js +41 -446
- package/docs/agent-delegation-drive.7.md +94 -86
- package/docs/agent-framework.md +33 -32
- package/docs/candidate-scoring.7.md +26 -24
- package/docs/canonical-workflow-apps.7.md +40 -40
- package/docs/capability-topology-registry.7.md +24 -24
- package/docs/cli-mcp-parity.7.md +230 -154
- package/docs/contract-migration-tooling.7.md +52 -41
- package/docs/control-plane-scheduling.7.md +49 -41
- package/docs/coordinator-blackboard.7.md +30 -30
- package/docs/dogfood-one-real-repo.7.md +44 -44
- package/docs/durable-state-and-locking.7.md +38 -30
- package/docs/end-to-end-golden-path.7.md +29 -29
- package/docs/error-feedback.7.md +27 -27
- package/docs/evidence-adoption-reasoning-chain.7.md +66 -58
- package/docs/execution-backends.7.md +88 -80
- package/docs/getting-started.md +35 -18
- package/docs/index.md +3 -3
- package/docs/mcp-app-surface.7.md +64 -64
- package/docs/multi-agent-cli-mcp-surface.7.md +86 -77
- package/docs/multi-agent-eval-replay-harness.7.md +63 -55
- package/docs/multi-agent-operator-ux.7.md +73 -65
- package/docs/multi-agent-runtime-core.7.md +39 -39
- package/docs/multi-agent-topologies.7.md +24 -24
- package/docs/multi-agent-trust-policy-audit.7.md +38 -38
- package/docs/node-snapshot-diff-replay.7.md +30 -22
- package/docs/observability-cost-accounting.7.md +53 -45
- package/docs/operator-ux.7.md +30 -30
- package/docs/pipeline-runner.7.md +31 -31
- package/docs/project-index.md +16 -5
- package/docs/real-execution-backends.7.md +51 -43
- package/docs/release-and-migration.7.md +46 -38
- package/docs/release-tooling.7.md +67 -50
- package/docs/routines.md +16 -16
- package/docs/run-registry-control-plane.7.md +124 -116
- package/docs/run-retention-reclamation.7.md +49 -41
- package/docs/sandbox-profiles.7.md +32 -32
- package/docs/scheduled-tasks.md +14 -14
- package/docs/security-trust-hardening.7.md +29 -29
- package/docs/source-context-profiles.7.md +28 -28
- package/docs/state-explosion-management.7.md +67 -59
- package/docs/state-node.7.md +8 -8
- package/docs/team-collaboration.7.md +66 -58
- package/docs/trust-model.md +126 -126
- package/docs/unix-principles.md +80 -80
- package/docs/vendor-manifest-loadability.7.md +20 -20
- package/docs/verifier-gated-commit.7.md +16 -16
- package/docs/web-desktop-workbench.7.md +73 -65
- package/docs/worker-isolation.7.md +34 -37
- package/docs/workflow-app-framework.7.md +38 -38
- package/manifest/plugin.manifest.json +4 -4
- package/package.json +3 -2
- package/scripts/bump-version.js +9 -1
- package/scripts/canonical-apps.js +4 -4
- package/scripts/dogfood-release.js +1 -1
- package/scripts/gen-parity-doc.js +106 -0
- package/scripts/golden-path.js +4 -4
- package/scripts/parity-check.js +27 -57
- package/scripts/release-flow.js +7 -6
- package/scripts/sync-project-index.js +1 -1
- package/dist/verifier-registry.js +0 -46
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# Canonical Workflow Apps
|
|
2
2
|
|
|
3
|
-
Canonical Workflow Apps are the official CW userland apps
|
|
4
|
-
runtime. They are not loose examples. Each one
|
|
3
|
+
Canonical Workflow Apps are the official CW userland apps kept up with the
|
|
4
|
+
runtime. They are not loose examples. Each one is in a first-class app
|
|
5
5
|
directory:
|
|
6
6
|
|
|
7
7
|
```text
|
|
@@ -9,7 +9,7 @@ apps/<app-id>/app.json
|
|
|
9
9
|
apps/<app-id>/workflow.js
|
|
10
10
|
```
|
|
11
11
|
|
|
12
|
-
The runner
|
|
12
|
+
The runner is still the base system. Canonical apps add domain behavior:
|
|
13
13
|
inputs, phases, task prompts, evidence gates, sandbox profile hints, and app
|
|
14
14
|
metadata.
|
|
15
15
|
|
|
@@ -17,8 +17,8 @@ metadata.
|
|
|
17
17
|
|
|
18
18
|
`architecture-review`
|
|
19
19
|
|
|
20
|
-
Map a repository architecture,
|
|
21
|
-
|
|
20
|
+
Map out a repository architecture, weigh the risks, check the important
|
|
21
|
+
findings, and put together an evidence-backed verdict.
|
|
22
22
|
|
|
23
23
|
```bash
|
|
24
24
|
node scripts/cw.js plan architecture-review \
|
|
@@ -31,10 +31,10 @@ node scripts/cw.js plan architecture-review \
|
|
|
31
31
|
`architecture-review-fast`
|
|
32
32
|
|
|
33
33
|
Run a shorter architecture review for a fast first result. The app keeps the
|
|
34
|
-
full `architecture-review` contract
|
|
34
|
+
full `architecture-review` contract open under its first id, but uses two
|
|
35
35
|
parallel Map workers, two parallel Assess workers, one verifier, and one verdict
|
|
36
|
-
worker. Operators
|
|
37
|
-
mapping/assessment work to a faster model while
|
|
36
|
+
worker. Operators may give a pinned JSONL source context and send
|
|
37
|
+
mapping/assessment work to a faster model while keeping stronger models for
|
|
38
38
|
verification and synthesis.
|
|
39
39
|
|
|
40
40
|
```bash
|
|
@@ -47,29 +47,29 @@ node scripts/architecture-review-fast.js \
|
|
|
47
47
|
--schedule-full
|
|
48
48
|
```
|
|
49
49
|
|
|
50
|
-
The wrapper
|
|
51
|
-
the fast app, runs `quickstart architecture-review-fast`, and
|
|
50
|
+
The wrapper gets one cached JSONL source context ready, passes its sha256 digest to
|
|
51
|
+
the fast app, runs `quickstart architecture-review-fast`, and may make
|
|
52
52
|
a one-shot background schedule for the full `architecture-review` app. When run
|
|
53
|
-
against an
|
|
54
|
-
small repo-local `repo` profile
|
|
53
|
+
against an outside repo without `--profile` or `--profile-file`, it writes a
|
|
54
|
+
small repo-local `repo` profile that covers common tracked text surfaces such as
|
|
55
55
|
README/package metadata, `src/`, `lib/`, `apps/`, `scripts/`, docs, and tests.
|
|
56
|
-
If the
|
|
56
|
+
If the picked profile sends out zero records, the wrapper fails closed in place of
|
|
57
57
|
passing an empty context digest to the app.
|
|
58
|
-
`--fast-model` and `--strong-model` are userland policy flags;
|
|
58
|
+
`--fast-model` and `--strong-model` are userland policy flags; inside, they
|
|
59
59
|
set the same task-level hints as `CW_ARCHITECTURE_REVIEW_FAST_MODEL` and
|
|
60
60
|
`CW_ARCHITECTURE_REVIEW_STRONG_MODEL`.
|
|
61
|
-
`--metrics` is opt-in; when
|
|
61
|
+
`--metrics` is opt-in; when it is there the wrapper adds elapsed-time, worker-step,
|
|
62
62
|
agent-spawn, and result-cache-hit counts to the JSON payload so operators can
|
|
63
|
-
measure foreground wait
|
|
63
|
+
measure foreground wait cuts without changing the default output shape.
|
|
64
64
|
|
|
65
|
-
For long full reviews, use the
|
|
66
|
-
`architecture-review` in the background after the fast report has
|
|
65
|
+
For long full reviews, use the routine or schedule surfaces you have to run
|
|
66
|
+
`architecture-review` in the background after the fast report has come back.
|
|
67
67
|
|
|
68
68
|
`pr-review-fix-ci`
|
|
69
69
|
|
|
70
|
-
Review a pull request or branch,
|
|
71
|
-
|
|
72
|
-
|
|
70
|
+
Review a pull request or branch, look at CI failures, work out the issues
|
|
71
|
+
you can act on, patch when `--mode fix` is allowed, check the outcomes, and
|
|
72
|
+
give a short account with evidence.
|
|
73
73
|
|
|
74
74
|
```bash
|
|
75
75
|
node scripts/cw.js plan pr-review-fix-ci \
|
|
@@ -82,8 +82,8 @@ node scripts/cw.js plan pr-review-fix-ci \
|
|
|
82
82
|
|
|
83
83
|
`release-cut`
|
|
84
84
|
|
|
85
|
-
|
|
86
|
-
packaging, release notes, and
|
|
85
|
+
Get a release ready with checklist discipline: version checks, changelog, tests,
|
|
86
|
+
packaging, release notes, and a last verification.
|
|
87
87
|
|
|
88
88
|
```bash
|
|
89
89
|
node scripts/cw.js plan release-cut \
|
|
@@ -95,8 +95,8 @@ node scripts/cw.js plan release-cut \
|
|
|
95
95
|
|
|
96
96
|
`research-synthesis`
|
|
97
97
|
|
|
98
|
-
|
|
99
|
-
evidence,
|
|
98
|
+
Break a research question into claims, look into sources, cross-check
|
|
99
|
+
the evidence, check the claims, and put together a short answer.
|
|
100
100
|
|
|
101
101
|
```bash
|
|
102
102
|
node scripts/cw.js plan research-synthesis \
|
|
@@ -109,7 +109,7 @@ node scripts/cw.js plan research-synthesis \
|
|
|
109
109
|
|
|
110
110
|
## Validation Matrix
|
|
111
111
|
|
|
112
|
-
Run the canonical app matrix from the plugin root:
|
|
112
|
+
Run the canonical app matrix from the plugin root directory:
|
|
113
113
|
|
|
114
114
|
```bash
|
|
115
115
|
cd plugins/cool-workflow
|
|
@@ -118,19 +118,19 @@ npm run canonical-apps
|
|
|
118
118
|
|
|
119
119
|
The command uses only Node.js standard library APIs and local temporary
|
|
120
120
|
workspaces. It validates each canonical app, shows its app metadata, plans it
|
|
121
|
-
with
|
|
121
|
+
with sample inputs, checks app id/version metadata in run state, checks
|
|
122
122
|
evidence-required verification or synthesis/verdict tasks, checks sandbox
|
|
123
|
-
profile hints, checks unique task ids, and checks duplicate ids do not break
|
|
123
|
+
profile hints, checks unique task ids, and checks that duplicate ids do not break
|
|
124
124
|
discovery.
|
|
125
125
|
|
|
126
|
-
`npm test`
|
|
127
|
-
same core assertions against generated `dist/`.
|
|
126
|
+
`npm test` takes in `test/canonical-workflow-apps-smoke.js`, which does the
|
|
127
|
+
same core assertions again against generated `dist/`.
|
|
128
128
|
|
|
129
129
|
## Framework Pressure
|
|
130
130
|
|
|
131
|
-
The apps
|
|
131
|
+
The apps put weight on different parts of the Workflow App framework on purpose:
|
|
132
132
|
|
|
133
|
-
-
|
|
133
|
+
- named required, optional, and repeated inputs
|
|
134
134
|
- app-directory discovery and app metadata
|
|
135
135
|
- readonly, locked-down, and workspace-write sandbox hints
|
|
136
136
|
- evidence-required verifier, synthesis, summary, and verdict tasks
|
|
@@ -138,7 +138,7 @@ The apps intentionally stress different parts of the Workflow App framework:
|
|
|
138
138
|
- compatibility between canonical app ids and legacy workflow-file wrappers
|
|
139
139
|
|
|
140
140
|
The legacy `workflows/architecture-review.workflow.js` and
|
|
141
|
-
`workflows/research-synthesis.workflow.js` files
|
|
141
|
+
`workflows/research-synthesis.workflow.js` files can still be loaded with named
|
|
142
142
|
compatibility ids:
|
|
143
143
|
|
|
144
144
|
```text
|
|
@@ -146,25 +146,25 @@ legacy-architecture-review
|
|
|
146
146
|
legacy-research-synthesis
|
|
147
147
|
```
|
|
148
148
|
|
|
149
|
-
The public `architecture-review` and `research-synthesis` ids are now
|
|
149
|
+
The public `architecture-review` and `research-synthesis` ids are now held by
|
|
150
150
|
the canonical app directories.
|
|
151
151
|
|
|
152
152
|
## Relationship To The Golden Path
|
|
153
153
|
|
|
154
|
-
`npm run canonical-apps`
|
|
155
|
-
plans
|
|
154
|
+
`npm run canonical-apps` shows that the official userland app matrix validates and
|
|
155
|
+
plans the right way. It does not run every worker for every app.
|
|
156
156
|
|
|
157
|
-
`npm run golden-path`
|
|
157
|
+
`npm run golden-path` is still the full integration proof:
|
|
158
158
|
|
|
159
159
|
```text
|
|
160
160
|
workflow app -> plan -> dispatch -> isolated worker -> candidate scoring
|
|
161
161
|
-> verifier -> gated commit -> report
|
|
162
162
|
```
|
|
163
163
|
|
|
164
|
-
Together they keep the kernel small while making the
|
|
165
|
-
|
|
164
|
+
Together they keep the kernel small while making the kept-up userland dull,
|
|
165
|
+
easy to inspect, and useful.
|
|
166
166
|
|
|
167
|
-
Use the Operator UX commands to
|
|
167
|
+
Use the Operator UX commands to look at any canonical app run:
|
|
168
168
|
|
|
169
169
|
```bash
|
|
170
170
|
node scripts/cw.js status <run-id>
|
|
@@ -6,12 +6,12 @@
|
|
|
6
6
|
|
|
7
7
|
## Description
|
|
8
8
|
|
|
9
|
-
v0.1.53
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
9
|
+
v0.1.53 adds two open registries. They let agents grow CW at runtime
|
|
10
|
+
with no need to wire things by hand in many files. New capabilities put
|
|
11
|
+
themselves in the registry and then work by themselves across CLI, MCP, and Workbench. New topologies put
|
|
12
|
+
themselves in the registry too and then come up by themselves in `topology list`, `topology validate`, and `topology apply`.
|
|
13
13
|
|
|
14
|
-
BSD
|
|
14
|
+
BSD way: keep **mechanism** (Map / pipe) apart from **policy** (entries).
|
|
15
15
|
Fail-closed on unknown ids.
|
|
16
16
|
|
|
17
17
|
## Capability Registry
|
|
@@ -53,18 +53,18 @@ registerCapabilityHandler({
|
|
|
53
53
|
|
|
54
54
|
### How it works
|
|
55
55
|
|
|
56
|
-
1. `registerCapabilityHandler()`
|
|
57
|
-
2. CLI: `resolveCliPath(["my", "new-tool"])`
|
|
58
|
-
3. MCP: `resolveMcpTool("cw_my_new_tool")`
|
|
59
|
-
4. `dispatchCapability(id, args, ctx)`
|
|
60
|
-
5. Both the CLI and MCP surfaces
|
|
61
|
-
their hardcoded switch statements
|
|
56
|
+
1. `registerCapabilityHandler()` keeps the handler in a `Map<string, CapabilityHandler>`
|
|
57
|
+
2. CLI: `resolveCliPath(["my", "new-tool"])` turns the CLI path into the capability id
|
|
58
|
+
3. MCP: `resolveMcpTool("cw_my_new_tool")` turns the tool name into the capability id
|
|
59
|
+
4. `dispatchCapability(id, args, ctx)` calls `handler.run(args, ctx)`
|
|
60
|
+
5. Both the CLI and MCP surfaces drop through to the dynamic dispatcher when
|
|
61
|
+
their hardcoded switch statements do not match an unknown command/tool
|
|
62
62
|
|
|
63
63
|
### Existing capabilities
|
|
64
64
|
|
|
65
|
-
All
|
|
65
|
+
All 182 capabilities that are there now keep working through their hardcoded switch
|
|
66
66
|
cases in `cli.ts` and `mcp-server.ts`. The dynamic dispatch is a **fallback**
|
|
67
|
-
— it only
|
|
67
|
+
— it turns on only for commands/tools not found in the old switches.
|
|
68
68
|
|
|
69
69
|
## Topology Registry
|
|
70
70
|
|
|
@@ -143,24 +143,24 @@ registerTopology({
|
|
|
143
143
|
### How it works
|
|
144
144
|
|
|
145
145
|
1. `registerTopology()` stores the definition in a `Map<string, MultiAgentTopologyDefinition>`
|
|
146
|
-
2. `listTopologyDefinitions()`
|
|
147
|
-
3. `getTopologyDefinition(id)`
|
|
148
|
-
4. `materializedRoles()` uses `role.count`
|
|
146
|
+
2. `listTopologyDefinitions()` gives back official + registered; registered wins when two ids are the same
|
|
147
|
+
3. `getTopologyDefinition(id)` looks at registered first, then official
|
|
148
|
+
4. `materializedRoles()` uses `role.count` to make copies — no more hardcoded
|
|
149
149
|
mapper/judge switch logic
|
|
150
|
-
5. `applyTopology()` works
|
|
150
|
+
5. `applyTopology()` works the same way for official and registered topologies
|
|
151
151
|
|
|
152
152
|
### Data-driven role expansion
|
|
153
153
|
|
|
154
|
-
Before v0.1.53, `materializedRoles()` hardcoded "mapper" and "judge" role
|
|
155
|
-
expansion. Now it
|
|
156
|
-
- `role.count > 1`:
|
|
157
|
-
- `role.count` undefined or 1:
|
|
158
|
-
-
|
|
159
|
-
input overrides still
|
|
154
|
+
Before v0.1.53, `materializedRoles()` hardcoded the "mapper" and "judge" role
|
|
155
|
+
expansion. Now it reads `role.count` on each role spec:
|
|
156
|
+
- `role.count > 1`: makes `role-1`, `role-2`, ... `role-N`
|
|
157
|
+
- `role.count` undefined or 1: makes one role instance
|
|
158
|
+
- So that official topologies keep working as before, the `mapperCount` and `judgeCount`
|
|
159
|
+
input overrides still hold
|
|
160
160
|
|
|
161
161
|
## See Also
|
|
162
162
|
|
|
163
|
-
- `capability-registry.ts` — the
|
|
163
|
+
- `capability-registry.ts` — the one true source for all capabilities
|
|
164
164
|
- `capability-dispatcher.ts` — the thin Map-based dispatch pipe
|
|
165
165
|
- `topology.ts` — topology definitions and the registry
|
|
166
166
|
- `types/topology.ts` — topology type definitions
|