_images/vLLM-WM-Logo.png

vLLM-Watermark

Tiny. Hackable. Lightning-fast watermarking for researchers built on vLLM

Getting started

Performance evaluation

Supported Algorithms

The following table summarizes the three main watermarking algorithms implemented in this package:

Algorithm

Description

Paper

Gumbel/OpenAI

Uses Gumbel-Max trick for deterministic sampling

Aaronson (2023)

KGW/Maryland

Green-red token partitioning with logit bias

Kirchenbauer et al. (2023)

PF (Permute-and-Flip)

Prefix-free coding with token permutations

Lean et al. (2024)

Note

Each algorithm has different trade-offs between detectability, robustness, and text quality. See individual algorithm pages for detailed theory and examples.

Quick start

  1. Install the package (see Installation Guide)

  2. Choose an algorithm from Watermarking Algorithms

  3. Run the example code to try it locally

For detailed API information, refer to the docstrings in the repository code.

Citation

If you use vLLM-Watermark in your research, please cite:

@software{vllm_watermark,
  title  = {vLLM-Watermark: A tiny, hackable research framework for
            LLM watermarking experiments},
  author = {Apurv Verma},
  year   = {2025},
  url    = {https://github.com/dapurv5/vLLM-Watermark}
}