> ## Documentation Index
> Fetch the complete documentation index at: https://docs.eco.com/llms.txt
> Use this file to discover all available pages before exploring further.

# svm venue: quantum

> The quantum Solana venue: the declaration and description of each of the 32 exports of @eco-incorp/sauce/svm.

Solana venue integration `quantum`, exported from `@eco-incorp/sauce/svm`.

Generated from the type declarations of `@eco-incorp/sauce`.

### `quantumSideBase`

*Function* · `@eco-incorp/sauce/svm`

Side-struct base offset for a direction (zeroIn reads side1, oneIn reads side0).

```typescript theme={null}
export declare function quantumSideBase(direction: "zeroIn" | "oneIn"): number;
```

### `quantumOutScale`

*Function* · `@eco-incorp/sauce/svm`

10^decimals of the direction's OUTPUT token.

```typescript theme={null}
export declare function quantumOutScale(cfg: QuantumPoolConfig): bigint;
```

### `quantumOutVault`

*Function* · `@eco-incorp/sauce/svm`

The direction's output vault (whose live balance is the hard out cap).

```typescript theme={null}
export declare function quantumOutVault(cfg: QuantumPoolConfig): Address;
```

### `quantumInVault`

*Function* · `@eco-incorp/sauce/svm`

The direction's input vault (the swap CPI's transfer destination).

```typescript theme={null}
export declare function quantumInVault(cfg: QuantumPoolConfig): Address;
```

### `quantumOutReserveOffset`

*Function* · `@eco-incorp/sauce/svm`

Cached out-reserve offset for the direction (the second half of the out cap).

```typescript theme={null}
export declare function quantumOutReserveOffset(cfg: QuantumPoolConfig): number;
```

### `fetchQuantumConfig`

*Function* · `@eco-incorp/sauce/svm`

Fetch + gate one Quantum pool and freeze both directions' walkable level
prefixes. Read-only against the loader.

```typescript theme={null}
export declare function fetchQuantumConfig(owned: OwnedAccountLoader, pool: Address): Promise<QuantumPoolConfig>;
```

### `QUANTUM_PROGRAM_ID`

*Variable* · `@eco-incorp/sauce/svm`

```typescript theme={null}
QUANTUM_PROGRAM_ID: Address<"QuaNtZsgYRe5Z9Bk4LZ4cTD9tbkVoyCNf1R2BN9bBDv">
```

### `QUANTUM_GLOBAL`

*Variable* · `@eco-incorp/sauce/svm`

The program's single global config account (one for every pool). Lived in
this venue's ladder module until the merge-decomposition ladders moved out;
it is a program address, not decomposition state, so it stays here.

```typescript theme={null}
QUANTUM_GLOBAL: Address<"3JumrbigQRj9TqEuy5fKGPHsQ6zCTwqqfVGhFhyoEMqH">
```

### `QUANTUM_POOL_SIZE`

*Variable* · `@eco-incorp/sauce/svm`

Exact pool account size (all 27 live mainnet pools).

```typescript theme={null}
QUANTUM_POOL_SIZE = 2280
```

### `OFF_MINT0`

*Variable* · `@eco-incorp/sauce/svm`

```typescript theme={null}
OFF_MINT0 = 0
```

### `OFF_MINT1`

*Variable* · `@eco-incorp/sauce/svm`

```typescript theme={null}
OFF_MINT1 = 32
```

### `OFF_VAULT0`

*Variable* · `@eco-incorp/sauce/svm`

```typescript theme={null}
OFF_VAULT0 = 64
```

### `OFF_VAULT1`

*Variable* · `@eco-incorp/sauce/svm`

```typescript theme={null}
OFF_VAULT1 = 96
```

### `OFF_RESERVE0`

*Variable* · `@eco-incorp/sauce/svm`

```typescript theme={null}
OFF_RESERVE0 = 128
```

### `OFF_RESERVE1`

*Variable* · `@eco-incorp/sauce/svm`

```typescript theme={null}
OFF_RESERVE1 = 136
```

