基于分数的渐进式编辑器用于黑盒语言模型的受控文本生成
Controlled Text Generation for Black-box Language Models via Score-based Progressive Editor
AI总结:
本文提出ScoPE方法,通过在黑盒语言模型生成过程中以词元级别渐进修改上下文并最大化目标分数,在保持流畅性的同时实现有效的受控文本生成。
摘要:
受控文本生成对于语言模型的实际应用非常重要,因为它确保生成的文本仅包含来自特定领域或数据集的期望属性。然而,现有方法要么不适用于黑盒模型,要么在控制生成文本与保持其流畅性之间存在显著的权衡。本文提出了基于分数的渐进式编辑器(ScoPE),这是一种旨在克服这些问题的新方法。ScoPE在骨干语言模型的生成过程中以词元级别修改上下文。这种修改引导后续文本自然地包含目标属性。为了促进这一过程,ScoPE采用了一种最大化目标分数的训练目标,充分兼顾了引导文本的能力和文本的流畅性。在多种受控生成任务上的实验结果表明,ScoPE能够有效调节生成文本的属性,同时充分利用骨干大语言模型的能力。我们的代码可在\url{https://github.com/ysw1021/ScoPE}获取。
英文摘要:
Controlled text generation is very important for the practical use of language models because it ensures that the produced text includes only the desired attributes from a specific domain or dataset. Existing methods, however, are inapplicable to black-box models or suffer a significant trade-off between controlling the generated text and maintaining its fluency. This paper introduces the Score-based Progressive Editor (ScoPE), a novel approach designed to overcome these issues. ScoPE modifies the context at the token level during the generation process of a backbone language model. This modification guides the subsequent text to naturally include the target attributes. To facilitate this process, ScoPE employs a training objective that maximizes a target score, thoroughly considering both the ability to guide the text and its fluency. Experimental results on diverse controlled generation tasks demonstrate that ScoPE can effectively regulate the attributes of the generated text while fully utilizing the capability of the backbone large language models. Our codes are available at \url{https://github.com/ysw1021/ScoPE}.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。