proofs
Provedunbiased-attentionsampling-lower-boundadaptiveheadline-theorem

Explicit e^R threshold: with the plant size m = ⌈n/(1+e^R)⌉ (which exists when 1+e^R ≤ n), every adaptive exactly unbiased sampler needs s ≥ min(1/2, 1/64V)·(1+e^R)/2 probes

For all n,k,s∈N\htmlData{mx=1}{n, k, s \in \htmlData{mx=0}{\mathbb{N}}}, Ω∈Type⁡\htmlData{mx=1}{\Omega \in \htmlData{mx=0}{\operatorname{Type}}}, w:Ω→R\htmlData{mx=3}{w : \htmlData{mx=0}{\Omega} \mathrel{\htmlData{mx=2}{\to}} \htmlData{mx=1}{\mathbb{R}}}, g:N→Ω→List⁡ R→Fin⁡ n\htmlData{mx=11}{g : \htmlData{mx=0}{\mathbb{N}} \mathrel{\htmlData{mx=10}{\to}} \htmlData{mx=1}{\Omega} \mathrel{\htmlData{mx=9}{\to}} \htmlData{mx=4}{\htmlData{mx=2}{\operatorname{List}}\,\htmlData{mx=3}{\mathbb{R}}} \mathrel{\htmlData{mx=8}{\to}} \htmlData{mx=7}{\htmlData{mx=5}{\operatorname{Fin}}\,\htmlData{mx=6}{n}}}, out:Ω→List⁡ R→R\htmlData{mx=7}{\mathit{out} : \htmlData{mx=0}{\Omega} \mathrel{\htmlData{mx=6}{\to}} \htmlData{mx=3}{\htmlData{mx=1}{\operatorname{List}}\,\htmlData{mx=2}{\mathbb{R}}} \mathrel{\htmlData{mx=5}{\to}} \htmlData{mx=4}{\mathbb{R}}}, hist:(Fin⁡ n→R)→Ω→N→List⁡ R\htmlData{mx=13}{\mathit{hist} : (\htmlData{mx=2}{\htmlData{mx=0}{\operatorname{Fin}}\,\htmlData{mx=1}{n}} \mathrel{\htmlData{mx=4}{\to}} \htmlData{mx=3}{\mathbb{R}}) \mathrel{\htmlData{mx=12}{\to}} \htmlData{mx=5}{\Omega} \mathrel{\htmlData{mx=11}{\to}} \htmlData{mx=6}{\mathbb{N}} \mathrel{\htmlData{mx=10}{\to}} \htmlData{mx=9}{\htmlData{mx=7}{\operatorname{List}}\,\htmlData{mx=8}{\mathbb{R}}}} and R,V∈R\htmlData{mx=1}{R, V \in \htmlData{mx=0}{\mathbb{R}}}, if ∀ω, 0≤w(ω)\htmlData{mx=4}{\forall \omega,\ 0 \mathrel{\htmlData{mx=3}{\leq}} \htmlData{mx=2}{\htmlData{mx=0}{w}(\htmlData{mx=1}{\omega})}}, ∑ωw(ω)=1\htmlData{mx=3}{\sum_{\omega} \htmlData{mx=2}{\htmlData{mx=0}{w}(\htmlData{mx=1}{\omega})}} \mathrel{\htmlData{mx=4}{=}} 1, ∀y,ω, hist(y,ω,0)=[]\htmlData{mx=6}{\forall y, \omega,\ \htmlData{mx=3}{\htmlData{mx=0}{\mathit{hist}}(\htmlData{mx=1}{y}, \htmlData{mx=2}{\omega}, 0)} \mathrel{\htmlData{mx=5}{=}} \htmlData{mx=4}{\left[ \right]}}, ∀y,ω,t, hist(y,ω,t+1)=hist(y,ω,t)++([y(g(t,ω,hist(y,ω,t)))])\htmlData{mx=26}{\forall y, \omega, t,\ \htmlData{mx=5}{\htmlData{mx=0}{\mathit{hist}}(\htmlData{mx=1}{y}, \htmlData{mx=2}{\omega}, \htmlData{mx=4}{\htmlData{mx=3}{t} + 1})} \mathrel{\htmlData{mx=25}{=}} \htmlData{mx=24}{\htmlData{mx=10}{\htmlData{mx=6}{\mathit{hist}}(\htmlData{mx=7}{y}, \htmlData{mx=8}{\omega}, \htmlData{mx=9}{t})} + \htmlData{mx=23}{\mathtt{+}(\htmlData{mx=22}{\left[ \htmlData{mx=21}{\htmlData{mx=11}{y}(\htmlData{mx=20}{\htmlData{mx=12}{g}(\htmlData{mx=13}{t}, \htmlData{mx=14}{\omega}, \htmlData{mx=19}{\htmlData{mx=15}{\mathit{hist}}(\htmlData{mx=16}{y}, \htmlData{mx=17}{\omega}, \htmlData{mx=18}{t})})})} \right]})}}}, ∑ωw(ω)⋅out(ω,hist(⋅↦0,ω,s))=0\htmlData{mx=12}{\sum_{\omega} \htmlData{mx=11}{\htmlData{mx=2}{\htmlData{mx=0}{w}(\htmlData{mx=1}{\omega})} \cdot \htmlData{mx=10}{\htmlData{mx=3}{\mathit{out}}(\htmlData{mx=4}{\omega}, \htmlData{mx=9}{\htmlData{mx=5}{\mathit{hist}}(\htmlData{mx=6}{\cdot \mapsto 0}, \htmlData{mx=7}{\omega}, \htmlData{mx=8}{s})})}}} \mathrel{\htmlData{mx=13}{=}} 0, ∑ωw(ω)⋅(out(ω,hist(⋅↦0,ω,s))−0)2≤V\htmlData{mx=14}{\sum_{\omega} \htmlData{mx=13}{\htmlData{mx=2}{\htmlData{mx=0}{w}(\htmlData{mx=1}{\omega})} \cdot \htmlData{mx=12}{(\htmlData{mx=11}{\htmlData{mx=10}{\htmlData{mx=3}{\mathit{out}}(\htmlData{mx=4}{\omega}, \htmlData{mx=9}{\htmlData{mx=5}{\mathit{hist}}(\htmlData{mx=6}{\cdot \mapsto 0}, \htmlData{mx=7}{\omega}, \htmlData{mx=8}{s})})} - 0})^{2}}}} \mathrel{\htmlData{mx=16}{\leq}} \htmlData{mx=15}{V}, ∀S∈powersetCard⁡(k+1,univ⁡), ∑ωw(ω)⋅out(ω,hist(j↦{Rif j∈S0otherwise,ω,s))=k+1⋅eRk+1⋅eR+(n−(k+1))\htmlData{mx=44}{\forall S \in \htmlData{mx=43}{\htmlData{mx=38}{\operatorname{powersetCard}}(\htmlData{mx=40}{\htmlData{mx=39}{k} + 1}, \htmlData{mx=42}{\htmlData{mx=41}{\operatorname{univ}}})},\ \htmlData{mx=17}{\sum_{\omega} \htmlData{mx=16}{\htmlData{mx=2}{\htmlData{mx=0}{w}(\htmlData{mx=1}{\omega})} \cdot \htmlData{mx=15}{\htmlData{mx=3}{\mathit{out}}\left(\htmlData{mx=4}{\omega}, \htmlData{mx=14}{\htmlData{mx=5}{\mathit{hist}}\left(\htmlData{mx=11}{j \mapsto \htmlData{mx=10}{\begin{cases} \htmlData{mx=6}{R} & \text{if } \htmlData{mx=7}{j} \mathrel{\htmlData{mx=9}{\in}} \htmlData{mx=8}{S} \\ 0 & \text{otherwise} \end{cases}}}, \htmlData{mx=12}{\omega}, \htmlData{mx=13}{s}\right)}\right)}}} \mathrel{\htmlData{mx=37}{=}} \htmlData{mx=36}{\frac{\htmlData{mx=23}{\htmlData{mx=20}{\htmlData{mx=19}{\htmlData{mx=18}{k} + 1}} \cdot \htmlData{mx=22}{e^{\htmlData{mx=21}{R}}}}}{\htmlData{mx=35}{\htmlData{mx=29}{\htmlData{mx=26}{\htmlData{mx=25}{\htmlData{mx=24}{k} + 1}} \cdot \htmlData{mx=28}{e^{\htmlData{mx=27}{R}}}} + (\htmlData{mx=34}{\htmlData{mx=31}{\htmlData{mx=30}{n}} - (\htmlData{mx=33}{\htmlData{mx=32}{k} + 1})})}}}}, ∀S∈powersetCard⁡(k+1,univ⁡), ∑ωw(ω)⋅(out(ω,hist(j↦{Rif j∈S0otherwise,ω,s))−k+1⋅eRk+1⋅eR+(n−(k+1)))2≤V\htmlData{mx=47}{\forall S \in \htmlData{mx=46}{\htmlData{mx=41}{\operatorname{powersetCard}}(\htmlData{mx=43}{\htmlData{mx=42}{k} + 1}, \htmlData{mx=45}{\htmlData{mx=44}{\operatorname{univ}}})},\ \htmlData{mx=38}{\sum_{\omega} \htmlData{mx=37}{\htmlData{mx=2}{\htmlData{mx=0}{w}(\htmlData{mx=1}{\omega})} \cdot \htmlData{mx=36}{\left(\htmlData{mx=35}{\htmlData{mx=15}{\htmlData{mx=3}{\mathit{out}}\left(\htmlData{mx=4}{\omega}, \htmlData{mx=14}{\htmlData{mx=5}{\mathit{hist}}\left(\htmlData{mx=11}{j \mapsto \htmlData{mx=10}{\begin{cases} \htmlData{mx=6}{R} & \text{if } \htmlData{mx=7}{j} \mathrel{\htmlData{mx=9}{\in}} \htmlData{mx=8}{S} \\ 0 & \text{otherwise} \end{cases}}}, \htmlData{mx=12}{\omega}, \htmlData{mx=13}{s}\right)}\right)} - \htmlData{mx=34}{\frac{\htmlData{mx=21}{\htmlData{mx=18}{\htmlData{mx=17}{\htmlData{mx=16}{k} + 1}} \cdot \htmlData{mx=20}{e^{\htmlData{mx=19}{R}}}}}{\htmlData{mx=33}{\htmlData{mx=27}{\htmlData{mx=24}{\htmlData{mx=23}{\htmlData{mx=22}{k} + 1}} \cdot \htmlData{mx=26}{e^{\htmlData{mx=25}{R}}}} + (\htmlData{mx=32}{\htmlData{mx=29}{\htmlData{mx=28}{n}} - (\htmlData{mx=31}{\htmlData{mx=30}{k} + 1})})}}}}\right)^{2}}}} \mathrel{\htmlData{mx=40}{\leq}} \htmlData{mx=39}{V}}, k+1≤n\htmlData{mx=1}{\htmlData{mx=0}{k} + 1} \mathrel{\htmlData{mx=3}{\leq}} \htmlData{mx=2}{n}, 0<V0 \mathrel{\htmlData{mx=1}{<}} \htmlData{mx=0}{V}, 0≤R0 \mathrel{\htmlData{mx=1}{\leq}} \htmlData{mx=0}{R}, n−(k+1)≤k+1⋅eR\htmlData{mx=4}{\htmlData{mx=1}{\htmlData{mx=0}{n}} - (\htmlData{mx=3}{\htmlData{mx=2}{k} + 1})} \mathrel{\htmlData{mx=11}{\leq}} \htmlData{mx=10}{\htmlData{mx=7}{\htmlData{mx=6}{\htmlData{mx=5}{k} + 1}} \cdot \htmlData{mx=9}{e^{\htmlData{mx=8}{R}}}} and k+1⋅(1+eR)≤2n\htmlData{mx=6}{\htmlData{mx=2}{\htmlData{mx=1}{\htmlData{mx=0}{k} + 1}} \cdot (\htmlData{mx=5}{1 + \htmlData{mx=4}{e^{\htmlData{mx=3}{R}}}})} \mathrel{\htmlData{mx=9}{\leq}} \htmlData{mx=8}{2\htmlData{mx=7}{n}} (given Fintype⁡ Ω\htmlData{mx=2}{\htmlData{mx=0}{\operatorname{Fintype}}\,\htmlData{mx=1}{\Omega}}), then

(∀N∈N, R′∈R,1+eR′≤N  ⟹  ∃m∈N,1≤m∧m≤N∧N−m≤m⋅eR′∧m⋅(1+eR′)≤2N)∧min⁡(12,164V)⋅(1+eR2)≤s\begin{aligned} & \left(\right. \htmlData{mx=1}{\forall} N \in \htmlData{mx=2}{\mathbb{N}},\ R' \in \htmlData{mx=3}{\mathbb{R}}, \\ & \quad \htmlData{mx=7}{1 + \htmlData{mx=6}{e^{\htmlData{mx=5}{R'}}}} \mathrel{\htmlData{mx=9}{\leq}} \htmlData{mx=8}{N} \\ & \quad \htmlData{mx=4}{\implies} \htmlData{mx=10}{\exists} m \in \htmlData{mx=11}{\mathbb{N}}, \\ & \quad \quad 1 \mathrel{\htmlData{mx=14}{\leq}} \htmlData{mx=13}{m} \\ & \quad \quad \htmlData{mx=12}{\land} \htmlData{mx=15}{m} \mathrel{\htmlData{mx=17}{\leq}} \htmlData{mx=16}{N} \\ & \quad \quad \htmlData{mx=12}{\land} \htmlData{mx=21}{\htmlData{mx=19}{\htmlData{mx=18}{N}} - \htmlData{mx=20}{m}} \mathrel{\htmlData{mx=26}{\leq}} \htmlData{mx=25}{\htmlData{mx=22}{m} \cdot \htmlData{mx=24}{e^{\htmlData{mx=23}{R'}}}} \\ & \quad \quad \htmlData{mx=12}{\land} \htmlData{mx=32}{\htmlData{mx=28}{\htmlData{mx=27}{m}} \cdot (\htmlData{mx=31}{1 + \htmlData{mx=30}{e^{\htmlData{mx=29}{R'}}}})} \mathrel{\htmlData{mx=35}{\leq}} \htmlData{mx=34}{2\htmlData{mx=33}{N}} \left.\right) \\ & \htmlData{mx=0}{\land} \htmlData{mx=45}{\htmlData{mx=40}{\min(\htmlData{mx=36}{\frac{1}{2}}, \htmlData{mx=39}{\frac{1}{\htmlData{mx=38}{64\htmlData{mx=37}{V}}}})} \cdot \left(\htmlData{mx=44}{\frac{\htmlData{mx=43}{1 + \htmlData{mx=42}{e^{\htmlData{mx=41}{R}}}}}{2}}\right)} \mathrel{\htmlData{mx=47}{\leq}} \htmlData{mx=46}{s} \end{aligned}
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
n, k, s range over natural numbers: the statement must hold for every choice. ((n k s : ℕ))
Type
Type: a definition from the library, not special notation. Its name is its meaning; open it in Lean to see how it is defined. (Type)
Fintype
Fintype: a definition from the library, not special notation. Its name is its meaning; open it in Lean to see how it is defined. (Fintype)
f(x)Function application
Fintype applied to Ω. Lean writes f x; papers write f(x). (Fintype Ω)
⟹Implies
If Ω, then ℝ. (Between types, A → B is the type of functions from A to B.) (Ω → ℝ)
∀For all
The statement after the comma holds for every ω. (∀ ω, 0 ≤ w ω)
∑Summation
Add up w(ω) for every ω. (∑ ω, w ω)
=Equality
∑ ω, w(ω) and 1 are the same. (∑ ω, w ω = 1)
<Less than
0 is strictly smaller than V. (0 < V)
RReal numbers
The real numbers: every point on the number line. (ℝ)
≤At most
0 is less than or equal to w(ω). (0 ≤ w ω)
·Multiplication
w(ω) times out(ω, hist(_ ↦ 0, ω, s)). (w ω * out ω (hist (fun _ => 0) ω s))
powersetCard
Finset.powersetCard: a definition from the library, not special notation. Its name is its meaning; open it in Lean to see how it is defined. (Finset.powersetCard)
List
List: a definition from the library, not special notation. Its name is its meaning; open it in Lean to see how it is defined. (List)
aᵇPower
out(ω, hist(_ ↦ 0, ω, s)) − 0 raised to the power 2. ((out ω (hist (fun _ => 0) ω s) - 0) ^ 2)
-Subtraction
out(ω, hist(_ ↦ 0, ω, s)) minus 0. On ℕ, Lean's subtraction stops at 0: 2 − 5 = 0. (out ω (hist (fun _ => 0) ω s) - 0)
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)
+Addition
t plus 1. (t + 1)
[a, b]List
The list of , in order. ([])
x ↦ f(x)Function (λ-abstraction)
The function sending _ to 0. Lean writes fun x => …; papers write x ↦ …. (fun _ => 0)
(x : T)Type ascription
univ read as a Finset(Fin(n)). Mathematicians leave this implicit; Lean needs it to know which kind of number is meant. ((Finset.univ : Finset (Fin n)))
univ
Finset.univ: a definition from the library, not special notation. Its name is its meaning; open it in Lean to see how it is defined. (Finset.univ)
∃There exists
At least one m makes the statement after the comma true. (∃ m : ℕ, 1 ≤ m ∧ m ≤ N ∧ (N : ℝ) - m ≤ …)
∧And
Both hold: N − m ≤ m · exp(R'), and m · (1 + exp(R')) ≤ 2 · N. ((N : ℝ) - m ≤ m * Real.exp R' ∧ (m : ℝ)…)
{ a if c; b otherwiseCases (if … then … else)
R when j ∈ S, and 0 otherwise. (if j ∈ S then R else 0)
∈Element of
j is a member of S. (j ∈ S)
a/bDivision
(k + 1) · exp(R) divided by (k + 1) · exp(R) + (n − (k + 1)). In Lean, dividing by 0 gives 0. (((k + 1 : ℝ) * Real.exp R) / ((k + 1 : …)
(x : T)As real numbers
k + 1 read as an element of real numbers. Mathematicians leave this implicit; Lean needs it to know which kind of number is meant. ((k + 1 : ℝ))
minMinimum
The smaller of 1/2 and 1/(64 · V). (min (1 / 2) (1 / (64 * V)))
eˣExponential function
e raised to the power R, where e ≈ 2.718. (Real.exp R)

Answers review round 3 (codex), which correctly noted that ua-adaptive-sampling-threshold proves s(k+1)/n ≥ min(1/2, 1/(64V)) but that its plant condition only bounds n/(k+1) from above, so the e^R threshold did not follow. This statement adds the missing parameter link: (1) for every N and R' with 1 + e^{R'} ≤ N there is a plant size m (namely ⌈N/(1+e^{R'})⌉) with 1 ≤ m ≤ N, constant planted mass N − m ≤ m e^{R'}, and small plant m(1+e^{R'}) ≤ 2N; (2) with such a plant (hypothesis (k+1)(1+e^R) ≤ 2n), every fully adaptive sampler that is exactly unbiased with variance ≤ V on the planted softmax family needs s ≥ min(1/2, 1/(64V))·(1+e^R)/2 probes per run. Embeds ua-adaptive-sampling-threshold (coupling lemma, softmax instance, two-point bound). Scope as stated by the reviewer: coordinate-value queries, common finite randomness, no preprocessing.

How it was proved

Proved
5 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
351 lines of Lean
Sign in to see the proofThe proof, its signed report and its history.

More proved statements