arXiv:2611.09822quant-phNov 2026

Manuscript Offprint

arXiv:2611.09822

Discovering formally verified quantum programs with AI

Sergey Shirobokov, Ben Jaderberg, Katerina Hristova, George Tsoukalas, Johannes Bausch, Eric Wieser, Francisco J. H. Heras, Nicholas C. Rubin, Guang Hao Low, Sébastien Racanière, Nenad Tomašev, Lei M. Zhang, James Watson, Tanuj Khattar, Aws Albarghouthi, Stavan Jain, Harun Khan, Leopoldo Sarra, Andrew W. Senior, Michael Broughton, Hussain Masoom, Sergio Boixo, Ryan Babbush, Swarat Chaudhuri, Pushmeet Kohli

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Sergey Shirobokov¹,†, Ben Jaderberg¹,†, Katerina Hristova‡, George Tsoukalas¹, Johannes Bausch¹*, Eric Wieser ①¹, Francisco J.H. Heras¹, Nicholas C. Rubin², Guang Hao Low², Sébastien Racanière¹, Nenad Tomašev¹, Lei M. Zhang¹, James Watson², Tanuj Khattar², Aws Albarghouthi‡, Stavan Jain‡, Harun Khan¹, Leopoldo Sarra¹, Andrew W. Senior¹, Michael Broughton², Hussain Masoom¹, Sergio Boixo², Ryan Babbush², Swarat Chaudhuri¹, and Pushmeet Kohli¹

¹Google DeepMind ²Google Quantum AI

November 9, 2026

The timeline by which quantum computers can solve breakthrough problems in science depends on improved quantum algorithms as much as on better hardware.¹,² Such algorithmic advances are typically achieved through many years of expert human collaboration.³,⁴ In mathematics and computer science, large language models have accelerated progress through automated discovery loops.⁵,⁶ However, quantum algorithms can only be evaluated by classical computers on restricted or small instances.⁷,⁸ Here we demonstrate automated discovery of quantum programs beyond these regimes including order-of-magnitude improvements on scientific applications. To achieve this, we build a quantum program library in the Lean theorem prover in which large language model agents synthesize novel programs against formal problem specifications and verify their correctness and cost. Agent teams collaborate, sharing results and knowledge through wikis and discussing ideas at organized conferences. Our results improve on prior baselines for parallel search⁹ (up to 1.4×), quantum arithmetic¹⁰ (290×), and simulations relevant to fusion, photochemistry and drug-metabolism by 11×, 8× and 2.5× respectively. Combining human and artificial intelligence at scale, under the rigor of mathematical proof, lets researchers design algorithms that today’s classical and quantum computers cannot test, shortening the path to practical quantum computation.

Quantum computers promise to tackle problems beyond classical reach across cryptanalysis,¹¹ optimization,¹² chemistry and drug discovery,¹³–¹⁵ materials science,¹⁶,¹⁷ and high-energy and plasma physics.¹⁸–²⁰ Many of the most promising applications are estimated to require a device with thousands of error-corrected (logical) qubits executing 10⁹ to 10¹⁵ logical operations,¹,²¹ well beyond the roughly one million operations projected for early fault-tolerant processors.² Beyond improvements in hardware and quantum error correction to build better logical qubits from noisy physical qubits,²² closing this gap relies on cumulative algorithmic resource reductions that lower qubit and gate counts.²³–²⁷ Historically, such reductions take sustained scientific effort over many years.³,⁴

Artificial intelligence (AI) offers a promising route to accelerate these improvements. Traditional machine learning has already been successfully applied to e.g. quantum hardware control,²⁸–³⁰ error-correction decoding,³¹

*Equal contributions. †Corresponding authors: shirobokov@google.com, benjaderberg@google.com. ‡These authors performed this work as research consultants on assignment at Google.

a) Discovery workflow

Figure

b) Research approaches and problems we consider

Figure

Figure 1: Formally verified multi-agent quantum program discovery. a) Researchers write a Lean quantum Hoare logic specification of correctness and cost, then launch their agent team, which iterates on error feedback from the Lean kernel. Teams publish independently re-verified solutions, partial results and dead ends to a shared wiki, and exchange ideas and critiques in scheduled conferences. b) Bars indicate which problem each approach can reach. AI search checked by numerical tests can only produce solutions that can be simulated classically (dashed line), which for arcsin means a restricted gate set.⁷

