Repository navigation
feat(openvm-prover): add verified proving checkpoints - #2340
Bruno12221 wants to merge 2 commits into
Conversation
|
@Bruno12221 is attempting to deploy a commit to the Gnosis Guild Team on Vercel. A member of the Team first needs to authorize it. |
|
No actionable comments were generated in the recent review.
|
| Layer / File(s) | Summary |
|---|---|
Checkpoint identity and bounded reads crates/openvm-prover/Cargo.toml, crates/openvm-prover/src/checkpoint.rs |
Checkpoint manifests bind proof stages to the OpenVM version and revision, application commitment, journal, configuration artifacts, and required files. Reads validate file type, size limits, and content digests. |
Checkpoint writes and publication crates/openvm-prover/src/checkpoint.rs |
Checkpoint writes record file digests and publish the manifest after syncing complete files. Publication checks destination paths and filesystem support, and tests cover interrupted writes, collisions, and file permissions. |
CLI and verified proof stages crates/openvm-prover/src/main.rs, crates/openvm-prover/src/stages.rs, crates/openvm-prover/README.md, docs/architecture/encrypted-computation.md |
The CLI routes four actions through staged proving. Handlers verify proof data against configured commitments and the journal before saving checkpoints. Root compression verifies the root proof and EVM proof before publishing a seal. |
Checkpoint and contract qualification crates/openvm-prover/tests/checkpoints/*, crates/openvm-prover/README.md, packages/interfold-contracts/test/Deployment/OpenVmCheckpoint.spec.ts |
The opt-in workflow builds a guest fixture, exercises proof stages and relocated checkpoints, and verifies a receipt. The contract test checks a genuine seal and rejects altered inputs. |
Priority:
Estimated code review effort: 4 (Complex) | ~60 minutes
Change: Feature
Sequence Diagram(s)
sequenceDiagram
participant ProverCLI
participant stages_run
participant Checkpoint
participant OpenVM_SDK
participant EVM_verifier
ProverCLI->>stages_run: Dispatch stage with input, journal, and output
stages_run->>Checkpoint: Open prior checkpoint or create output checkpoint
stages_run->>OpenVM_SDK: Prove and natively verify proof
OpenVM_SDK-->>stages_run: Return proof and verification result
stages_run->>Checkpoint: Save proof and publish completed manifest
stages_run->>EVM_verifier: Generate and verify root seal during compression
EVM_verifier-->>stages_run: Return verified seal
Suggested reviewers: ctrlc03
Merge Risk: 
Minimal · up to aa802
-
No identified issue blocks merging the staged checkpoint workflow after normal checks.
Pre-merge checks: 
4 · 
1
-
Failed checks: 1 warning Passed checks: 4 passedFull details: Docstring Coverage
-
Explanation
Docstring coverage is 1.22% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 82 functions across 6 files. (6 skipped: 6 unsupported.)
Resolution
Write docstrings for the functions missing them to satisfy the coverage threshold.
-
Finishing Touches: 💡 1
-
🛠️ Fix failing CI checks: 💡
-
- Commit to this branch
- Create a new PR
🧪 Generate unit tests (beta)
-
- Create a new PR
-
- Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Warning
Some tools did not complete. Review the errors below.
🔧 ESLint
-
If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.
packages/interfold-contracts/test/Deployment/OpenVmCheckpoint.spec.ts
-
ESLint skipped: missing config or dependency (missing-dependency). The ESLint configuration references a package that is not available in the sandbox.
-
🔧 Clippy (1.99.0)
-
Clippy execution failed
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
Comment @coderabbitai help to get the list of available commands.
bd880ed to
5f25881
Compare
|
@coderabbitai review |
|
|
@coderabbitai full review |
✅ Action performed
|
What and why
Add optional, verified checkpoints at the existing application, aggregation and root proof
boundaries. The one-shot command currently saves only the final seal, so a late failure can require
repeating earlier proving work.
The motivation came from running a pilot for sealed-bid NFT auctions locally, where long proof
runs and compression memory requirements made the full pipeline difficult to run uninterrupted.
Developers running locally can encounter these constraints even when a production prover has ample
RAM and compute.
Saving completed stages makes it possible to:
when sufficient memory is available.
The new commands are
prove-app,aggregate-stark,prove-rootandcompress-root. Each saved orimported proof is cryptographically verified against the expected application identity and exact
journal. Manifests bind the SDK revision and artifact/file hashes, and are published last after
synchronizing checkpoint files. Outputs cannot overwrite existing paths, and publication
capabilities are checked before expensive proving.
The patch also includes a small pinned guest, an opt-in reproduction workflow and an actual-contract
receipt test. Existing one-shot commands remain available.
Verification
Tested on Ubuntu with Rust 1.91.1 and locked dependencies:
tests were explicitly invoked and passed with earlier and newly generated fixtures.
processes, including checkpoint relocation and compression resumed in a fresh supervisor after a
completed root.
accepted the genuine receipt and rejected changed proof, journal and identity inputs, with
independent checks also passing on macOS.
new-source license checks.
The fresh qualification used a small synthetic guest. Compression sampled about 27.5 GiB
process-group RSS on a 32 GB machine; no speedup comparison was performed. Restart testing used a
planned stop at a completed boundary, and relocation used directories on one physical host. Contract
checks used an isolated project with the exact repository test, helpers and unchanged contracts.
Full repository CI, abrupt power loss, and CUDA compilation/runtime have not been tested.
Compatibility
Existing
prove/verifybehavior, journal binding, receipt encoding and deployed verifier identitiesremain unchanged. No contract, circuit, peer/replay schema or protocol release-counter changes are
introduced. The new local checkpoint schema pins the current SDK revision and requires matching
artifacts. Existing workers can continue using their original one-shot flow.
This is a manual worker CLI feature; automatic HTTP recovery remains outside its scope. Imported
proof byte limits do not bound decoded memory or CPU time. Worker dependency versions are unchanged;
inherited SDK advisories remain unresolved. Compatibility was reviewed against the encrypted
computation and protocol-history domain documents.
Summary by CodeRabbit