Swarm Oracle: Trustless Blockchain Agreements through Robot Swarms

Alexandre Pacheco, Hanqing Zhao, Volker Strobel, Tarik Roukny, Gregory Dudek, Andreagiovanni Reina, Marco DorigoarXiv 2025 · OpenReview

Abstract

Blockchain consensus, rooted in the principle "don't trust, verify", limits access to real-world data, which may be ambiguous or inaccessible to some participants. Oracles address this limitation by supplying data to blockchains, but existing solutions may reduce autonomy, transparency, or reintroduce the need for trust. We propose Swarm Oracle: a decentralized network of autonomous robots—that is, a robot swarm—that use onboard sensors and peer-to-peer communication to collectively verify real-world data and provide it to smart contracts on public blockchains. Swarm Oracle leverages the built-in decentralization, fault tolerance and mobility of robot swarms, which can flexibly adapt to meet information requests on-demand, even in remote locations. Unlike typical cooperative robot swarms, Swarm Oracle integrates robots from multiple stakeholders, protecting the system from single-party biases but also introducing potential adversarial behavior. To ensure the secure, trustless and global consensus required by blockchains, we employ a Byzantine fault-tolerant protocol that enables robots from different stakeholders to operate together, reaching social agreements of higher quality than the estimates of individual robots. Through extensive experiments using both real and simulated robots, we showcase how consensus on uncertain environmental information can be achieved, despite several types of attacks orchestrated by large proportions of the robots, and how a reputation system based on blockchain tokens lets Swarm Oracle autonomously recover from faults and attacks, a requirement for long-term operation.

Introduction: The Oracle Problem

Blockchains are deterministic systems that operate on the principle of "don't trust, verify." However, this isolation creates a fundamental "oracle problem": blockchains cannot natively access off-chain data—such as weather conditions, asset prices, or environmental states—without relying on external sources. If these sources are centralized, the core blockchain principles of decentralization and trustlessness are compromised.

While software-based decentralized oracles (e.g., Chainlink) serve digital data, "hardware oracles" for the physical world are less developed. Traditional IoT solutions often lack the mobility and autonomy needed for dynamic environments. Furthermore, standard swarm robotics consensus methods often allow for persistent local discrepancies, whereas blockchain systems require a single, globally agreed-upon state.

Swarm Oracle Architecture

The Swarm Oracle framework addresses these challenges by using a robot swarm as a decentralized, trustless data source. The architecture integrates swarm robotics with a Byzantine fault-tolerant (BFT) protocol and a token-based reputation system.

Overview of the Swarm Oracle architecture and its interaction with public blockchains.

The system employs a multi-layered approach:

  • Robot-Hosted Sidechain: To mitigate the high costs of public blockchains, robots maintain a private Ethereum-based sidechain using Proof-of-Authority (PoA) consensus. This ensures a global, immutable ordering of all robot reports.
  • Byzantine Fault-Tolerant (BFT) Protocol: The system requires a "supermajority" (2/3) of reputation tokens to reach consensus. This threshold ensures safety and liveness even if a significant portion of the swarm is "Byzantine" (malicious or faulty).
  • Clustering for Noisy Data: Real-world sensors are inherently noisy. Swarm Oracle uses incremental k-means clustering to group similar readings into proposals, allowing the swarm to reach an exact agreement on a value (the cluster centroid) despite individual variances.
  • Reputation System: This "self-healing" mechanism requires robots to deposit tokens to vote. Correct votes are rewarded, while lying or abstaining leads to stake loss, effectively diminishing the influence of malicious actors over time.

The Swarm Oracle Protocol

The operational workflow is divided into three distinct steps:

  1. Data Collection: Prompted by a query from a public blockchain, robots self-organize to autonomously gather environmental data using their onboard sensors.
  2. Data Exchange and Ordering: Robots exchange sensor reports via peer-to-peer gossip. At fixed intervals, leaders are elected to assemble new blocks containing these ordered reports.
  3. Protocol Enactment: Every robot executes the deterministic Swarm Oracle smart contract using the ordered reports as inputs. The resulting consensus is an exact value, replicated by all robots independently.

Experimental Validation

The framework was evaluated through short-run physical experiments and long-run simulations. Physical trials utilized a swarm of 12 Pi-puck robots (approx. 22.5 hours of runtime), while simulations in the ARGoS environment covered 400 trials (approx. 278 hours).

Physical experimental setup with Pi-puck robots in an arena.

Key Results

  • Attack Resistance: The system successfully reached correct agreements even when 1/3 of the robots (the theoretical BFT limit) coordinated to lie.
  • Accuracy: Under attack, consensus error remained low (below 20 RGB distance units), matching the performance of an attack-free swarm.
  • Self-Healing: In long-run scenarios, the time to reach consensus dropped from 6 minutes to 3.7 minutes as the reputation system economically "starved" faulty robots.
  • Hardware Feasibility: The study proved that low-cost hardware (Raspberry Pi Zero W) is capable of running full Ethereum nodes and participating in BFT consensus.

Conclusion and Future Work

Swarm Oracle demonstrates that robot swarms can serve as robust, trustless bridges between the physical world and digital blockchains. By treating faults and attacks uniformly and introducing economic costs to adversarial behavior, the system achieves a high level of resilience.

Future research will address physical vulnerabilities, such as "body-walls" where robots physically block others' sensors. Additionally, cryptographic "commit-reveal" schemes could prevent "copycat" behavior, where malicious robots simply mimic the reports of reputable peers.

Summary updated

Abstract

Blockchain consensus, rooted in the principle ``don't trust, verify'', limits access to real-world data, which may be ambiguous or inaccessible to some participants. Oracles address this limitation by supplying data to blockchains, but existing solutions may reduce autonomy, transparency, or reintroduce the need for trust. We propose Swarm Oracle: a decentralized network of autonomous robots -- that is, a robot swarm -- that use onboard sensors and peer-to-peer communication to collectively verify real-world data and provide it to smart contracts on public blockchains. Swarm Oracle leverages the built-in decentralization, fault tolerance and mobility of robot swarms, which can flexibly adapt to meet information requests on-demand, even in remote locations. Unlike typical cooperative robot swarms, Swarm Oracle integrates robots from multiple stakeholders, protecting the system from single-party biases but also introducing potential adversarial behavior. To ensure the secure, trustless and global consensus required by blockchains, we employ a Byzantine fault-tolerant protocol that enables robots from different stakeholders to operate together, reaching social agreements of higher quality than the estimates of individual robots. Through extensive experiments using both real and simulated robots, we showcase how consensus on uncertain environmental information can be achieved, despite several types of attacks orchestrated by large proportions of the robots, and how a reputation system based on blockchain tokens lets Swarm Oracle autonomously recover from faults and attacks, a requirement for long-term operation.
BibTeX
@misc{pacheco2025swarm,
  author = {Alexandre Pacheco and Hanqing Zhao and Volker Strobel and Tarik Roukny and Gregory Dudek and Andreagiovanni Reina and Marco Dorigo},
  title = {{Swarm Oracle: Trustless Blockchain Agreements through Robot Swarms}},
  year = {2025},
  eprint = {2509.15956},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2509.15956},
}
Figure