Anthropic's FlashProve: Zero-Knowledge Proofs for LLM Model Verification
Anthropic's open-source FlashProve project uses zkSNARK zero-knowledge proofs to let users verify that LLM responses come from the claimed model, detecting proxy services that secretly swap expensive models for cheaper alternatives, though practical deployment faces cost, context-length, and trust-anchor challenges.
Introduction: The Problem of AI Proxy "Watering Down"
Many users access models like Claude Opus through third-party proxies (中转站) for lower cost and convenience. However, proxies can secretly forward requests to cheaper models while charging for premium ones, and users have no reliable way to detect this. The only observable output is the final text; the intermediate chain is a black box.
Why Traditional Verification Fails
Asking the model fails because proxies can inject system prompts forcing any model to claim a specific identity.
Testing knowledge or style is unreliable: a wrong answer could be either model error or substitution.
Re-running with known weights is impossible for closed-source models (weights are proprietary) and impractical for open-source ones (hundreds of GB, high-end GPUs required).
FlashProve's Three-Step Verification Process
Step 1: Weight Fingerprinting
The model vendor computes a short, collision-resistant fingerprint (hash) of the exact model weights and publishes the fingerprint ID. Any weight change produces a completely different fingerprint; the fingerprint reveals nothing about the weights themselves (analogous to password hashing).
Step 2: Per-Response Credential Generation
For each inference request, the service provider uses GPU to generate a credential file proving: "The weights matching this fingerprint, given this input, produced these output tokens." The credential binds three elements: weights, input, and output. Any alteration breaks the credential.
Step 3: Client-Side Verification
The user collects four items: the trusted fingerprint, their original prompt, the received response, and the provider's credential. A CPU-only verifier checks them in ~20 seconds, outputting YES or NO. No GPU or weights needed.
How Verification Works Without Re-Running the Model: zkSNARK Explained
FlashProve uses zkSNARK (Zero-Knowledge Succinct Non-Interactive Argument of Knowledge). The author illustrates with an auditing analogy:
Encode with redundancy : Transform the computation trace into a longer, error-correcting-code-like representation. A single changed value corrupts a large fraction of the encoded trace.
Commit then sample : The prover commits to the full encoded trace via a Merkle tree root hash. The verifier then samples a few random positions derived from that hash. The prover cannot predict which positions will be checked.
Zero-knowledge : Random masks added during encoding mean sampled values reveal nothing about the original weights or intermediate activations.
This yields succinct verification (orders of magnitude less work than re-execution) and zero-knowledge property (weights remain hidden).
Three Cheating Strategies and Why They Fail
Model substitution : Cheaper model's weights won't match the published fingerprint; credential verification fails.
Replay attack : Credentials bind specific input-output pairs; any token or prompt change invalidates the credential.
Forge credential : Requires breaking the underlying hash function; probability negligible.
Why This Wasn't Feasible Before: Performance Breakthrough
Prior work (VerInf on Llama-4-Maverick 400B parameters) required 14.3 hours to prove 1,000 tokens, producing a 93.6 GB proof, with verification taking nearly a day.
FlashProve on the same model (MoE, 17B active params per token) on a single H100 GPU with batch size 24:
Proving time: 223 seconds (≈110 tokens/sec throughput)
Proof size: 18.78 MB
Verification time: 17–21 seconds on CPU
Key optimizations:
Active-parameter-only proving : Only the 17B active parameters (not full 400B) are included in the proof, saving >90% work.
Asynchronous batched proving : Responses are returned immediately; proofs are generated later on separate machines in batches (~5 min latency per request).
Five Practical Limitations (Cold Water)
Fingerprint trust anchor missing : A malicious proxy could publish its own fingerprint for a small model. Like HTTPS needing CAs, fingerprints need a trusted issuer; no such mechanism exists yet.
Vendor participation required : Only the weight holder (Anthropic, OpenAI, etc.) can generate credentials. Anthropic has not committed to deploying this for Claude; the repo is labeled a research prototype.
High cost and short context : Proving costs 70–95× normal inference GPU time. Context limited to 1024 tokens (vs. tens of thousands in real coding sessions).
Integer vs. float/sampling mismatch : FlashProve proves integer-model execution with greedy decoding. Real services use FP16/FP8 and sampling. Anthropic's test on 96 real responses: 0 passed under strict rules. Relaxing rules admits almost any output.
Only verifies weight identity, not correctness : Truncated responses pass as shorter valid responses. Does not guarantee model wasn't "dumbed down" via early stopping or other manipulations.
Conclusion
FlashProve won't kill proxies immediately due to cost, context limits, missing trust infrastructure, and vendor adoption uncertainty. However, it demonstrates a viable direction: moving from pure trust to cryptographic verification. Proving cost dropped from "one day per response" to "minutes per response" on 400B-parameter models. If costs fall another 1–2 orders of magnitude and official APIs attach proofs, proxies substituting models will become instantly detectable by users.
Reference: https://www.anthropic.com/research/provable-inference
Code example
来源丨
经授权
转自
小林coding(ID:CodingLin)
作者
丨
小林codingSigned-in readers can open the original source through BestHub's protected redirect.
This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactand we will review it promptly.
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.
