harness-everything 0.32.0 → 0.33.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.
- package/.claude-plugin/marketplace.json +1 -1
- package/.claude-plugin/plugin.json +2 -1
- package/CHANGELOG.md +10 -0
- package/README.md +3 -2
- package/ci/mechanism-2az-step-type-registry.test.js +86 -0
- package/ci/openai-plugin-package.test.js +1 -1
- package/ci/release-consistency-check.js +26 -9
- package/ci/release-consistency-check.test.js +30 -0
- package/ci/router-workflow-plan.test.js +36 -0
- package/code-review/SKILL.md +41 -0
- package/code-review/references/review-playbook.md +40 -0
- package/code-review/templates/finding.template.md +33 -0
- package/docs/openai-plugin.md +1 -1
- package/docs/workflows/code-review.md +58 -0
- package/evals/code-review/eval.yaml +26 -0
- package/evals/code-review/tasks/negative-grill-me.yaml +16 -0
- package/evals/code-review/tasks/negative-security-review.yaml +16 -0
- package/evals/code-review/tasks/negative-tdd.yaml +16 -0
- package/evals/code-review/tasks/negative-verification-loop.yaml +16 -0
- package/evals/code-review/tasks/positive-pr-review.yaml +16 -0
- package/evals/code-review/tasks/positive-revised-head-rereview.yaml +16 -0
- package/harness-everything/SKILL.md +1 -1
- package/harness-everything/references/skill-registry.md +1 -0
- package/harness-everything/scripts/routing-keywords.json +7 -0
- package/hooks/scripts/lib/binding-resolver.js +1 -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/scripts/lib/binding-resolver.js +1 -0
- package/plugins/harness-everything/plugin.json +1 -1
- package/plugins/harness-everything/skills/code-review/SKILL.md +41 -0
- package/plugins/harness-everything/skills/code-review/references/review-playbook.md +40 -0
- package/plugins/harness-everything/skills/code-review/templates/finding.template.md +33 -0
- package/plugins/harness-everything/skills/harness-everything/SKILL.md +1 -1
- package/plugins/harness-everything/skills/harness-everything/references/skill-registry.md +1 -0
- package/plugins/harness-everything/skills/harness-everything/scripts/routing-keywords.json +7 -0
- package/sbom.cdx.json +7 -7
|
@@ -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.
|
|
13
|
+
"version": "0.33.0",
|
|
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.
|
|
4
|
+
"version": "0.33.0",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Miya Daniel"
|
|
7
7
|
},
|
|
@@ -23,6 +23,7 @@
|
|
|
23
23
|
],
|
|
24
24
|
"skills": [
|
|
25
25
|
"./multi-agent-workspace",
|
|
26
|
+
"./code-review",
|
|
26
27
|
"./environment-detection",
|
|
27
28
|
"./eval-harness",
|
|
28
29
|
"./fable-discipline",
|
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,16 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project are documented in this file.
|
|
4
4
|
|
|
5
|
+
## [0.33.0](https://github.com/dyphn1/Harness-everything/compare/v0.32.0...v0.33.0) (2026-10-17)
|
|
6
|
+
|
|
7
|
+
### Features
|
|
8
|
+
|
|
9
|
+
* **code-review:** add evidence-tiered independent review skill ([#329](https://github.com/dyphn1/Harness-everything/issues/329)) ([2acb220](https://github.com/dyphn1/Harness-everything/commit/2acb22098a5fc360306b0ed34fa3ddcf21592fea))
|
|
10
|
+
|
|
11
|
+
### Bug Fixes
|
|
12
|
+
|
|
13
|
+
* **code-review:** register the code-review binding so review steps can load it ([acb766a](https://github.com/dyphn1/Harness-everything/commit/acb766aea36361262f3536db36069265aa66d871))
|
|
14
|
+
|
|
5
15
|
## [0.32.0](https://github.com/dyphn1/Harness-everything/compare/v0.31.3...v0.32.0) (2026-10-17)
|
|
6
16
|
|
|
7
17
|
### Features
|
package/README.md
CHANGED
|
@@ -184,7 +184,7 @@ The authoritative current matrix is [docs/platform-capabilities.md](docs/platfor
|
|
|
184
184
|
| **Claude Code** | Native lifecycle hooks (`PreToolUse`, `PostToolUse`, `SessionStart`, `UserPromptSubmit`, `Stop`) | `.claude/settings.json`, `.claude/skills/`, `.claude/agents/` | Semantic workflow contracts are reminder-observed; Rule-of-3 reflection and explicit permission boundaries may block |
|
|
185
185
|
| **OpenCode** | Native plugin module ([`opencode-plugin/index.mjs`](opencode-plugin/index.mjs), install as `harness-enforcement.js`) | `.opencode/plugins/` | **Partial live-host evidence** — project-scope `.js` loading and edit/verification state on OpenCode 1.18.31 (macOS); current workflow/verification behavior is reminder-oriented, with only the third-failure reflection boundary blocking edits |
|
|
186
186
|
| **Codex — general installer path** | Skills + `AGENTS.md` instructions | `AGENTS.md` + repo-scoped `.agents/skills/` | **Instruction/advisory delivery only**; semantic MUST/SHOULD/MAY still applies, without a hard-enforcement claim |
|
|
187
|
-
| **Codex / local OpenAI plugin** | `.codex-plugin` package with session, prompt, supported-tool, subagent, and stop hooks plus
|
|
187
|
+
| **Codex / local OpenAI plugin** | `.codex-plugin` package with session, prompt, supported-tool, subagent, and stop hooks plus 27 canonical skills | `.agents/plugins/marketplace.json` → `plugins/harness-everything/` | **Mechanism-tested local contract observation plus explicit permission/Rule-of-3 boundaries** for the packaged mappings; live host loading remains unverified |
|
|
188
188
|
| **Public OpenAI Skills-only plugin** | Public Skills-only bundle | Generated submission ZIP from `plugins/harness-everything/skills/` | **Skill/workflow behavior only**; no local `.codex-plugin` lifecycle hooks in the public artifact |
|
|
189
189
|
| **Cursor** | Native Project Rules + project skills | `.cursorrules` + `.cursor/skills/` | Advisory only |
|
|
190
190
|
| **GitHub Copilot agent surfaces** | Agent Skills + repository custom instructions | `.github/copilot-instructions.md` + `.github/skills/` | Agent Skills path is documented; no live Harness session or plugin install is verified |
|
|
@@ -229,7 +229,7 @@ This repo uses a flat layout (waza/agentskills.io convention). The table below m
|
|
|
229
229
|
| `.agents/plugins` | **Distribution** | OpenAI/Codex repository marketplace metadata |
|
|
230
230
|
| `plugins/harness-everything` | **Distribution** | Local OpenAI/Codex plugin package plus canonical skill copies |
|
|
231
231
|
| `submission/openai` | **Distribution / Review** | Public OpenAI Skills-only listing/test inputs |
|
|
232
|
-
| `evals` | **Routing Evals** |
|
|
232
|
+
| `evals` | **Routing Evals** | 27 trigger/routing eval suites (waza format) |
|
|
233
233
|
| `eval-framework` | **Quality Gates** | Negative-control fixtures for consistency/collision gates (not a skill) |
|
|
234
234
|
| `contract-integrity` | **Quality Gates** | ADR→spec→ticket→test→implementation trace audit (Phase 1; not a directly routed skill) |
|
|
235
235
|
| `telemetry` | **Quality Gates** | Local JSONL operational evidence layer with report/benchmark scripts (not a skill) |
|
|
@@ -238,6 +238,7 @@ This repo uses a flat layout (waza/agentskills.io convention). The table below m
|
|
|
238
238
|
| `docs` | **Documentation** | Philosophy, architecture, routing, reflection, platform capabilities, generated repository contract, audit |
|
|
239
239
|
| `references` | **Documentation** | Shared checklists (security, performance, definition-of-done) |
|
|
240
240
|
| `multi-agent-workspace` | **Skill (Tier 3)** | Scaffold a verified multi-agent workspace and select bounded specialists from an external catalog without vendoring the full roster |
|
|
241
|
+
| `code-review` | **Skill (Tier 2)** | Independent, evidence-tiered PR/diff code review (read-only by default) |
|
|
241
242
|
| `environment-detection` | **Foundation** | Preflight: detect OS, shell, package manager |
|
|
242
243
|
| `eval-harness` | **Skill (Tier 2)** | Evaluate agent outputs against rubrics |
|
|
243
244
|
| `fable-discipline` | **Skill (Tier 3)** | Fable execution guardrails when Fable is selected |
|
|
@@ -832,6 +832,92 @@ checkCase('Claude hook copy is byte-identical and a tracked Codex runtime includ
|
|
|
832
832
|
compat.uninstall({ codexHome });
|
|
833
833
|
});
|
|
834
834
|
|
|
835
|
+
checkCase('registered code-review optional binding activates review steps from source and packaged roots', () => {
|
|
836
|
+
const requirements = [
|
|
837
|
+
{ id: 'req-review', stepType: 'review', summary: 'Review the change', acceptance: 'findings recorded with evidence tiers', optionalBindings: ['code-review'] },
|
|
838
|
+
{ id: 'req-verify', stepType: 'verification', summary: 'Verify the change', acceptance: 'objective checks pass' },
|
|
839
|
+
];
|
|
840
|
+
for (const leg of [
|
|
841
|
+
{ root: ROOT, sessionId: 'code-review-source-root', expected: path.join(ROOT, 'code-review', 'SKILL.md') },
|
|
842
|
+
{ root: path.join(tempRoot, 'code-review-packaged-root'), sessionId: 'code-review-packaged-root', expected: path.join(tempRoot, 'code-review-packaged-root', 'skills', 'code-review', 'SKILL.md') },
|
|
843
|
+
]) {
|
|
844
|
+
if (leg.root !== ROOT) {
|
|
845
|
+
fs.mkdirSync(leg.root, { recursive: true });
|
|
846
|
+
for (const directory of ['hooks', 'harness-everything', 'scripts', 'fable-mode']) {
|
|
847
|
+
fs.cpSync(path.join(ROOT, directory), path.join(leg.root, directory), { recursive: true });
|
|
848
|
+
}
|
|
849
|
+
fs.cpSync(path.join(packageRoot, 'skills'), path.join(leg.root, 'skills'), { recursive: true });
|
|
850
|
+
}
|
|
851
|
+
const session = planSession(leg.sessionId, requirements, 'iterative-single', leg.root, FIX_PROMPT, 'author-declared plan with an optional code-review binding', leg.root);
|
|
852
|
+
assert.strictEqual(session.planned.status, 0, session.planned.stderr);
|
|
853
|
+
const declared = readJson(session.obligationsFile).requirements[0].optionalBindings.find(item => item.id === 'code-review');
|
|
854
|
+
assert.strictEqual(declared.availability, 'available', 'the registered optional binding must resolve from the declared runtime root');
|
|
855
|
+
assert.strictEqual(fs.realpathSync(declared.resolvedPath), fs.realpathSync(leg.expected), 'the optional binding resolves to the canonical code-review skill file');
|
|
856
|
+
const legController = path.join(leg.root, 'hooks/scripts/workflow-disposition.js');
|
|
857
|
+
const started = run(legController, ['start', '--session-id', leg.sessionId], leg.root);
|
|
858
|
+
assert.strictEqual(started.status, 0, started.stderr);
|
|
859
|
+
const load = run(legController, [
|
|
860
|
+
'binding', '--session-id', leg.sessionId, '--step-id', 'req-review', '--binding-id', 'code-review',
|
|
861
|
+
'--disposition', 'loaded', '--evidence', 'Read code-review/SKILL.md and applied its evidence-tier rubric.',
|
|
862
|
+
], leg.root);
|
|
863
|
+
assert.strictEqual(load.status, 0, load.stderr);
|
|
864
|
+
const loaded = readJson(session.obligationsFile).requirements[0].optionalBindings.find(item => item.id === 'code-review');
|
|
865
|
+
assert.strictEqual(loaded.status, 'loaded');
|
|
866
|
+
assert.strictEqual(fs.realpathSync(loaded.resolvedPath), fs.realpathSync(leg.expected), 'the loaded binding keeps its canonical resolved path');
|
|
867
|
+
const passed = run(legController, [
|
|
868
|
+
'step', '--session-id', leg.sessionId, '--step-id', 'req-review', '--disposition', 'pass',
|
|
869
|
+
'--evidence', 'Review findings filed against the diff with evidence tiers.',
|
|
870
|
+
], leg.root);
|
|
871
|
+
assert.strictEqual(passed.status, 0, passed.stderr);
|
|
872
|
+
}
|
|
873
|
+
|
|
874
|
+
const notNeeded = planSession('code-review-not-needed', requirements, 'iterative-single', ROOT, FIX_PROMPT, 'author-declared plan marks code-review not needed');
|
|
875
|
+
assert.strictEqual(notNeeded.planned.status, 0, notNeeded.planned.stderr);
|
|
876
|
+
assert.strictEqual(run(controller, ['start', '--session-id', 'code-review-not-needed'], ROOT).status, 0);
|
|
877
|
+
assert.strictEqual(run(controller, [
|
|
878
|
+
'binding', '--session-id', 'code-review-not-needed', '--step-id', 'req-review', '--binding-id', 'code-review',
|
|
879
|
+
'--disposition', 'not-needed', '--evidence', 'Reviewed inline against the agentic-commons review rubric.',
|
|
880
|
+
], ROOT).status, 0, 'an optional binding can be marked not-needed');
|
|
881
|
+
assert.strictEqual(run(controller, [
|
|
882
|
+
'step', '--session-id', 'code-review-not-needed', '--step-id', 'req-review', '--disposition', 'pass',
|
|
883
|
+
'--evidence', 'Review completed without the optional skill.',
|
|
884
|
+
], ROOT).status, 0, 'marking code-review not-needed still lets the review step pass');
|
|
885
|
+
|
|
886
|
+
const unknown = planSession('code-review-unknown-optional', [
|
|
887
|
+
{ id: 'req-review', stepType: 'review', summary: 'Review the change', acceptance: 'findings recorded with evidence tiers', optionalBindings: ['no-such-skill'] },
|
|
888
|
+
{ id: 'req-verify', stepType: 'verification', summary: 'Verify the change', acceptance: 'objective checks pass' },
|
|
889
|
+
]);
|
|
890
|
+
assert.strictEqual(unknown.planned.status, 0, unknown.planned.stderr);
|
|
891
|
+
const undeclared = readJson(unknown.obligationsFile).requirements[0].optionalBindings.find(item => item.id === 'no-such-skill');
|
|
892
|
+
assert.strictEqual(undeclared.availability, 'unknown', 'an unregistered binding id stays unknown');
|
|
893
|
+
assert.strictEqual(run(controller, ['start', '--session-id', 'code-review-unknown-optional'], ROOT).status, 0);
|
|
894
|
+
const cannotLoad = run(controller, [
|
|
895
|
+
'binding', '--session-id', 'code-review-unknown-optional', '--step-id', 'req-review', '--binding-id', 'no-such-skill',
|
|
896
|
+
'--disposition', 'loaded', '--evidence', 'attempted load without a registered path',
|
|
897
|
+
], ROOT);
|
|
898
|
+
assert.strictEqual(cannotLoad.status, 2, cannotLoad.stderr);
|
|
899
|
+
assert.match(cannotLoad.stderr, /no registered load path/, cannotLoad.stderr);
|
|
900
|
+
assert.strictEqual(run(controller, [
|
|
901
|
+
'step', '--session-id', 'code-review-unknown-optional', '--step-id', 'req-review', '--disposition', 'pass',
|
|
902
|
+
'--evidence', 'premature pass while the unknown optional binding is pending',
|
|
903
|
+
], ROOT).status, 2, 'a pending unknown optional binding still blocks a premature step pass');
|
|
904
|
+
assert.strictEqual(run(controller, [
|
|
905
|
+
'binding', '--session-id', 'code-review-unknown-optional', '--step-id', 'req-review', '--binding-id', 'no-such-skill',
|
|
906
|
+
'--disposition', 'not-needed', '--evidence', 'No Harness skill exists under that id.',
|
|
907
|
+
], ROOT).status, 0, 'an unknown optional binding is marked not-needed instead');
|
|
908
|
+
assert.strictEqual(run(controller, [
|
|
909
|
+
'step', '--session-id', 'code-review-unknown-optional', '--step-id', 'req-review', '--disposition', 'pass',
|
|
910
|
+
'--evidence', 'Review completed without any optional skill.',
|
|
911
|
+
], ROOT).status, 0, 'marking the unknown optional binding not-needed lets the step pass');
|
|
912
|
+
|
|
913
|
+
const forbidden = planSession('code-review-review-still-forbids-tdd', [
|
|
914
|
+
{ id: 'req-review', stepType: 'review', summary: 'Review the change', acceptance: 'the change is reviewed', optionalBindings: ['tdd'] },
|
|
915
|
+
{ id: 'req-verify', stepType: 'verification', summary: 'Verify the change', acceptance: 'objective checks pass' },
|
|
916
|
+
]);
|
|
917
|
+
assert.strictEqual(forbidden.planned.status, 2);
|
|
918
|
+
assert.match(forbidden.planned.stderr, /review steps cannot bind tdd/);
|
|
919
|
+
});
|
|
920
|
+
|
|
835
921
|
fs.rmSync(tempRoot, { recursive: true, force: true });
|
|
836
922
|
console.log(`\n${failed === 0 ? 'PASS' : 'FAIL'}: Stage A workflow step-type registry (${failed} failures)`);
|
|
837
923
|
process.exit(failed === 0 ? 0 : 1);
|
|
@@ -104,7 +104,7 @@ const packagedSkillNames = fs.readdirSync(path.join(PLUGIN, 'skills'), { withFil
|
|
|
104
104
|
.filter(entry => entry.isDirectory())
|
|
105
105
|
.map(entry => entry.name)
|
|
106
106
|
.sort();
|
|
107
|
-
assert.strictEqual(skillNames.length,
|
|
107
|
+
assert.strictEqual(skillNames.length, 27, 'canonical suite should contain 27 skills');
|
|
108
108
|
assert.deepStrictEqual(packagedSkillNames, skillNames, 'OpenAI package must contain exactly the canonical skill set');
|
|
109
109
|
for (const entry of SOURCE_MANIFEST.skills) {
|
|
110
110
|
const source = path.resolve(ROOT, entry);
|
|
@@ -43,6 +43,22 @@ const releaseRenames = new Map([
|
|
|
43
43
|
['create-agent-launcher', 'multi-agent-workspace']
|
|
44
44
|
]);
|
|
45
45
|
|
|
46
|
+
function logicalSkillName(skill) {
|
|
47
|
+
return releaseRenames.get(skill) || skill;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
function compareSkillCatalogs(tagSkills, currentSkills) {
|
|
51
|
+
const releaseLogical = new Set(tagSkills.map(logicalSkillName));
|
|
52
|
+
const currentLogical = new Set(currentSkills.map(logicalSkillName));
|
|
53
|
+
const missing = [...releaseLogical].filter(skill => !currentLogical.has(skill)).sort();
|
|
54
|
+
const additions = [...new Set(currentSkills.filter(skill => !releaseLogical.has(logicalSkillName(skill))))].sort();
|
|
55
|
+
return { missing, additions, exitCode: missing.length ? 1 : 0 };
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
function formatAdditions(additions) {
|
|
59
|
+
return additions.length ? `Additions since release tag: ${additions.join(', ')}` : '';
|
|
60
|
+
}
|
|
61
|
+
|
|
46
62
|
function git(args) {
|
|
47
63
|
return execFileSync('git', args, { cwd: root, encoding: 'utf8' }).trim();
|
|
48
64
|
}
|
|
@@ -90,15 +106,13 @@ function main() {
|
|
|
90
106
|
process.exit(2);
|
|
91
107
|
}
|
|
92
108
|
const current = new Set(discoverSkills(root));
|
|
93
|
-
const
|
|
94
|
-
const releaseLogical = new Set(tagRoot.map(skill => releaseRenames.get(skill) || skill));
|
|
95
|
-
const missing = [...releaseLogical].filter(skill => !currentLogical.has(skill));
|
|
96
|
-
const extra = [...currentLogical].filter(skill => !releaseLogical.has(skill));
|
|
109
|
+
const comparison = compareSkillCatalogs(tagRoot, [...current]);
|
|
97
110
|
console.log(`Release ${tag}: ${tagRoot.length} skill(s); current tree: ${current.size} skill(s).`);
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
111
|
+
const additionsLine = formatAdditions(comparison.additions);
|
|
112
|
+
if (additionsLine) console.log(additionsLine);
|
|
113
|
+
if (comparison.exitCode !== 0) {
|
|
114
|
+
console.error(`Missing from current tree: ${comparison.missing.join(', ')}`);
|
|
115
|
+
process.exit(comparison.exitCode);
|
|
102
116
|
}
|
|
103
117
|
|
|
104
118
|
let references = 0;
|
|
@@ -140,7 +154,10 @@ function main() {
|
|
|
140
154
|
console.error(`CURRENT RELEASE CHECK FAILED: ${currentReferences.failures.length} dangling reference(s).`);
|
|
141
155
|
process.exit(1);
|
|
142
156
|
}
|
|
143
|
-
|
|
157
|
+
const additionLabel = comparison.additions.length === 1 ? 'addition' : 'additions';
|
|
158
|
+
console.log(`RELEASE SKILL BASELINE PASSED for ${tag}: all ${tagRoot.length} release-tag skills remain present; current source has ${current.size} skill(s), including ${comparison.additions.length} ${additionLabel} not yet in the tag.`);
|
|
144
159
|
}
|
|
145
160
|
|
|
146
161
|
if (require.main === module) main();
|
|
162
|
+
|
|
163
|
+
module.exports = { compareSkillCatalogs, formatAdditions };
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
const assert = require('assert');
|
|
4
|
+
const { compareSkillCatalogs, formatAdditions } = require('./release-consistency-check');
|
|
5
|
+
|
|
6
|
+
const addedSkill = compareSkillCatalogs(
|
|
7
|
+
['existing-skill'],
|
|
8
|
+
['code-review', 'existing-skill']
|
|
9
|
+
);
|
|
10
|
+
assert.deepStrictEqual(addedSkill.missing, [], 'a release-tag skill must remain present');
|
|
11
|
+
assert.deepStrictEqual(addedSkill.additions, ['code-review']);
|
|
12
|
+
assert.strictEqual(addedSkill.exitCode, 0, 'an extra current skill is informational');
|
|
13
|
+
assert.strictEqual(formatAdditions(addedSkill.additions), 'Additions since release tag: code-review');
|
|
14
|
+
|
|
15
|
+
const missingSkill = compareSkillCatalogs(
|
|
16
|
+
['existing-skill', 'removed-skill'],
|
|
17
|
+
['existing-skill']
|
|
18
|
+
);
|
|
19
|
+
assert.deepStrictEqual(missingSkill.missing, ['removed-skill']);
|
|
20
|
+
assert.strictEqual(missingSkill.exitCode, 1, 'a released skill missing from current source must fail');
|
|
21
|
+
|
|
22
|
+
const renamedSkill = compareSkillCatalogs(
|
|
23
|
+
['build-multi-agent-system'],
|
|
24
|
+
['multi-agent-workspace']
|
|
25
|
+
);
|
|
26
|
+
assert.deepStrictEqual(renamedSkill.missing, [], 'the established rename must satisfy the released entry');
|
|
27
|
+
assert.deepStrictEqual(renamedSkill.additions, [], 'a rename must not be reported as a new addition');
|
|
28
|
+
assert.strictEqual(renamedSkill.exitCode, 0);
|
|
29
|
+
|
|
30
|
+
console.log('Release consistency catalog additions, missing-skill failures, and rename mapping verified.');
|
|
@@ -27,6 +27,12 @@ function check(condition, message) {
|
|
|
27
27
|
}
|
|
28
28
|
}
|
|
29
29
|
|
|
30
|
+
function reviewBindingIds(run) {
|
|
31
|
+
const text = `${run.result.stdout || ''}\n${run.result.stderr || ''}`;
|
|
32
|
+
const line = text.match(/Candidate step binding ids: ([^\r\n]+)/);
|
|
33
|
+
return line ? line[1].split(',').map(id => id.trim()).filter(Boolean) : [];
|
|
34
|
+
}
|
|
35
|
+
|
|
30
36
|
function runTier(prompt, options = {}) {
|
|
31
37
|
const contractPath = path.join(os.tmpdir(), `harness-router-test-${process.pid}-${Math.random().toString(16).slice(2)}.json`);
|
|
32
38
|
const context = options.context || null;
|
|
@@ -91,6 +97,36 @@ if (validContract(iterative, 'iterative-single')) {
|
|
|
91
97
|
check(!plan.requiredInvariants.includes('tdd'), 'binding ids remain step-local rather than workflow invariants');
|
|
92
98
|
}
|
|
93
99
|
|
|
100
|
+
const reviewPositives = [
|
|
101
|
+
'Review PR #412 before we merge it',
|
|
102
|
+
'Review pull request #412',
|
|
103
|
+
'Review this PR before merge',
|
|
104
|
+
'Review the diff',
|
|
105
|
+
'Review the implementation',
|
|
106
|
+
'Re-review the fix at the new HEAD',
|
|
107
|
+
];
|
|
108
|
+
const reviewNegatives = [
|
|
109
|
+
'review project plan',
|
|
110
|
+
'review proposal',
|
|
111
|
+
'review process',
|
|
112
|
+
'preview pr environment',
|
|
113
|
+
'Review this proposal',
|
|
114
|
+
'Review the project plan',
|
|
115
|
+
'Review my process',
|
|
116
|
+
'Re-review the problem statement',
|
|
117
|
+
'Review my implementation plan, ask one question at a time',
|
|
118
|
+
'Preview the diff rendering',
|
|
119
|
+
'Preview PR #412 environment',
|
|
120
|
+
];
|
|
121
|
+
for (const prompt of reviewPositives) {
|
|
122
|
+
const run = runTier(prompt);
|
|
123
|
+
check(reviewBindingIds(run).includes('code-review'), `review signal: ${JSON.stringify(prompt)} yields the code-review candidate`);
|
|
124
|
+
}
|
|
125
|
+
for (const prompt of reviewNegatives) {
|
|
126
|
+
const run = runTier(prompt);
|
|
127
|
+
check(!reviewBindingIds(run).includes('code-review'), `review signal: ${JSON.stringify(prompt)} stays code-review-free`);
|
|
128
|
+
}
|
|
129
|
+
|
|
94
130
|
const memoryPersist = runTier('Persist this lesson as memory after resolving the checkout regression.');
|
|
95
131
|
if (validContract(memoryPersist, 'self-evolve persistence')) {
|
|
96
132
|
const plan = memoryPersist.contract.workflowPlan;
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: code-review
|
|
3
|
+
description: "Independently review a PR, diff or finished implementation for correctness, contract and negative-path defects, with source-anchored findings labelled executed, source-traced or inconclusive; read-only by default. USE FOR: \"review this PR before merge\", \"re-review the fix at the new HEAD\". DO NOT USE FOR: \"security threat modeling\", \"implementing or fixing the code\"."
|
|
4
|
+
license: Apache-2.0
|
|
5
|
+
metadata:
|
|
6
|
+
author: Miya Daniel
|
|
7
|
+
version: 0.33.0
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# Code Review
|
|
11
|
+
|
|
12
|
+
Independently review completed changes for correctness, contract violations, and negative-path defects. Default to read-only.
|
|
13
|
+
|
|
14
|
+
## 📋 Skill Contract
|
|
15
|
+
|
|
16
|
+
| Component | Specification |
|
|
17
|
+
| :--- | :--- |
|
|
18
|
+
| **Trigger / Input** | Requested review of a PR, diff, implementation, or revised HEAD. |
|
|
19
|
+
| **Expected Output** | Source-anchored findings and an evidence-qualified summary. |
|
|
20
|
+
| **State Mutations** | None unless the user explicitly authorizes an action. |
|
|
21
|
+
| **Enforcement Gate** | Apply the checklist in `<this-skill-dir>/references/review-playbook.md`. |
|
|
22
|
+
|
|
23
|
+
## USE FOR:
|
|
24
|
+
- Review a PR / diff / finished implementation before merge
|
|
25
|
+
- Re-review a revised HEAD: prior-finding disposition + new risks
|
|
26
|
+
|
|
27
|
+
## DO NOT USE FOR:
|
|
28
|
+
- Security-only threat modeling / secrets / OWASP (use `security-review`)
|
|
29
|
+
- Design or plan stress-testing (use `grill-me`); running gates (use `verification-loop`); writing the fix (use `tdd`)
|
|
30
|
+
|
|
31
|
+
## Workflow
|
|
32
|
+
|
|
33
|
+
1. Pin repository, contract, base/head, changed scope, and CI state; inspect relevant callers and consumers.
|
|
34
|
+
2. Independently trace behavior and test applicable counterexamples. Separate severity from safety conditions.
|
|
35
|
+
3. Report only supported findings with evidence tier, smallest correction, regression, and positive control. Use `<this-skill-dir>/templates/finding.template.md`.
|
|
36
|
+
4. On re-review, disposition every prior finding at the new HEAD, then inspect for regressions.
|
|
37
|
+
5. Keep review read-only unless explicitly authorized. Do not claim “bug-free.”
|
|
38
|
+
|
|
39
|
+
In the interim, bind explicitly on an existing review step: `{"stepType":"review","optionalBindings":["code-review"]}`.
|
|
40
|
+
|
|
41
|
+
Deep dive: <this-skill-dir>/references/review-playbook.md
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# Review Playbook
|
|
2
|
+
|
|
3
|
+
Use this checklist for the applicable risks; do not force irrelevant categories.
|
|
4
|
+
|
|
5
|
+
## Establish scope and evidence
|
|
6
|
+
|
|
7
|
+
- [ ] Pin repository, PR, base/head SHA, user requirement or PRD/ADR, changed files, relevant callers/callees, and current CI state. Avoid unrelated checkout areas.
|
|
8
|
+
- [ ] Make an independent pass. Treat author explanations and tests as leads, not proof; derive expected behavior from contracts and source.
|
|
9
|
+
- [ ] Label evidence honestly: **executed/reproduced** (command, result, environment, SHA); **source-traced** (concrete path and preconditions); **inconclusive** (missing facts or ambiguous semantics; do not present as a proven blocker).
|
|
10
|
+
- [ ] Inventory user-facing entry points and configuration handoffs (CLI flags, cwd, path spellings, config loading). Exercise them end-to-end, not only the recently edited internals.
|
|
11
|
+
- [ ] Reproduce a candidate finding against the PR base before classifying it as new. Pre-existing defects are follow-ups, not new blockers.
|
|
12
|
+
|
|
13
|
+
## Try applicable counterexamples
|
|
14
|
+
|
|
15
|
+
- [ ] Missing, null, malformed input; old persisted state; base-to-candidate transitions; tenant/scope boundaries.
|
|
16
|
+
- [ ] Missing or broken dependencies: enumerate every entry point, including help, recovery, and stop paths; inspect fallback behavior.
|
|
17
|
+
- [ ] OS/shell differences; concurrency, crash, retry; user paths and symlinks; API/migration compatibility; downstream or generated views.
|
|
18
|
+
- [ ] Follow each important diagnostic/fact through every consumer and ancestor. Check whether required facts are computed before derived authority, indexes, or output.
|
|
19
|
+
- [ ] Compare new rules with previously accepted rules and controls. Separate display severity from safety prerequisites.
|
|
20
|
+
|
|
21
|
+
## Check tests and output
|
|
22
|
+
|
|
23
|
+
- [ ] Ask whether each test still passes if the behavior is disabled, bypassed, or broken (mutation thought experiment). Confirm the test is included in CI.
|
|
24
|
+
- [ ] When output text changes, compare the intended changed lines with literal templates; do not exclude changed lines from assertions.
|
|
25
|
+
- [ ] Dedupe findings. Use P1 for severe merge blockers, P2 for meaningful correctness/contract defects, P3 for low-risk issues; avoid speculation.
|
|
26
|
+
- [ ] For each finding, include exact path:line or diff anchor at HEAD SHA, trigger, observed behavior, violated contract and impact, evidence tier, smallest fix, negative regression, positive control, and disposition.
|
|
27
|
+
|
|
28
|
+
## Re-review and conclude
|
|
29
|
+
|
|
30
|
+
- [ ] Pin the new HEAD. Disposition every prior finding separately: resolved, still open, superseded, or inconclusive. Then inspect fix-induced side effects and new changes.
|
|
31
|
+
- [ ] Stay read-only unless the user/workflow explicitly authorizes action. Do not edit, comment, label, or merge on review authority alone.
|
|
32
|
+
- [ ] Summarize scope/SHA, CI, covered and unexamined risks, fixed/open/new counts, and evidence-grounded merge recommendation. “No actionable findings in examined scope” does not mean “bug-free.” Distinguish repository tests from live-host evidence.
|
|
33
|
+
|
|
34
|
+
## Per-finding format
|
|
35
|
+
|
|
36
|
+
`[P1/P2/P3] Title` — `path:line @ <HEAD SHA>`
|
|
37
|
+
|
|
38
|
+
**Trigger** → **behavior** → **contract violation / impact**. **Evidence:** executed / source-traced / inconclusive. **Minimal correction:** … **Regression:** negative case …; positive control … **Disposition:** blocker / follow-up / owner decision.
|
|
39
|
+
|
|
40
|
+
Use `<this-skill-dir>/templates/finding.template.md` for the complete findings and summary form.
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# Code Review — <PR or change>
|
|
2
|
+
|
|
3
|
+
## Scope and evidence
|
|
4
|
+
|
|
5
|
+
- Repository / PR:
|
|
6
|
+
- Base SHA → reviewed HEAD SHA:
|
|
7
|
+
- Requirement / PRD / ADR:
|
|
8
|
+
- Changed files and relevant callers/consumers:
|
|
9
|
+
- CI state and commands observed:
|
|
10
|
+
- Counterexample categories covered:
|
|
11
|
+
- Risks not examined / evidence limits:
|
|
12
|
+
|
|
13
|
+
## Findings
|
|
14
|
+
|
|
15
|
+
### [P1/P2/P3] <Short, specific title>
|
|
16
|
+
|
|
17
|
+
- **Location:** `<path>:<line or diff anchor> @ <HEAD SHA>`
|
|
18
|
+
- **Trigger:** <minimal input, state transition, or interleaving>
|
|
19
|
+
- **Behavior → impact:** <observed or source-traced behavior and violated contract>
|
|
20
|
+
- **Evidence tier:** <executed/reproduced | source-traced | inconclusive; include exact command/result or preconditions>
|
|
21
|
+
- **Minimal correction:** <smallest feasible fix>
|
|
22
|
+
- **Regression:** Negative case: <case that fails before fix>; positive control: <valid behavior that remains valid>
|
|
23
|
+
- **Disposition:** <blocker | follow-up | owner decision; for re-review, resolved | still open | superseded | inconclusive>
|
|
24
|
+
|
|
25
|
+
<!-- Duplicate this finding section as needed. Remove headings for which there are no findings. -->
|
|
26
|
+
|
|
27
|
+
## Summary
|
|
28
|
+
|
|
29
|
+
- **Scope / reviewed SHA:**
|
|
30
|
+
- **CI evidence:**
|
|
31
|
+
- **Covered / unexamined risks:**
|
|
32
|
+
- **Findings:** <fixed / open / new counts on re-review>
|
|
33
|
+
- **Conclusion:** <merge recommendation grounded in evidence; “no actionable findings in examined scope” is not a claim of bug-free code>
|
package/docs/openai-plugin.md
CHANGED
|
@@ -74,7 +74,7 @@ The local package path is distinct from the general `--codex` installer. The gen
|
|
|
74
74
|
The package tests prove the following repository-side contract:
|
|
75
75
|
|
|
76
76
|
- the portable root manifest and `.codex-plugin` compatibility manifest agree on identity, version, interface, and hook entry point;
|
|
77
|
-
- the root `skills/` tree contains exactly the
|
|
77
|
+
- the root `skills/` tree contains exactly the 27 canonical skills;
|
|
78
78
|
- Windows and POSIX hook commands resolve through `PLUGIN_ROOT`;
|
|
79
79
|
- session start emits the compact policy and prompt submission invokes invariant-first routing;
|
|
80
80
|
- supported local `Bash` and `apply_patch` calls receive the packaged guards and state tracking;
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
# Workflow: Code Review
|
|
2
|
+
|
|
3
|
+
> Independently review a PR, diff, or finished implementation for correctness, contract, and negative-path defects — read-only by default, with evidence-tiered, source-anchored findings.
|
|
4
|
+
|
|
5
|
+
Source of truth: `code-review/SKILL.md`.
|
|
6
|
+
|
|
7
|
+
Contract summary from SKILL.md — Trigger: requested review of a PR, diff, implementation, or revised HEAD. Output: source-anchored findings and an evidence-qualified summary. USE FOR: review a PR/diff/finished implementation before merge, re-review a revised HEAD (prior-finding disposition + new risks). DO NOT USE FOR: security-only threat modeling/secrets/OWASP (use `security-review`); design or plan stress-testing (use `grill-me`); running gates (use `verification-loop`); writing the fix (use `tdd`).
|
|
8
|
+
|
|
9
|
+
## 1. Skill Behavior Workflow
|
|
10
|
+
|
|
11
|
+
```mermaid
|
|
12
|
+
graph TD
|
|
13
|
+
A[Pinned Repo Principle BB And CI State] --> B[Read Diff And Relevant Callers Callees]
|
|
14
|
+
B --> C[Map State Trust Fallback Consumers Tests]
|
|
15
|
+
C --> D[Construct Counterexamples And Negative Paths]
|
|
16
|
+
D --> E[Verify Findings Against Source And CI]
|
|
17
|
+
E --> F{Actionable Supported Finding}
|
|
18
|
+
F -->|yes| G[P1 P2 P3 Severity Plus Evidence Tier Plus Minimal Fix Plus Regression]
|
|
19
|
+
F -->|no| H[Discard Qualify Or Mark Inconclusive]
|
|
20
|
+
G --> I[Report Read Only Only Authorized Actions Post]
|
|
21
|
+
H --> I
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
## 2. Triggering and Routing Path
|
|
25
|
+
|
|
26
|
+
```mermaid
|
|
27
|
+
graph TD
|
|
28
|
+
ReviewReq[Review This PR Or Diff Request] --> Skill[code-review SKILL]
|
|
29
|
+
ReReviewReq[Re-Review Fix At New HEAD] --> Skill
|
|
30
|
+
SecurityReq[Threat Model Secrets OWASP] --> NotCodeReview[security-review SKILL]
|
|
31
|
+
DesignReq[Stress Test Plan Or Design] --> Grm[grill-me SKILL]
|
|
32
|
+
GateReq[Run Build Test Lint Gates] --> VL[verification-loop SKILL]
|
|
33
|
+
FixReq[Implement Or Fix] --> Tdd[tdd SKILL]
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
## 3. Re-Review Cycle
|
|
37
|
+
|
|
38
|
+
```mermaid
|
|
39
|
+
graph TD
|
|
40
|
+
New[Fix Pushed New HEAD] --> Pin[Pin New SHA And Diff]
|
|
41
|
+
Pin --> Prior[Disposition Every Prior Finding Resolved Open Superseded Inconclusive]
|
|
42
|
+
Prior --> Regress[Inspect Fix For Induced Side Effects And New Changes]
|
|
43
|
+
Regress --> Sum[Summary Scope SHA CI Fixed Open New Counts Evidence-Grounded Recommendation]
|
|
44
|
+
Sum -->|fix needed| Fix[Fix New Defects]
|
|
45
|
+
Fix --> Pin
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
Template: `code-review/templates/finding.template.md`. Deep dive: `code-review/references/review-playbook.md`.
|
|
49
|
+
|
|
50
|
+
## 4. Verification Check
|
|
51
|
+
|
|
52
|
+
- [ ] Repository, contract, base/head SHA, changed scope, and CI state pinned before reviewing
|
|
53
|
+
- [ ] Independent pass completed; author explanations and tests treated as leads, not proof
|
|
54
|
+
- [ ] Applicable counterexamples constructed (missing/malformed input, persisted state, transitions, boundaries, degraded dependencies, OS/shell, concurrency); irrelevant categories not forced
|
|
55
|
+
- [ ] Every reported finding carries exact path:line/diff anchor at HEAD, trigger, observed behavior, violated contract, impact, evidence tier (executed / source-traced / inconclusive), smallest fix, negative regression, and positive control
|
|
56
|
+
- [ ] Prior findings dispositioned at the new HEAD on re-review, plus fix-induced regressions inspected
|
|
57
|
+
- [ ] Review stayed read-only unless explicitly authorized; no edits, comments, labels, or merges on review authority
|
|
58
|
+
- [ ] Summary distinguished "no actionable findings in examined scope" from "bug-free," with test/CI/live-host evidence boundaries stated
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
name: code-review-routing-eval
|
|
2
|
+
description: Trigger precision eval for the code-review skill.
|
|
3
|
+
skill: code-review
|
|
4
|
+
version: "1.0"
|
|
5
|
+
config:
|
|
6
|
+
trials_per_task: 1
|
|
7
|
+
timeout_seconds: 300
|
|
8
|
+
parallel: false
|
|
9
|
+
executor: copilot-sdk
|
|
10
|
+
model: claude-sonnet-4.6
|
|
11
|
+
metrics:
|
|
12
|
+
- name: task_completion
|
|
13
|
+
weight: 0.7
|
|
14
|
+
threshold: 0.8
|
|
15
|
+
description: Did code-review trigger exactly when it should, and stay dormant for neighboring skills' requests?
|
|
16
|
+
- name: efficiency
|
|
17
|
+
weight: 0.3
|
|
18
|
+
threshold: 0.7
|
|
19
|
+
description: Did the skill stay within behavior limits?
|
|
20
|
+
graders:
|
|
21
|
+
- type: behavior
|
|
22
|
+
name: token-budget
|
|
23
|
+
config:
|
|
24
|
+
max_tokens: 1200
|
|
25
|
+
tasks:
|
|
26
|
+
- "tasks/*.yaml"
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
id: negative-code-review-002
|
|
2
|
+
name: Plan stress-testing must route to grill-me, not code-review
|
|
3
|
+
description: Stress-testing a design or plan one question at a time is in code-review's DO NOT USE FOR scope and belongs to grill-me; code-review must stay dormant.
|
|
4
|
+
tags:
|
|
5
|
+
- negative-trigger
|
|
6
|
+
inputs:
|
|
7
|
+
prompt: "Re-review my plan, asking one question at a time: stress-test the new billing service plan until we agree on where retries live."
|
|
8
|
+
expected:
|
|
9
|
+
should_trigger: false
|
|
10
|
+
graders:
|
|
11
|
+
- type: text
|
|
12
|
+
name: not-contains-keywords
|
|
13
|
+
config:
|
|
14
|
+
contains:
|
|
15
|
+
- "source-anchored"
|
|
16
|
+
- "source-traced"
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
id: negative-code-review-001
|
|
2
|
+
name: Security threat modeling must route to security-review, not code-review
|
|
3
|
+
description: A security-only threat modeling request is in code-review's DO NOT USE FOR scope and belongs to security-review; code-review must stay dormant.
|
|
4
|
+
tags:
|
|
5
|
+
- negative-trigger
|
|
6
|
+
inputs:
|
|
7
|
+
prompt: "Re-review the STRIDE threat model for security only: do a full threat model of the new payments endpoint against the OWASP Top 10, including secrets exposure."
|
|
8
|
+
expected:
|
|
9
|
+
should_trigger: false
|
|
10
|
+
graders:
|
|
11
|
+
- type: text
|
|
12
|
+
name: not-contains-keywords
|
|
13
|
+
config:
|
|
14
|
+
contains:
|
|
15
|
+
- "source-anchored"
|
|
16
|
+
- "source-traced"
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
id: negative-code-review-004
|
|
2
|
+
name: Implementing the fix must route to tdd, not code-review
|
|
3
|
+
description: Writing the fix test-first is implementation work that belongs to tdd; code-review is read-only and must stay dormant.
|
|
4
|
+
tags:
|
|
5
|
+
- negative-trigger
|
|
6
|
+
inputs:
|
|
7
|
+
prompt: "Fix the off-by-one error in the pagination helper. Write a regression test first, then make it pass."
|
|
8
|
+
expected:
|
|
9
|
+
should_trigger: false
|
|
10
|
+
graders:
|
|
11
|
+
- type: text
|
|
12
|
+
name: not-contains-keywords
|
|
13
|
+
config:
|
|
14
|
+
contains:
|
|
15
|
+
- "source-anchored"
|
|
16
|
+
- "source-traced"
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
id: negative-code-review-003
|
|
2
|
+
name: Running the gates must route to verification-loop, not code-review
|
|
3
|
+
description: Running the build, types, lint and test gates is an objective check that belongs to verification-loop; code-review must stay dormant.
|
|
4
|
+
tags:
|
|
5
|
+
- negative-trigger
|
|
6
|
+
inputs:
|
|
7
|
+
prompt: "Run the build, type check, lint and the full test suite on this branch and tell me which gates pass."
|
|
8
|
+
expected:
|
|
9
|
+
should_trigger: false
|
|
10
|
+
graders:
|
|
11
|
+
- type: text
|
|
12
|
+
name: not-contains-keywords
|
|
13
|
+
config:
|
|
14
|
+
contains:
|
|
15
|
+
- "source-anchored"
|
|
16
|
+
- "source-traced"
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
id: positive-code-review-001
|
|
2
|
+
name: Pre-merge PR review request triggers code-review
|
|
3
|
+
description: "Independently review a PR, diff or finished implementation for correctness, contract and negative-path defects, with source-anchored findings labelled executed, source-traced or inconclusive; read-only by default. USE FOR: \"review this PR before merge\", \"re-review the fix at the new HEAD\". DO NOT USE FOR: \"security threat modeling\", \"implementing or fixing the code\"."
|
|
4
|
+
tags:
|
|
5
|
+
- positive-trigger
|
|
6
|
+
inputs:
|
|
7
|
+
prompt: "Review PR #412 before we merge it. Check the diff for correctness and negative-path defects against the contract in the PRD, and label each finding as executed, source-traced or inconclusive."
|
|
8
|
+
expected:
|
|
9
|
+
should_trigger: true
|
|
10
|
+
graders:
|
|
11
|
+
- type: text
|
|
12
|
+
name: contains-keywords
|
|
13
|
+
config:
|
|
14
|
+
contains:
|
|
15
|
+
- "source-traced"
|
|
16
|
+
- "inconclusive"
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
id: positive-code-review-002
|
|
2
|
+
name: Re-review of a revised HEAD triggers code-review
|
|
3
|
+
description: "Independently review a PR, diff or finished implementation for correctness, contract and negative-path defects, with source-anchored findings labelled executed, source-traced or inconclusive; read-only by default. USE FOR: \"review this PR before merge\", \"re-review the fix at the new HEAD\". DO NOT USE FOR: \"security threat modeling\", \"implementing or fixing the code\"."
|
|
4
|
+
tags:
|
|
5
|
+
- positive-trigger
|
|
6
|
+
inputs:
|
|
7
|
+
prompt: "The author pushed a new commit to address last round's findings. Re-review the new HEAD: check each prior finding on its own as resolved, still open or superseded, and look for regressions the fix introduced."
|
|
8
|
+
expected:
|
|
9
|
+
should_trigger: true
|
|
10
|
+
graders:
|
|
11
|
+
- type: text
|
|
12
|
+
name: contains-keywords
|
|
13
|
+
config:
|
|
14
|
+
contains:
|
|
15
|
+
- "prior finding"
|
|
16
|
+
- "HEAD"
|
|
@@ -18,6 +18,7 @@ Every skill in this repository is reachable from this router. If a task matches
|
|
|
18
18
|
| `grill-me` | Tier 2 | User asks to be grilled on a plan (pure Q&A). |
|
|
19
19
|
| `improve-codebase-architecture` | Tier 2 | Deep architectural analysis / refactor planning. |
|
|
20
20
|
| `eval-harness` | Tier 2 | Scoring, stress testing, benchmark comparison. |
|
|
21
|
+
| `code-review` | Tier 2 | Explicit review requests of a PR/diff/finished implementation: correctness, contract, and negative-path findings with evidence tiers, read-only by default — not threat modeling (`security-review`), plan interrogation (`grill-me`), or gate running (`verification-loop`). |
|
|
21
22
|
| `verification-loop` | Tier 2/3 gate | Before declaring done or creating a PR. |
|
|
22
23
|
| `security-review` | Tier 2/3 gate | Changes touching auth, input handling, secrets, network boundaries. |
|
|
23
24
|
| `fable-mode` | Tier 3 | v3 staged planning, named-agent delegation, model selection, failable gates, and cold review. |
|
|
@@ -611,6 +611,13 @@
|
|
|
611
611
|
"bindings": [
|
|
612
612
|
"zoom-out"
|
|
613
613
|
]
|
|
614
|
+
},
|
|
615
|
+
{
|
|
616
|
+
"id": "review",
|
|
617
|
+
"bindings": [
|
|
618
|
+
"code-review"
|
|
619
|
+
],
|
|
620
|
+
"regex": "\\b(?:code[- ]review|pr review)\\b|\\b(?:re-)?review\\s+(?:(?:(?:this|the|my)\\s+)?(?:pr\\b|pull request\\b|diff\\b|(?:finished\\s+)?implementation\\b(?!\\s+plan\\b))|the\\s+(?:fix\\b|new\\s+head\\b))|程式碼審查|代码审查"
|
|
614
621
|
}
|
|
615
622
|
]
|
|
616
623
|
}
|
|
@@ -40,6 +40,7 @@ const PACKAGED_BINDING_PATHS = {
|
|
|
40
40
|
'git-commit': 'git-commit/SKILL.md',
|
|
41
41
|
'security-review': 'security-review/SKILL.md',
|
|
42
42
|
'review-guidance': 'harness-everything/references/triage-and-tiers.md',
|
|
43
|
+
'code-review': 'code-review/SKILL.md',
|
|
43
44
|
};
|
|
44
45
|
const SKILL_ID = /^[a-z0-9][a-z0-9-]{0,63}$/;
|
|
45
46
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "harness-everything",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.33.0",
|
|
4
4
|
"description": "Harness OS: An Orchestrated Agent Operating System for AI-driven Development",
|
|
5
5
|
"main": "harness-everything/scripts/bootstrap.js",
|
|
6
6
|
"bin": {
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"test:consistency": "node ci/consistency-check.js && node ci/doc-capability-consistency.test.js && node ci/repository-contract.test.js && node ci/mechanism-2ao-plugin-sync.test.js && node ci/prompt-contract-regressions.test.js",
|
|
21
21
|
"test:docs:capabilities": "node ci/doc-capability-consistency.test.js",
|
|
22
22
|
"test:references": "node ci/reference-check.js",
|
|
23
|
-
"test:release": "node ci/release-consistency-check.js && node ci/mechanism-2x-release-automation.test.js && node ci/mechanism-2x-release-commit-message.test.js && node ci/mechanism-2ap-sbom.test.js",
|
|
23
|
+
"test:release": "node ci/release-consistency-check.js && node ci/release-consistency-check.test.js && node ci/mechanism-2x-release-automation.test.js && node ci/mechanism-2x-release-commit-message.test.js && node ci/mechanism-2ap-sbom.test.js",
|
|
24
24
|
"test:release:semantics": "node ci/semantic-release-analyzer.test.mjs",
|
|
25
25
|
"test:install": "node scripts/verify-install.js",
|
|
26
26
|
"system-one:install": "node harness-everything/scripts/system-one/install.js",
|
|
@@ -40,6 +40,7 @@ const PACKAGED_BINDING_PATHS = {
|
|
|
40
40
|
'git-commit': 'git-commit/SKILL.md',
|
|
41
41
|
'security-review': 'security-review/SKILL.md',
|
|
42
42
|
'review-guidance': 'harness-everything/references/triage-and-tiers.md',
|
|
43
|
+
'code-review': 'code-review/SKILL.md',
|
|
43
44
|
};
|
|
44
45
|
const SKILL_ID = /^[a-z0-9][a-z0-9-]{0,63}$/;
|
|
45
46
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://agent-plugins.org/schemas/1.0.0/plugin.schema.json",
|
|
3
3
|
"name": "harness-everything",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.33.0",
|
|
5
5
|
"description": "Invariant-first engineering harness for routing, verification, and failure recovery while preserving agent autonomy.",
|
|
6
6
|
"author": {
|
|
7
7
|
"name": "Miya Daniel",
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: code-review
|
|
3
|
+
description: "Independently review a PR, diff or finished implementation for correctness, contract and negative-path defects, with source-anchored findings labelled executed, source-traced or inconclusive; read-only by default. USE FOR: \"review this PR before merge\", \"re-review the fix at the new HEAD\". DO NOT USE FOR: \"security threat modeling\", \"implementing or fixing the code\"."
|
|
4
|
+
license: Apache-2.0
|
|
5
|
+
metadata:
|
|
6
|
+
author: Miya Daniel
|
|
7
|
+
version: 0.33.0
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# Code Review
|
|
11
|
+
|
|
12
|
+
Independently review completed changes for correctness, contract violations, and negative-path defects. Default to read-only.
|
|
13
|
+
|
|
14
|
+
## 📋 Skill Contract
|
|
15
|
+
|
|
16
|
+
| Component | Specification |
|
|
17
|
+
| :--- | :--- |
|
|
18
|
+
| **Trigger / Input** | Requested review of a PR, diff, implementation, or revised HEAD. |
|
|
19
|
+
| **Expected Output** | Source-anchored findings and an evidence-qualified summary. |
|
|
20
|
+
| **State Mutations** | None unless the user explicitly authorizes an action. |
|
|
21
|
+
| **Enforcement Gate** | Apply the checklist in `<this-skill-dir>/references/review-playbook.md`. |
|
|
22
|
+
|
|
23
|
+
## USE FOR:
|
|
24
|
+
- Review a PR / diff / finished implementation before merge
|
|
25
|
+
- Re-review a revised HEAD: prior-finding disposition + new risks
|
|
26
|
+
|
|
27
|
+
## DO NOT USE FOR:
|
|
28
|
+
- Security-only threat modeling / secrets / OWASP (use `security-review`)
|
|
29
|
+
- Design or plan stress-testing (use `grill-me`); running gates (use `verification-loop`); writing the fix (use `tdd`)
|
|
30
|
+
|
|
31
|
+
## Workflow
|
|
32
|
+
|
|
33
|
+
1. Pin repository, contract, base/head, changed scope, and CI state; inspect relevant callers and consumers.
|
|
34
|
+
2. Independently trace behavior and test applicable counterexamples. Separate severity from safety conditions.
|
|
35
|
+
3. Report only supported findings with evidence tier, smallest correction, regression, and positive control. Use `<this-skill-dir>/templates/finding.template.md`.
|
|
36
|
+
4. On re-review, disposition every prior finding at the new HEAD, then inspect for regressions.
|
|
37
|
+
5. Keep review read-only unless explicitly authorized. Do not claim “bug-free.”
|
|
38
|
+
|
|
39
|
+
In the interim, bind explicitly on an existing review step: `{"stepType":"review","optionalBindings":["code-review"]}`.
|
|
40
|
+
|
|
41
|
+
Deep dive: <this-skill-dir>/references/review-playbook.md
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# Review Playbook
|
|
2
|
+
|
|
3
|
+
Use this checklist for the applicable risks; do not force irrelevant categories.
|
|
4
|
+
|
|
5
|
+
## Establish scope and evidence
|
|
6
|
+
|
|
7
|
+
- [ ] Pin repository, PR, base/head SHA, user requirement or PRD/ADR, changed files, relevant callers/callees, and current CI state. Avoid unrelated checkout areas.
|
|
8
|
+
- [ ] Make an independent pass. Treat author explanations and tests as leads, not proof; derive expected behavior from contracts and source.
|
|
9
|
+
- [ ] Label evidence honestly: **executed/reproduced** (command, result, environment, SHA); **source-traced** (concrete path and preconditions); **inconclusive** (missing facts or ambiguous semantics; do not present as a proven blocker).
|
|
10
|
+
- [ ] Inventory user-facing entry points and configuration handoffs (CLI flags, cwd, path spellings, config loading). Exercise them end-to-end, not only the recently edited internals.
|
|
11
|
+
- [ ] Reproduce a candidate finding against the PR base before classifying it as new. Pre-existing defects are follow-ups, not new blockers.
|
|
12
|
+
|
|
13
|
+
## Try applicable counterexamples
|
|
14
|
+
|
|
15
|
+
- [ ] Missing, null, malformed input; old persisted state; base-to-candidate transitions; tenant/scope boundaries.
|
|
16
|
+
- [ ] Missing or broken dependencies: enumerate every entry point, including help, recovery, and stop paths; inspect fallback behavior.
|
|
17
|
+
- [ ] OS/shell differences; concurrency, crash, retry; user paths and symlinks; API/migration compatibility; downstream or generated views.
|
|
18
|
+
- [ ] Follow each important diagnostic/fact through every consumer and ancestor. Check whether required facts are computed before derived authority, indexes, or output.
|
|
19
|
+
- [ ] Compare new rules with previously accepted rules and controls. Separate display severity from safety prerequisites.
|
|
20
|
+
|
|
21
|
+
## Check tests and output
|
|
22
|
+
|
|
23
|
+
- [ ] Ask whether each test still passes if the behavior is disabled, bypassed, or broken (mutation thought experiment). Confirm the test is included in CI.
|
|
24
|
+
- [ ] When output text changes, compare the intended changed lines with literal templates; do not exclude changed lines from assertions.
|
|
25
|
+
- [ ] Dedupe findings. Use P1 for severe merge blockers, P2 for meaningful correctness/contract defects, P3 for low-risk issues; avoid speculation.
|
|
26
|
+
- [ ] For each finding, include exact path:line or diff anchor at HEAD SHA, trigger, observed behavior, violated contract and impact, evidence tier, smallest fix, negative regression, positive control, and disposition.
|
|
27
|
+
|
|
28
|
+
## Re-review and conclude
|
|
29
|
+
|
|
30
|
+
- [ ] Pin the new HEAD. Disposition every prior finding separately: resolved, still open, superseded, or inconclusive. Then inspect fix-induced side effects and new changes.
|
|
31
|
+
- [ ] Stay read-only unless the user/workflow explicitly authorizes action. Do not edit, comment, label, or merge on review authority alone.
|
|
32
|
+
- [ ] Summarize scope/SHA, CI, covered and unexamined risks, fixed/open/new counts, and evidence-grounded merge recommendation. “No actionable findings in examined scope” does not mean “bug-free.” Distinguish repository tests from live-host evidence.
|
|
33
|
+
|
|
34
|
+
## Per-finding format
|
|
35
|
+
|
|
36
|
+
`[P1/P2/P3] Title` — `path:line @ <HEAD SHA>`
|
|
37
|
+
|
|
38
|
+
**Trigger** → **behavior** → **contract violation / impact**. **Evidence:** executed / source-traced / inconclusive. **Minimal correction:** … **Regression:** negative case …; positive control … **Disposition:** blocker / follow-up / owner decision.
|
|
39
|
+
|
|
40
|
+
Use `<this-skill-dir>/templates/finding.template.md` for the complete findings and summary form.
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# Code Review — <PR or change>
|
|
2
|
+
|
|
3
|
+
## Scope and evidence
|
|
4
|
+
|
|
5
|
+
- Repository / PR:
|
|
6
|
+
- Base SHA → reviewed HEAD SHA:
|
|
7
|
+
- Requirement / PRD / ADR:
|
|
8
|
+
- Changed files and relevant callers/consumers:
|
|
9
|
+
- CI state and commands observed:
|
|
10
|
+
- Counterexample categories covered:
|
|
11
|
+
- Risks not examined / evidence limits:
|
|
12
|
+
|
|
13
|
+
## Findings
|
|
14
|
+
|
|
15
|
+
### [P1/P2/P3] <Short, specific title>
|
|
16
|
+
|
|
17
|
+
- **Location:** `<path>:<line or diff anchor> @ <HEAD SHA>`
|
|
18
|
+
- **Trigger:** <minimal input, state transition, or interleaving>
|
|
19
|
+
- **Behavior → impact:** <observed or source-traced behavior and violated contract>
|
|
20
|
+
- **Evidence tier:** <executed/reproduced | source-traced | inconclusive; include exact command/result or preconditions>
|
|
21
|
+
- **Minimal correction:** <smallest feasible fix>
|
|
22
|
+
- **Regression:** Negative case: <case that fails before fix>; positive control: <valid behavior that remains valid>
|
|
23
|
+
- **Disposition:** <blocker | follow-up | owner decision; for re-review, resolved | still open | superseded | inconclusive>
|
|
24
|
+
|
|
25
|
+
<!-- Duplicate this finding section as needed. Remove headings for which there are no findings. -->
|
|
26
|
+
|
|
27
|
+
## Summary
|
|
28
|
+
|
|
29
|
+
- **Scope / reviewed SHA:**
|
|
30
|
+
- **CI evidence:**
|
|
31
|
+
- **Covered / unexamined risks:**
|
|
32
|
+
- **Findings:** <fixed / open / new counts on re-review>
|
|
33
|
+
- **Conclusion:** <merge recommendation grounded in evidence; “no actionable findings in examined scope” is not a claim of bug-free code>
|
|
@@ -18,6 +18,7 @@ Every skill in this repository is reachable from this router. If a task matches
|
|
|
18
18
|
| `grill-me` | Tier 2 | User asks to be grilled on a plan (pure Q&A). |
|
|
19
19
|
| `improve-codebase-architecture` | Tier 2 | Deep architectural analysis / refactor planning. |
|
|
20
20
|
| `eval-harness` | Tier 2 | Scoring, stress testing, benchmark comparison. |
|
|
21
|
+
| `code-review` | Tier 2 | Explicit review requests of a PR/diff/finished implementation: correctness, contract, and negative-path findings with evidence tiers, read-only by default — not threat modeling (`security-review`), plan interrogation (`grill-me`), or gate running (`verification-loop`). |
|
|
21
22
|
| `verification-loop` | Tier 2/3 gate | Before declaring done or creating a PR. |
|
|
22
23
|
| `security-review` | Tier 2/3 gate | Changes touching auth, input handling, secrets, network boundaries. |
|
|
23
24
|
| `fable-mode` | Tier 3 | v3 staged planning, named-agent delegation, model selection, failable gates, and cold review. |
|
|
@@ -611,6 +611,13 @@
|
|
|
611
611
|
"bindings": [
|
|
612
612
|
"zoom-out"
|
|
613
613
|
]
|
|
614
|
+
},
|
|
615
|
+
{
|
|
616
|
+
"id": "review",
|
|
617
|
+
"bindings": [
|
|
618
|
+
"code-review"
|
|
619
|
+
],
|
|
620
|
+
"regex": "\\b(?:code[- ]review|pr review)\\b|\\b(?:re-)?review\\s+(?:(?:(?:this|the|my)\\s+)?(?:pr\\b|pull request\\b|diff\\b|(?:finished\\s+)?implementation\\b(?!\\s+plan\\b))|the\\s+(?:fix\\b|new\\s+head\\b))|程式碼審查|代码审查"
|
|
614
621
|
}
|
|
615
622
|
]
|
|
616
623
|
}
|
package/sbom.cdx.json
CHANGED
|
@@ -2,23 +2,23 @@
|
|
|
2
2
|
"$schema": "https://cyclonedx.org/schema/bom-1.7.schema.json",
|
|
3
3
|
"bomFormat": "CycloneDX",
|
|
4
4
|
"specVersion": "1.7",
|
|
5
|
-
"serialNumber": "urn:uuid:
|
|
5
|
+
"serialNumber": "urn:uuid:52f0d0e2-1bad-500d-83b5-0965e29f6e5d",
|
|
6
6
|
"version": 1,
|
|
7
7
|
"metadata": {
|
|
8
|
-
"timestamp": "2026-10-
|
|
8
|
+
"timestamp": "2026-10-17T15:47:14.418Z",
|
|
9
9
|
"tools": [
|
|
10
10
|
{
|
|
11
11
|
"vendor": "Harness Everything",
|
|
12
12
|
"name": "generate-sbom.js",
|
|
13
|
-
"version": "0.
|
|
13
|
+
"version": "0.33.0"
|
|
14
14
|
}
|
|
15
15
|
],
|
|
16
16
|
"component": {
|
|
17
17
|
"type": "application",
|
|
18
|
-
"bom-ref": "pkg:npm/harness-everything@0.
|
|
18
|
+
"bom-ref": "pkg:npm/harness-everything@0.33.0",
|
|
19
19
|
"name": "harness-everything",
|
|
20
|
-
"version": "0.
|
|
21
|
-
"purl": "pkg:npm/harness-everything@0.
|
|
20
|
+
"version": "0.33.0",
|
|
21
|
+
"purl": "pkg:npm/harness-everything@0.33.0"
|
|
22
22
|
}
|
|
23
23
|
},
|
|
24
24
|
"components": [
|
|
@@ -1999,7 +1999,7 @@
|
|
|
1999
1999
|
]
|
|
2000
2000
|
},
|
|
2001
2001
|
{
|
|
2002
|
-
"ref": "pkg:npm/harness-everything@0.
|
|
2002
|
+
"ref": "pkg:npm/harness-everything@0.33.0",
|
|
2003
2003
|
"dependsOn": [
|
|
2004
2004
|
"pkg:npm/%40commitlint/cli@19.8.1",
|
|
2005
2005
|
"pkg:npm/%40commitlint/config-conventional@19.8.1",
|