Agents · L2 · 20 min
ReAct, at learning depth
Learn in five minutes
- ReAct interleaves a written reason and an action.
- The paper is Yao and co-authors, 2022.
- The reason is not automatically true. It is text.
- The action still goes through your tool and your cap.
- You can store the reason in the trace so a reviewer can see it.
A reason that says 'the note contains a date' must be checked against the note. The sentence is not the check.
Visual
Reason, then act
- Write a reason: the card has no due date.
- Act: call the refuse tool.
- Check the card.
- If the reason was wrong, the trace shows the mismatch.
Quiz
Ecosystem
- ReAct
- A pattern that writes a reason and takes an action in turns.
Sisters: Workflows, State machines, Function calling.
The same loop can sit behind chat or a voice turn. The channel does not remove the cap.
MCP is one way to plug tools into that loop. It is the next track.
Config
- Write the goal in one sentence.
- Name the input and the allowed output.
- Save the trace next to the result.
Troubleshooting
- The answer looks fluent and is wrong. Check whether a source passage actually contains the claim.
- The loop never stops. Set a step cap and stop when the tool result repeats.
Sources and go deeper
- Yao and co-authors, ReAct: Synergizing Reasoning and Acting in Language Models, 2022 paper last checked 2026-10
- Large language model — Wikipedia wikipedia last checked 2026-10