Repository navigation
v0.1.0: a standalone FlashProve verifier in Bend 2
The first public release of a standalone FlashProve verifier written in Bend 2. Given a model commitment, the tokens and a proof, it checks that every covered token is the committed integer model's first choice. It runs on a CPU and never sees the weights.
What works
- All four published configurations at both model sizes, the larger one with Llama 4 Maverick's dimensions. Each is checked under both acceptance policies, exact match and clipped gap.
- The whole verification runs in Bend: the key, the selected leaf and the request. Bend compiles to C, and the C entry point only passes the arguments in.
- One executable for any worker count. It prints the same answer with 1 worker or 16; 91 of 91 comparisons are identical.
Results
The full-size proof is 17.9 MiB and covers 1,001 tokens. Each time is the median of three fresh processes, from launch to exit. Every row measures the same Bend source (digest 7eb80fa0).
| CPU | Bend, 1 worker | Bend, 16 workers | Lean OnBytes | C++ cp_verify -j 1 |
|---|---|---|---|---|
| Apple M4 Max | 18.24 s | 8.20 s | 63.71 s | 8.54 s |
| Intel Xeon Platinum 8480CL (16 cores) | 34.46 s | 16.08 s | 94.64 s | 21.01 s (one core) |
- Against Lean OnBytes, FlashProve's native Lean verifier, Bend is 3.5× faster with one worker and 7.75× faster with 16 workers on the M4. On the Xeon the figures are 2.75× and 5.8×.
- Against the C++ reference with one worker each, Bend takes 2.1× (M4) and 1.6× (Xeon) as long. With 16 workers it finishes first on both machines.
M4 report · Xeon report · Measurement protocol
How it is checked
- Conformance: all four published proofs verify, and Bend and C++ both reject all 122 altered proof sets and all 256 fuzzed proofs. A separate campaign added 40,000 fuzzed inputs. A fresh proof from an H100 prover, under a new commitment, passed both verifiers.
- Types and kernel: all 164 modules pass Bend's dependent type checker. Bend's independent kernel (Lean v4.34.0) rechecked the standalone verifier and the proofs.
- Proven laws about the verifier's own code, checked on every commit:
- the 32-bit carry and borrow helpers compute
a + banda − b; - the Goldilocks product and reduction return the canonical residue;
- the cubic extension product is the schoolbook product modulo X³ − 2;
- the canonical decoders are exact, and reading bytes into words and back gives the same bytes.
- the 32-bit carry and borrow helpers compute
- Plans derived in Bend. Bend derives all 28 bundled transcript chains, byte for byte, from the public configuration files: chain parameters, round accounting and weight placement. The ported planner agrees with the pinned C++ at every layer.
- CI runs six parallel groups in about 15 minutes of wall time on every pull request, and fails if Bend's CPU time drifts beyond a budget relative to C++ on the same runner.
Limits
- No end-to-end proof yet. Nothing yet proves that Bend's acceptance implies the Lean verifier's acceptance for every input. The proven laws cover the arithmetic and decoding layers.
- Four configurations only. Some planner inputs still come from catalogs tied to the four published configurations. Deriving those inputs for configurations that were not shipped is tracked in #31, #88 and #32.
- Assumptions behind
bits=128. The security target assumes the proof-of-work rounds and commitment binding. Read the assurance contract before relying on it. - Synthetic weights. The larger model uses synthetic weights. The verifier is pinned to FlashProve
0.16.0-rc.26(9e2bdd8) and Bend2.0.40.
Try it
make bootstrap upstream standalone
make smoke # about 40 s warm: both small proofs, plus one altered bit that must be refused