XQuad is a hardware-agnostic toolchain for expressing and running quadratic optimization problems across quantum annealers and classical solvers.
The tool addresses the fragmentation of quantum and classical optimization backends by providing a common intermediate representation—analogous to LLVM for quadratic models. Users write a problem once in a standardized format and retarget it to any supported backend without rewriting. The approach centers on a formal virtual-machine specification with cross-implementation parity mechanically enforced in CI: every conformance vector runs on both the production Rust VM and a Python reference VM, and disagreement fails the build. The Rust core supports `no_std + alloc`, enabling deployment inside WASM runtimes, Substrate pallets, and native binaries. The Python umbrella provides an interactive API with `Program`, `Session`, and `RunResult` objects designed for REPL and Jupyter workflows, allowing users to load a program once and run it with different inputs while inspecting outputs by slot.
Adoption is suitable for teams solving quadratic optimization problems who want to avoid vendor lock-in and need flexibility across multiple solver backends. The base installation includes CPU simulated annealing; GPU solvers (NVIDIA CUDA, Apple Metal) and quantum hardware access (D-Wave Advantage, Quip Network) are available as composable extras. The project is in early public release with a stated caveat that the instruction set, binary format, and public API may change before v1.0, making it unsuitable for production use at this stage. Prebuilt wheels are available for Linux x86_64 and aarch64 on Python 3.13+; macOS and Windows require a Rust toolchain to build the FFI extension from source.
Development activity shows a spec-first discipline with formal behavior documentation in a committed specification file that serves as the source of truth for both implementations. The project maintains a pure-Python reference VM alongside the production Rust implementation, using it as a conformance oracle to catch divergence automatically. The codebase is organized into three independent Rust crates and five Python distributions, each with a focused scope, suggesting modular design and the ability to adopt components incrementally.