🌢️ Math of LLMs: The Red–Green Method

Red, Green, or β€œChristmas”?

Before picking each word, a watermarked LLM hashes the previous word with a secret key K, splitting the dictionary into Green (Ξ³) and Red (1βˆ’Ξ³), then gently boosts Green words by +Ξ΄. Facts stay intact, synonyms drift Green, and counting Green hits separates watermarked AI from human text.

GREEN CHILE HITS (UNIQUE PAIRS) 31 / 60 (51.7%)Human β€œChristmas” baseline: 25% Green / 75% Red
z-SCORE & p-VALUE +4.77Οƒ p = 9.20 Γ— 10⁻⁷ (Exact Binomial: 8.38 Γ— 10⁻⁢)
VERDICT (THRESHOLD z β‰₯ 4.0) πŸ€– Watermarked AI Detected Reject Hβ‚€ (1 in 1,087,125 human false-positive chance)
Green (31) Red (29)
πŸ“ˆ Detection As You Go z(t) +4.77Οƒ
-20246 AI line (z = 4.0) Word 1Word 61 (60 scored)
z=31βˆ’(0.25)(60)60β‹…0.25β‹…0.75=+4.77z = \frac{31 - (0.25)(60)}{\sqrt{60\cdot0.25\cdot0.75}} = \mathbf{+4.77}
z = 4.0 Obs (+4.77) -4-20246
🌢️ Green Chile Heat δ+3.0
βš™οΈ More Controls (Hard Mode, Ξ³, Topic, Paraphrase Attack)
Topic:

πŸ“ How It Works in 3 Steps

1. HASH & SPLIT

Hash the previous word with secret key K to paint a fresh Green List (Ξ³) and Red List (1βˆ’Ξ³) at every step.

PRFK ⁣(s(tβˆ’1),v)β€…β€ŠβŸΆβ€…β€ŠGt (Ξ³)β€…β€ŠβŠ”β€…β€ŠRt (1βˆ’Ξ³)\mathrm{PRF}_K\!\left(s^{(t-1)}, v\right) \;\longrightarrow\; G_t\text{ (}\gamma\text{)} \;\sqcup\; R_t\text{ (}1-\gamma\text{)}
2. SOFT BOOST (+Ξ΄)

Add +Ξ΄ only to Green logits before Softmax. Factual words still win even if Red; creative synonyms shift Green.

β„“~k=β„“k+δ 1[k∈Gt]β€…β€ŠβŸΉβ€…β€ŠP~G=eΞ΄PGeΞ΄PG+1βˆ’PG\tilde{\ell}_k = \ell_k + \delta\,\mathbf{1}[k \in G_t] \;\Longrightarrow\; \tilde{P}_G = \frac{e^{\delta}P_G}{e^{\delta}P_G + 1 - P_G}
3. COUNT & z-TEST

The detector never needs the LLM weights β€” just key K. Count Green hits and test against Binomial(T, Ξ³).

z=∣s∣Gβˆ’Ξ³TT γ(1βˆ’Ξ³),p=1βˆ’Ξ¦(z)z = \frac{|s|_G - \gamma T}{\sqrt{T\,\gamma(1 - \gamma)}}, \qquad p = 1 - \Phi(z)
Why Soft (+δ) Beats Hard (δ = ∞):"The capital of France is ___"

Even though "Paris" hashed into the Red list, its raw logit (11.4) dwarfs every Green candidate. Soft watermarking (+Ξ΄) leaves "Paris" untouched, whereas a Hard Watermark forces a hallucination!

Paris R
100% β†’ 99%
Lyon G
0% β†’ 0%
Marseille G
0% β†’ 0%
Nice R
0% β†’ 0%
Bordeaux G
0% β†’ 0%

⚠️ Two Big Catches (What Actually Happens in Practice)

1. Only the Key Holder Can Detect (Why ChatGPT/Gemini Score ~0Οƒ)

Red–Green is a cooperative cryptographic watermark, not a universal AI detector. Only an LLM that actively biased its logits with key K can be caught by key K. Publishing K lets anyone scrub the watermark or spoof innocent humans β€” while zero-key classifiers (GPTZero / Pangram) work on any model but cannot mathematically bound false accusations.

2. Repeating One Word ("ai ai ai...") Breaks Coin-Flip Independence

The Binomial z-test assumes each scored word is an independent draw. If a single pair like ("ai", "ai") happens to hash Green (25% chance), typing it 15 times inflates z past +4.6Οƒ! Real detectors (Kirchenbauer Β§6 & DeepMind's SynthID) fix this by scoring each unique word-pair at most once (Dedupe: ON).

πŸ›οΈ Real CS Conference Busts (2024–2026) & Who Holds the Key?

ICML 2026 β€’ SECRET CANARY TRAP (p < 10⁻¹⁰)

497 Papers Desk-Rejected via Invisible Prompt

Organizers hid 2 unique secret phrases (from 170,000) inside confidential PDFs. 506 reviewers pasted PDFs into LLMs β†’ 795 AI reviews deleted and 497 linked papers desk-rejected. Like Red–Green, a secret signal upfront makes accidental matches < 1 in 10 billion.

NEURIPS 2026 POSITION TRACK β€’ ZERO-KEY BACKLASH

18.4% Auto-Rejected β€” Then Flagged the Chairs' Own Papers

Commercial zero-key detector Pangram auto-rejected 178 / 969 papers without appeal β€” until researchers ran the track chairs' own human papers through it and got 24%–69% AI flags. Without a secret key K, formal and ESL prose triggers false positives.

NEURIPS 2025 β€’ FACT CHECK (~0% FP)

100+ Fake Citations in 51 Accepted Papers

A GPTZero DOI audit of all 4,841 accepted papers caught 100+ hallucinated references (even "John Doe and Jane Smith"), pushing arXiv toward 1-year bans β€” zero false positives, but only catches sloppy unverified errors.

ICLR 2024–2026 β€’ CORPUS WORD SPIKES

"Commendable, Meticulous, Intricate" (6.5%–21% Reviews)

Stanford (Liang, Zou et al.) avoided risky individual accusations and measured corpus-wide word shifts (6.5%–16.9% LLM-modified reviews); an ICLR 2026 census put full-AI reviews near ~21%.

ParadigmWho Detects?Any LLM?False-Positive Risk
Red–Green / SynthID (Symmetric)Key holder K onlyNo (opt-in)Provably < 10⁻⁹
Public-Key Watermark (Fairoze et al.)Anyone (pk)No (opt-in)Cryptographic (needs long text)
Active Canary Trap (ICML 2026)Trap planterYesProvably < 10⁻¹⁰
Zero-Key Classifier (GPTZero / Pangram)AnyoneYesUnbounded (flags chairs / ESL)