Codex CLI Review, Planning & Project Commands
This group covers what you do around the agent's work rather than to it — inspecting what changed, deciding on an approach before anything is written, and giving a repository standing instructions so you stop repeating yourself in every session.
| Action | Windows | Mac | Description |
|---|---|---|---|
| Show the working-tree diff | /diff | /diff | Displays the Git diff of everything currently changed, untracked files included. The habitual check after an agent turn, and the reason untracked files are covered is that a new file is exactly what you would otherwise miss. |
| Run a code review | /review | /review | Reviews the working tree, with presets for comparing against a base branch, uncommitted changes only, or specific commits. Distinct from reading the diff yourself — this is the agent examining its own output against the code around it. |
| Switch to plan mode | /plan | /plan | Produces an execution plan without changing anything on disk. Worth reaching for on any task large enough that you would rather argue with the approach before it becomes a diff you have to read. |
| Generate an AGENTS.md scaffold | /init | /init | Creates a repository instructions file that Codex reads on every future session in that directory. The place to record conventions you would otherwise repeat in every prompt — build commands, style rules, directories to leave alone. |
| Change model and reasoning effort | /model | /model | Opens a picker for the active model and how much reasoning effort it should spend, switchable mid-conversation. Dropping to a lighter model for mechanical work and back up for design questions is a real cost lever within a single session. |
| List configured MCP tools | /mcp | /mcp | Shows which Model Context Protocol servers this session can reach. The first thing to check when an integration you configured appears to be doing nothing — an MCP server that failed to start is silent rather than loud. |
| Copy the last response | /copy | /copy | Puts the most recent completed output on the system clipboard, which beats selecting multi-line text in a terminal by a wide margin. Particularly useful for a generated command or block of code headed somewhere else. |
/diff shows the Git diff of everything currently changed, untracked files included. That inclusion is the important detail: a newly created file is precisely what an ordinary diff omits and precisely what you would otherwise fail to notice. Running /diff after each substantive turn is the habit that keeps an agent-driven session honest, because it converts a description of what the agent says it did into the actual set of changes on disk.
/review is a different operation from reading a diff. It has the agent examine the working tree as a reviewer would, with presets for comparing against a base branch, looking only at uncommitted changes, or reviewing specific commits. Having a model review its own output has obvious limits — it shares whatever misunderstanding produced the code — but it reliably catches the mechanical class of problem, and it costs one command.
/plan is the one worth reaching for more often than most people do. It produces an execution plan without touching anything on disk, which moves the argument about approach to before the work rather than after it. For any task large enough that you would be annoyed to read a wrong diff, arguing with a plan is cheaper in every dimension: less time, less context, and no working tree to restore.
/init generates an AGENTS.md scaffold in the current directory, and it is probably the highest-value few minutes available anywhere in the tool. Codex reads that file at the start of every future session in that repository. Build commands, test commands, code style, directories that must not be touched, deployment caveats, the reason a piece of code looks the way it does — anything you have explained twice belongs there. Every instruction moved into the file is one you stop paying for in attention and in context on every subsequent session, and unlike a prompt it is version-controlled alongside the code it describes.
/model opens a picker for the active model and its reasoning effort, changeable mid-conversation. This is a genuine cost and latency lever rather than a preference: dropping to a lighter model for mechanical edits and raising it for design questions within one session is a reasonable working pattern, and the switch does not reset context. Being able to make that choice per task rather than per session is the point.
/mcp lists the Model Context Protocol servers this session can reach, and it is the first thing to check when an integration you configured appears to be doing nothing. An MCP server that failed to start does not announce itself — it is simply absent, and the agent behaves as though the capability was never configured. /plugins covers the same ground for marketplace plugins, with /reload-plugins picking up changes without restarting.
/copy puts the most recent completed output on the system clipboard. That sounds trivial until you have tried to select thirty lines of code out of a terminal with the mouse, across a scroll boundary, without catching the prompt characters at the start of each line. For anything generated that is headed somewhere else — a command, a config block, a commit message — it is the difference between one keystroke and a fiddly selection.
Taken together this group is what separates supervising an agent from merely instructing one. /plan before, /diff and /review after, AGENTS.md so the context persists: none of them are shortcuts in the keystroke-saving sense, and all of them save considerably more time than the ones that are.
There is a natural sequence to them that is worth naming, because most people arrive at it eventually and it is faster to start there. For any task beyond a small edit: /plan first and read what comes back, correcting the approach while correcting is cheap. Let the agent work. /diff when it stops, to see what actually changed rather than what was reported. /review if the change is large enough that a second pass is worth a command. Commit. Anything you found yourself explaining during that cycle goes into AGENTS.md so the next session starts further along.
That loop is also what makes the difference between the tool being useful on a large codebase and being useful only on small self-contained tasks. Without /plan, the first sign of a misunderstanding is a diff. Without /diff, the record of what happened is the agent's own summary. Without AGENTS.md, every session re-learns the same conventions from scratch. Each of the three closes a specific gap, and it is the combination rather than any one of them that changes how much you can hand over.