spec-review

spec-review is a command for Claude Code from fengshao1227/ccg-workflow. It costs 16 tokens per session (1,914 once invoked), scanned A, original, MIT.

A command for reviewing an OpenSpec proposal with two separate AI models. OpenSpec is a way to describe planned software changes before implementation.

In plain words
What is it for?
It is for checking changed files against a proposal, its specifications, and property-based testing requirements, then combining the reviewers' findings.
Why use it?
Using two independent reviews can reveal missed requirements or code-quality problems before work continues.

Command for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: reads .claude/ paths.

Part of the ccg plugin — 58 skills, 12 commands, 7 agents shipped together

Good fit It is for checking changed files against a proposal, its specifications, and property-based testing requirements, then combining the reviewers' findings.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/fengshao1227/ccg-workflow/spec-review
About the project

CCG is a command-line workflow engine that coordinates Claude, Codex, Gemini, and other models as specialized collaborators on coding tasks. It is used to analyze requests, choose a strategy, delegate work to model-specific roles, and combine their results. The catalogue entries provide the skills, commands, agents, and plugin that implement this workflow.

fengshao1227/ccg-workflow · 5,881 stars · on GitHub · ccg.fengshao1227.com

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/fengshao1227/ccg-workflow

Made for: Claude Code.

Or install ccg, the plugin that ships this one along with the rest of its 58 skills, 12 commands, 7 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for spec-review

