-
Notifications
You must be signed in to change notification settings - Fork 4
add README for stwo_run_and_prove #278
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add README for stwo_run_and_prove #278
Conversation
YairVaknin-starkware
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@YairVaknin-starkware reviewed 2 files and all commit messages, and made 1 comment.
Reviewable status:complete! all files reviewed, all discussions resolved (waiting on @nitsan-starkware).
Yael-Starkware
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Yael-Starkware reviewed 2 files and all commit messages, and made 10 comments.
Reviewable status: all files reviewed, 9 unresolved discussions (waiting on @nitsan-starkware).
crates/stwo_run_and_prove/src/README.md line 4 at r1 (raw file):
Run a compiled Cairo program and generate a Stwo proof for it. Optionally verify the proof. Saves the proof to the given path with the requested format, and optionally saves the program output and data for debugging.
Suggestion:
Runs a compiled Cairo program and generates a Stwo proof for it. Optionally verifies the proof.
Saves the proof to the given path with the requested format, and optionally saves the program output and data for debugging.crates/stwo_run_and_prove/src/README.md line 27 at r1 (raw file):
Optional arguments: - `--program_input <PathBuf>`: Absolute path to the program input file. - `--program_output <PathBuf>`: Absolute path for the program output.
Suggestion:
Absolute path where the program's output will be saved.crates/stwo_run_and_prove/src/README.md line 30 at r1 (raw file):
- `--prover_params_json <PathBuf>`: Absolute path to the JSON file containing the prover parameters. - `--proof_format <ProofFormat>`: Proof format (Json or CairoSerde. default: CairoSerde). - `--verify <bool>`: Should verify the generated proof.
- change suggestion below
- does it really need the bool value? or is it enough to just add "--verify" to the command line?
Suggestion:
If true, the program will verify the generated proof.crates/stwo_run_and_prove/src/README.md line 31 at r1 (raw file):
- `--proof_format <ProofFormat>`: Proof format (Json or CairoSerde. default: CairoSerde). - `--verify <bool>`: Should verify the generated proof. - `--save_debug_data <bool>`: Should save the ProverInput to a file in `debug_data_dir` for both success and failure.
same comment as for --verify
Code quote:
`--save_debug_data <bool>`: Should save the ProverInput to a file in `debug_data_dir` for both success and failure.crates/stwo_run_and_prove/src/README.md line 42 at r1 (raw file):
--verify \ --debug_data_dir path/to/debug_output \ --save_debug_data
according to the example, you don't need the "bool" from my previous questions.
Code quote:
Example with verification and debug data:
cargo run -p stwo_run_and_prove -- \
--program path/to/compiled_program.json \
--program_input path/to/program_input.json \
--proof_path path/to/proof.json \
--verify \
--debug_data_dir path/to/debug_output \
--save_debug_datacrates/stwo_run_and_prove/src/README.md line 47 at r1 (raw file):
## What it does 1. Runs the given Cairo program.
Suggestion:
Runs the given Cairo program with cairo-vm.crates/stwo_run_and_prove/src/README.md line 49 at r1 (raw file):
1. Runs the given Cairo program. 2. Calls `stwo_cairo_adapter::adapter::adapt(&cairo_runner)` to produce `ProverInput`. 3. Prove the program, and optionally verify it.
Suggestion:
Proves the program, and optionally verifies it.crates/stwo_run_and_prove/src/README.md line 50 at r1 (raw file):
2. Calls `stwo_cairo_adapter::adapter::adapt(&cairo_runner)` to produce `ProverInput`. 3. Prove the program, and optionally verify it. 4. Saves the outputs to the given paths.
Suggestion:
Saves the outputs and optionally the debug data, to the given paths.README.md line 33 at r1 (raw file):
### `stwo_run_and_prove` / (crate: `stwo_run_and_prove`) Runs a compiled cairo program and generates a Stwo proof for it. Optionally verify the proof, and saves the program output and data for debugging.
Suggestion:
Optionally verifies the proof9da9bc3 to
4b3fd27
Compare
nitsan-starkware
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@nitsan-starkware made 7 comments.
Reviewable status: 0 of 3 files reviewed, 9 unresolved discussions (waiting on @Yael-Starkware and @YairVaknin-starkware).
crates/stwo_run_and_prove/src/README.md line 30 at r1 (raw file):
Previously, Yael-Starkware (YaelD) wrote…
- change suggestion below
- does it really need the bool value? or is it enough to just add "--verify" to the command line?
We don't need the bool value (see the example below). How do you think that I should mention it?
README.md line 33 at r1 (raw file):
### `stwo_run_and_prove` / (crate: `stwo_run_and_prove`) Runs a compiled cairo program and generates a Stwo proof for it. Optionally verify the proof, and saves the program output and data for debugging.
Done.
crates/stwo_run_and_prove/src/README.md line 4 at r1 (raw file):
Run a compiled Cairo program and generate a Stwo proof for it. Optionally verify the proof. Saves the proof to the given path with the requested format, and optionally saves the program output and data for debugging.
Done.
crates/stwo_run_and_prove/src/README.md line 27 at r1 (raw file):
Optional arguments: - `--program_input <PathBuf>`: Absolute path to the program input file. - `--program_output <PathBuf>`: Absolute path for the program output.
Done.
crates/stwo_run_and_prove/src/README.md line 47 at r1 (raw file):
## What it does 1. Runs the given Cairo program.
Done.
crates/stwo_run_and_prove/src/README.md line 49 at r1 (raw file):
1. Runs the given Cairo program. 2. Calls `stwo_cairo_adapter::adapter::adapt(&cairo_runner)` to produce `ProverInput`. 3. Prove the program, and optionally verify it.
Done.
crates/stwo_run_and_prove/src/README.md line 50 at r1 (raw file):
2. Calls `stwo_cairo_adapter::adapter::adapt(&cairo_runner)` to produce `ProverInput`. 3. Prove the program, and optionally verify it. 4. Saves the outputs to the given paths.
By 'outputs' I meant all the outputs that I mentioned below.
Yael-Starkware
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Yael-Starkware reviewed 3 files and all commit messages, made 1 comment, and resolved 6 discussions.
Reviewable status: all files reviewed, 3 unresolved discussions (waiting on @nitsan-starkware).
crates/stwo_run_and_prove/src/README.md line 30 at r1 (raw file):
Previously, nitsan-starkware (Nitsan Davidovich) wrote…
We don't need the bool value (see the example below). How do you think that I should mention it?
just remove "" from the text.
my suggestion is not relevant if there is no bool value, but please remove the "should"
'--verfiy': Verifies the generated proof.
nitsan-starkware
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@nitsan-starkware made 3 comments.
Reviewable status: all files reviewed, 3 unresolved discussions (waiting on @Yael-Starkware).
crates/stwo_run_and_prove/src/README.md line 30 at r1 (raw file):
Previously, Yael-Starkware (YaelD) wrote…
just remove "" from the text.
my suggestion is not relevant if there is no bool value, but please remove the "should"
'--verfiy': Verifies the generated proof.
Done.
crates/stwo_run_and_prove/src/README.md line 31 at r1 (raw file):
Previously, Yael-Starkware (YaelD) wrote…
same comment as for --verify
Done.
crates/stwo_run_and_prove/src/README.md line 42 at r1 (raw file):
Previously, Yael-Starkware (YaelD) wrote…
according to the example, you don't need the "bool" from my previous questions.
Right
4b3fd27 to
ce39a2b
Compare
Yael-Starkware
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Yael-Starkware reviewed 1 file and all commit messages, made 3 comments, and resolved 3 discussions.
Reviewable status: all files reviewed, 3 unresolved discussions (waiting on @nitsan-starkware).
crates/stwo_run_and_prove/src/README.md line 50 at r1 (raw file):
Previously, nitsan-starkware (Nitsan Davidovich) wrote…
By 'outputs' I meant all the outputs that I mentioned below.
I think this version is more clear:
"Saves the proof, the output and optionally the debug data, to the given paths."
crates/stwo_run_and_prove/src/README.md line 30 at r3 (raw file):
- `--prover_params_json <PathBuf>`: Absolute path to the JSON file containing the prover parameters. - `--proof_format <ProofFormat>`: Proof format (Json or CairoSerde. default: CairoSerde). - `--verify <bool>`: Verifies the generated proof.
Suggestion:
`--verify`: Verifies the generated proof.crates/stwo_run_and_prove/src/README.md line 31 at r3 (raw file):
- `--proof_format <ProofFormat>`: Proof format (Json or CairoSerde. default: CairoSerde). - `--verify <bool>`: Verifies the generated proof. - `--save_debug_data <bool>`: Saves the ProverInput to a file in `debug_data_dir` for both success and failure.
Suggestion:
`--save_debug_data`: Saves the ProverInput to a file in `debug_data_dir` for both success and failure.
nitsan-starkware
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@nitsan-starkware made 3 comments.
Reviewable status: all files reviewed, 3 unresolved discussions (waiting on @Yael-Starkware).
crates/stwo_run_and_prove/src/README.md line 50 at r1 (raw file):
Previously, Yael-Starkware (YaelD) wrote…
I think this version is more clear:
"Saves the proof, the output and optionally the debug data, to the given paths."
Done.
crates/stwo_run_and_prove/src/README.md line 30 at r3 (raw file):
- `--prover_params_json <PathBuf>`: Absolute path to the JSON file containing the prover parameters. - `--proof_format <ProofFormat>`: Proof format (Json or CairoSerde. default: CairoSerde). - `--verify <bool>`: Verifies the generated proof.
Done.
crates/stwo_run_and_prove/src/README.md line 31 at r3 (raw file):
- `--proof_format <ProofFormat>`: Proof format (Json or CairoSerde. default: CairoSerde). - `--verify <bool>`: Verifies the generated proof. - `--save_debug_data <bool>`: Saves the ProverInput to a file in `debug_data_dir` for both success and failure.
Done.
ce39a2b to
051e2db
Compare
Yael-Starkware
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Yael-Starkware reviewed 1 file and all commit messages, made 1 comment, and resolved 2 discussions.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @nitsan-starkware).
crates/stwo_run_and_prove/src/README.md line 31 at r3 (raw file):
Previously, nitsan-starkware (Nitsan Davidovich) wrote…
Done.
one ` is missing
051e2db to
dc5616f
Compare
nitsan-starkware
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@nitsan-starkware made 1 comment.
Reviewable status: 2 of 3 files reviewed, 1 unresolved discussion (waiting on @Yael-Starkware).
crates/stwo_run_and_prove/src/README.md line 31 at r3 (raw file):
Previously, Yael-Starkware (YaelD) wrote…
one ` is missing
Fixed. thanks
Yael-Starkware
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Yael-Starkware reviewed 1 file and all commit messages, made 1 comment, and resolved 1 discussion.
Reviewable status:complete! all files reviewed, all discussions resolved (waiting on @nitsan-starkware).
Merge activity
|
dc5616f to
7267fbd
Compare

Type
Description
Breaking changes?
This change is