agentleFS
allmontyallmonty/better-code-agent/skills/review-change/SKILL.md

review-change

Skill0 starsChanged 11 days agoMITView on GitHub

Reviews a code change in a fresh context that never saw the reasoning behind it - correctness including code outside the diff, the plan's acceptance criteria, tests, architecture boundaries, security, load, and unneeded code - and reports ranked, verified findings with fixes. Use when the user asks to review changes, a commit, a branch or a PR, or before merging AI-written code.

35 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use plan-change, implement-change and 9 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • BanKnightSkill

    plan-change

    将已完成 spec/design 的 change 拆成可执行 plan 与 tasks。用户要把设计落成执行计划、任务清单或实现步骤时使用。

    Also in 7 projects that use this

  • Codagent-AISkill

    implement-change

    Implements an approved change in one continuous session, with tiered test runs. Use when asked to implement a change from its approved definition, or to invoke codagent:implement-change.

    Also in 7 projects that use this

  • MaheshAwasareSkill

    write-runbook

    Generate an operational runbook for a service from its code, config, and dependencies — what to do when it breaks, where to look, how to roll back, who to escalate to. Use proactively before a service goes to production, after a major incident, or when handing off operational ownership.

    Also in 3 projects that use this

  • Sagargupta16Skill

    upgrade-dependencies

    Upgrade a project's dependencies one at a time, running the test suite after each bump and reverting the ones that break it. Use it during routine dependency maintenance, when a batch of updates has accumulated; before a major release, to go into it on current and patched dependencies; when Renovate or Dependabot PRs have piled up and you want them resolved locally in one sitting; when a security advisory means you need the patched version in, and you need to know what it breaks.

    Also in 3 projects that use this

  • testified-ossSkill

    incident-triage

    Triage production incidents with severity assessment, root cause hypothesis, impact analysis, and escalation recommendations. Use when analyzing outages, errors, or production issues.

    Also in 4 projects that use this

  • srclightSkill

    refactor-safely

    This skill should be used when the user asks to "refactor", "rename", "move", "change a function signature", "extract a method", "delete unused code", "clean up", or any modification that could break callers or dependents. Provides a pre-change safety checklist using srclight's graph tools to assess blast radius before touching code.

    Also in 3 projects that use this

The file

We split this skill into the rules it gives an agent

2 rules. 0 are common, 1 is distinctive, and 1 is very specific to this project.

  • 0

    Common

    Most of the 31 edited versions we read keep these.

  • 1

    Distinctive

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Read AGENTS.md, the rules in .claude/rules/, and any plan in docs/plans/ or ADR the change relates to (check commit messages and …

    line 23
  2. Distinctive:

    Before reporting, re-read the code and confirm the failure scenario is real.

    line 40

“Common” is measured: kept by at least 6 in 10 of the 31 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Review a change

Work in the user's project: the current working directory. Every path below is relative to it, not to this skill's own folder.

You are reviewing code you didn't write. Read only; don't edit files.

1. Get the change

Target: $ARGUMENTS

  • Empty: uncommitted changes (git diff HEAD plus untracked files); if there are none, the last commit (git show HEAD).
  • A commit, range or branch: git diff <base>...<target> (branch base: main or master).
  • A PR number: gh pr diff <n> and gh pr view <n>.

2. Get the intent

Read AGENTS.md, the rules in .claude/rules/, and any plan in docs/plans/ or ADR the change relates to (check commit messages and docs/PROGRESS.md). The plan's acceptance criteria are the spec.

3. Read beyond the diff

For every changed function, type, field, route or config key, grep its callers and users and read them. Many real bugs are in untouched files: a renamed field, a changed return type, a new required argument.

4. Check, in this order

  1. Correctness: wrong logic, unhandled edge cases (empty, null, zero, max, unicode, concurrent), error paths, broken callers, data migrations without backfill or rollback.
  2. Spec: each acceptance criterion is implemented and has a test. Anything built that wasn't asked for.
  3. Tests: new behaviour has tests at the right level; tests would fail if the code broke; no test deleted, skipped or loosened (look for removed asserts, .skip, xit, @pytest.mark.skip, widened tolerances).
  4. Architecture: forbidden dependency directions, logic in the wrong layer, reaching into another module's internals, new patterns that contradict the codebase or an ADR.
  5. Security: unvalidated input at trust boundaries, injection, missing authorisation, secrets, unsafe deserialisation, invented or typo-squatted packages.
  6. Load: N+1 queries, unbounded loops or result sets, missing pagination or timeouts, work in hot paths that should be cached or batched.
  7. Unneeded code: abstractions with one use, dead code, options nobody asked for, duplicates of an existing helper.

Skip style and formatting; linters own that. A reviewer asked to find problems always finds something, so report only what matters for correctness, safety, maintainability or the spec.

5. Verify every finding

Before reporting, re-read the code and confirm the failure scenario is real. Drop anything you can't back with a concrete scenario. "No findings" is a valid result.

6. Report

Ranked, most severe first:

### [Must fix | Should fix | Consider] <one-line title>
`path/to/file.ext:line`
What happens: <concrete input or state → wrong result>
Fix: <the specific change>

End with a verdict: Ready to merge, Merge after must-fixes, or Needs rework, plus anything you could not check (e.g. couldn't run the app).

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.