Provedalphabaguettealgorithm-ideab5
Skipping softmax mass B ≤ δ·A changes the log-sum-exp loss by at most δ
For all , if , and , then
What the notation means · or point at any symbol
- RReal numbers
- The real numbers: every point on the number line. (
ℝ) - x ∈ TVariables
- A, B, δ range over real numbers: the statement must hold for every choice. (
(A B δ : ℝ)) - <Less than
- 0 is strictly smaller than A. (
0 < A) - ≤At most
- 0 is less than or equal to B. (
0 ≤ B) - ∧And
- Both hold: 0 ≤ log(A + B) − log(A), and log(A + B) − log(A) ≤ δ. (
0 ≤ Real.log (A + B) - Real.log A ∧ Rea…) - ·Multiplication
- δ times A. (
δ * A) - logNatural logarithm
- The logarithm of A + B to base e: the power e must be raised to to give A + B. (
Real.log (A + B)) - -Subtraction
- log(A + B) minus log(A). On ℕ, Lean's subtraction stops at 0: 2 − 5 = 0. (
Real.log (A + B) - Real.log A) - +Addition
- A plus B. (
A + B)
theorem vocab-lse-skip-error (A B δ : ℝ) (hA : 0 < A) (hB : 0 ≤ B) (hδ : B ≤ δ * A) :
0 ≤ Real.log (A + B) - Real.log A ∧ Real.log (A + B) - Real.log A ≤ δIdea B5. If the kept vocabulary mass is A > 0 and the skipped mass B satisfies 0 ≤ B ≤ δA, then 0 ≤ log(A + B) − log A ≤ δ: the cross-entropy computed from kept logits underestimates the exact loss by at most δ.
How it was proved
- Proved
- 3 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
- 22 lines of Lean
Sign in to see the proofThe proof, its signed report and its history.