FOUNDATIONS
How Invarians measures blockchain infrastructure state, architecture, measurement method, calibration, and three output primitives (Attestation, Regime, Drift Signal).
Post-PBS and MEV-Boost have fragmented mempool visibility. No single node observes all pending transactions, rendering mempool snapshots structurally unreliable. Invarians abandons mempool-based assumptions and measures only what is consensus-finalized: the block itself.
Mempool observations · raw price volatility · liquidity depth · transaction intent signals · gas market narrative.
τ texture (long-term structural regime, 5–13 h window) · π pressure (short-term operational friction, ~5 min window) · their divergence. The single exception on the demand side: the echo of activity (sigma, size, transaction count) measured on confirmed blocks, not on intent flow.
This principle was published in Post-PBS, blockchains need infrastructure metrics, not mempool illusions (November 2024). The data model lives up to it: the active raw measurements table (ans_invariants_v3) contains zero mempool, zero raw fees, zero intent — only block-level observations.
Blockchain infrastructure is not one system. It is three structurally distinct layers, each with different operating constraints, different failure modes, and different measurement requirements. Invarians measures each layer independently.
→ four regimes (SxDx)
→ regime S1Dx (τ non-discriminant)
→ two states (BS1 / BS2)
Since the Dencun upgrade (March 2024), L2 rollups post batch data to Ethereum via blobs, a separate fee market that does not flow through L1 basefee. An L2 sequencer incident or batch posting gap now produces no economic signature on L1. Fee monitors watching L1 are structurally blind to it. Invarians measures L2 infrastructure state directly, from rollup block data and from L1-anchored batch signals.
For L1 chains, infrastructure state is the product of two independent axes: a structural axis and a demand axis. The separation is critical, structural stress and demand pressure can occur independently, simultaneously, or in opposition. Reading both independently is what makes S2D1 detectable.
rhythm_ratio, normalized departure from calibrated historical cadence.
Threshold S2: rhythm_ratio ≥ chain-specific calibrated value.
Dimensions:
sigma_ratio · size_ratio · tx_ratio
There is no cross-chain normalization. Every threshold is derived from each chain's own multi-year historical distribution. What constitutes an anomaly on Ethereum is calibrated from Ethereum data. What constitutes an anomaly on Solana is calibrated from Solana data.
Every panel response carries a cryptographic envelope: a SHA-256 hash of the canonical JSON payload, an HMAC-SHA256 signature over that hash, and a key identifier. The agent can independently verify (via POST /v2/verify) that the payload was produced by Invarians and has not been altered in transit.
The data is what Invarians produced at computed_at. It is non-repudiable on the server side, integrity-protected end-to-end, and reproducible against the canonical JSON form (sorted keys).
That the underlying observation is correct (calibration responsibility) · that the regime classification is appropriate for the agent's policy (interpretation responsibility) · that the chain is safe to act on (fitness-for-action responsibility, see Primitive 3).
The HMAC envelope includes "anchor": null in v2.0. Once the InvariansAnchor contract is deployed on Arbitrum, each canonical payload hash will be batch-anchored on-chain (Merkle root with epoch boundary). The anchor field will then contain { tx_hash, block_number, contract }, providing a permissionless integrity check independent of the HMAC server.
The combination of the two axes produces four base regimes. The classification is discrete and unambiguous, each measurement window maps to exactly one regime. Four legacy regimes: S1D1 · S1D2 · S2D1 · S2D2.
Since 2026-04-29, the panel API also emits signed regime codes on chains with calibrated lower bounds. The four base codes are extended with direction suffixes on the demand axis (D2+, D2-, D2±) and on the structure axis (S2+, S2-). Total: 12 codes on L1 and 12 codes on L2 (since v2.0, L2 also reaches S2 thanks to sequencer_publish_latency). The legacy 4 codes remain valid as aliases. See section 03b below.
S2D1 is the regime with the highest diagnostic value. It captures infrastructure events, validator behavior anomalies, timing disruptions, network-layer issues, that produce no fee signature. A fee monitor would report S1D1 during an S2D1 period. This is the core of the two-axis approach: the structural and demand layers must be read independently to detect it.
On L2 rollups, the structural axis (τ) is architecturally constant, the sequencer produces blocks at fixed cadence. Only the demand axis varies. L2 rollups are currently classified as S1D1 or S1D2. Full regime coverage (S2D1 · S2D2) requires alternative structural instruments under development (Phase D, April 2026).
The 4-state grid above is one-sided: it only captures deviations above the calibrated nominal window. But several real-world signatures fall below nominal: cascading liquidations (composition concentrated, total tx_count drops), sequencer halts (rhythm slows AND tx drops), censorship of a transaction class (selective tx exclusion), agentic bundle dominance (size up, tx down). Adding lower bounds on each axis produces signed direction codes, extending the grid to 12 regimes on L1 and 9 on L2.
D2 alias. DeFi season, ETF events, organic activity surge.S2 alias. Sequencer drift, validator outages.D2± captures composition asymmetry that the legacy 4-state grid misses. Size-up + tx-down (or vice versa) means the chain is processing fewer but larger transactions than baseline (the typical profile of a bot cascade on Aave or Compound, MEV searcher dominance, or stablecoin depeg arbitrage HFT). The first such pattern observed on Invarians was the rsETH cascade of 2026-04-18 on Ethereum: with signed codes active, the panel would have emitted S1D2- at 14h UTC instead of the legacy S1D1.
Activated chain by chain since 2026-04-29: ETH, POL on L1; ARB, BASE, OP on L2. SOL and AVAX scheduled for July 2026 calibration. ARB uses a multi-dim demand workaround (size + tx) because sigma_ratio is structurally degenerate on Arbitrum Nitro. See glossary and calibration_log Entries #029 to #032.
Regime classification answers what is the substrate doing now. It does not answer is it safe to act in the next 30 minutes. The Drift Signal is the third primitive: it measures whether the chain is converging toward, diverging from, or stable around its long-term baseline.
Each classifying observable carries two exponential moving averages: a short EMA (~10 h half-life) tracking the current state, and a long EMA (~30 d half-life) representing the chain's structural baseline. The shift = ratio_short - ratio_long measures how far the chain currently deviates from its 30-day pace.
The shift alone tells you the magnitude of deviation. Two derived fields tell you whether it is amplifying or reverting:
shift_delta = shift_now - shift_prev — direction of the value movement between cycles.
shift_magnitude_delta = |shift_now| - |shift_prev| — whether the deviation is growing (positive) or shrinking (negative), regardless of which side of the baseline.
An agent that reads only the regime sees a snapshot. An agent that reads the Drift Signal in addition can distinguish:
- Regime D2+, drift growing → demand surge active and accelerating, regime sticky
- Regime D2+, drift shrinking → demand surge ending, return to D1 within hours
- Regime D2-, drift growing → starvation deepening, depressed demand persists
- Regime D2-, drift shrinking → starvation recovering, return to D1 likely
An agent making a 30-minute decision uses the regime + drift to estimate whether its operating context will hold long enough to execute. That estimate is left to the agent's policy — Invarians provides the data, not the threshold.
The Drift Signal is exposed in the panel API in ?include=diagnostic mode, with shift, shift_delta, shift_magnitude_delta per classifying metric and a composite drift object per axis (structural / demand). Two new structural observables join in v2.0: Beacon Chain participation rate on Ethereum, sequencer publish latency on each L2. These observables emit shift_available: false during their slow-EMA stabilization period (~30 days post-launch), then automatically activate.
The Drift Signal is a substrate-physics concept. Chains evolve under sustained agentic load on the time scale of weeks: structural rhythm slowly shifts, demand baselines slowly migrate, validator participation slowly trends. The 10 h / 30 d EMA pair captures exactly that scale.
Bridges are operational pipelines, not substrates. Their fitness-for-action is fully captured by current state (BS1 / BS2), per-message latency P90 / P99, success rate, and crypto anchor verifiability — at the cycle granularity of the collector (10 min). Forcing a substrate-style drift onto operational latency would conflate two different physical phenomena. The three-primitive architecture therefore exposes Drift Signal on L1 and L2 entries only; bridge entries expose state, metrics, and crypto pointer without a drift block.
The bridge layer operates on different time scales and with different signal characteristics from L1 and L2. Its state is binary and fast-moving, it reflects the current operational condition of the cross-chain transfer path, not a structural regime.
backlog: within baseline
backlog: above threshold
L1/L2 regimes (SxDx) reflect structural conditions, inertial, slow-moving, derived from multi-year calibration. Bridge state (BS1/BS2) reflects operational throughput, fast-moving, binary, measured in seconds to minutes. The distinction is architectural. Mixing them would distort both signals.
Bridge signal collection active since March 2026. Variable-latency bridges (CCIP, CCTP) classified with unified BS1 / BS2 nomenclature. Each bridge entry exposes a capability_level field indicating the depth of signal captured.
Each CCTP message is captured individually: the source DepositForBurn event, the MessageTransmitter.MessageSent payload, the resulting messageHash, and the Circle ECDSA secp256k1 attestation signature (65 bytes). The signature is retrievable via GET /v2/cctp/attestation/{message_hash} and is independently verifiable against Circle's published attester public key, providing a cryptographic chain of trust distinct from the Invarians HMAC envelope.
Bridge entry exposes metrics.latency_p90_s, metrics.latency_p99_s, metrics.success_rate_1h computed on per-message latencies, plus crypto.anchor = "circle_ecdsa" and crypto.verifiable_via pointer. A pending queue handles the asymmetry between collector cycle (10 min) and source-chain finality (~13-19 min on Ethereum-anchored chains): messages whose Iris attestation arrives after their first observation are re-polled at each subsequent cycle until attested or 2 h expiry, with no message lost.
Each CCIP message is captured individually: source CCIPSendRequested on the OnRamp and destination ExecutionStateChanged on the OffRamp, matched per message by the bytes32 messageId. Real send-to-execute latency per lane per direction is derived from the match.
Bridge entry exposes metrics.execute_latency_p90_s computed on per-message latencies, plus metrics.sequence_gap and metrics.messages_confirmed_1h. RMN.isCursed() per chain remains a safety boolean. crypto.anchor is null today (no per-message cryptographic anchor captured yet for CCIP). Each captured message is retrievable via GET /v2/ccip/message/{message_id}.
A pending queue handles the asymmetry between collector cycle and CCIP end-to-end latency, mirroring the CCTP pending model.
Beyond discrete regime classification, the v2.0 panel exposes a continuous drift signal per axis. Regime answers "what is the substrate doing now?". Drift answers "is it moving toward a transition?".
For every axis (structural, demand) the panel reports three numbers in a single drift object: magnitude, raw delta, and magnitude_delta. Magnitude is the maximum absolute shift across the axis observables (rhythm, continuity, beacon_participation on ETH; sigma, size, tx, complexity, gas_complexity on demand). Magnitude_delta tells whether that deviation is widening (positive) or shrinking (negative) between cycles.
Regime classification remains the primary output. The drift composite gives systems that require it a continuous fitness-for-action signal: substrate stable, mild drift, active drift, or imminent transition probable. Per-metric blocks (in diagnostic mode) expose the same triplet (shift, shift_delta, shift_magnitude_delta) at observable granularity.
Every threshold is derived empirically. No assumption is introduced by design.
/verify endpoint.| Chain | τ structural | π demand | Regime coverage |
|---|---|---|---|
| Ethereum | Calibrated, backtest 2020–2024 | Calibrated, FPR 1.23% | S1D1 · S1D2 · S2D1 · S2D2 |
| Polygon | Calibrated, backtest 2020–2023 | Calibrated, TPR 100% (4/4 events), FPR 14.57% | S1D1 · S1D2 · S2D1 · S2D2 |
| Solana | Calibrated, partial (τ FPR 1.77%) | Pending, tx_count unavailable in dataset | S1D1 · S2D1 (S1D2 · S2D2 pending) |
| Avalanche | Empirical estimate, no BigQuery backtest | Empirical estimate, confidence LOW | Operational, confidence LOW |
| L2 Rollups, distinct measurement framework | |||
| Base | τ non-discriminant (sequencer constant cadence) | 30d statistical calibration v3 (2026-04-16), σ threshold 1.20 | S1D1 · S1D2 (S2D1 · S2D2 pending Phase D) |
| Optimism | τ non-discriminant (sequencer constant cadence) | 30d statistical calibration v3 (2026-04-16), σ threshold 1.12 | S1D1 · S1D2 (S2D1 · S2D2 pending Phase D) |
| Arbitrum | τ compressed (P99/P50 = 1.086) | π broken, gasLimit ≈ 2⁵⁰ (gas_complexity_ratio Phase B) | Recalibration pending |
Validated on real incidents. Not synthetic data. Invarians has been calibrated and backtested against documented historical events, each one verified against independent sources.
ETF speculation congestion, +12.2h advance over fee monitors
Invarians detected structural demand elevation 12.2 hours before gas P80 confirmed it. L1 structural regime (S1D2) was measurable from finalized block data alone, no mempool, no prediction.
37-minute batch posting gap — zero L1 signature
Batch posting stopped for 37 minutes. During the entire window, L1 ETH showed S1D1, structurally normal. Fee monitors: no signal. Invarians: BS2 bridge state, L2 regime S1D2 (×1649 block ratio).
The measurement chain — architecture, axes, classification, calibration — produces three distinct outputs in a single signed payload (since API v2.0, 2026-04-30):
/v2/verify.
Answers: can I trust this data?
Answers: what is the substrate doing now?
shift, shift_delta, shift_magnitude_delta over short (~10 h) and long (~30 d) EMAs, plus composite drift per axis. Tells the agent whether the regime is persisting, amplifying, or reverting.
Answers: is it safe to act in the next 30 minutes?
Invarians certifies what the infrastructure is and where it is drifting. It does not prescribe what the agent should do. Execution policy, thresholds, risk tolerance, fallback logic — belongs to the agent. The three primitives provide the factual basis for that policy. The decision does not.
Pattern Reference (the historical frequency of each (L1 × L2 × Bridge) combination) remains a complementary research output, exposed via /patterns and the pattern_frequency_snapshots dataset. It is an analytical reference, not part of the live signed payload.
/verify.Invarians tracks blockchain behavior under AI agent load and defines safe execution windows. Current monitoring scope:
| Layer | Coverage |
|---|---|
| L1 | Ethereum, Solana, Polygon, Avalanche |
| L2 (Ethereum-anchored) | Arbitrum, Base, Optimism |
| Chainlink CCIP lanes | Bidirectional, L1 ↔ L1 and L1 ↔ L2 |
| Circle CCTP routes | Bidirectional, L1 ↔ L1 and L1 ↔ L2 |
Bridge classification scope is variable-latency surfaces only (Chainlink CCIP, Circle CCTP). Institutional RWA settlement moves stablecoins via CCTP and tokens via CCIP, both bidirectional.