Provedalphabaguettebaguette-zoptimizer
AdamW with decoupled decay keeps every parameter in a fixed box forever
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. (
ℕ) - ⟹Implies
- If ℕ, then ℝ. (Between types, A → B is the type of functions from A to B.) (
ℕ → ℝ) - x : TVariables
- θ, u range over ℕ → ℝ: the statement must hold for every choice. (
(θ u : ℕ → ℝ)) - x ∈ TVariables
- a, η, K range over real numbers: the statement must hold for every choice. (
(a η K : ℝ)) - <Less than
- 0 is strictly smaller than a. (
0 < a) - ≤At most
- a is less than or equal to 1. (
a ≤ 1) - ∀For all
- The statement after the comma holds for every t. (
∀ t, |u t| ≤ K) - RReal numbers
- The real numbers: every point on the number line. (
ℝ) - |x|Absolute value
- The size of u(t) without its sign. (
|u t|) - =Equality
- θ(t + 1) and (1 − a) · θ(t) − η · u(t) are the same. (
θ (t + 1) = (1 - a) * θ t - η * u t) - f(x)Function application
- u applied to t. Lean writes f x; papers write f(x). (
u t) - +Addition
- t plus 1. (
t + 1) - maxMaximum
- The larger of |θ(0)| and η · K/a. (
max |θ 0| (η * K / a)) - ·Multiplication
- 1 − a times θ(t). (
(1 - a) * θ t) - -Subtraction
- 1 minus a. On ℕ, Lean's subtraction stops at 0: 2 − 5 = 0. (
1 - a) - a/bDivision
- η · K divided by a. In Lean, dividing by 0 gives 0. (
η * K / a)
theorem bz-adamw-uniform-box (θ u : ℕ → ℝ) (a η K : ℝ) (ha0 : 0 < a) (ha1 : a ≤ 1) (hη : 0 ≤ η) (hu : ∀ t, |u t| ≤ K) (hθ : ∀ t, θ (t + 1) = (1 - a) * θ t - η * u t) :
∀ t, |θ t| ≤ max |θ 0| (η * K / a)θ(t+1) = (1−a)θ(t) − η·u(t) with 0 < a ≤ 1 (a = lr·decay) and |u| ≤ K gives |θ(t)| ≤ max(|θ(0)|, ηK/a) for ALL t. The master-weight bank therefore has a compile-time integer width valid for an unbounded training run. A short search did not find this uniform-in-time box stated in the literature. Part of the plan 'Baguette-Z: closed-loop certified integer-state training'.
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
- 25 lines of Lean
Sign in to see the proofThe proof, its signed report and its history.