command

self-review

Arguments: $ARGUMENTS --- Multi-agent review of the current branch compared to `origin/main`. Launches parallel specialized agents to catch bugs, security issues, design problems, and code quality con

$ curl -fsSL https://skills.reveni.dev/install.sh | bash

Arguments: $ARGUMENTS


Purpose

Multi-agent review of the current branch compared to origin/main. Launches parallel specialized agents to catch bugs, security issues, design problems, and code quality concerns. Outputs a single prioritized report.


Silent Execution


Argument Parsing

Valid flags: --quick, --pr <number>.

Unknown flags: log a warning and continue.


Flow

Show the plan once at the start:

====================================
SELF-REVIEW
====================================
Phase: Discovery
[ ] 1. Collect branch changes
Phase: Analysis (parallel)
[ ] 2a. Code quality review
[ ] 2b. Logic & correctness review
[ ] 2c. Security review
[ ] 2d. Architecture review
Phase: Report
[ ] 3. Merge & prioritize findings
====================================

Then show a single progress line per step.


Phase: Discovery

1. Collect branch changes

If --pr <number> was provided:

gh pr view <number> --json title,body,baseRefName,headRefName,files
gh pr diff <number>

Use the PR diff as the source of changes.

Otherwise (default — local branch):

# Branch name
git branch --show-current

# Changed files
git diff --name-only --diff-filter=d origin/main

# Full diff (needed by agents)
git diff origin/main

# Commit history
git log --oneline origin/main..HEAD

If no changes found: show "No changes to review." and stop.

Show: ▶ Step 1: Collecting changes... OK (N files changed, K commits)


Phase: Analysis (parallel agents)

Launch ALL agents in parallel using the Agent tool. Each agent receives the full diff and the file list as context. Do NOT run them sequentially.

If --quick flag: only launch agents 2a and 2b. Skip 2c and 2d.

IMPORTANT: You MUST launch the agents in a single message with multiple Agent tool calls so they run concurrently.

2a. Code Quality Review

Launch agent with subagent_type: "oh-my-claudecode:quality-reviewer".

Prompt the agent with:

2b. Logic & Correctness Review

Launch agent with subagent_type: "oh-my-claudecode:code-reviewer".

Prompt the agent with:

2c. Security Review

Launch agent with subagent_type: "oh-my-claudecode:security-reviewer".

Prompt the agent with:

2d. Architecture Review

Launch agent with subagent_type: "oh-my-claudecode:architect".

Prompt the agent with:

Show progress as each agent completes:

▶ Step 2a: Code quality review... OK (4 findings)
▶ Step 2b: Logic & correctness review... OK (2 findings)
▶ Step 2c: Security review... OK (1 finding)
▶ Step 2d: Architecture review... OK (0 findings)

Phase: Report

3. Merge & prioritize findings

Collect all findings from all agents. Deduplicate: if two agents flag the same file:line with the same concern, keep the one with higher severity and richer detail.

Determine origin tag for each finding using the diff:

Sort by: severity (CRITICAL > HIGH > MEDIUM > LOW), then NEW before PRE-EXISTING, then by file path.

Display the final report:

====================================
   SELF-REVIEW REPORT
====================================

Branch: feature/sc-12345/add-widget
Base: origin/main
Scope: 12 files changed, 5 commits
Agents: quality, logic, security, architecture

── CRITICAL (1) ─────────────────────

  1. [Security] NEW — SQL injection in raw query
     src/api/views/orders.py:45
     → `cursor.execute(f"SELECT * FROM orders WHERE id = {order_id}")`
     → Use parameterized query: cursor.execute("SELECT ... WHERE id = %s", [order_id])
     (agent: security)

── HIGH (2) ──────────────────────────

  2. [Logic] NEW — Missing null check before access
     src/services/returns.py:78
     → `return order.customer.email` — order.customer can be None
     → Add null check or use optional chaining
     (agent: logic)

  3. [Quality] NEW — Function exceeds 80 lines
     src/api/views/orders.py:12-98
     → OrderViewSet.create is 86 lines with 5 levels of nesting
     → Extract validation and notification logic to separate methods
     (agent: quality)

── MEDIUM (2) ─────────────────────────

  4. [Architecture] NEW — Business logic in view layer
     src/api/views/orders.py:30-55
     → Price calculation should live in the domain/service layer
     (agent: architecture)

  5. [Quality] PRE-EXISTING — Duplicated error handling
     src/services/returns.py:22-35
     src/services/exchanges.py:18-31
     → 14 lines of identical try/except pattern
     (agent: quality)

── LOW (1) ────────────────────────────

  6. [Quality] PRE-EXISTING — Unused import
     src/services/returns.py:3
     → `from datetime import timedelta` not used
     (agent: quality)

====================================
   SUMMARY
   1 CRITICAL · 2 HIGH · 2 MEDIUM · 1 LOW
   New: 4 | Pre-existing: 2
   Agents: quality (3) · logic (1) · security (1) · architecture (1)
====================================

Severity definitions:

If zero findings: show "No issues found. Code looks clean!"


Rules