Table of Contents
- Instructions for quick start with Truffle Deployment
Follow the steps below to launch the Oracle contracts using Truffle.
Open two terminals.
On one terminal run: Clone the repo, cd into it, and then run:
$ npm install
$ truffle compile
$ truffle migrate
$ truffle exec scripts/01_DeployTellor.js
- On the second termila run:
$ ganache-cli -m "nick lucian brenda kevin sam fiscal patch fly damp ocean produce wish"
- On the first terminal run:
$ truffle test
- And wait for the message 'START MINING RIG!!'
- Kick off the python miner file ./miner/testMinerB.py.
Production and test python miners are available under the miner subdirectory here. You will need to get at least 5 miners running.
Step by step instructions on setting up a Mineable Oracle without truffle are available here: Detailed documentation for self setup
Ethereum smart contracts cannot access off-chain data. If your smart contract relies on off-chain (e.g. internet) data to evaluate or execute a function, you either have to manually feed the data to your contract, incentivize users to do it, or rely on a centralized party to provide the data (Oraclize.it is generally the standard).
The tellor oracle is a decentralized oracle. It provides a decentralized alternative for contracts to interact with and obtain data from off-chain (aka API data).
Tellor implements a hybrid Proof-of-work (PoW)/Proof-of-Stake (PoS) model where miners have to stake tellor tributes (tellor's native token) to be able to mine and along with the PoW solution they also provide an off-chain data point. The first five miners to provide the PoW and off-chain data point are rewarded: the miner with the median value is given the highest reward since that is what is used as the 'official' value and the four miners get a lower reward that decreases the further they are from the median. Once validated and processed the value is available for on-chain contracts to use. The value can be disputed by anyone holding tellor tributes within 10 blocks after being mined for a fee. After the value goes to dispute, anyone holding tributes can vote on it's validity. If the vote determines the value was invalid the reporting party gets awarded the miner's stake, otherwise the wrongly accused miner gets the reporting fee.
A deep dive in methodology is available here: In-Depth Overview
High level inspiration from EIP918 Mineable Token.
Why we need a decentralized option? Checkout: "Trusted third parties are security holes" ~ Nick Szabo, 2001
Metamask - www.metamask.io
Truffle - http://truffleframework.com/
If you have questions, ask us on Slack: https://deriveth.slack.com/
Check out or issues log here on Github or contribute to our future plans to implement a GPU miner(not built in python), provide a way to pay in Ether for data, and improve our reward/incentives mechanism.
Any contributions are welcome!
We are happy to report that a successful Tellor build has successfully compiled and been deployed to the Rinkeby testnet.
July 8, 2018--A proof-of-work oracle project that was the first iteration of this idea was a submission to Angel Hack's Washington DC Hackathon hosted on July 7th - 8th. It was designed, spec'ed, built, and deployed in a 24-hour agile sprint. For a quick overview of the oracle origins checkout our article, Proof-of-Work Oracle.
September 30, 2018--This project has been revised to improve efficiency.
December 10, 2018 -- This project has been revised to improve security.
We invite you to audit and test our project - and submit any issues to the repo directly.
This repository is maintained by the Tellor team - www.tellor.io
Tellor Inc. 2019