让大模型多智能体系统通过强化学习自动优化流程,提升任务表现。
UnityMAS-O: A General RL Optimization Framework for LLM-Based Multi-Agent Systems

- 将完整工作流作为优化单元,支持角色、交互、奖励的灵活定义。
- 在多个数据集上优化后,小模型和严格代码评测指标提升显著。
- 适合需要多智能体协作与可复用训练框架的研究者使用。
基于大模型的多智能体系统将复杂任务分解为相互协作的角色,但多数仍依赖手动提示、工具和控制规则,智能体极少通过统一的强化学习接口进行优化。现有RL后训练框架主要针对单策略优化,缺乏对用户自定义多智能体流程、结构化交互、角色专属信用分配及可配置参数共享的支持。本文提出UnityMAS-O,一种面向大模型多智能体系统的通用强化学习优化框架。UnityMAS-O将完整工作流视为优化单元,而非单一响应或策略轨迹。它通过四个一等对象表示工作流:逻辑智能体角色、图状轨迹、用户定义奖励和智能体-模型映射。该设计解耦了逻辑角色与物理模型参数,支持完全共享、完全隔离和部分共享,奖励可在角色、回合和轨迹层级分配。UnityMAS-O基于Ray构建星型拓扑运行时,中心控制器执行工作流、调用工具、记录结构化轨迹并组装奖励;模型本地的工作组负责采样、缓冲、优势计算和分布式PPO式更新。用户可无需重写优化基础设施,即可定义智能体、工作流、模型映射和奖励。我们在检索增强问答、迭代代理搜索和反思式代码生成任务上实例化UnityMAS-O。在Natural Questions、HotpotQA和未见代码任务上,优化后的多智能体强化学习系统显著优于手动设定的工作流,尤其在小模型和严格代码全通过指标上提升明显。结果表明,UnityMAS-O可作为可复用基础架构,将多样化的基于大模型的多智能体工作流转化为可训练的多智能体强化学习系统。
原文摘要 · Abstract (English)
LLM-based multi-agent systems decompose complex tasks into interacting roles, but most remain manually orchestrated by prompts, tools, and control rules, while agents are rarely optimized through a unified reinforcement learning interface. Existing RL post-training frameworks mainly target single-policy optimization and lack abstractions for user-defined multi-agent workflows, structured interaction, role-specific credit assignment, and configurable parameter sharing. We present UnityMAS-O, a general RL optimization framework for LLM-based multi-agent systems. UnityMAS-O treats the complete workflow as the optimization unit, rather than a single response or policy trajectory. It represents workflows through four first-class objects: logical agent roles, graph trajectories, user-defined rewards, and agent--model mappings. This decouples logical agents from physical model parameters, supporting full sharing, full separation, and partial sharing, with rewards assigned at role, turn, and trajectory levels. UnityMAS-O extends verl with a Ray-based star-topology runtime. A central controller executes workflows, invokes tools, records structured trajectories, and assembles rewards; model-local worker groups handle rollout, buffering, advantage computation, and distributed PPO-style updates. Users can define agents, workflows, model mappings, and rewards without rewriting the optimization infrastructure. We instantiate UnityMAS-O on retrieval-augmented QA, iterative agentic search, and reflective code generation. Across Natural Questions, HotpotQA, and held-out code tasks, multi-agent RL improves manually specified workflows after optimization, with especially large gains for smaller models and strict code all-passed metrics. These results show that UnityMAS-O can serve as a reusable substrate for converting diverse LLM-based multi-agent workflows into trainable multi-agent RL systems.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。