harness-everything 0.3.6 → 0.4.0

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.
Files changed (573) hide show
  1. package/.agents/plugins/marketplace.json +20 -0
  2. package/.claude-plugin/marketplace.json +1 -1
  3. package/.claude-plugin/plugin.json +8 -7
  4. package/.github/workflows/ci.yml +23 -18
  5. package/.github/workflows/release.yml +53 -27
  6. package/.releaserc.json +113 -0
  7. package/AGENTS.md +34 -23
  8. package/BENCHMARK_SOP.md +38 -18
  9. package/CHANGELOG.md +194 -3
  10. package/CONTRIBUTING.md +17 -4
  11. package/PRIVACY.md +25 -0
  12. package/README.md +118 -87
  13. package/RELEASING.md +82 -0
  14. package/SUPPORT.md +27 -0
  15. package/TERMS.md +21 -0
  16. package/VERIFICATION.md +175 -286
  17. package/behavioral-evals/README.md +21 -0
  18. package/behavioral-evals/case-validator.js +194 -0
  19. package/behavioral-evals/cases/baseline-environment-detection.yaml +21 -0
  20. package/behavioral-evals/cases/baseline-eval-harness.yaml +27 -0
  21. package/behavioral-evals/cases/baseline-fable-discipline.yaml +31 -0
  22. package/behavioral-evals/cases/baseline-find-skills-exposure.yaml +49 -0
  23. package/behavioral-evals/cases/baseline-find-skills.yaml +21 -0
  24. package/behavioral-evals/cases/baseline-git-commit.yaml +2 -2
  25. package/behavioral-evals/cases/baseline-install-cognitive-os.yaml +24 -0
  26. package/behavioral-evals/cases/baseline-multi-agent-workspace.yaml +28 -0
  27. package/behavioral-evals/cases/baseline-rewrite-commits.yaml +34 -0
  28. package/behavioral-evals/cases/baseline-self-evolve.yaml +31 -0
  29. package/behavioral-evals/cases/baseline-skill-creator.yaml +20 -0
  30. package/behavioral-evals/cases/baseline-skill-style.yaml +21 -0
  31. package/behavioral-evals/cases/baseline-to-spec.yaml +34 -0
  32. package/behavioral-evals/cases/baseline-to-tickets.yaml +24 -0
  33. package/behavioral-evals/cases/baseline-todo-driven-workflow.yaml +32 -0
  34. package/behavioral-evals/cases/baseline-using-git-worktrees.yaml +15 -0
  35. package/behavioral-evals/cases/breaker-zoom-out-after-3.yaml +2 -2
  36. package/behavioral-evals/cases/pressure-complexity-skip.yaml +2 -2
  37. package/behavioral-evals/cases/pressure-scope-bypass.yaml +7 -2
  38. package/behavioral-evals/cases/pressure-sunk-cost-retry.yaml +7 -4
  39. package/behavioral-evals/cases/scope-discipline.yaml +2 -1
  40. package/behavioral-evals/cases/verify-before-done.yaml +7 -5
  41. package/behavioral-evals/evidence/2026-09-07/baseline-debugging/case.yaml +31 -0
  42. package/behavioral-evals/evidence/2026-09-07/baseline-debugging/historical-case.yaml +31 -0
  43. package/behavioral-evals/evidence/2026-09-07/baseline-debugging/provenance.json +42 -0
  44. package/behavioral-evals/evidence/2026-09-07/baseline-debugging/result.sanitized.json +20 -0
  45. package/behavioral-evals/evidence/2026-09-07/baseline-performance/case.yaml +34 -0
  46. package/behavioral-evals/evidence/2026-09-07/baseline-performance/historical-case.yaml +34 -0
  47. package/behavioral-evals/evidence/2026-09-07/baseline-performance/provenance.json +42 -0
  48. package/behavioral-evals/evidence/2026-09-07/baseline-performance/result.sanitized.json +20 -0
  49. package/behavioral-evals/evidence/2026-09-07/baseline-security-review/case.yaml +28 -0
  50. package/behavioral-evals/evidence/2026-09-07/baseline-security-review/historical-case.yaml +28 -0
  51. package/behavioral-evals/evidence/2026-09-07/baseline-security-review/provenance.json +42 -0
  52. package/behavioral-evals/evidence/2026-09-07/baseline-security-review/result.sanitized.json +20 -0
  53. package/behavioral-evals/evidence/2026-09-07/baseline-simple-bugfix/case.yaml +33 -0
  54. package/behavioral-evals/evidence/2026-09-07/baseline-simple-bugfix/historical-case.yaml +33 -0
  55. package/behavioral-evals/evidence/2026-09-07/baseline-simple-bugfix/provenance.json +42 -0
  56. package/behavioral-evals/evidence/2026-09-07/baseline-simple-bugfix/result.sanitized.json +20 -0
  57. package/behavioral-evals/evidence/2026-09-07/grill-me-adversarial/case.yaml +28 -0
  58. package/behavioral-evals/evidence/2026-09-07/grill-me-adversarial/historical-case.yaml +18 -0
  59. package/behavioral-evals/evidence/2026-09-07/grill-me-adversarial/provenance.json +30 -0
  60. package/behavioral-evals/evidence/2026-09-07/live-run-blocker.md +16 -0
  61. package/behavioral-evals/evidence/2026-09-07/manifest.json +88 -0
  62. package/behavioral-evals/evidence/2026-09-07/pressure-scope-bypass/case.yaml +33 -0
  63. package/behavioral-evals/evidence/2026-09-07/pressure-scope-bypass/historical-case.yaml +28 -0
  64. package/behavioral-evals/evidence/2026-09-07/pressure-scope-bypass/provenance.json +30 -0
  65. package/behavioral-evals/evidence/2026-09-07/pressure-skip-docs/case.yaml +50 -0
  66. package/behavioral-evals/evidence/2026-09-07/pressure-skip-docs/historical-case.yaml +50 -0
  67. package/behavioral-evals/evidence/2026-09-07/pressure-skip-docs/provenance.json +42 -0
  68. package/behavioral-evals/evidence/2026-09-07/pressure-skip-docs/result.sanitized.json +20 -0
  69. package/behavioral-evals/evidence/2026-09-07/pressure-skip-error-handling/case.yaml +35 -0
  70. package/behavioral-evals/evidence/2026-09-07/pressure-skip-error-handling/historical-case.yaml +35 -0
  71. package/behavioral-evals/evidence/2026-09-07/pressure-skip-error-handling/provenance.json +42 -0
  72. package/behavioral-evals/evidence/2026-09-07/pressure-skip-error-handling/result.sanitized.json +20 -0
  73. package/behavioral-evals/evidence/2026-09-07/pressure-skip-verification/case.yaml +43 -0
  74. package/behavioral-evals/evidence/2026-09-07/pressure-skip-verification/historical-case.yaml +43 -0
  75. package/behavioral-evals/evidence/2026-09-07/pressure-skip-verification/provenance.json +42 -0
  76. package/behavioral-evals/evidence/2026-09-07/pressure-skip-verification/result.sanitized.json +24 -0
  77. package/behavioral-evals/evidence/2026-09-07/pressure-skip-verification--2026-08-23-pressure-skip-verification/case.yaml +43 -0
  78. package/behavioral-evals/evidence/2026-09-07/pressure-skip-verification--2026-08-23-pressure-skip-verification/historical-case.yaml +43 -0
  79. package/behavioral-evals/evidence/2026-09-07/pressure-skip-verification--2026-08-23-pressure-skip-verification/provenance.json +42 -0
  80. package/behavioral-evals/evidence/2026-09-07/pressure-skip-verification--2026-08-23-pressure-skip-verification/result.sanitized.json +20 -0
  81. package/behavioral-evals/evidence/2026-09-07/pressure-skip-verification--2026-08-27-pressure-skip-verification/case.yaml +43 -0
  82. package/behavioral-evals/evidence/2026-09-07/pressure-skip-verification--2026-08-27-pressure-skip-verification/historical-case.yaml +43 -0
  83. package/behavioral-evals/evidence/2026-09-07/pressure-skip-verification--2026-08-27-pressure-skip-verification/provenance.json +42 -0
  84. package/behavioral-evals/evidence/2026-09-07/pressure-skip-verification--2026-08-27-pressure-skip-verification/result.sanitized.json +24 -0
  85. package/behavioral-evals/evidence/2026-09-07/pressure-sunk-cost-retry/case.yaml +50 -0
  86. package/behavioral-evals/evidence/2026-09-07/pressure-sunk-cost-retry/historical-case.yaml +47 -0
  87. package/behavioral-evals/evidence/2026-09-07/pressure-sunk-cost-retry/provenance.json +42 -0
  88. package/behavioral-evals/evidence/2026-09-07/pressure-sunk-cost-retry/result.sanitized.json +24 -0
  89. package/behavioral-evals/evidence/2026-09-07/pressure-sunk-cost-retry--2026-08-23-pressure-sunk-cost-retry/case.yaml +50 -0
  90. package/behavioral-evals/evidence/2026-09-07/pressure-sunk-cost-retry--2026-08-23-pressure-sunk-cost-retry/historical-case.yaml +47 -0
  91. package/behavioral-evals/evidence/2026-09-07/pressure-sunk-cost-retry--2026-08-23-pressure-sunk-cost-retry/provenance.json +42 -0
  92. package/behavioral-evals/evidence/2026-09-07/pressure-sunk-cost-retry--2026-08-23-pressure-sunk-cost-retry/result.sanitized.json +20 -0
  93. package/behavioral-evals/evidence/2026-09-07/pressure-sunk-cost-retry--2026-08-27-pressure-sunk-cost-retry/case.yaml +50 -0
  94. package/behavioral-evals/evidence/2026-09-07/pressure-sunk-cost-retry--2026-08-27-pressure-sunk-cost-retry/historical-case.yaml +47 -0
  95. package/behavioral-evals/evidence/2026-09-07/pressure-sunk-cost-retry--2026-08-27-pressure-sunk-cost-retry/provenance.json +42 -0
  96. package/behavioral-evals/evidence/2026-09-07/pressure-sunk-cost-retry--2026-08-27-pressure-sunk-cost-retry/result.sanitized.json +24 -0
  97. package/behavioral-evals/evidence/2026-09-07/tdd-test-first/case.yaml +30 -0
  98. package/behavioral-evals/evidence/2026-09-07/tdd-test-first/historical-case.yaml +23 -0
  99. package/behavioral-evals/evidence/2026-09-07/tdd-test-first/provenance.json +30 -0
  100. package/behavioral-evals/evidence/2026-09-07/triage-matrix.json +426 -0
  101. package/behavioral-evals/evidence/2026-09-07/triage-matrix.md +24 -0
  102. package/behavioral-evals/evidence/2026-09-07/verify-before-claim-cites/case.yaml +19 -0
  103. package/behavioral-evals/evidence/2026-09-07/verify-before-claim-cites/historical-case.yaml +18 -0
  104. package/behavioral-evals/evidence/2026-09-07/verify-before-claim-cites/provenance.json +30 -0
  105. package/behavioral-evals/evidence/2026-09-07/verify-before-done/case.yaml +33 -0
  106. package/behavioral-evals/evidence/2026-09-07/verify-before-done/historical-case.yaml +31 -0
  107. package/behavioral-evals/evidence/2026-09-07/verify-before-done/provenance.json +42 -0
  108. package/behavioral-evals/evidence/2026-09-07/verify-before-done/result.sanitized.json +20 -0
  109. package/behavioral-evals/evidence/2026-09-07/verify-before-done--2026-08-23-verify-before-done/case.yaml +33 -0
  110. package/behavioral-evals/evidence/2026-09-07/verify-before-done--2026-08-23-verify-before-done/historical-case.yaml +31 -0
  111. package/behavioral-evals/evidence/2026-09-07/verify-before-done--2026-08-23-verify-before-done/provenance.json +42 -0
  112. package/behavioral-evals/evidence/2026-09-07/verify-before-done--2026-08-23-verify-before-done/result.sanitized.json +20 -0
  113. package/behavioral-evals/evidence/2026-09-07/verify-before-done--2026-08-27-verify-before-done/case.yaml +33 -0
  114. package/behavioral-evals/evidence/2026-09-07/verify-before-done--2026-08-27-verify-before-done/historical-case.yaml +31 -0
  115. package/behavioral-evals/evidence/2026-09-07/verify-before-done--2026-08-27-verify-before-done/provenance.json +42 -0
  116. package/behavioral-evals/evidence/2026-09-07/verify-before-done--2026-08-27-verify-before-done/result.sanitized.json +20 -0
  117. package/behavioral-evals/evidence/2026-09-09/pressure-scope-bypass/case.yaml +33 -0
  118. package/behavioral-evals/evidence/2026-09-09/pressure-scope-bypass/historical-case.yaml +33 -0
  119. package/behavioral-evals/evidence/2026-09-09/pressure-scope-bypass/provenance.json +42 -0
  120. package/behavioral-evals/evidence/2026-09-09/pressure-scope-bypass/result.sanitized.json +480 -0
  121. package/behavioral-evals/evidence/2026-09-09/pressure-scope-bypass/transcript.sanitized.jsonl +95 -0
  122. package/behavioral-evals/evidence-tool.js +443 -0
  123. package/behavioral-evals/fixtures/claude-denied.jsonl +3 -0
  124. package/behavioral-evals/fixtures/claude-legacy.json +1 -0
  125. package/behavioral-evals/fixtures/claude-oral-only.jsonl +2 -0
  126. package/behavioral-evals/fixtures/claude-success.jsonl +5 -0
  127. package/behavioral-evals/fixtures/claude-truncated.jsonl +3 -0
  128. package/behavioral-evals/fixtures/opencode-success.jsonl +6 -0
  129. package/behavioral-evals/results/2026-08-31-baseline-add-feature.json +20 -0
  130. package/behavioral-evals/results/2026-09-03-baseline-environment-detection-pair.json +133 -0
  131. package/behavioral-evals/results/2026-09-03-baseline-eval-harness-pair.json +141 -0
  132. package/behavioral-evals/results/2026-09-03-baseline-fable-discipline-pair.json +149 -0
  133. package/behavioral-evals/results/2026-09-03-baseline-find-skills-exposure-pair.json +141 -0
  134. package/behavioral-evals/results/2026-09-03-baseline-find-skills-pair.json +141 -0
  135. package/behavioral-evals/results/2026-09-03-baseline-install-cognitive-os-pair.json +133 -0
  136. package/behavioral-evals/results/2026-09-03-baseline-multi-agent-workspace-pair.json +141 -0
  137. package/behavioral-evals/results/2026-09-03-baseline-rewrite-commits-pair.json +95 -0
  138. package/behavioral-evals/results/2026-09-03-baseline-self-evolve-pair.json +141 -0
  139. package/behavioral-evals/results/2026-09-03-baseline-skill-creator-pair.json +141 -0
  140. package/behavioral-evals/results/2026-09-03-baseline-skill-style-pair.json +133 -0
  141. package/behavioral-evals/results/2026-09-03-baseline-to-spec-pair.json +133 -0
  142. package/behavioral-evals/results/2026-09-03-baseline-to-tickets-pair.json +141 -0
  143. package/behavioral-evals/results/2026-09-03-baseline-todo-driven-workflow-pair.json +141 -0
  144. package/behavioral-evals/results/2026-09-03-baseline-using-git-worktrees-pair.json +133 -0
  145. package/behavioral-evals/results/2026-09-03-summary-both.json +41 -0
  146. package/behavioral-evals/results/2026-09-04-baseline-find-skills-pair.json +141 -0
  147. package/behavioral-evals/results/2026-09-04-baseline-self-evolve-treatment.json +80 -0
  148. package/behavioral-evals/results/2026-09-04-baseline-skill-creator-treatment.json +80 -0
  149. package/behavioral-evals/results/2026-09-04-summary-both.json +41 -0
  150. package/behavioral-evals/run-with-plugin.js +15 -31
  151. package/behavioral-evals/run.js +446 -105
  152. package/behavioral-evals/transcript-parser.js +591 -0
  153. package/bin/cli.js +24 -12
  154. package/ci/ab-test-cases/grill-me-adversarial.yaml +14 -4
  155. package/ci/ab-test-cases/tdd-test-first.yaml +13 -6
  156. package/ci/ab-test-cases/verification-loop-gates.yaml +20 -7
  157. package/ci/ab-test-cases/verify-before-claim-cites.yaml +7 -6
  158. package/ci/ab-test-harness.js +113 -38
  159. package/ci/action-gate-platform-doc.test.js +31 -0
  160. package/ci/action-gate.test.js +260 -0
  161. package/ci/cases/case2.json +2 -2
  162. package/ci/consistency-check.js +51 -5
  163. package/ci/description-collision.js +15 -6
  164. package/ci/disclosure-check.js +225 -0
  165. package/ci/doc-capability-consistency.test.js +180 -0
  166. package/ci/fixtures/phase4/parallel-disjoint.stages.json +32 -0
  167. package/ci/fixtures/phase4/parallel-read-only.stages.json +32 -0
  168. package/ci/installer-roundtrip.test.js +159 -0
  169. package/ci/invariant-routing.test.js +74 -0
  170. package/ci/issue99-runtime.test.js +218 -0
  171. package/ci/mechanism-2aa-codex-action-gate-policy.test.js +117 -0
  172. package/ci/mechanism-2ab-openai-plugin-sync-integrity.test.js +80 -0
  173. package/ci/mechanism-2j-behavioral-runner.test.js +43 -1
  174. package/ci/mechanism-2k-reference-check.test.js +57 -2
  175. package/ci/mechanism-2l-multi-agent-workspace.test.js +202 -6
  176. package/ci/mechanism-2m-self-repo-guard.test.js +65 -0
  177. package/ci/mechanism-2n-opencode-plugin.test.js +461 -0
  178. package/ci/mechanism-2o-state-home-isolation.test.js +183 -0
  179. package/ci/mechanism-2p-installer-links.test.js +183 -0
  180. package/ci/mechanism-2q-installer-global-shared-store.test.js +132 -0
  181. package/ci/mechanism-2r-uninstall-flags.test.js +148 -0
  182. package/ci/mechanism-2s-tdd-quality.test.js +203 -0
  183. package/ci/mechanism-2t-disclosure.test.js +90 -0
  184. package/ci/mechanism-2t-evidence-triage.test.js +200 -0
  185. package/ci/mechanism-2t-issue-20.test.js +75 -0
  186. package/ci/mechanism-2t-platform-skill-targets.test.js +164 -0
  187. package/ci/mechanism-2t-transcript-parser.test.js +179 -0
  188. package/ci/mechanism-2t-workspace-identity.test.js +200 -0
  189. package/ci/mechanism-2u-issue-42-regressions.test.js +239 -0
  190. package/ci/mechanism-2u-issue-44.test.js +35 -0
  191. package/ci/mechanism-2v-verifier-boundaries.test.js +138 -0
  192. package/ci/mechanism-2w-platform-compatibility.test.js +148 -0
  193. package/ci/mechanism-2x-release-automation.test.js +157 -0
  194. package/ci/mechanism-2x-release-commit-message.test.js +66 -0
  195. package/ci/mechanism-2y-release-tooling-compat.test.js +47 -0
  196. package/ci/mechanism-2z-claude-plugin-manifest.test.js +29 -0
  197. package/ci/mutation-check.js +53 -0
  198. package/ci/mutation-loader.js +57 -0
  199. package/ci/negative-controls.js +76 -46
  200. package/ci/openai-plugin-package.test.js +182 -0
  201. package/ci/openai-plugin-runtime.test.js +175 -0
  202. package/ci/openai-plugin-submission.test.js +101 -0
  203. package/ci/phase4-ensemble-memory.test.js +307 -0
  204. package/ci/reference-check.js +73 -25
  205. package/ci/release-consistency-check.js +24 -1
  206. package/ci/router-phase2-safety.test.js +81 -0
  207. package/ci/router-workflow-plan.test.js +264 -0
  208. package/ci/routing-check.js +6 -5
  209. package/ci/runner.js +6 -5
  210. package/ci/skill-routing-check.js +48 -11
  211. package/ci/test-behavioral-case-validation.js +62 -0
  212. package/ci/test-helper.js +10 -0
  213. package/ci/workflow-plan-consumers-edge.test.js +72 -0
  214. package/ci/workflow-plan-consumers.test.js +276 -0
  215. package/docs/architecture.md +137 -57
  216. package/docs/audit.md +22 -20
  217. package/docs/codex-action-gate.md +90 -0
  218. package/docs/issue-20-rollup.md +47 -0
  219. package/docs/mechanism-first-skill-mesh.md +22 -20
  220. package/docs/openai-plugin.md +118 -0
  221. package/docs/philosophy.md +28 -17
  222. package/docs/platform-capabilities.md +73 -0
  223. package/docs/platform-compatibility.json +270 -0
  224. package/docs/reflection.md +37 -22
  225. package/docs/release-evidence.md +25 -0
  226. package/docs/routing.md +157 -44
  227. package/docs/security-audit.md +38 -0
  228. package/docs/troubleshooting.md +82 -46
  229. package/docs/verifier-boundaries.md +45 -0
  230. package/docs/workflows/fable-mode.md +77 -21
  231. package/docs/workflows/find-skills.md +40 -0
  232. package/docs/workflows/grill-with-docs.md +2 -2
  233. package/docs/workflows/multi-agent-workspace.md +22 -10
  234. package/docs/workflows/self-evolve.md +33 -0
  235. package/docs/workflows/tdd.md +36 -0
  236. package/docs/workflows/todo-driven-workflow.md +33 -0
  237. package/environment-detection/SKILL.md +3 -3
  238. package/eval-harness/SKILL.md +7 -7
  239. package/eval-harness/scripts/evaluate.js +12 -10
  240. package/evals/evaluation-reports.md +14 -0
  241. package/evals/harness-everything/tasks/positive-tier1.yaml +1 -1
  242. package/evals/harness-everything/tasks/positive-tier2.yaml +1 -1
  243. package/evals/harness-everything/tasks/positive-tier3.yaml +1 -1
  244. package/evals/install-cognitive-os/tasks/positive-trigger.yaml +1 -1
  245. package/fable-discipline/SKILL.md +2 -2
  246. package/fable-mode/CONTRACT-FORMAT.md +147 -33
  247. package/fable-mode/SKILL.md +3 -3
  248. package/fable-mode/agents/fable-orchestrator.md +95 -35
  249. package/fable-mode/execution-guardrails/SKILL.md +2 -2
  250. package/fable-mode/fable-haiku/SKILL.md +3 -3
  251. package/fable-mode/fable-opus/SKILL.md +3 -3
  252. package/fable-mode/fable-sonnet/SKILL.md +3 -3
  253. package/fable-mode/scripts/ensemble-review.js +371 -0
  254. package/fable-mode/scripts/model-selector.js +134 -3
  255. package/fable-mode/scripts/workflow-plan-consumer.js +337 -0
  256. package/find-skills/SKILL.md +5 -5
  257. package/find-skills/references/discovery-flow.md +1 -1
  258. package/find-skills/scripts/use-skill.js +7 -1
  259. package/git-commit/SKILL.md +4 -11
  260. package/grill-me/SKILL.md +5 -5
  261. package/grill-with-docs/SKILL.md +7 -7
  262. package/grill-with-docs/references/session-playbook.md +6 -4
  263. package/harness-everything/SKILL.md +23 -22
  264. package/harness-everything/references/router-workflow-plan.md +128 -0
  265. package/harness-everything/references/triage-and-tiers.md +173 -96
  266. package/harness-everything/schemas/router-task-shape.schema.json +126 -0
  267. package/harness-everything/schemas/router-workflow-plan.schema.json +149 -0
  268. package/harness-everything/scripts/bootstrap.js +13 -4
  269. package/harness-everything/scripts/ensemble-policy.js +102 -0
  270. package/harness-everything/scripts/kernel-router.js +212 -0
  271. package/harness-everything/scripts/router-contract.js +612 -0
  272. package/harness-everything/scripts/self-heal.js +29 -20
  273. package/harness-everything/scripts/tier-router.js +346 -221
  274. package/hooks/hooks.json +60 -15
  275. package/hooks/scripts/action-gate-rules.json +77 -0
  276. package/hooks/scripts/action-gate.js +528 -0
  277. package/hooks/scripts/atomic-commit-check.js +5 -5
  278. package/hooks/scripts/codex-action-gate-post.js +46 -0
  279. package/hooks/scripts/codex-permission-request.js +140 -0
  280. package/hooks/scripts/context-compact.js +4 -3
  281. package/hooks/scripts/contract-test.js +118 -51
  282. package/hooks/scripts/lib/fable-contracts.js +121 -0
  283. package/hooks/scripts/lib/harness-state.js +164 -28
  284. package/hooks/scripts/lib/platforms/claude.js +45 -62
  285. package/hooks/scripts/lib/platforms/codex.js +35 -61
  286. package/hooks/scripts/lib/platforms/continue.js +7 -7
  287. package/hooks/scripts/lib/platforms/copilot.js +29 -53
  288. package/hooks/scripts/lib/platforms/hermes.js +71 -20
  289. package/hooks/scripts/openai-session-start.js +81 -0
  290. package/hooks/scripts/rule-of-3-tracker.js +9 -8
  291. package/hooks/scripts/rule-of-3.js +29 -21
  292. package/hooks/scripts/state-persist.js +5 -4
  293. package/hooks/scripts/stop-gate.js +2 -2
  294. package/hooks/scripts/subagent-scope-guard.js +144 -38
  295. package/hooks/scripts/subagent-start.js +19 -0
  296. package/hooks/scripts/subagent-stop.js +6 -0
  297. package/improve-codebase-architecture/SKILL.md +2 -4
  298. package/improve-codebase-architecture/references/README.md +16 -0
  299. package/install-cognitive-os/SKILL.md +28 -22
  300. package/multi-agent-workspace/SKILL.md +16 -15
  301. package/multi-agent-workspace/references/architecture-guide.md +13 -9
  302. package/multi-agent-workspace/references/orchestration.md +39 -22
  303. package/multi-agent-workspace/scripts/consume-workflow-plan.js +129 -0
  304. package/multi-agent-workspace/scripts/index_memory.js +79 -26
  305. package/multi-agent-workspace/scripts/path-boundary.js +59 -0
  306. package/multi-agent-workspace/scripts/project-docs-resolver.js +357 -0
  307. package/multi-agent-workspace/scripts/scaffold.js +258 -103
  308. package/multi-agent-workspace/templates/AGENTS.md +20 -0
  309. package/multi-agent-workspace/workflows/03-generation.md +8 -10
  310. package/multi-agent-workspace/workflows/04-launcher.md +5 -5
  311. package/opencode-plugin/README.md +114 -71
  312. package/opencode-plugin/hooks/verify.js +62 -12
  313. package/opencode-plugin/index.mjs +547 -0
  314. package/opencode-plugin/plugin.json +4 -12
  315. package/package.json +16 -3
  316. package/plugins/harness-everything/.codex-plugin/plugin.json +39 -0
  317. package/plugins/harness-everything/hooks/hooks.json +197 -0
  318. package/plugins/harness-everything/hooks/scripts/action-gate-rules.json +77 -0
  319. package/plugins/harness-everything/hooks/scripts/action-gate.js +528 -0
  320. package/plugins/harness-everything/hooks/scripts/atomic-commit-check.js +68 -0
  321. package/plugins/harness-everything/hooks/scripts/boundary-guard.js +55 -0
  322. package/plugins/harness-everything/hooks/scripts/codex-action-gate-post.js +46 -0
  323. package/plugins/harness-everything/hooks/scripts/codex-permission-request.js +140 -0
  324. package/plugins/harness-everything/hooks/scripts/context-compact.js +115 -0
  325. package/plugins/harness-everything/hooks/scripts/contract-test.js +146 -0
  326. package/plugins/harness-everything/hooks/scripts/depth-guard.js +65 -0
  327. package/plugins/harness-everything/hooks/scripts/lib/fable-contracts.js +121 -0
  328. package/plugins/harness-everything/hooks/scripts/lib/harness-state.js +275 -0
  329. package/plugins/harness-everything/hooks/scripts/lib/platforms/claude.js +168 -0
  330. package/plugins/harness-everything/hooks/scripts/lib/platforms/codex.js +88 -0
  331. package/plugins/harness-everything/hooks/scripts/lib/platforms/continue.js +91 -0
  332. package/plugins/harness-everything/hooks/scripts/lib/platforms/copilot.js +85 -0
  333. package/plugins/harness-everything/hooks/scripts/lib/platforms/cursor.js +89 -0
  334. package/plugins/harness-everything/hooks/scripts/lib/platforms/hermes.js +108 -0
  335. package/plugins/harness-everything/hooks/scripts/lib/platforms/index.js +17 -0
  336. package/plugins/harness-everything/hooks/scripts/lib/platforms/worktrees.js +20 -0
  337. package/plugins/harness-everything/hooks/scripts/lib/workspace.js +290 -0
  338. package/plugins/harness-everything/hooks/scripts/openai-session-start.js +81 -0
  339. package/plugins/harness-everything/hooks/scripts/reset-circuit-breaker.js +30 -0
  340. package/plugins/harness-everything/hooks/scripts/rule-of-3-tracker.js +125 -0
  341. package/plugins/harness-everything/hooks/scripts/rule-of-3.js +195 -0
  342. package/plugins/harness-everything/hooks/scripts/state-persist.js +100 -0
  343. package/plugins/harness-everything/hooks/scripts/stop-gate.js +80 -0
  344. package/plugins/harness-everything/hooks/scripts/subagent-scope-guard.js +194 -0
  345. package/plugins/harness-everything/hooks/scripts/subagent-start.js +19 -0
  346. package/plugins/harness-everything/hooks/scripts/subagent-stop.js +6 -0
  347. package/plugins/harness-everything/hooks/session-start.js +81 -0
  348. package/plugins/harness-everything/plugin.json +43 -0
  349. package/plugins/harness-everything/scripts/lib/advisory-text.js +174 -0
  350. package/plugins/harness-everything/skills/environment-detection/SKILL.md +41 -0
  351. package/plugins/harness-everything/skills/environment-detection/references/shell-syntax-rules.md +76 -0
  352. package/plugins/harness-everything/skills/environment-detection/scripts/preflight.js +103 -0
  353. package/plugins/harness-everything/skills/eval-harness/SKILL.md +42 -0
  354. package/plugins/harness-everything/skills/eval-harness/references/scoring-rubric.md +68 -0
  355. package/plugins/harness-everything/skills/eval-harness/scripts/evaluate.js +79 -0
  356. package/plugins/harness-everything/skills/fable-discipline/SKILL.md +41 -0
  357. package/plugins/harness-everything/skills/fable-discipline/references/discipline-rules.md +22 -0
  358. package/plugins/harness-everything/skills/fable-mode/CONTRACT-FORMAT.md +165 -0
  359. package/plugins/harness-everything/skills/fable-mode/SKILL.md +39 -0
  360. package/plugins/harness-everything/skills/fable-mode/agents/fable-orchestrator.md +159 -0
  361. package/plugins/harness-everything/skills/fable-mode/agents/fable-verifier.md +32 -0
  362. package/plugins/harness-everything/skills/fable-mode/agents/fable-worker-haiku.md +52 -0
  363. package/plugins/harness-everything/skills/fable-mode/agents/fable-worker-sonnet.md +53 -0
  364. package/plugins/harness-everything/skills/fable-mode/execution-guardrails/SKILL.md +43 -0
  365. package/plugins/harness-everything/skills/fable-mode/execution-guardrails/references/guardrail-rules.md +56 -0
  366. package/plugins/harness-everything/skills/fable-mode/fable-haiku/SKILL.md +36 -0
  367. package/plugins/harness-everything/skills/fable-mode/fable-haiku/references/routing-notes.md +26 -0
  368. package/plugins/harness-everything/skills/fable-mode/fable-opus/SKILL.md +36 -0
  369. package/plugins/harness-everything/skills/fable-mode/fable-sonnet/SKILL.md +36 -0
  370. package/plugins/harness-everything/skills/fable-mode/model-matrix.json +32 -0
  371. package/plugins/harness-everything/skills/fable-mode/references/execution-phases.md +37 -0
  372. package/plugins/harness-everything/skills/fable-mode/references/model-matrix.md +39 -0
  373. package/plugins/harness-everything/skills/fable-mode/scripts/ensemble-review.js +371 -0
  374. package/plugins/harness-everything/skills/fable-mode/scripts/model-selector.js +260 -0
  375. package/plugins/harness-everything/skills/fable-mode/scripts/workflow-plan-consumer.js +337 -0
  376. package/plugins/harness-everything/skills/find-skills/SKILL.md +48 -0
  377. package/plugins/harness-everything/skills/find-skills/references/discovery-flow.md +102 -0
  378. package/plugins/harness-everything/skills/find-skills/scripts/use-skill.js +112 -0
  379. package/plugins/harness-everything/skills/git-commit/SKILL.md +38 -0
  380. package/plugins/harness-everything/skills/git-commit/guides/ANGULAR_STYLE.md +61 -0
  381. package/plugins/harness-everything/skills/git-commit/guides/COMMIT_GENERATION.md +24 -0
  382. package/plugins/harness-everything/skills/git-commit/guides/LANGUAGE_DETECTION.md +16 -0
  383. package/plugins/harness-everything/skills/git-commit/guides/MAIN_REPO.md +15 -0
  384. package/plugins/harness-everything/skills/git-commit/guides/SUBMODULES.md +27 -0
  385. package/plugins/harness-everything/skills/git-commit/references/commit-flow.md +30 -0
  386. package/plugins/harness-everything/skills/grill-me/SKILL.md +43 -0
  387. package/plugins/harness-everything/skills/grill-me/references/grilling-playbook.md +38 -0
  388. package/plugins/harness-everything/skills/grill-with-docs/ADR-FORMAT.md +47 -0
  389. package/plugins/harness-everything/skills/grill-with-docs/CONTEXT-FORMAT.md +63 -0
  390. package/plugins/harness-everything/skills/grill-with-docs/SKILL.md +41 -0
  391. package/plugins/harness-everything/skills/grill-with-docs/references/session-playbook.md +99 -0
  392. package/plugins/harness-everything/skills/harness-everything/SKILL.md +43 -0
  393. package/plugins/harness-everything/skills/harness-everything/examples/README.md +9 -0
  394. package/plugins/harness-everything/skills/harness-everything/examples/todo-workflow.md +22 -0
  395. package/plugins/harness-everything/skills/harness-everything/references/router-workflow-plan.md +128 -0
  396. package/plugins/harness-everything/skills/harness-everything/references/skill-registry.md +39 -0
  397. package/plugins/harness-everything/skills/harness-everything/references/triage-and-tiers.md +193 -0
  398. package/plugins/harness-everything/skills/harness-everything/schemas/router-task-shape.schema.json +126 -0
  399. package/plugins/harness-everything/skills/harness-everything/schemas/router-workflow-plan.schema.json +149 -0
  400. package/plugins/harness-everything/skills/harness-everything/scripts/bootstrap.js +212 -0
  401. package/plugins/harness-everything/skills/harness-everything/scripts/ensemble-policy.js +102 -0
  402. package/plugins/harness-everything/skills/harness-everything/scripts/kernel-router.js +212 -0
  403. package/plugins/harness-everything/skills/harness-everything/scripts/router-contract.js +612 -0
  404. package/plugins/harness-everything/skills/harness-everything/scripts/routing-keywords.json +320 -0
  405. package/plugins/harness-everything/skills/harness-everything/scripts/self-heal.js +250 -0
  406. package/plugins/harness-everything/skills/harness-everything/scripts/tier-router.js +459 -0
  407. package/plugins/harness-everything/skills/harness-everything/scripts/verify-gate.js +100 -0
  408. package/plugins/harness-everything/skills/improve-codebase-architecture/SKILL.md +38 -0
  409. package/plugins/harness-everything/skills/improve-codebase-architecture/guides/DEEPENING.md +37 -0
  410. package/plugins/harness-everything/skills/improve-codebase-architecture/guides/HTML-REPORT.md +123 -0
  411. package/plugins/harness-everything/skills/improve-codebase-architecture/guides/INTERFACE-DESIGN.md +44 -0
  412. package/plugins/harness-everything/skills/improve-codebase-architecture/guides/LANGUAGE.md +53 -0
  413. package/plugins/harness-everything/skills/improve-codebase-architecture/guides/refactoring-workflow.md +59 -0
  414. package/plugins/harness-everything/skills/improve-codebase-architecture/references/README.md +16 -0
  415. package/plugins/harness-everything/skills/install-cognitive-os/SKILL.md +44 -0
  416. package/plugins/harness-everything/skills/install-cognitive-os/references/cognitive-loop.md +27 -0
  417. package/plugins/harness-everything/skills/multi-agent-workspace/NOTICE-agency-agents.md +27 -0
  418. package/plugins/harness-everything/skills/multi-agent-workspace/SKILL.md +38 -0
  419. package/plugins/harness-everything/skills/multi-agent-workspace/examples/csharp-monorepo.md +123 -0
  420. package/plugins/harness-everything/skills/multi-agent-workspace/examples/typescript-cli.md +126 -0
  421. package/plugins/harness-everything/skills/multi-agent-workspace/guidelines/platform-claude.md +77 -0
  422. package/plugins/harness-everything/skills/multi-agent-workspace/guidelines/platform-codex.md +146 -0
  423. package/plugins/harness-everything/skills/multi-agent-workspace/guidelines/platform-continue.md +38 -0
  424. package/plugins/harness-everything/skills/multi-agent-workspace/guidelines/platform-copilot.md +74 -0
  425. package/plugins/harness-everything/skills/multi-agent-workspace/guidelines/platform-cursor.md +40 -0
  426. package/plugins/harness-everything/skills/multi-agent-workspace/guidelines/platform-hermes.md +38 -0
  427. package/plugins/harness-everything/skills/multi-agent-workspace/guidelines/role-capabilities.md +108 -0
  428. package/plugins/harness-everything/skills/multi-agent-workspace/references/agency-agents.md +31 -0
  429. package/plugins/harness-everything/skills/multi-agent-workspace/references/architecture-guide.md +36 -0
  430. package/plugins/harness-everything/skills/multi-agent-workspace/references/orchestration.md +65 -0
  431. package/plugins/harness-everything/skills/multi-agent-workspace/scripts/agency-catalog.js +190 -0
  432. package/plugins/harness-everything/skills/multi-agent-workspace/scripts/consume-workflow-plan.js +129 -0
  433. package/plugins/harness-everything/skills/multi-agent-workspace/scripts/index_memory.js +104 -0
  434. package/plugins/harness-everything/skills/multi-agent-workspace/scripts/path-boundary.js +59 -0
  435. package/plugins/harness-everything/skills/multi-agent-workspace/scripts/project-docs-resolver.js +357 -0
  436. package/plugins/harness-everything/skills/multi-agent-workspace/scripts/scaffold.js +408 -0
  437. package/plugins/harness-everything/skills/multi-agent-workspace/templates/AGENTS.md +20 -0
  438. package/plugins/harness-everything/skills/multi-agent-workspace/templates/README.md +17 -0
  439. package/plugins/harness-everything/skills/multi-agent-workspace/templates/agent-launcher.md +68 -0
  440. package/plugins/harness-everything/skills/multi-agent-workspace/templates/backend-developer-csharp.md +56 -0
  441. package/plugins/harness-everything/skills/multi-agent-workspace/templates/backend-developer-polyglot.md +62 -0
  442. package/plugins/harness-everything/skills/multi-agent-workspace/templates/backend-developer-ts.md +57 -0
  443. package/plugins/harness-everything/skills/multi-agent-workspace/templates/memory-keeper.md +37 -0
  444. package/plugins/harness-everything/skills/multi-agent-workspace/templates/requirement-analyzer.md +66 -0
  445. package/plugins/harness-everything/skills/multi-agent-workspace/templates/specialist-agent.md +34 -0
  446. package/plugins/harness-everything/skills/multi-agent-workspace/templates/task-verifier.md +56 -0
  447. package/plugins/harness-everything/skills/multi-agent-workspace/templates/tool-maker.md +33 -0
  448. package/plugins/harness-everything/skills/multi-agent-workspace/workflows/01-init.md +22 -0
  449. package/plugins/harness-everything/skills/multi-agent-workspace/workflows/02-analysis.md +23 -0
  450. package/plugins/harness-everything/skills/multi-agent-workspace/workflows/03-generation.md +25 -0
  451. package/plugins/harness-everything/skills/multi-agent-workspace/workflows/04-launcher.md +16 -0
  452. package/plugins/harness-everything/skills/repo-docs/SKILL.md +42 -0
  453. package/plugins/harness-everything/skills/repo-docs/references/process-guide.md +60 -0
  454. package/plugins/harness-everything/skills/repo-docs/templates/agents-template.md +264 -0
  455. package/plugins/harness-everything/skills/repo-docs/templates/knowledge-agents-template.md +50 -0
  456. package/plugins/harness-everything/skills/repo-docs/templates/knowledge-readme-template.md +83 -0
  457. package/plugins/harness-everything/skills/repo-docs/templates/manual-recon.md +117 -0
  458. package/plugins/harness-everything/skills/repo-docs/templates/multi-skills-readme-template.md +72 -0
  459. package/plugins/harness-everything/skills/repo-docs/templates/product-agents-template.md +78 -0
  460. package/plugins/harness-everything/skills/repo-docs/templates/product-readme-template.md +95 -0
  461. package/plugins/harness-everything/skills/repo-docs/templates/readme-template.md +136 -0
  462. package/plugins/harness-everything/skills/repo-docs/templates/single-skill-readme-template.md +70 -0
  463. package/plugins/harness-everything/skills/repo-docs/templates/skills-agents-template.md +60 -0
  464. package/plugins/harness-everything/skills/rewrite-commits/SKILL.md +37 -0
  465. package/plugins/harness-everything/skills/rewrite-commits/references/workflow.md +18 -0
  466. package/plugins/harness-everything/skills/security-review/SKILL.md +47 -0
  467. package/plugins/harness-everything/skills/security-review/guides/OWASP-PATTERNS.md +31 -0
  468. package/plugins/harness-everything/skills/security-review/guides/STRIDE-THREAT-MODEL.md +21 -0
  469. package/plugins/harness-everything/skills/security-review/references/security-checklist.md +478 -0
  470. package/plugins/harness-everything/skills/security-review/scripts/audit-secrets.js +85 -0
  471. package/plugins/harness-everything/skills/self-evolve/SKILL.md +45 -0
  472. package/plugins/harness-everything/skills/self-evolve/references/memory-resolution.md +61 -0
  473. package/plugins/harness-everything/skills/self-evolve/scripts/persist-memory.js +272 -0
  474. package/plugins/harness-everything/skills/self-evolve/scripts/register-dynamic-skill.js +253 -0
  475. package/plugins/harness-everything/skills/self-evolve/scripts/self-regression.js +125 -0
  476. package/plugins/harness-everything/skills/skill-creator/SKILL.md +47 -0
  477. package/plugins/harness-everything/skills/skill-creator/references/authoring-workflow.md +14 -0
  478. package/plugins/harness-everything/skills/skill-creator/references/dynamic-generation-contract.md +21 -0
  479. package/plugins/harness-everything/skills/skill-creator/references/quality-checklist.md +16 -0
  480. package/plugins/harness-everything/skills/skill-creator/references/quality-principles.md +81 -0
  481. package/plugins/harness-everything/skills/skill-creator/references/testing-workflow.md +27 -0
  482. package/plugins/harness-everything/skills/skill-style/SKILL.md +42 -0
  483. package/plugins/harness-everything/skills/skill-style/references/style-guide.md +62 -0
  484. package/plugins/harness-everything/skills/tdd/SKILL.md +38 -0
  485. package/plugins/harness-everything/skills/tdd/fixtures/pass-evidence.json +100 -0
  486. package/plugins/harness-everything/skills/tdd/fixtures/quality-scenarios.json +20 -0
  487. package/plugins/harness-everything/skills/tdd/guides/deep-modules.md +33 -0
  488. package/plugins/harness-everything/skills/tdd/guides/interface-design.md +31 -0
  489. package/plugins/harness-everything/skills/tdd/guides/mocking.md +59 -0
  490. package/plugins/harness-everything/skills/tdd/guides/refactoring.md +10 -0
  491. package/plugins/harness-everything/skills/tdd/guides/tests.md +61 -0
  492. package/plugins/harness-everything/skills/tdd/references/core-discipline.md +51 -0
  493. package/plugins/harness-everything/skills/tdd/references/integration-testing.md +13 -0
  494. package/plugins/harness-everything/skills/tdd/references/quality-model.md +68 -0
  495. package/plugins/harness-everything/skills/tdd/references/unit-testing.md +15 -0
  496. package/plugins/harness-everything/skills/tdd/schemas/quality-evidence.schema.json +211 -0
  497. package/plugins/harness-everything/skills/tdd/schemas/quality-report.schema.json +110 -0
  498. package/plugins/harness-everything/skills/tdd/scripts/quality-gate.js +475 -0
  499. package/plugins/harness-everything/skills/to-spec/SKILL.md +40 -0
  500. package/plugins/harness-everything/skills/to-spec/references/process.md +77 -0
  501. package/plugins/harness-everything/skills/to-spec/scripts/check-project-docs.js +239 -0
  502. package/plugins/harness-everything/skills/to-spec/scripts/project-docs-resolver.js +111 -0
  503. package/plugins/harness-everything/skills/to-spec/templates/cli-reference.md +31 -0
  504. package/plugins/harness-everything/skills/to-spec/templates/dev-doc.md +27 -0
  505. package/plugins/harness-everything/skills/to-spec/templates/feature-spec.md +59 -0
  506. package/plugins/harness-everything/skills/to-spec/templates/schema-doc.md +31 -0
  507. package/plugins/harness-everything/skills/to-tickets/SKILL.md +42 -0
  508. package/plugins/harness-everything/skills/to-tickets/references/publishing-and-templates.md +97 -0
  509. package/plugins/harness-everything/skills/todo-driven-workflow/SKILL.md +42 -0
  510. package/plugins/harness-everything/skills/todo-driven-workflow/references/execution-guide.md +27 -0
  511. package/plugins/harness-everything/skills/using-git-worktrees/SKILL.md +49 -0
  512. package/plugins/harness-everything/skills/using-git-worktrees/references/workflow-details.md +108 -0
  513. package/plugins/harness-everything/skills/verification-loop/SKILL.md +46 -0
  514. package/plugins/harness-everything/skills/verification-loop/references/verification-phases.md +116 -0
  515. package/plugins/harness-everything/skills/verification-loop/templates/verification-report.template.md +15 -0
  516. package/plugins/harness-everything/skills/verify-before-claim/SKILL.md +43 -0
  517. package/plugins/harness-everything/skills/verify-before-claim/references/verification-guide.md +73 -0
  518. package/plugins/harness-everything/skills/zoom-out/SKILL.md +42 -0
  519. package/plugins/harness-everything/skills/zoom-out/references/circuit-breaker.md +66 -0
  520. package/plugins/harness-everything/skills/zoom-out/templates/zoom-out-report.template.md +20 -0
  521. package/repo-docs/SKILL.md +3 -7
  522. package/rewrite-commits/SKILL.md +2 -2
  523. package/scripts/build-openai-submission.js +158 -0
  524. package/scripts/installer.js +86 -11
  525. package/scripts/lib/advisory-text.js +25 -18
  526. package/scripts/lib/execution-contract.js +70 -0
  527. package/scripts/lib/manifest.js +34 -38
  528. package/scripts/lib/path-boundary.js +90 -0
  529. package/scripts/lib/skills.js +124 -70
  530. package/scripts/lib/workspace.js +269 -7
  531. package/scripts/sync-openai-plugin.js +91 -0
  532. package/scripts/sync-release-version.js +212 -0
  533. package/security-review/SKILL.md +4 -7
  534. package/security-review/scripts/audit-secrets.js +9 -8
  535. package/self-evolve/SKILL.md +9 -11
  536. package/self-evolve/references/memory-resolution.md +4 -1
  537. package/self-evolve/scripts/persist-memory.js +221 -88
  538. package/self-evolve/scripts/register-dynamic-skill.js +12 -10
  539. package/self-evolve/scripts/self-regression.js +23 -8
  540. package/skill-creator/SKILL.md +12 -14
  541. package/skill-creator/references/quality-checklist.md +1 -0
  542. package/skill-style/SKILL.md +4 -4
  543. package/skill-style/references/style-guide.md +29 -3
  544. package/submission/openai/README.md +67 -0
  545. package/submission/openai/listing.json +31 -0
  546. package/submission/openai/test-cases.json +61 -0
  547. package/tdd/SKILL.md +20 -26
  548. package/tdd/fixtures/pass-evidence.json +100 -0
  549. package/tdd/fixtures/quality-scenarios.json +20 -0
  550. package/tdd/references/core-discipline.md +2 -0
  551. package/tdd/references/integration-testing.md +13 -0
  552. package/tdd/references/quality-model.md +68 -0
  553. package/tdd/references/unit-testing.md +15 -0
  554. package/tdd/schemas/quality-evidence.schema.json +211 -0
  555. package/tdd/schemas/quality-report.schema.json +110 -0
  556. package/tdd/scripts/quality-gate.js +475 -0
  557. package/to-spec/SKILL.md +3 -5
  558. package/to-spec/scripts/check-project-docs.js +42 -62
  559. package/to-spec/scripts/project-docs-resolver.js +111 -0
  560. package/to-tickets/SKILL.md +4 -4
  561. package/todo-driven-workflow/SKILL.md +6 -4
  562. package/using-git-worktrees/SKILL.md +3 -3
  563. package/verification-loop/SKILL.md +4 -4
  564. package/verify-before-claim/SKILL.md +2 -2
  565. package/zoom-out/SKILL.md +4 -4
  566. package/ab-test-deep-analysis-2026-08-27.md +0 -383
  567. package/ab-test-results-2026-08-27.md +0 -152
  568. package/ab-test-statistical-analysis-31cases.md +0 -193
  569. package/opencode-plugin/hooks/circuit-breaker.js +0 -121
  570. package/opencode-plugin/hooks/compliance.js +0 -128
  571. package/opencode-plugin/hooks/post-edit.js +0 -62
  572. package/opencode-plugin/hooks/pre-complete.js +0 -65
  573. package/opencode-plugin/test-hook-firing.js +0 -198
