A Reinforcement Learning Environment for Directed Quantum Circuit Synthesis

Michael Kölle, Tom Schubert, Philipp Altmann, Maximilian Zorn, Jonas Stein, Claudia Linnhoff-Popien

Researchers at LMU Munich have introduced a novel reinforcement learning (RL) environment designed to automate Directed Quantum Circuit Synthesis (DQCS). By framing the construction of quantum circuits as a sequential decision-making task, the study demonstrates how RL agents can discover efficient, hardware-ready state preparation circuits, potentially replacing the manual, non-scalable methods currently used by quantum programmers.

The Challenge of State Preparation

In quantum computing, state preparation involves transforming a standard initial state (typically $|00...0\rangle$) into a specific target state required for an algorithm. This process faces two primary hurdles:

  1. Combinatorial Complexity: The number of possible circuit layouts grows exponentially with the number of qubits and gates, making the search for an optimal sequence extremely difficult.
  2. Hardware Noise: Real-world quantum hardware is susceptible to decoherence. Every additional gate increases the error rate, necessitating the discovery of the "shallowest" (shortest) possible circuits to maintain fidelity.

Methodology: DQCS as a Markov Decision Process

The researchers formulated the synthesis task as a Markov Decision Process (MDP), enabling the use of standard RL algorithms. The environment, built using the Pennylane framework, provides agents with observations of the current and target quantum states represented as real vectors of complex coefficients.

Action Space and Gate Sets

To ensure portability to real hardware, the agent is restricted to the Clifford+T gate set. The action space is "multi-discrete": the agent first selects a gate type and then chooses the qubits to which it should be applied. This prevents bias toward gates that can be applied to more qubit pairs.

The Clifford+T gate set used as the action space for the RL agent, including matrix representations and circuit notation.

Algorithms and Rewards

The study benchmarked Proximal Policy Optimization (PPO) against Advantage Actor-Critic (A2C). PPO proved significantly more stable. Interestingly, the researchers found that a simple "step-penalty" reward—penalizing the agent for every gate used until the target is reached—was more robust than complex distance-based rewards based on state fidelity.

Key Results and Scaling

In 2-qubit benchmarks, the PPO agent demonstrated remarkable efficiency, finding the mathematically minimal circuits for Bell states with 96% to 100% probability. On average, PPO achieved a "Reconstructed Circuit-Depth" of approximately 112%, meaning the discovered circuits were nearly as short as the ground-truth targets used for training.

However, the study also highlighted the "curse of dimensionality." As the number of qubits increases, the performance of the agents begins to degrade, as shown in the scaling analysis below.

Reconstruction circuit depth performance across different qubit counts, illustrating how agent efficiency decreases as the system size grows.

Insights and Future Directions

Several key insights emerged from this work:

  • Vector Representation: Using vector representations of states instead of density matrices reduced computational costs by lowering dimensionality from $N^2$ to $N$.
  • Specialization: Agents trained on specific circuit depths ($\lambda$) performed best at those levels, suggesting that a "curriculum" of increasing difficulty is necessary for general-purpose synthesis.
  • Hardware Native Output: By using the Clifford+T set, the resulting circuits do not require further transpilation, which often introduces additional gate overhead on fault-tolerant architectures.

Future work will focus on overcoming scaling limits through Curriculum Learning and integrating parameterized gates (e.g., $RX(\theta)$) to support Variational Quantum Eigensolvers (VQE).

Summary updated

BibTeX
@inproceedings{kolle2024reinforcement,
  author = {Michael Kölle and Tom Schubert and Philipp Altmann and Maximilian Zorn and Jonas Stein and Claudia Linnhoff-Popien},
  title = {{A Reinforcement Learning Environment for Directed Quantum Circuit Synthesis}},
  booktitle = {ICAART},
  year = {2024},
  doi = {10.5220/0012383200003636},
}
Figure