### `OFF_SIDE0`

*Variable* · `@eco-incorp/sauce/svm`

```typescript theme={null}
OFF_SIDE0 = 144
```

### `OFF_SIDE1`

*Variable* · `@eco-incorp/sauce/svm`

```typescript theme={null}
OFF_SIDE1 = 928
```

### `OFF_DEC0`

*Variable* · `@eco-incorp/sauce/svm`

```typescript theme={null}
OFF_DEC0 = 1760
```

### `OFF_DEC1`

*Variable* · `@eco-incorp/sauce/svm`

```typescript theme={null}
OFF_DEC1 = 1761
```

### `OFF_LEVEL_COUNT`

*Variable* · `@eco-incorp/sauce/svm`

```typescript theme={null}
OFF_LEVEL_COUNT = 1763
```

### `SIDE_LEVELS`

*Variable* · `@eco-incorp/sauce/svm`

```typescript theme={null}
SIDE_LEVELS = 0
```

### `SIDE_LEVEL_STRIDE`

*Variable* · `@eco-incorp/sauce/svm`

```typescript theme={null}
SIDE_LEVEL_STRIDE = 16
```

### `SIDE_EXPIRY`

*Variable* · `@eco-incorp/sauce/svm`

```typescript theme={null}
SIDE_EXPIRY = 256
```

### `SIDE_KINDS`

*Variable* · `@eco-incorp/sauce/svm`

```typescript theme={null}
SIDE_KINDS = 384
```

### `QUANTUM_LEVEL_SLOTS`

*Variable* · `@eco-incorp/sauce/svm`

Hard array bound inside a side struct (the venue's own index guard is \< 17).

```typescript theme={null}
QUANTUM_LEVEL_SLOTS = 16
```

### `EXPIRY_SCALE`

*Variable* · `@eco-incorp/sauce/svm`

expirySlot is stored scaled by 1e4; the venue divides before comparing (.text 0x1058).

```typescript theme={null}
EXPIRY_SCALE = 10000n
```

### `QUANTUM_MAX_LEVELS`

*Variable* · `@eco-incorp/sauce/svm`

Shipped levels per direction. 16 is the venue's own array bound; all but 5
of the 27 live pools publish 5. The walk is a bounded loop (not unrolled),
so this costs three 16-entry arrays of slot locals, not 16x the fragment.

```typescript theme={null}
QUANTUM_MAX_LEVELS = 16
```

### `QUANTUM_KIND_TRAPEZOID`

*Variable* · `@eco-incorp/sauce/svm`

Level kinds the fragment implements: 1 = trapezoid (every live pool side).

```typescript theme={null}
QUANTUM_KIND_TRAPEZOID = 1
```

### `QuantumLevel`

*Interface* · `@eco-incorp/sauce/svm`

```typescript theme={null}
export interface QuantumLevel {
    index: number;
}
```

### `QuantumWindow`

*Interface* · `@eco-incorp/sauce/svm`

```typescript theme={null}
export interface QuantumWindow {
    levels: QuantumLevel[];
}
```

### `QuantumPoolConfig`

*Interface* · `@eco-incorp/sauce/svm`

```typescript theme={null}
export interface QuantumPoolConfig extends PoolConfig {
    venue: typeof SLUG;
    direction: "zeroIn" | "oneIn";
    mint0: Address;
    mint1: Address;
    vault0: Address;
    vault1: Address;
    dec0: number;
    dec1: number;
    levelCount: number;
    windows: {
        zeroIn: QuantumWindow;
        oneIn: QuantumWindow;
    };
}
```

### `quantum`

*Variable* · `@eco-incorp/sauce/svm`

The Quantum venue: a market maker that posts priced levels, each with an expiry slot.

```typescript theme={null}
quantum: {
    slug: string;
    programId: Address<"QuaNtZsgYRe5Z9Bk4LZ4cTD9tbkVoyCNf1R2BN9bBDv">;
    tokenProgram: Address<"TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA">;
    fetchPoolConfig: typeof fetchQuantumConfig;
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.