Senmurv

Methodology

How Senmurv works

A full description of the data pipeline, confidence model, on-chain mechanism, and push strategy.

1. Data feeds

Each feed is identified by a dot-separated key such as crypto.tvl.arbitrum or sports.f1.drivers.norris.points. Feeds are grouped into three categories:

  • crypto — chain-level metrics: TVL, DEX volume (24h), gas fees (24h) across Ethereum, Arbitrum, and Base
  • economics — macro interest rates: US EFFR, SOFR, EU ECB MRR
  • sports — live standings: Formula 1 driver and constructor points

New categories and feeds can be added by registering a fetcher — the aggregation and confidence pipeline is category-agnostic.

2. Multi-source aggregation

For each feed, Senmurv queries every available source independently and in parallel. Current sources include DeFiLlama, Dune Analytics, Jolpica, ESPN, the NY Fed, the ECB, and the SOFR administrator. No single provider is trusted exclusively.

After collection, all readings for a feed are aggregated into a single value — the arithmetic mean — and a confidence score:

confidence = 1 − max(|v − mean| / |mean|) for each source v
  • All sources agree exactly → 1.00
  • One source is 10 % off the mean → 0.90
  • One source is 40 % off → 0.60
  • Single source only → 0.50 (data exists but cannot be cross-checked)
  • No sources → 0.00

3. Hybrid feeds

Some feeds are derived rather than directly fetched — they combine readings from different sources or different metric types into a single value. For example, gas fees reported in ETH by a block explorer are multiplied by an ETH/USD price reading from a separate source to produce a USD-denominated fee feed.

Hybrid feeds are labelled composed in the interface. Their confidence reflects both the agreement between raw readings and the uncertainty introduced by the shared price dependency. This allows the oracle to publish metrics that no single data provider offers in isolation.

4. Push oracle

A Python keeper process runs every hour via GitHub Actions. It fetches all sources, aggregates the readings, and calls setMetrics() on the on-chain MetricRegistry contract to publish the latest values and confidence scores. Smart contracts consume any feed in a single synchronous call:

(uint256 value, uint256 confidence, uint256 timestamp) = oracle.getMetric("crypto.tvl.arbitrum");

Values are encoded as fixed-point integers with 8 decimal places (value = raw × 10⁸) and confidence as basis points (10000 = 100 %). The timestamp field allows consumers to reject stale data above an age threshold of their choosing.

The contract is deployed on Base Sepolia and Arbitrum Sepolia. Mainnet deployment follows once the keeper and confidence thresholds are battle-tested.

5. Delta push & feed config

The keeper does not blindly re-publish every metric each hour. Before broadcasting a transaction, it reads the current on-chain values and applies per-feed push rules defined in feed_config.json:

  • change_threshold — minimum fractional change before re-publishing. Crypto feeds use 0.5 % to absorb rounding noise between hourly fetches. Sports and economics feeds use 0 % — any change triggers a push.
  • heartbeat_hours — even if unchanged, a feed is re-published after this many hours so consumers can verify the oracle is alive. Crypto feeds heartbeat every 24 h; sports feeds every 7 days (aligned with grand prix frequency).
  • enabled — a feed can be disabled without removing it.

Push rules are resolved by pattern matching on the feed key (exact key beats glob pattern beats category default), so individual feeds can be tuned without touching keeper code.

6. Prediction markets

Prediction markets built on Senmurv use oracle feeds as their settlement source. A market specifies a feed key, a target value, and an expiry timestamp. At expiry, the settlement contract calls the oracle and resolves positions automatically — no human intervention required.

Confidence gating prevents settlement on low-quality data: if the oracle confidence at expiry is below a market-defined threshold, settlement is deferred until a high-confidence reading arrives. This aligns market incentives with data quality.