ワンクリックで
review
Plan-aware graph-enhanced code review before merge. CRITICAL issues block merge. Use after fix/verify.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
Plan-aware graph-enhanced code review before merge. CRITICAL issues block merge. Use after fix/verify.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
SOC 職業分類に基づく
Meta-orchestrator — dispatches to the right skill for the task. Use before any non-trivial work.
Library-agnostic Flutter/Dart code review checklist covering widget best practices, state management patterns (BLoC, Riverpod, Provider, GetX, MobX, Signals), Dart idioms, performance, accessibility, security, and clean architecture.
Structured 6-phase debugging. Build feedback loop first, reproduce deterministically, hypothesize with ranked falsifiable theories, instrument one variable at a time, fix with regression test, cleanup. Use when a bug exists, tests fail unexpectedly, or behavior is wrong and cause is unknown.
Toolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing browser screenshots, and viewing browser logs.
Database migration best practices for schema changes, data migrations, rollbacks, and zero-downtime deployments across PostgreSQL, MySQL, and common ORMs (Prisma, Drizzle, Kysely, Django, TypeORM, golang-migrate).
Run integration and e2e tests after unit tests pass. Use after /supergraph:fix when unit tests are green.
| name | review |
| description | Plan-aware graph-enhanced code review before merge. CRITICAL issues block merge. Use after fix/verify. |
| mcp | codebase-memory-mcp |
Final gate before merge. Graph-enhanced review with plan awareness.
/supergraph:fix completed (tests pass, lint clean)/supergraph:review | plan auth-login | plan auth-login task 2
"🔍 /supergraph:review — starting graph-enhanced code review..."
0 plans → skip | 1 → use | >1 → ask | plan <slug> → match.
Parse tasks, scope to task N if provided.
BASE_SHA=$(git rev-parse origin/master || git rev-parse origin/main || git rev-parse HEAD~1)
HEAD_SHA=$(git rev-parse HEAD)
git diff --stat "$BASE_SHA..$HEAD_SHA" && git diff --name-only "$BASE_SHA..$HEAD_SHA"
Use plan checkpoint commits as range if available. No changed files → check plan for incomplete tasks.
Reindex changed files first so graph reflects current code (not stale pre-edit state):
index_status(project=CBM_PROJECT); stale/degraded → index_repository(repo_path=<absolute>, name=CBM_PROJECT, mode=CBM_INDEX_MODE)
detect_changes(project=CBM_PROJECT)
trace_path(project=CBM_PROJECT, mode="inbound/outbound/data_flow")
# After get_graph_schema, run validated cycles, hubs, bridges, test-gaps,
# complexity, and cross-boundary recipes.
Per file: query_graph(query_type="tests", target=file).
3b. Serena code intelligence (optional):
If /supergraph:scan was not run this session, call mcp__serena__initial_instructions() first.
For each changed symbol/function:
mcp__serena__find_referencing_symbols(symbol=<changed_symbol>)
mcp__serena__find_implementations(symbol=<changed_symbol>)
For each changed file:
mcp__serena__get_diagnostics_for_file(file=<changed_file>)
Pass results to code-reviewer agent prompt under "Serena findings: [callers, implementations, diagnostics]". Skip gracefully if Serena unavailable — log "Serena unavailable, skipping code intelligence".
Stage 1 — Spec Compliance: Verify implementation matches plan requirements. Stage 2 — Code Quality: Verify code is clean, tested, maintainable.
Never start code quality review before spec compliance is verified.
Agent(
subagent_type="supergraph:code-reviewer",
description="Independent review: [plan-name or scope]",
prompt="Review BASE_SHA..HEAD_SHA. First verify spec compliance, then code quality.
BASE_SHA: [base] | HEAD_SHA: [head]
Changes:
[git diff --stat + git diff output]
Graph context:
- Hub/Bridge affected: [list/none]
- Surprise connections: [list/none]
- Affected flows: [list/none]
- Knowledge gaps: [list/none]
Serena findings (if available):
- find_referencing_symbols: [callers per changed symbol]
- get_diagnostics_for_file: [diagnostics per changed file]
Plan requirements: [task sections or none]
Focus: plan alignment, bugs, security, architecture, tests, graph risks, Serena diagnostics (if provided).
Output: strengths, Critical, Important, Minor, verdict (YES|WITH_FIXES|NO)"
)
Run $TEST_CMD and $LINT_CMD. Failures → add to Critical.
| Severity | Sources | Action |
|---|---|---|
| Critical | Reviewer Critical, tests/lint fail, circular deps, broken hub API, surprise>0.7, in_progress tasks | Block merge |
| Important | Reviewer Important, surprise 0.5-0.7, missing hotspot tests, bridge node without validation, stuck tasks | Fix unless risk accepted |
| Minor | Reviewer Minor, clean graph, good coverage | Note only |
| Gate | Check |
|---|---|
| Blast radius | All affected files handled? Unexpected files? |
| Hub safety | Callers tested? API backward-compatible? Breaking changes documented? |
| Bridge nodes | Cross-community impact assessed? |
| Surprise | >0.7: investigate coupling. 0.5-0.7: document or refactor. <0.5: ok |
| Knowledge gaps | Untested hotspots changed? Add tests or accept risk |
| TDD | RED/GREEN evidence per behavior? Regression tests for bugs? Tests assert behavior not internals? |
Critical → fix immediately, no exceptions. Important → fix unless user accepts risk. Push back with evidence, not opinion. Minor → note, optional.
When human gives review feedback:
## Review Report
- Verdict: PASS | NEEDS_CHANGES | BLOCKED
- Changed: N files | Blast radius: M
- Hub/Bridge: [list/none] | Surprise: [list/none]
- Tests: PASS|FAIL | Lint: PASS|FAIL
- Critical: N | Important: N | Minor: N
- Reasoning: [summary]
Verdict rules:
PASS → 0 Critical, reviewer YESNEEDS_CHANGES → 0 Critical, >0 Important or reviewer WITH_FIXESBLOCKED → >0 Critical or reviewer NOPASS + all tasks reviewed → mark Status: completed, add review log.
BLOCKED → mark affected tasks stuck, append blocker list.
If review revealed undocumented domain rules, invariants, or terminology:
printf '\n## <term or invariant>\n[what was discovered]\n' >> CONTEXT.md
Examples: hidden ordering constraints, shared state assumptions, boundary rules between modules.
Serena memory (optional — for non-PASS verdicts): On BLOCKED or NEEDS_CHANGES, persist findings for the next fix cycle:
mcp__serena__write_memory(
title="<plan-slug>-review-verdict",
content="Verdict: [BLOCKED|NEEDS_CHANGES]. Critical: [...]. Callers affected: [...]. Diagnostics: [...]"
)
Skip if Serena unavailable or verdict is PASS.
PASS → ready to merge.
NEEDS_CHANGES → /supergraph:fix, then re-review. Max 2 cycles, then escalate.
BLOCKED → escalate immediately, no auto-fix.