Verifiable evaluations of machine learning models using zkSNARKs

Verifiable evaluations of machine learning models using zkSNARKs

May 22, 2024 | Tobin South, Alexander Camuto, Shrey Jain, Shayla Nguyen, Robert Mahari, Christian Paquin, Jason Morton, Alex 'Sandy' Pentland
This paper presents a method for verifiable evaluation of machine learning models using zkSNARKs, enabling the creation of verifiable attestations that confirm model performance and fairness metrics without revealing private model weights. The system allows for the generation of zero-knowledge proofs that can be used to verify that a model with fixed private weights achieves stated performance or fairness metrics over public inputs. The approach is flexible and can be applied to any standard neural network model with varying computational requirements. The system includes a flexible proving system that maps ONNX model formats to proof circuits, enabling verifiable attestations on a wide range of models, including traditional non-neural models, multi-layer perceptrons, convolutional neural networks, long short-term memory networks, and small transformers. The system also includes a working implementation for public use with arbitrary models using the ezkl toolkit. The system addresses the challenge of verifying model performance claims in environments where model weights are kept private. This is particularly important in commercial applications where model transparency and accountability are critical. The system allows users to verify that the model they are using has the same performance characteristics as claimed, without needing to run their own tests or trust the model provider. This is achieved through a challenge-based model for checking model inference matches performance-attested model weights, and by allowing users to verify the model they access matches the model of the performance claim by verifying that the proof is valid and the corresponding model weight hash matches the original claim. The system also includes a method for aggregating inference proofs into verifiable evaluation attestations, which can be used to demonstrate the accuracy of models either through simple bundling of small proofs and verification files or through meta-proofs of performance over model inference proofs. The system's flexibility was demonstrated across a range of ML models ranging from small perceptrons and regression models to medium-sized transformers. The system leverages a 'predict, then prove' approach to serving results and proofs combined with a user challenge model of auditing responses, reducing the computational costs in production and shifting compute demands to model trainers. This is the first practical implementation of a verifiable evaluation for arbitrary ML systems, maintaining model weight confidentiality while ensuring model integrity. The system provides a new transparency paradigm in the verifiable evaluation of private models.This paper presents a method for verifiable evaluation of machine learning models using zkSNARKs, enabling the creation of verifiable attestations that confirm model performance and fairness metrics without revealing private model weights. The system allows for the generation of zero-knowledge proofs that can be used to verify that a model with fixed private weights achieves stated performance or fairness metrics over public inputs. The approach is flexible and can be applied to any standard neural network model with varying computational requirements. The system includes a flexible proving system that maps ONNX model formats to proof circuits, enabling verifiable attestations on a wide range of models, including traditional non-neural models, multi-layer perceptrons, convolutional neural networks, long short-term memory networks, and small transformers. The system also includes a working implementation for public use with arbitrary models using the ezkl toolkit. The system addresses the challenge of verifying model performance claims in environments where model weights are kept private. This is particularly important in commercial applications where model transparency and accountability are critical. The system allows users to verify that the model they are using has the same performance characteristics as claimed, without needing to run their own tests or trust the model provider. This is achieved through a challenge-based model for checking model inference matches performance-attested model weights, and by allowing users to verify the model they access matches the model of the performance claim by verifying that the proof is valid and the corresponding model weight hash matches the original claim. The system also includes a method for aggregating inference proofs into verifiable evaluation attestations, which can be used to demonstrate the accuracy of models either through simple bundling of small proofs and verification files or through meta-proofs of performance over model inference proofs. The system's flexibility was demonstrated across a range of ML models ranging from small perceptrons and regression models to medium-sized transformers. The system leverages a 'predict, then prove' approach to serving results and proofs combined with a user challenge model of auditing responses, reducing the computational costs in production and shifting compute demands to model trainers. This is the first practical implementation of a verifiable evaluation for arbitrary ML systems, maintaining model weight confidentiality while ensuring model integrity. The system provides a new transparency paradigm in the verifiable evaluation of private models.
Reach us at info@study.space