Pictionary Proof

Pictionary Proof

Play a multiplayer drawing game, with provably fair and privacy-respecting zkML scoring mechanism.


The problem Pictionary Proof solves

We (partially, doesn't 100% work) implemented a game that works as follows:

  1. Users join, set start time
  2. The smart contract randomly and secretly picks 1 out of 10 cathegories
  3. Each user submits a drawing via the webapp
  4. A neural network (CNN classifier for Imagenette, a 10-classes version of Imagenet, only about 10^6 parameters) classifies the user submission. We compute a proof of the forward pass of the neural network.
  5. A Risc0 zkVM compares the evaluation of the submisssion (a vector with 10 entries) against the secretly picked class and computes a score.
  6. whoever has the best score wins, I.e. whoever submitted the drawing that the classifier thought was closest to the secretly picked class.

Challenges we ran into

  1. We had to find a neural network that was viable for snarking. Originially we tried the smaller versions of MobileNet (ultra-small classifiers for Imagenet), but gave up on that because the RAM requrements were to big to deploy that anywere.

  2. We found and error in out original design: In the original verision, the secret pick by the game contract would have been visible to the players in the zkVM journal for the scoring of the frst round.

Tracks Applied (2)

Prizes for Top 3, Hackers' Choice & Chewing Glass

We built a thing with zk tooling.

🤝 ZK Coprocessor

We compute the game scoring with Risc0

RISC Zero

Discussion