GithubHelp home page GithubHelp logo

fflonk's Introduction

This repo aims to build a collection of tools for augmenting polynomial commitment schemes (PCS, from now on).

Shplonk

Shplonk, scheme #2 (aka private aggregation scheme from Halo Infinite, section 4) accumulates k opening tuples (Cf, z, v), each claiming that f(z) = v, commit(f) = Cf for a univariate polynomial f and points z, v, into a single one (C', z', v'), such that a proof for the aggregate claim attests that all other k claims are valid. It allows to compile a simple PCS, capable of proving single evaluation of a single polynomial at a time, into a PCS opening multiple polynomials each in different sets of points with a single proof. The overhead limits to producing the valid aggregate claim, that is generating one commitment by the prover, linear combination of k+2 commitments by the verifier, O(klog(k)) field operations for both, and one commitment of communication.

Notice that this type of aggregation is different from aggregation for vector commitments in that the proof for the aggregated claim is produced from scratch, while in the latter case the aggregate proof is computed from the proofs for the individual claims. At least, it is not implemented.

FFlonk

FFlonk from n polynomials of degrees not exceeding d constructs a polynomial of degree less that nd, such that evaluating each of the individual polynomials in the same k points is equivalent to evaluating the combined polynomial in nk points. In combination with a PCS enjoying efficient multipoint openings, asymptotically reduces the number of commitments to transfer and improves verifier performance.

What is implemented

  1. Traits for a minimal PCS (far from being perfect).
  2. Simplest form of KZG implementing these traits.
  3. Halo Inifinite private aggregation (aka Schplonk scheme #2) generic over the traits.
  4. Fflonk routines: combining polynomials, converting evaluations.
  5. Fflonk PCS from the original paper: opens Ffflonk-combined polynomials with Shplonk-compiled KZG.
  6. A test comparing opening a very vanilla (not zk, arithmetic gate only, no polynomial splitting) Plonk polynomial assignment using
    • Batching verification of KZG proofs in different points and linearization, as described in the original P lonK
    • The scheme described in ff lonK, Section 7.

KZG benchmarks

cargo test bench_minimal_kzg --release --features "parallel print-trace" -- --nocapture --ignored

outputs timings for generating a setup, committing to a 2^16-degree polynomial, proving and verifying an opening in a single point.

fflonk's People

Contributors

noc2 avatar swasilyev avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.