Reflexion: Language Agents with Verbal Reinforcement Learning

Reflexion: Language Agents with Verbal Reinforcement Learning

10 Oct 2023 | Noah Shinn, Federico Cassano, Edward Berman, Ashwin Gopinath, Karthik Narasimhan, Shunyu Yao
The paper introduces *Reflexion*, a novel framework for reinforcement learning in large language models (LLMs) that uses verbal feedback to enhance learning from trial-and-error. Unlike traditional reinforcement learning methods, Reflexion updates agents through linguistic feedback rather than weight updates. Agents reflect on task feedback signals and maintain reflective text in an episodic memory buffer to improve decision-making in subsequent trials. Reflexion is flexible and can incorporate various types and sources of feedback signals, leading to significant improvements across diverse tasks such as sequential decision-making, coding, and language reasoning. The authors demonstrate that Reflexion achieves state-of-the-art results on the HumanEval coding benchmark, surpassing GPT-4. The paper also includes ablation studies and analysis of different feedback signals, feedback incorporation methods, and agent types, providing insights into their impact on performance. All code, demos, and datasets are released for further research.The paper introduces *Reflexion*, a novel framework for reinforcement learning in large language models (LLMs) that uses verbal feedback to enhance learning from trial-and-error. Unlike traditional reinforcement learning methods, Reflexion updates agents through linguistic feedback rather than weight updates. Agents reflect on task feedback signals and maintain reflective text in an episodic memory buffer to improve decision-making in subsequent trials. Reflexion is flexible and can incorporate various types and sources of feedback signals, leading to significant improvements across diverse tasks such as sequential decision-making, coding, and language reasoning. The authors demonstrate that Reflexion achieves state-of-the-art results on the HumanEval coding benchmark, surpassing GPT-4. The paper also includes ablation studies and analysis of different feedback signals, feedback incorporation methods, and agent types, providing insights into their impact on performance. All code, demos, and datasets are released for further research.
Reach us at info@study.space