arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2408.04983cs.CL
收藏

谨慎地变得困惑:基于选择性熵最大化的文本序列记忆擦除

Get Confused Cautiously: Textual Sequence Memorization Erasure with Selective Entropy Maximization

Queen Mary University of London(伦敦玛丽女王大学)

Zhaohan Zhang, Ziquan Liu, Ioannis Patras

AI总结:

针对 LLM 逐字记忆训练文本的问题,本文提出 EMSO 框架,利用对比梯度度量选择性更新权重并最大化熵,从而在大规模遗忘请求下兼顾记忆擦除与模型能力。

摘要:

大型语言模型(LLM)已被发现会逐字记忆并背诵其训练集中的部分文本序列,这在使用 LLM 时引发了对隐私和版权问题的广泛担忧。这种文本序列记忆(TSM)现象使得对 LLM 输出进行监管、防止其生成某些被记忆文本以满足用户要求的需求十分迫切。然而,我们的实证研究表明,现有的 TSM 擦除方法无法在不显著损害模型效用的情况下遗忘大量被记忆样本。为了在 LLM 中更好地平衡 TSM 擦除的有效性与模型效用,本文提出了一种基于带选择性优化的熵最大化(EMSO)的新框架,其中更新的权重通过一种新颖的对比梯度度量来选择,无需任何额外模型或数据的参与。我们的分析表明,与现有方法相比,使用熵最大化损失进行训练具有更稳定的优化过程,并能更好地保持模型效用。对比梯度度量通过同时考虑梯度大小和方向,定位对 TSM 擦除最具影响力的权重。在三种模型规模上进行的大量实验表明,我们的方法在处理大规模遗忘请求的同时,能够保持模型在语言生成和推理方面的能力,表现优异。

英文摘要:

Large Language Models (LLMs) have been found to memorize and recite some of the textual sequences from their training set verbatim, raising broad concerns about privacy and copyright issues when using LLMs. This Textual Sequence Memorization (TSM) phenomenon leads to a high demand to regulate LLM output to prevent it from generating certain memorized text to meet user requirements. However, our empirical study reveals that existing methods for TSM erasure fail to forget massive memorized samples without substantially jeopardizing the model utility. To achieve a better trade-off between the effectiveness of TSM erasure and model utility in LLMs, our paper proposes a new framework based on Entropy Maximization with Selective Optimization (EMSO), where the updated weights are chosen with a novel contrastive gradient metric without any participation of additional model or data. Our analysis shows that training with the entropy maximization loss has a more stable optimization process and better keeps model utility than existing methods. The contrastive gradient metric localizes the most influential weight for TSM erasure by taking both the gradient magnitude and direction into consideration. Extensive experiments across three model scales demonstrate that our method excels in handling large-scale forgetting requests while preserving model ability in language generation and reasoning.

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

↑