Skip to content

Architecture

HPEC is organized as a pipeline that ingests operations, executes them against a fast in-memory working state, and periodically commits verified results to Altius L1. Its defining idea is a dual-state model.

The dual-state model

HPEC maintains two linked views of state:

  • Fast working state — the high-performance state HPEC executes against off-chain. It is optimized for throughput and low latency.
  • L1 custody & settlement state — the authoritative on-chain record of balances and commitments held by Altius L1.

Execution happens against the fast state; the two are reconciled by batched settlement to L1. This gives users on-chain custody guarantees while preserving off-chain execution speed.

Incoming operations Sequencer Execution risk · margin Settlement relay Altius L1 settlement Data availability & indexing Fast working state

Component groups

HPEC is built from focused services (Rust crates), grouped by responsibility:

  • Sequencing & execution — orders incoming operations and executes them against the fast working state.
  • Risk & margin — evaluates risk and margin constraints as part of execution.
  • State — manages the fast working state and the deltas that are committed to L1.
  • Settlement relay — batches verified results and submits them to the L1 settlement contracts (see Settlement to L1).
  • Data availability & indexing — makes execution data available and provides historical query/indexing.
  • Clustering — multi-node operation with quorum and leader election for availability.
  • Gateway & auth — the external API surface and authentication.
  • Simulation & chaos testing — tooling to validate behavior and resilience under adversarial conditions.

How it connects

HPEC connects to Altius L1 as its settlement L1 over JSON-RPC. In local development, the Altius devnet orchestrator wires HPEC to a running Altius L1 by pointing HPEC's L1 endpoint at the chain's RPC.