QAgent:一种基于大语言模型的用于自主OpenQASM编程的多智能体系统
QAgent: An LLM-based Multi-Agent System for Autonomous OpenQASM programming
AI总结:
研究针对OpenQASM编程挑战提出QAgent,它是基于大语言模型的多智能体系统,集成规划、合成和校准工作流程,利用检索增强生成及多智能体推理确保正确性,在多模型评估中表现出色,证明集成对可靠量子程序生成很关键。
摘要:
在OpenQASM级别对量子电路进行编程对于在有噪声的中等规模量子(NISQ)设备上实现硬件感知优化和可靠执行至关重要,但由于需要特定领域规划、迭代代码合成和低级校准,这仍然具有挑战性。本文提出了QAgent,这是第一个用于端到端OpenQASM代码生成的自主多智能体框架。QAgent在统一的规划-合成-校准工作流程中集成了模式感知任务规划、示例和工具驱动的代码合成以及硬件感知校准。该系统利用检索增强生成(RAG)来访问结构化内核知识、示例和后端约束,并采用具有迭代执行反馈的协调多智能体推理来确保正确性。我们在五个大语言模型(LLMs)上对12个代表性量子内核及其组合进行了评估。结果表明,QAgent在单核任务上的Pass@1准确率提高了47-70%,在多核工作流程上对于大型模型的准确率超过88%,大大优于现有基线。此外,在实际硬件频率漂移情况下,QAgent通过自动校准保持接近单位的执行保真度,而基于软件开发工具包(SDK)的LLM方法则会显著下降。这些结果表明,集成规划、合成和校准对于可靠的量子程序生成至关重要。QAgent的实现已在该https URL上开源。
英文摘要:
Programming quantum circuits at the OpenQASM level is essential for achieving hardware-aware optimization and reliable execution on noisy intermediate-scale quantum (NISQ) devices, yet it remains challenging due to the need for domain-specific planning, iterative code synthesis, and low-level calibration. In this paper, we present QAgent, the first autonomous multi-agent framework for end-to-end OpenQASM code generation. QAgent integrates schema-aware task planning, example- and tool-driven code synthesis, and hardware-aware calibration within a unified planning-synthesis-calibration workflow. The system leverages retrieval-augmented generation (RAG) to access structured kernel knowledge, examples, and backend constraints, and employs coordinated multi-agent reasoning with iterative execution feedback to ensure correctness. We evaluate QAgent on 12 representative quantum kernels and their compositions across five large language models (LLMs). Results show that QAgent improves Pass@1 accuracy by 47-70% on single-kernel tasks and achieves over 88% accuracy on multi-kernel workflows for large models, substantially outperforming existing baselines. Furthermore, under realistic hardware frequency drift, QAgent maintains near-unit execution fidelity through automated calibration, whereas SDK-based LLM methods suffer significant degradation. These results demonstrate that integrating planning, synthesis, and calibration is critical for reliable quantum program generation. The implementation of QAgent is open-sourced at https://github.com/fuzhenxiao/QAgent
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。