Using LLMs for High-Assurance Crypto: A Lean Formal Verification Experiment

jedisct1 · x · 2026-10-22

Cryptography researcher mrosenberg recounts using LLMs on the Kopis key encapsulation scheme: routine AI optimizations left code 2–8x slower than rivals, and riskier optimizations (NTTs, vectorized multiplication, multi-lane hashing) were hard to review safely. The team's answer: add a formally verified Lean implementation, made feasible by LLMs recently getting good at writing Lean—strengthening the paper while guaranteeing correctness of aggressive optimizations.

Original post →

More from coding & agent

coding & agent channel →