A reviewer who did not write it
By the end of this lesson you will have one screener change merged through a pull request after a fresh session (and a second model, if you have one) reviewed it without having written it, every finding marked real, plausible-and-wrong or taste, and a failing test for each real one.
You review every diff with four lenses, and the tests catch for good what the lenses found once. One thing neither fixes: the author of a change is the worst-placed reader of it. That holds for you, and twice over for an agent reviewing code it wrote ten minutes ago in the same session — it remembers what it meant, so it reads what it meant.
This lesson adds the reader who did not write it, and the gate that decides when that reader's opinion is enough.
Branch, then pull request
The first course in this track used branches to try things without risk. Here a branch becomes the unit of review:
git switch -c screener-csv-export
# the agent works, the tests go green, it commits
git push -u origin screener-csv-export
gh pr create --fill
The last line uses the GitHub CLI; opening the pull request on the GitHub website does the same. The push goes to a repository of your own: if your project is still a clone of the starter, create a repository under your account first (gh repo create) and push there, never to the starter's origin. Before the review, run git diff main...HEAD --stat: it must list only the files of this one change. If it lists the whole product, main is not the branch this change started from, so name the right base branch in the review prompt. A pull request is the branch's diff with a page around it: a description, a place for comments, and the checks CI ran on exactly that code. Make it the only way into main, for your own changes too — the habit has to hold on the day you are sure.
A second reader, three ways
A fresh session. Start a new session of your agent — /clear, or a new terminal — so it carries nothing from the one that wrote the change. Give it only the diff and the job:
Review the diff of this branch against main as code you did not write. Use the four lenses in REVIEW.md: leaks, cost, lies, failure. List each problem with the line it is on and what it would cost. Do not fix anything.
Both agents also have a built-in review that looks for correctness bugs: in Claude Code, /code-review with the pull request's number, or with the branch name before you have pushed; in Codex, /review against main, or codex review --base main from your shell. Run it too, and then ask for your four lenses, which it does not know about.
A second model. The other agent, if you have one installed — Codex CLI if you build with Claude Code, Claude Code if you build with Codex — or any other, given the same diff and the same prompt. A different model has different blind spots, and where two reviewers disagree is where you look hardest. This step is optional: the install for either agent is in Your coding agent, and with only one, the fresh session and the built-in review are this lesson's reviewers.
A person. Still the best reviewer, when you have one.
The prompt matters more than the reviewer. "Review this" gets style notes. The four lenses, named, get findings — and "do not fix anything" keeps a review a list rather than a second diff to read.
Read the critique sceptically
A reviewing agent is as confident when wrong as the author was. Expect three kinds of finding:
- Real: a line and a consequence you can reproduce. Write a failing test for it, then fix it.
- Plausible and wrong: it reports that the proxy forwards
api_tokenwhen the drop is two lines up. Check, then discard — and do not argue it round; it will agree with you either way. - Taste: rename this, extract that. Ignore it unless it would have prevented a bug.
A finding you cannot reproduce is not a finding yet, and the failing test is how you find out.
CI is the gate, not the reviewer
Reviewers advise; CI decides. On a pull request, the starter's workflow runs the key scan, lint, the type check, npm test and npm run check:leak on exactly the code that would merge. Red means not mergeable, whatever a reviewer says. Green means the checks you encoded hold, and a reviewer's job is everything no check encodes: whether the change makes sense at all.
The finding that pays for the habit
A real case, from a sample calendar app — earnings, dividends and splits for a watchlist, drawn as one calendar. It worked: right dates, right rows, nothing red. And of the calls one page view spent, between 70 and 95 went on fetching feeds only so the page could sort and merge them — work that did not need the API at all.
Nothing about it was broken, so the author's own review passed it: each fetch made sense in the file where it was written. It is exactly the question a reader holding only the diff and the cost lens is placed to ask — what is each of these calls for? — and the meter from Build Your First Tool is how you check the answer.
Try it now
- Make a branch for your next screener change — a link that downloads the rows on screen as a CSV file is a good size, because nothing in this course has built it — let your agent do it with the tests green, push it and open a pull request.
- Start a fresh session, give it the four-lens prompt below, and save its findings. Then run the built-in review on the pull request as well, as above.
- If you have a second agent installed, give it the same diff and prompt.
- Sort every finding into real, plausible-and-wrong or taste. For each real one, write the failing test before the fix.
- Merge only when CI is green on the pull request, then delete the branch. Count how many real findings the author's own review had missed.
The prompt
The change first. On the new branch (git switch -c screener-csv-export), mock mode on, plan mode on, paste:
Add a "Download CSV" link to the screen page that downloads the rows
on screen as a CSV file: the same columns, in the same order, from
the rows the page already has, so it makes no new request. Write the
tests first. Done means npm test, typecheck, lint and check:leak
green; then commit on this branch and show me the diff.
Push it and open the pull request. Then the review: in the fresh session — /clear, or a new terminal — paste:
First run git diff main...HEAD --stat and tell me which files differ; if
it is more than this one change, stop and ask me which branch to
compare. Then review the diff of this branch against main as code you
did not write. Use the four lenses in REVIEW.md: leaks, cost, lies,
failure. List each problem with the file, the line and what it would
cost. Do not fix anything. Save the list to notes/review-2.md.
A good answer is a list in notes/review-2.md and nothing else; the verdicts beside each finding are yours.
Check it yourself
- The reviewing session changed one file,
notes/review-2.md. - Every finding carries your verdict and, if you discarded it, the line that proves it wrong.
- Each real finding has a test that failed before its fix and passes after.
- The pull request's checks were green when you merged.
Compare with ours
notes/review-2.md: branch screener-csv-export
real lies the export writes dividend_yield as the raw fraction
0.0002 while the table shows 0.02%. Failing test, then
the same percent helper in the export.
wrong leaks "api_token is forwarded": the export link carries only
the f= filters it was built from. Checked, discarded.
taste "rename f to filters". Ignored.
The full state at the end of this unit is on the starter's branch ref/build-a-screener/u3.

Checkpoint
git status # notes/review-2.md, nothing else
git add -A
git commit -m "Second-reader review of the CSV export, each finding sorted"
Then the fix for each real finding, its test first, and the merge through the pull request. Then answer this lesson's questions.