Euled Optimizer

Give it a Lean 4 file. It returns the same theorems with as few proof steps as it can find, checked by Lean, and says when no shorter proof exists.

  1. Every theorem and lemma statement stays byte-identical. Only proofs change.
  2. A step is one tactic. have h : x := by ring is two steps.
  3. Optimal means Euled checked every shorter proof built from its tactic list and Lean rejected all of them.

Pick a mode. Clear uses only tactics a reader can follow by hand (no aesop, grind, decide). Minimal allows every tactic and also runs the token shortener.

Limits

  1. Files run in Lean 4.24 with Mathlib. Up to 60 KB, one job at a time, 30 jobs a day.
  2. The lower bound covers proofs built from the tactic list: generic tactics plus every one-line tactic your proof already uses. A proof using some other tactic could still be shorter.
  3. Proofs need to be complete. Files with sorry are refused.