Manuscript Offprint

arXiv:2609.06708

A Trustworthy Watermarking Framework for LLM-Generated Food Safety Content

Zhongli Fang, Yiran Chen, Lingyun Zhang, Yu Liu, Ping Chen, Xiaoyan Sun, Jun Dai

Zhongli Fang1,2^{1,2}, Yiran Chen1,2^{1,2}, Lingyun Zhang1,2^{1,2}, Yu Liu1,2^{1,2}, Ping Chen2∗^{2*}, Xiaoyan Sun3∗^{3*} and Jun Dai3∗^{3*}

1^{1}School of Computer Science and Technology, Fudan University, China

2^{2}Institute of Big Data, Fudan University, China

3^{3} Worcester Polytechnic Institute

Abstract—Large language models are transforming many industries with their text generation abilities. However, their outputs can be easily tampered with, creating serious risks in critical areas such as food safety reporting. To protect the integrity and traceability of AI-generated content, this paper introduces ToSS (Token Oriented Repartitioning and Strategic Selection), a reliable authentication method using adaptive dual watermarking. The key innovation of ToSS is its dual watermark encoding approach that divides vocabulary tokens into black and white sublists, enabling precise bit-level embedding of traceability information. Additionally, an entropy adaptive mechanism dynamically selects text regions with high prediction uncertainty for watermark insertion, maintaining text fluency and factual accuracy while ensuring reliable traceability. Experiments on multiple datasets, including food domain texts, demonstrate that ToSS achieves leading performance in both watermark capacity and decoding accuracy.

Index Terms—Large Language Models, Text Watermarking, Food Content Safety

I. INTRODUCTION

With the rapid development of artificial intelligence, various industries are accelerating their transition towards intelligentization [1]. The rise of generative models, particularly large language models (LLMs) [2], has significantly advanced technologies in speech, image, and text generation, profoundly changing people's lives and work patterns. However, the swift pace of technological advancement has also introduced significant regulatory and security challenges. In recent years, the misuse of generative models to create fake news, celebrity images, and tamper with critical documents has become increasingly prominent. Especially in the food sector, LLMs could be maliciously used to forge food safety inspection reports, alter nutritional composition tables, generate false traceability information, or even fabricate misleading nutritional advice or fake health certifications, posing serious threats to public health and market order. Therefore, there is an urgent need for effective content authentication mechanisms to prevent such misuse. Watermarking technology, as a viable solution, can embed traceable identifiers into generated content. By detecting the presence of a watermark (zero-bit watermarking) or extracting embedded specific information (multi-bit watermarking), it enables authentication of content origin and user identity tracing, thereby ensuring content authenticity and trustworthiness.

Figure

Fig. 1. Illustration of watermark extraction in the ToSS framework. The first-stage watermark verifies existence using red and green token lists, while the second-stage watermark encodes multi-bit traceability information through black (orange) and white (blue) token lists. The extracted bit sequence is compared with the stored reference to determine whether the text is authentic or tampered.

Current works, such as the zero-bit watermarking scheme by Kirchenbauer et al. [3], have made significant progress in proving the existence of generated text, while Qu et al. [4] have explored the embedding of multi-bit information. However, these existing approaches generally struggle to achieve stable embedding and reliable extraction of long-bit information within limited text lengths while preserving text quality. Particularly in practical application scenarios like food reports and nutritional guidance, there is often a need to embed complete traceability information, certification numbers, or timestamps as long-bit data within a single paragraph or short statement [5]. The performance of existing technologies in such short texts remains insufficient. Consequently, there is still a lack of watermarking techniques capable of effectively storing long-bit information within a single paragraph, which limits their practical application in fine-grained authentication scenarios.

In contrast, this paper proposes an adaptive dual-watermarking framework named Token-Oriented Repartitioning and Strategic Selection (ToSS) for authenticating content

∗^{*}Corresponding authors: Ping Chen (pchen@fudan.edu.cn), Xiaoyan Sun (xsun7@wpi.edu) and Jun Dai (jdai@wpi.edu)

Figure

Fig. 2. Overview of the ToSS framework. Given an input prompt, the language model generates text while the entropy-based filtering module identifies high-entropy and low-entropy regions. Multi-bit watermark information is embedded only in high-entropy regions via dynamic black-white list selection, while low-entropy regions are preserved to maintain textual fluency and factual accuracy.

generated by large models, as illustrated in Fig. 1. In the dual-watermark design, the first-stage watermark partitions the vocabulary into a green list and a red list, and biases generation toward green-list tokens to enable zero-bit watermark existence verification. The second-stage watermark further divides the green list into a white list (blue tokens) and a black list (orange tokens), embedding multi-bit traceability information through forced sampling according to the target bit sequence. In addition, ToSS incorporates an entropy-adaptive mechanism: watermark embedding is strengthened in high-entropy regions, while only a light green-list bias is applied in low-entropy regions to preserve textual fluency.

During verification, the system first performs zero-bit detection and then reconstructs the multi-bit sequence using the black/white list assignments, comparing it against the stored reference to determine whether the text has been tampered with. Experimental results show that ToSS can robustly embed and extract watermarks of up to 64 bits in short-text scenarios such as food safety reports and nutritional guidance, and significantly outperforms existing methods in text fluency and factual consistency.

In summary, the main contributions of this paper are as follows:

  • The proposal of an adaptive dual-watermarking framework combines the existence verification capability of zero-bit watermarking with the information tracing ability of multi-bit watermarking, achieving efficient and fine-grained content authentication within a unified framework.
  • The design of a dynamic hard-coded list mechanism builds upon the green list, dynamically partitions black and white lists using pseudo-random hash functions, and employs a hard-selection rule to unambiguously map message bits to vocabulary choices, enhancing the reliability and stealth of information embedding.
  • The introduction of an entropy-adaptive embedding strategy allows intelligent selection of embedding opportunities based on the predictive entropy of the language

model, enforcing strong embedding in high entropy regions to ensure capacity while prioritizing text quality protection in low-entropy regions, thus achieving an optimal balance between watermark strength and text fluency.

  • The achievement of efficient long bit information embedding and extraction in short texts enables stable embedding of up to 64 bits of traceability information within paragraph-level short texts, addressing the limitation of insufficient embedding capacity in constrained paragraphs in existing technologies and providing a feasible authentication solution for practical scenarios such as food reports.

References (23)

  • High-resolution image synthesis with latent diffusion models
  • A comprehensive overview of large language models
  • A watermark for large language models
  • Provably robust multi-bit watermarking for ai-generated text
  • Survey of hallucination in natural language generation
  • Natural language watermarking and tamperproofing
  • The hiding virtue of ambiguity: quantifiably resilient watermarking of natural language text through synonym substitutions
  • Adversarial watermarking transformer: Towards tracing text provenance with data hiding
  • Protecting intellectual property of language generation apis with lexical watermark
  • Cater: Intellectual property protection on text generation apis via conditional watermarks
  • Three bricks to consolidate watermarks for large language models
  • Advancing beyond identification: Multi-bit watermark for large language models
  • Towards codable watermarking for injecting multi-bits information to llms (opens arXiv in a new tab)
  • Watermarking language models for many adaptive users
  • Paraphrasing evades detectors of ai-generated text, but retrieval is an effective defense
  • Exploring the limits of transfer learning with a unified text-to-text transformer
  • Essays with instructions
  • Pointer Sentinel Mixture Models
  • Ivypanda essays
  • All-recipes dataset
  • Provable robust watermarking for ai-generated text (opens arXiv in a new tab)
  • Qlora: Efficient finetuning of quantized llms
  • The falcon series of open language models (opens arXiv in a new tab)