IT lexicon › AI & ML › ReAct (prompting pattern)

ReAct (prompting pattern)

AI & ML På svenska → Updated: 2026-07-30

Reasoning + Acting — an agent pattern where the LLM alternates between generating "Thought:" (reasoning) and "Action:" (tool call), receives "Observation:" from the tool, and repeats until the task is done. Yao et al, 2022.

Pioneer paper for LLM agents. Format: e.g. Thought: I need to search for the price of X. Action: search("X price"). Observation: $50. Thought: That matches the budget. Action: finish(yes). Despite the name, nothing to do with the React library — completely unrelated. LangChain's ReAct agent was the default implementation for a long time. Modern alternatives: Plan-and-Execute, Reflexion (learn from mistakes), Tree-of-Thoughts (multi-path reasoning). ReAct is still the base-case agent loop students learn first.

← Back to the lexicon