Backends
What a Backend Is
In Tessera, a backend is an entry in the backend registry that defines three things:
| Component | Description |
|---|---|
| Basis gate set | The set of gate names natively supported by the hardware |
| Decomposition map | A map from non-basis gate names to equivalent sequences of basis gates |
| Default coupling map | The hardware topology used for routing when no override is provided |
When you pass backend="IBM" to transpile(), Tessera looks up the IBM entry in the registry, uses its basis gate set to determine what needs decomposing, its decomposition map to perform those decompositions, and its default coupling map for qubit layout and routing.
IBM
Basis gates: cx, rz, sx, x, u
Default device: FakeNairobiV2: 7 qubits, heavy-hex topology
Registry key: "IBM"
Available coupling maps
| Key | Device | Qubits | Topology |
|---|---|---|---|
IBM_DEFAULT | FakeNairobiV2 | 7 | Heavy-hex |
IBM_BRISBANE | FakeBrisbane | 127 | Heavy-hex |
IBM_SHERBROOKE | FakeSherbrooke | 127 | Heavy-hex |
# Default (FakeNairobiV2, 7 qubits)
transpile(qc, backend="IBM")
# Brisbane (127 qubits)
transpile(qc, backend="IBM", coupling_map="IBM_BRISBANE")
# Sherbrooke (127 qubits)
transpile(qc, backend="IBM", coupling_map="IBM_SHERBROOKE")IBM coupling maps are derived from real hardware topologies via Qiskit's fake provider backends.
IonQ
Basis gates: rx, ry, rz, cx
Default device: Aria: 25 qubits, all-to-all topology
Registry key: "IONQ"
Available coupling maps
| Key | Device | Qubits | Topology |
|---|---|---|---|
IONQ_ARIA | IonQ Aria | 25 | All-to-all |
IONQ_FORTE | IonQ Forte | 36 | All-to-all |
# Default (Aria, 25 qubits)
transpile(qc, backend="IONQ")
# Forte (36 qubits)
transpile(qc, backend="IONQ", coupling_map="IONQ_FORTE")BasicSwapRouter will never need to insert SWAP gates for IonQ circuits regardless of the circuit structure. The routing pass still runs but is effectively a no-op.Rigetti
Basis gates: rx, rz, cz
Default device: Ankaa-2: 84 qubits, rectangular grid topology
Registry key: "RIGETTI"
Available coupling maps
| Key | Device | Qubits | Topology |
|---|---|---|---|
RIGETTI_ANKAA | Rigetti Ankaa-2 | 84 | 7×12 rectangular grid |
RIGETTI_ANKAA_9Q | Rigetti Ankaa-9Q-3 | 9 | 3×3 rectangular grid |
# Default (Ankaa-2, 84 qubits)
transpile(qc, backend="RIGETTI")
# Ankaa-9Q-3 (9 qubits, useful for small circuit testing)
transpile(qc, backend="RIGETTI", coupling_map="RIGETTI_ANKAA_9Q")cx is not in Rigetti's basis gate set. Any cx gate, whether in the input circuit or introduced during decomposition, is inlined as H·CZ·H (H gate, CZ gate, H gate) since cz is the native two-qubit gate. This is handled automatically by the decomposition map.Backend and Coupling Map Independence
The backend and coupling map are fully independent in Tessera. The backend controls only gate decomposition, including which gates need to be broken down and how. The coupling map controls only routing topology, including which qubits are adjacent and how SWAPs are inserted. There is no validation tying them together.
This means you can freely mix any backend with any coupling map:
# Decompose to IBM basis gates but route using IonQ's all-to-all topology
transpile(qc, backend="IBM", coupling_map="IONQ_ARIA")
# Decompose to Rigetti basis gates but route on a small 9-qubit grid
transpile(qc, backend="RIGETTI", coupling_map="RIGETTI_ANKAA_9Q")In practice you'll almost always use a coupling map that matches your backend's hardware, but the separation is intentional because it keeps the two concerns cleanly isolated and makes both easier to test and extend independently.
Using a Non-Default Coupling Map
Pass any registry key string or a TesseraCouplingMap instance directly to transpile():
# Named key
transpile(qc, backend="IBM", coupling_map="IBM_BRISBANE")
# Custom coupling map
from tessera.hardware.coupling_map import TesseraCouplingMap
cm = TesseraCouplingMap(4, [(0,1),(1,0),(1,2),(2,1),(2,3),(3,2)])
transpile(qc, backend="IBM", coupling_map=cm)See the Coupling Maps page for the full list of available registry keys and details on building custom topologies.
Adding a New Backend
Tessera's backend registry is designed to be extended with minimal friction. adding a new backend touches only a handful of files and requires no changes to any pass. See the Adding a Backend guide for a full step-by-step walkthrough.