通过动态修剪提示词控制大模型对话多样性,调节稳定与创新的平衡。
Exploring and Controlling Diversity in LLM-Agent Conversation
- 基于注意力分数动态删减提示内容,实现多样性可控
- 记忆模块对多样性影响最大,高注意力部分抑制多样性
- 仅需一个参数即可调节,兼容现有控制方法,适合模拟研究
在长时序的LLM-Agent对话模拟中,对话多样性易随时间下降。为探究提示设计的影响,我们拆解了生成提示的模块化结构,发现减少上下文信息可提升输出多样性。基于此,提出自适应提示修剪(APP)方法,通过单一参数lambda控制多样性:根据注意力得分动态移除低效提示片段,且兼容已有多样性调控手段。实验表明,该方法能有效调节多样性,并揭示所有提示组件均限制多样性,其中记忆模块影响最显著。此外,高注意力内容始终抑制多样性。
原文摘要 · Abstract (English)
Controlling diversity in LLM-agent simulations is essential for balancing stability in structured tasks with variability in open-ended interactions. However, we observe that dialogue diversity tends to degrade over long-term simulations. To explore the role of prompt design in this phenomenon, we modularized the utterance generation prompt and found that reducing contextual information leads to more diverse outputs. Based on this insight, we propose Adaptive Prompt Pruning (APP), a novel method that allows users to control diversity via a single parameter, lambda. APP dynamically prunes prompt segments based on attention scores and is compatible with existing diversity control methods. We demonstrate that APP effectively modulates diversity through extensive experiments and propose a method to balance the control trade-offs. Our analysis reveals that all prompt components impose constraints on diversity, with the Memory being the most influential. Additionally, high-attention contents consistently suppress output diversity.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。