Abstract
Prompting approaches have been recently explored in text style transfer, where a textual prompt is used to query a pretrained language model to generate style-transferred texts word by word in an autoregressive manner. However, such a generation process is less controllable and early prediction errors may affect future word predictions. In this paper, we present a prompt-based editing approach for text style transfer. Specifically, we prompt a pretrained language model for style classification and use the classification probability to compute a style score. Then, we perform discrete search with word-level editing to maximize a comprehensive scoring function for the style-transfer task. In this way, we transform a prompt-based generation problem into a classification one, which is a training-free process and more controllable than the autoregressive generation of sentences. In our experiments, we performed both automatic and human evaluation on three style-transfer benchmark datasets, and show that our approach largely outperforms the state-of-the-art systems that have 20 times more parameters. Additional empirical analyses further demonstrate the effectiveness of our approach.
Abstract (translated)
Prompting approaches 在文本风格转移中得到了最近的研究,其中使用文本Prompt查询预训练语言模型,以逐字生成风格转移文本,这是一种自回归的生成过程。然而,这种生成过程控制性较少,早期预测错误可能会影响未来的单词预测。在本文中,我们提出了基于Prompt的编辑方法,具体来说,我们Prompt了预训练语言模型以风格分类,并使用分类概率计算风格得分。然后,我们使用词级编辑进行离散搜索,以最大化风格转移任务的全面得分函数。通过这种方式,我们将基于Prompt的生成问题转化为分类问题,这是一个无需训练的过程,比句子自回归生成过程更可控。在我们的实验中,我们对三个风格转移基准数据集进行了自动和人类评估,并表明,我们的方法 largely outperforms 20倍参数更多的先进系统。此外,额外的经验证分析进一步证明了我们方法的有效性。
URL
https://arxiv.org/abs/2301.11997