Profile

Settings

Loading…

← Papers

Help

FAQ

Which features require signing in?

You can read the commentary, paper info, Model Structure and related papers of public papers without signing in. Sign in to manage your account or contact us about your inquiries.

Can I upload a PDF file?

Upload papers with an arXiv or DOI link; the commentary is public to everyone. Papers whose source and terms of use can't be verified, so the commentary can't be made public, can't be uploaded. Uploading PDF files and keeping papers private are for subscribers only, and a paper uploaded as a file is saved as private only. Searching for official info by title runs only when you press the button.

Are the figures and AI commentary accurate?

Figures come only from the original paper, and only those whose terms of use are verified are shown. The commentary is written by AI and may be wrong. Check important claims, numbers and figure context against the evidence in the original paper.

I want to report a copyright issue.

Terms of use and the source of the original paper are on the Paper info tab. If there's a problem, choose "Paper content, figures and copyright" under Contact us and send the paper link, the part in question, and evidence that you hold the rights. Receiving your report doesn't confirm any rights or remove anything right away. You can see the result of the review under My inquiries.

I forgot my password.

If you signed up with email, use Forgot password in the sign-in window to reset it with your verified email. If you signed up with Google, Naver or Kakao, change your password with that service.

What should I include in an inquiry?

Tell us which screen you were on and what you were doing when the problem happened, along with the paper link. Don't include personal information such as passwords, API keys, verification codes or phone numbers. Inquiries and replies are stored in Refivu and you can see them under My inquiries.

How do I delete my account?

In Settings, under My account, press Delete account. Review what will be deleted and complete identity verification to delete your account. For other requests, choose "Account" under Contact us.

Paper commentary

Detection Is Not Early Warning: Evaluating Token-Level Alarms on Language Model Failures

Token-level alarms should be scored by how early they fire before failures

  • Problem Response-level metrics like AUROC cannot tell whether a monitor warns before a failure or only flags it after it has started. Those metrics count every token after the onset as positive, so they reward late detection.
  • Method PREWARN is an evaluation protocol for any failure with an annotated onset. It sets each monitor's threshold on validation data to a chosen error rate, then scores its alarms against the onset.
  • Results Probes warn early on two of three models, while AUROC ranks them as equal.