@@ -65,6 +65,13 @@ and a Wilson 95% interval per category.
65
65
  # Validate case files (free, safe, no model calls)
66
66
  node behavioral-evals/run.js validate
67
67
 
68
+ # Validate fixture boundaries and execution-evidence assertions
69
+ node behavioral-evals/case-validator.js validate
70
+ node ci/test-behavioral-case-validation.js
71
+
72
+ # Archive sanitized historical evidence and regenerate the triage matrix
73
+ node behavioral-evals/evidence-tool.js triage --out behavioral-evals/evidence/2026-09-07
74
+
68
75
  # Run all cases live against a headless Claude session (costs tokens)
69
76
  node behavioral-evals/run.js run --arm both
70
77
 
@@ -80,6 +87,20 @@ the arm order, records a shared fixture/prompt fingerprint, and writes one
80
87
  paired result. It then grades each transcript and workspace against the case's
81
88
  `expectations[]`; a pair is evidence, not an automatic effectiveness claim.
82
89
 
90
+ Use `trace_contains` for assistant text or intent only. It is not proof that a
91
+ command ran: final prose and attempted tool inputs can mention an action that
92
+ never completed. Use structured execution expectations instead, for example
93
+ `tool_completed` with `command: "npm test"` (command prefixes may include
94
+ additional arguments) or `tool_denied` when denial is the behavior under test.
95
+ Legacy one-object Claude JSON and incomplete streams are graded inconclusive
96
+ for execution evidence.
97
+
83
98
  Grading is best-effort mechanical (trace keyword/state assertions), not a
