How statement and proof provenance work
The first chip identifies the source of the statement or construction; the second identifies the source of its local proof or verification.
- Literature-sourced: the exact statement appears in a cited source; only wording and notation differ.
- AI-adapted: a semantically identical restatement of literature-sourced material, modulo indexing, notation, and boundary cases adopted by the library.
- AI-generated: a genuinely novel statement formulated by AI, with no source for the claim itself.
These labels describe origin, not correctness: citations and verification chips remain separate evidence.
A nonfinal token has inverse-length influence under bounded soft attention
Statement
Fix a finite token alphabet and a fixed soft-attention sequence model with layers, heads per layer, fixed query/key/value matrices, and positionwise maps that are globally Lipschitz. Assume the layer-zero input states use the additive convention , where is the embedding of token and is the position- embedding. Assume the token embeddings are bounded, the positional embeddings satisfy , and all model parameters are independent of the input length . For two length- inputs with the same end marker at position and differing in only one token at a position , there is a constant , depending only on these bounds, matrices, maps, , and , such that their final hidden states satisfy
If a fixed globally Lipschitz map followed by softmax converts the final hidden state to next-token probabilities, then another constant with the same allowed dependence satisfies . No bound is asserted when the changed symbol is the final end marker, or when the number of layers, matrices, or their norms vary with .
Statement references
Facts & Assumptions
Given: A fixed soft-attention model satisfying the additive layer-zero convention and bounds in the Statement, an input length , and two inputs differing only at position .
In each soft-attention head, the row attention weights are the softmax of the query-key scores, sum to one, and the head output is their weighted sum of value vectors (Hard and soft attention sequence models).
The finite matrices, layer count, number of heads, embedding bounds, and global Lipschitz constants are fixed independently of , as required in the Statement.
Proof
There are constants such that for every position , input length , and input pair. At layer zero this follows from and the bounded token and positional embeddings. If it holds at layer , each value vector has norm at most and each attention output is a convex combination of those values by [F1]; the fixed globally Lipschitz positionwise map is bounded on this resulting bounded set. Induction gives all .
Consequently every dot-product score at every layer has absolute value at most some . For any row with keys, its softmax weight is at most , since its numerator is at most and its denominator is at least .
We prove by induction on that for constants independent of , the changed position satisfies , while every satisfies . This holds at because only the bounded token embedding at changes. Assume it holds at and fix a query position and one head. Its query changes by . Its key at position can change by , while all other keys change by , using the fixed linear matrices and the induction hypothesis. Hence its score-difference vector has and for , for a constant independent of .
Interpolate the two score vectors linearly. All interpolated scores remain in , so the distinguished key has softmax weight at most throughout by step 2.1. For softmax probabilities , differentiation gives ; therefore , and integration yields .
The head values are uniformly bounded by step 1.1. Splitting the difference of the two weighted sums into (i) the change of values under the first attention row and (ii) the change of attention weights applied to the second value list gives : the changed value at has weight , all other value changes are , and the total weight change is by step 4.1. The positionwise map is Lipschitz, so for every . At , boundedness from step 1.1 gives a constant difference. This proves the induction claim.
Since , the induction bound gives . For a logit perturbation , the softmax derivative is , whose norm is at most ; hence the prediction probabilities differ by at most a constant times . Taking completes the hidden-state bound and supplies the stated probability bound.
Remarks
The proof includes the change in softmax attention weights caused by the changed key. This term is necessary because attention scores depend on the hidden states; it is bounded using the mass of the one changed key and the changes of the remaining logits.
Depends on
Used by
Dependency tree · two levels
3 results within two dependency steps of this one, each drawn at its shortest distance from it. An arrow runs from a result to what uses it, so the chart reads left to right and ends at this result, which carries a heavier outline. Every node is a link to that result. Click elsewhere on the chart to enlarge it.
Sources
- Hahn, Theoretical Limitations of Self-Attention in Neural Sequence Models, §6, Lemma 5 and proof (standard reference, not scraped)