Nov 10, 2026

brooks-lint: Ground AI Code Reviews in Twelve Classic Engineering Books

A 2k-star code-review tool that diagnoses code against six production-code and six test-suite decay risks synthesized from twelve classic engineering books, returning Symptom → Source → Consequence → Remedy findings with book citations and a 0–100 Health Score.

#tutorial#developer-tools#architecture#testing

Most code quality tools count lines and cyclomatic complexity. brooks-lint, a 2k-star MIT-licensed tool, grounds AI code reviews in twelve classic engineering books — and every finding names the book it came from.

Why This Skill Matters

The README's framing: instead of counting lines, brooks-lint diagnoses code against six production-code decay risks (R1–R6) and six test-suite decay risks (T1–T6) synthesized from twelve classic engineering books. The production six:

RiskDiagnostic question
R1 Cognitive OverloadHow much mental effort to understand this?
R2 Change PropagationHow many unrelated things break on one change?
R3 Knowledge DuplicationIs the same decision expressed in multiple places?
R4 Accidental ComplexityIs the code more complex than the problem?
R5 Dependency DisorderDo dependencies flow in a consistent direction?
R6 Domain Model DistortionDoes the code faithfully represent the domain?

The twelve books span The Mythical Man-Month, Code Complete, Refactoring, Clean Architecture, The Pragmatic Programmer, Domain-Driven Design, A Philosophy of Software Design, Software Engineering at Google, The Art of Unit Testing, How Google Tests Software, Working Effectively with Legacy Code, and xUnit Test Patterns; the README's Twelve Books table maps each to its contributing risks, with exceptions and false-positive guards documented in skills/_shared/source-coverage.md. Every finding returns as Symptom → Source → Consequence → Remedy with a book citation, a severity label, and a 0–100 Health Score — and the shared framework's Iron Law forbids fixes before diagnosis: "A finding without a consequence and a remedy is not a finding — it is noise."

Installation

Claude Code installs from the plugin marketplace:

/plugin marketplace add hyhmrright/brooks-lint
/plugin install brooks-lint@brooks-lint-marketplace

