harness-everything 0.8.0 → 0.8.1
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/marketplace.json +1 -1
- package/.claude-plugin/plugin.json +1 -1
- package/.github/workflows/ci.yml +12 -2
- package/AGENTS.md +36 -35
- package/CHANGELOG.md +17 -0
- package/README.md +2 -2
- package/benchmarks/results/reviews/pr142-verification.json +95 -0
- package/ci/action-gate.test.js +1 -1
- package/ci/doc-capability-consistency.test.js +3 -0
- package/ci/invariant-routing.test.js +87 -74
- package/ci/mechanism-2af-worktree-isolation.test.js +152 -0
- package/ci/mechanism-2ag-router-worktree-contract.test.js +44 -0
- package/ci/mechanism-2ah-workflow-lifecycle.test.js +140 -0
- package/ci/openai-plugin-package.test.js +9 -6
- package/ci/workflow-execution-contract.test.js +60 -0
- package/docs/architecture.md +111 -114
- package/docs/mechanism-first-skill-mesh.md +92 -103
- package/docs/openai-plugin.md +1 -1
- package/docs/philosophy.md +40 -33
- package/docs/platform-capabilities.md +2 -2
- package/docs/reviews/pr-142-issue-131.md +89 -0
- package/docs/routing.md +61 -124
- package/docs/workflow-runtime.md +109 -0
- package/fable-mode/CONTRACT-FORMAT.md +3 -1
- package/fable-mode/SKILL.md +1 -1
- package/fable-mode/execution-guardrails/SKILL.md +1 -1
- package/fable-mode/fable-haiku/SKILL.md +1 -1
- package/fable-mode/fable-opus/SKILL.md +1 -1
- package/fable-mode/fable-sonnet/SKILL.md +1 -1
- package/fable-mode/scripts/workflow-plan-consumer.js +3 -1
- package/harness-everything/SKILL.md +11 -10
- package/harness-everything/references/triage-and-tiers.md +76 -107
- package/harness-everything/scripts/kernel-router-core.js +263 -0
- package/harness-everything/scripts/kernel-router.js +97 -225
- package/harness-everything/scripts/router-contract-core.js +612 -0
- package/harness-everything/scripts/router-contract.js +21 -581
- package/hooks/hooks.json +22 -1
- package/hooks/scripts/contract-test.js +24 -2
- package/hooks/scripts/lib/workflow-isolation.js +102 -0
- package/hooks/scripts/lib/workflow-runtime.js +102 -0
- package/hooks/scripts/state-persist.js +1 -0
- package/hooks/scripts/workflow-disposition.js +97 -0
- package/hooks/scripts/workflow-gate.js +53 -0
- package/hooks/scripts/workflow-stop-gate.js +44 -0
- package/opencode-plugin/plugin.json +1 -1
- package/package.json +2 -2
- package/plugins/harness-everything/.codex-plugin/plugin.json +1 -1
- package/plugins/harness-everything/hooks/hooks.json +20 -1
- package/plugins/harness-everything/hooks/scripts/contract-test.js +24 -2
- package/plugins/harness-everything/hooks/scripts/lib/workflow-isolation.js +102 -0
- package/plugins/harness-everything/hooks/scripts/lib/workflow-runtime.js +102 -0
- package/plugins/harness-everything/hooks/scripts/state-persist.js +1 -0
- package/plugins/harness-everything/hooks/scripts/workflow-disposition.js +97 -0
- package/plugins/harness-everything/hooks/scripts/workflow-gate.js +53 -0
- package/plugins/harness-everything/hooks/scripts/workflow-stop-gate.js +44 -0
- package/plugins/harness-everything/plugin.json +1 -1
- package/plugins/harness-everything/scripts/lib/advisory-text.js +51 -54
- package/plugins/harness-everything/skills/fable-mode/CONTRACT-FORMAT.md +3 -1
- package/plugins/harness-everything/skills/fable-mode/SKILL.md +1 -1
- package/plugins/harness-everything/skills/fable-mode/execution-guardrails/SKILL.md +1 -1
- package/plugins/harness-everything/skills/fable-mode/fable-haiku/SKILL.md +1 -1
- package/plugins/harness-everything/skills/fable-mode/fable-opus/SKILL.md +1 -1
- package/plugins/harness-everything/skills/fable-mode/fable-sonnet/SKILL.md +1 -1
- package/plugins/harness-everything/skills/fable-mode/scripts/workflow-plan-consumer.js +3 -1
- package/plugins/harness-everything/skills/harness-everything/SKILL.md +11 -10
- package/plugins/harness-everything/skills/harness-everything/references/triage-and-tiers.md +76 -107
- package/plugins/harness-everything/skills/harness-everything/scripts/kernel-router-core.js +263 -0
- package/plugins/harness-everything/skills/harness-everything/scripts/kernel-router.js +97 -225
- package/plugins/harness-everything/skills/harness-everything/scripts/router-contract-core.js +612 -0
- package/plugins/harness-everything/skills/harness-everything/scripts/router-contract.js +21 -581
- package/plugins/harness-everything/skills/using-git-worktrees/SKILL.md +14 -16
- package/plugins/harness-everything/skills/using-git-worktrees/references/workflow-details.md +44 -85
- package/scripts/lib/advisory-text.js +51 -54
- package/using-git-worktrees/SKILL.md +14 -16
- package/using-git-worktrees/references/workflow-details.md +44 -85
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
"name": "harness-everything",
|
|
11
11
|
"source": "./",
|
|
12
12
|
"description": "Harness OS: an orchestrated agent operating system — tier routing, circuit breaker guardrails, verification gates, WAL session memory, and self-evolving workspace rules.",
|
|
13
|
-
"version": "0.8.
|
|
13
|
+
"version": "0.8.1",
|
|
14
14
|
"author": {
|
|
15
15
|
"name": "Miya Daniel"
|
|
16
16
|
},
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "harness-everything",
|
|
3
3
|
"description": "Harness OS: an orchestrated agent operating system — tier routing, circuit breaker guardrails, verification gates, WAL session memory, and self-evolving workspace rules.",
|
|
4
|
-
"version": "0.8.
|
|
4
|
+
"version": "0.8.1",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Miya Daniel"
|
|
7
7
|
},
|
package/.github/workflows/ci.yml
CHANGED
|
@@ -70,8 +70,18 @@ jobs:
|
|
|
70
70
|
- uses: actions/checkout@v7
|
|
71
71
|
with:
|
|
72
72
|
fetch-depth: 0
|
|
73
|
-
- name: Install waza CLI
|
|
74
|
-
run:
|
|
73
|
+
- name: Install pinned waza CLI
|
|
74
|
+
run: |
|
|
75
|
+
WAZA_VERSION=0.38.6
|
|
76
|
+
WAZA_SHA256=a799587795fd462411ca7c7af5faccee7e24f08e41d152c10738d31334d1c063
|
|
77
|
+
mkdir -p "$HOME/bin"
|
|
78
|
+
curl -fL --retry 3 --retry-all-errors \
|
|
79
|
+
-o "$HOME/bin/waza" \
|
|
80
|
+
"https://github.com/microsoft/waza/releases/download/v${WAZA_VERSION}/waza-linux-amd64"
|
|
81
|
+
echo "${WAZA_SHA256} $HOME/bin/waza" | sha256sum -c -
|
|
82
|
+
chmod +x "$HOME/bin/waza"
|
|
83
|
+
echo "$HOME/bin" >> "$GITHUB_PATH"
|
|
84
|
+
"$HOME/bin/waza" --version
|
|
75
85
|
- name: Check every canonical SKILL.md passes waza readiness gates
|
|
76
86
|
run: |
|
|
77
87
|
fail=0
|
package/AGENTS.md
CHANGED
|
@@ -4,20 +4,20 @@ description: Operating guide for AI agents working inside the Harness-everything
|
|
|
4
4
|
|
|
5
5
|
# AGENTS.md — Working in This Repository
|
|
6
6
|
|
|
7
|
-
You are modifying **Harness**: an orchestrated agent operating system (skills + hooks/plugins + routing) for AI coding agents. Changes here ship to real agent sessions; a vague `SKILL.md`, stale manifest, contradictory platform claim, or
|
|
7
|
+
You are modifying **Harness**: an orchestrated agent operating system (skills + hooks/plugins + routing) for AI coding agents. Changes here ship to real agent sessions; a vague `SKILL.md`, stale manifest, contradictory platform claim, or selected workflow that remains bypassable can misroute other people's agents. Precision is the product.
|
|
8
8
|
|
|
9
9
|
## Repository Layout
|
|
10
10
|
|
|
11
11
|
| Path | What it is |
|
|
12
12
|
|---|---|
|
|
13
13
|
| `<skill-name>/SKILL.md` | One canonical skill per top-level directory. Frontmatter: `name`, `description`, `metadata.author`, `metadata.version`. |
|
|
14
|
-
| `hooks/` | Claude Code lifecycle hook scripts and shared mechanisms such as circuit breaker, scope
|
|
15
|
-
| `harness-everything/scripts/` | Runtime: kernel/tier routing, verification, bootstrap, self-heal. |
|
|
14
|
+
| `hooks/` | Claude Code lifecycle hook scripts and shared mechanisms such as circuit breaker, workflow/action/scope guards, and stop gates. Do not infer that every host packages every hook. |
|
|
15
|
+
| `harness-everything/scripts/` | Runtime: kernel/tier routing, workflow contract, verification, bootstrap, self-heal. |
|
|
16
16
|
| `opencode-plugin/` | OpenCode native plugin implementation. Mechanism-tested, with partial live-host evidence for project-scope `.js` loading and edit/verification state on OpenCode 1.18.31 (macOS); see the evidence boundary below. |
|
|
17
17
|
| `.agents/plugins/` + `plugins/harness-everything/` | Local OpenAI/Codex marketplace + `.codex-plugin` package with canonical skill copies and packaged session/prompt hooks. |
|
|
18
18
|
| `submission/openai/` | Public OpenAI Skills-only listing/test inputs. The public artifact does not include local `.codex-plugin` lifecycle hooks. |
|
|
19
19
|
| `evals/<skill>/` | Trigger/routing eval per skill (waza format). Required for every canonical routed skill. |
|
|
20
|
-
| `behavioral-evals/` | LLM-behavior cases run via headless CLI sessions
|
|
20
|
+
| `behavioral-evals/` | LLM-behavior cases run via headless CLI sessions and structurally validated by CI. |
|
|
21
21
|
| `benchmarks/` | BENCHMARK_SOP fixtures and recorded results. Evidence lives here or nowhere. |
|
|
22
22
|
| `.claude-plugin/` | Claude Code plugin distribution manifests. Must list exactly the on-disk canonical skills. |
|
|
23
23
|
| `docs/platform-capabilities.md` | Canonical current platform/install/enforcement/evidence matrix. |
|
|
@@ -27,43 +27,44 @@ You are modifying **Harness**: an orchestrated agent operating system (skills +
|
|
|
27
27
|
|
|
28
28
|
## OpenCode evidence boundary
|
|
29
29
|
|
|
30
|
-
The retained [OpenCode evidence](benchmarks/results/live-host/opencode-2026-09-16/README.md) supports
|
|
30
|
+
The retained [OpenCode evidence](benchmarks/results/live-host/opencode-2026-09-16/README.md) supports project-scope `.js` loading and edit/verification state on OpenCode 1.18.31 (macOS). The final snapshot is post-reset (`hardLock: false`, `count: 1`). Hard lock is only an interactive observation with no retained blocked-tool trace; reflection was operator-seeded, then agent-rewritten. Agent-controlled state deletion resets the breaker. Global scope, npm-package installation, and other OpenCode versions remain unverified.
|
|
31
31
|
|
|
32
32
|
## Non-Negotiable Change Rules
|
|
33
33
|
|
|
34
|
-
1. **Every canonical SKILL.md keeps ≤ 500 tokens** (hard CI gate) and must contain `## USE FOR:` and `## DO NOT USE FOR
|
|
35
|
-
2. **Descriptions are routing surfaces.**
|
|
36
|
-
3. **A new canonical skill ships with a routing eval
|
|
37
|
-
4. **Release version policy:** normal PRs do not manually bump package/plugin versions. `semantic-release`
|
|
38
|
-
5. **Distribution manifests are generated facts
|
|
39
|
-
6. **Platform capability claims are tested contracts.**
|
|
40
|
-
7. **Runtime/workflow claims are generated facts.** `package.json`, `.nvmrc`,
|
|
41
|
-
8. **CHANGELOG.md keeps pending human-authored notes under `[Unreleased]`.**
|
|
42
|
-
9. **Conventional Commit type is release input.**
|
|
43
|
-
10. **
|
|
34
|
+
1. **Every canonical SKILL.md keeps ≤ 500 tokens** (hard CI gate) and must contain `## USE FOR:` and `## DO NOT USE FOR:`. Deep detail goes in references/guides.
|
|
35
|
+
2. **Descriptions are routing surfaces.** Differentiate neighboring skills deliberately; `test:collision` guards overlap.
|
|
36
|
+
3. **A new canonical skill ships with a routing eval.** Positive task `description:` must exactly match the skill frontmatter description.
|
|
37
|
+
4. **Release version policy:** normal PRs do not manually bump package/plugin versions. `semantic-release` owns stable SemVer and `scripts/sync-release-version.js` owns distribution synchronization. Nested sub-skills inherit their parent skill version.
|
|
38
|
+
5. **Distribution manifests are generated facts:** add/remove/rename changes must sync every copied/listed distribution. Run `npm run plugin:sync`, `npm run test:consistency`, and `npm run test:plugin:openai`.
|
|
39
|
+
6. **Platform capability claims are tested contracts.** Update `docs/platform-capabilities.md` with integration behavior changes. Package/mechanism evidence is not live-host evidence, and public Skills-only behavior does not include local lifecycle hooks.
|
|
40
|
+
7. **Runtime/workflow claims are generated facts.** `package.json`, `.nvmrc`, Dockerfile, and active workflows feed `scripts/repository-contract.js`; run `npm run docs:sync` after relevant changes.
|
|
41
|
+
8. **CHANGELOG.md keeps pending human-authored notes under `[Unreleased]`.** Semantic-release owns stable headings/tags/release notes.
|
|
42
|
+
9. **Conventional Commit type is release input.** Breaking→major; `feat`→minor; `fix`/`perf`/`refactor`/`build`/`revert`→patch; docs/test/ci/style/chore do not release by themselves.
|
|
43
|
+
10. **Selected workflow is mandatory; reasoning inside it stays flexible.** Before omitting a suggested skill, read/evaluate its complete `SKILL.md` flow. Suggested skills may be `not-applicable` with a flow-grounded reason, but a selected topology must be executed to resolution. Do not bypass it because the task feels simple/routine/already clear. Escape is limited to genuinely uncovered workflow scope or host-capability loss and requires explicit scope + evidence. Do not turn this into one universal TODO/TDD/Fable sequence.
|
|
44
|
+
11. **Major mutation requires Git worktree isolation.** Read-only discovery may stay in the bound repository. Tier 3 / Fable source and artifact changes must target a verified linked worktree belonging to that repository; creation failure means `blocked`. Worktree isolation is separate from durable multi-agent workspace state. Scoped escape never waives it. See [workflow-runtime.md](docs/workflow-runtime.md) for the tested boundary and limitations.
|
|
44
45
|
|
|
45
46
|
## Verification Before You Claim Done
|
|
46
47
|
|
|
47
|
-
Run the
|
|
48
|
+
Run the gates that cover the same contract categories as CI:
|
|
48
49
|
|
|
49
50
|
```bash
|
|
50
|
-
npm test
|
|
51
|
-
npm run test:mutations
|
|
52
|
-
npm run test:mechanism
|
|
53
|
-
npm run test:consistency
|
|
54
|
-
npm run test:repo-contract
|
|
55
|
-
npm run test:docs:capabilities
|
|
56
|
-
npm run test:references
|
|
57
|
-
npm run test:release
|
|
58
|
-
npm run test:collision
|
|
59
|
-
npm run test:routing:skills
|
|
60
|
-
npm run test:routing:invariants
|
|
61
|
-
npm run test:plugin:openai
|
|
62
|
-
npm run test:plugin:submission
|
|
51
|
+
npm test
|
|
52
|
+
npm run test:mutations
|
|
53
|
+
npm run test:mechanism
|
|
54
|
+
npm run test:consistency
|
|
55
|
+
npm run test:repo-contract
|
|
56
|
+
npm run test:docs:capabilities
|
|
57
|
+
npm run test:references
|
|
58
|
+
npm run test:release
|
|
59
|
+
npm run test:collision
|
|
60
|
+
npm run test:routing:skills
|
|
61
|
+
npm run test:routing:invariants
|
|
62
|
+
npm run test:plugin:openai
|
|
63
|
+
npm run test:plugin:submission
|
|
63
64
|
npm run test:platform:compatibility
|
|
64
65
|
```
|
|
65
66
|
|
|
66
|
-
If waza is installed (`~/bin/waza`), also run
|
|
67
|
+
If waza is installed (`~/bin/waza`), also run:
|
|
67
68
|
|
|
68
69
|
```bash
|
|
69
70
|
waza check <skill-dir>
|
|
@@ -71,16 +72,16 @@ waza spec verify <skill> evals/<skill>/eval.yaml --fail --threshold 1
|
|
|
71
72
|
waza tokens check
|
|
72
73
|
```
|
|
73
74
|
|
|
74
|
-
Node.js 24 is
|
|
75
|
+
Node.js 24 is primary CI across Ubuntu/Windows/macOS; a Node.js 22 lane protects the supported minimum. See [docs/repository-contract.md](docs/repository-contract.md).
|
|
75
76
|
|
|
76
|
-
Do not report "it works" from reading
|
|
77
|
+
Do not report "it works" from code reading. State the evidence layer proved: package, deterministic mechanism, live host, or behavior.
|
|
77
78
|
|
|
78
79
|
## Behavioral & Benchmark Evidence
|
|
79
80
|
|
|
80
|
-
Deterministic mechanism tests prove the tested hook/plugin contract; they do **not** prove a real host loaded it or that
|
|
81
|
+
Deterministic mechanism tests prove the tested hook/plugin contract; they do **not** prove a real host loaded it or that behavior improved. For behavior:
|
|
81
82
|
|
|
82
83
|
- `node behavioral-evals/run.js run --engine opencode` (or `--engine claude`) — on-demand, token-costing.
|
|
83
|
-
-
|
|
84
|
+
- Weekly behavioral workflow validates case structure and runs live cases only when its runner has the required CLI.
|
|
84
85
|
- `node benchmarks/run.js scaffold <scenario>` → run both variants → `record` with evidence logs.
|
|
85
86
|
|
|
86
|
-
For a live-host enforcement claim, preserve a host/session artifact showing the mechanism
|
|
87
|
+
For a live-host enforcement claim, preserve a host/session artifact showing the mechanism loaded and fired. For an effectiveness claim, use the paired evidence discipline in #71 rather than inferring improvement from mechanism presence.
|
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,23 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project are documented in this file.
|
|
4
4
|
|
|
5
|
+
## [0.8.1](https://github.com/dyphn1/Harness-everything/compare/v0.8.0...v0.8.1) (2026-09-17)
|
|
6
|
+
|
|
7
|
+
### Bug Fixes
|
|
8
|
+
|
|
9
|
+
* **router:** enforce selected workflow lifecycle ([9f3394a](https://github.com/dyphn1/Harness-everything/commit/9f3394a3ff59aaa08428e12a9a2784e7541368c4))
|
|
10
|
+
* **workflow:** Close lifecycle isolation gaps ([96b58e7](https://github.com/dyphn1/Harness-everything/commit/96b58e7ce2e52312880663e59380038e4bf5f985)), closes [#131](https://github.com/dyphn1/Harness-everything/issues/131)
|
|
11
|
+
* **workflow:** Normalize Windows worktree paths ([18ee645](https://github.com/dyphn1/Harness-everything/commit/18ee645a1a7165d01d60a964947082ad0108b93c)), closes [#131](https://github.com/dyphn1/Harness-everything/issues/131)
|
|
12
|
+
* **workflow:** require worktree isolation for major mutations ([9ba0098](https://github.com/dyphn1/Harness-everything/commit/9ba0098adc94fe141fca2c03f07d0883d9a56b9b))
|
|
13
|
+
|
|
14
|
+
## [Unreleased]
|
|
15
|
+
|
|
16
|
+
### Fixed
|
|
17
|
+
|
|
18
|
+
- Make selected workflows persist across follow-up prompts, bind Fable runs to workflow/session identities, and require correlated stage evidence before completion (#131, #142).
|
|
19
|
+
- Enforce major-workflow Git worktree isolation at supported mutation hooks, check direct/patch targets and explicit shell paths, and retain isolation across scoped escape and blocked states.
|
|
20
|
+
- Provide bounded run entry/replan and per-stage escape commands; expose unsupported hosts and shell-sandbox limits without upgrading live-host evidence.
|
|
21
|
+
|
|
5
22
|
## [0.8.0](https://github.com/dyphn1/Harness-everything/compare/v0.7.0...v0.8.0) (2026-09-17)
|
|
6
23
|
|
|
7
24
|
### Features
|
package/README.md
CHANGED
|
@@ -68,7 +68,7 @@ npx github:dyphn1/Harness-everything install
|
|
|
68
68
|
1. **Use the selected surface's real mechanism:** Claude Code hooks, the local OpenAI plugin lifecycle hooks, OpenCode's plugin API, or advisory instructions depending on what you installed.
|
|
69
69
|
2. **Preflight / session context where packaged:** Hook-capable surfaces can inject environment/session context automatically; advisory-only surfaces must not be described as if they do.
|
|
70
70
|
3. **Verification boundary:** Completion claims require objective evidence; whether that boundary is mechanically invoked or explicitly called depends on the host surface.
|
|
71
|
-
4. **Mandatory
|
|
71
|
+
4. **Mandatory applicable workflow:** Evaluate each suggested skill's complete `SKILL.md` before omission, then resolve the selected topology with objective evidence. Reasoning and implementation remain flexible; escape applies only to a declared uncovered stage with evidence. Tier 3 / Fable mutation requires a verified Git worktree. See the [workflow runtime contract](docs/workflow-runtime.md) for entry, completion, and host limits. Harness does not impose one universal TODO/TDD/Fable sequence.
|
|
72
72
|
|
|
73
73
|
### What Gets Installed (and How to Remove It)
|
|
74
74
|
|
|
@@ -312,4 +312,4 @@ npm run test:plugin:openai
|
|
|
312
312
|
npm run test:plugin:submission
|
|
313
313
|
```
|
|
314
314
|
|
|
315
|
-
After intentional runtime/workflow changes, run `npm run docs:sync` and commit the regenerated repository contract. All script modifications must pass 100% cleanly before pushing to keep the runtime immunized against behavioral regression.
|
|
315
|
+
After intentional runtime/workflow changes, run `npm run docs:sync` and commit the regenerated repository contract. All script modifications must pass 100% cleanly before pushing to keep the runtime immunized against behavioral regression.
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
{
|
|
2
|
+
"schemaVersion": 1,
|
|
3
|
+
"baselineCommit": "8b99baec44745e171f078fe9eb3dac6fd812b5c8",
|
|
4
|
+
"reviewedRevision": "commit containing this report",
|
|
5
|
+
"evidenceLayer": "local deterministic mechanisms and packages",
|
|
6
|
+
"environment": {
|
|
7
|
+
"os": "win32",
|
|
8
|
+
"node": "v24.15.0",
|
|
9
|
+
"npm": "11.12.1"
|
|
10
|
+
},
|
|
11
|
+
"gates": [
|
|
12
|
+
{
|
|
13
|
+
"gate": "test",
|
|
14
|
+
"exitCode": 0,
|
|
15
|
+
"seconds": 76.007
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
"gate": "test:mutations",
|
|
19
|
+
"exitCode": 0,
|
|
20
|
+
"seconds": 5.309
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
"gate": "test:mechanism",
|
|
24
|
+
"exitCode": 0,
|
|
25
|
+
"seconds": 54.904
|
|
26
|
+
},
|
|
27
|
+
{
|
|
28
|
+
"gate": "test:consistency",
|
|
29
|
+
"exitCode": 0,
|
|
30
|
+
"seconds": 0.782
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
"gate": "test:repo-contract",
|
|
34
|
+
"exitCode": 0,
|
|
35
|
+
"seconds": 0.522
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
"gate": "test:docs:capabilities",
|
|
39
|
+
"exitCode": 0,
|
|
40
|
+
"seconds": 0.639
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"gate": "test:references",
|
|
44
|
+
"exitCode": 0,
|
|
45
|
+
"seconds": 0.597
|
|
46
|
+
},
|
|
47
|
+
{
|
|
48
|
+
"gate": "test:release",
|
|
49
|
+
"exitCode": 0,
|
|
50
|
+
"seconds": 5.161
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
"gate": "test:collision",
|
|
54
|
+
"exitCode": 0,
|
|
55
|
+
"seconds": 0.481
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
"gate": "test:routing:skills",
|
|
59
|
+
"exitCode": 0,
|
|
60
|
+
"seconds": 2.926
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
"gate": "test:routing:invariants",
|
|
64
|
+
"exitCode": 0,
|
|
65
|
+
"seconds": 3.521
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
"gate": "test:plugin:openai",
|
|
69
|
+
"exitCode": 0,
|
|
70
|
+
"seconds": 4.225
|
|
71
|
+
},
|
|
72
|
+
{
|
|
73
|
+
"gate": "test:plugin:submission",
|
|
74
|
+
"exitCode": 0,
|
|
75
|
+
"seconds": 0.963
|
|
76
|
+
},
|
|
77
|
+
{
|
|
78
|
+
"gate": "test:platform:compatibility",
|
|
79
|
+
"exitCode": 0,
|
|
80
|
+
"seconds": 0.612
|
|
81
|
+
}
|
|
82
|
+
],
|
|
83
|
+
"mechanismSuites": 44,
|
|
84
|
+
"lifecycleAssertions": {
|
|
85
|
+
"source": 50,
|
|
86
|
+
"openaiPackage": 50
|
|
87
|
+
},
|
|
88
|
+
"waza": {
|
|
89
|
+
"checks": 57,
|
|
90
|
+
"passed": 57
|
|
91
|
+
},
|
|
92
|
+
"liveHost": "not run for this change",
|
|
93
|
+
"behavioralEffectiveness": "not measured for this change",
|
|
94
|
+
"windowsPathRegression": "Native resolution equates Windows 8.3 and long path spellings; regression and final local self-regression passed."
|
|
95
|
+
}
|
package/ci/action-gate.test.js
CHANGED
|
@@ -237,7 +237,7 @@ try {
|
|
|
237
237
|
check(canonicalHooks.hooks.Stop.some(group => group.id === 'harness:stop:action-gate-audit'), 'Claude hook manifest closes unresolved approvals on Stop');
|
|
238
238
|
|
|
239
239
|
const pluginHooks = JSON.parse(fs.readFileSync(path.join(ROOT, 'plugins', 'harness-everything', 'hooks', 'hooks.json'), 'utf8'));
|
|
240
|
-
const pluginPre = pluginHooks.hooks.PreToolUse.find(group => group.matcher === 'Bash|apply_patch');
|
|
240
|
+
const pluginPre = pluginHooks.hooks.PreToolUse.find(group => group.matcher === 'Bash|apply_patch' && group.hooks.some(hook => /codex-action-gate-pre\.js/.test(hook.command)));
|
|
241
241
|
check(pluginPre && pluginPre.hooks.some(hook => /codex-action-gate-pre\.js/.test(hook.command)), 'OpenAI plugin wires the attribution-aware Codex action-gate adapter to Bash|apply_patch');
|
|
242
242
|
check(!Object.prototype.hasOwnProperty.call(pluginHooks.hooks, 'PostToolUseFailure'), 'Codex plugin does not declare unsupported PostToolUseFailure lifecycle event');
|
|
243
243
|
const pluginPost = pluginHooks.hooks.PostToolUse.find(group => group.matcher === 'Bash|apply_patch');
|
|
@@ -44,6 +44,7 @@ const CURRENT_SURFACES = [
|
|
|
44
44
|
'docs/platform-capabilities.md',
|
|
45
45
|
'docs/reflection.md',
|
|
46
46
|
'docs/routing.md',
|
|
47
|
+
'docs/workflow-runtime.md',
|
|
47
48
|
'docs/troubleshooting.md',
|
|
48
49
|
'docs/openai-plugin.md',
|
|
49
50
|
'submission/openai/README.md',
|
|
@@ -59,6 +60,8 @@ const STALE_PATTERNS = [
|
|
|
59
60
|
/Only possible on Claude Code \(the only platform with a hook\/exit-code execution system\)/i,
|
|
60
61
|
/On platforms with no hook system at all \(Cursor, Copilot, Codex/i,
|
|
61
62
|
/hooks[^\n]{0,100}Hard enforcement, Claude Code only/i,
|
|
63
|
+
/mandatory evaluation\s*[,/]\s*advisory execution/i,
|
|
64
|
+
/Tier-specific skills remain advisory/i,
|
|
62
65
|
/Codex[^\n]{0,180}\.codex\/skills\//i,
|
|
63
66
|
];
|
|
64
67
|
|
|
@@ -7,19 +7,15 @@ const ROOT = path.resolve(__dirname, '..');
|
|
|
7
7
|
let failed = 0;
|
|
8
8
|
|
|
9
9
|
function check(condition, message) {
|
|
10
|
-
if (condition) {
|
|
11
|
-
|
|
12
|
-
} else {
|
|
13
|
-
console.error(` FAIL ${message}`);
|
|
14
|
-
failed++;
|
|
15
|
-
}
|
|
10
|
+
if (condition) console.log(` PASS ${message}`);
|
|
11
|
+
else { console.error(` FAIL ${message}`); failed++; }
|
|
16
12
|
}
|
|
17
13
|
|
|
18
14
|
function read(rel) {
|
|
19
15
|
return fs.readFileSync(path.join(ROOT, rel), 'utf8');
|
|
20
16
|
}
|
|
21
17
|
|
|
22
|
-
console.log('===
|
|
18
|
+
console.log('=== Mandatory Workflow Routing Contract ===');
|
|
23
19
|
|
|
24
20
|
const kernel = path.join(ROOT, 'harness-everything', 'scripts', 'kernel-router.js');
|
|
25
21
|
const tier2 = spawnSync(process.execPath, [kernel, 'add a login endpoint with tests and update the implementation'], {
|
|
@@ -36,25 +32,30 @@ check(tier2.stdout.includes('Verify before claim'), 'verify-before-claim invaria
|
|
|
36
32
|
check(tier2.stdout.includes('after 3 same-signature failures'), 'failure escalation invariant is present');
|
|
37
33
|
check(tier2.stdout.includes('loop-budget:'), 'iterative-single loop budget invariant is present');
|
|
38
34
|
check(tier2.stdout.includes('evaluate-suggestions-before-skip'), 'non-empty suggestions inject evaluate-before-skip invariant');
|
|
39
|
-
check(tier2.stdout.includes('
|
|
40
|
-
check(tier2.stdout.includes('
|
|
35
|
+
check(tier2.stdout.includes('WORKFLOW SKILLS (EVALUATE APPLICABILITY'), 'domain suggestions remain applicability inputs');
|
|
36
|
+
check(tier2.stdout.includes('SELECTED WORKFLOW IS MANDATORY'), 'selected workflow execution is mandatory');
|
|
41
37
|
check(tier2.stdout.includes('tdd:'), 'Tier 2 can still recommend TDD');
|
|
42
38
|
check(!tier2.stdout.includes('BASE EXECUTION LOOP'), 'legacy fixed base-execution-loop output is suppressed');
|
|
43
|
-
check(tier2.stdout.includes('
|
|
39
|
+
check(tier2.stdout.includes('Mandatory applicable workflow'), 'orchestration policy requires selected applicable workflow');
|
|
40
|
+
check(tier2.stdout.includes('model controls HOW to satisfy it'), 'reasoning/implementation freedom remains inside workflow');
|
|
41
|
+
check(tier2.stdout.includes('WORKFLOW EXECUTION CONTRACT (MANDATORY WHEN SELECTED)'), 'kernel emits workflow execution contract');
|
|
42
|
+
check(tier2.stdout.includes('- State: unpersisted'), 'manual route without host session does not claim persisted lifecycle');
|
|
43
|
+
check(tier2.stdout.includes('Generic simple/routine/already-clear reasons cannot waive'), 'model confidence cannot bypass workflow');
|
|
44
|
+
check(tier2.stdout.includes('Escape is limited to workflow-uncovered-scope or host-capability-unavailable'), 'workflow escape is exception-only');
|
|
45
|
+
check(!tier2.stdout.includes('execution remains advisory after evaluation'), 'old advisory execution wording is absent');
|
|
46
|
+
check(!tier2.stdout.includes('isolated-worktree-before-mutation'), 'Tier 2 does not inherit the major-workflow worktree invariant');
|
|
44
47
|
|
|
45
48
|
const tier2Checkpoints = tier2.stdout.match(/HARNESS ROUTING CHECKPOINT \(REQUIRED VISIBLE STATE\)/g) || [];
|
|
46
|
-
check(tier2Checkpoints.length === 1, 'Tier 2 emits exactly one
|
|
47
|
-
check(tier2.stdout.includes('- Tier: Tier 2'), 'checkpoint exposes
|
|
48
|
-
check(tier2.stdout.includes('- Strategy: iterative-single'), 'checkpoint exposes
|
|
49
|
+
check(tier2Checkpoints.length === 1, 'Tier 2 emits exactly one routing checkpoint');
|
|
50
|
+
check(tier2.stdout.includes('- Tier: Tier 2'), 'checkpoint exposes Tier 2');
|
|
51
|
+
check(tier2.stdout.includes('- Strategy: iterative-single'), 'checkpoint exposes selected strategy');
|
|
49
52
|
check(/- Required invariants: .*verify-before-claim/.test(tier2.stdout), 'checkpoint exposes required invariants');
|
|
50
|
-
check(/- Suggested skills: .*tdd/.test(tier2.stdout), 'checkpoint exposes
|
|
51
|
-
check(tier2.stdout.includes('Suggestion evaluation: MANDATORY'), 'checkpoint
|
|
52
|
-
check(tier2.stdout.includes('read its complete SKILL.md entry'), 'checkpoint requires reading
|
|
53
|
-
check(tier2.stdout.includes('name, description, router summary'), 'checkpoint rejects metadata-only
|
|
54
|
-
check(tier2.stdout.includes('routine/common task'), 'checkpoint rejects
|
|
55
|
-
check(tier2.stdout.includes('
|
|
56
|
-
check(tier2.stdout.includes('unresolved/unavailable rather than skipped'), 'checkpoint preserves unresolved suggestions instead of silent skip');
|
|
57
|
-
check(tier2.stdout.includes('If all are skipped after evaluation'), 'all-skipped rationale is grounded after evaluation');
|
|
53
|
+
check(/- Suggested skills: .*tdd/.test(tier2.stdout), 'checkpoint exposes suggestions');
|
|
54
|
+
check(tier2.stdout.includes('Suggestion evaluation: MANDATORY'), 'checkpoint requires suggestion evaluation');
|
|
55
|
+
check(tier2.stdout.includes('read its complete SKILL.md entry'), 'checkpoint requires reading skill entry');
|
|
56
|
+
check(tier2.stdout.includes('name, description, router summary'), 'checkpoint rejects metadata-only omission');
|
|
57
|
+
check(tier2.stdout.includes('routine/common task'), 'checkpoint rejects routine-task omission shortcut');
|
|
58
|
+
check(tier2.stdout.includes('selected workflow is mandatory'), 'checkpoint distinguishes skill applicability from topology obligation');
|
|
58
59
|
|
|
59
60
|
const tier3 = spawnSync(process.execPath, [kernel, 'audit the entire repository architecture and coordinate multiple modules'], {
|
|
60
61
|
cwd: ROOT,
|
|
@@ -62,86 +63,98 @@ const tier3 = spawnSync(process.execPath, [kernel, 'audit the entire repository
|
|
|
62
63
|
});
|
|
63
64
|
check(tier3.status === 0, 'Tier 3 kernel routing exits successfully');
|
|
64
65
|
check(/RECOMMENDED TIER:\s*Tier 3/i.test(tier3.stdout), 'macro task remains Tier 3');
|
|
65
|
-
check(tier3.stdout.includes('"strategy":"fable-staged"'), 'Tier 3
|
|
66
|
-
check(tier3.stdout.includes('fable-mode / fable-discipline'), 'Tier 3
|
|
67
|
-
check(tier3.stdout.includes('
|
|
68
|
-
check(tier3.stdout.includes('
|
|
69
|
-
check(tier3.stdout.includes('
|
|
66
|
+
check(tier3.stdout.includes('"strategy":"fable-staged"'), 'Tier 3 task selects fable-staged');
|
|
67
|
+
check(tier3.stdout.includes('fable-mode / fable-discipline'), 'Tier 3 plan exposes Fable capabilities');
|
|
68
|
+
check(tier3.stdout.includes('selected Fable topology must be entered and resolved before completion'), 'selected Fable topology is mandatory');
|
|
69
|
+
check(tier3.stdout.includes('WORKFLOW EXECUTION CONTRACT (MANDATORY WHEN SELECTED)'), 'Tier 3 emits execution contract');
|
|
70
|
+
check(tier3.stdout.includes('isolated-worktree-before-mutation'), 'Tier 3 structured plan carries the worktree isolation invariant');
|
|
71
|
+
check(tier3.stdout.includes('using-git-worktrees'), 'Tier 3 structured plan surfaces the worktree workflow skill');
|
|
72
|
+
check(tier3.stdout.includes('mutations require Git worktree isolation'), 'Tier 3 execution contract requires worktree isolation before mutation');
|
|
73
|
+
check(tier3.stdout.includes('unavailable isolation means BLOCKED'), 'Tier 3 worktree failure blocks instead of falling back in place');
|
|
70
74
|
|
|
71
75
|
const harnessSkill = read('harness-everything/SKILL.md');
|
|
72
|
-
check(!/Requests that already name a skill/i.test(harnessSkill), 'harness entrypoint no longer opts out when another skill is named');
|
|
73
76
|
check(/Work that names or matches another skill/i.test(harnessSkill), 'named domain skills still pass through Harness routing');
|
|
74
|
-
check(/
|
|
75
|
-
check(/
|
|
76
|
-
check(/
|
|
77
|
-
check(
|
|
78
|
-
check(/
|
|
79
|
-
check(/Using one suggestion does not waive evaluation of others/i.test(harnessSkill), 'skill contract applies evaluation per omitted suggestion');
|
|
80
|
-
check(/Unreadable suggestions are `unresolved\/unavailable`/i.test(harnessSkill), 'skill contract defines unreadable suggestion disposition');
|
|
81
|
-
check(/If all are skipped, give one brief flow-grounded reason/i.test(harnessSkill), 'skill contract preserves evaluated all-skipped rationale');
|
|
82
|
-
check(/mandatory evaluation, advisory execution/i.test(harnessSkill), 'skill entry states the core disposition succinctly');
|
|
77
|
+
check(/selected topology is not advisory/i.test(harnessSkill), 'skill contract makes selected topology mandatory');
|
|
78
|
+
check(/"Simple", "routine".*cannot justify omission/i.test(harnessSkill), 'skill contract rejects confidence/routine omission shortcuts');
|
|
79
|
+
check(/explicit escape with uncovered scope \+ evidence/i.test(harnessSkill), 'skill contract defines evidence-backed escape');
|
|
80
|
+
check(/Complete only after applicable workflow obligations and objective verification resolve/i.test(harnessSkill), 'skill contract gates completion on workflow resolution');
|
|
81
|
+
check(/mandatory applicable workflow; flexible reasoning\/implementation/i.test(harnessSkill), 'skill entry states core policy');
|
|
83
82
|
|
|
84
83
|
const pluginHarnessSkill = read('plugins/harness-everything/skills/harness-everything/SKILL.md');
|
|
85
84
|
check(pluginHarnessSkill === harnessSkill, 'canonical/plugin Harness SKILL.md copies remain identical');
|
|
86
|
-
|
|
87
|
-
check(
|
|
88
|
-
|
|
89
|
-
|
|
85
|
+
check(read('plugins/harness-everything/skills/harness-everything/scripts/kernel-router.js') === read('harness-everything/scripts/kernel-router.js'), 'canonical/plugin kernel-router copies remain identical');
|
|
86
|
+
check(read('plugins/harness-everything/skills/harness-everything/scripts/kernel-router-core.js') === read('harness-everything/scripts/kernel-router-core.js'), 'canonical/plugin kernel-router core copies remain identical');
|
|
87
|
+
check(read('plugins/harness-everything/skills/harness-everything/references/triage-and-tiers.md') === read('harness-everything/references/triage-and-tiers.md'), 'canonical/plugin triage references remain identical');
|
|
88
|
+
|
|
89
|
+
const worktreeSkill = read('using-git-worktrees/SKILL.md');
|
|
90
|
+
check(/Major workflow mode/i.test(worktreeSkill), 'worktree skill defines mandatory major-workflow mode');
|
|
91
|
+
check(/never fall back to the primary working tree/i.test(worktreeSkill), 'worktree skill blocks unsafe in-place fallback for major work');
|
|
92
|
+
check(/Creation\/entry failure => `BLOCKED`/i.test(worktreeSkill), 'worktree skill makes isolation failure a blocked state');
|
|
93
|
+
check(read('plugins/harness-everything/skills/using-git-worktrees/SKILL.md') === worktreeSkill, 'canonical/plugin worktree skill copies remain identical');
|
|
90
94
|
|
|
91
95
|
const cognitiveSkill = read('install-cognitive-os/SKILL.md');
|
|
92
|
-
check(/policy, not a required peer-skill selection/i.test(cognitiveSkill), 'Cognitive OS
|
|
93
|
-
check(!/Tasks already governed by a more specific domain skill/i.test(cognitiveSkill), 'domain skill selection no longer disables Cognitive OS policy');
|
|
96
|
+
check(/policy, not a required peer-skill selection/i.test(cognitiveSkill), 'Cognitive OS remains reasoning policy rather than peer dependency');
|
|
94
97
|
|
|
95
98
|
const hooks = JSON.parse(read('hooks/hooks.json'));
|
|
96
99
|
const promptHooks = hooks.hooks && hooks.hooks.UserPromptSubmit;
|
|
97
100
|
const command = promptHooks && promptHooks[0] && promptHooks[0].hooks && promptHooks[0].hooks[0] && promptHooks[0].hooks[0].command;
|
|
98
|
-
check(command === 'node "${CLAUDE_PLUGIN_ROOT}/harness-everything/scripts/kernel-router.js"', 'UserPromptSubmit anchors
|
|
101
|
+
check(command === 'node "${CLAUDE_PLUGIN_ROOT}/harness-everything/scripts/kernel-router.js"', 'UserPromptSubmit anchors kernel to Claude plugin root');
|
|
102
|
+
const preHooks = hooks.hooks && hooks.hooks.PreToolUse || [];
|
|
103
|
+
const workflowHook = preHooks.find(entry => entry.id === 'harness:pre:workflow-gate');
|
|
104
|
+
check(Boolean(workflowHook), 'Claude PreToolUse includes workflow gate');
|
|
105
|
+
check(workflowHook && /Bash/.test(workflowHook.matcher) && /PowerShell/.test(workflowHook.matcher) && /Edit/.test(workflowHook.matcher) && /Write/.test(workflowHook.matcher), 'Claude workflow gate covers shell and artifact mutation');
|
|
106
|
+
const stopHooks = hooks.hooks && hooks.hooks.Stop || [];
|
|
107
|
+
check(stopHooks.some(entry => entry.id === 'harness:stop:workflow-completion-gate'), 'Claude Stop includes Fable workflow completion gate');
|
|
108
|
+
|
|
109
|
+
const openaiHooks = JSON.parse(read('plugins/harness-everything/hooks/hooks.json'));
|
|
110
|
+
const openaiWorkflowHook = (openaiHooks.hooks && openaiHooks.hooks.PreToolUse || []).find(entry =>
|
|
111
|
+
(entry.hooks || []).some(hook => String(hook.command || '').includes('workflow-gate.js'))
|
|
112
|
+
);
|
|
113
|
+
check(openaiWorkflowHook && /Bash/.test(openaiWorkflowHook.matcher) && /apply_patch/.test(openaiWorkflowHook.matcher), 'Codex/OpenAI packaged workflow gate covers Bash and apply_patch');
|
|
99
114
|
|
|
100
115
|
const triageDoc = read('harness-everything/references/triage-and-tiers.md');
|
|
101
|
-
check(
|
|
102
|
-
check(
|
|
103
|
-
check(
|
|
104
|
-
check(
|
|
105
|
-
check(triageDoc
|
|
106
|
-
check(
|
|
107
|
-
check(triageDoc.includes('Using one suggested skill does not waive evaluation'), 'reference preserves per-suggestion evaluation');
|
|
108
|
-
check(triageDoc.includes('cannot be resolved/read is not a valid skip'), 'reference preserves unresolved/unavailable state');
|
|
109
|
-
check(triageDoc.includes('Kernel emission alone is not proof'), 'reference preserves the #82 host-evidence boundary');
|
|
116
|
+
check(/Mandatory applicable workflow/i.test(triageDoc), 'triage reference documents mandatory applicable workflow');
|
|
117
|
+
check(/topology becomes the run's execution contract/i.test(triageDoc), 'triage reference makes topology a contract');
|
|
118
|
+
check(/workflow-uncovered-scope/i.test(triageDoc), 'triage reference documents narrow escape policy');
|
|
119
|
+
check(/A tier is \*\*not\*\* a fixed TODO\/TDD\/Fable pipeline/i.test(triageDoc), 'triage reference rejects universal tier pipeline');
|
|
120
|
+
check(/```mermaid/.test(triageDoc), 'triage reference retains executable flowchart documentation');
|
|
121
|
+
check(/cross-host live-enforcement claim/i.test(triageDoc), 'triage reference preserves host evidence boundary');
|
|
110
122
|
|
|
111
123
|
const routingDoc = read('docs/routing.md');
|
|
112
|
-
check(
|
|
113
|
-
check(routingDoc
|
|
114
|
-
check(routingDoc
|
|
124
|
+
check(/Mandatory applicable workflow/i.test(routingDoc), 'routing docs use mandatory workflow policy');
|
|
125
|
+
check(/workflow-gate\.js/.test(routingDoc), 'routing docs describe PreToolUse workflow gate');
|
|
126
|
+
check(/workflow-stop-gate\.js/.test(routingDoc), 'routing docs describe completion gate');
|
|
127
|
+
check(/workflow-disposition\.js/.test(routingDoc), 'routing docs describe explicit escape mechanism');
|
|
128
|
+
check(!/mandatory to evaluate and advisory to execute/i.test(routingDoc), 'routing docs remove old advisory execution contract');
|
|
115
129
|
|
|
116
130
|
const architectureDoc = read('docs/architecture.md');
|
|
117
|
-
check(
|
|
118
|
-
check(architectureDoc
|
|
131
|
+
check(/topology becomes a lifecycle contract/i.test(architectureDoc), 'architecture makes selected topology lifecycle contract');
|
|
132
|
+
check(/workflow-gate\.js/.test(architectureDoc), 'architecture includes workflow bypass gate');
|
|
133
|
+
check(!/Mandatory evaluation, advisory execution/i.test(architectureDoc), 'architecture removes old advisory execution policy');
|
|
119
134
|
|
|
120
135
|
const philosophyDoc = read('docs/philosophy.md');
|
|
121
|
-
check(
|
|
136
|
+
check(/Constrain Lifecycle, Not Reasoning/i.test(philosophyDoc), 'philosophy separates lifecycle constraint from reasoning freedom');
|
|
137
|
+
check(/Applicable workflow is mandatory/i.test(philosophyDoc), 'philosophy states applicable workflow requirement');
|
|
138
|
+
check(!/Mandatory Evaluation, Advisory Execution/i.test(philosophyDoc), 'philosophy removes old advisory execution policy');
|
|
122
139
|
|
|
123
140
|
const meshDoc = read('docs/mechanism-first-skill-mesh.md');
|
|
124
|
-
check(
|
|
141
|
+
check(/mandatory applicable workflow \+ local skill autonomy/i.test(meshDoc), 'skill mesh documents mandatory outer workflow and local skill autonomy');
|
|
142
|
+
check(/selected topology is mandatory for the run/i.test(meshDoc), 'skill mesh distinguishes selected topology from skill suggestions');
|
|
125
143
|
|
|
126
144
|
const capabilitiesDoc = read('docs/platform-capabilities.md');
|
|
127
|
-
check(capabilitiesDoc.includes('repository/agent contract'), 'platform docs distinguish
|
|
128
|
-
check(capabilitiesDoc.includes('does not
|
|
145
|
+
check(capabilitiesDoc.includes('repository/agent contract'), 'platform docs distinguish contract from host enforcement evidence');
|
|
146
|
+
check(capabilitiesDoc.includes('does not upgrade `platform-compatibility.json` live-host status values'), 'routing change does not inflate compatibility status');
|
|
129
147
|
|
|
130
|
-
const
|
|
131
|
-
check(
|
|
132
|
-
check(
|
|
148
|
+
const advisory = read('scripts/lib/advisory-text.js');
|
|
149
|
+
check(/For EVERY suggested skill/i.test(advisory), 'generated advisory instructions require per-suggestion applicability evaluation');
|
|
150
|
+
check(/selected workflow topology is mandatory once applicable/i.test(advisory), 'advisory surfaces carry mandatory workflow semantics');
|
|
151
|
+
check(/No universal skill pipeline/i.test(advisory), 'advisory surfaces reject universal skill pipeline');
|
|
152
|
+
check(/workflow genuinely cannot cover part of the task/i.test(advisory), 'advisory surfaces constrain workflow escape');
|
|
153
|
+
check(read('plugins/harness-everything/scripts/lib/advisory-text.js') === advisory, 'OpenAI plugin advisory mirror matches canonical source');
|
|
133
154
|
|
|
134
155
|
const agents = read('AGENTS.md');
|
|
135
|
-
check(
|
|
136
|
-
|
|
137
|
-
const advisory = read('scripts/lib/advisory-text.js');
|
|
138
|
-
check(advisory.includes('For EVERY suggested skill'), 'generated advisory instructions require per-suggestion evaluation');
|
|
139
|
-
check(advisory.includes('entry/basic flow before skipping it'), 'Codex AGENTS generator includes read-before-skip');
|
|
140
|
-
check(advisory.includes('There is NO universal TODO/TDD/Fable sequence'), 'advisory surfaces reject the old fixed execution pipeline');
|
|
141
|
-
check(!advisory.includes('Initialize the `todo-driven-workflow` checklist first'), 'old forced Tier 2/3 checklist pipeline is removed');
|
|
142
|
-
check(!advisory.includes('load `fable-mode` and `fable-discipline`, run sub-agents'), 'old forced Tier 3 Fable pipeline is removed');
|
|
143
|
-
const pluginAdvisory = read('plugins/harness-everything/scripts/lib/advisory-text.js');
|
|
144
|
-
check(pluginAdvisory === advisory, 'OpenAI plugin advisory mirror matches canonical source');
|
|
156
|
+
check(/Selected workflow is mandatory; reasoning inside it stays flexible/i.test(agents), 'repository agent contract matches mandatory workflow policy');
|
|
157
|
+
check(!/Router suggestions are mandatory to evaluate, advisory to execute/i.test(agents), 'repository agent contract removes old advisory execution rule');
|
|
145
158
|
|
|
146
159
|
console.log(`\n${failed === 0 ? 'PASS' : 'FAIL'}: invariant routing contract (${failed} failure${failed === 1 ? '' : 's'})`);
|
|
147
160
|
process.exit(failed === 0 ? 0 : 1);
|