Show HN: Lean4 proof that SSOT requires definition-time hooks and introspection
Published: (January 8, 2026 at 12:15 AM EST)
1 min read
Source: Hacker News
Source: Hacker News
Overview
I formalized the Single Source of Truth (SSOT) principle in Lean 4 (~2.1k LOC, zero sorry) and proved two core results:
- Structural SSOT is achievable only when a language provides definition‑time hooks and runtime introspection.
- Macros/codegen (before definition) and reflection (after definition) are the mechanisms that enable this.