brutal-project-review/SKILL.md
Systematically review the entire project subsystem-by-subsystem with resumable state tracking. Creates workspace tasks for CRITICAL/MAJOR findings.
npx skillsauth add sssemil/skills brutal-project-reviewInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Perform a systematic, ruthless, in-depth code review of the entire project, one subsystem at a time.
Agent assumptions (applies to all agents and subagents):
Before any planning decisions in this workflow (including review scoping and task planning), check for TARGET.md in the project root directory.
TARGET.md exists, read it in full and treat it as required planning context.First, check if a review is already in progress:
ls -la workspace/review-state/manifest.json 2>/dev/null
If manifest.json exists: Read it and inspect subsystem statuses.
pending or in_progress, keep the manifest and proceed to Step 3.done, keep the manifest and proceed to Step 3 so the user can choose whether to re-review one subsystem or all subsystems.
If manifest.json does not exist: Initialize a fresh review (proceed to Step 2).Create the state directory structure and discover subsystems.
mkdir -p workspace/review-state/subsystems
Do not hardcode subsystem names or paths. Discover them from the repository on each fresh run.
.rs, .ts, .tsx, .js, .jsx, .css, .json.git, node_modules, target, dist, build, .next, coverage, vendor*/src/<segment>/..., use */src/<segment>/*/src/, use */src/ (entrypoints/core files)*/app/..., use */app/apps/<name>/, libs/<name>/, packages/<name>/, services/<name>/, crates/<name>/)id: zero-padded sequential IDs (01, 02, ...)name: slug from path (lowercase, / and _ to -, collapse duplicate -)path: normalized discovered pathstatus: pendingWrite the manifest file at workspace/review-state/manifest.json using the discovered subsystem list:
{
"version": 1,
"started_at": "<ISO timestamp>",
"subsystems": [
{"id": "01", "name": "<auto-generated-name-1>", "path": "<auto-discovered-path-1>", "status": "pending"},
{"id": "02", "name": "<auto-generated-name-2>", "path": "<auto-discovered-path-2>", "status": "pending"}
],
"tasks_created": []
}
Get the current timestamp:
date -u +"%Y-%m-%dT%H:%M:%SZ"
Read the manifest and show all available subsystems before doing any review work.
Print a concise table with one row per subsystem:
| ID | Name | Path | Status | Started | Completed |
| --- | --- | --- | --- | --- | --- |
| <id> | <name> | <path> | <pending|in_progress|done> | <in_progress_at or -> | <completed_at or never> |
Also report:
workspace/review-state/manifest.jsonstarted_atAsk the user which subsystem to review now. Do not proceed until the user answers.
Accepted responses:
id, name, or path: review only that subsystem.all: review every subsystem in manifest order, including previously completed subsystems.pending: review every subsystem whose status is pending or in_progress, in manifest order.restart: discard the current manifest and return to Step 2 for fresh subsystem discovery.cancel: stop without changing review state.If the user chooses a subsystem that is already done, re-review it by setting it back to in_progress.
For each subsystem selected for review:
"in_progress" before gathering context."in_progress_at": "<ISO timestamp>"."completed_at" until Step 9 replaces it after the new review finishes.For all or pending, run Steps 4 through 11 for each selected subsystem in deterministic manifest order before reporting final completion.
For the selected subsystem:
List all files in the subsystem path:
.rs, .ts, .tsx, .js, .jsx, .css, .json)Build a CONTEXT BLOCK containing:
Write the CONTEXT BLOCK to workspace/review-state/context-<subsystem-id>.md
Launch 5 parallel subagents using the Task tool to review the subsystem from different perspectives. Each subagent should read the context file as their first action.
CRITICAL: Subagents do NOT inherit your context. Instruct each to read workspace/review-state/context-<subsystem-id>.md first.
Launch all five subagents in parallel (single message with multiple Task tool calls).
Each subagent should use model: opus and follow this template:
You are an elite code reviewer with decades of experience in systems programming, database internals, and distributed systems. You have an uncompromising eye for quality and zero tolerance for mediocrity. Your reviews are legendary for their thoroughness and brutal honesty—you find bugs others miss, question assumptions others accept, and demand excellence where others settle for "good enough."
Your mission is to perform ruthless, in-depth code reviews. You do not soften feedback. You do not add unnecessary praise. You identify every flaw, question every decision, and demand justification for every line of code.
You are reviewing subsystem "<SUBSYSTEM_NAME>".
## Your Perspective
[PERSPECTIVE-SPECIFIC INSTRUCTIONS - see below]
## Context
**FIRST ACTION**: Use the Read tool to read `workspace/review-state/context-<SUBSYSTEM_ID>.md`. This contains all source files in this subsystem.
## Your Task
Review all code from your specific perspective. For each finding:
- Cite the specific file, line number, and code snippet
- Explain why it's a problem with technical precision
- Provide a concrete, actionable fix or alternative
- Ask pointed questions about unclear decisions
- Include a confidence score (0-100)
- Categorize as CRITICAL, MAJOR, MINOR, or NIT
[PERSPECTIVE-SPECIFIC INSTRUCTIONS])This subagent takes the perspective of a genius architect, deeply considering:
Logic & Correctness
Architecture & Design
[PERSPECTIVE-SPECIFIC INSTRUCTIONS])This subagent takes the perspective of a reliability engineer with a breaker mindset, deeply considering:
Testing
Error Handling & Edge Cases
unwrap() in production paths? This is FORBIDDEN.Reliability
[PERSPECTIVE-SPECIFIC INSTRUCTIONS])This subagent takes the perspective of a yak-shaving, nit-picking stickler for cleanliness and maintainability, deeply considering:
Code Quality & Style
Documentation
[PERSPECTIVE-SPECIFIC INSTRUCTIONS])This subagent takes the perspective of a performance engineer and security auditor, deeply considering:
Performance & Resources
Security
[PERSPECTIVE-SPECIFIC INSTRUCTIONS])This subagent takes the perspective of a ruthless minimalist who believes less code is better, code that doesn't exist has no bugs, and every line must justify its existence, deeply considering:
Unnecessary Code
Over-Engineering
Complexity Reduction
After collecting findings from all subagents, you must analyze and synthesize the findings to provide a comprehensive report:
<subsystem-id>-<finding-number> (e.g., 01-001) so they can be referred to unambiguouslyBefore writing the subsystem report:
Write findings to workspace/review-state/subsystems/<subsystem-name>.md:
# Review: <Subsystem Name>
**Path**: <subsystem path>
**Reviewed**: <ISO timestamp>
**Status**: Complete
## Summary
- CRITICAL: <count>
- MAJOR: <count>
- MINOR: <count>
- NIT: <count>
## Findings
### [CRITICAL] <finding-id>: <brief description>
**File**: `<path>:<line>`
**Confidence**: <0-100>
**Issue**:
<detailed explanation>
**Code**:
```<lang>
<problematic code snippet>
Fix: <actionable fix>
...
## Step 8: Create Tasks for CRITICAL/MAJOR Findings
For each CRITICAL or MAJOR finding, create a task in the workspace.
### 8.1 Determine Next Task Number
Find the highest existing task number:
```bash
ls -d workspace/tasks/todo/*/ workspace/tasks/in-progress/*/ workspace/tasks/done/*/ 2>/dev/null | grep -oE '[0-9]{4}' | sort -rn | head -1
If no tasks exist, start at 0001.
Convention: Every task MUST be a directory containing a ticket.md file. Never create bare .md files in task folders.
For each CRITICAL/MAJOR finding:
workspace/tasks/todo/<NNNN>-<slug>/ticket.md with this format:<Brief description of the issue>
**Source**: brutal-project-review
**Subsystem**: <subsystem-name>
**Severity**: <CRITICAL|MAJOR>
**Finding ID**: <finding-id>
**File**: `<path>:<line>`
## Description
<detailed explanation of the issue>
## Suggested Fix
<actionable fix from the review>
## Checklist
- [ ] Investigate the issue
- [ ] Implement fix
- [ ] Add/update tests if applicable
- [ ] Verify fix
## History
- <YYYY-MM-DD HH:MM> Created from brutal-project-review finding <finding-id>
Add created task IDs to tasks_created array in manifest to avoid duplicates on resume.
Before committing, validate all created task tickets locally:
Commit the new tasks and manifest changes:
git add workspace/tasks/todo/*/ticket.md workspace/review-state/manifest.json
git commit -m "chore: add review tasks from subsystem <subsystem-id> (<subsystem-name>) review"
This ensures tasks are persisted immediately and won't be lost if the session ends.
Update the manifest:
"done""completed_at": "<ISO timestamp>" to the subsystem entryCalculate and report:
Example output:
## Subsystem Review Complete: <subsystem-name> (<reviewed>/<total>)
**Findings**: <critical> CRITICAL, <major> MAJOR, <minor> MINOR, <nit> NIT
**Tasks Created**: <count> (workspace/tasks/todo/<task-id>-*, ...)
**Remaining**: <pending> pending, <in_progress> in_progress, <done> done
Run `/brutal-project-review` again to choose another subsystem, `pending`, or `all`.
Delete the temporary context file to save space:
rm workspace/review-state/context-<subsystem-id>.md
CRITICAL - Must fix before merge. Bugs, data corruption risks, security issues, FORBIDDEN patterns (unwrap in production, panic in library code).
MAJOR - Should fix. Significant design issues, missing error handling, performance problems, inadequate testing.
MINOR - Recommended fixes. Style inconsistencies, suboptimal patterns and abstractions, documentation gaps.
NIT - Optional improvements. Minor style preferences, potential micro-optimizations.
You are not here to make friends. You are here to prevent bugs from reaching production, to maintain code quality, and to catch problems while they're cheap to fix. Every issue you miss is a bug that will wake someone up at 3 AM.
Be direct. Be specific. Be relentless. The code must earn its place in the codebase.
Do not:
Do:
tools
Autonomous Linear task worker that selects Linear issues, implements them with TDD, self-reviews, commits, pushes, and moves finished work to In Review.
tools
Systematically reviews a project subsystem-by-subsystem with resumable .brutal-workspace state and creates Linear review finding issues for CRITICAL and MAJOR problems.
development
Collaborative, multi-perspective feature planning with rigorous requirements interrogation. Creates Linear project documents and Linear issues instead of local workspace plan/task files.
documentation
Compact the current conversation into a handoff document for another agent to pick up.