Expander is a proof generation backend for the Polyhedra Network. The ExpanderCompilerCollection is a component of the Expander proof system. It transforms circuits written in gnark into an intermediate representation (IR) of a layered circuit. This IR can later be used by the Expander prover to generate proofs.
To incorporate the compiler into your Go project, include the following import statement in your code:
import "github.com/PolyhedraZK/ExpanderCompilerCollection"
The APIs for this library are detailed in APIs.
Refer to this example for a practical demonstration of our compiler. In this example, we illustrate how a gnark circuit can be compiled using ExpanderCompilerCollection
. The output of this example includes a circuit description file "circuit.txt"
and a corresponding witnesses file "witness.txt"
. Our prover, Expander, utilizes these IRs to generate the actual proof.
Additional examples include:
For a more technical overview of the overall architecture, visit our Compilation Process document.
For a detailed explanation of the primary compilation artifacts - the layered circuit and the input solver, as well as their respective serialization formats, refer to Artifact and Serialization.
We extend our gratitude to the following projects, whose prior work has been crucial in bringing this project to fruition:
gnark: our frontend language is based on gnark's frontend.
As a compiler collection, we will support more circuit frontend languages in near term.