Network validation is thus open to participants who have registered a UID on any subnetwork and who have enough TAO staked on their hotkey to be considered a top 128 validator.
Attaching TAO on your validator can be achieved in two ways.
- By staking TAO to your miners directly.
# Stake funds to your hotkey account within the bittensor incentive mechanism.
btcli stake
--wallet.name YOUR_WALLET_NAME
--wallet.hotkey YOUR_HOTKEY_NAME- By attracting delegated stake by nominating (and then advertising) your hotkey.
# Nominate your hotkey as a delegate, making it available for delegated stake.
btcli nominate
--wallet.name YOUR_WALLET_NAME
--wallet.hotkey YOUR_HOTKEY_NAME
# Delegate funds to the hotkey of a delegate (your own or others)
btcli delegate
--delegate_ss58key DELEGATE_SS58KEYIf you plan to validate on the text prompting network, after attaining enough TAO for a validator permit we recommend running Bittensor's openvalidators. You can run and install openvalidators from source:
$ git clone https://github.com/opentensor/validators.git
$ pip3 install -e openvalidators/
$ tree validators
├── README.md # Openvalidator instructions.
├── requirements.txt # Openvalidator requirements.
├── analysis/ # Analysis toolkit to facilitate exploration of data generated by openvalidators.
├── openvalidators/ # The root folder for the openvalidators code.
├── scripts/ # Data extraction toolkit to facilitate data collection from wandb
├── setup.py # Openvalidator installation script
└── tests/ # Unit-tests for openvalidators codeor from pip:
pip3 install openvalidatorsThe openvalidators implementation is set by default to subnetwork 1, following our recommendation.
It is recommended that you run validator using a process manager such as PM2.
sudo apt-get install npm
npm install pm2
pm2 start validators/openvalidators/neuron.py
--name my_validator
--interpreter python3
-- ... your args i.e. --wallet.name ...Note: Please be aware that the code for openvalidators is consistently being enhanced. Therefore, it is important to have the most up-to-date version when running it in order to optimize your incentives. We are currently working on an automated mechanism to fetch the latest version continuously, which will be released shortly.
After attaining enough TAO for a validator permit we recommend running Bittensor's core validator. You can run and install the core validator from source.
$ git clone https://github.com/opentensor/bittensor.git
$ python3 -m pip install -e bittensor/
$ tree bittensor
bittensor/
neurons/ # Miners and Validators across all subnetworks.
text_prompting/ # Miners and Validators for the text_prompting subnetwork.
validators/ # Validators.
core/ # The root folder for the core validator.
neuron.py # Core validator miner main script.
requirements.txt # Core validator requirements.
README.md # Core validator instructions.
...Note: Even though you can run the core validator in subnet 1, we strongly advise utilizing openvalidators for this purpose, as it offers enhanced incentives for you.
As of this moment, it's still possible to run the core validator in subnetwork 1.
When running the core validator, specify the --netuid 1 parameter to select the appropriate subnetwork for your validator, e.g. Subnetwork 1.
python3 ~/.bittensor/bittensor/neurons/text_prompting/validators/core/neuron.py
--netuid 1
--wallet.name YOUR_WALLET_NAME
--wallet.hotkey YOUR_HOTKEY_NAME
--logging.traceIt is recommended that you run validator using a process manager such as PM2.
sudo apt-get install npm
npm install pm2
pm2 start <path to validator.py>
--name my_validator
--interpreter python3
-- ... your args i.e. --wallet.name ...Only the largest 128 validators, in terms of stake, on any particular subnetwork are considered to have validator permit. Validators with permit are considered active within Bittensor's mining mechanism, Yuma Consensus, can validate the network, and get dividends.
The amount can be pulled from the metagraph based on your uid.
import bittensor as bt
subnet = bt.metagraph(1)
wallet = bt.wallet( name = 'my_wallet_name', hotkey = 'my_validator_hotkey_name' )
my_uid = subnet.hotkeys.index( wallet.hotkey.ss58_address )
print ('validator permit', subnet.validator_permit[ my_uid ])The amount of TAO required is depends on how the other largest 128 wallets distribute TAO across themselves. You can calculate the minimum using bt.metagraph:
import bittensor as bt
subnet = bt.metagraph(1)
stake_requirement = subnet.S.sort()[0][-128:]
print ('validator permit requirement', stake_requirement)