arXiv:2509.11361cs.AI2025-09被引 6

多智能体协作优化提示词,提升大模型任务表现与效率

MAPGD: Multi-Agent Prompt Gradient Descent for Collaborative Prompt Optimization

  • 多个专用智能体分别优化提示的不同维度,协同完成优化
  • 在分类和推理任务上,准确率和效率均优于单智能体方法
  • 支持可解释性优化,适合需要稳定高效提示工程的场景

提示工程对充分发挥大语言模型能力至关重要,但现有优化方法多沿单一路径,存在适应性差、梯度冲突和计算开销高的问题。本文提出MAPGD(多智能体提示梯度下降)框架,将提示优化重构为专业化智能体间的协作过程。每个智能体专注指令清晰度、示例选择、格式结构或风格适配等不同优化维度,通过语义梯度嵌入、冲突检测与融合机制实现协同。为增强鲁棒性与稳定性,引入两项新机制:超球面约束梯度聚类(HCGC),通过角度边界约束实现紧凑且分离良好的聚类;通道自适应智能体重赋权(CAAW),根据验证性能动态调整各智能体贡献权重。在分类与推理基准上的实验表明,MAPGD在准确率与效率上持续优于单智能体及随机基线。消融实验证实了梯度融合、智能体专精与冲突解决的有效性。整体构建了一个统一、基于梯度、可解释且具备理论收敛保证的鲁棒提示优化框架。

原文摘要 · Abstract (English)

Prompt engineering is crucial for fully leveraging large language models (LLMs), yet most existing optimization methods follow a single trajectory, resulting in limited adaptability, gradient conflicts, and high computational overhead. We propose MAPGD (Multi-Agent Prompt Gradient Descent), a novel framework that reconceptualizes prompt optimization as a collaborative process among specialized agents. Each agent focuses on a distinct refinement dimension, such as instruction clarity, example selection, format structure, or stylistic adaptation, and their contributions are coordinated through semantic gradient embedding, conflict detection, and fusion. To further enhance robustness and stability, MAPGD introduces two new mechanisms: Hypersphere Constrained Gradient Clustering (HCGC), which enforces angular margin constraints for compact and well-separated clusters, and Channel Adaptive Agent Weighting (CAAW), which dynamically reweights agent contributions based on validation performance. Experiments on classification and reasoning benchmarks show that MAPGD consistently surpasses single-agent and random baselines in both accuracy and efficiency. Ablation studies confirm the effectiveness of gradient fusion, agent specialization, and conflict resolution. Together, these components establish MAPGD as a unified, gradient-based, and interpretable framework for robust prompt optimization with theoretical convergence guarantees.

提示工程多智能体大模型优化

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