arXiv:2505.14412cs.AIcs.CL2025-05被引 11

用强化学习自动生成高效提示,提升大模型表现。

PRL: Prompts from Reinforcement Learning

  • 基于强化学习自动优化提示,可生成训练中未见的新示例。
  • 在分类、摘要和简化任务上均超越现有方法,最高提升6.93分。
  • 适合需要高效提示工程的AI研究者与应用开发者。

有效提示工程仍是充分释放大语言模型能力的核心挑战。尽管精心设计的提示能显著提升性能,但其构造通常依赖专家直觉和对任务的深入理解。此外,最具影响力的提示往往依赖人类难以察觉的细微语义线索,却对引导模型行为至关重要。本文提出PRL(Prompts from Reinforcement Learning),一种基于强化学习的自动提示生成新方法。与以往方法不同,PRL能够生成训练过程中未见过的少样本示例。该方法在多个基准测试中达到顶尖水平,包括文本分类、简化与摘要任务。在分类任务中,相比APE提升2.58%,相比EvoPrompt提升1.00%;摘要任务上,平均ROUGE分数相比APE提升4.32,相比EvoPrompt提升2.12;简化任务中SARI得分相比APE提升6.93,相比EvoPrompt提升6.01。代码已公开于https://github.com/Batorskq/prl。

原文摘要 · Abstract (English)

Effective prompt engineering remains a central challenge in fully harnessing the capabilities of LLMs. While well-designed prompts can dramatically enhance performance, crafting them typically demands expert intuition and a nuanced understanding of the task. Moreover, the most impactful prompts often hinge on subtle semantic cues, ones that may elude human perception but are crucial for guiding LLM behavior. In this paper, we introduce PRL (Prompts from Reinforcement Learning), a novel RL-based approach for automatic prompt generation. Unlike previous methods, PRL can produce novel few-shot examples that were not seen during training. Our approach achieves state-of-the-art performance across a range of benchmarks, including text classification, simplification, and summarization. On the classification task, it surpasses prior methods by 2.58% over APE and 1.00% over EvoPrompt. Additionally, it improves the average ROUGE scores on the summarization task by 4.32 over APE and by 2.12 over EvoPrompt and the SARI score on simplification by 6.93 over APE and by 6.01 over EvoPrompt. Our code is available at https://github.com/Batorskq/prl .

提示工程强化学习大模型自动优化

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