Planning and multi-step reasoning
Breaking goals into steps—how agents plan, and how that overlaps with classical search.
What you'll learn
- Compare implicit planning in prompts with explicit plan–execute loops.
- Relate LLM step lists to classical search and decomposition.
- Detect when to use planners, graphs, or human checkpoints.
In plain English
Complex tasks rarely finish in one reply. Planning means splitting a goal into ordered steps: gather files, analyze data, draft report, review. Agents may write the plan in text, maintain a todo list in memory, or call a dedicated planner module.
Multi-step reasoning is the model thinking across turns—each step's output becomes context for the next.
How it works
Patterns include plan-then-act (generate a numbered plan, execute step by step), ReAct-style interleaving (thought → action → observation), and external workflow engines (DAGs, state machines) where the LLM fills nodes.
Classical AI search still applies when states and actions are well defined—LLMs propose heuristics or natural language plans; code can verify constraints.
- Decompose: break user goal into checkable subtasks.
- Execute: one subtask per loop iteration with tools.
- Replan: update steps when observations contradict assumptions.
- Stop: verify completion criteria before returning.
Going deeper
Long horizons accumulate error—early wrong assumptions propagate. Shorter plans with frequent observation beats one giant upfront scheme.
Hybrid systems use LLMs for language-heavy steps and traditional code for math, SQL, or graph search where determinism wins.
Common misconceptions
- A detailed plan at the start guarantees success.
- Environments change; agents need observation-driven replanning.
- Chain-of-thought equals reliable planning.
- CoT is generated text; executable plans need validation and tools.
- Classical planning is obsolete.
- Explicit graphs and search help when actions and states are discrete.
Key facts
- Agents break goals into steps executed over multiple loop iterations.
- Plans can be implicit (prompt) or explicit (stored task lists).
- Observations after each step should trigger replanning when needed.
- Error compounding makes horizon length a key design parameter.
- Hybrid LLM + code workflows outperform pure monologue on many ops tasks.
Sources used
These free resources informed this page. ANN writes original explainers; we do not copy course text behind paywalls.
- Dive into Deep Learning — RL and sequence modeling background for planning loops.
- Google Machine Learning Crash Course — Evaluation mindset for iterative systems.
- Anthropic Prompt Engineering Interactive Tutorial — Tool schemas and structured prompts for agent loops.
Also explore AI companies, Live Feed, and Weekly Brief.
