Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
git clone --depth 1 https://github.com/helmedeiros/clean-code-skillsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/commands/helmedeiros/clean-code-skills/branch-review)<a href="https://agentmods.dev/commands/helmedeiros/clean-code-skills/branch-review"><img src="https://agentmods.dev/badge/commands/helmedeiros/clean-code-skills/branch-review/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/commands/helmedeiros/clean-code-skills/branch-review"><img src="https://agentmods.dev/badge/commands/helmedeiros/clean-code-skills/branch-review.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00033 | $0.01721 |
| Opus 5 | $0.00016 | $0.00860 |
| Sonnet 5 | $0.00007 | $0.00344 |
| Haiku 4.5 | $0.00003 | $0.00172 |
Grade A, and why
branch-review scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 106 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Branch Code Quality Review
Compare the old code on the base branch against the new code on the feature branch and produce a detailed, evidence-backed scorecard.
Review Process
Step 1: Identify the Branch
Use the provided branch argument if available, otherwise use the current branch. Determine the base branch (main or master).
Step 2: Gather Data
Run the following analyses against the diff between the base branch and the feature branch:
git diff <base>...HEAD --statto list all changed files.git diff <base>...HEADto read the actual changes.- Count lines per component or file. Flag files over 200 lines.
- Check type safety: strict mode in
tsconfig.json, count@ts-ignore,@ts-expect-error,as any,as unknown,Record<string, any>. - Check styling approach: count CSS modules vs inline styles (
style={{,style={). - Check test coverage: count test files,
describe/it/testblocks, distinguish integration vs unit vs shallow tests. - Check accessibility: count
aria-attributes,role=, semantic HTML elements, color-only status indicators. - Check error handling: try/catch patterns, error boundaries, API error handling.
- Check code duplication: repeated constants, copy-pasted components, duplicated helpers.
- Check API integration: cancellation, retries, typed responses, caching.
- Check routing: lazy loading, nested layouts, 404 handling, breadcrumbs.
- Check state management: prop drilling depth, global state, custom hooks.
- Check DX tooling: linting, formatting, pre-commit hooks, import sorting.
Step 3: Check for Previous Reviews
Look for a file called BRANCH_REVIEW.md in the repo root or .claude/ directory. If found, include a "Previous New" column in the scorecard to show progression.
Step 4: Score Each Dimension
Rate each dimension on a 1-10 scale for both old and new code. Back every score with file names, line counts, or pattern counts.
Scoring Rubrics
- Type Safety: 1-3 = no types or
anyeverywhere; 4-6 = partial types with casts; 7-8 = strict mode, few casts; 9-10 = complete types, generic utilities, no unsafe casts. - State Management: 1-3 = global mutations, no patterns; 4-6 = basic hooks/state; 7-8 = proper state libs, minimal prop drilling; 9-10 = optimized selectors, derived state, signal-based.
- Component Architecture: 1-3 = monolithic files 1000+ lines; 4-6 = some splitting but large files remain; 7-8 = most files under 200 lines, clear separation; 9-10 = composable, single-responsibility, under 150 lines.
- Routing: 1-3 = no client routing or full reloads; 4-6 = basic routing; 7-8 = lazy loading, nested layouts; 9-10 = code splitting, prefetching, 404/error routes, breadcrumbs.
- Styling: 1-3 = all inline or massive CSS files; 4-6 = mixed inline and modules; 7-8 = CSS modules or tokens, few inline; 9-10 = design token system, zero inline, themeable.
- Testing: 1-3 = no tests; 4-6 = shallow smoke tests only; 7-8 = behavior tests, good coverage, some integration; 9-10 = integration + e2e, sub-component tests, a11y tests.
- Error Handling: 1-3 = unhandled errors crash app; 4-6 = basic try/catch; 7-8 = error boundaries, typed errors, user feedback; 9-10 = retry logic, graceful degradation, monitoring.
- API Integration: 1-3 = raw fetch, no error handling; 4-6 = wrapper with basic error handling; 7-8 = typed responses, caching, cancellation; 9-10 = retry, pagination, optimistic updates.
- Accessibility: 1-3 = no ARIA, no semantic HTML; 4-6 = some ARIA labels; 7-8 = keyboard nav, screen reader support, semantic HTML; 9-10 = WCAG AA compliant, a11y tests.
- Code Duplication: 1-3 = extensive copy-paste; 4-6 = some shared utils; 7-8 = centralized constants, shared components; 9-10 = DRY, shared hooks, component library.
- DX & Maintainability: 1-3 = no tooling; 4-6 = basic linting; 7-8 = lint + format + pre-commit + aliases; 9-10 = CI checks, auto-fix, consistent conventions, documentation.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 9d ago First seen · 106 lines · 33 tokens per session scan A 5925227d4bc6
branch-review is a command published in the GitHub repository helmedeiros/clean-code-skills (2 stars, last pushed 6mo ago), licensed MIT. It adds 33 tokens to every session and 1,721 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other commands, from other repositories
review-pack
Inspect Soliton's risk-adaptive context pack for a PR or local diff (Step 1 + Step 2 + Step 2.5 + Step 2.75; no agent dispatch).
dc-review
Two-stage code review orchestrator. Stage 1 (spec compliance, binary) → Stage 2 (code quality, severity-tagged). Stage 2 skipped if Stage 1 fails. Lane-aware (trivial = Stage 2 only).
meta
Umbrella for learning, evolution, ADR generation, and architecture review. Subcommands cover the Learn layer of the workflow (Layer 5) plus on-demand maintenance gates.
verify
Run build, test, lint, security, and static analysis pipeline. Modes -- quick, pre-commit, full, gate.
discover
Run a full product discovery cycle — from outcome definition through opportunity mapping, prioritisation, and experiment design. Use when the team isn't sure what to build next, or before writing a PRD for a complex feature space.
pm-review
Review local git diff with reasoning + snippets; cross-check; dispose findings into the rules library.