Skip to content
BENIBIX Learn

Diff and Code Review

Level 3 · Parallel work and review

The commands that check work before it ships. Read changes with /diff, look for bugs with /code-review, and watch the app run with /verify.

Course contentsLesson 8 of 17

After this lesson you can

  • Pick the review command that fits the question
  • Set how wide /code-review looks
  • Hand a very large change to /batch

12 mincovers 8 glossary entries

Worth reading first: Background Session Commands

How to check a change before it ships

Claude Code has five commands that check work before it ships. /diff shows each change in your files, Claude's and yours, line by line. /code-review looks for bugs. /simplify tidies. /security-review looks for ways in. /autofix-pr watches a pull request and pushes fixes. In the fullscreen view, /diff opens beside the chat.

/code-review looks for bugs. With no target, it reviews your branch's new commits and anything not yet committed. Name a pull request number, a branch or a path to review that instead. /review is another name for it. It reports what it found, and it changes nothing unless you ask.

A level from low to max sets how wide it looks. The low level reports fewer findings it is sure of. The max level reports more, and a few of them may be wrong. --fix applies the findings, and --comment posts them on the pull request. ultra sends a deep review to the cloud, with 3 free runs on a personal Claude plan.

/simplify asks a different question: could this be cleaner? Four review helpers work at once, on reuse, simpler code, speed, and whether the change sits at the right level. Then it makes the fixes, and it does not look for bugs. /security-review asks a third: can someone break in? It reads only your branch's changes against origin's default branch.

/autofix-pr keeps watch after you open a pull request. It starts a cloud session for the branch you have checked out. When a CI check fails or a reviewer comments, it pushes a fix. Pass a prompt to narrow it, such as only fix lint errors. It needs the gh tool.

/run and /verify check by using the app, not by reading code. /run builds your project's app, opens it and drives it the way a person would. /verify does the same to judge one change, and reports what it saw. /run-skill-generator writes the project skill both of them use to learn how your app starts.

/batch is for one change too big for one chat, such as moving src from JavaScript to TypeScript. It reads the code and splits the work into 5 to 30 parts. Each part can be done alone. Once you say yes to the plan, each part gets its own helper and worktree. The helper runs the tests and opens a pull request.

The review commands side by side

CommandThe question it asksDoes it change code?
/code-reviewIs it broken?Only with --fix
/simplifyCould it be cleaner?Yes
/security-reviewCan someone break in?No
/verifyDoes it work when used?No
Three reviews, three different questions.

Worked example

Emma reviews before she opens a pull request

Emma's branch touches 14 files. She runs /code-review high and gets 3 findings, one of them a missed check for an empty value.

She runs /code-review high --fix, then /security-review, which finds nothing. /diff now shows 2 more changed lines than before: the fix she asked for.

The words for this lesson8

Check yourself

Which command looks for bugs, not for cleanups?

Finished this lesson?

Marking it complete also marks its 8 glossary entries learned, which updates your roadmap and your saved page. 0 are already marked.