CSE 598 Research Project · Winter 2025

Sequential Testing for
Language Model Watermarks

Adaptive watermark detection through testing by betting

Devashish JuyalEmilio Cantu-CerviniZicheng JinSri Likhita Adru

University of Michigan

Abstract

Language model watermarks embed a statistical signal in generated text. Detecting that signal typically requires repeated comparisons against randomized alternatives. This project studies a sequential Monte Carlo approach that evaluates evidence as it accumulates, allowing detection to stop early for rejection or futility. We examine detection power, false-positive rates, and resampling cost, including under text edits.

An interactive explanation

When can a detector stop?

A fixed-budget test uses a predetermined number of comparisons. A sequential test checks the evidence after each one.

Choose a scenario, advance the comparisons, or inspect a point along the trace to see the idea in action.

This teaching simulation uses synthetic scores. It is not the research detector or a measure of detection accuracy.

Sequential testing, illustrated

Teaching simulation
Comparisons0 / 80
Illustration statusReady to explore
Synthetic evidence over comparisons Illustrative score, not a p-value. Use Run simulation or Next comparison to explore. Illustrative threshold 7 0 −7 0 40 80
Synthetic evidenceNumber of comparisons

A clear signal can reach the threshold with fewer comparisons.

What does this illustrate?

A seeded random walk adds +1 or −1 per comparison and stops at +7 or 80 comparisons. It is not the research detector, a p-value, or experimental data. Chance-like paths can also cross this illustrative threshold; no error guarantee applies to this animation.

Inside the
original experiment
Language model
OPT-1.3B
Text source
C4
Generated length
80 tokens
Significance level
α = 0.05
Betting parameter
c = 0.04

Method overview

A secret key guides word sampling. Detection asks whether the text aligns with that key more closely than it would with random alternatives.

01

Generate with a key

Watermarking changes how tokens are sampled, leaving a statistical signal in the output.

02

Compare against chance

The detector compares the text’s alignment with the shared key against randomized keys.

03

Know when to stop

Sequential testing monitors evidence and may stop early for rejection or futility.

Keep the conclusion specific. No evidence for a watermark does not prove that a person wrote the text.

The original research

Experimental results

Detection quality is only half the story. Explore false positives, computational cost, and what happens when the text is edited.

Historical figure

Power & false positives

Open full size
Original research figure comparing detection power and null rejection rate across permutation budgets.
Report setup: OPT-1.3B, 200 texts, 80 generated tokens, α = 0.05 and c = 0.04. Original project figure; not a new reproduction.

These are preserved research figures. Raw per-trial runs are not included in the repository; resample counts alone do not establish a wall-clock speedup. Validation status

Behind the project

Contributors & resources

University of Michigan
CSE 598, Winter 2025

Devashish Juyal, Emilio Cantu-Cervini, Zicheng Jin, and Sri Likhita Adru.

Devashish contributed the literature survey, sequential testing framework, detection implementation, proposed power and null-rejection experiments, and analysis of statistical validity. The research and experimental work were collaborative.