Provedproposal-principleattentionunifiedprinciple
Positive-feature proposals are sampleable mixtures: feature c ∝ φ_c(q)·S_c then key ∝ ψ_c(j) gives P(j) = ⟨φ(q),ψ(j)⟩ / Σ_j' ⟨φ(q),ψ(j')⟩
For all , , and , if , , and , then
What the notation means · or point at any symbol
- NNatural numbers
- The natural numbers 0, 1, 2, …. In Lean they start at 0. (
ℕ) - x ∈ TVariables
- r, n range over natural numbers: the statement must hold for every choice. (
(r n : ℕ)) - Fin
- Fin: a definition from the library, not special notation. Its name is its meaning; open it in Lean to see how it is defined. (
Fin) - f(x)Function application
- Fin applied to r. Lean writes f x; papers write f(x). (
Fin r) - ⟹Implies
- If Fin(r), then ℝ. (Between types, A → B is the type of functions from A to B.) (
Fin r → ℝ) - ∀For all
- The statement after the comma holds for every c. (
∀ c, 0 < φ c) - =Equality
- ∑ c, φ(c) · (∑ i, ψ(c, i))/(∑ c', φ(c') · (∑ i, ψ(c', i)))… and (∑ c, φ(c) · ψ(c, j))/(∑ i, ∑ c, φ(c) · ψ(c, i)) are the same. (
∑ c, (φ c * (∑ i, ψ c i) / ∑ c', φ c' *…) - <Less than
- 0 is strictly smaller than φ(c). (
0 < φ c) - ·Multiplication
- φ(c) times ∑ i, ψ(c, i). (
φ c * (∑ i, ψ c i)) - a/bDivision
- φ(c) · (∑ i, ψ(c, i)) divided by ∑ c', φ(c') · (∑ i, ψ(c', i)). In Lean, dividing by 0 gives 0. (
φ c * (∑ i, ψ c i) / ∑ c', φ c' * (∑ i,…) - RReal numbers
- The real numbers: every point on the number line. (
ℝ) - ∑Summation
- Add up ψ(c, i) for every i. (
∑ i, ψ c i)
theorem pp-positive-feature-mixture {r n : ℕ} (φ : Fin r → ℝ) (ψ : Fin r → Fin n → ℝ) (j : Fin n) (hφ : ∀ c, 0 < φ c) (hψ : ∀ c i, 0 < ψ c i) (hn : 0 < n) (hr : 0 < r) :
∑ c, (φ c * (∑ i, ψ c i) / ∑ c', φ c' * (∑ i, ψ c' i)) * (ψ c j / ∑ i, ψ c i) = (∑ c, φ c * ψ c j) / ∑ i, ∑ c, φ c * ψ c iPlaces positive random-feature (Performer-style) attention inside the Proposal Principle: the feature map defines a proposal that is sampleable in O(r + log n) per draw after O(nr) preprocessing, to which exact rejection or SNIS+MLMC correction applies with cost 1 + χ² — turning a biased kernel approximation into an unbiased estimator of exact softmax attention. Part of 'The Proposal Principle: attention complexity is proposal complexity'.
How it was proved
- Proved
- 4 October 2026
- By
- Ajax, with the agent “Baguette math & proofs (Claude Code, 2026-10-03)”
- Checked by
- Lean's kernel (Lean 4.33.1, with Mathlib); the proof is signed and replays offline
- Axioms
- Classical.choice, Quot.sound, propext
- Proof
- 19 lines of Lean
Sign in to see the proofThe proof, its signed report and its history.