and small-scale circuit synthesis.³² While large language models (LLMs) are rapidly advancing mathematics and classical algorithms via execution-based search and automated reasoning⁵,³³⁻³⁹ as well as formal theorem proving for fixed conjectures,⁶,⁴⁰ their application to quantum computing lags behind due to the challenge of verifying general correctness without fault-tolerant hardware to test on. High-throughput validation of LLM-generated quantum programs has thus been restricted to circuit regimes that can be classically simulated,⁷,⁸ limiting the design space and scale of discovery (Fig. 1b), whereas concurrent LLM-assisted formalization has focused on verifying known algorithms (Appendix A). Bringing AI discovery to general quantum algorithms instead requires pairing formal models of quantum computation with mathematical proofs of correctness and cost, with access to tools such as numerical heuristics where they are effective. Formal reasoning is particularly critical when targeting asymptotic speedups and large-scale applications spanning thousands of qubits—just like scientists have reasoned about quantum algorithms over the past decades.

In this work, we introduce a Lean⁴¹ verification library based on quantum Hoare logic (QHL),⁴² engineer a multi-agent research workflow built around it, and prove new resource reductions across asymptotic algorithms and large-scale scientific simulations. Our library pairs a language for quantum programs and classical control flow with formal proofs of correctness and resource cost, chosen per specification. For fault-tolerant circuits we use the spacetime cost Q⋅TQ \cdot \mathcal{T}, the number QQ of qubits times the number T\mathcal{T} of TT gates, which are costly in error-corrected quantum computers.⁴³ Researchers launch heterogeneous teams of LLM agents that iterate on algorithms, and exchange concepts, partial results, and dead ends through a shared wiki and scheduled cross-team virtual conferences, while an independent verifier audits every proof against a frozen specification written in our library (Fig. 1a). Across five problems (Fig. 1b)—computing arcsin, parallel Grover search, cytochrome P450 energy levels, fusion alpha-particle stopping power and non-Born–Oppenheimer molecular dynamics—this workflow discovers new programs and circuits with machine-checked proofs of correctness and cost, reducing resource costs by 290×290\times for arcsin (combining classical and formal search), and by up to 10×10\times for our scientific applications compared to the strongest prior baselines (Fig. 3). Together, these advances shift researchers effort from manual circuit design, optimization, and resource tracking to problem specification and scientific interpretation.

Specification StoppingPower lean abbrev systemQubits : N := 3 * (218 * 6 + 8) def stoppingPowerAncillas : N := sorry noncomputable def stoppingPowerProgram (c : Configuration) (j : Fin 10) ... : DynamicCircuit Var n := sorry theorem stoppingPower_correctness ... : ∃ W : Unitary (2 ^ (systemQubits + stoppingPowerAncillas)) (∀ spinUp, ApproximatesTimeEvolution (hamiltonian c) (j.val + 1 : ℝ) 0.01 (fermionicProjector spinUp) W) ∧ RealizesUnitaryFromBasisOutcomesAndZeroWorkspace rSys gridStates rAnc hdisj W (stoppingPowerProgram c j ...).compile := by sorry def stoppingPowerConstCost : N := sorry theorem stoppingPower_const_cost ... : (∀ j, (stoppingPowerProgram c j ...).count .TOFF = 0) ∧ (systemQubits + stoppingPowerAncillas) * (50 * Σ j, (stoppingPowerProgram c j ...).count .T) ≤ stoppingPowerConstCost := by sorry

① 3,948 system qubits 218 electrons, each 3 × 6 qubits α²⁺ projectile, 3 × 8 qubits 216 protons are classical, set by c

② Unitary W approximates time evolution e⁻ⁱHt |ψ⟩ |0⟩⁺ⁿ W ≈ e⁻ⁱHt |ψ⟩|0⟩⁺ⁿ fermionic |ψ⟩, error ≤ 0.01

③ The compiled program realizes W |x⟩ |0⟩⁺ⁿ compiled program W|x⟩|0⟩⁺ⁿ |x⟩ any grid state

④ Program spacetime cost qubits · T gates ≤ claimed cost no Toffoli gates

Figure 2: Lean specifications for discovery tasks. An abridged specification for electronic stopping power in warm-dense hydrogen,⁴⁸ where the goal is to construct a quantum program that simulates time evolution under the system Hamiltonian H. The agents fill in each sorry statement, which is Lean's placeholder for an unfilled definition or proof: the ancilla qubit count, the circuit and its claimed cost, and the proofs of the correctness and cost theorems. (1) The system qubits store the momentum of every quantum particle. (2) A unitary matrix W on the system and ancilla qubits (extra qubits used to aid computation) must simulate time evolution e⁻ⁱH(c)t for every physically allowed electron state, up to a specified error, and return the ancillas to |0⟩. (3) The compiled program must act as W on grid states whenever the ancillas start in |0⟩. (4) The cost is a function of the logical spacetime volume Q · T multiplied by the repeated runs of the stopping power routine: 50 repeats × 10 time steps × Q · T (Sec. 2.3).

1. Formally Verified Multi-Agent Discovery

References (84)