DocsCurrent Page

Oracles


DexBotics uses multiple oracle types to verify task completion in a trustless manner.


Oracle Types


Geofence Oracle


Verifies robot presence at specified GPS coordinates.


Data Required:
  • GPS track log with timestamps
  • Minimum dwell time at location
  • Accuracy/precision metrics

Attestation Schema:
json
{
  "task_id": 123,
  "robot": "robot_nft_mint_pubkey",
  "tracks": [
    {"t": 1730791000, "lat": 53.5, "lon": 10.2},
    {"t": 1730791015, "lat": 53.501, "lon": 10.201}
  ],
  "proofs": [{"type":"qr_photo","cid":"bafy..."}],
  "sig": "base58(signature)"
}

QR-Photo Oracle


Verifies robot captured QR code at task site.


Process:

1. Robot scans QR code

2. Takes photo with timestamp

3. Uploads to IPFS

4. Submits CID on-chain


Validation:
  • QR code matches expected value
  • Photo timestamp within task window
  • Image integrity verified

Beacon Oracle


Proximity verification using Bluetooth/RF beacons.


Requirements:
  • Fixed beacon IDs at task sites
  • RSSI signal strength logs
  • Distance estimation algorithm

Advantages:
  • Works indoors without GPS
  • Difficult to spoof
  • Real-time verification

Human Attester


Manual quality inspection for subjective criteria.


Use Cases:
  • Cleanliness verification
  • Quality control
  • Damage assessment
  • Complex task validation

Requirements:
  • Higher stake (e.g., 10x standard)
  • Reputation history
  • Attestation photos/notes

Stake-Weighted Voting


Each oracle's vote is weighted by their staked $DEXB:


oracle_weight = stake_amount * reputation_multiplier
quorum_threshold = sum(all_oracle_weights) * 0.66

Example:
  • Oracle A: 5,000 $DEXB × 1.2 rep = 6,000 weight
  • Oracle B: 3,000 $DEXB × 1.0 rep = 3,000 weight
  • Oracle C: 2,000 $DEXB × 0.9 rep = 1,800 weight
  • Total: 10,800 weight
  • Quorum: 7,128 (66%)

If A and B vote accept (9,000 weight), quorum is reached.


Slashing Conditions


Oracles can be slashed for:

  • Voting against clear evidence
  • Colluding with robots
  • Delayed attestation
  • Pattern of minority votes

Penalty: 10-50% of staked amount

Running an Oracle Node


bash
npm install -g @dexbotics/oracle-node

dexbotics-oracle start \
  --type geofence \
  --stake 5000 \
  --keypair ~/.config/solana/oracle.json \
  --cluster devnet

Requirements:
  • Minimum 1,000 $DEXB stake
  • Reliable uptime
  • Fast response time (<30s)
  • Honest attestation