Quantum code review

AI writes quantum code. qcheck reviews it.

A review layer for AI-generated Qiskit and OpenQASM.

Catch the avoidable before code reaches humans, CI, or simulators.

$ qcheck verify bell.py
# static review, no execution
pass QuantumCircuit + measurement
flag execute() removed in Qiskit 1.0
flag Aer import removed
# 1 passed · 2 flagged

Get started

Run a local review

Install qcheck-quantum from PyPI, then review your file:

pip install qcheck-quantum
qcheck verify your-circuit.py --json

The CLI and GitHub Action are free and open source. qcheck reviews your code locally without executing it or sending telemetry.

Agent and CI examples

Signals

What qcheck reviews

qcheck v0 reviews static signals — no execution required, so it runs safely on untrusted model output inside an agent loop or CI.

Qiskit

API usage

Flags removed-in-1.0 imports like execute() and Aer, and deprecated gate aliases.

OpenQASM

Parse issues

Header, register declarations, index ranges, and measurement validity.

Safety

Unsafe patterns

Filesystem, network, process, or dynamic-exec constructs are flagged before anything runs.

Structure

Missing measurements

Common mistakes that make a circuit fail or return nothing useful.

Models

Common LLM mistakes

The recurring errors models make in generated quantum snippets.

Review

A review, not a verdict

Each snippet returns a set of signals — passed or flagged — that a developer or agent can act on before the code runs.

modern_qiskit_apino removed 1.0 imports
declared_registersqreg / creg present, in range
has_measurementcircuit measures qubits
execute_removedexecute() removed in Qiskit 1.0
unsafe_side_effectwrites to disk
3 passed · 2 flagged

Scope

What it does — and doesn't

In scope

  • Static review of Qiskit / OpenQASM snippets
  • Common, avoidable failures
  • CI and agent preflight
  • Machine-readable JSON output

Not in scope

  • Hardware execution
  • Algorithm correctness or formal proof
  • PQC migration

Benchmark

Static review benchmark

Tracks how AI-generated snippets perform against qcheck's current static review checks. It reports static_pass_rate on a small public task set as an early quality signal. Rows marked SAMPLE are demo data.

#ModelProviderStatic pass ratePassed / AttemptedUnsafeqcheck
1demo-model SAMPLEsample50.0%3 / 61v0.1.0

Real runs will include provenance, task counts, qcheck version, and prompt hash. See the methodology.

Roadmap

Where it is going

Available

CLI & GitHub Action

Static review for Qiskit, OpenQASM, PennyLane and Cirq, with JSON and SARIF output.

Planned

MCP

An agent-callable interface to static review.

Under evaluation

Hosted verification

Reproducible checks and checked repairs for a defined task contract. Not available as a self-service product today.

Pilot enquiry

Have a recurring quantum-code failure?

Tell us what fails in your agent or CI workflow and what evidence you need to trust a correction.

Start with a non-confidential summary. We will agree the scope, deliverables and price before accepting payment. Hosted verification and checked repairs are being evaluated; this is a pilot enquiry, not access to an available hosted service.

Discuss a paid pilot