Retroformer: Retrospective Large Language Agents with Policy Gradient Optimization

Fuente: arXiv
Guardado en:
Detalles Bibliográficos
Autores principales: Yao, Weiran, Heinecke, Shelby, Niebles, Juan Carlos, Liu, Zhiwei, Feng, Yihao, Xue, Le, Murthy, Rithesh, Chen, Zeyuan, Zhang, Jianguo, Arpit, Devansh, Xu, Ran, Mui, Phil, Wang, Huan, Xiong, Caiming, Savarese, Silvio
Formato: Preprint
Publicado: 2023
Materias:
Acceso en línea:
Etiquetas: Agregar Etiqueta
Sin Etiquetas, Sea el primero en etiquetar este registro!
_version_ 1866910434372616192
author Yao, Weiran
Heinecke, Shelby
Niebles, Juan Carlos
Liu, Zhiwei
Feng, Yihao
Xue, Le
Murthy, Rithesh
Chen, Zeyuan
Zhang, Jianguo
Arpit, Devansh
Xu, Ran
Mui, Phil
Wang, Huan
Xiong, Caiming
Savarese, Silvio
author_facet Yao, Weiran
Heinecke, Shelby
Niebles, Juan Carlos
Liu, Zhiwei
Feng, Yihao
Xue, Le
Murthy, Rithesh
Chen, Zeyuan
Zhang, Jianguo
Arpit, Devansh
Xu, Ran
Mui, Phil
Wang, Huan
Xiong, Caiming
Savarese, Silvio
contents Recent months have seen the emergence of a powerful new trend in which large language models (LLMs) are augmented to become autonomous language agents capable of performing objective oriented multi-step tasks on their own, rather than merely responding to queries from human users. Most existing language agents, however, are not optimized using environment-specific rewards. Although some agents enable iterative refinement through verbal feedback, they do not reason and plan in ways that are compatible with gradient-based learning from rewards. This paper introduces a principled framework for reinforcing large language agents by learning a retrospective model, which automatically tunes the language agent prompts from environment feedback through policy gradient. Specifically, our proposed agent architecture learns from rewards across multiple environments and tasks, for fine-tuning a pre-trained language model which refines the language agent prompt by summarizing the root cause of prior failed attempts and proposing action plans. Experimental results on various tasks demonstrate that the language agents improve over time and that our approach considerably outperforms baselines that do not properly leverage gradients from the environment. This demonstrates that using policy gradient optimization to improve language agents, for which we believe our work is one of the first, seems promising and can be applied to optimize other models in the agent architecture to enhance agent performances over time.
format Preprint
id arxiv_https___arxiv_org_abs_2308_02151
institution arXiv
publishDate 2023
record_format arxiv
spellingShingle Retroformer: Retrospective Large Language Agents with Policy Gradient Optimization
Yao, Weiran
Heinecke, Shelby
Niebles, Juan Carlos
Liu, Zhiwei
Feng, Yihao
Xue, Le
Murthy, Rithesh
Chen, Zeyuan
Zhang, Jianguo
Arpit, Devansh
Xu, Ran
Mui, Phil
Wang, Huan
Xiong, Caiming
Savarese, Silvio
Computation and Language
Artificial Intelligence
Recent months have seen the emergence of a powerful new trend in which large language models (LLMs) are augmented to become autonomous language agents capable of performing objective oriented multi-step tasks on their own, rather than merely responding to queries from human users. Most existing language agents, however, are not optimized using environment-specific rewards. Although some agents enable iterative refinement through verbal feedback, they do not reason and plan in ways that are compatible with gradient-based learning from rewards. This paper introduces a principled framework for reinforcing large language agents by learning a retrospective model, which automatically tunes the language agent prompts from environment feedback through policy gradient. Specifically, our proposed agent architecture learns from rewards across multiple environments and tasks, for fine-tuning a pre-trained language model which refines the language agent prompt by summarizing the root cause of prior failed attempts and proposing action plans. Experimental results on various tasks demonstrate that the language agents improve over time and that our approach considerably outperforms baselines that do not properly leverage gradients from the environment. This demonstrates that using policy gradient optimization to improve language agents, for which we believe our work is one of the first, seems promising and can be applied to optimize other models in the agent architecture to enhance agent performances over time.
title Retroformer: Retrospective Large Language Agents with Policy Gradient Optimization
topic Computation and Language
Artificial Intelligence
url https://arxiv.org/abs/2308.02151