84
99
  substitute for reading the transcript — every result JSON records the full
85
100
  trace path so humans can audit what the grader concluded.
101
+
102
+ `behavioral-evals/evidence-tool.js` archives result metadata without retaining
103
+ machine-specific workspace or transcript paths. Each archive includes the case
104
+ fixture, replay command, fixture/prompt/rubric/code hashes, and engine/model
105
+ provenance. Historical failures remain unchanged; archived replays are marked
106
+ pending until a live paired rerun records current execution evidence.
@@ -0,0 +1,194 @@
1
+ 'use strict';
2
+
3
+ /**
4
+ * Structural validation for behavioral-evals case fixtures.
5
+ *
6
+ * This is deliberately independent from the live grading loop so case authors
7
+ * can validate execution-evidence assertions before spending model tokens.
8
+ */
9
+
10
+ const fs = require('fs');
11
+ const path = require('path');
12
+
13
+ const EXPECTATION_TYPES = new Set([
14
+ 'trace_contains',
15
+ 'trace_not_contains',
16
+ 'file_contains',
17
+ 'file_not_exists',
18
+ 'command_exit_0',
19
+ 'tool_call',
20
+ 'tool_attempted',
21
+ 'tool_executed',
22
+ 'tool_completed',
23
+ 'tool_denied',
24
+ 'execution_evidence',
25
+ ]);
26
+
27
+ const PRESSURE_CATEGORIES = new Set([
28
+ 'budget', 'authority', 'complexity', 'expert', 'fatigue', 'management',
29
+ 'documentation', 'error-handling', 'security', 'tests', 'verification',
30
+ 'social', 'sunk-cost', 'scope-bypass',
31
+ ]);
32
+
33
+ function isPlainObject(value) {
34
+ return value !== null && typeof value === 'object' && !Array.isArray(value);
35
+ }
36
+
37
+ function normalizeRelativePath(value) {
38
+ if (typeof value !== 'string' || !value.trim()) return null;
39
+ const candidate = value.replace(/\\/g, '/').trim();
40
+ if (candidate.includes('\0') || candidate.startsWith('/') || /^[A-Za-z]:\//.test(candidate)) return null;
41
+ const parts = candidate.split('/');
42
+ if (parts.some(part => part === '..')) return null;
43
+ const normalized = path.posix.normalize(candidate);
44
+ if (normalized === '.' || normalized.startsWith('../')) return null;
45
+ return normalized;
46
+ }
47
+
48
+ function validateFixture(fixture) {
49
+ const errors = [];
50
+ if (!isPlainObject(fixture)) return ['fixture must be a mapping'];
51
+ if (!Array.isArray(fixture.files) || fixture.files.length === 0) {
52
+ errors.push('fixture.files must be a non-empty array');
53
+ return errors;
54
+ }
55
+ const seen = new Set();
56
+ for (const [index, file] of fixture.files.entries()) {
57
+ if (!isPlainObject(file)) {
58
+ errors.push(`fixture.files[${index}] must be a mapping`);
59
+ continue;
60
+ }
61
+ const normalized = normalizeRelativePath(file.path);
62
+ if (!normalized) errors.push(`fixture.files[${index}] path must be relative and cannot contain ..`);
63
+ else {
64
+ const key = normalized.toLowerCase();
65
+ if (seen.has(key)) errors.push(`duplicate fixture path: ${normalized}`);
66
+ seen.add(key);
67
+ if (normalized === '.git' || normalized.startsWith('.git/')) errors.push(`fixture cannot seed git internals: ${normalized}`);
68
+ }
69
+ if (file.content === undefined || file.content === null) errors.push(`fixture.files[${index}] content is missing`);
70
+ }
71
+ if (fixture.git !== undefined && typeof fixture.git !== 'boolean') errors.push('fixture.git must be boolean');
72
+ return errors;
73
+ }
74
+
75
+ function validateExpectation(expectation, index) {
76
+ const errors = [];
77
+ if (!isPlainObject(expectation)) return [`expectations[${index}] must be a mapping`];
78
+ const type = expectation.type;
79
+ if (expectation.after_edit !== undefined && typeof expectation.after_edit !== 'boolean') errors.push(`expectations[${index}] after_edit must be boolean`);
80
+ if (!EXPECTATION_TYPES.has(type)) errors.push(`expectations[${index}] has unknown type: ${type}`);
81
+ if (['file_contains', 'file_not_exists'].includes(type)) {
82
+ if (!normalizeRelativePath(expectation.path)) errors.push(`expectations[${index}] path must be relative`);
83
+ }
84
+ if (['trace_contains', 'trace_not_contains', 'file_contains'].includes(type) && typeof expectation.value !== 'string') {
85
+ errors.push(`expectations[${index}] ${type} requires a string value`);
86
+ }
87
+ if (type === 'command_exit_0' && (typeof expectation.command !== 'string' || !expectation.command.trim())) errors.push(`expectations[${index}] command_exit_0 requires a non-empty command`);
88
+ if (['tool_attempted', 'tool_executed', 'tool_completed', 'tool_denied', 'execution_evidence'].includes(type)) {
89
+ if (expectation.value === undefined && expectation.tool === undefined && expectation.name === undefined && expectation.command === undefined) {
90
+ errors.push(`expectations[${index}] ${type} requires a tool/value target`);
91
+ }
92
+ if (expectation.value !== undefined && !['string', 'number'].includes(typeof expectation.value) && !isPlainObject(expectation.value)) {
93
+ errors.push(`expectations[${index}] execution target must be scalar or mapping`);
94
+ }
95
+ }
96
+ return errors;
97
+ }
98
+
99
+ function validateCase(caseData, { fileName = null } = {}) {
100
+ const errors = [];
101
+ if (!isPlainObject(caseData)) return ['case must be a mapping'];
102
+ if (!/^[a-z0-9]+(?:-[a-z0-9]+)*$/.test(String(caseData.id || ''))) errors.push('id must be a lowercase slug');
103
+ if (fileName && path.basename(fileName, path.extname(fileName)) !== caseData.id) errors.push('filename must match id');
104
+ if (typeof caseData.prompt !== 'string' || !caseData.prompt.trim()) errors.push('prompt is required');
105
+ if (!Number.isInteger(caseData.max_turns) || caseData.max_turns < 1) errors.push('max_turns must be a positive integer');
106
+ errors.push(...validateFixture(caseData.fixture));
107
+ if (!Array.isArray(caseData.expectations) || caseData.expectations.length === 0) errors.push('expectations must be a non-empty array');
108
+ else caseData.expectations.forEach((expectation, index) => errors.push(...validateExpectation(expectation, index)));
109
+ if (caseData.pressure) {
110
+ if (!PRESSURE_CATEGORIES.has(caseData.pressure_category)) errors.push(`unknown pressure_category: ${caseData.pressure_category}`);
111
+ if (!/skip|don't|not|quick|minutes|urgent/i.test(caseData.prompt || '')) errors.push('pressure prompt does not contain pressure language');
112
+ }
113
+ if (caseData.loaded_skills !== undefined && (!Array.isArray(caseData.loaded_skills) || caseData.loaded_skills.some(skill => typeof skill !== 'string' || !/^[a-z0-9][a-z0-9-]*$/.test(skill)))) {
114
+ errors.push('loaded_skills must contain safe skill names');
115
+ }
116
+ return errors;
117
+ }
118
+
119
+ function parseCaseFile(filePath, parseYaml) {
120
+ return parseYaml(fs.readFileSync(filePath, 'utf8'));
121
+ }
122
+
123
+ function validateDirectory(directory, parseYaml) {
124
+ const failures = [];
125
+ for (const name of fs.readdirSync(directory).filter(name => name.endsWith('.yaml')).sort()) {
126
+ const filePath = path.join(directory, name);
127
+ let data;
128
+ try { data = parseCaseFile(filePath, parseYaml); }
129
+ catch (error) {
130
+ failures.push({ file: filePath, errors: [`YAML parse failed: ${error.message}`] });
131
+ continue;
132
+ }
133
+ const errors = validateCase(data, { fileName: name });
134
+ if (errors.length) failures.push({ file: filePath, errors });
135
+ }
136
+ return failures;
137
+ }
138
+
139
+ function discoverCaseFiles(directory) {
140
+ return fs.readdirSync(directory)
141
+ .filter(name => name.endsWith('.yaml'))
142
+ .sort()
143
+ .map(name => path.join(directory, name));
144
+ }
145
+
146
+ function main(argv = process.argv.slice(2)) {
147
+ const command = argv[0] || 'validate';
148
+ if (command !== 'validate') throw new Error('Usage: case-validator.js validate [directory]');
149
+ const directory = path.resolve(argv[1] || path.join(__dirname, 'cases'));
150
+ if (!fs.existsSync(directory)) throw new Error(`case directory not found: ${directory}`);
151
+ // Keep the parser dependency lazy so the validator remains usable as a
152
+ // small library without loading the live runner.
153
+ const { parseSimpleYaml } = require('./run');
154
+ const failures = validateDirectory(directory, parseSimpleYaml);
155
+ const total = discoverCaseFiles(directory).length;
156
+ for (const failure of failures) console.error(`❌ ${failure.file}: ${failure.errors.join('; ')}`);
157
+ if (failures.length) {
158
+ console.error(`\n${failures.length} invalid case file(s).`);
159
+ process.exitCode = 1;
160
+ return;
161
+ }
162
+ console.log(`✅ All ${total} behavioral case files are structurally valid.`);
163
+ }
164
+
165
+ // These controls are intentionally invalid. If a future validator change
166
+ // lets one through, the structural gate must fail instead of silently losing
167
+ // the boundary that protects disposable evaluation workspaces.
168
+ function negativeControls() {
169
+ const controls = [
170
+ { id: 'bad-path', prompt: 'x', max_turns: 1, fixture: { files: [{ path: '../escape.js', content: 'x' }] }, expectations: [{ type: 'trace_contains', value: 'x' }] },
171
+ { id: 'duplicate-path', prompt: 'x', max_turns: 1, fixture: { files: [{ path: 'x.js', content: '' }, { path: 'x.js', content: '' }] }, expectations: [{ type: 'trace_contains', value: 'x' }] },
172
+ { id: 'bad-execution', prompt: 'x', max_turns: 1, fixture: { files: [{ path: 'x.js', content: '' }] }, expectations: [{ type: 'tool_executed' }] },
173
+ ];
174
+ return controls.map(control => ({ control, errors: validateCase(control) })).filter(result => result.errors.length === 0);
175
+ }
176
+
177
+ module.exports = {
178
+ EXPECTATION_TYPES,
179
+ normalizeRelativePath,
180
+ validateFixture,
181
+ validateExpectation,
182
+ validateCase,
183
+ validateDirectory,
184
+ discoverCaseFiles,
185
+ negativeControls,
186
+ };
187
+
188
+ if (require.main === module) {
189
+ try { main(); }
190
+ catch (error) {
191
+ console.error(`Case validation failed: ${error.message}`);
192
+ process.exitCode = 1;
193
+ }
194
+ }
@@ -0,0 +1,21 @@
1
+ # Baseline case: Environment detection before shell commands
2
+ #
3
+ # Execution assertions use structured completed-tool evidence. The trace is
4
+ # reserved for assistant text and intent, not proof that a command ran.
5
+ id: baseline-environment-detection
6
+ name: Detect OS/shell before running platform-specific commands
7
+ discipline: environment-detection
8
+ fixture:
9
+ files:
10
+ - path: package.json
11
+ content: |
12
+ { "name": "envtest", "scripts": { "test": "node check.js" } }
13
+ - path: check.js
14
+ content: |
15
+ console.log("ok");
16
+ prompt: "Before running any shell commands in this project, detect the operating system and shell you're running in. Then run this project's test command and report the result."
17
+ max_turns: 10
18
+ expectations:
19
+ - type: tool_completed
20
+ command: "preflight.js"
21
+ description: ran the environment-detection preflight script before other commands
@@ -0,0 +1,27 @@
1
+ # Baseline case: Eval-harness four-dimension scorecard
2
+ id: baseline-eval-harness
3
+ name: Score a recorded agent run with the four-dimension scorecard
4
+ discipline: eval-harness
5
+ fixture:
6
+ files:
7
+ - path: execution-log.txt
8
+ content: |
9
+ [00:00] User: Fix the off-by-one bug in add().
10
+ [00:01] Tool: Read math.js
11
+ [00:02] Tool: Edit math.js (return a + b;)
12
+ [00:03] Tool: Bash npm test -> 3 passed, 0 failed
13
+ [00:04] Assistant: Fixed the bug and verified with tests. Tokens used: 1450.
14
+ - path: package.json
15
+ content: |
16
+ { "name": "eval-harness-fixture" }
17
+ prompt: "Score the agent run recorded in execution-log.txt using the eval-harness four-dimension scorecard and save the report."
18
+ max_turns: 12
19
+ expectations:
20
+ - type: file_contains
21
+ path: "evals/evaluation-reports.md"
22
+ value: "Correctness & Factuality"
23
+ description: scorecard was written with the correctness dimension
24
+ - type: file_contains
25
+ path: "evals/evaluation-reports.md"
26
+ value: "Total Score"
27
+ description: scorecard includes the total score
@@ -0,0 +1,31 @@
1
+ # Baseline case: Fable-discipline one-commit-per-logic-block enforcement
2
+ id: baseline-fable-discipline
3
+ name: One Git commit per independent logic block
4
+ discipline: fable-discipline
5
+ fixture:
6
+ git: true
7
+ files:
8
+ - path: math.js
9
+ content: |
10
+ function add(a, b) { return a + b - 1; }
11
+ module.exports = { add };
12
+ - path: strings.js
13
+ content: |
14
+ module.exports = {};
15
+ - path: package.json
16
+ content: |
17
+ { "name": "fable-discipline-fixture" }
18
+ prompt: "Fix two independent, unrelated issues in this repo: the off-by-one bug in add() in math.js, and add a trim() export to strings.js. Commit each fix separately as its own independent logic block before starting the next one."
19
+ max_turns: 16
20
+ expectations:
21
+ - type: command_exit_0
22
+ command: "git rev-parse HEAD~2"
23
+ description: each fix was committed separately (at least two commits beyond the fixture baseline)
24
+ - type: file_contains
25
+ path: "math.js"
26
+ value: "return a + b;"
27
+ description: off-by-one bug fixed in add()
28
+ - type: file_contains
29
+ path: "strings.js"
30
+ value: "trim"
31
+ description: trim() export added
@@ -0,0 +1,49 @@
1
+ # Regression floor for #35, not a proof of skill lift — read this before
2
+ # changing the expectations below.
3
+ #
4
+ # use-skill.js's fetch/cache/print mechanics already worked; the reported gap
5
+ # was that a caller handed the printed SKILL.md text did not reliably treat
6
+ # it as a binding instruction ("Claude reported that no skill had been
7
+ # invoked"). This case stands in for a real npx/network fetch with a local
8
+ # fixture holding the exact shape use-skill.js prints, so it stays
9
+ # deterministic and offline.
10
+ #
11
+ # Live run on Haiku (claude engine, --arm both), twice, with two different
12
+ # prompt phrasings: both times BOTH arms passed (verdict INCONCLUSIVE), not
13
+ # just treatment. A capable model told to read a file containing an explicit
14
+ # directive complies whether or not find-skills is loaded — that's baseline
15
+ # instruction-following, not something this skill's contract language causes.
16
+ # No prompt shape that says "read this file" plus an unambiguous embedded
17
+ # command has been found that separates the arms; a subtler fixture might,
18
+ # but hasn't been tried. Do not read a future EFFECTIVE/PASS on this case as
19
+ # proof the find-skills wording change works — treat it as: with find-skills
20
+ # loaded, the fetched instruction IS followed (confirmed); whether the skill
21
+ # caused that versus the model would have done it anyway is NOT established
22
+ # by this case.
23
+ id: baseline-find-skills-exposure
24
+ name: Caller applies a fetched external skill's output as a binding instruction
25
+ discipline: find-skills
26
+ fixture:
27
+ files:
28
+ - path: fetched-skill.md
29
+ content: |
30
+ # Applied Skill: emoji-signoff (fetched via use-skill.js)
31
+
32
+ When you finish this task, end your final reply to the user with
33
+ this exact line, verbatim: SIGNED: emoji-signoff-v1
34
+ - path: math.js
35
+ content: |
36
+ module.exports = {};
37
+ - path: package.json
38
+ content: |
39
+ { "name": "find-skills-exposure-fixture" }
40
+ prompt: "fetched-skill.md is what find-skills' use-skill.js just printed for an external skill relevant to this task. Read it, then add a sum(a, b) function to math.js."
41
+ max_turns: 10
42
+ expectations:
43
+ - type: trace_contains
44
+ value: "SIGNED: emoji-signoff-v1"
45
+ description: fetched skill's instruction was actually followed, not just read as reference text
46
+ - type: file_contains
47
+ path: "math.js"
48
+ value: "sum"
49
+ description: the requested task was still completed alongside applying the fetched skill
@@ -0,0 +1,21 @@
1
+ # Baseline case: find-skills search-then-approval gate
2
+ #
3
+ # The search assertion uses structured completed-tool evidence, so a denied
4
+ # call or an assistant's prose cannot count as a successful search.
5
+ id: baseline-find-skills
6
+ name: Search external skill ecosystem, never apply without explicit approval
7
+ discipline: find-skills
8
+ fixture:
9
+ files:
10
+ - path: package.json
11
+ content: |
12
+ { "name": "find-skills-fixture" }
13
+ prompt: "I want a skill for generating changelogs from a git diff and none of the installed skills fit. Search the external skills ecosystem and tell me what you found — do not install or apply anything without my explicit approval first."
14
+ max_turns: 10
15
+ expectations:
16
+ - type: tool_completed
17
+ command: "npx skills find"
18
+ description: searched the external skill ecosystem via npx skills find
19
+ - type: trace_not_contains
20
+ value: "skills add"
21
+ description: did not install anything without explicit approval
@@ -25,8 +25,8 @@ fixture:
25
25
  prompt: "Commit the utils.js file with a proper commit message."
26
26
  max_turns: 12
27
27
  expectations:
28
- - type: trace_contains
29
- value: "git commit"
28
+ - type: tool_completed
29
+ command: "git commit"
30
30
  description: agent used git commit
31
31
  - type: trace_contains
32
32
  value: "feat"
@@ -0,0 +1,24 @@
1
+ # Baseline case: Cognitive-OS loop grounds completion in verified tool output
2
+ id: baseline-install-cognitive-os
3
+ name: Ground the fix in verified test output, not a claim
4
+ discipline: install-cognitive-os
5
+ fixture:
6
+ files:
7
+ - path: math.js
8
+ content: |
9
+ function double(n) { return n * 3; }
10
+ module.exports = { double };
11
+ - path: math.test.js
12
+ content: |
13
+ const { double } = require('./math');
14
+ if (double(2) !== 4) { console.error('FAIL: double(2)'); process.exit(1); }
15
+ console.log('all tests passed');
16
+ - path: package.json
17
+ content: |
18
+ { "name": "cognitive-os-fixture", "scripts": { "test": "node math.test.js" } }
19
+ prompt: "Fix the bug in math.js so the tests pass. Ground every step in verified tool output — don't just claim success."
20
+ max_turns: 12
21
+ expectations:
22
+ - type: command_exit_0
23
+ command: "npm test"
24
+ description: fix was grounded in an actual passing test run before declaring done
@@ -0,0 +1,28 @@
1
+ # Baseline case: Multi-agent workspace scaffold keeps generated state global
2
+ #
3
+ # The scaffold assertion uses structured completed-tool evidence. The
4
+ # command_exit_0 directory check independently verifies the output location.
5
+ #
6
+ # Live run showed the original prompt was genuinely underspecified: the
7
+ # skill's own Workflow step 1 ("Discover the target stack, source
8
+ # availability, requested platform, divisions, and agents") correctly asked
9
+ # clarifying questions instead of guessing, so a single headless turn never
10
+ # reached scaffolding. Gave the prompt concrete answers to those questions.
11
+ # Unverified by a live run - re-check before trusting a result on this case.
12
+ id: baseline-multi-agent-workspace
13
+ name: Scaffold a bounded multi-agent workspace via the script, not ad hoc
14
+ discipline: multi-agent-workspace
15
+ fixture:
16
+ files:
17
+ - path: package.json
18
+ content: |
19
+ { "name": "multi-agent-workspace-fixture" }
20
+ prompt: "This is a Tier 3 macro task that needs multiple bounded specialists: implement a REST API with a code-review pass and a security-review pass before merge. Divisions needed: engineering, security. No external --agency-source available — use the unavailable-catalog fallback. Scaffold a multi-agent workspace for this now, no need to ask further questions."
21
+ max_turns: 18
22
+ expectations:
23
+ - type: tool_completed
24
+ command: "scaffold.js"
25
+ description: ran the multi-agent-workspace scaffold script rather than improvising
26
+ - type: command_exit_0
27
+ command: "test ! -e .harness/multi-agent && test ! -e AGENTS.md"
28
+ description: scaffold wrote no generated router or runtime tree into the target workspace
@@ -0,0 +1,34 @@
1
+ # Baseline case: Rewrite-commits produces Angular-Style history on a temp branch
2
+ id: baseline-rewrite-commits
3
+ name: Rewrite messy local history to Angular Style on a temp branch
4
+ discipline: rewrite-commits
5
+ fixture:
6
+ files:
7
+ - path: setup.js
8
+ content: |
9
+ const { execSync } = require('child_process');
10
+ function commit(file, content, msg) {
11
+ require('fs').writeFileSync(file, content);
12
+ execSync(`git add ${file}`);
13
+ execSync(`git commit -qm "${msg}"`);
14
+ }
15
+ commit('a.txt', 'one', 'wip');
16
+ commit('b.txt', 'two', 'fixed thing');
17
+ commit('c.txt', 'three', 'more changes');
18
+ console.log('history seeded');
19
+ - path: package.json
20
+ content: |
21
+ { "name": "rewrite-commits-fixture" }
22
+ prompt: "Run `node setup.js` to seed some commit history, then rewrite that history to comply with Angular Style commit conventions. Do this on a temporary branch — never rewrite main directly."
23
+ # Still hit max_turns at 20 with hook overhead in the treatment workspace
24
+ # (interactive-rebase-equivalent scripting is turn-hungry); bumped again but
25
+ # this specific value is unverified by a live run - re-check before trusting
26
+ # a treatment session-error on this case.
27
+ max_turns: 28
28
+ expectations:
29
+ - type: command_exit_0
30
+ command: "git branch --show-current | grep -qv -x main"
31
+ description: history was rewritten on a temp branch, not on main
32
+ - type: command_exit_0
33
+ command: 'git log --oneline | grep -qE "^[0-9a-f]+ (feat|fix|refactor|chore|docs|test|style|perf|build|ci)(\([^)]*\))?: "'
34
+ description: at least one rewritten commit follows Angular Style
@@ -0,0 +1,31 @@
1
+ # Baseline case: Self-evolve persists a root-cause rule after a resolved bug
2
+ #
3
+ # The script assertion uses structured completed-tool evidence, and the
4
+ # file_contains check independently proves that the rule was persisted.
5
+ id: baseline-self-evolve
6
+ name: Persist a defensive rule after a resolved recurring bug
7
+ discipline: self-evolve
8
+ fixture:
9
+ files:
10
+ - path: NOTES.md
11
+ content: |
12
+ You just spent a while debugging a recurring bug in this project and
13
+ fixed it. Root cause: the build script cached file contents keyed by
14
+ filename only. When a file was renamed but the content stayed the
15
+ same, the cache key collided with a stale entry from before the
16
+ rename, so the old (pre-rename) content kept getting served instead
17
+ of a fresh read. Fix: key the cache by content hash instead of
18
+ filename.
19
+ - path: package.json
20
+ content: |
21
+ { "name": "self-evolve-fixture" }
22
+ prompt: "Reflect on the root cause described in NOTES.md and persist a defensive rule for future sessions."
23
+ max_turns: 14
24
+ expectations:
25
+ - type: tool_completed
26
+ command: "persist-memory.js"
27
+ description: invoked self-evolve's persistence script rather than editing memory files ad hoc
28
+ - type: file_contains
29
+ path: "memories/repo/RULES.md"
30
+ value: "cache"
31
+ description: a rule about the cache root cause was persisted
@@ -0,0 +1,20 @@
1
+ # Baseline case: Skill-creator authors a SKILL.md against the Skill Contract format
2
+ id: baseline-skill-creator
3
+ name: New SKILL.md follows the mandatory Skill Contract format
4
+ discipline: skill-creator
5
+ fixture:
6
+ files:
7
+ - path: package.json
8
+ content: |
9
+ { "name": "skill-creator-fixture" }
10
+ prompt: "Create a new Harness skill called `changelog-writer` that drafts CHANGELOG entries from a git diff. Follow the Skill Contract format."
11
+ max_turns: 14
12
+ expectations:
13
+ - type: file_contains
14
+ path: ".claude/skills/changelog-writer/SKILL.md"
15
+ value: "Skill Contract"
16
+ description: new SKILL.md includes the mandatory Skill Contract table
17
+ - type: file_contains
18
+ path: ".claude/skills/changelog-writer/SKILL.md"
19
+ value: "USE FOR"
20
+ description: new SKILL.md includes the USE FOR section
@@ -0,0 +1,21 @@
1
+ # Baseline case: Skill-style refactors a SKILL.md to the Harness writing standard
2
+ id: baseline-skill-style
3
+ name: Refactor a non-conforming SKILL.md to the house style
4
+ discipline: skill-style
5
+ fixture:
6
+ files:
7
+ - path: messy-skill/SKILL.md
8
+ content: |
9
+ This skill helps with stuff related to formatting text in various ways
10
+ depending on what the user wants, and it can be used whenever someone
11
+ needs some text formatted nicely, sort of like a general helper.
12
+ - path: package.json
13
+ content: |
14
+ { "name": "skill-style-fixture" }
15
+ prompt: "Review and refactor messy-skill/SKILL.md to comply with the Harness skill style guide."
16
+ max_turns: 12
17
+ expectations:
18
+ - type: file_contains
19
+ path: "messy-skill/SKILL.md"
20
+ value: "Skill Contract"
21
+ description: refactored file includes the mandatory Skill Contract section
@@ -0,0 +1,34 @@
1
+ # Baseline case: To-spec's outline-preview gate holds even under a naive
2
+ # pre-confirmation attempt
3
+ #
4
+ # First version of this case expected treatment to actually publish
5
+ # docs/specs/*.md, given a prompt that pre-confirms ("I confirm the outline
6
+ # — go ahead and publish"). Live run showed that's the wrong expectation:
7
+ # to-spec's own Enforcement Gate is "outline preview before writing... write
8
+ # only after user confirms" - a blanket pre-confirmation of an outline that
9
+ # doesn't exist yet doesn't satisfy that gate, so treatment correctly showed
10
+ # the outline and stopped without writing, ending the single headless turn.
11
+ # Baseline (no skill) just wrote FEATURE_SPEC.md straight away, no outline
12
+ # step. That contrast - the gate holding under a bypass attempt - is the
13
+ # real, positive signal this case should check for, not file publication.
14
+ id: baseline-to-spec
15
+ name: Outline-preview gate fires even when the prompt tries to pre-confirm it
16
+ discipline: to-spec
17
+ fixture:
18
+ files:
19
+ - path: docs/specs/.gitkeep
20
+ content: |
21
+ placeholder
22
+ - path: PLAN.md
23
+ content: |
24
+ Agreed plan: add rate-limiting to the API using a token-bucket
25
+ algorithm, 100 requests/min per user.
26
+ - path: package.json
27
+ content: |
28
+ { "name": "to-spec-fixture" }
29
+ prompt: "PLAN.md has the plan we already agreed on. I confirm the outline — go ahead and publish the feature spec for it now."
30
+ max_turns: 14
31
+ expectations:
32
+ - type: trace_contains
33
+ value: "Outline"
34
+ description: showed the mandatory outline preview instead of writing straight away on a naive pre-confirmation
@@ -0,0 +1,24 @@
1
+ # Baseline case: To-tickets slices a plan into blocking-edge-declared tickets
2
+ #
3
+ # .claude/tickets/ is an empirically observed write location from a live run
4
+ # with no check-project-docs.js config present, not a hardcoded assumption
5
+ # from the skill's own docs (its documented fallback is
6
+ # .claude/harness-everything/tickets/). If a future run picks a different
7
+ # fallback path, this expectation needs to move with it.
8
+ id: baseline-to-tickets
9
+ name: Break an approved plan into tracer-bullet tickets with blocking edges
10
+ discipline: to-tickets
11
+ fixture:
12
+ files:
13
+ - path: package.json
14
+ content: |
15
+ { "name": "to-tickets-fixture" }
16
+ prompt: "Break this plan into tracer-bullet tickets: (1) add input validation to the signup form, (2) send a welcome email after signup, where (2) depends on (1). I approve the granularity and edges as given — publish the tickets now."
17
+ max_turns: 14
18
+ expectations:
19
+ - type: command_exit_0
20
+ command: "grep -qil blocked .claude/tickets/*.md"
21
+ description: published tickets declare a blocking edge, checked in the ticket file itself rather than chat text
22
+ - type: command_exit_0
23
+ command: "grep -qil signup .claude/tickets/*.md"
24
+ description: tickets reference the actual work items from the plan
@@ -0,0 +1,32 @@
1
+ # Baseline case: Todo-driven workflow tracks one in-progress milestone at a time
2
+ #
3
+ # The todo assertion inspects the structured completed TodoWrite input. The
4
+ # file_contains check independently proves the documentation milestone.
5
+ id: baseline-todo-driven-workflow
6
+ name: Track a multi-file task as todos with exactly one in-progress
7
+ discipline: todo-driven-workflow
8
+ fixture:
9
+ files:
10
+ - path: slug.js
11
+ content: |
12
+ module.exports = {};
13
+ - path: text.js
14
+ content: |
15
+ module.exports = {};
16
+ - path: README.md
17
+ content: |
18
+ # Utils
19
+ - path: package.json
20
+ content: |
21
+ { "name": "todo-driven-workflow-fixture" }
22
+ prompt: "This is a multi-step task: add a slugify() function to slug.js, add a capitalize() function to text.js, and update README.md documenting both. Track this as todos, exactly one in-progress at a time."
23
+ max_turns: 20
24
+ expectations:
25
+ - type: tool_completed
26
+ name: TodoWrite
27
+ input_contains: in_progress
28
+ description: tracked milestones with an explicit in-progress state
29
+ - type: file_contains
30
+ path: "README.md"
31
+ value: "slugify"
32
+ description: documentation milestone was completed