Thanks to visit codestin.com
Credit goes to lib.rs

#quantum-computing #ibm #hardware #api-bindings

logosq-hardware-integrator

Hardware backend integration for LogosQ quantum computing framework

1 unstable release

0.1.0 Jan 20, 2026

#588 in Science

MIT license

39KB
530 lines

LogosQ Hardware Integrator

A Rust crate for integrating LogosQ with quantum hardware providers, enabling seamless transitions from simulation to real QPU execution.

Features

  • Type-safe API calls: Compile-time circuit validation
  • Async support: Non-blocking job submission via Tokio
  • Multi-backend: IBM Quantum, IonQ, Google, Rigetti
  • Robust error handling: Comprehensive error types for all failure modes

Quick Start

use logosq_hardware_integrator::{IbmBackend, HardwareBackend, Circuit};

#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
    let backend = IbmBackend::new_from_env().await?;
    
    let circuit = Circuit::new(2)
        .h(0)
        .cx(0, 1)
        .measure_all();
    
    let job = backend.submit_circuit(&circuit, 1024).await?;
    let result = job.wait_for_result().await?;
    
    println!("Counts: {:?}", result.counts());
    Ok(())
}

Installation

[dependencies]
logosq-hardware-integrator = "0.1"
tokio = { version = "1.35", features = ["full"] }

Set environment variables:

export IBM_QUANTUM_TOKEN="your_token"
export IONQ_API_KEY="your_key"

License

MIT OR Apache-2.0

Dependencies

~12–28MB
~303K SLoC