Subnet 123
MANTIS
Barbarian
Decentralized AI-driven forecasting subnet rewarding miners for high-quality, information-rich financial predictions.

SN123:MANTIS
| Subnet | Description | Category | Company |
|---|---|---|---|
| SN123:MANTIS | Time Series for BTC Forecasting | Predictive systems | Mantis |
MANTIS is an ambitious Bittensor subnet focused on decentralized financial forecasting. It operates as a specialized validator node (Subnet 123) that incentivizes miners to produce information with real predictive value. In essence, miners on MANTIS submit encoded predictions (embeddings) about future price movements of various assets, and the validator evaluates how much each miner’s data improves the overall prediction. This subnet is often described as a “signal machine” due to its radical, information-theoretic design. It has been deployed with uncommon scientific rigor, ensuring that only genuinely useful signals are rewarded in the ecosystem.
Unlike a traditional predictor, MANTIS doesn’t just try to forecast Bitcoin or other asset prices in isolation – it redefines how useful information is measured, extracted, and rewarded in a decentralized setting. The system specifically targets the next 1-hour returns of a basket of financial assets (initially focusing on cryptocurrencies like BTC/USD, with plans to include forex pairs). By evaluating miners based on the information-theoretical value their contributions add to predicting these returns, MANTIS creates the first cooperative, incentivized prediction market for asset prices on Bittensor. In fact, the lead developer notes this is “the first decentralized, cooperative, incentivized prediction of BTCUSD in history” – highlighting the groundbreaking nature of the project.
In practical terms, MANTIS continuously collects encrypted prediction data from all participating miners and uses a rigorous workflow to turn those inputs into rewards. It employs time-lock encryption to prevent cheating (miners can’t see actual price outcomes before their predictions are locked) and only decrypts submissions when it’s time to evaluate them. After decryption, the subnet trains an AI model to predict asset returns using all the miners’ data combined, and then uses permutation importance (a machine learning technique) to measure each miner’s marginal contribution to the prediction’s accuracy. Miners whose data significantly improves the model’s performance are considered to have high “salience.” Finally, MANTIS sets on-chain weights to reward miners in proportion to the salience of their contributions, directly linking reward share to the predictive value they provided. In summary, MANTIS transforms decentralized AI predictions into a quantitative signal, and allocates rewards to miners based on information gain – aligning incentives so that miners compete to provide the most useful predictive insights.
Key Functionality Highlights
Financial Prediction Task: Focuses on forecasting 1-hour price returns for a set of assets (starting with Bitcoin/USD, and designed to handle multiple cryptos or forex pairs). Miners submit numeric embeddings that represent their predictive insights for these assets.
Time-Lock Encryption for Fairness: Uses a decentralized randomness beacon (Drand) to lock each submission until a future block, ensuring miners cannot alter or submit predictions after seeing actual price outcomes. This guarantees the predictions are genuine and time-stamped prior to result knowledge.
AI Model Evaluation: Uses an XGBoost-based machine learning model to aggregate all miners’ data and predict price movements. It then applies permutation importance to each miner’s data feature to quantify its contribution (salience) to prediction accuracy. This is an information-theoretic scoring – effectively measuring how much information gain each miner provides to the forecasting task.
On-Chain Reward Setting: The validator automatically writes new weight values to the Bittensor chain, proportional to each miner’s accumulated salience score. In other words, miners who consistently provide more predictive signal get higher weights (and thus earn more $TAO rewards), aligning miner incentives with true signal quality.
Robust Data Integrity: MANTIS includes multiple safeguards – it verifies that each payload actually comes from the claimed miner (by embedding the miner’s hotkey in the data), rejects malformed or out-of-bound data (replacing it with neutral placeholders), and even filters out periods of stale prices (zero volatility periods) so that miners can’t game the system by “predicting” a non-moving price. These measures ensure the model isn’t misled by garbage data or trivial scenarios, maintaining a high-quality signal environment.
All together, MANTIS creates a closed-loop system where miners are encouraged to continuously improve their models to beat the market signal. It’s a modular, information-driven AI subnet that pushes Bittensor into the realm of financial prediction – a bold use case where each miner essentially acts as a small algorithmic trader, and the validator (MANTIS) serves as the objective referee that measures who actually has alpha (skill in prediction) and rewards them accordingly.
MANTIS is implemented as a sophisticated Bittensor validator program (written in Python) that coordinates data collection, model training, and blockchain interactions on Subnet 123. The product is essentially a custom Bittensor subnet build tailored for time-series data. It consists of several core components working in unison to carry out its unique consensus mechanism:
- Orchestrator Loop (validator.py): The main process runs in sync with Bittensor’s blockchain blocks, triggering actions at defined intervals. Every few blocks, it initiates a cycle of operations – from pulling new miner data, to processing and evaluating that data, to updating weights. This orchestrator is the “brain” that ensures all parts of the system execute in the right order and on schedule.
- Data Fetching & Commitments (cycle.py & comms.py): MANTIS uses a commit-reveal scheme. Each miner hosts an HTTP endpoint with their latest encrypted payload (commit). The validator’s cycle component reads the list of active miners from the Bittensor chain and downloads each miner’s payload blob via HTTP. The comms.py module handles these network requests asynchronously and enforces limits (e.g. maximum payload size to prevent spam). This design allows scalable and secure ingestion of miner data from potentially hundreds of sources in parallel.
- Secure Storage & Time-Lock (storage.py – DataLog): Incoming encrypted payloads and price data are appended to a central DataLog structure. The DataLog queues all payloads and waits until enough time has passed (defined by a time-lock delay) to decrypt them safely. Decryption uses the tlock library and public randomness from Drand, ensuring that each payload is unlocked only after the target time (so miners cannot cheat by submitting after seeing the outcome). The DataLog also keeps historical price data for multiple assets and tracks miner identities (so if a miner’s hotkey changes, their old data won’t be wrongly attributed). All decrypted data is stored in-memory (and can be backed up from a URL on startup), making the validator state self-contained and easy to manage or reset.
- Predictive Model (model.py – XGBoost): At the heart of MANTIS’s AI logic is an XGBoost regression model. Once a batch of fresh data is decrypted and ready, the validator forms a training dataset consisting of recent miner embeddings and the corresponding asset returns (e.g., the actual 1-hour price changes). The model is trained (or updated) to predict the next return from the miners’ combined inputs. Crucially, MANTIS then applies permutation importance on this model – it systematically shuffles each miner’s contribution to see how it affects prediction error. This yields a salience score per miner: if removing or randomizing a miner’s data causes the model to lose accuracy, that miner had valuable signal. The use of a tree-based ensemble (XGBoost) was a deliberate technical choice by the team, as they migrated from an earlier simple neural network (MLP) to XGBoost to reduce noise and improve the clarity of these importance scores. The model’s output is not a public prediction feed, but rather an internal mechanism to benchmark miner performance on the prediction task.
- Blockchain Interface (subtensor via Bittensor SDK): Finally, MANTIS closes the loop by translating salience scores into Bittensor weights updates. After computing each miner’s normalized score, the validator uses the Bittensor subtensor.set_weights() call to update the weights on-chain. This operation effectively tells the Bittensor network how to allocate the next block’s mining rewards (TAO issuance or incentives) among miners on Subnet 123. Miners with higher weights will receive a larger portion of the rewards, directly reflecting their contribution to the collective intelligence of MANTIS. All of this happens automatically on a repeating schedule (every TASK_INTERVAL blocks as configured) without human intervention.
Technical Architecture
The MANTIS codebase is modular and designed for extensibility. Key parameters like the list of tracked assets and their embedding dimensions are centralized in a config file for easy adjustments. The entire pipeline from data ingestion to model evaluation runs continuously, pipelined around the blockchain’s block time. MANTIS also emphasizes security at each step – verifying that each payload actually belongs to the claimed miner (by checking an embedded hotkey in the decrypted data) and validating the structure of data to ignore any corrupt or outlier inputs. By combining these components, the build achieves a trust-minimized oracle for predictions: the system autonomously extracts a signal from the swarm of miners and feeds back a reward mechanism that reinforces good predictions. The entire code is open-source (MIT-licensed) and primarily written in Python (with ~88% Python code), making it accessible for audit and community contribution.
In summary, the MANTIS product is a custom Bittensor subnet runtime that turns a network of AI miners into a collective forecasting engine. It’s not a user-facing app but rather a protocol-level build – one that any TAO holder can interact with by either running a miner to contribute predictions or delegating stake to support the subnet. Its architecture is deliberately modular – for example, one could swap in a different model or salience metric by modifying model.py, or track new assets by tweaking config.py, without overhauling the entire system. This modularity ensures MANTIS can evolve rapidly, which is key given the complexity of financial time-series and the constant search for better signal extraction methods.
MANTIS was conceived and is led by a developer known by the pseudonym “Barbarian.” On social platforms (X/Twitter), Barbarian goes by @Barbarian7676 and has been the driving force behind Subnet 123’s design and implementation. The community acknowledges him as the creator of MANTIS. Barbarian is an active member of the Bittensor ecosystem who has articulated the vision for MANTIS in public. He emphasized the novelty of the project, stating “we are doing (to my knowledge) the first decentralized, cooperative, incentivized prediction of BTCUSD in history!”.
On the development side, the open-source repository for MANTIS (hosted on GitHub) lists two contributors: Barbariandev (the GitHub handle for Barbarian) and an additional contributor with the handle s0wa48. Barbariandev authored the vast majority of the code (including core modules and the detailed whitepaper/README), indicating that Barbarian is the principal engineer of the project. The second contributor, s0wa48, has also been acknowledged, though their role appears to be smaller – possibly assisting with code or research contributions.
The MANTIS team is relatively small and agile. There isn’t a formal corporate entity behind MANTIS; it is more of a community-driven project. However, the professionalism of the implementation (e.g., rigorous whitepaper, security considerations, etc.) speaks to the team’s strong technical background. Barbarian himself has engaged with the community to refine the subnet – for example, discussing technical updates (like switching models for better performance) and future plans. This openness suggests the team values collaboration and is receptive to improvements.
In summary, Barbarian (lead developer) is the face and brain of MANTIS. The team’s communication has come mostly through technical documentation (the GitHub repo’s whitepaper) and social media updates. The accuracy and depth of MANTIS’s design have been praised by community analysts (such as @CryptoZPunisher on X, who wrote a detailed overview of the subnet) – reflecting well on the team’s capability. With Barbarian at the helm, the project is positioned as a labor of love by a knowledgeable builder in the Bittensor ecosystem, rather than a large funded team. This lean setup hasn’t stopped MANTIS from achieving milestones; if anything, it underscores the power of a single visionary developer aided by community support in the Bittensor network.



