arXiv cs.AI· Shuyang Xiang·· 4 小时前AI 评分38
Transformer 的条件无毛定理:语言模型如何遗忘提示词
A Conditional No-Hair Theorem for Transformers: How Language Models Forget Their Prompt
AI 导读
研究者提出 Transformer 的“条件无毛定理”:两个提示词接同一续写时,隐藏状态差异约按 t^-α 幂律衰减,α=1 对应固定提示词在均匀注意力中的份额收缩速度。
正文 · 原文
Abstract:A black hole retains only a few conserved charges of the matter it formed from. We are inspired to make the analogy and we ask how much an autoregressive transformer retains of its prompt after generating $t$ tokens. For two prompts followed by the same continuation, the difference of their hidden states decays approximately as a power law $t^{-\alpha}$, where $\alpha=1$ is the rate at which a fixed prompt's share of uniform attention shrinks. Beyond the first layers, trained models forget faster ($\alpha\approx0.55$--$0.7$) than untrained ones of the same architecture ($\alpha\approx0.2$--$0.5$). For finite-depth pre-LN softmax transformers with bounded attention logits and non-degenerate pre-norm activations, we prove that this offset is $O\big(P(\log t)^{L-1}/t\big)$ for prompt length $P$ and depth $L$: the prompt's direct influence is diluted as the context grows, and \emph{relay} through continuation tokens adds only logarithmic factors. Conditional on the generated text, the prompt's influence on the next token thus vanishes. The bound fixes only the asymptotic shape and is uninformative at the lengths we measure in trained networks; an exactly solvable linear relay model shows that it cannot be improved and accounts for the untrained curves. Cancelling the dilution with a logit bias on the prompt stops the decay early in training, and training suppresses relay by about one billion tokens, before attention sinks form. A toolkit that measures $\alpha$ for any Hugging Face causal language model is publicly available.
| Subjects: | Artificial Intelligence (cs.AI) |
| Cite as: | arXiv:2610.24133 [cs.AI] |
| (or arXiv:2610.24133v2 [cs.AI] for this version) | |
| https://doi.org/10.48550/arXiv.2610.24133 arXiv-issued DOI via DataCite |
Submission history
From: Shuyang Xiang [view email]
[v1]
Fri, 16 Oct 2026 19:03:20 UTC (104 KB)
[v2]
Tue, 17 Nov 2026 10:37:12 UTC (105 KB)
来源:arXiv cs.AI · arxiv.org