HyperAI

ReAct Framework

The ReAct framework was proposed by Yao Shunyu et al. from Princeton University and Google Research in their paper “REACT:SYNERGIZING REASONING AND ACTING IN LANGUAGE MODELS” proposed a general paradigm that combines advances in reasoning and action to enable language models to solve a variety of language reasoning and decision-making tasks. The study demonstrated that the Reason+Act (ReAct) paradigm systematically outperforms the Reason+Act-only paradigm when prompting larger language models and fine-tuning smaller language models. The tight combination of reasoning and action also presents a task-solving trajectory consistent with humans, thereby improving interpretability, diagnosability, and controllability.

ReAct enables language models to generate verbal reasoning traces and textual actions in an interleaved manner. While actions result in observational feedback from the external environment, reasoning traces do not affect the external environment. Instead, they influence the model's internal state by reasoning about the context and updating the model with useful information to support future reasoning and actions.

ReAct is a simple yet effective approach for reasoning and acting in collaborative language models. Through various experiments focusing on multi-hop question answering, fact checking, and interactive decision-making tasks, the research team shows that ReAct, with interpretable decision traces, leads to superior performance.

ReAct demonstrates the feasibility of jointly modeling thoughts, actions, and environmental feedback in a language model, making it a versatile agent capable of solving tasks that require interaction with the environment.