arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2610.22294cs.CL
收藏

基于扩散语言模型的多目标少样本提示

Multi-Target Few-Shot Prompting with Diffusion Language Models

University of Texas at Austin(德克萨斯大学奥斯汀分校)

Anton Xue, Alan Li, Rahul Saha

AI总结:

该研究针对少样本提示中因果自回归模型生成效果不佳的问题,提出基于扩散语言模型的多目标少样本提示方法,通过示例引导填充共享画布的多个掩码区域,结合似然比奖励提升填充准确率,在基准测试和软件重构中验证了方法的有效性。

摘要:

少样本提示在难以指定指令和奖励时十分有用,其应用之一是示例编辑,即需将演示的格式更改或API迁移应用于多个位置。但此类编辑常依赖左右上下文,导致因果自回归模型的生成效果不佳。为此,我们提出基于扩散语言模型的多目标少样本提示,通过示例引导填充共享画布内的多个掩码区域。为解决少样本提示中可靠遵循演示的挑战,我们进一步利用画布的选择性掩码推导似然比奖励,以支持示例引导的填充。在少样本提示基准测试和软件重构案例研究中,我们发现演示可提升填充准确率,在多种设置下示例引导还能带来进一步增益。

英文摘要:

Few-shot prompting is useful when instructions and rewards are hard to specify. One such application is editing by example, where a demonstrated formatting change or API migration may need to be applied across multiple sites. However, such edits often depend on both left and right context, making generation with causal autoregressive models awkward. We therefore introduce multi-target few-shot prompting with diffusion language models, where examples guide the infilling of multiple masked regions within a shared canvas. To address the known challenge of reliably following demonstrations in few-shot prompting, we further leverage selective masking of the canvas to derive a likelihood-ratio reward that favors example-supported infills. Across few-shot prompting benchmarks and software refactoring case studies, we find that demonstrations improve infilling accuracy, with example guidance yielding further gains in several settings.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