让大模型提示词在分布变化下仍稳定有效,提升跨场景通用性。
DRO-InstructZero: Distributionally Robust Prompt Optimization for Large Language Models
- 用鲁棒贝叶斯优化构建提示词搜索,考虑最坏情况下的性能表现
- 在文本改写任务中准确率提升25-30个百分点,代码调试也增益约25点
- 无需修改模型即可通用适配,适合追求提示词可靠性的研究与应用
大语言模型对提示词极其敏感。现有自动提示搜索方法(如InstructZero)在分布偏移和对抗评估下表现下降,因其仅优化单一分布下的期望性能。为此,DRO-InstructZero将零样本提示优化建模为鲁棒贝叶斯优化:以f-散度球定义评估分布的模糊集,通过鲁棒采集规则最大化最差情况下的预期效用,同时保持贝叶斯搜索的查询效率。该方法明确追求分布转移下的可靠性,而非仅平均表现。实验遵循指令归纳协议,在正式化重写、代码调试和翻译任务中,使用相同查询预算。例如,在BIG-Bench信息到正式改写任务中,准确率从61.3 ± 0.7% 提升至约85%-90%,绝对提升约25-30个百分点;自动调试在领域偏移下提升约25点。而稳定任务如因果推理仍保持96%以上,说明无分布内性能损失。改进效果在不同散度选择和解码温度下均一致。总体而言,DRO-InstructZero将分布鲁棒优化与提示学习结合,提供一种即插即用、通用的可靠提示对齐方法,适用于真实世界中的不确定性场景。
原文摘要 · Abstract (English)
Large language models are highly sensitive to prompt wording. However, popular automatic prompt search methods, including InstructZero, often degrade under distribution shift and adversarial evaluation because they optimize expected performance under a single evaluation distribution. Consequently, prompts that work in one setting frequently fail to transfer. To address this, DRO-InstructZero formulates zero-shot prompt optimization as robust Bayesian optimization. Specifically, an f-divergence ball defines an ambiguity set around the evaluation distribution, and a robust acquisition rule maximizes worst-case expected utility while retaining the query efficiency of Bayesian search. Therefore, the search explicitly targets reliability under distribution shift rather than average behavior alone. Experiments follow the instruction-induction protocol with matched query budgets across formality rewriting, code debugging, and translation. For example, on BIG-Bench informative-to-formal rewriting, accuracy improves from 61.3 +/- 0.7% to approximately 85-90%, yielding an absolute gain of about 25-30 points. Moreover, auto-debugging shows about +25-point gains under domain shift. Meanwhile, stable tasks such as cause-and-effect remain above 96%, indicating no loss on in-distribution cases. Furthermore, improvements are consistent across divergence choices and decoding temperatures. Overall, DRO-InstructZero connects distributionally robust optimization with prompt learning, offering a plug-and-play and general approach for reliable, transferable prompt alignment under real-world uncertainty.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。