Explain the structural difference between a pure chain-of-thought (CoT) trace and a ReAct trace. What does interleaving Thought → Action → Observation steps buy over a CoT trace that only reasons?
ReAct interleaves Thought, Action, and Observation, so each step reasons over a real tool result. Pure chain-of-thought reasons over a hallucinated continuation instead.
Imagine doing a long math word problem two ways. In the first way you sit in a quiet room and reason it out entirely in your head, never checking anything against the real world. If you misremember one number on line two, every line after it inherits that mistake and you never notice. In the second way, after each step you actually look something up, run a quick calculation, or check a fact. Then you continue reasoning from what you found. The second person stays anchored to reality. Chain-of-thought is the first person, reasoning in pure imagination. ReAct is the second person. It thinks a little, acts to gather a real fact, looks at the result, then thinks again with that fact in hand.
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.
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.
Chain-of-thought and ReAct are both ways to make a language model reason in steps. But they differ in one structural property that changes everything downstream. Chain-of-thought is a single uninterrupted generation. The model is prompted to think out loud. It emits a reasoning trace where every token is conditioned only on the prompt and the tokens it has already produced. After the prompt, no information from outside the model ever enters the trace.
ReAct breaks that single trace into a repeating cycle of three step types. A Thought is the model reasoning. An Action is a tool invocation. An Observation is the real result that tool returned, written back into the context by the runtime rather than generated by the model. The core idea is interleaving. Reasoning and acting alternate, so the model never reasons very far without checking its work against the world.
That one change is why ReAct is treated as the foundational agent pattern rather than a prompting trick. It controls where information enters a reasoning trace, with consequences for accuracy, recovery, and cost.
The structural difference: one trace versus interleaved triples
In a pure chain-of-thought trace, the model receives the question and generates a continuous block of reasoning that ends in an answer. The trace is autoregressive end to end. Token 500 depends on tokens 1 through 499, all of which the model itself produced. The world is consulted exactly once, at the prompt, and never again.
ReAct rewrites this as a loop. The model emits a Thought, then an Action such as search(query) or calculator(expr). The runtime executes that Action and appends the genuine result as an Observation. The model then emits the next Thought, which now reads that Observation as part of its context. In practice, literal labels in the prompt format usually delimit the three step types. The runtime can then parse out the Action, run it, and splice the Observation back in before handing control to the model again.
The detail that matters most is who writes the Observation. The model does not generate it. The runtime injects it. That single fact is the entire difference between reasoning in imagination and reasoning grounded in fact. It is easy to miss when ReAct is described as merely chain-of-thought with tools attached.
Some things stay the same. Both traces are still produced one token at a time by the same model, and both still benefit from the model thinking before answering. ReAct does not replace reasoning; it breaks it into shorter parts. The Thought steps in ReAct are exactly chain-of-thought reasoning. What changes is that genuine tool results now separate those reasoning bursts. The model alternates between proposing and verifying, instead of proposing all the way to a conclusion it never checks.
Situations where this technique stops working.
2–4 min · Everything important, quickly.
Real products, models, and research that use this idea.
- LangChain's create_agent, built on LangGraph, wraps Anthropic or OpenAI tool calling in a loop of a model node and a tool node. It cycles Thought, Action, and Observation until the model emits a final answer.
- Claude Opus 4.7 in agentic search interleaves reasoning with web-search tool calls. Each new query is shaped by the snippets the last search actually returned.
What an interviewer would ask next. Try answering before peeking at the approach.
QIf ReAct grounds each step, why do ReAct agents still hallucinate and loop on bad tool results?
Grounding only helps if the model reads the Observation correctly. Discuss misread errors, noisy tool output, and the need for repeated-action detection plus verification of claimed answers before accepting them.
Red flags & common mistakes
The phrases that signal junior thinking. Click to expand.
Red flags & common mistakes
The phrases that signal junior thinking. Click to expand.
Describing ReAct as only chain of thought with tools attached. The point is interleaving, so each Thought reasons over a real Observation rather than a guessed one.
60 second bullets to scan on the way to the call.
Contrast what feeds each step in chain of thought versus a ReAct trace.
Name the three token types ReAct interleaves and where each comes from.
Primary sources. Browse if you want the original framing.
Same topic, related formats. Practice these next.