Auditing Accuracy Claims on Private Test Sets with Batched Homomorphic Encryption

Many machine learning results in medicine, education, and industry are reported on data that can never be released. Examples include a pneumoconiosis detector claiming 91.50% accuracy on protected chest X-rays, and voice-search models trained on smart-TV logs. Artifact review committees can check that such code runs. They cannot check the headline number, so the paper is rewarded for a claim that nobody outside the lab can test. We propose a protocol that lets a reviewer recompute the claimed metric on the real private test set without seeing it. The data holder publishes an encrypted, committed copy of the test set. After the claim is made, the reviewer draws a random subsample. The reviewer then runs the authors' released model on those encrypted examples, and the reviewer and data holder jointly decrypt a single number: how many predictions were correct.

The encryption is fully homomorphic encryption (FHE): a scheme that allows additions and multiplications directly on encrypted numbers, so a computation can run without decrypting its inputs. FHE is usually dismissed for machine learning because one encrypted prediction can take minutes and move gigabytes. Our central observation is that auditing a claim is exactly the workload where those costs largely disappear. A reviewer does not need a fast answer for one example. They need a few thousand examples evaluated once, with a turnaround of days. That is the large-batch, latency-tolerant regime in which FHE's packing of thousands of values into one ciphertext pays off.

Core Claim

To confirm or reject a claimed accuracy to within a tolerance $\epsilon$ at confidence $1-\delta$, a reviewer only needs a uniformly random sample of size

$$n \geq \frac{\ln(2/\delta)}{2\epsilon^2},$$

where the bound is Hoeffding's inequality for the mean of bounded per-example correctness indicators. For $\epsilon = 0.03$ and $\delta = 0.05$ this gives roughly 2,050 examples, which fits inside the 4,096 slots that CryptoNets packed into a single ciphertext. CryptoNets is the early system that ran a five-layer network on encrypted MNIST. Its reported per-prediction latency was 250 seconds, but it sustained 58,982 predictions per hour, with about 367.5 MB of ciphertext for 4,096 images.

The claim is that sampling, commitment, and batching together turn FHE auditing from intractable to affordable within an artifact-review budget. Sampling is what makes the check statistically sound. Commitment before sampling is what makes cherry-picking impossible. Batching is what makes the cost manageable.

The contrast is stark. The best-documented per-image FHE cost on a realistic model is from Haralampieva et al., who compared encrypted inference frameworks on MNIST and Malaria cell images. They report nearly 549 seconds and about 56 GB of transfer for one Malaria image through HE-Transformer. Naively repeating that 2,050 times would take on the order of 300 hours and over 100 TB of transfer. No volunteer committee can absorb that. Whether the batched audit really costs a small multiple of one batch is the empirical question this project answers.

Research Program

The audit involves three parties: the authors, a data custodian, and the reviewer. The authors release model weights to the reviewer, which is standard artifact review. The data custodian is usually the authors' institution or a hospital data office.

At submission time, the custodian encrypts the full test set, inputs and labels, under a key that is split between custodian and reviewer. The custodian publishes a hash commitment to the ciphertexts and signs it. After the paper's claim is fixed, the reviewer draws sample indices from public randomness. The reviewer evaluates the plaintext model weights against the encrypted inputs; multiplying a ciphertext by known weights is much cheaper than multiplying two ciphertexts. The reviewer then compares each prediction to its encrypted label homomorphically and sums the correctness indicators into one ciphertext. Only that aggregate count is jointly decrypted.

This design splits the roles cleanly. FHE supplies confidentiality: the data never leaves encryption. Integrity comes from the protocol rather than the cryptography: the reviewer executes every step except contributing a key share. We should be honest about what this does not prove. If the custodian commits to a fake or unusually easy test set, the audit inherits that fake. The protocol moves trust away from the author's reported number and onto a custodian's signed commitment. That is the same trust institutions already place in data-use agreements, and much less than trusting a bare number.

The central technical problem is fidelity. FHE natively computes only additions and multiplications, so ReLUs and the final argmax must be replaced by polynomials. That means the audited model is not exactly the claimed model. SecureNets frames the tension: low-degree approximations are cheap but inaccurate, while high-degree ones are faithful but deep enough to force bootstrapping, the costly operation that refreshes ciphertext noise. Prior work such as SAFENet and the activation-free PolyNeXt resolved that tension in favor of speed. Both redesigned the model, which an auditor is not allowed to do.

The audit setting resolves it the other way. Latency barely matters, and the bootstrapping cost is shared across every packed example. So we can choose high-degree approximations purely to minimize disagreement with the plaintext model. We then measure the remaining disagreement and charge it against the tolerance $\epsilon$.

We will build this as an open evaluation tool aimed at artifact committees. It will take a PyTorch model and produce a fidelity report alongside the encrypted accuracy. Its design will respond to the documented fragility of research code (Write Code that People Want to Use), because a verification tool that suffers bit rot defeats its own purpose.

Baselines

The naive reference point is the status quo: the reported number is accepted, and the artifact at most earns an "Available" badge in the sense of Key et al., who distinguish archived artifacts from independently executed ones. Its cost is zero, and it detects no inflated claims at all. We will measure how often it accepts the planted false claims described below. By construction, the answer is always.

