---
title: Sudoku snark
subtitle: a story by [Kompact.io](https://kompact.io)
mainfont: jetbrains-mono
# title-slide-attributes:
    # data-background-image: ./assets/background.jpg
    # data-background-gradient: "linear-gradient(147deg, #000000 0%, #2c3e50 74%)"
# data-background-gradient: "radial-gradient(#283b95,#17b2c3)"
background-image: ./assets/background.avif 
background-opacity: "0.35"
---

# How it started 

## There is hackathon on cardano 🥳 ... 

## But wait! 🧐 There is a ZK track 

## Surely No!?

- Fundemtal primitives for any zk-alg are not available in plutus
- Midnight, the much hyped zk sidechain, is essentially in stealth mode
- zk on cardano? not possible! 😵‍💫

- Using some other chain for zk and bridging over
... that's _bridging_: we want _zk_

## ... oh, hello [PR#5231][pr-5231] 👀 {data-background-image="./assets/zk-pr-screenshot.png" data-background-opacity="0.3"} 

[pr-5231]: https://github.com/input-output-hk/plutus/pull/5231

## 

- A beast of a PR: 6 months, 230 commits, 319 files changed
- Finally merged during this hackathon

> This PR adds new built-in types and functions to Plutus Core and PlutusTx 
> for pairings over BLS12-381, as specified in CIP-0381. 

## What does this mean??

- [CIP-0381][cip-0381]: Plutus support for Pairings over `BLS12_381`
- In other words, plutus gets the builtins 
that make it possible to begin genuine zk on cardano

[cip-0381]: https://cips.cardano.org/cips/cip0381/

## So Yes! We can zk on cardano

## First hurdle

- Only the primitives are provided; we need implement a zk-alg
- Use it as the basis for a dapp
- And do both in a way that doesn't break the (tx exunits) bank

## And then?

- Having zk in the latest version of plutus is one thing:
Running a zk dapp on cardano is quite another!

- There is no chance of running these new primitives on 
Cardano mainnet any time soon

## Not on L1, but ... hydra {data-background-image="./assets/hydra.png" data-background-opacity="0.3"} 

- Hydra can, in theory, run a modified version of plutus
- Hydra is very much Cardano

## ... so we'd need to: 📋

- Create a zk validator
- Create the related functionality to build relevant txs
- Bump the various cardano libraries necessary to get hydra to run 
the latest
- Deploy

(Do this all in less than three weeks, while keeping the day job 😅)

# Sudoku snark 

## Aims

- Create a non trivial zk dapp on Cardano, that provides as a demonstrable PoC

- The Dapp itself can be facile: its contribution is to derisk more ambitious dapps with stronger use cases

## The game 

- Competitive sudoku.
- Contestants register their desire to take part
- Game master initializes a puzzle with first, and second prizes
- A contestant can claim a prize by proving they know the answer
- by the powers of zk, the claim does not disclose the solution

xxxxxxxxxxxx


# What next?

# Why this should win?

## The judging criteria 

- Innovation and Necessity to the Cardano Blockchain Ecosystem (20%)

This evaluates how novel and essential your solution is within the Cardano ecosystem. It looks at whether your idea is unique and if it solves a critical need.

- Maturity of the Tech and Product (40%)

This assesses the technical robustness and readiness of your solution. It considers the technology used, the degree of completion, and the readiness for deployment of your product.

- Go-to-Market Strategy, User Acquisition Strategy and Community Growth Strategy (20%)

This looks at your plan to introduce your product to the market, how you plan to acquire users, and strategies you have for growing your community. It evaluates the viability and potential effectiveness of these strategies.

- Team and Experience (20%)

## ..

- Given that zk is 
  - highly technical
  - incredibly nacent in blockchain
  - barely exists on cardano
- expecting a maturish product with a "go2market" strategy seemed ... ambitious 

# As for the team 

## @waalge {data-background-image="./assets/dp.jpg" data-background-opacity="0.3"} 

- Cheif of [Kompact.io](https://kompact.io)
- 2 years building around cardano (eg guchi.io)
- Previously full stack dev, ML/NLP researcher
- PhD in geometry

<a href="https://www.linkedin.com/in/dominic-algernon-wallis-123b42187/">
  <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 448 512" height="80" preserveAspectRatio="xMidYMid meet" fill="white">
    <!--! Font Awesome Pro 6.4.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2023 Fonticons, Inc. -->
    <path
      d="M416 32H31.9C14.3 32 0 46.5 0 64.3v383.4C0 465.5 14.3 480 31.9 480H416c17.6 0 32-14.5 32-32.3V64.3c0-17.8-14.4-32.3-32-32.3zM135.4 416H69V202.2h66.5V416zm-33.2-243c-21.3 0-38.5-17.3-38.5-38.5S80.9 96 102.2 96c21.2 0 38.5 17.3 38.5 38.5 0 21.3-17.2 38.5-38.5 38.5zm282.1 243h-66.4V312c0-24.8-.5-56.7-34.5-56.7-34.6 0-39.9 27-39.9 54.9V416h-66.4V202.2h63.7v29.2h.9c8.9-16.8 30.6-34.5 62.9-34.5 67.2 0 79.7 44.3 79.7 101.9V416z" />
  </svg>
</a>
---
<a href="https://twitter.com/waalge">
  <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512" height="80" preserveAspectRatio="xMidYMid meet" fill="white">
    <!--! Font Awesome Pro 6.4.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2023 Fonticons, Inc. -->
    <path
      d="M459.37 151.716c.325 4.548.325 9.097.325 13.645 0 138.72-105.583 298.558-298.558 298.558-59.452 0-114.68-17.219-161.137-47.106 8.447.974 16.568 1.299 25.34 1.299 49.055 0 94.213-16.568 130.274-44.832-46.132-.975-84.792-31.188-98.112-72.772 6.498.974 12.995 1.624 19.818 1.624 9.421 0 18.843-1.3 27.614-3.573-48.081-9.747-84.143-51.98-84.143-102.985v-1.299c13.969 7.797 30.214 12.67 47.431 13.319-28.264-18.843-46.781-51.005-46.781-87.391 0-19.492 5.197-37.36 14.294-52.954 51.655 63.675 129.3 105.258 216.365 109.807-1.624-7.797-2.599-15.918-2.599-24.04 0-57.828 46.782-104.934 104.934-104.934 30.213 0 57.502 12.67 76.67 33.137 23.715-4.548 46.456-13.32 66.599-25.34-7.798 24.366-24.366 44.833-46.132 57.827 21.117-2.273 41.584-8.122 60.426-16.243-14.292 20.791-32.161 39.308-52.628 54.253z" />
  </svg>
</a>
