cool-workflow 0.1.79 → 0.1.81
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 +1 -1
- package/.codex-plugin/plugin.json +1 -1
- package/README.md +51 -3
- package/apps/architecture-review/app.json +1 -1
- package/apps/architecture-review-fast/app.json +64 -0
- package/apps/architecture-review-fast/workflow.js +153 -0
- 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/agent-config.js +21 -7
- package/dist/candidate-scoring.js +42 -22
- package/dist/capability-core.js +132 -17
- package/dist/capability-registry.js +138 -168
- package/dist/cli.js +97 -98
- package/dist/collaboration.js +5 -6
- package/dist/commit.js +20 -6
- package/dist/compare.js +18 -0
- package/dist/coordinator/classify.js +45 -0
- package/dist/coordinator/paths.js +42 -0
- package/dist/coordinator/util.js +129 -0
- package/dist/coordinator.js +127 -300
- package/dist/dispatch.js +35 -0
- package/dist/drive.js +79 -6
- package/dist/error-feedback.js +8 -4
- package/dist/evidence-reasoning.js +3 -3
- package/dist/execution-backend/agent.js +331 -0
- package/dist/execution-backend/probes.js +96 -0
- package/dist/execution-backend/util.js +47 -0
- package/dist/execution-backend.js +73 -421
- package/dist/mcp-server.js +79 -183
- package/dist/multi-agent/graph.js +84 -0
- package/dist/multi-agent/helpers.js +145 -0
- package/dist/multi-agent/paths.js +22 -0
- package/dist/multi-agent-eval/format.js +194 -0
- package/dist/multi-agent-eval/normalize.js +51 -0
- package/dist/multi-agent-eval.js +39 -244
- package/dist/multi-agent-host.js +0 -19
- package/dist/multi-agent.js +125 -314
- package/dist/node-snapshot.js +3 -3
- package/dist/observability/format.js +61 -0
- package/dist/observability/intake.js +98 -0
- package/dist/observability.js +14 -160
- package/dist/operator-ux/format.js +364 -0
- package/dist/operator-ux.js +22 -363
- package/dist/orchestrator/lifecycle-operations.js +2 -1
- package/dist/orchestrator/report.js +8 -0
- package/dist/orchestrator.js +26 -9
- package/dist/reclamation.js +26 -21
- package/dist/run-export.js +494 -25
- package/dist/run-registry/derive.js +172 -0
- package/dist/run-registry/format.js +124 -0
- package/dist/run-registry/gc.js +251 -0
- package/dist/run-registry/policy.js +16 -0
- package/dist/run-registry/queue.js +116 -0
- package/dist/run-registry.js +89 -597
- package/dist/run-state-schema.js +1 -0
- package/dist/sandbox-profile.js +43 -2
- package/dist/state-explosion/format.js +159 -0
- package/dist/state-explosion/helpers.js +82 -0
- package/dist/state-explosion.js +165 -304
- package/dist/state-node.js +19 -4
- package/dist/telemetry-attestation.js +55 -0
- package/dist/telemetry-demo.js +15 -3
- package/dist/telemetry-ledger.js +60 -15
- package/dist/topology.js +25 -8
- package/dist/triggers.js +33 -14
- package/dist/trust-audit.js +145 -33
- package/dist/version.js +1 -1
- package/dist/worker-isolation/helpers.js +51 -0
- package/dist/worker-isolation/paths.js +46 -0
- package/dist/worker-isolation.js +39 -115
- package/docs/agent-delegation-drive.7.md +71 -0
- package/docs/canonical-workflow-apps.7.md +37 -0
- package/docs/cli-mcp-parity.7.md +16 -0
- package/docs/contract-migration-tooling.7.md +6 -0
- package/docs/control-plane-scheduling.7.md +6 -0
- package/docs/dogfood/resume-drive-real-agent-2026-06-14.md +40 -0
- package/docs/durable-state-and-locking.7.md +8 -0
- package/docs/evidence-adoption-reasoning-chain.7.md +6 -0
- package/docs/execution-backends.7.md +6 -0
- package/docs/index.md +2 -0
- package/docs/launch/demo.tape +28 -0
- package/docs/launch/launch-kit.md +96 -17
- package/docs/launch/pre-launch-checklist.md +53 -0
- package/docs/multi-agent-cli-mcp-surface.7.md +8 -0
- package/docs/multi-agent-eval-replay-harness.7.md +6 -0
- package/docs/multi-agent-operator-ux.7.md +6 -0
- package/docs/multi-agent-trust-policy-audit.7.md +27 -0
- package/docs/node-snapshot-diff-replay.7.md +6 -0
- package/docs/observability-cost-accounting.7.md +6 -0
- package/docs/project-index.md +27 -6
- package/docs/real-execution-backends.7.md +6 -0
- package/docs/release-and-migration.7.md +8 -0
- package/docs/release-tooling.7.md +6 -0
- package/docs/routines.md +23 -0
- package/docs/run-registry-control-plane.7.md +89 -2
- package/docs/run-retention-reclamation.7.md +8 -0
- package/docs/source-context-profiles.7.md +119 -0
- package/docs/state-explosion-management.7.md +13 -0
- package/docs/team-collaboration.7.md +6 -0
- package/docs/trust-model.md +267 -0
- package/docs/unix-principles.md +49 -1
- package/docs/vendor-manifest-loadability.7.md +43 -0
- package/docs/web-desktop-workbench.7.md +6 -0
- package/manifest/plugin.manifest.json +1 -1
- package/manifest/source-context-profiles.json +142 -0
- package/package.json +4 -1
- package/scripts/agents/builtin-templates.json +7 -0
- package/scripts/agents/claude-p-agent.js +129 -43
- package/scripts/architecture-review-fast.js +362 -0
- package/scripts/bump-version.js +5 -10
- package/scripts/canonical-apps-list.js +64 -0
- package/scripts/canonical-apps.js +36 -4
- package/scripts/coverage-gate.js +211 -0
- package/scripts/dogfood-release.js +1 -1
- package/scripts/golden-path.js +4 -4
- package/scripts/parity-check.js +5 -0
- package/scripts/release-check.js +5 -1
- package/scripts/source-context.js +291 -0
- package/scripts/version-sync-check.js +5 -7
- package/skills/ci-triage/SKILL.md +50 -0
- package/skills/ci-triage/agents/openai.yaml +4 -0
- package/skills/cool-workflow/SKILL.md +4 -1
- package/skills/deploy-check/SKILL.md +55 -0
- package/skills/deploy-check/agents/openai.yaml +4 -0
- package/skills/design-qa/SKILL.md +49 -0
- package/skills/design-qa/agents/openai.yaml +4 -0
- package/skills/pr-review/SKILL.md +45 -0
- package/skills/pr-review/agents/openai.yaml +4 -0
- package/dist/capability-dispatcher.js +0 -86
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: deploy-check
|
|
3
|
+
description: >-
|
|
4
|
+
Verify Cool Workflow release, publish, deploy, or package readiness. Use when
|
|
5
|
+
Codex must check build/test gates, generated manifests, project index sync,
|
|
6
|
+
dist/source contract, changelog/release notes, npm package contents, or
|
|
7
|
+
pre-tag risk before shipping.
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# Deploy Check
|
|
11
|
+
|
|
12
|
+
## Overview
|
|
13
|
+
|
|
14
|
+
Deploy check is the verifier side of release work. It confirms the artifact a
|
|
15
|
+
user receives matches the source, docs, manifests, and stated capability.
|
|
16
|
+
|
|
17
|
+
## Workflow
|
|
18
|
+
|
|
19
|
+
1. Confirm the intended capability and release scope.
|
|
20
|
+
2. Inspect branch status and generated artifact drift.
|
|
21
|
+
3. Run the deterministic gates.
|
|
22
|
+
4. Check docs/man-page coverage for shipped behavior.
|
|
23
|
+
5. Check package contents and `dist/` policy.
|
|
24
|
+
6. Report risk before any tag or publish step.
|
|
25
|
+
|
|
26
|
+
## Commands
|
|
27
|
+
|
|
28
|
+
```bash
|
|
29
|
+
npm run build
|
|
30
|
+
npm test
|
|
31
|
+
npm run gen:manifests -- --check
|
|
32
|
+
npm run index:check
|
|
33
|
+
npm run version:sync
|
|
34
|
+
npm run release:check
|
|
35
|
+
git diff --check
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
For package inspection:
|
|
39
|
+
|
|
40
|
+
```bash
|
|
41
|
+
npm pack --dry-run
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
## Red Lines
|
|
45
|
+
|
|
46
|
+
- Do not tag without test evidence.
|
|
47
|
+
- Do not write reviewer verdict files by hand.
|
|
48
|
+
- Do not silently skip `dist/` drift if the package still ships `dist/`.
|
|
49
|
+
- Do not publish undocumented behavior.
|
|
50
|
+
- Do not call a release ready if generated manifests or project index drift.
|
|
51
|
+
|
|
52
|
+
## Output Rules
|
|
53
|
+
|
|
54
|
+
Return a ship/no-ship verdict, gate results, artifact risks, and the next
|
|
55
|
+
operator action.
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: design-qa
|
|
3
|
+
description: >-
|
|
4
|
+
Evaluate Cool Workflow architecture, product design, operator UX,
|
|
5
|
+
context-pack, workflow-app, MCP/CLI, or release-process proposals. Use when
|
|
6
|
+
Codex must decide whether a design respects FreeBSD/POLA,
|
|
7
|
+
mechanism-not-policy, stable JSON surfaces, evidence, and verifier boundaries
|
|
8
|
+
before implementation.
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
# Design QA
|
|
12
|
+
|
|
13
|
+
## Overview
|
|
14
|
+
|
|
15
|
+
Design QA checks whether a proposed capability belongs in the kernel,
|
|
16
|
+
userland, a manifest, a wrapper, a routine, or an eval before implementation.
|
|
17
|
+
|
|
18
|
+
## Workflow
|
|
19
|
+
|
|
20
|
+
1. State the user capability in one sentence.
|
|
21
|
+
2. Identify the contract surface: CLI, MCP, `.cw/` state, file layout, docs,
|
|
22
|
+
package contents, or external wrapper.
|
|
23
|
+
3. Separate mechanism from policy. Move policy into data, apps, wrappers, env,
|
|
24
|
+
or docs.
|
|
25
|
+
4. Check POLA: existing outputs, flags, exit codes, and file layouts stay
|
|
26
|
+
byte-identical unless a new opt-in surface is used.
|
|
27
|
+
5. Define verifier evidence: tests, manifests, screenshots for UI, replay, or
|
|
28
|
+
logs.
|
|
29
|
+
6. Decide whether the work needs a new eval case or skill update.
|
|
30
|
+
|
|
31
|
+
## Checks
|
|
32
|
+
|
|
33
|
+
- Does it preserve stdout-as-data?
|
|
34
|
+
- Does it fail closed instead of guessing?
|
|
35
|
+
- Does it avoid vendor-specific parsing in `src/`?
|
|
36
|
+
- Does it keep generated files verifiable?
|
|
37
|
+
- Does it have a man page or docs contract?
|
|
38
|
+
- Can maker and verifier run in separate worktrees?
|
|
39
|
+
|
|
40
|
+
## Output Rules
|
|
41
|
+
|
|
42
|
+
Return:
|
|
43
|
+
|
|
44
|
+
1. Verdict: acceptable, revise, or reject.
|
|
45
|
+
2. Required contract shape.
|
|
46
|
+
3. Verification plan.
|
|
47
|
+
4. Risks and non-goals.
|
|
48
|
+
|
|
49
|
+
Do not turn design QA into implementation unless the user asks to proceed.
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: pr-review
|
|
3
|
+
description: >-
|
|
4
|
+
Review Cool Workflow pull requests or branch diffs. Use when Codex must
|
|
5
|
+
inspect code changes for bugs, regressions, FreeBSD/POLA violations, missing
|
|
6
|
+
tests, generated artifact drift, release-contract risk, or CI implications,
|
|
7
|
+
and return findings first with file/line citations.
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# PR Review
|
|
11
|
+
|
|
12
|
+
## Overview
|
|
13
|
+
|
|
14
|
+
Review for correctness and release risk before style. Findings lead; summaries
|
|
15
|
+
are secondary. Treat missing tests and POLA drift as real risks.
|
|
16
|
+
|
|
17
|
+
## Workflow
|
|
18
|
+
|
|
19
|
+
1. Read the diff and identify touched contracts: CLI, MCP, `.cw/` state, docs,
|
|
20
|
+
dist, manifests, tests, release flow, or public package files.
|
|
21
|
+
2. Inspect the surrounding code for behavioral expectations.
|
|
22
|
+
3. Check whether tests exercise the changed behavior and fail closed.
|
|
23
|
+
4. Look for stdout chatter, silent fallback, hidden policy in core, untracked
|
|
24
|
+
generated drift, and accidental public-output changes.
|
|
25
|
+
5. Report findings first, ordered by severity, with file and line references.
|
|
26
|
+
6. Include open questions only when they block confidence.
|
|
27
|
+
|
|
28
|
+
## Review Rules
|
|
29
|
+
|
|
30
|
+
- Do not request cosmetic rewrites unless they hide a bug.
|
|
31
|
+
- Do not approve undocumented shipped behavior.
|
|
32
|
+
- Do not accept type-only additions without runtime behavior.
|
|
33
|
+
- Do not accept `dist/` edits without matching `src/` changes.
|
|
34
|
+
- For UI work, require screenshots or browser verification.
|
|
35
|
+
|
|
36
|
+
## Output Shape
|
|
37
|
+
|
|
38
|
+
Use this order:
|
|
39
|
+
|
|
40
|
+
1. Findings
|
|
41
|
+
2. Open questions
|
|
42
|
+
3. Test gaps
|
|
43
|
+
4. Short summary
|
|
44
|
+
|
|
45
|
+
If there are no findings, say so clearly and name residual risk.
|
|
@@ -1,86 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
// Capability Dispatcher — the thin MECHANISM pipe that routes a capability id
|
|
3
|
-
// to its registered handler function. It knows nothing about which capabilities
|
|
4
|
-
// exist (that's POLICY, declared elsewhere via registerCapabilityHandler).
|
|
5
|
-
//
|
|
6
|
-
// BSD discipline:
|
|
7
|
-
// - ONE THING: map (capability id, args, ctx) -> handler output.
|
|
8
|
-
// - SEPARATE MECHANISM FROM POLICY. The Map is mechanism; which entries are
|
|
9
|
-
// registered is policy (callers registerCapabilityHandler at import time).
|
|
10
|
-
// - FAIL CLOSED. Unknown capability id -> CapabilityError with a named refusal.
|
|
11
|
-
// - COMPOSABLE. The dispatcher is a pure router; CLI and MCP surfaces compose
|
|
12
|
-
// their own formatting/protocol wrapping around it. No surface knows how to
|
|
13
|
-
// format — the handler returns raw data, the surface renders it.
|
|
14
|
-
// - NO HIDDEN STATE. The registry is a plain Map; no lazy loading, no magic.
|
|
15
|
-
//
|
|
16
|
-
// From v0.1.53: this replaces the "manual switch in cli.ts + mcp-server.ts"
|
|
17
|
-
// anti-pattern for NEW capabilities. Existing hardcoded capabilities remain in
|
|
18
|
-
// the switch until they are progressively migrated; the fallback path in both
|
|
19
|
-
// surfaces first checks the switch, then falls through to this dispatcher.
|
|
20
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
21
|
-
exports.registerCapabilityHandler = registerCapabilityHandler;
|
|
22
|
-
exports.getCapabilityHandler = getCapabilityHandler;
|
|
23
|
-
exports.dispatchCapability = dispatchCapability;
|
|
24
|
-
exports.resolveCliPath = resolveCliPath;
|
|
25
|
-
exports.resolveMcpTool = resolveMcpTool;
|
|
26
|
-
exports.listCapabilityIds = listCapabilityIds;
|
|
27
|
-
class CapabilityError extends Error {
|
|
28
|
-
code;
|
|
29
|
-
capabilityId;
|
|
30
|
-
constructor(capabilityId, reason, code) {
|
|
31
|
-
super(`Capability "${capabilityId}": ${reason}`);
|
|
32
|
-
this.name = "CapabilityError";
|
|
33
|
-
this.code = code;
|
|
34
|
-
this.capabilityId = capabilityId;
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
const _handlerRegistry = new Map();
|
|
38
|
-
/** Register a capability handler. Later registrations with the same capability
|
|
39
|
-
* id overwrite earlier ones (last-write-wins dedup). */
|
|
40
|
-
function registerCapabilityHandler(handler) {
|
|
41
|
-
_handlerRegistry.set(handler.descriptor.capability, handler);
|
|
42
|
-
}
|
|
43
|
-
/** Look up a handler by capability id. Returns undefined when not found. */
|
|
44
|
-
function getCapabilityHandler(capabilityId) {
|
|
45
|
-
return _handlerRegistry.get(capabilityId);
|
|
46
|
-
}
|
|
47
|
-
/** Dispatch a capability by id. Resolves the handler, invokes `run()`.
|
|
48
|
-
* Fail-closed: throws CapabilityError when no handler is registered. */
|
|
49
|
-
function dispatchCapability(capabilityId, args, ctx) {
|
|
50
|
-
const handler = _handlerRegistry.get(capabilityId);
|
|
51
|
-
if (!handler)
|
|
52
|
-
throw new CapabilityError(capabilityId, "no handler registered", "not-found");
|
|
53
|
-
return handler.run(args, ctx);
|
|
54
|
-
}
|
|
55
|
-
/** Resolve a CLI path (e.g. ["gc", "plan"]) to a capability id by matching
|
|
56
|
-
* registered handlers' `cli.path` bindings. Returns undefined when no match. */
|
|
57
|
-
function resolveCliPath(cliPath) {
|
|
58
|
-
if (!cliPath.length)
|
|
59
|
-
return undefined;
|
|
60
|
-
for (const handler of _handlerRegistry.values()) {
|
|
61
|
-
if (!handler.descriptor.cli)
|
|
62
|
-
continue;
|
|
63
|
-
const expected = handler.descriptor.cli.caseTokens || handler.descriptor.cli.path;
|
|
64
|
-
if (pathsMatch(expected, cliPath))
|
|
65
|
-
return handler.descriptor.capability;
|
|
66
|
-
}
|
|
67
|
-
return undefined;
|
|
68
|
-
}
|
|
69
|
-
/** Resolve an MCP tool name to a capability id by matching registered handlers'
|
|
70
|
-
* `mcp.tool` bindings. Returns undefined when no match. */
|
|
71
|
-
function resolveMcpTool(toolName) {
|
|
72
|
-
for (const handler of _handlerRegistry.values()) {
|
|
73
|
-
if (handler.descriptor.mcp?.tool === toolName)
|
|
74
|
-
return handler.descriptor.capability;
|
|
75
|
-
}
|
|
76
|
-
return undefined;
|
|
77
|
-
}
|
|
78
|
-
/** List all registered capability ids. */
|
|
79
|
-
function listCapabilityIds() {
|
|
80
|
-
return [..._handlerRegistry.keys()].sort();
|
|
81
|
-
}
|
|
82
|
-
function pathsMatch(expected, actual) {
|
|
83
|
-
if (expected.length !== actual.length)
|
|
84
|
-
return false;
|
|
85
|
-
return expected.every((token, i) => actual[i] === token);
|
|
86
|
-
}
|