Skip to content

Releases

qmutate v0.1.0

Choose a tag to compare

@rasidi3112 rasidi3112 released this 30 Oct 07:36

First public release of qmutate, a pre-alpha Python library for mutation testing of Qiskit quantum circuits. The API may change in later versions.

What is included

  • Mutation operator: removal of one top-level instruction (remove_instruction). This is the only operator in this release.
  • Mutant enumeration: generate_removal_mutants, one candidate per top-level instruction. Barriers and measurements are skipped unless allowed.
  • Running an oracle: run_removal_mutants runs your oracle on the original circuit first, then on every generated mutant, with the outcomes killed, survived, error and not_run.
  • Metrics and reports: mutation score and MutationMetrics, report_to_dict (report schema version 1) and format_text_report.
  • Equivalence checks: check_equivalence and classify_report with the unitary and ideal_distribution models, verdicts equivalent, not_equivalent and unknown, and an equivalence-adjusted score.
  • Sampling: compare_counts and distribution_oracle, a finite-shot sampling oracle whose verdicts carry statistical guarantees under stated assumptions.

Research artefacts

The evaluation/ directory holds the Phase 6A study: six circuits, a frozen catalogue of 70 hand-written faults and six test suites, run under a frozen protocol (revision 9) and an approved code freeze on Qiskit 2.6.1 and 2.0.3, with identical results in both. Under the protocol's decision rules H1 and H3 were supported and H4 was not. These results apply only to that catalogue; see evaluation/REPORT.md for every metric and the known limitations.

Requirements and verified versions

  • Python >=3.11 and qiskit>=2.0,<3.
  • Verified on macOS arm64: Python 3.11 with Qiskit 2.0.3 and 2.6.1 (all 803 tests), Python 3.11 with Qiskit 2.0.0 and 2.3.1 (the 632 library tests), and Python 3.13 and 3.14 with Qiskit 2.6.1 (the 632 library tests). Linux, Windows and Python 3.12 are not verified yet.

Installation

qmutate is not on PyPI. Install it from source:

git clone https://github.com/rasidi3112/qmutate.git
cd qmutate
python -m pip install -e ".[test]"

License

Apache License 2.0.