Designing quantum algorithms is a complex and counterintuitive task, making it an ideal candidate for AI-driven algorithm discovery. To this end, we employ the Hive, an AI platform for program synthesis, which utilises large language models to drive a highly distributed evolutionary process for discovering new algorithms. We focus on the ground state problem in quantum chemistry, and discover efficient quantum heuristic algorithms that solve it for molecules LiH, H2O, and F2 while exhibiting significant reductions in quantum resources relative to state-of-the-art near-term quantum algorithms. Further, we perform an interpretability study on the discovered algorithms and identify the key functions responsible for the efficiency gains. Finally, we benchmark the Hive-discovered circuits on the Quantinuum System Model H2 quantum computer and identify minimum system requirements for chemical precision. We envision that this novel approach to quantum algorithm discovery applies to other domains beyond chemistry, as well as to designing quantum algorithms for fault-tolerant quantum computers.
Figures & tables
Figure 1: Overview of AI algorithm discovery frameworks. The system samples high-performing programs from a programs database that serve as the basis for improvements proposed by an LLM. New programs are evaluated in a sandbox to generate a quantifiable performance score, and both the program and its score are stored in the programs database to use in future iterations.
Figure 2: VQE-style quantum algorithms. This family of quantum algorithms is defined by two components: a parametrised quantum circuit and a classical optimisation step. The aim is to find the ground state of a molecule, so we seek a trial state that yields the lowest eigenvalue of the molecule’s Hamiltonian. We first define the Hamiltonian of a molecule in a chosen basis and at a given geometry, the initial state, typically the Hartree–Fock state, and an operator pool {Oi(θi)} . These parameterised operators are used by the classical optimisation step to generate an ansatz and update its parameters. The trial state is evaluated, and based on the results, the classical step updates the ansatz and its parameters iteratively in a feedback loop.
Figure 3: Quantum algorithm discovery workflow. An application of the workflow shown in Fig. 1 to the quantum algorithm skeleton shown in Fig. 2 . The Hive is provided with a problem skeleton and information about the molecule at hand, which contains basic code to construct and evaluate quantum operators implemented by InQuanto . It is also given a generic prompt that contains a basic description of the molecular ground-state problem in quantum chemistry. The candidate algorithms are evaluated on a backend, a quantum computer, or a classical simulator or emulator, which returns the energy value that serves as the main objective for the Hive to optimise.
General Prompt
You are an expert in NISQ quantum computation, variational/heuristic quantum algorithms, and quantum chemistry. The project focuses on determining the ground state energy of H 2 O in STO-3G using a UCCSD operator pool (single and double excitations). Your objective is to achieve chemical precision (1.6 mHa) over bond lengths from 1.0 Å to 3.0 Å. Use InQuanto for molecular data, CUDA-Q for quantum circuit execution, and OpenFermion for electronic structure information. Backends are expensive: any approach that increases backend calls will be rejected . The main scoring metric is how well the solution reaches chemical precision across all bond lengths (via ChemistryDriverPySCFMolecularROHF with point_group_symmetry=True ). General implementation hints include caching, classical pre-filtering ( score_excitation ), parametrised kernels, deterministic reproducibility, efficient ansatz construction, and adaptive optimisation near convergence. Reuse the provided _evaluate_ansatz_energy function, which manages caching and asynchronous execution.
Table 1: Example layout of a structured natural language prompt for a quantum chemistry optimisation workflow, demonstrated on the H 2 O molecule in the STO-3G basis using a qubit excitation operator pool. The Table summarises the hierarchical prompt composition: first defining the global objective (chemical-precision ground state energy estimation) and implementation constraints, followed by incremental heuristic strategies enhancing efficiency and variational performance in NISQ-era simulations.
Figure 4: Energy precision of bond dissociation curves obtained with the Hive algorithms and ADAPT baselines as a function of bond length. a – c , Bond dissociation curves (top panels) and energy errors relative to FCI (bottom panels) for LiH ( a ), H 2 O ( b ), and F 2 ( c ). Hive results are shown as red circles, ADAPT-VQE and QEB-ADAPT-VQE are shown as blue squares and green pentagons, respectively. Hollow markers indicate the specific bond lengths used in the evolution of the Hive ansatz, while solid markers represent test points evaluated using the evolved algorithms. The dashed grey line in the error plots marks the chemical precision threshold ( 1.6\times10−3Ha ). Bond length for LiH denotes the Li–H distance; for H 2 O, the O–H bond length (with both O–H bonds stretched symmetrically); and for F 2 , the F–F distance.
Figure 5: Quantum resource overhead of the Hive algorithms and ADAPT baselines for different molecules. Scaling of variational parameters (top row), total circuit evaluations (exact statevector energy evaluations, middle row), and two-qubit gate counts (after compilation to the Quantinuum H2 native gate set, bottom row) for LiH ( a ), H 2 O ( b ), and F 2 ( c ). Hive results are shown as red circles, ADAPT-VQE and QEB-ADAPT-VQE are shown as blue squares and green pentagons, respectively. Points where algorithms failed to converge to energy error below chemical precision E−EFCI≤1.6mHa are omitted from the plots. Bond lengths follow the definitions in Fig. 4 .
Figure 6: LiH ablations and mechanism-level interpretability of the Hive -evolved algorithm. ( a–c ) Progressive ablation study for LiH (12 qubits) across bond lengths. Bars show the performance of the mechanism ladder (L0 Basic → L1 Scoring → L2 Growth → L3 Optimisation → L4 Refinement → L5 Compression) for energy error ( a ), circuit evaluations ( b ), and two-qubit gate count ( c ), with colours matching the ladder levels. Horizontal blue (green) lines denote ADAPT-VQE (QEB-ADAPT-VQE) results at the same geometries. The dashed horizontal line and shaded region indicate the chemical-precision band; resource panels report only configurations that meet the precision threshold E−EFCI≤1.6mHa . ( d ) Single pseudocode block showing the ablation level L∈{0,1,2,3,4,5} , where higher levels activate additional branches (colour-coded as in a–c ). Symbols: M molecular data at fixed geometry; R bond length; A current operator set (ansatz); θ current parameter vector; E current energy; P fixed operator pool; C candidate queue; s operator score; o∈C candidate operator; t growth-iteration index; T maximum growth iterations; θ0 initial angle for the newly proposed operator; θ⋆ updated angle returned by the local update; E′ trial energy after the local update; ΔE(o)=E−E′ per-append energy improvement; τ acceptance threshold; lmin minimum enforced ansatz length.
Figure 7: Robustness and error mitigation effectiveness of the LiH Hive algorithm and (QEB-)ADAPT-VQE on noisy emulator and hardware. The left panel displays results for ADAPT-VQE (blue squares) and QEB-ADAPT-VQE (green pentagons), while the right panel shows the Hive algorithm (red circles). Results are presented for three noise regimes: unmitigated emulator results (Raw, dashed lines), mitigated results using Partition Measurement Symmetry Verification (PMSV, lighter solid lines), and a Forecast model (darker solid lines). Additionally, we present experimental data obtained from the Quantinuum H2-1 hardware (red star at 2.0A˚ ). The Forecast model utilizes Quantinuum H2-1 Emulator parameters quantinuum_hardware_2025 (2025) with single-qubit error rates tuned from 10−5 to 10−7 and two-qubit error rate tuned from 10−3 to 10−5 . Memory errors in this model are improved by a factor of 2–4. The horizontal dashed grey line marks the chemical precision threshold. All points use a fixed shot budget per measurement circuit of 104 shots, and error bars are obtained by bootstrap resampling. Bootstrap error bars appear geometrically asymmetric on logarithmic scales due to the non-linear mapping of the y-axis.
Appendix figures & tables2 assets
Supplementary material from the paper’s appendix.
Appendix
Figure 8: H 2 O ablations and mechanism-level interpretability of the Hive -evolved algorithm. ( a–c ) Progressive ablation study for H 2 O (14 qubits) across bond lengths. Bars show the performance of the mechanism ladder (L0 Basic → L1 Scoring → L2 Growth → L3 Optimisation → L4 Refinement → L5 Compression) for energy error ( a ), circuit evaluations ( b ), and two-qubit gate count ( c ), with colours matching the ladder levels. Horizontal blue (green) lines denote ADAPT-VQE (QEB-ADAPT-VQE) results at the same geometries. The dashed horizontal line and shaded region indicate the chemical-precision band; resource panels report only configurations that meet the precision threshold E−EFCI≤1.6mHa . ( d ) Single pseudocode block showing the ablation level L∈{0,1,2,3,4,5} , where higher levels activate additional branches (colour-coded as in a–c ). Symbols: M molecular data at fixed geometry; R bond length; k outer self-training-cycle index; K(L) maximum number of outer training cycles; op_type operator-pool family used in the current outer cycle; P operator pool for the current outer cycle; C candidate queue; C′ temporary working head slice used in the current selection step; s operator score; m(R) bond-length-dependent head-slice size; A current operator set (ansatz); ∣A∣ current ansatz length; ls singles-first warmup cutoff; o∈C candidate operator; Θ test-angle set for the proposed operator; θ current parameter vector; θ⋆ selected/refined angle for the newly proposed operator; E current energy; E′ trial energy after appending o at θ⋆ ; ΔE(o)=E−E′ per-append energy improvement; τ acceptance threshold; t per-cycle growth-iteration index; T maximum selection iterations.
Figure 9: F 2 ablations and mechanism-level interpretability of the Hive -evolved algorithm. ( a–c ) Progressive ablation study for F 2 (20 qubits) across bond lengths. Bars show the performance of the mechanism ladder (L0 Basic → L1 Scoring → L2 Growth → L3 Optimisation → L4 Refinement → L5 Compression) for energy error ( a ), circuit evaluations ( b ), and two-qubit gate count ( c ), with colours matching the ladder levels. Horizontal blue (green) lines denote ADAPT-VQE (QEB-ADAPT-VQE) results at the same geometries. The dashed horizontal line and shaded region indicate the chemical-precision band; resource panels report only configurations that meet the precision threshold E−EFCI≤1.6mHa . ( d ) Single pseudocode block showing the ablation level L∈{0,1,2,3,4,5} , where higher levels activate additional branches (colour-coded as in a–c ). Symbols: M molecular data at fixed geometry; r bond length; A current operator set (ansatz); ∣A∣ current ansatz size; θ current parameter vector; E current energy; Ebest best energy seen so far; P operator pool; C candidate queue; s(o) operator score; o candidate operator; o⋆ look-ahead-selected operator; B look-ahead batch size; θtest look-ahead test angle; E⋆ energy after look-ahead seeding; θ⋆ updated angle returned by the 1D local append update; E′ trial energy after appending o ; ΔE(o)=E−E′ per-append energy improvement; ε score cutoff; K queue truncation size; nacc number of accepted operators; Tops maximum accepted-operator budget; passes current pass count; Pmax maximum number of passes.
Quantum state preparation is a key component of many quantum algorithms. Performing this step efficiently is essential for realizing practical quantum advantage in quantum chemistry applications. Iterative algorithms like ADAPT-VQE can produce shallow ground-state preparation circuits, but become computationally prohibitive for the larger molecules relevant to materials science and pharmaceutical development. Here, we introduce ADAPT-GQE, a generative AI framework that learns to synthesize ground-state preparation circuits for electronic structure calculations. We first use ADAPT-VQE to generate high-quality reference circuits, which are then used as targets for training models for circuit generation. Once trained, the model can efficiently propose and score circuits, enabling reinforcement learning (RL) to drive circuit generation accuracy beyond the accuracy of the ADAPT-VQE training data. This pipeline achieves order-of-magnitude reductions in circuit generation time relative to ADAPT-VQE while maintaining comparable or improved state-preparation accuracy. We demonstrate ADAPT-GQE on imipramine, a well-established tricyclic antidepressant that serves as a representative, challenging target for computational modelling in drug stability protocols. We execute generated circuits on Quantinuum Helios-1, representing a milestone for AI-generated quantum chemistry circuits on state-of-the-art quantum hardware. These results establish a pathway toward automated quantum circuit synthesis for utility-scale quantum computational chemistry.
Alex Koziell-Pipe, Jasmine Brewer, Jem Guhit +14
1Quantinuum, London, UK. · 3NVIDIA Corporation, Santa Clara, CA, USA. · 2Quantinuum, Cambridge, UK. +2
Quantum chemistry simulations underpin modern materials discovery, yet their impact is limited by steep computational cost and dependence on fixed approximation schemes. Foundation models, such as machine-learned interatomic potentials, have accelerated parts of this workflow, but their reliance on large-scale pretraining restricts adaptability at the frontier of chemical space, where methodological innovation and sparse data are the norm. Agentic AI systems can automate existing simulation pipelines, yet they remain constrained by the predefined tools and algorithms they orchestrate. In response, we introduce LADeQ, an LLM-guided workflow that discovers, implements, and benchmarks candidate approximation algorithms at test-time within existing quantum chemistry codes. Rather than selecting from a predefined repertoire, LADeQ constructs candidate approximation schemes on demand, drawing on techniques from disciplines such as spatial statistics, circuit simulation, and kernel methods that have had little prior presence in electronic-structure theory. Because it builds on an out-of-the-box language model, LADeQ requires no task-specific pretraining or curated data, and the resulting implementations are transparent and inspectable, with explicitly traceable approximation errors that enable principled control of accuracy--efficiency trade-offs. We show that LADeQ accelerates coupled cluster singles and doubles (CCSD) and configuration interaction singles and doubles (CISD) calculations while keeping correlation-energy errors within user-specified tolerances, demonstrating autonomous, objective-driven discovery of approximation algorithms inside existing electronic-structure solvers.
Masaya Hagai, Yuta Suzuki, Tomoya Murata +2
Lattice Lab, Toyota Motor Corporation · Department of Chemistry, Graduate School of Science, Nagoya University · National Institute of Informatics
The design of high performing quantum circuits remains largely dependent on human expertise. We introduce an autonomous agentic framework that employs large language models (LLMs) to conduct iterative quantum circuit designs under explicit design constraints. Our system integrates seven components: Exploration, Generation, Discussion, Validation, Storage, Evaluation, and Review. These components form a closed-loop workflow that combines web-based knowledge acquisition, literature-grounded critique, executable code generation, and experimental feedback. We evaluate the framework on two tasks: quantum feature map construction for quantum machine learning and ansatz generation for variational quantum eigensolver applications in quantum chemistry. In image classification benchmarks, the best generated feature map outperforms representative quantum feature maps and, when scaled to larger qubit counts, surpasses the classical radial basis function kernel. In molecular ground state estimation across seven molecules, the generated ansatz attains competitive accuracy with widely used chemically inspired and hardware-efficient constructions while satisfying the imposed scaling constraints. These results establish LLM driven agentic system as a viable paradigm for automated quantum circuit design and illustrate how AI systems can participate in iterative scientific optimization workflows across scientific domains.
Kenya Sakka, Wataru Mizukami, Kosuke Mitarai
Center for Quantum Information and Quantum Biology, The University of Osaka, 1-2 Machikaneyama, Toyonaka 560-0043, Japan · Graduate School of Engineering Science, The University of Osaka 1-3 Machikaneyama, Toyonaka, Osaka 560-8531, Japan