Short-form commands are auto-installed on first session start, or run bash hooks/session-start yourself. To skip the marketplace: mkdir -p ~/.claude/skills/brooks-lint && cp -r skills/* ~/.claude/skills/brooks-lint/.

Gemini CLI takes an extension install; inside a Codex session, ask for the skill:

/extensions install https://github.com/hyhmrright/brooks-lint   # Gemini CLI
Install the brooks-lint skill from hyhmrright/brooks-lint       # ask inside a Codex session

Any other agent that loads Agent Skills runs all six modes with no conversion — one command installs them:

# pick your platform; --project installs into the current repo instead of your global config
curl -fsSL https://raw.githubusercontent.com/hyhmrright/brooks-lint/main/scripts/install.sh | bash -s -- <platform>
#   <platform> = opencode · cursor · windsurf · antigravity · pi · kiro · copilot · droid · dsh · gemini · codex · claude · bob · agents

On Node.js 20+ the same skills install through npm — no Git or Bash needed — and the installer covers 13 named coding tools plus the generic agents target:

npx brooks-lint install <platform>
npx brooks-lint install <platform> --project
npx brooks-lint install --list

The installer copies the skills flat so the shared framework (../_shared/) always resolves; its automated checks verify file layouts and resources, not runtime behavior in every host.

Real Workflow: Review a Pull Request

Suppose a feature just tacked loyalty points onto an existing profile-update method. In the repo, run:

/brooks-review

or paste a diff or point the agent at the changed files. The skill scans the six production decay risks in order, then automatically adds a lightweight Step 7 Quick Test Check (skipped for docs-only diffs); when you name no files, its SKILL.md applies Auto Scope Detection first.

The README's worked example is a UserService.update_profile method that updates fields, sends change-notification emails, recalculates loyalty points, and invalidates a cache in one body. The output: a 28/100 Health Score with a one-paragraph verdict, then itemized findings — two printed plus "6 more findings including SQL injection, dependency disorder, magic numbers". Each finding follows the same four lines. The Change Propagation finding cites Fowler's Divergent Change from Refactoring and Orthogonality from The Pragmatic Programmer; the remedy is to extract NotificationService, LoyaltyService, and UserCacheInvalidator. The Domain Model Distortion one catches a silent bug — the code overwrites the stored email before comparing it, so the change-notification condition is always false — citing Code Complete, Chapter 17 on unusual control structures.

Asking works too ("review this PR", "audit the architecture") — on every platform the skills trigger automatically when you discuss code quality, architecture, or test health.

Real Workflow: Audit Architecture, Debt, and Tests

/brooks-audit maps module dependencies, identifies circular dependencies, and checks Conway's Law alignment. The report opens with a Mermaid dependency graph, modules color-coded by severity (red for Critical findings, yellow for Warning, green for clean), and it renders natively in GitHub, Notion, and other Markdown environments. /brooks-debt classifies debt across the six decay risks, scores each finding by Pain × Spread, and produces a repayment roadmap with Critical, Scheduled, and Monitored tiers. /brooks-test audits the suite against six test-space decay risks: Test Obscurity, Test Brittleness, Test Duplication, Mock Abuse, Coverage Illusion, and Architecture Mismatch. /brooks-health runs abbreviated scans across all four quality dimensions into one weighted composite Health Score — the README suggests it before a release or when onboarding a team; for a deep dive on any single dimension, use that dimension's own skill rather than /brooks-health.

Tips

  • An optional .brooks-lint.yaml at the project root holds these settings: strictness presets (strict, balanced by default, legacy-friendly), disable for risk codes, severity overrides, ignore globs, focus (cannot combine with disable), custom_risks, suppress with an optional expires: date, and a Full-Sweep-only sweep key that caps the non-critical re-scan rounds (max_iterations, default 3). Copy .brooks-lint.example.yaml to start.
  • The tool measures itself. npm run benchmark scores the shipped parser against a frozen corpus of 30 real, model-generated reports spanning all six modes: exact severity-count match 30/30, risk-code precision/recall 100%/100% (56 finding-level codes, 0 false positives / 0 false negatives), valid SARIF 2.1.0 on all 30 — and npm test guards the result. The corpus deliberately includes 9 false-positive/tradeoff reports.
  • Scope the headline numbers the way the README does: the comparison table (94% overall pass rate for brooks-lint vs 16% for Claude alone, across three scenarios) is labeled illustrative; the deterministic numbers are the parser-fidelity ones above.
  • CI is a GitHub Action (hyhmrright/brooks-lint/.github/actions/brooks-lint@v1.9.1), mode: review only: the review posts as a PR comment; gates include fail-below, fail-on: critical, fail-on-regression (backed by a committed .brooks-lint-history.json), and sarif-file for GitHub Code Scanning. Project config is read from the base commit by default, so a pull request cannot weaken the policy that reviews it. Cost: about $0.05–0.15 per PR run.
  • Syntax differs by platform: Claude Code also accepts the namespaced /brooks-lint:brooks-review, Codex CLI uses $brooks-review, pi registers /skill:brooks-review — elsewhere, natural language triggers the matching skill from its description.

When Not to Use This

  • It does not replace your linter — the README says so outright, and it catches what linters can't: architectural drift, knowledge silos, and domain model distortion.
  • CI supports mode: review only; audit, debt, test, health, and sweep need an interactive agent with project access, and Full Sweep needs interactive execution.
  • The GitHub Action path cannot review pull requests from forks — forked runs get neither repository secrets nor id-token: write.
  • Findings are diagnostics, not verdicts: the parser benchmark measures report-parsing fidelity, not whether a finding is correct, and the README notes the eval suite's deterministic checks do not establish semantic correctness.
  • Host verification is uneven: per the maintainer's 2026-10-16 policy note, only Codex-related capabilities are currently tested; verification of Claude Code, Gemini CLI, and other platforms is historical, and the ten table platforms are verified at the file-layout level, not yet run end-to-end by the maintainer on every platform.

See the leaderboard for more skills.