π€ AI Summary
This work presents the first complete formal verification of the semantic correctness of StarkWareβs S-two Algebraic Intermediate Representation (AIR) within the Lean 4 theorem prover. By integrating finite field algebra, formal semantics, and a precise modeling of AIR constraints, the study rigorously establishes that the satisfiability of this AIR logically entails the correct and complete execution of the corresponding Cairo virtual machine program. This formalization constructs a rigorous bridge between STARK cryptographic proof systems and formal verification, thereby providing a trustworthy mathematical foundation for computational integrity in STARK-based blockchain protocols.
π Abstract
StarkWare's S-two prover provides an efficient means for establishing, on blockchain, that a program written in the Cairo virtual machine language runs to completion. The latter claim is encoded by an algebraic intermediate representation (AIR) that captures the semantics of the Cairo language. The AIR asserts the existence of tables of values from a finite field satisfying certain algebraic constraints. A cryptographic interactive proof system, circle STARK, provides an efficiently-checked certificate that the AIR is satisfied. We describe our verification, using the Lean 4 proof assistant, that the AIR encoding is sound, which is to say, the satisfiability of the AIR implies the computational claim.