Riverlane LogoDeltakit Logo

The open-source software for developing and adopting Quantum Error Correction

An SDK for quantum error correction, built by Riverlane. Designed for researchers, developers, and quantum engineers.

Getting started

  1. 1

    Create access token

    This free token is used to access our cloud APIs.

    Generate token
  2. 2

    Install Deltakit

    Run the following command in your terminal.

    pip install deltakit
  3. 3

    Setup your token

    In Python, run the following code to save your token:

    from deltakit import Client
    Client.set_token("YOUR_TOKEN")
  4. 4

    That's it!

    Dive into our examples to learn more about Deltakit.

    View Docs

Run your first experiment

Follow this basic workflow to define a QEC circuit, simulate noise, and run your experiment.

Generate circuit

Create a repetition code and use it to build a distance 3 memory circuit

rep_code = RepetitionCode(distance=3, stabiliser_type=PauliBasis.Z)
circuit = css_code_memory_circuit(
	css_code=rep_code, num_rounds=3, logical_basis=PauliBasis.Z)

Add realistic noise

Apply a superconducting noise model to the circuit and compile it to a QPU

noise = SI1000Noise(p=0.01)
qpu = QPU(qubits=circuit.qubits, noise_model=noise)
noisy_circ = qpu.compile_and_add_noise_to_circuit(circuit)

Simulate circuit

Either use Stim locally or on the cloud to run a fast stabiliser simulation of your circuit

measurements, _ = simulation.simulate_with_stim(
	noisy_circ, 100_000, client=cloud)
detectors, observables = measurements.to_detectors_and_observables(noisy_circ.as_stim_circuit())

Decode circuit

Use our cloud-hosted state-of-the-art local clustering decoder to decode the measurement results

lc_decoder = LCDecoder(noisy_circ, client=cloud,
	num_observables=noisy_circ.as_stim_circuit().num_observables)
predictions = lc_decoder.decode_batch_to_logical_flip(detectors.as_numpy())

Join a community of quantum scientists and engineers using Deltakit