arXiv:2509.23387cs.CL2025-09NeurIPS被引 9

通过动态调整优化过程,让提示词生成更高效稳定。

No Loss, No Gain: Gated Refinement and Adaptive Compression for Prompt Optimization

  • 引入门控机制过滤无效更新,确保每次改进都有效
  • 在停滞时压缩提示核心,打破局部最优困局
  • 仅用1/4预算达到领先效果,适合资源有限场景

提示工程对发挥大语言模型潜力至关重要。尽管自动提示优化可替代昂贵的手动设计,但生成有效提示仍具挑战性,现有方法常因陷入局部最优而导致效率低下。为此,我们提出GRACE框架,融合门控精炼与自适应压缩两种协同策略,实现高效提示优化。门控精炼通过反馈调节门和更新拒绝门,对更新信号进行筛选,确保优化稳定有效;当优化停滞时,自适应压缩策略提炼提示核心概念,重构优化路径,开辟新方向。通过有策略地引入信息损失,GRACE显著提升性能与效率。在涵盖三个实际领域的11项任务上(包括BIG-Bench Hard、领域特定任务及通用NLP任务)的实验表明,其平均相对性能分别较当前最优方法提升4.7%、4.4%和2.7%。进一步分析显示,其仅需前序方法25%的提示生成预算即可达成同等效果,凸显高优化效率与低计算开销。代码已开源:https://github.com/Eric8932/GRACE。

原文摘要 · Abstract (English)

Prompt engineering is crucial for leveraging the full potential of large language models (LLMs). While automatic prompt optimization offers a scalable alternative to costly manual design, generating effective prompts remains challenging. Existing methods often struggle to stably generate improved prompts, leading to low efficiency, and overlook that prompt optimization easily gets trapped in local optima. Addressing this, we propose GRACE, a framework that integrates two synergistic strategies: Gated Refinement and Adaptive Compression, achieving Efficient prompt optimization. The gated refinement strategy introduces a feedback regulation gate and an update rejection gate, which refine update signals to produce stable and effective prompt improvements. When optimization stagnates, the adaptive compression strategy distills the prompt's core concepts, restructuring the optimization trace and opening new paths. By strategically introducing information loss through refinement and compression, GRACE delivers substantial gains in performance and efficiency. In extensive experiments on 11 tasks across three practical domains, including BIG-Bench Hard (BBH), domain-specific, and general NLP tasks, GRACE achieves significant average relative performance improvements of 4.7%, 4.4% and 2.7% over state-of-the-art methods, respectively. Further analysis shows that GRACE achieves these gains using only 25% of the prompt generation budget required by prior methods, highlighting its high optimization efficiency and low computational overhead. Our code is available at https://github.com/Eric8932/GRACE.

提示优化大模型高效算法

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