Skip to main content
QUICK REVIEW

[论文解读] Language Agent Tree Search Unifies Reasoning Acting and Planning in Language Models

Andy Zhou, Kai Yan|arXiv (Cornell University)|Oct 6, 2023
Topic ModelingComputer Science被引用 9
一句话总结

LATS 通过将语言模型组件在蒙特卡洛树搜索框架中视为代理、价值函数和优化器,将规划、行动和推理统一为语言模型的能力,并利用外部反馈和自我反思来提升在各种任务上的决策。

ABSTRACT

While language models (LMs) have shown potential across a range of decision-making tasks, their reliance on simple acting processes limits their broad deployment as autonomous agents. In this paper, we introduce Language Agent Tree Search (LATS) -- the first general framework that synergizes the capabilities of LMs in reasoning, acting, and planning. By leveraging the in-context learning ability of LMs, we integrate Monte Carlo Tree Search into LATS to enable LMs as agents, along with LM-powered value functions and self-reflections for proficient exploration and enhanced decision-making. A key feature of our approach is the incorporation of an environment for external feedback, which offers a more deliberate and adaptive problem-solving mechanism that surpasses the constraints of existing techniques. Our experimental evaluation across diverse domains, including programming, interactive question-answering (QA), web navigation, and math, validates the effectiveness and generality of LATS in decision-making while maintaining competitive or improved reasoning performance. Notably, LATS achieves state-of-the-art pass@1 accuracy (92.7%) for programming on HumanEval with GPT-4 and demonstrates gradient-free performance (average score of 75.9) comparable to gradient-based fine-tuning for web navigation on WebShop with GPT-3.5. Code can be found at https://github.com/lapisrocks/LanguageAgentTreeSearch

研究动机与目标

  • Motivate the need for autonomous LM agents that can plan, act, and reason in external environments.
  • Propose LATS, a general LM-based Monte Carlo Tree Search framework that leverages environment feedback and self-reflection.
  • Demonstrate LATS across diverse domains (programming, open-domain QA, and web navigation) to show broad applicability.
  • Show that external feedback and an integrated reasoning-acting-planning loop improve performance over prior prompting methods.

提出的方法

  • Repurpose a pretrained LM as an LM agent, value function, and optimizer within an MCTS-like search.
  • Define a node as [x, a1..i, o1..i], and perform standard MCTS operations (selection, expansion, evaluation, simulation, backpropagation) with LM prompts guiding actions and value estimates.
  • Use the LM to generate n actions at expansion and to score leaf nodes as the value function, enabling deliberate trajectory construction.
  • Incorporate external feedback via environment observations and a self-reflection module that annotates failed trajectories and is stored for in-context learning.
  • Include a reflection step that augments future trials with semantic guidance, enriching the scalar reward signal.
  • Allow the LM to interact with external tools or APIs (as in ReAct) within the action set to bridge reasoning with action in real environments.
  • Evaluate LATS on programming (HumanEval with GPT-4), HotPotQA, and WebShop to illustrate versatility and performance gains.
Figure 1: An overview of LATS. LATS uses an external environment and self-reflection to improve reasoning and decision-making.
Figure 1: An overview of LATS. LATS uses an external environment and self-reflection to improve reasoning and decision-making.

实验结果

研究问题

  • RQ1Can an LM-based Monte Carlo Tree Search framework unify reasoning, planning, and acting for decision-making tasks?
  • RQ2Does leveraging external environmental feedback and LM-generated reflections improve performance beyond prior prompting methods like ReAct, CoT, ToT, and RAP?
  • RQ3How does LATS perform across domains requiring programming, multi-hop QA, and web navigation?
  • RQ4What is the impact of varying the expansion width (n) and trajectory samples (k) on performance and computation?
  • RQ5To what extent does self-reflection contribute to performance gains in LM-driven planning and acting?

主要发现

  • LATS 在 GPT-4 的 HumanEval 编程任务上达到 94.4% 的 Pass@1,创造该设置的最新纪录。
  • 在 WebShop 任务上,GPT-3.5 下的 LATS 平均得分为 75.9,展现出相对于基线的更优探索型规划。
  • 在 HotPotQA 中,LATS 在行动驱动的因果性评估(EM)方面达到最高值 0.61,推理表现也具竞争力(0.61,介于基线的 0.60–0.64 区间)。
  • LATS 在 HotPotQA 的不同采样预算下均优于 ReAct,且更大规模的节点扩展(n)带来持续提升。
  • 自我反思对性能的贡献适中(在某些消融实验中约提升 0.05 点),表明语义性反馈在标量反向传播之外提供了互补价值。
  • 消融结果显示移除某些组件(LM 启发式、反思或 DFS 配置)会降低性能,强调完整 LATS 设计的重要性。
Figure 2: An overview of the differences between LATS and recently proposed LM search algorithms ToT (Yao et al., 2023a ) and RAP (Hao et al., 2023 ) . LATS leverages environmental feedback and self-reflection to further adapt search and improve performance.
Figure 2: An overview of the differences between LATS and recently proposed LM search algorithms ToT (Yao et al., 2023a ) and RAP (Hao et al., 2023 ) . LATS leverages environmental feedback and self-reflection to further adapt search and improve performance.

阅读本论文

在 Nubint 阅读器中打开原文,边读边就任意段落提问。

在 Nubint 中阅读本论文

本解读由 AI 根据论文原文生成,引用前请核对原文。