openspec-peer-review
Skill1 starsChanged 59 days agoApache-2.0View on GitHub
Emits an objective Peer Review Findings section and rewrites an OpenSpec package to satisfy quality standards. Use this whenever the user asks to review, critique, or polish an existing plan, or as the final step in generating an OpenSpec package.
In this repository39 other files it gives its agents.
- agent-core/AGENTS.mdAGENTS.md
- .agents/AGENTS.mdAGENTS.md
- AGENTS.mdAGENTS.md
- behavioral-regression/AGENTS.mdAGENTS.md
- claude-foundation/AGENTS.mdAGENTS.md
- config/AGENTS.mdAGENTS.md
- corpora/AGENTS.mdAGENTS.md
- demo/AGENTS.mdAGENTS.md
- docs/AGENTS.mdAGENTS.md
- examples/AGENTS.mdAGENTS.md
- experiments/AGENTS.mdAGENTS.md
- flow-corpus/AGENTS.mdAGENTS.md
- flow-protocol/AGENTS.mdAGENTS.md
- openspec/AGENTS.mdAGENTS.md
- scripts/AGENTS.mdAGENTS.md
- skills/AGENTS.mdAGENTS.md
- tests/AGENTS.mdAGENTS.md
- claude-foundation/CLAUDE.mdCLAUDE.md
- merge-gate-auditorSkill
- update-executive-reportSkill
- update-executive-reportSkill
- architecture-drift-guardSkill
- commonSkill
- corpus-guardianSkill
- dataset-lintSkill
- deploySkill
- e2e-matrix-sentinelSkill
- eval-corpus-forgeSkill
- hierarchical-recursive-brainstormSkill
- model-benchSkill
- openai-judgeSkill
- openspec-implementation-reviewSkill
- openspec-quality-planSkill
- pre-pr-gateSkill
- project-setupSkill
- quality-gateSkill
- refactoring-decomposerSkill
- repo-invariant-reviewSkill
- test-completeness-guardSkill
The file
We split this skill into the rules it gives an agent
2 rules. About 0 are common, 1 is distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 44
If the input is not a recognizable plan, ask for a valid OpenSpec package.
- Very specific: line 50
Run structural only (python scripts/validate_skill.py --skill .
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
openspec-peer-review — E2E Action Skill
Perform OpenSpec peer review end to end: take an existing OpenSpec package, emit objective review findings, and rewrite the package to meet quality standards.
1. Preconditions (input contract)
- The user has provided an existing OpenSpec package or plan.
- You have reviewed the composition contract and examples in
references/research-application.md.
2. Procedure (the E2E steps)
Execute the following review protocol (long form + worked examples in
references/two-pass-protocol.md):
- Pass 1 — mechanical fact-check. Pin the tree under review (record the commit SHA). Re-derive every falsifiable claim in the package against that tree — run the command, read the file:line, execute the config — and record a per-claim verdict: CONFIRMED / CORRECTED / REFUTED, each with evidence. No claim is accepted on the strength of the source document alone.
- Pass 2 — adversarial design review. Attack the design: failure modes, CI-invariant collisions, contract mismatches, silent-drift paths. Verify each attack before keeping it; an attack that dies under verification is recorded as refuted, never deleted — a reviewed-and-rejected risk is information the next reviewer needs.
- Critique: Analyze the input package against the quality standards defined by
openspec-quality-plan(mandatory "Code Hygiene & Quality Gates", phase-level hygiene gates, backwards compatibility, zero hard-coded configuration). - Emit Findings: Output a "Peer Review Findings" section explicitly listing the shortcomings and necessary improvements, ordered confirmed premises → defects found in the tree → corrections that reshaped the design → refuted attacks. This section must appear before any rewritten files.
- Rewrite: Rewrite the entire OpenSpec package incorporating the improvements, ensuring it fully meets every quality standard.
3. Output contract (postconditions — what "done" means)
- A "Peer Review Findings" section appears first, in the pass-derived order above, with the reviewed tree's SHA and a verdict + evidence per falsifiable claim.
- A rewritten OpenSpec package follows the findings.
- The rewritten package strictly satisfies the
openspec-quality-planstandards. - Refuted attacks from pass 2 remain in the findings (marked refuted), not silently dropped.
4. Failure handling
- If the input is not a recognizable plan, ask for a valid OpenSpec package.
5. Validation gate (before declaring success)
Subjective skill validation: There is no honest scripted gate for the quality of a peer review.
- Run structural only (
python scripts/validate_skill.py --skill . --tier structural) to keep the metadata/triggering honest. - Self-check against explicit, concrete criteria:
- Findings Ordered First: The "Peer Review Findings" section is the first element of the output.
- Standards Met: The rewritten package includes the "Code Hygiene & Quality Gates" and phase-level hygiene gates.
- Claims Pinned: Pass 1 names the tree SHA it re-derived against, and every falsifiable claim carries a CONFIRMED / CORRECTED / REFUTED verdict with evidence.
- Refuted Attacks Kept: Pass 2's rejected attacks appear in the findings, marked refuted.
6. Examples
See references/research-application.md for concrete examples, and
references/two-pass-protocol.md for two full worked reviews from this repository.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

