Skip to content

New plugin: plan-coverage — verify plan covers all spec requirements #33

Description

@dapi

Summary

Agent plan-coverage inside plan-reviewer plugin (#34). Verifies that an implementation plan fully covers the source specification. Maps spec requirements ↔ plan steps bidirectionally.

File: plan-reviewer/agents/plan-coverage.md

Triggered by: /review-plan plan.md --spec <spec-url>

Problem

After writing-plans generates a plan from a spec, there's no verification that:

  • Every spec requirement has corresponding plan step(s)
  • Every plan step traces back to a spec requirement (no orphan steps)
  • Acceptance criteria from spec are covered by test steps in plan

This is a traceability problem, orthogonal to grounding (#32).

What plan-coverage checks

Input

  • Implementation plan (docs/plans/*.md) — parsed by orchestrator
  • Source spec (GitHub issue URL, Google Doc, local file, Docmost page)

Checks

  1. Forward coverage: spec requirement → plan steps (find MISSING)
  2. Backward traceability: plan step → spec requirement (find ORPHAN steps)
  3. AC coverage: acceptance criteria → test steps in plan
  4. Coverage score: % of requirements covered, % of AC covered

Output format

Findings with COV-* prefix:

Coverage: plan.md <-> spec #45

  COV-1  R1: User can login        -> Task 2, 3       COVERED
  COV-2  R2: Password reset        -> Task 5           COVERED
  COV-3  R3: 2FA support           -> (none)           MISSING
  COV-4  AC1: Error on wrong pass  -> Task 2 Step 1    COVERED
  COV-5  AC2: Lockout after 5 fail -> (none)           MISSING

  COV-6  Task 1: Setup DB schema   -> R1, R2           TRACED
  COV-7  Task 4: Refactor utils    -> (none)           ORPHAN

Score: 66% requirements covered (2/3), 50% AC covered (1/2)

Why separate agent (not inline in orchestrator)

  • Different inputs: grounder needs plan + codebase. Coverage needs plan + spec.
  • Optional: only runs when --spec is provided
  • Independent value: useful even for well-structured, grounded plans
  • Spec parsing complexity: must handle GitHub issues, Google Docs, local files, Docmost

Tools needed

  • WebFetch — for fetching spec from URLs
  • Read — for local spec files
  • Bash — for gh issue view (GitHub issues)

Acceptance criteria

  • Agent file: plan-reviewer/agents/plan-coverage.md
  • Extracts requirements/AC from spec (GitHub issues, Google Docs, local files)
  • Extracts tasks/steps from plan
  • Produces bidirectional traceability (forward + backward)
  • Reports MISSING requirements and ORPHAN steps
  • Coverage score (% requirements, % AC)
  • Per-finding output with COV-* prefix

Parent issue: #34 (Meta: plan-reviewer orchestrator)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions