mlsanityData to 14 Oct 2026

QTestBench: A Test Framework for Evaluating LLM-Generated Quantum Code

arXiv 2610.13811 ↗First posted 9 Oct 2026cs.LG cs.CL quant-phcited by 0

Not on the map. Why?

Abstract (arXiv)

Large language models (LLMs) have shown strong results in classical code generation and are increasingly used to write the unit tests that safeguard that code. Whether they can do the same for quantum software is less clear, because quantum programs are probabilistic, depend on numerical tolerances, and are judged by domain-specific checkers, so a well-formed test can still disagree with the benchmark's verdict. Existing quantum benchmarks measure whether a model produces a correct solution, but not whether its tests can distinguish correct implementations from faulty ones. We introduce QTestBench, a framework that evaluates LLM-generated quantum test suites against independent benchmark checkers, never treating the tests themselves as ground truth. For each task, QTestBench prompts models to produce syntactic, semantic, and behavioral tests, injects candidate solutions at runtime, and compares each test verdict with the checker's label under three validation cohorts, each answering a distinct diagnostic question. We benchmark five LLMs on eight PennyLane QHack challenges and ten Qiskit HumanEval tasks. Generated suites almost always execute, but discrimination lags behind: the best generator reaches a test quality of 0.71 on QHack and 0.34 on Qiskit HumanEval, so executability alone overstates test quality. Oracle-verified synthetic mutants stabilize bug-detection estimates when natural faulty solutions are scarce, as on three of ten Qiskit tasks that yield none. QTestBench offers a reproducible, cross-framework benchmark for the trustworthiness of LLM-generated quantum tests.

Key facts. No citing papers in the map yet (data through 14 Oct 2026). Builds on 17 of its 29 references that are in the map. First posted on arXiv 9 Oct 2026.

Builds on

17 of 29 references.

References · 17

  1. 2021Evaluating Large Language Models Trained on Codecited by 8,320
  2. 2021Program Synthesis with Large Language Modelscited by 3,637
  3. 2023StarCoder: may the source be with you!cited by 799
  4. 2020CodeBLEU: a Method for Automatic Evaluation of Code Synthesiscited by 479
  5. 2023Software Testing with Large Language Models: Survey, Landscape, and Visioncited by 166
  6. 2023CodeScore: Evaluating Code Generation by Learning Code Executioncited by 67
  7. 2024Qiskit HumanEval: An Evaluation Benchmark For Quantum Code Generative Modelscited by 30
  8. 2024Qiskit Code Assistant: Training LLMs for generating Quantum Computing Codecited by 25
  9. 2024Benchmarks and Metrics for Evaluations of Code Generation: A Critical Reviewcited by 20
  10. 2025QuanBench: Benchmarking Quantum Code Generation with Large Language Modelscited by 12
  11. 2025Enhancing LLM-based Quantum Code Generation with Multi-Agent Optimization and Quantum Error Correctioncited by 11
  12. 2025A PennyLane-Centric Dataset to Enhance LLM-based Quantum Code Generation using RAGcited by 9
5 more
  1. 2025QHackBench: Benchmarking Large Language Models for Quantum Code Generation Using PennyLane Hackathon Challengescited by 8
  2. 2025Assessing the Quality and Security of AI-Generated Code: A Quantitative Analysiscited by 7
  3. 2025QCoder Benchmark: Bridging Language Generation and Quantum Hardware through Simulator-Based Feedbackcited by 7
  4. 2018On Testing Quantum Programscited by 3
  5. 2026PennySynth: RAG-Driven Data Synthesis for Automated Quantum Code Generationcited by 1

Built on by

Not cited yet.