Classical software engineering has been shaped by learned code representations, where approaches such as code2vec, CodeBERT, and recent large-scale code models support tasks including clone detection, structural anomaly detection, and code search. Quantum software engineering, however continues to build primarily on syntactic and rule-based techniques. Existing representations and tools such as QChecker, NiCad for quantum programs, and LintQ apply pattern matching and static analysis but they do not capture program-level semantics across circuits. Essentially, these representations are not designed for Aritificial Intelligence and Large Language Model pipelines for quantum software engineering. We present QuantumCode2Vec, a learned representation of quantum programs that captures structural patterns at the level of algorithmic behavior. Driven by the impact of code2vec, the approach decomposes quantum circuits into quantum-aware paths that reflect qubit evolution, entanglement structure, and circuit properties, and aggregates them through attention into fixed length representations and embeddings. Across canonical quantum algorithms, the learned representations group circuits by algorithm, remain stable under superficial changes, and generalize across circuit sizes. In a retrieval setting, similar circuits consistently correspond to the same algorithm, supporting semantic clone detection and code search. In this paper, our goal is to position QuantumCode2Vec as a fundamental learned representation and emedding for quantum software engineering.
Classical software engineering has been shaped by learned code representations, where approaches such as code2vec, CodeBERT, and recent large-scale code models support tasks including clone detection, structural anomaly detection, and code search. Quantum software engineering, however continues to build primarily on syntactic and rule-based techniques. Existing representations and tools such as QChecker, NiCad for quantum programs, and LintQ apply pattern matching and static analysis but they do not capture program-level semantics across circuits. Essentially, these representations are not designed for Aritificial Intelligence and Large Language Model pipelines for quantum software engineering. We present QuantumCode2Vec, a learned representation of quantum programs that captures structural patterns at the level of algorithmic behavior. Driven by the impact of code2vec, the approach decomposes quantum circuits into quantum-aware paths that reflect qubit evolution, entanglement structure, and circuit properties, and aggregates them through attention into fixed length representations and embeddings. Across canonical quantum algorithms, the learned representations group circuits by algorithm, remain stable under superficial changes, and generalize across circuit sizes. In a retrieval setting, similar circuits consistently correspond to the same algorithm, supporting semantic clone detection and code search. In this paper, our goal is to position QuantumCode2Vec as a fundamental learned representation and emedding for quantum software engineering.
Software developers often spend more time reading and understanding existing source code than writing new code. As a result, improving code comprehensibility can significantly enhance software development and maintenance by reducing the cognitive effort required to grasp program functionality. Code comments play a critical role in this process, helping developers navigate and maintain software more efficiently. However, numerous software projects suffer from missing, outdated, or inconsistent comments, forcing developers to infer functionality directly from the code. The design of programming languages also impacts code comprehension; as previous research suggests; different programming paradigms influence the ease with which developers understand code. This insight has driven researchers to explore machine learning (ML) and deep learning (DL) techniques for a variety of software engineering tasks, including testing, vulnerability detection, and source code analysis. Given the rapid growth in this research area, it has become increasingly difficult for the community to keep track of existing approaches and environments. Recently, ML and DL techniques have been widely adopted for tasks such as source code representation, quality analysis, and automated testing. In this paper, we introduce a novel quantum deep learning method that demonstrates superior performance over classical approaches in the comprehension of source code. Our approach highlights the potential of quantum computing to enhance machine learning techniques applied in the software engineering domain.
The work aims to enable the use of common software engineering techniques and tools for quantum programming languages (e.g., OpenQASM). With the increased interest in quantum computing, researchers are adopting the use of higher-level quantum programming languages versus low-level circuit diagrams. While general purpose programming languages (e.g., C++, Python) are highly supported by a variety of software engineering tools, these novel programming languages for quantum computing have almost no support. Useable tools for debugging, static analysis, error detection, and transformation are currently non-existent. This work extends an existing software infrastructure (i.e., srcML) for the analysis, exploration, and manipulation of source code to OpenQASM. The srcML infrastructure, via parsing, generates abstract syntax information of programs to support high-level querying and analysis of the source code. With this, quantum developers can extract information and identify possible errors or inefficiencies in their programs. The paper presents the basic syntactic markup for OpenQASM. Also, a number of relevant quantum-based problems (e.g., iteration patterns, control recursion) are described and examples of how they are addressed using srcML are given.
Abstract The field of Quantum Computing (QC) is advancing rapidly, introducing new programming paradigms and frameworks. This rapid growth also increases the vulnerability of quantum programs (QPs) to bugs and code smells. Despite considerable research, detecting code smells in QPs remains underexplored. To bridge this gap, this paper presents QUAMET , a novel structural and semantic analysis approach designed to establish software metrics for QPs and detect quantum code smells. Structural analysis examines code structure and program architecture, focusing on rules and patterns essential for identifying code smells. Semantic analysis, utilising quantum circuit analysis and parse trees, explores the meaning of the code. The study used a publicly available LintQ dataset, which contains real-world QPs implemented with Qiskit. After thorough pre-processing, the dataset was refined to extract structural and semantic metrics, resulting in a labelled dataset of 4,102 projects. This dataset is instrumental in identifying six distinct types of code smells, reviewed by industry and academic experts. The dataset and metrics are validated using reviews and classifications, demonstrating significant advancements in detecting quantum code smells. The results highlight the importance of combining structural and semantic analyses to enhance code smell detection accuracy, providing insights into their potential impact on QPs' performance and maintainability.
We propose a learning-based approach to quantum compilation by translating OpenQASM to Quantum Intermediate Representation (QIR) using a fine-tuned CodeBERT model. Trained on 10,000 synthetic QASM-QIR pairs, the model captures code semantics while addressing QIR verbosity and the 512-token limit via a custom token compression scheme. Finetuning was performed on the Frontier supercomputer, with results showing syntactic correctness and stable validation loss reduction. Our method moves toward enabling flexible, language-modeldriven quantum software tools. It also introduces syntax error handling and the possibility of incorporating classical control constructs, addressing limitations in existing rule-based compilers like qBraid-QIR. While the current model has been validated on quantum-only circuits, we propose future evaluations on hybrid quantum-classical examples. This poster will provide architecture insights, compression examples, training loss plots, and QIR outputs. Our work highlights the potential for scalable, adaptable compilation in future quantum toolchains.
Quantum computing has demonstrated the potential to solve computationally intensive problems more efficiently than classical methods. Many software engineering tasks, such as test case selection, static analysis, code clone detection, and defect prediction, involve complex optimization, search, or classification, making them candidates for quantum enhancement. In this paper, we introduce Quantum-Based Software Engineering (QBSE) as a new research direction for applying quantum computing to classical software engineering problems. We outline its scope, clarify its distinction from quantum software engineering (QSE), and identify key problem types that may benefit from quantum optimization, search, and learning techniques. We also summarize existing research efforts that remain fragmented. Finally, we outline a preliminary research agenda that may help guide the future development of QBSE, providing a structured and meaningful direction within software engineering.
Although most software engineering work today targets classical systems, quantum computing has become an area of growing interest for developers who want to understand alternative computational models. This thesis addresses the difficulty of learning to construct and reason about quantum circuits by focusing on small, illustrative circuit-based algorithms (Bell states, GHZ states, and a reduced Grover’s search) as structured examples around which an interactive learning platform is built. The aim is to support step-by-step understanding of these circuits while investigating how large language models (LLMs) can assist with circuit generation and explanation. The work presents a web-based platform that allows users to incrementally build circuits, visualize their layer-by-layer evolution, and inspect key properties such as gate composition and measurement probabilities. On top of this platform, two LLM-based assistance strategies are implemented: a stateless baseline that operates solely on naturallanguage prompts, and a context-aware, agentic mode that receives structured information about the current circuit and simulation results. Their behavior is compared in an offline evaluation on a fixed set of exemplar tasks, using a rubric that scores correctness of the resulting circuits, relevance of explanations to the actual circuit, and pedagogical clarity. The results indicate that the agentic, state-aware integration produces more accurate, better-grounded, and more instructionally useful outputs than the stateless baseline on the examined tasks. The thesis contributes an example-driven approach to quantum computing education for software engineers, an inspection-oriented platform design, and empirical evidence that platform-state-aware LLM agents can provide higher-quality assistance than purely prompt-based interaction in this domain.