arXiv:2502.01600cs.LGcs.AI2025-02被引 102

用强化学习训练能长期交互的智能体,性能超越大模型。

Reinforcement Learning for Long-Horizon Interactive LLM Agents

  • 直接在真实环境中用强化学习训练数字代理,不依赖预设规则。
  • 320亿参数模型在AppWorld上比OpenAI o1高9个百分点,相对提升15%。
  • 适合研究长期任务规划与真实环境交互的AI开发者。

交互式数字代理(IDAs)通过调用状态化数字环境的API来响应用户请求。尽管基于指令微调的大语言模型(LLMs)可在多步交互中响应界面调用反馈,但它们并未在其目标环境中进行训练。此前方法在AppWorld等复杂基准上的任务完成率不足一半。本文提出一种强化学习(RL)方法,直接在目标环境中训练IDAs。我们将该训练形式化为部分可观测马尔可夫决策过程,并推导出LOOP——一种数据与内存高效的近端策略优化变体。LOOP无需价值网络,且内存中仅保留一个底层LLM副本,实现简便且内存效率堪比单个LLM微调。在AppWorld环境中,使用LOOP训练的320亿参数代理,性能优于更大的OpenAI o1代理9个百分点(相对提升15%)。据我们所知,这是首个在通过直接API调用与状态化、多领域、多应用环境交互的场景中应用强化学习的报告。分析表明,该代理学会了查阅API文档、避免无根据假设、减少虚构内容并从失误中恢复。

原文摘要 · Abstract (English)

Interactive digital agents (IDAs) leverage APIs of stateful digital environments to perform tasks in response to user requests. While IDAs powered by instruction-tuned large language models (LLMs) can react to feedback from interface invocations in multi-step exchanges, they have not been trained in their respective digital environments. Prior methods accomplish less than half of tasks in sophisticated benchmarks such as AppWorld. We present a reinforcement learning (RL) approach that trains IDAs directly in their target environments. We formalize this training as a partially observable Markov decision process and derive LOOP, a data- and memory-efficient variant of proximal policy optimization. LOOP uses no value network and maintains exactly one copy of the underlying LLM in memory, making its implementation straightforward and as memory-efficient as fine-tuning a single LLM. A 32-billion-parameter agent trained with LOOP in the AppWorld environment outperforms the much larger OpenAI o1 agent by 9 percentage points (15% relative). To our knowledge, this is the first reported application of RL to IDAs that interact with a stateful, multi-domain, multi-app environment via direct API calls. Our analysis sheds light on the effectiveness of RL in this area, showing that the agent learns to consult the API documentation, avoid unwarranted assumptions, minimize confabulation, and recover from setbacks.

强化学习智能体长时序大模型

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。