为低熵文本生成设计无失真水印,提升可信度与安全性
HeavyWater and SimplexWater: Distortion-Free LLM Watermarks for Low-Entropy Next-Token Predictions
- 基于优化框架,用随机侧信息增强水印可检测性
- 在代码生成等低熵场景下,检测准确率高且文本质量损失小
- 适用于任意大模型,支持灵活调节检测与失真平衡
大型语言模型(LLM)水印可用于验证文本来源、遏制机器生成文本滥用,并提升对AI系统的信任。现有水印方法通过修改LLM的下一个词预测结果来实现,其更新后的预测依赖于随机侧信息(如通过哈希已生成词生成)。在编码等低熵生成任务中,由于下一个词预测几乎确定,水印设计尤为困难。本文提出一种水印设计的优化框架,旨在理解如何最优利用随机侧信息以最大化水印检测概率并最小化文本失真。分析结果指导设计出两种新水印:HeavyWater与SimplexWater。二者均可调,能优雅权衡检测准确率与文本失真,适用于任意LLM且与侧信息生成方式无关。多个基准测试表明,它们在低熵场景下仍可实现高检测准确率且对生成质量影响极小。理论分析还揭示了LLM水印与编码理论间的意外联系。
原文摘要 · Abstract (English)
Large language model (LLM) watermarks enable authentication of text provenance, curb misuse of machine-generated text, and promote trust in AI systems. Current watermarks operate by changing the next-token predictions output by an LLM. The updated (i.e., watermarked) predictions depend on random side information produced, for example, by hashing previously generated tokens. LLM watermarking is particularly challenging in low-entropy generation tasks -- such as coding -- where next-token predictions are near-deterministic. In this paper, we propose an optimization framework for watermark design. Our goal is to understand how to most effectively use random side information in order to maximize the likelihood of watermark detection and minimize the distortion of generated text. Our analysis informs the design of two new watermarks: HeavyWater and SimplexWater. Both watermarks are tunable, gracefully trading-off between detection accuracy and text distortion. They can also be applied to any LLM and are agnostic to side information generation. We examine the performance of HeavyWater and SimplexWater through several benchmarks, demonstrating that they can achieve high watermark detection accuracy with minimal compromise of text generation quality, particularly in the low-entropy regime. Our theoretical analysis also reveals surprising new connections between LLM watermarking and coding theory. The code implementation can be found in https://github.com/DorTsur/HeavyWater_SimplexWater
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。