workflowContext Engineering1 min read
Explore → Plan → Implement
Separate research from implementation so you stop solving the wrong problem.
A four-phase workflow built into Claude Code that prevents the most common failure mode — jumping straight to code before understanding the codebase. Use it whenever the change touches more than one file or the scope isn't obvious upfront.
The Problem
Most agentic coding failures happen in the first ten seconds — when Claude jumps straight to writing code before it understands the codebase. It solves the wrong problem, edits the wrong file, or misses a pattern your team has already established. The explore-first loop fixes that.
Phase 1: Explore
Open Plan Mode (Shift+Tab twice) and ask Claude to read relevant files without touching anything:
read /src/auth and understand how sessions and login work.also check how we handle environment variables for secrets.Claude explores without making changes. You see what it finds before it acts.
Phase 2: Plan
Still in Plan Mode, ask for a concrete implementation plan:
I want to add Google OAuth. What files need to change?What's the session flow? Write a step-by-step plan.Press Ctrl+G to open the plan in your editor and edit it directly before Claude proceeds. This is the moment to catch wrong assumptions cheaply.
Phase 3: Implement
Switch to Normal Mode and give Claude the green light — with a verification hook:
implement the OAuth flow from your plan. write tests for thecallback handler, run the test suite, and fix any failures.Claude writes, tests, and iterates. You review output, not keystrokes.
More in Context Engineering
- 1 min readWriter / Reviewer PatternA second Claude session reviewing code it didn't write catches more than a self-review.Read
- 2 min readCLAUDE.md That Actually WorksStop re-explaining your project to every new agent session.Read
- 4 min readAGENTS.md — One File, Every AgentThe open standard that makes your project context portable across Claude Code, Cursor, Codex, Copilot, and 20+ other agents. Write it once, every agent reads it.Read
