Delta Z

Delta Z

The first implementation of zero-knowledge differential privacy.

The problem Delta Z solves

Delta Z is the first Zero Knowledge Differential Privacy (ZKDP) protocol.

In 2009, Netflix identified an opportunity to share their customer database with the ML community to improve their recommender engine. All data was pseudoanonymous yet hackers were able to reconstruct private information about individuals using statistical methods. This is a fundamental limitation given formally by The Fundamental Law of Information Recovery / Reconstruction Attack.

Clearly, pseudoanonymity is flawed.

Differential privacy provides mathematical guarantees that no personal information can ever be reconstructed from query results. However, it relies on a trusted data curator which is a single point-of-failure for corruption in a way that users are none-the-wiser.

Delta Z is a completely trustless DP solution. We have have implemented key algorithms from differential privacy literature as a Cairo-based smart contracts deployed on StarkNet (goerli). Mantle is used as a scalable L2 through which user queries are routed to the Cairo contracts. This allows users to submit queries as normal but receive results with verifiably correct noise that doesn't hinder their analysis.

Challenges I ran into

  • Many differential privacy mechanisms use continous functions like integrals which cannot be calculated in a ZK compatible way. Examples include the Gauss error function. We approximated such functions using truncated Taylor series.
  • ZK proofs use finite fields which makes it difficult for floating-point arithmetic to be implemented. Instead, to process rational number arithmetic, we made use of QNumbers (16.16) which were implemented in the Orion ZKML library.
  • StarkNet has an upper bound on the number of steps it can support which was a limitation when implementing more complex features in the noise addition algorithm.
  • Routing queries from the Mantle contract to the StarkNet contract was difficult and was therefore not implemented in this prototype. However, from an infra perspective, this would be the next key step.

Discussion