Zenaique

Why do plan then act agents keep an explicit plan block in context, even when the model could re-plan from scratch?

Flashcard·Medium·4.0 · 0·~30s·Asked atForethoughtRephrase AiWriter
Attempt it
TL;DR

A persisted plan block anchors agent behavior, gives engineers a debuggable artifact, and lets the model condition cheaply on a stable trajectory instead of re-deriving intent every iteration.

Memory aid
Sign in to see the mnemonic that makes this stick.
Easy to grasp

Picture a kitchen with five cooks who share one notepad. If every cook ripped out the page and rewrote the menu from scratch every minute, the kitchen would never produce a meal. The notepad keeps everyone aligned. Now imagine the notepad as the agent's plan. It is a short list pinned at the top of the conversation. It says what the agent is trying to do and which step it is on. Each new action looks at the notepad, picks up where the last action left off, and updates the page only when a step is done. The notepad does not free the cooks from thinking, but it stops them from arguing with their past selves about what dinner is.

Concept explanation~2 min read

Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example. Click to expand.

Plan then act is a common agent design pattern. The agent writes an explicit plan as its first action, then iterates: read the plan, pick the next step, call a tool, observe the result, update the plan, repeat. The persistent plan block is the spine of that loop. Without it, every iteration is a fresh planning problem and the agent thrashes. With it, the agent commits to a trajectory and the engineer can read what it committed to.

What the plan block contains

A well-formed plan block is short and structured. The top line names the overall goal. A sub-list lists the open sub-goals in priority order, and an optional notes line records any constraints the agent has discovered. The plan is not a chain-of-thought log, and it is not a tool call history. It is the agent's current intent, expressed in a form a person can read in five seconds.

The structure matters. A free-form prose plan tends to grow unbounded because there is no obvious place to delete from. A list-structured plan with explicit status markers (open, done, dropped) gives the agent a natural edit interface. It can mark a sub-goal done when it closes, or drop one when it turns out to be unreachable. The whole point of the block is to be edited, so the format should make editing easy.

In practice the plan often coexists with two other context engineering primitives. One is a running summary of the conversation so far (compresses old turns). The other is a memory store for durable facts the agent has learned (survives across sessions). Each one has its own job. The plan is about what the agent is doing now, not about what has happened or what is true.

Why consistency matters more than freshness
The debuggability dividend
Cheaper conditioning and attention focus
Failure mode: plan rot and how to prevent it
Sign in to unlock the full deep dive.

Situations where this technique stops working.

Sign in to see when this approach fails.

2–4 min · Everything important, quickly.

Sign in to see the quick scan of the deep dive.

Real products, models, and research that use this idea.

  • LangGraph's typed state stores the plan as a named field and updates it in-place via reducer functions on each node.
  • Anthropic's Agent SDK has todo-tracking tools that the model calls to mark items pending, in progress or completed across turns.
Sign in to see more production examples.

What an interviewer would ask next. Try answering before peeking at the approach.

QWhat does plan rot look like in practice, and how do you detect it?
A

Plan rot is when the plan grows without being edited, so it accumulates done sub-goals, dead branches, and stale notes. Detection signals: plan-block token count rising monotonically across iterations, model tool calls starting to ignore the plan, and trace summaries showing the agent re-deriving intent inside its reasoning instead of conditioning on the plan. The fix is to give the model an explicit edit-plan tool or a reducer step that compresses closed sub-goals.

2 more follow-ups an interviewer would ask next. Sign in to reveal them.

Red flags & common mistakes

The phrases that signal junior thinking. Click to expand.

Most common mistake

Treating the plan as a write-once header instead of a living document that gets pruned and updated as sub-goals close.

Sign in to see all red flags and common mistakes.

60 second bullets to scan on the way to the call.

  • State what a plan block is and where it sits in the assistant turn

  • Name the three reasons to persist it across iterations

Sign in to unlock the revision sheet.

Primary sources. Browse if you want the original framing.

Similar questions

Same topic, related formats. Practice these next.

4 curated
Next question
List the trace spans a context engineering pipeline should emit per call
Flashcard·Medium