LPsLux Proposals
P-Chain
LP-9007

Oracle Provider Staking and Slashing

Final

Bonded registration, per-feed configuration, stake-weighted aggregation, rolling reputation, and an explicit slashing schedule for oracle data providers

Category
Core
Created
2025-12-01

Abstract

LP-9005 specifies how a price reaches a consuming chain: bonded signers observe off-chain sources, aggregate by weighted median, attest through M-Chain, and deliver via Warp with a C-Chain access path. It does not say what a provider must post to participate, how a bad report is punished, or how a provider's history changes its weight. This LP specifies that economic layer: registration bonds, per-feed configuration, stake-weighted aggregation with outlier rejection, a rolling reputation score, and an explicit slashing schedule.

Motivation

A price feed is only as honest as the cost of lying to it. Aggregation mathematics bounds the damage a minority can do; it does not make participation expensive or misreporting painful. Naming the bond, the offenses, and the exact penalty for each turns "trust the signers" into a number a consumer can reason about, and gives an integrator something to check before wiring a lending market or a perpetual to a feed.

Specification

Feed Configuration

Each feed is identified by a (baseAsset, quoteAsset) pair and carries the liveness parameters providers are held to:

Feed {
    feedID      [32]byte    // hash(baseAsset || quoteAsset)
    baseAsset   string      // e.g., "LUX"
    quoteAsset  string      // e.g., "USD"
    heartbeat   uint64      // max seconds between updates
    deviation   uint256     // min price change to trigger update (bps)
    decimals    uint8       // price precision (e.g., 8 = 1e8)
}

heartbeat and deviation together define when a provider owes a report: at least once per heartbeat window, and immediately when the observed price moves by more than deviation. Missing either obligation is a slashable event.

Provider Registration

Data providers stake LUX and register the feeds they serve:

  • Minimum stake: 500 LUX per provider
  • Feed registration: providers declare which feeds they serve
  • Reputation score: rolling accuracy metric based on deviation from the consensus median

A provider's stake is at risk on every feed it has registered for. Registering for more feeds does not require more capital but does increase exposure, which is the intended pressure against over-registration.

Report Submission

Providers submit signed reports:

Report {
    feedID      [32]byte
    price       uint256     // price * 10^decimals
    timestamp   uint64      // observation timestamp
    sources     []string    // e.g., ["binance", "coinbase", "kraken"]
    signature   []byte      // provider's signature
}

The signature makes every report attributable, which is what makes the slashing schedule below enforceable: a penalty is always tied to a specific report by a specific provider.

Stake-Weighted Aggregation

Per feed, per round:

  1. Collect all reports for feedID in the round
  2. Filter outliers: discard reports more than 3 standard deviations from the median
  3. Compute the median weighted by provider stake
  4. Emit the aggregated price with its confidence score

This is the provider-weighting rule behind the WeightedMedian aggregator of LP-9005 §5, which additionally applies a MaxDeviation bound and a circuit breaker on the aggregate. Stake weighting means the cost of moving the median is proportional to the capital an attacker must bond — and lose.

Reputation Score

Each provider carries a rolling accuracy metric: the distribution of its reports' deviation from the accepted aggregate over a trailing window. The score is advisory to consumers and may be used to break ties among providers of equal stake; it never overrides the slashing schedule.

Slashing Schedule

OffenseConditionPenalty
Stale dataMissed a heartbeat window0.1% of stake per miss
Outlier manipulationConsistently reporting >2 standard deviations from the median1% of stake per offense
DowntimeOffline for more than 1 hour0.5% of stake

Penalties are cumulative. A provider whose stake falls below the 500 LUX minimum is deregistered from every feed and must re-bond to return.

Dissemination

Aggregated prices are attested and delivered by the mechanism of LP-9005 — M-Chain threshold signature over the aggregate, Warp delivery, and the chain-specific access paths described there. This LP adds no separate transport.

Rationale

Penalties are proportional to stake rather than flat, so the schedule scales across providers of any size without a governance parameter per tier. Staleness is cheap per miss and expensive in aggregate, which matches the actual harm: one late report is noise, a chronically late provider is a broken feed. Sustained outlier reporting is priced an order of magnitude higher because it is the only offense that can move a price.

Security Considerations

  1. Collusion resistance: median aggregation weighted by stake requires colluding providers to control more than half the bonded stake on a feed to move the accepted price.
  2. Flash-loan immunity: reports are off-chain observations, not on-chain spot prices, so a flash loan cannot manipulate the input. Bonds are locked and cannot be assembled inside a block.
  3. Latency: providers must meet the end-to-end targets of LP-9005 §9; the heartbeat is an obligation on the provider, not a bound on delivery.
  4. Deregistration griefing: penalties accrue per offense and are bounded per round, so a transient network partition cannot deregister an otherwise honest provider in a single window.
  • LP-9005 — the oracle protocol this LP bonds
  • LP-9011 — on-chain read path
  • LP-9211 — running oracle provision as a restaked service
  • LP-9203, LP-9205 — consumers whose solvency depends on these bonds

Copyright (C) 2024-2026, Lux Industries Inc. All rights reserved.

Licensed under the MIT License.