Figure 1: Overview of PREWARN. Left: a monitor runs a scorer over the generated tokens and alarms
where the score crosses τ (dots mark flagged tokens, the flag…

Figure 1 : Overview of PREWARN. Left: a monitor runs a scorer over the generated tokens and alarms where the score crosses τ (dots mark flagged tokens, the flag the first alarm); AUROC rates three such monitors as equal although their first alarms fall well before, just before and after the onset o(r). Right: what PREWARNneeds and its three steps: calibrate the threshold on validation to the budget β, run the monitor on the test split, and score the alarms against the onset on the three tasks.

Original paper · CC BY 4.0 · Marco De Negri, Luca Sartori, Lorenzo Baggi, Moritz Reihs, Eduard Frank Ďurech, Mennatallah El-Assady, Valentina Pyatkin, Anna Hedström · Detection Is Not Early Warning: Evaluating Token-Level Alarms on Language Model Failures · Original paper figure · Extracted the figure area from page 2 of the original PDF.

Why alarm timing is missing from monitor scores

Many language model failures start at one specific token, which the paper calls the onset.

These metrics count every unit after the onset as a positive, so they reward flagging the failure rather than flagging it early.

Timing evaluations usually miss one of two ingredients: an annotated onset, so alarms can be split before and after it, or a threshold fixed at the deployment error rate. Duan et al. credit only alarms raised before repetition starts, but they tune their threshold for detection.

The authors propose PREWARN, which fixes each monitor's threshold on validation data at a chosen error rate. For repetitive degeneration, PREWARN fixes the share of healthy responses that raise an alarm, which is the false-alarm budget.

The PREWARN protocol and its three steps

PREWARN fixes each monitor's threshold on validation data at an error rate chosen for the application, then scores the alarms against the onset. The authors apply it to any failure with an annotated onset, and the failure is first defined as a response that fails, with the onset as its first token. A scorer gives each position t a score s_t in [0,1], using only information available when that token is generated.

A monitor with threshold τ flags a position once its score reaches τ, and the first alarm of a response is its first flagged position. Its first alarm is set to infinity when no position is flagged, so a response without alarms never counts as early.

Step 1 sets τ to the lowest value at which the false-alarm rate on validation stays within β, because the authors choose the false-alarm budget for repetitive degeneration. Equation (1) defines τ*(β) as the minimum τ for which the count of healthy responses with a first alarm stays at or below β times the number of healthy validation responses.

Step 2 runs the scorer with τ over every test response, which yields the flags and the first alarm of each response.

Step 3 scores the alarms against the onset, with response classification measured by AUROC and the best accuracy of the maximum token score. Early warning uses warning coverage over a window of W = 256 positions, the early-warning rate and the lead. Early and Lead are computed over the alarmed responses only, so they must be read together with the detection rate.

Warning coverage rises when a scorer flags more tokens everywhere, so the authors pair it with pre-window coverage and compare the early-warning rate against random alarms.

The false-alarm rate is reported as a check, showing whether the threshold fixed on validation carries over to the test split. The probes that PREWARN scores are trained with a target positive from K = 256 tokens before the onset, which asks them to fire before the failure is visible.

Probes and baselines as scorers

The probe reads the residual stream at layer ℓ, applies the layer norm, and passes a linear score through a sigmoid. \[ s_t=\sigma\big(w^\top \mathrm{LN}(h^{(\ell)}_t)+b\big) \] The frozen probe trains only the layer-norm affine parameters together with its weight and bias, and it reads the generator's own activations, so it adds no forward pass.

The adapted probe also trains rank-16 LoRA adapters on the attention and MLP projections of all layers up to the probe layer, which means a second forward pass through those layers.

Binary cross-entropy trains the probe on these labels. The layer and checkpoint are chosen by the highest validation Warn256 at β = 1%, among those whose post-onset coverage reaches at least 0.3, so a probe can't win on early flags alone. This rule picks layer 15 for the frozen probe on APERTUS and LLAMA and layer 5 on MISTRAL.

Six baselines have no learned weights, and they are grouped by what they read: the response length, the emitted tokens, or the generator's confidence. Their windows and n-gram sizes are tuned on validation with the same rule that selects the probes.

The authors sampled 10 responses for each of 3,630 prompts from seven sources, for each of three models: APERTUS-8B-INSTRUCT, LLAMA-3.1-8B-INSTRUCT and MISTRAL-7B-INSTRUCT. An LLM judge, CLAUDESONNET5, labels degenerate loops, and every capped test response was then checked by hand.

Why response-level scores can't rank early warning

The first comparison pits four scorers against each other on APERTUS at layer 15: the token-cap rule, the adapted probe, and two frozen probes with the highest and lowest validation AUROC. On response classification the four are indistinguishable, and the token-cap rule reaches the highest best accuracy. Detection rate is close to 1 for all four, so the differences only appear in the metrics that use the onset.

Keeping only the token with the highest score, which usually lies deep in the loop, removes almost every early warning yet leaves AUROC unchanged.

The validation ranking by warning coverage predicts the test ranking closely, with τ of 0.94.

Across layers, AUROC stays above 0.96 and best accuracy varies by less than 3%.

Probes warn early on two of three models

On APERTUS and LLAMA, the early-warning rate of both the frozen and the adapted probe is above one half, well above that of random alarms. Warning coverage runs 1.4 to 3 times pre-window coverage, which the authors read as a signal of the coming loop.

On MISTRAL the early-warning rate of every probe stays below one half, though it sits above the rate of random alarms. Here the median first alarm comes after the onset, so the probes fire late rather than early. Warning coverage is close to pre-window coverage, so the probes flag the warning window and earlier tokens at about the same share.

Their detection rate is still 0.99, so the probes detect the failure on MISTRAL without warning of it. Adaptation can't add information the response does not yet contain, so the authors suspect the coming loop's signal is weak or absent until the loop begins.

The threshold fixed on validation carries over to test at the 5% budget, giving every probe a false-alarm rate of 4.5% to 5.6%. On the held-out sources, the frozen probes of LLAMA and MISTRAL raise an alarm on almost every degenerate response. Their early-warning rate drops to 0.20 and 0.12 there, and their median first alarm comes after the onset.

What adapting the probe adds

Adapting the probe more than doubles warning coverage on every model, compared with the frozen probe at the same layer. Adaptation also raises post-onset coverage, but it barely raises the early-warning rate. The early-warning rate counts each response once, at its first alarm, so extra flags on a response that already warned don't raise it.

Pre-window coverage rises alongside warning coverage, so many of the added flags land long before the onset. Reading the adapted probe at its own layer gives the same picture. Since the probe stays linear, the authors trace these changes to the representation it reads.

On Apertus and Llama, the frozen probe flags more tokens as the onset approaches, and the adapted probes show the same rise.

Figure 4: On APERTUSand LLAMA, probes flag more tokens as the onset approaches, and adaptation
adds flags long before it; on MISTRAL, flags rise only after the…

Figure 4 : On APERTUSand LLAMA, probes flag more tokens as the onset approaches, and adaptation adds flags long before it; on MISTRAL, flags rise only after the onset. Top: share of flagged tokens on degenerate responses by distance from the onset (bins of 32 tokens; positions more than 1,024 tokens before the onset pooled on the left). Bottom: the same on healthy responses by position (bins of 128 tokens), where flags also rise with length; the strip below gives the number of responses still running, on a log scale. Panel titles give the layers of the three probes. β= 5%, human-verified in-domain test split; mean over three seeds with95%intervals from leaving out one prompt at a time.

Original paper · CC BY 4.0

Per the Figure 4 analysis, the flags on Mistral don't gain a trend toward the onset, so adaptation doesn't help early warning there.

Untrained baselines against the probes

Every scorer has a high AUROC, and the token-cap rule has the highest on LLAMA and MISTRAL. The token-cap rule still flags only the last token of a capped response, after the budget is spent. On APERTUS the adapted probe at layer 30 has a lower AUROC than both the token-cap rule and rep/ℓ.

The text baselines measure repetition in emitted tokens, which shows up only after the first cycle of the loop, and the confidence baselines rise only once tokens repeat the previous cycle. Both groups can detect the loop, but they can't warn of it.

The best untrained baseline on APERTUS, windowed seq-rep-n, reaches an early-warning rate of 0.296, compared to 0.246 for random alarms. No baseline warns much more often than random alarms.

Limits of the case study

The lead times depend on where the onset is placed, which is the first token of the first loop.

Prompts that ask for repetition, enumerations, brute-force search or code produce responses that the study labels healthy. The authors didn't test whether the probes can tell that kind of repetition apart from degeneration.

The training strategy and selection rule were chosen on degeneration alone, so another failure may need a different strategy. Other failures may also call for scorers beyond linear probes. On the held-out sources, the thresholds keep the false-alarm rate below 1%, while the in-domain test split sits at 4.5% to 5.6%. There, the frozen probes of LLAMA and MISTRAL warn less, with early-warning rates of 0.20 and 0.12.

Their median first alarm falls after the onset.

The degenerate labels came from an LLM judge, which quotes where each loop begins. The reviewers then checked every capped response of both test splits by hand.

Choosing between frozen and adapted probes

A deployer choosing a probe for repetitive degeneration has two options that differ only by the LoRA adapters. The frozen probe reads the generator's own activations, so it adds no extra forward pass. On APERTUS and LLAMA, the frozen probe already fires before the onset on most loops it flags.

Adaptation more than doubles warning coverage on every model, but it barely raises the early-warning rate.

On MISTRAL, neither probe warns before most loops, and the median alarm comes after the onset. The released probes come with thresholds at 1%, 5% and 10%, so they could trigger stopping, resampling or steering before the loop starts. The authors leave that intervention unexplored, and they don't test it.

Paper info

Authors
Marco De Negri, Luca Sartori, Lorenzo Baggi, Moritz Reihs, Eduard Frank Ďurech, Mennatallah El-Assady, Valentina Pyatkin, Anna Hedström
Venue
arXiv · Preprint
First published
2026-11-12
Added
2026-11-13
Updated
2026-11-12
Version
v1
arXiv
2611.16803
Category
cs.LG · cs.CL
Original paper terms
CC BY 4.0
What we show
Paper info, commentary and permitted figures from the original paper

AI commentary is a separate explanation from the original paper and may contain errors. The original paper and figures follow each source's terms of use and any rights noted separately.

Abstract

Many failures of language models begin at a specific token, the onset. A monitor that reads the model during generation can classify the finished response, detect the failure once it is under way, or warn before it begins, and only a warning leaves time to stop or steer the generation. Monitors are usually evaluated with response-level metrics such as AUROC, which ignore when the monitor fires. We introduce PREWARN, an evaluation protocol for any failure with an annotated onset. It calibrates each monitor's threshold on validation data to an error rate chosen for the application, runs the monitor, and scores its alarms relative to the onset on all three tasks. As a case study we apply it to repetitive degeneration in three open language models, with early warning as the main task, using linear probes on activations and six untrained baselines. Response-level metrics saturate on this failure, and a rule that reads only the response length scores almost perfectly, while probes that AUROC ranks as equal warn very differently under PREWARN. Probes warn before the onset on most degenerate responses of two of the three models, low-rank adapters below the probe more than double the share of tokens just before the onset that it flags, largely by flagging degenerate responses long before the onset, and no untrained baseline warns much more often than random alarms. We release the probes with calibrated thresholds at https://huggingface.co/collections/marcodene/prewarn-degeneration-probes

Quote from the paper

Marco De Negri, Luca Sartori, Lorenzo Baggi, Moritz Reihs, Eduard Frank Ďurech, Mennatallah El-Assady, Valentina Pyatkin, Anna Hedström (2026). Detection Is Not Early Warning: Evaluating Token-Level Alarms on Language Model Failures. arXiv:2611.16803v1. https://arxiv.org/abs/2611.16803v1

BibTeX
@misc{negri2026detection,
  title = {{Detection Is Not Early Warning: Evaluating Token-Level Alarms on Language Model Failures}},
  author = {Marco De Negri and Luca Sartori and Lorenzo Baggi and Moritz Reihs and Eduard Frank Ďurech and Mennatallah El-Assady and Valentina Pyatkin and Anna Hedström},
  year = {2026},
  eprint = {2611.16803},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2611.16803v1}
}

See related papersBrowse other papers

Paper preview
Account security

Connect Google account

If you connect a Google account, you can sign in with it too.

Refivu

Delete account

Refivu
Refivu

Sign up