Skip to main content
Public lesson library

Lessons for engineering teams

Make technical work easier to explain, review and hand over. Use lessons on systems, problem-solving and collaboration to improve the next design discussion or written decision.

Lesson previews

Tell Them How or Tell Them What?

The best comment is explicit about the risk and flexible about implementation. It anchors the requirement in code health, then lets the closest engineer choose an equivalent fix.

5 min
The 400-Line Attention Limit

Review fatigue turns deep review into surface scanning. Review speed is a team throughput issue, not a politeness issue. When feedback arrives days later, the author has swapped context, the branch has drifted, and the reviewer is tempted to batch many comments into one painful round. Fast first response changes the economics: small corrections happen while the code is warm, and major concerns surface before the author builds more on top of a shaky premise. Speed does not mean shallow review; it means scheduling focused review windows and declining or rerouting work you cannot review in time. Size affects defect…

5 min
The Risk-First Review Walk

The trigger A mixed PR lands with UI, API, and migration changes. The first visible line is rarely the highest-risk line. Risk-first review Start where a wrong decision would invalidate the rest of the review. Line-one scan Feels thorough, often finds polish first Fewer wasted comments, better blockers Sequence review by consequence, not file order. 01 Design 02 Behavior 03 Tests 04 Try Step 1

5 min
Turning a Nit Storm into a Useful Review

Marco M PR author 1 Acknowledge 2 Sort 3 Close Your review has many comments and the author asks what actually blocks merge. Without severity, volume feels like rejection. Teach Conventional Comments triage The framework is to keep safety high while challenging the code directly: label intent, name behavior, explain impact, and invite a fix. Blunt verdict Fast to type, slow to repair Clear feedback without personal threat Labels make intent readable.

5 min
What to Inspect in a Review

Place each concern under the review lens it primarily exercises. Design / architecture Functionality / user behavior Tests / verification Maintainability / readability A new service duplicates an existing policy boundary. A timeout path returns success to the client. The new test would still pass if the guard were removed. A function now has three responsibilities and unclear names. The migration order breaks zero-downtime deploys. The UI shows the old plan limit after upgrade.

5 min
When the Author Pushes Back

A required comment receives confident pushback and the thread starts looping. A stalled PR is a process bug as well as a technical disagreement. Evidence → criterion → convergence Treat pushback as a request to make the review standard explicit. Repeat louder Creates friction without new information No dead threads Consensus needs a criterion both sides can inspect. Evidence The author says the double-write cannot happen. What do you do first? Criterion No guarantee is documented. What standard decides? Converge The author still disagrees after the criterion is named. What next? Fresh application

5 min
Write the PR Description Reviewers Need

A PR description says only “fix invoice export.” Context → change → risk → verification. A thin description shifts discovery work to the reviewer and increases the chance that comments focus on visible details instead of intended behavior. fix invoice export Problem: invoice exports dropped annual-plan discounts. Change: centralizes discount calculation in InvoiceTotals and updates CSV export. Risk: tax-inclusive plans and legacy annual discounts. Verified: unit tests for monthly, annual, and tax-inclusive exports plus manual CSV check for org 4812. Context State the user-visible problem: annual discounts disappear in CSV export. Reviewers now know what behavior the code must repair.…

5 min
Pick The Plan That Fits The Sandbox

You need to fix a schema mismatch. The run has workspace-write only, no network, and no approvals. The production-shaped command usually fetches the latest schema from a remote service.

5 min
Choose Between “Explain”, “Plan”, And “Implement”

A noisy production symptom just landed: checkout sessions sometimes duplicate line items, but nobody has isolated whether the issue is in the cart reducer, the API retry path, or stale local state. You have logs from one incident and no clean reproduction yet.

5 min
Apply & Commit: Script Your Next Bugfix Brief

A real upcoming bugfix branch where you expect to use Codex within the next two or three days. Pick something concrete: a flaky spec in your repo, a regression on your current feature branch, or a bug discovered during PR review. The commitment only counts if it is tied to an actual branch, test, or failing path you can name. Objective: I will ask Codex to fix ____. Constraints: It must stay within ____ and preserve ____. Starting evidence: I will point Codex to ____ and ____. Verification: I will require ____ plus ____. Why this task matters now: ____.…

5 min
Apply & Commit: Use A Review Triage Pass Before Replying

A live PR or an imminent pull request review where Codex may help you respond to comments. Make this specific to your workflow: name the branch or PR, the kind of comments you expect, and the review pressure you usually feel. Good examples include a shared-helper bugfix PR, a design-system refactor under review, or a branch with comments about test coverage and scope. Situation: On PR or branch ____, I expect review comments about ____. My triage rule: Before any Codex patch or reply, I will label each comment as code fix, explanation gap, or scope cleanup. My response habit:…

5 min
Worked Walkthrough: From Repo Findings To A Safe Plan

Codex inspected a flaky upload test and suggested touching the spec, the upload helper, a timeout constant, and an analytics hook. Root cause -> Minimal files -> Verification Discovery output often contains adjacent files that are plausible but not yet justified. If you execute the whole list, the diff grows faster than your certainty. Keep only root-cause files Retain the spec and upload helper because both map directly to the reproduced failure path. Each kept file must connect to the bug narrative, not just live nearby in the codebase. Reject weakly justified neighbors Drop the timeout constant and analytics hook…

5 min
Decision Walk: Debug In A Dirty Worktree

