paperbot · PL 论文追踪

全部论文 待读 收藏

P2 QuanBench: Benchmarking Quantum Code Generation with Large Language Models

QuanBench:用大语言模型基准测试量子代码生成
ASE 2025 40th IEEE/ACM International Conference on Automated Software Engineering (ASE)2025匹配度 2/10 · 论文聚焦量子代码生成基准与 LLM 评测,属于 LLM+编程语言/代码生成方向,但未涉及静态分析、形式化验证、浮点或贝叶斯程序分析等用户核心方向;量子领域也非画像关注点。引用 4 inbox
Xiaoyu Guo, Minggu Wang, Jianjun Zhao
crossref: 2026-09-12

AI 速览

一句话:提出 QuanBench 基准,用 44 个量子编程任务评测 LLM 的量子代码生成能力,发现正确率不足 40%。

大语言模型在通用代码生成上表现良好,但其量子代码生成能力尚缺乏系统研究。本文提出 QuanBench,一个用于评测 LLM 量子代码生成能力的基准,包含 44 个编程任务,覆盖量子算法、态制备、门分解与量子机器学习。每个任务都配有可执行的规范解答,并从功能正确性(Pass@K)与量子语义等价性(Process Fidelity)两个维度进行评估。作者评测了若干近期模型,包括通用模型与代码专用模型。结果显示,当前 LLM 生成正确量子代码的能力有限,总体准确率低于 40%,且频繁出现语义错误。论文还分析了常见失败案例,如使用过时 API、电路构造错误以及算法逻辑错误。QuanBench 为未来改进 LLM 量子代码生成研究提供了基础。

问题
现有 LLM 在通用代码生成上表现良好,但其量子代码生成能力缺乏系统性的评测基准与研究。
方法
构建 QuanBench 基准,含 44 个覆盖量子算法、态制备、门分解与量子机器学习的任务,每个任务提供可执行规范解,并以 Pass@K 与 Process Fidelity 评测多个通用及代码专用 LLM。
评估
在多个近期 LLM 上运行基准,报告总体准确率低于 40% 并归纳过时 API、电路构造错误、算法逻辑错误等失败模式。
原文摘要(Abstract)

Large language models (LLMs) have demonstrated good performance in general code generation; however, their capabilities in quantum code generation remain insufficiently studied. This paper presents QuanBench, a benchmark for evaluating LLMs on quantum code generation. QuanBench includes 44 programming tasks that cover quantum algorithms, state preparation, gate decomposition, and quantum machine learning. Each task has an executable canonical solution and is evaluated by functional correctness (Pass@K) and quantum semantic equivalence (Process Fidelity). We evaluate several recent LLMs, including general-purpose and code-specialized models. The results show that current LLMs have limited capability in generating the correct quantum code, with overall accuracy below 40% and frequent semantic errors. We also analyze common failure cases, such as outdated API usage, circuit construction errors, and incorrect algorithm logic. QuanBench provides a basis for future work on improving quantum code generation with LLMs.

链接与引用

DOI 原文 ·

BibTeX
@inproceedings{paperbot9536,
  title = {QuanBench: Benchmarking Quantum Code Generation with Large Language Models},
  author = {Xiaoyu Guo and Minggu Wang and Jianjun Zhao},
  booktitle = {ASE},
  year = {2025},
  doi = {10.1109/ase63991.2025.00218}
}