Commit 10d3bd2
feat(airbender): adapt prover server to v31 verifier wire format (#4880)
Adapt the Airbender prover server to the v31 verifier wire format and
add the plumbing needed to prove and verify a batch with it end-to-end:
a zkstack knob to deploy the Airbender L1 verifier, and a GPU e2e CI
lane that proves batch 1 and checks the proof on L1.
## What ❔
**Verifier bump (v31 wire format)**
- Bump `eravm-airbender-verifier` to the released `v31.1.1` tag, which
removes the `V0`/`V1` `AirbenderVerifierInput` envelope and adopts the
v31 wire layout (`L2PubdataValidator`, `settlement_layer`,
`interop_fee`).
- client: deserialize the FRI job directly into the single
`AirbenderVerifierInput` instead of polling `V1AirbenderVerifierInput`
and wrapping it in `AirbenderVerifierInput::V1`; the integration test
drops `.into_v1()` accordingly.
- `build.rs` resolves guest/VK artifacts from the pinned tag as usual
(with retry on transient download errors); the `AIRBENDER_*` env
overrides remain available for local development.
- SNARK wrapper: bind the guest program paths so the wrapper proves the
pinned guest.
- Note: the committed LFS bincode corpus used by the (ignored,
GPU-gated) integration test predates the v31 layout and still needs
regenerating.
**zkstack: `--verifier-type` (`testnet` | `dual` | `airbender`)**
- New `VerifierType` threaded through `ecosystem init` and `ctm` init
into the CTM deploy scripts; `airbender` wires the Airbender PLONK
verifier into the third slot of the Era dual verifier. Defaults preserve
current behavior (`testnet` for `no-proofs`, `dual` otherwise). Named
`--verifier-type` to avoid colliding with forge's `--verifier`.
- genesis validation: the dual verifier's sub-verifier VK check now
recognizes Airbender chains (index 2 on the Era dual verifier) and only
treats index 2 as Airbender when index 0 (FFLONK) also resolves, since
the ZKsyncOS dual verifier reuses index 2 for its own PLONK
sub-verifier. There is no config field for the Airbender VK hash yet
(TODO in code); a mismatch surfaces on L1 at prove time.
- `setDAValidatorPair` call sites updated for the new signature (adds
`access_control_restriction`).
**CI: Airbender GPU e2e lane**
- New `ci-airbender-prover-e2e.yml`: builds the prover server with CUDA
13 on a high-CPU runner, then on an RTX6000 GPU runner inits an
ecosystem with `--verifier-type airbender`, sends precompile txs into
batch 1, proves FRI then SNARK, and asserts on-chain that
`getTotalBatchesVerified` advances (real `proveBatchesSharedBridge`
through the Airbender verifier).
- The lane only runs for same-repo PRs: it executes a PR-built binary on
a persistent self-hosted GPU runner, so fork-controlled code never
reaches it.
- New checkers (`airbender_proof_status_checker`,
`batch_verified_on_l1_checker`) and `bin/prepare_airbender_fixture` to
collect proof artifacts for refreshing the era-contracts
`AirbenderPlonkProofFixture.sol`.
- `setup-env` gains an `sccache` toggle (the GPU hosts cannot
authenticate the GCS backend).
## Why ❔
The v31 protocol upgrade changed the batch commitment inputs (pubdata
validator, settlement layer, interop fee), and the Airbender verifier
repo followed with a breaking wire-format change. This PR keeps the
prover server compatible and adds the missing deployment/CI story so the
Airbender proving path is exercised end-to-end on every relevant change.
## Is this a breaking change?
- [ ] Yes
- [x] No
## Operational changes
- `zkstack ecosystem init` / `zkstack ctm init` accept `--verifier-type
{testnet,dual,airbender}`; omitting it preserves current defaults.
- The CTM deploy-script input gains an optional `airbender_verifier`
flag (older input configs stay compatible).
- The prover server accepts `PROVER_GUEST_DIST_DIR`, `FRI_VK`,
`SNARK_VK`, `SNARK_TRUSTED_SETUP_FILE`, `PROVER_SERVER_URL` to point at
artifacts explicitly.
## Checklist
- [x] PR title corresponds to the body of PR (we generate changelog
entries from PRs).
- [x] Tests for the changes have been added / updated.
- [x] Documentation comments have been added / updated.
- [x] Code has been formatted via `zkstack dev fmt` and `zkstack dev
lint`.
---------
Signed-off-by: Danil Lugovskoi <dl@matterlabs.dev>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>1 parent fb5f82e commit 10d3bd2
35 files changed
Lines changed: 983 additions & 213 deletions
File tree
- .github
- actions/setup-env
- workflows
- airbender_prover_server
- src
- tests
- bin
- prover_checkers
- core
- lib/object_store/src
- node
- genesis/src
- state_keeper/src/executor/tests
- zkstack_cli/crates
- config/src/forge_interface/deploy_ctm
- types/src
- zkstack/src
- commands
- chain
- gateway
- init
- ctm
- args
- commands
- ecosystem
- args
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
7 | 12 | | |
8 | 13 | | |
9 | 14 | | |
| |||
20 | 25 | | |
21 | 26 | | |
22 | 27 | | |
| 28 | + | |
23 | 29 | | |
24 | 30 | | |
25 | 31 | | |
| 32 | + | |
26 | 33 | | |
27 | 34 | | |
28 | 35 | | |
| |||
36 | 43 | | |
37 | 44 | | |
38 | 45 | | |
| 46 | + | |
39 | 47 | | |
40 | 48 | | |
41 | 49 | | |
| |||
44 | 52 | | |
45 | 53 | | |
46 | 54 | | |
47 | | - | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
48 | 62 | | |
49 | 63 | | |
50 | 64 | | |
| |||
53 | 67 | | |
54 | 68 | | |
55 | 69 | | |
| 70 | + | |
56 | 71 | | |
57 | 72 | | |
58 | 73 | | |
| |||
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
18 | | - | |
19 | 18 | | |
20 | 19 | | |
21 | 20 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| 19 | + | |
19 | 20 | | |
20 | 21 | | |
21 | 22 | | |
| |||
57 | 58 | | |
58 | 59 | | |
59 | 60 | | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
60 | 78 | | |
61 | 79 | | |
62 | 80 | | |
| |||
124 | 142 | | |
125 | 143 | | |
126 | 144 | | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
127 | 155 | | |
128 | 156 | | |
129 | 157 | | |
| |||
196 | 224 | | |
197 | 225 | | |
198 | 226 | | |
| 227 | + | |
199 | 228 | | |
200 | 229 | | |
201 | 230 | | |
| |||
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
102 | 102 | | |
103 | 103 | | |
104 | 104 | | |
105 | | - | |
106 | | - | |
107 | | - | |
108 | | - | |
109 | | - | |
110 | | - | |
111 | | - | |
112 | | - | |
113 | | - | |
114 | | - | |
| 105 | + | |
| 106 | + | |
115 | 107 | | |
116 | 108 | | |
117 | 109 | | |
| |||
0 commit comments