README.md
[![agentmods](https://agentmods.dev/badge/commands/fengshao1227/ccg-workflow/spec-review/github.svg)](https://agentmods.dev/commands/fengshao1227/ccg-workflow/spec-review)
Your own site
<a href="https://agentmods.dev/commands/fengshao1227/ccg-workflow/spec-review"><img src="https://agentmods.dev/badge/commands/fengshao1227/ccg-workflow/spec-review/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for spec-review

Your own site · 80×15
<a href="https://agentmods.dev/commands/fengshao1227/ccg-workflow/spec-review"><img src="https://agentmods.dev/badge/commands/fengshao1227/ccg-workflow/spec-review.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 16 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,914 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00016 $0.01914
Opus 5 $0.00008 $0.00957
Sonnet 5 $0.00003 $0.00383
Haiku 4.5 $0.00002 $0.00191

Measured 9d ago against content hash 7030c200d7e1, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

spec-review scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

Origin

Copies of this mod

1 near-identical copy found in the catalogue:

templates/commands/spec-review.md · 125 lines

How it starts

The opening of the file, as written. The whole thing — 125 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Core Philosophy

  • Dual-model cross-validation catches blind spots single-model review would miss.
  • Critical findings SHOULD be addressed before proceeding.
  • Review validates implementation against spec constraints and code quality.
  • This is an independent review tool—can be used anytime, not tied to archive workflow.

Guardrails

  • MANDATORY: Both {{BACKEND_PRIMARY}} AND {{FRONTEND_PRIMARY}} must complete review before synthesis.
  • Review scope is strictly limited to the proposal's changes—no scope creep.
  • Refer to openspec/config.yaml for project conventions when reviewing OpenSpec proposals.

Steps

  1. Select Proposal

    • Run openspec list --json to display Active Changes.
    • Confirm with user which proposal ID to review.
    • Run openspec status --change "<proposal_id>" --json to load spec and tasks.
  2. Collect Implementation Artifacts

    • Identify all files modified by this proposal.
    • Use git diff to get change summary.
    • Load relevant spec constraints and PBT properties from openspec/changes/<id>/specs/.
  3. Multi-Model Review (PARALLEL)

    • CRITICAL: You MUST launch BOTH {{BACKEND_PRIMARY}} AND {{FRONTEND_PRIMARY}} in a SINGLE message with TWO Bash tool calls.
    • DO NOT call one model first and wait. Launch BOTH simultaneously with run_in_background: true.
    • 工作目录{{WORKDIR}} 必须通过 Bash 执行 pwd(Unix)或 cd(Windows CMD)获取当前工作目录的绝对路径,禁止从 $HOME 或环境变量推断。如果用户通过 /add-dir 添加了多个工作区,先确定任务相关的工作区。

    Step 3.1: In ONE message, make TWO parallel Bash calls:

    FIRST Bash call ({{BACKEND_PRIMARY}}):

    Bash({
      command: "~/.claude/bin/codeagent-wrapper --progress --backend {{BACKEND_PRIMARY}} {{GEMINI_MODEL_FLAG}}{{GROK_MODEL_FLAG}}{{KIMI_MODEL_FLAG}}{{OPENCODE_MODEL_FLAG}}- \"{{WORKDIR}}\" <<'EOF'\nReview proposal <proposal_id> implementation:\n\n## {{BACKEND_PRIMARY}} Review Dimensions\n1. **Spec Compliance**: Verify ALL constraints from spec are satisfied\n2. **PBT Properties**: Check invariants, idempotency, bounds are correctly implemented\n3. **Logic Correctness**: Edge cases, error handling, algorithm correctness\n4. **Backend Security**: Injection vulnerabilities, auth checks, input validation\n5. **Regression Risk**: Interface compatibility, type safety, breaking changes\n\n## Output Format (JSON)\n{\n  \"findings\": [\n    {\n      \"severity\": \"Critical|Warning|Info\",\n      \"dimension\": \"spec_compliance|pbt|logic|security|regression\",\n      \"file\": \"path/to/file.ts\",\n      \"line\": 42,\n      \"description\": \"What is wrong\",\n      \"constraint_violated\": \"Constraint ID from spec (if applicable)\",\n      \"fix_suggestion\": \"How to fix\"\n    }\n  ],\n  \"passed_checks\": [\"List of verified constraints/properties\"],\n  \"summary\": \"Overall assessment\"\n}\nEOF",
      run_in_background: true,
      timeout: 300000,
      description: "{{BACKEND_PRIMARY}}: backend/logic review"
    })
    

    SECOND Bash call ({{FRONTEND_PRIMARY}}) - IN THE SAME MESSAGE:

    Bash({
      command: "~/.claude/bin/codeagent-wrapper --progress --backend {{FRONTEND_PRIMARY}} {{GEMINI_MODEL_FLAG}}{{GROK_MODEL_FLAG}}{{KIMI_MODEL_FLAG}}{{OPENCODE_MODEL_FLAG}}- \"{{WORKDIR}}\" <<'EOF'\nReview proposal <proposal_id> implementation:\n\n## {{FRONTEND_PRIMARY}} Review Dimensions\n1. **Pattern Consistency**: Naming conventions, code style, project patterns\n2. **Maintainability**: Readability, complexity, documentation adequacy\n3. **Integration Risk**: Dependency changes, cross-module impacts\n4. **Frontend Security**: XSS, CSRF, sensitive data exposure\n5. **Spec Alignment**: Implementation matches spec intent (not just letter)\n\n## Output Format (JSON)\n{\n  \"findings\": [\n    {\n      \"severity\": \"Critical|Warning|Info\",\n      \"dimension\": \"patterns|maintainability|integration|security|alignment\",\n      \"file\": \"path/to/file.ts\",\n      \"line\": 42,\n      \"description\": \"What is wrong\",\n      \"spec_reference\": \"Spec section (if applicable)\",\n      \"fix_suggestion\": \"How to fix\"\n    }\n  ],\n  \"passed_checks\": [\"List of verified aspects\"],\n  \"summary\": \"Overall assessment\"\n}\nEOF",
      run_in_background: true,
      timeout: 300000,
      description: "{{FRONTEND_PRIMARY}}: patterns/integration review"
    })
    

Read the full file on GitHub · 125 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 125 lines · 16 tokens per session scan A 7030c200d7e1

Subscribe to this mod's changes

spec-review is a command published in the GitHub repository fengshao1227/ccg-workflow (5,881 stars, last pushed 6d ago), licensed MIT. It adds 16 tokens to every session and 1,914 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.