Wrap Proof
Re-encodes an existing STARK (VADCOP) proof into a smaller STARK proof or a PLONK proof for on-chain verification. Covers the input, proving-key, output, and performance flags and the resulting proof formats.
Generate a PLONK or minimal-STARK proof from an existing STARK
(VADCOP) proof. wrap takes a previously generated full STARK proof
file and re-encodes it into a smaller or differently-shaped proof.
cargo-zisk wrap --proof <PROOF> [OPTIONS]
Inputs
| Flag | Short | Default | Description |
|---|---|---|---|
--proof <PROOF> | -p | required | Path to the STARK (VADCOP) proof file to wrap. |
Proving Keys
Reuse a precomputed key instead of pulling the one at the default location. Pick the right flag for the proof type you intend to generate.
| Flag | Short | Default | Description |
|---|---|---|---|
--proving-key <PROVING_KEY> | -k | cached key | Path to a precomputed STARK proving key. |
--proving-key-plonk <PROVING_KEY_PLONK> | -w | cached key | Path to a precomputed PLONK proving key. Only consulted when --plonk is set. |
Proof Output
Where the wrapped proof is written and what shape it takes.
| Flag | Short | Default | Description |
|---|---|---|---|
--output <OUTPUT> | -o | File path the wrapped proof is written to. | |
--minimal | -c | false | Wrap into a smaller STARK proof. Mutually exclusive with --plonk. |
--plonk | false | Wrap into a PLONK proof, required for on-chain verification via the EVM verifier. Mutually exclusive with --minimal. |
Performance
| Flag | Short | Default | Description |
|---|---|---|---|
--gpu | -g | false | Use GPU acceleration during the wrapping step. Requires a supported CUDA GPU. |
Diagnostics
| Flag | Short | Default | Description |
|---|---|---|---|
--verbose | -v | off | Increase output verbosity. Pass -v for info, -vv for debug-level detail. |
Examples
Wrap a STARK proof into a PLONK proof for on-chain verification:
cargo-zisk wrap --proof ./proofs/proof.bin --plonk --output ./proofs/proof.plonk
Wrap into a smaller STARK proof (slower to produce, smaller artifact):
cargo-zisk wrap --proof ./proofs/proof.bin --minimal --output ./proofs/proof.min
Wrap on a GPU using non-default proving keys:
cargo-zisk wrap \
--proof ./proofs/proof.bin \
--plonk \
--proving-key-plonk ./keys/my-plonk-pk \
--gpu \
--output ./proofs/proof.plonk
Outputs
Writes the wrapped proof to the path specified by --output. The
exact format depends on the type flag:
--minimal— a compact STARK proof with the same verification semantics as the original VADCOP proof.--plonk— a PLONK proof verifiable by an EVM verifier contract.