Phase 10 · Agentic AI/
Lesson 10.3advanced3 h⚡ live demo

Reasoning and planning for agents

ReAct, plan-and-execute, search over thoughts, reflection, reasoning models

A long task is a sequence of decisions, and every wrong decision costs a step at best and the whole task at worst (10.9 Evaluating agents). Planning techniques — interleaved reasoning (ReAct), up-front plans, tree search, self-critique — are ways to spend more compute at decision points where it pays off. Since 2024 much of this moved inside reasoning models trained with RL (8.6 Reasoning models and test-time compute), so you also need to know which hand-built techniques are obsolete and which still matter.

You'll be able to

  • Write and read ReAct traces and explain why reasoning plus acting beats either alone
  • Compare plan-and-execute, Tree of Thoughts, LATS, Reflexion and Self-Refine on cost and when they help
  • Explain why external verification (tests, tool outputs) is the bottleneck for self-improvement loops
  • Decide when to use a reasoning model's built-in deliberation versus explicit planning scaffolds, and control the budget

Key ideas

  1. ReAct interleaves thoughts, actions and observations: reasoning tracks the plan, actions ground it in real information — the explicit form of the agent loop.
  2. Plan-and-execute writes a plan first, executes with cheaper calls and replans on surprises; keep the plan mutable or it goes stale.
  3. Search methods (best-of-N, self-consistency, Tree of Thoughts, LATS) trade N×–100× compute for reliability and only pay off with a trustworthy verifier or judgeable partial states.
Show 4 more key ideas
  1. Reflexion and Self-Refine help when feedback is external (tests, tools); self-critique with nothing new to look at is weak and biased.
  2. Verification is the bottleneck: a planner with a perfect verifier can brute-force success; without one it is hoping.
  3. Reasoning models internalized much of the scaffolding; the remaining levers are thinking budgets, external verification and best-of-N.
  4. Spend deliberation on hard, irreversible or unverifiable decisions and act directly on easy reversible ones.

Suggested path through this lesson