Welcome to the RISC Zero Rust Starter Template! This template is intended to give you a starting point for building a project using the RISC Zero zkVM. Throughout the code are comments labelled TODO
in places where we expect projects will need to modify the code.
TODO: Replace this README with a README for your project
TODO: Verify whether the included .gitignore
, LICENSE
, and rust-toolchain
files are appropriate to your project
First, make sure rustup is installed. This project uses a nightly version of Rust. The rust-toolchain
file will be used by cargo
to automatically install the correct version.
To build all methods and execute the method within the zkVM, run the following command:
cargo run
This is an empty template, and so there is no expected output (until you modify the code).
Search this template for the string TODO
, and make the necessary changes to implement the required feature described by the TODO
comment. Some of these changes will be complex, and so we have a number of instructional resources to assist you in learning how to write your own code for the RISC Zero zkVM:
- The Getting Started section of the RISC Zero website is a great place to get started. There are additional explainers and overviews on our website as well.
- Example projects are available in our risc0/risc0-rust-examples repository.
- Reference documentation for our Rust crates is available at [docs.rs], including the RISC Zero zkVM crate, the RISC Zero zkVM guest crate, the RISC Zero build crate, and others (the full list is available at [https://github.com/risc0/risc0/blob/main/README.md]).
- Our main repository.
We welcome contributions to documentation and code via PRs and GitHub Issues on our main repository, this repository, or any of our other repositories.