Latent Undertow: How Ordinary Typos Break Probes

Latent Undertow: How Ordinary Typos Break Probes

潜在的暗流:普通拼写错误如何破坏探测器

LLMs handle ordinary typing variation fluently: a typo or missing punctuation leaves both user intent and the model’s response substantively unchanged. Yet probes that detect malicious prompts by reading the model’s hidden states tell a different story: the same edit rotates the readout vector by 43—56° at the perturbed token, decaying below 15% within ~10 downstream tokens.

大语言模型(LLMs)能够流畅地处理日常输入中的拼写变化:一个拼写错误或缺失的标点符号,既不会改变用户的意图,也不会实质性地影响模型的回复。然而,那些通过读取模型隐藏状态来检测恶意提示词的探测器(Probes)却呈现出完全不同的情况:同样的编辑会在受干扰的 Token 处使读取向量(Readout vector)旋转 43 到 56 度,并在随后的约 10 个 Token 内衰减至 15% 以下。

Stacking ~3 common typos per message cuts a single-position prompt-injection probe’s TPR@FPR=1% by 12.0pp, a gap recalibration alone cannot close. Multi-position aggregation cures localized perturbations (<= 0.5 loss) but only attenuates distributed ones, where even attention- and max-based aggregators still drop ~3.8pp.

在每条消息中堆叠约 3 个常见的拼写错误,会使单位置提示词注入探测器的 TPR@FPR=1% 指标下降 12.0 个百分点,仅靠重新校准无法弥补这一差距。多位置聚合方法可以修复局部干扰(损失 <= 0.5),但只能缓解分布式干扰,即使是基于注意力机制(Attention-based)和最大值(Max-based)的聚合器,性能仍会下降约 3.8 个百分点。

For single-position probes, we introduce a KV-cache fork: a short fixed suffix appended after the user message lets the probe read a few tokens downstream of the perturbation, exploiting its rapid spatial decay. This closes 95% of the gap (-0.6pp residual) — an order of magnitude better than perturbation-augmented training (-3.7pp).

针对单位置探测器,我们引入了一种 KV 缓存分支(KV-cache fork):在用户消息后附加一个简短的固定后缀,让探测器能够读取干扰发生后下游的几个 Token,从而利用其快速的空间衰减特性。这种方法弥补了 95% 的性能差距(残差仅为 -0.6 个百分点),比干扰增强训练(-3.7 个百分点)的效果高出一个数量级。

The rotation-and-decay geometry replicates on Llama-3.1-8B, Qwen3-8B, and Gemma-4-E4B; probe evaluation is on Llama-3.1-8B.

这种旋转与衰减的几何特性在 Llama-3.1-8B、Qwen3-8B 和 Gemma-4-E4B 模型上均得到了验证;探测器的评估工作是在 Llama-3.1-8B 上进行的。