arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 2401.06712cs.CLcs.LG
收藏

使用风格表示的少样本机器生成文本检测

Few-Shot Detection of Machine-Generated Text using Style Representations

Lawrence Livermore National Laboratory(劳伦斯利弗莫尔国家实验室);Johns Hopkins University(约翰斯·霍普金斯大学);U.S. Department of Defense(美国国防部)

Rafael Rivera Soto, Kailin Koch, Aleem Khan, Barry Chen, Marcus Bishop, Nicholas Andrews

AI总结:

本文提出利用人类文本中的写作风格表示进行少样本机器生成文本检测,无需训练目标模型样本,即可识别人机文本并预测具体生成模型。

摘要:

指令微调语言模型能够以令人信服的方式模仿人类写作,其出现带来了显著的滥用风险。然而,如果能够检测一段文本是由语言模型而非人类作者撰写的,就可以对抗这种滥用。以往解决该问题的一些方法依赖监督方法,即在经确认的人类与机器撰写文档语料库上进行训练。遗憾的是,模型欠规格化给基于神经网络的检测器带来了不可避免的挑战,使其在面对数据漂移时十分脆弱,例如更新的语言模型发布后,其生成的文本比用于训练检测器的模型所产生的文本更加流畅。另一些方法则要求访问可能生成待检测文档的模型,而这通常并不现实。鉴于这些挑战,我们采用一种根本不同的方法,在训练时不依赖所关注语言模型的样本。相反,我们建议利用从人类撰写文本中估计出的写作风格表示。事实上,我们发现,能够有效区分不同人类作者的特征,也能有效区分人类作者与机器作者,包括 Llama-2、ChatGPT 和 GPT-4 等最先进的大型语言模型。此外,在给定若干感兴趣的特定语言模型各自撰写的少量示例时,我们的方法还能够预测给定文档是由哪个模型生成的。复现我们实验所需的代码和数据可在 https://github.com/LLNL/LUAR/tree/main/fewshot_iclr2024 获取。

英文摘要:

The advent of instruction-tuned language models that convincingly mimic human writing poses a significant risk of abuse. However, such abuse may be counteracted with the ability to detect whether a piece of text was composed by a language model rather than a human author. Some previous approaches to this problem have relied on supervised methods by training on corpora of confirmed human- and machine- written documents. Unfortunately, model under-specification poses an unavoidable challenge for neural network-based detectors, making them brittle in the face of data shifts, such as the release of newer language models producing still more fluent text than the models used to train the detectors. Other approaches require access to the models that may have generated a document in question, which is often impractical. In light of these challenges, we pursue a fundamentally different approach not relying on samples from language models of concern at training time. Instead, we propose to leverage representations of writing style estimated from human-authored text. Indeed, we find that features effective at distinguishing among human authors are also effective at distinguishing human from machine authors, including state-of-the-art large language models like Llama-2, ChatGPT, and GPT-4. Furthermore, given a handful of examples composed by each of several specific language models of interest, our approach affords the ability to predict which model generated a given document. The code and data to reproduce our experiments are available at https://github.com/LLNL/LUAR/tree/main/fewshot_iclr2024.

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

↑