Skip to main content
QUICK REVIEW

[Paper Review] Scaling up Trustless DNN Inference with Zero-Knowledge Proofs

Daniel Kang, Tatsunori Hashimoto|arXiv (Cornell University)|Oct 17, 2022
COVID-19 diagnosis using AIMedicine11 citations
TL;DR

This paper presents the first zero-knowledge proof system for verifying full-resolution ImageNet-scale DNN inference using ZK-SNARKs, enabling trustless, non-interactive verification of model predictions on commodity hardware. It achieves 79% top-5 accuracy with proving times up to 1,000x faster than prior work, using novel arithmetization optimizations like lookup arguments for non-linearities and sub-circuit reuse.

ABSTRACT

As ML models have increased in capabilities and accuracy, so has the complexity of their deployments. Increasingly, ML model consumers are turning to service providers to serve the ML models in the ML-as-a-service (MLaaS) paradigm. As MLaaS proliferates, a critical requirement emerges: how can model consumers verify that the correct predictions were served, in the face of malicious, lazy, or buggy service providers? In this work, we present the first practical ImageNet-scale method to verify ML model inference non-interactively, i.e., after the inference has been done. To do so, we leverage recent developments in ZK-SNARKs (zero-knowledge succinct non-interactive argument of knowledge), a form of zero-knowledge proofs. ZK-SNARKs allows us to verify ML model execution non-interactively and with only standard cryptographic hardness assumptions. In particular, we provide the first ZK-SNARK proof of valid inference for a full resolution ImageNet model, achieving 79\% top-5 accuracy. We further use these ZK-SNARKs to design protocols to verify ML model execution in a variety of scenarios, including for verifying MLaaS predictions, verifying MLaaS model accuracy, and using ML models for trustless retrieval. Together, our results show that ZK-SNARKs have the promise to make verified ML model inference practical.

Motivation & Objective

  • To address the critical challenge of verifying correct execution of ML models in untrusted ML-as-a-service (MLaaS) environments.
  • To enable non-interactive, zero-knowledge verification of DNN inference at scale, specifically for ImageNet-level models.
  • To design practical protocols for verifying MLaaS predictions, model accuracy, and trustless document retrieval using ZK-SNARKs.
  • To optimize ZK-SNARK construction for DNNs to make verification feasible on commodity hardware.

Proposed method

  • Leverages ZK-SNARKs to generate succinct, zero-knowledge proofs of correct DNN inference without revealing inputs or weights.
  • Employs novel arithmetization techniques: lookup arguments for non-linearities and sub-circuit reuse across layers to reduce circuit size.
  • Commits to model weights via cryptographic hashes while proving correct inference, preserving model privacy.
  • Designs protocols combining ZK-SNARKs with economic incentives to enable trustless verification in MLaaS, auditing, and retrieval.
  • Uses Clopper-Pearson exact confidence intervals and Hoeffding’s inequality to determine sample sizes for statistical verification of model accuracy and prediction correctness.
  • Estimates costs on public cloud hardware (AWS r8i.8xlarge) for proving and verifying across different protocol parameters.

Experimental results

Research questions

  • RQ1Can ZK-SNARKs be scaled to verify full-resolution ImageNet models with practical proving and verification times?
  • RQ2How can ZK-SNARKs be efficiently applied to DNN inference while preserving model weight privacy?
  • RQ3What are the practical costs and performance trade-offs of using ZK-SNARKs for verifying MLaaS predictions and model accuracy?
  • RQ4Can ZK-SNARK-based protocols enable trustless, verifiable document retrieval in adversarial settings?
  • RQ5How do the proposed optimizations (lookup arguments, sub-circuit reuse) reduce circuit size and proving time compared to prior work?

Key findings

  • The paper presents the first ZK-SNARK circuit for a full-resolution ImageNet model (MobileNet v2) that can be proven and verified in 10 seconds on commodity hardware.
  • The system achieves 79% top-5 accuracy on ImageNet, demonstrating practical feasibility for real-world DNN inference verification.
  • Proving times are up to 1,000x faster than prior work, with lower bounds from existing methods being significantly higher.
  • Proof sizes are orders of magnitude smaller than MPC-based approaches, which can require tens to hundreds of gigabytes.
  • Cost estimates show that verifying Google Cloud Vision API predictions with similar overhead would add only 4% cost if scaled to MobileNet v2's efficiency.
  • Verifying model accuracy within ε=1% of target accuracy requires ~15,000 samples and ~$2,500 in cloud costs at δ=5%, which is feasible for high-stakes domains like healthcare or finance.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.