Background

RISC Zero

The team at RISC Zero is excited you’re participating in our bounty! RISC Zero’s core product is our general purpose RISC-V zkVM. This allows a developer to write normal Rust and generate zero-knowledge proofs about its execution. Software requires building blocks and, with RISC Zero’s technology, you can use your favorite Rust crates to build whatever you can dream up. Additionally, because you’re generating a ZKP, in order for everyone to agree on what you’ve done, that computation only needs to be run once. That means orders of magnitude cheaper computation.

Bonsai

Generating a zero-knowledge proof on your own machine, however, is only part of the goal. You need something to do with that proof. With Bonsai, RISC Zero’s upcoming compute network, you get a number of important additional features. The first fundamental feature is delegable proof generation - the ability to not actually have to do the proof generation yourself. This is a core component of chain interoperability, but it’s also quite useful for efficiency and ease-of-use reasons. The next important feature is proof broadcast - because Bonsai’s current focus is computation, you’ll want to be able to access proof of that computation on your chain of choice - for this bounty, that chain is Ethereum.

With all of that in place, you’ve now got yourself a pretty powerful supercharger. By using the Bonsai proxy contract, you can effectively run Rust as part of your Solidity contracts. No more gas cost concerns, and you get to write in plain Rust.

function calculate_fibonacci(uint256 n) external {
    bonsai_proxy.submit_request(image_id, abi.encode(n), address(this));
}

Network Access

Bonsai is not currently publicly available, but we are excited to get ETHDenver participants hacking on it. As part of this bounty, you’ll have to request access to the network. This exercise is particularly important for us and the network because it will allow us to hear from you about the experience - we want to hear what worked, what didn’t, and talk about how to make things better. That feedback will be fundamental to getting to the first public launch, and we hope you’ll stick with us along that journey.

Bounty

As is laid out in the bounty description, the goal here is to build a Bonsai application. We encourage you to think about computationally complex tasks that you wouldn’t have otherwise been able to build on Ethereum.

Getting Started

Building distributed applications is hard, so we tried to make onboarding as easy as possible. To do so, we recommend every bounty participant start out with our Bonsai Starter Template. This template is a Bonsai application for calculating Fibonacci numbers. Starting with this scaffolding will help you quickly jump into building your app, without having to worry about infrastructure. Our Bonsai website also includes an overview of key components of the starter template, as well as Bonsai itself.

Getting Support

Not only is Bonsai pre-release software, but this is probably going to be a new experience for many bounty participants. Given that, members of the RISC Zero team will be available on Discord [roughly] around the clock. Participants are welcome to engage either in the ETHDenver discord, or our discord channel (especially if you want to stay involved after ETHDenver).

Deploying to Bonsai

Though deploying your application is not a hard requirement of the bounty, it definitely helps. Once your app is working well locally, you’ll want to deploy it to the Bonsai Testnet, which is connected to the Goerli Testnet. To do so, you’ll need to request access to the network. You can do that here.