---
title: "ReAct Prompting"
source: "https://systems-analysis.info/eng/ReAct_Prompting"
wiki: "systems-analysis.info/eng"
article: "ReAct_Prompting"
language: "en"
categories:
  - "Category:English"
  - "Category:Large language models"
  - "Category:Machine learning"
  - "Category:Prompt engineering"
  - "Category:Technology"
revision_id: 324
wiki_created_at: 2026-09-06T22:22:06Z
wiki_modified_at: 2026-09-06T22:22:06Z
downloaded_at: 2026-09-07T22:22:42Z
---

# ReAct Prompting

**ReAct** (short for **Reason + Act**) is a prompting paradigm for [large language models](https://systems-analysis.info/eng/Large_language_model "Large language model") (LLMs) that enables them to solve complex tasks by interleaving verbal reasoning (thoughts) and actions that interact with an external environment<sup>[\[1\]](https://systems-analysis.info/eng/ReAct_Prompting#cite_note-yao2022react-1)</sup>. The method was proposed in 2022 by researchers from **Google Research** and **Princeton University** and has become a fundamental approach in the development of intelligent agents.

The key innovation of ReAct is the integration of logical reasoning, characteristic of techniques like Chain-of-Thought (CoT), with the execution of external actions, such as information retrieval or interaction with software interfaces (APIs). This allows the model to dynamically adjust its plan, verify facts, and overcome the limitations of its own often outdated or incomplete knowledge<sup>[\[2\]](https://systems-analysis.info/eng/ReAct_Prompting#cite_note-googleblog-react-2)</sup>.

## Background and History

Before the advent of ReAct, there were two primary but separate approaches to using LLMs for solving complex problems:

- **Chain-of-Thought (CoT)**: The model generates step-by-step logical reasoning to solve a task, but it does so in an "informational vacuum," relying solely on its internal knowledge. This often leads to factual errors and "hallucinations"<sup>[\[1\]](https://systems-analysis.info/eng/ReAct_Prompting#cite_note-yao2022react-1)</sup>.
- **Act-Only**: The model generates a sequence of actions to interact with an external environment (e.g., in text-based games), but without explicit high-level planning. Such systems struggle with errors and cannot adapt their strategy when faced with unforeseen circumstances.

ReAct was created to synergistically combine the strengths of both approaches. It allows the model not only to reason but also to *ground* its reasoning in facts from the external world and adapt its actions based on the feedback received.

## How It Works: The Thought–Action–Observation Cycle

ReAct operates within an iterative cycle that includes three key components. The model sequentially generates a trajectory consisting of **Thought**, **Action**, and **Observation** steps.

**Example prompt structure:**

***Question: What is the capital city where the inventor known for alternating current was born?***

***Thought 1:** I need to find out who invented alternating current. Then, I need to find their birthplace and check if that city is a capital.*

***Action 1:** Search\[inventor of alternating current\]*

***Observation 1:** Alternating current (AC) was developed and promoted by Nikola Tesla.*

***Thought 2:** Now I need to find out where Nikola Tesla was born.*

***Action 2:** Search\[Nikola Tesla's birthplace\]*

***Observation 2:** Nikola Tesla was born in the village of Smiljan, Austrian Empire (modern-day Croatia).*

***Thought 3:** Smiljan is not a capital city. Thus, the question does not have a straightforward answer as phrased. However, Tesla lived and worked for a long time in the US. Perhaps the question refers to the capital of the country where he made his major discoveries. That is a more complex question. I should state the fact based on his birthplace. The city of his birth is not a capital.*

***Final Answer:** The inventor associated with alternating current, Nikola Tesla, was born in Smiljan (Croatia), which is not a capital city.*

### Thought

The model generates internal reasoning in which it analyzes the task, decomposes it into sub-tasks, forms or adjusts a plan of action, and assesses the current state. This step does not affect the external environment but serves for internal planning.

### Action

Based on its reasoning, the model performs an external action by calling one of the available tools. Examples of actions include:

- Search \[query\] — to search for information in a knowledge base (e.g., Wikipedia).
- Click \[element\] — to navigate a web page.
- API_call \[parameters\] — to call an external API.

### Observation

The system or an external tool executes the action and returns a result (observation). This could be a text snippet, an API response, or an error message. The model uses this observation to form its next thought, closing the feedback loop<sup>[\[2\]](https://systems-analysis.info/eng/ReAct_Prompting#cite_note-googleblog-react-2)</sup>.

## Experimental Results and Effectiveness

The authors of ReAct tested the method on a wide range of tasks, demonstrating its superiority over CoT and Act-Only approaches.

| Benchmark    | Task                         | ReAct (Success/Accuracy) | Chain-of-Thought (Success/Accuracy) | Act-Only (Success/Accuracy) |
|--------------|------------------------------|--------------------------|-------------------------------------|-----------------------------|
| **FEVER**    | Fact Verification            | **87.6%**                | 82.8%                               | 70.1%                       |
| **HotpotQA** | Multi-hop Question Answering | 31.8%                    | **36.3%**                           | 17.0%                       |
| **ALFWorld** | Text-based Game (Planning)   | **71%**                  | 10%                                 | 13%                         |
| **WebShop**  | Web Navigation               | **40%**                  | \-                                  | 30.1%                       |

ReAct results compared to baseline methods on key benchmarks<sup>[\[1\]](https://systems-analysis.info/eng/ReAct_Prompting#cite_note-yao2022react-1)</sup>

- In tasks requiring **fact verification** (FEVER), ReAct significantly outperforms CoT, as it can verify information.
- In **interactive planning** tasks (ALFWorld, WebShop), ReAct demonstrates a huge advantage, as it can adapt to a changing environment.
- In **pure reasoning** tasks (HotpotQA), CoT can show comparable or even better results. However, a hybrid **ReAct+CoT** approach showed the best performance, achieving 35% on HotpotQA<sup>[\[1\]](https://systems-analysis.info/eng/ReAct_Prompting#cite_note-yao2022react-1)</sup>.

## Criticism and Limitations

Despite its effectiveness, ReAct has several limitations and vulnerabilities.

- **Brittleness**: Later research has shown that ReAct's success may be attributed not so much to a genuine synergy of reasoning and action but to the **syntactic similarity** between examples in the prompt and the current task. The model might follow the \`Thought-Action-Observation\` template without fully understanding the semantics of the reasoning<sup>[\[3\]](https://systems-analysis.info/eng/ReAct_Prompting#cite_note-verma2024brittle-3)</sup>.
- **Computational Costs**: Each ReAct cycle requires at least one LLM call and one call to an external tool, making it slow and expensive compared to standard prompting.
- **Dependence on Tools**: The agent's effectiveness is directly dependent on the quality and reliability of the available tools. An incorrect or noisy response from an API can steer the model's reasoning down a false path.

## Significance and Further Development

ReAct became a significant milestone in AI development, marking a shift from **generative systems** to **agentic systems**. It laid the conceptual and practical foundation for most modern frameworks for creating agents, such as:

- **LangChain**
- **LlamaIndex**
- **AutoGen**

The ideas behind ReAct served as a starting point for more complex reasoning architectures, such as **Reflexion** (which adds a self-reflection cycle after failures) and **Tree of Thoughts (ToT)** (which explores multiple reasoning paths in parallel).

## External links

- <a href="https://react-lm.github.io/" class="external text" rel="nofollow">Official ReAct Project Page</a>
- <a href="https://learnprompting.org/docs/agents/react" class="external text" rel="nofollow">ReAct description in the Learn Prompting guide</a>
- Google Research (2022). *ReAct: Synergizing Reasoning and Acting in Language Models* (blog post). <a href="https://research.google/blog/react-synergizing-reasoning-and-acting-in-language-models/" class="external text" rel="nofollow">Google Research Blog</a>.
- <a href="https://en.wikipedia.org/wiki/Prompt_engineering" class="external text" rel="nofollow">Prompt engineering — Wikipedia</a>

## Literature

- Yao, S. et al. (2022). *ReAct: Synergizing Reasoning and Acting in Language Models*. <a href="https://arxiv.org/abs/2210.03629" class="external text" rel="nofollow">arXiv:2210.03629</a>.
- Yao, S. et al. (2023). *Tree of Thoughts: Deliberate Problem Solving with Large Language Models*. <a href="https://arxiv.org/abs/2305.10601" class="external text" rel="nofollow">arXiv:2305.10601</a>.
- Shinn, N. et al. (2023). *Reflexion: Language Agents with Verbal Reinforcement Learning*. <a href="https://arxiv.org/abs/2303.11366" class="external text" rel="nofollow">arXiv:2303.11366</a>.
- Verma, V. et al. (2024). *On the Brittle Foundations of ReAct Prompting for Agentic Large Language Models*. <a href="https://arxiv.org/abs/2405.13966" class="external text" rel="nofollow">arXiv:2405.13966</a>.
- Yao, S. et al. (2022). *WebShop: Towards Scalable Real-World Web Interaction with Grounded Language Agents*. <a href="https://arxiv.org/abs/2207.01206" class="external text" rel="nofollow">arXiv:2207.01206</a>.
- Shridhar, M. et al. (2020). *ALFWorld: Aligning Text and Embodied Environments for Interactive Learning*. <a href="https://arxiv.org/abs/2010.03768" class="external text" rel="nofollow">arXiv:2010.03768</a>.
- Qin, L. et al. (2023). *AutoGen: Enabling Next-Gen LLM Applications via Multi-Agent Collaboration*. <a href="https://arxiv.org/abs/2308.08155" class="external text" rel="nofollow">arXiv:2308.08155</a>.
- Thorne, J. et al. (2018). *FEVER: A Large-Scale Dataset for Fact Extraction and Verification*. <a href="https://arxiv.org/abs/1803.05355" class="external text" rel="nofollow">arXiv:1803.05355</a>.
- Yang, Z. et al. (2018). *HotpotQA: A Dataset for Diverse, Explainable Multi-hop Question Answering*. <a href="https://arxiv.org/abs/1809.09600" class="external text" rel="nofollow">arXiv:1809.09600</a>.

## References

1.  <span id="cite_note-yao2022react-1">↑ <sup>[1.0](https://systems-analysis.info/eng/ReAct_Prompting#cite_ref-yao2022react_1-0)</sup> <sup>[1.1](https://systems-analysis.info/eng/ReAct_Prompting#cite_ref-yao2022react_1-1)</sup> <sup>[1.2](https://systems-analysis.info/eng/ReAct_Prompting#cite_ref-yao2022react_1-2)</sup> <sup>[1.3](https://systems-analysis.info/eng/ReAct_Prompting#cite_ref-yao2022react_1-3)</sup> Yao, S., Zhao, J., Yu, D., et al. (2022). "ReAct: Synergizing Reasoning and Acting in Language Models". *arXiv preprint arXiv:2210.03629*. <a href="https://arxiv.org/abs/2210.03629" class="external autonumber" rel="nofollow">[1]</a></span>
2.  <span id="cite_note-googleblog-react-2">↑ <sup>[2.0](https://systems-analysis.info/eng/ReAct_Prompting#cite_ref-googleblog-react_2-0)</sup> <sup>[2.1](https://systems-analysis.info/eng/ReAct_Prompting#cite_ref-googleblog-react_2-1)</sup> "ReAct: Synergizing Reasoning and Acting in Language Models". *Google Research Blog*. <a href="https://research.google/blog/react-synergizing-reasoning-and-acting-in-language-models/" class="external autonumber" rel="nofollow">[2]</a></span>
3.  <span id="cite_note-verma2024brittle-3">[↑](https://systems-analysis.info/eng/ReAct_Prompting#cite_ref-verma2024brittle_3-0) Verma, V., et al. (2024). "On the Brittle Foundations of ReAct Prompting for Agentic Large Language Models". *arXiv preprint arXiv:2405.13966*. <a href="https://arxiv.org/abs/2405.13966" class="external autonumber" rel="nofollow">[3]</a></span>