The text-only automated baseline is ARA. ARA uses language-model agents to rebuild a paper's workflow from its text and reports about 61% accuracy against human reproducibility verdicts across ReScience C, ReproBench, and GoldStandardDB. It is the strongest scalable check that needs no data access. We will run it on the written descriptions of our planted-claim papers, with the same set of papers seen by every method. Because ARA never touches the data, we expect it to be blind to numeric inflation when the text is honest. Beating it means detecting inflations it misses while matching its labor cost per paper.

The strongest existing system for confidential evaluation is a hardware enclave, a protected region of the CPU that runs code in isolation. Haralampieva et al. report about 0.14 s per image for TF-Trusted on Intel SGX, roughly constant across model sizes. They report 0.25 s for CrypTen, a framework built on secure multi-party computation, in which several non-colluding servers each hold a share of the data. Both are far faster than any FHE figure in the literature.

For fairness, we will run the same random-challenge protocol inside an enclave and through CrypTen. This uses identical models, sample sizes, and hardware class, with each backend given the same engineering-time budget for tuning. We do not expect FHE to beat these systems on wall-clock time. Beating them means two things. First, completing audits they cannot: models that exceed enclave memory, which Haralampieva et al. identify as SGX's binding constraint, or audits without a non-colluding second server. Second, staying within a stated review budget of one commodity CPU node for 24 hours, with transfer in the low gigabytes.

The reference cost for the FHE backend is HE-Transformer's reported 549 seconds and 56 GB per Malaria image.

Two ablations isolate the key ingredients. In the first, the authors choose which examples are evaluated instead of the reviewer, which tests whether random challenge after commitment is what defeats cherry-picking. In the second, we compare evaluating examples one at a time against packing them, and low-degree against high-degree activation approximations. This isolates whether batching is what makes FHE affordable and whether the fidelity loss stays within $\epsilon$.

Why not just…?

Why not just use a hardware enclave? This is the most serious threat. For small models it may simply be better. The random-challenge protocol is independent of the computing backend, so if enclaves suffice everywhere, the protocol survives and FHE is unnecessary. Two things argue against assuming that. Enclaves have hard memory limits, which Haralampieva et al. flag as constraining larger architectures. They also require trusting the hardware vendor's attestation, which some hospital data offices may not accept. Our head-to-head experiment reports, model by model, where each backend fails. If the enclave dominates across our model ladder, we will say so.

Why not just use secure multi-party computation? CrypTen is fast on a local network. However, Haralampieva et al. note that local-network benchmarks hide the cost of many communication rounds over the open internet. Multi-party computation also needs servers that do not collude, which a reviewer and an author do not naturally provide. The FHE audit needs only one round of ciphertext transfer and one joint decryption, which suits reviewers who are asynchronous and geographically spread out. We will measure all backends under emulated wide-area network latency to test this.

Why not just require mock data or compiled proxies? Athanassoulis et al. propose binaries, mocked datasets, and simplified code so reviewers can test mechanics without proprietary data. That approach checks whether code runs. It cannot check accuracy on the real distribution, which is precisely the claim in cases like Devnath et al.. In our experiments, a model can be inflated on the real test set while scoring honestly on a synthetic proxy, and proxy-based review will then pass it.

Why not just have the data custodian rerun the code? A custodian that reruns the code and reports the result is cheap. However, the custodian is usually the authors' own institution, so the report is not independent. In our protocol, the custodian only contributes a key share and the reviewer performs every computation. The ablation in which the custodian runs the evaluation, with the authors free to select the examples, shows how much inflation each design can hide.

Proposed Experiments

We will simulate private data using public sets whose ground truth we control: MNIST, the 27,558-image Malaria cell set, and CIFAR-10. This lets us match the networks of Haralampieva et al. (Models X–Z) and of SAFENet (CNN-7, ResNet-32). The model ladder runs from CryptoNets-scale networks up to ResNet-32. We will add one PolyNeXt-style polynomial backbone to test whether architectures designed for FHE are cheaper to audit.

For each model we create honest claims and planted false claims. The false claims include accuracy inflated by 2–10 points through evaluation on a curated subset, a submitted model that differs from the evaluated one, and test-set leakage. Each claim is audited at $\epsilon \in \{0.01, 0.03, 0.05\}$.

We will measure five things. The first is verdict agreement with plaintext ground truth, where we target at least 99% on honest claims. The second is the detection rate of inflations larger than $\epsilon$, where we target at least $1-\delta$. The third is the fidelity gap, meaning the disagreement between the polynomial-approximated predictions and the plaintext argmax. The fourth is reviewer wall-clock time and the fifth is bytes transferred, both reported against HE-Transformer's 549 s and 56 GB per image and CryptoNets' 367.5 MB per 4,096-image batch.

The decisive checks are the following. The project succeeds if the batched FHE audit of about 2,050 samples on Malaria Model Z finishes within one node-day. It must also keep the fidelity gap below $\epsilon/2$ and detect a 5-point inflation at the stated confidence. It fails if bootstrapping makes high-fidelity approximation cost more than the batch savings. It is superseded if enclaves handle every model in the ladder within their memory limits. Any of these three outcomes tells artifact committees which backend to adopt.