The situation A checkout flake must be fixed on a branch that already contains unrelated copy, analytics, and design edits from the user. One careless command can turn a focused bugfix into an accidental cleanup PR. Guiding principle Constrain, inspect, justify, then edit On a dirty branch, strong Codex work keeps re-establishing which files belong to the task and which do not. Bad shortcut Run broad formatters or accept an unexplained file list. You protect existing work while still fixing the bug. Dirty state demands explicit file boundaries. Start Codex proposes running a repo-wide formatter before debugging because some files…

5 min
Dialogue: Explain A Sandbox Limitation Without Sounding Defensive

Lead LD Engineering lead 01 State limit 02 Show progress 03 Hand off Your lead asks whether the Codex session finished the schema fix. The answer is “partly,” because the remote sync step was blocked by network restrictions. You need to sound accountable without faking completion. 2 local fixes completed in repo 1 remote step still blocked 1 follow-up can run in broader env Own the limit and the plan

5 min
Decision Walk: When A Command Is Blocked

The situation A write step for a generated migration file fails because the target directory is outside the writable roots. You still need to make progress without smuggling in a fake success. Guiding principle Classify the blocker, then split the task Once a command reveals a hard permission limit, the plan should separate executable work from deferred work. Bad shortcut Retry the same blocked command or claim the task is done anyway. The session remains truthful and productive. A hard blocker should sharpen the plan, not stall it. Interpret The command fails with a permission error naming a non-writable directory.…

5 min
Dialogue: Answer PR Pushback Without Getting Defensive

Reviewer RV Senior engineer 01 Interpret 02 Respond 03 Tighten The reviewer says the diff looks larger than the bug warrants after seeing one shared helper and one seemingly unrelated file. You need to decide whether to explain, fix, or trim. 3 files currently in diff 1 helper clearly tied to root cause 1 file questionable justification Explain the invariant, remove the baggage

5 min
Dialogue: Push Back On A Vague Refactor Request

Requester RQ Product engineer 01 Clarify 02 Constrain 03 Commit The requester wants a cleanup “while you are in there,” but the current goal is fixing one flaky service test before end of day. Without negotiation, Codex will inherit a moving target. 1 bug must be fixed today 3 ideas possible cleanup themes 0 boundary scope not yet named Negotiate the outcome, not the mood

5 min
Should You Ask For A PR-Ready Output Yet?

Codex has a patch that appears to fix the bug. One target test and lint pass, but an integration command still has not run, and the diff contains a small unrelated cleanup that would be easy to drop.

5 min
Worked Walkthrough: Build A PR Story From The Diff

You have a finished branch that changes a shared serializer, one checkout page, and two regression tests. Problem -> Fix -> Scope -> Proof If the PR description only lists files or implementation details, reviewers have to reverse-engineer why the shared helper and downstream page both belong in the same branch. State the problem Open with the duplicated line-item bug that customers saw during checkout retries. A reviewer should know what behavior changed before they see any file names. Name the chosen fix and scope boundary Explain that the serializer owns the retry contract, the page update follows that contract,…

5 min
Plan Before The First Edit

Codex should earn the first edit. Discovery is a separate phase Agentic tools are fast enough that they can hide bad reasoning. A patch appears quickly, so it feels productive. But speed is not the same thing as localization. In a medium or large repo, the first plausible file is often not the real source of the problem. A better pattern is: inspect first, edit second. Ask Codex to read the relevant files, summarize the failure path, and propose the smallest likely change set. That creates a shared model of the problem before the diff begins. It also gives you…

5 min
Decision Walk: Triage A PR Review Comment

The situation A reviewer comments “This feels risky” on a change that touched a shared helper and two downstream tests. The wrong response can either hide a real bug or create needless churn. Guiding principle Classify the review signal first Some comments call for code, some for explanation, and some for clarifying discussion. Codex should not assume they are all the same. Bad shortcut Patch immediately without understanding what the reviewer is really objecting to. Reviewer trust rises because the response matches the concern. Do not solve an explanation problem with needless code. Interpret What is the strongest first move…

5 min
Quick Reference: PR Review Reply Cards

What is the first move after reading a vague review comment like “this feels risky”? Classify whether the concern is a real bug risk, an explanation gap, or a scope problem. You cannot choose the right branch action until you know what kind of signal the comment is sending. How do explanation problems differ from code problems in review? Do not answer the wrong concern Evidence and edits are different tools. “Let us just defend the whole diff so we do not have to rework anything during review.” A branch contains one weakly justified file alongside necessary root-cause changes. Your…

5 min
Quick Reference: Run-Control Cards For Codex

What four lines belong in a strong opening Codex brief? Objective, constraints, starting evidence, and verification. Those four lines tell the agent what matters, where the boundaries are, where to look first, and how success will be proven. When should you ask Codex to explain instead of implement? Choose the right first verb Match autonomy to uncertainty. “Can we just let Codex clean up whatever looks messy while it is in there?” A teammate is expanding scope during a focused bugfix. Your line Let us keep today’s run on the bug and only include adjacent cleanup if it stays inside…

5 min
Quick Reference: Sandbox Judgment Cards

What should a hard sandbox blocker do to the plan? It should split the work into what is still executable locally and what must be deferred. Once the limit is known, repeated retries are noise. The productive move is to adapt the plan and make the deferred step explicit. What separates a disciplined blocked run from an undisciplined one? Blocked does not mean useless Honest adaptation preserves trust. “Keep retrying the remote command; maybe the sandbox will let it through.” A teammate is reacting emotionally to an environment limit. Your line The environment already told us this path is blocked,…

5 min

Skill catalogue | Browse the library

Put it into practice

Choose your next learning habit.

Contact us