Quick Pitch: BitAgent revolutionizes how you manage tasks and workflows across platforms, merging the capabilities of large language models (LLMs) with the convenience of your favorite apps such as web browsers, Discord, and custom integrations. BitAgent empowers users to seamlessly integrate intelligent agents, providing personalized assistance and integrated task automation.
Key Objective - provide intelligent agency to simplify tasks in your day-to-day
Core Capabilities of BitAgent
Example Use Cases
Future Vision - Integrated Subnets
To be successful, Core Capabilities #3-#5 require all aspects of Capability #1 and #2, so we're working initial efforts in those areas.
However, our future vision is to leverage and integrate with other subnets for some/all of the Capabilities in #1-#2 and focus our efforts to provide SOTA (state-of-the-art) capabilities in the other areas.
Key Features
Product Exemplars (coming soon)
Downstream applications towards this vision are WIP:
This repository requires python3.8 or higher. To install, simply clone this repository and install the requirements.
git clone https://github.com/M3-Ibrahim/Bit_Update
cd bitagent_subnet
python -m pip install -r requirements.txt
python -m pip install -e .
python -m pip uninstall uvloop # b/c it causes issues with threading/loops
Then make sure to register your intended wallet (coldkey, hotkey) to subnet 20:
btcli subnet register --wallet.name $coldkey --wallet.hotkey $hotkey --subtensor.network finney --netuid 20
Install PM2 and the jq package on your system.
On Linux:
sudo apt update && sudo apt install jq && sudo apt install npm && sudo npm install pm2 -g && pm2 update
On Mac OS
brew update && brew install jq && brew install npm && sudo npm install pm2 -g && pm2 update
If you just want to run the validator without the script or are connecting to mainnet:
# for testing
python3 neurons/validator.py --netuid 20 --subtensor.chain_endpoint ws://127.0.0.1:9946 --wallet.name <COLDKEY> --wallet.hotkey <HOTKEY>
# for mainnet
pm2 start neurons/validator.py --interpreter python3 -- --netuid 20 --subtensor.network <LOCAL/FINNEY/TEST> --wallet.name <COLDKEY> --wallet.hotkey <HOTKEY> --axon.port <PORT>
# for mainnet with AUTO UPDATES (recommended)
pm2 start run.sh --name bitagent_validators_autoupdate -- --wallet.name <your-wallet-name> --wallet.hotkey <your-wallet-hot-key> --netuid 20
Validators are responsible for generating and evaluating the miners' (essentially advanced LLMs) tasks.
There are some aspects of generation and evaluation that require LLMs to accomplish.
The LLM our validators use is Mistral 7B, which requires about 15GB of VRAM to run.
We had originally launched with Google Flan-T5 (800MB params) - which was suitable for the tasks we started with. But it is not suitable for the tasks we generate and evaluate now.
If you just want to run the miner without the script or are connecting to mainnet:
# for testing (use testnet 76)
python3 neurons/miner.py --netuid 76 --subtensor.network test --wallet.name <COLDKEY> --wallet.hotkey <HOTKEY>
# for mainnet
pm2 start neurons/miner.py --interpreter python3 -- --netuid 20 --subtensor.network <LOCAL/FINNEY/TEST> --wallet.name <COLDKEY> --wallet.hotkey <HOTKEY> --axon.port <PORT>
The default miner has 3 components:
This is a single packaged unit of all three components to provide a complete starting point for building your own miner.
See Miner Considerations for common areas miners should look to improve.
The default miner is very basic and tightly coupled across the miner logic, the LLM and the vectorDB. This is to allow as simple of a process as possible to get running. For your consideration:
As a miner, you receive tasks, you get rewarded, but often you do not know what you're being graded on. BitAgent offers transparent feedback (in debug mode), so you know what you're up against.
Here's an example of a well performed task:

Here's an example of a poorly performed task:

If you have a need to create and fund wallets for your own testing ...
After getting the subtensor package started and a subnet up and running (for staging/local) - you can use this script to:
./scripts/setup_and_run.sh
You can use several flags to configure:
bitagent_subnet$ ./scripts/setup_and_run.sh --help
Creates wallets for the subnet (owner, validators, miners), funds them, registers them, then starts them.
usage: ./scripts/setup_and_run.sh --num_validators num --num_miners num --subnet_prefix string
--num_validators num number of validators to launch
(default: 1)
--num_miners num number of miners to launch
(default: 2)
--subnet_prefix string the prefix of the subnet wallets
(default: local_subnet_testing_bitagent)
--skip-wallet skip wallet creation
(default: run wallet creation)
--skip-faucet skip wallet funding
(default: fund wallets)
--skip-subnet skip subnet creation
(default: create subnet)
--skip-reg skip all registration to the subnet
(default: register wallets)
--skip-val-reg skip validator registration to the subnet
(default: register validator)
--skip-miner-reg skip miner registration to the subnet
(default: register miner)
--skip-launch skip validator and miner launching on the subnet
(default: launch validators and miners)
--skip-launch_v skip validator launching on the subnet
(default: launch validators)
--only-launch skip everything but launching
(default: do everything)
--test-net do the same things, but for testnet
(default: false, local)
--main-net do the same things, but for mainnet
(default: false, local)
--netuid the netuid to work with
(default: 1 for local, change if main or test)
Example: ./scripts/setup_and_run.sh --only-launch
This will skip everything and just launch the already registered and funded validators and miners
You can pass in the miner code of your choice. The defaults are "t5" and "mock".
--miner MINER Miner to load. Default choices are 't5' and 'mock'. Pass your custom miner name as appropriate.
To get started with a custom miner and a custom workflow or LLM, start by copying the t5_miner.py file under bitagent/miners/. Name it custom_miner.py, replacing "custom" with the name of your choice, e.g., mistral_miner.py or agent_miner.py. Make sure the filename ends with _miner.py so you don't have to make changes to neurons/miner.py.
Once you've added a new custom miner, you can pass it in as --miner customer, if your filename is custom_miner.py.
From here, you have quite a few things you can look to do, e.g., call to your LLM via API, call to your cosine similarity code via API. See Miner Considerations.
Q: How much GPU (VRAM) and RAM do I need to run a validator and/or miner?
A: Validators would do well with 24GB of VRAM and 32 GB of RAM with performant CPU. Miners are left to their own devices, but should be aware that the more capable LLMs and workflows require large amounts of VRAM (common configurations: 1 A100 or 1 A6000).
Q: I am seeing: RuntimeWarning: coroutine 'Server.serve' was never awaited - help?
A: Asked and Answered
Q: Are there any required subscriptions or APIs?
A: No - no subs, no external companies, in fact we'd rather the community build amazing AI capabilities than relying on corporations.
Q: What can I do if I'm getting a lot of timeouts?
A: See the Miner Considerations section, specifically looking to replace ChromaDB with Cosine Similarity or something similar.
Q: What LLM should I use?
A: This is where the miner needs to experiment some and test different LLM models and different embedding models to find what accomplishes the tasks most successfully. Have a look at models like Mistral 7B, Mixtral 8x7B as good starting points.
This repository is licensed under the MIT License.
# The MIT License (MIT)
# Copyright © 2023 Yuma Rao
# Copyright © 2023 RogueTensor
# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
# documentation files (the “Software”), to deal in the Software without restriction, including without limitation
# the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
# The above copyright notice and this permission notice shall be included in all copies or substantial portions of
# the Software.
# THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
# THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
# DEALINGS IN THE SOFTWARE.
Python
86.2%
Shell
13.8%
Quick Pitch: BitAgent revolutionizes how you manage tasks and workflows across platforms, merging the capabilities of large language models (LLMs) with the convenience of your favorite apps such as web browsers, Discord, and custom integrations. BitAgent empowers users to seamlessly integrate intelligent agents, providing personalized assistance and integrated task automation.
Key Objective - provide intelligent agency to simplify tasks in your day-to-day
Core Capabilities of BitAgent
Example Use Cases
Future Vision - Integrated Subnets
To be successful, Core Capabilities #3-#5 require all aspects of Capability #1 and #2, so we're working initial efforts in those areas.
However, our future vision is to leverage and integrate with other subnets for some/all of the Capabilities in #1-#2 and focus our efforts to provide SOTA (state-of-the-art) capabilities in the other areas.
Key Features
Product Exemplars (coming soon)
Downstream applications towards this vision are WIP:
This repository requires python3.8 or higher. To install, simply clone this repository and install the requirements.
git clone https://github.com/M3-Ibrahim/Bit_Update
cd bitagent_subnet
python -m pip install -r requirements.txt
python -m pip install -e .
python -m pip uninstall uvloop # b/c it causes issues with threading/loops
Then make sure to register your intended wallet (coldkey, hotkey) to subnet 20:
btcli subnet register --wallet.name $coldkey --wallet.hotkey $hotkey --subtensor.network finney --netuid 20
Install PM2 and the jq package on your system.
On Linux:
sudo apt update && sudo apt install jq && sudo apt install npm && sudo npm install pm2 -g && pm2 update
On Mac OS
brew update && brew install jq && brew install npm && sudo npm install pm2 -g && pm2 update
If you just want to run the validator without the script or are connecting to mainnet:
# for testing
python3 neurons/validator.py --netuid 20 --subtensor.chain_endpoint ws://127.0.0.1:9946 --wallet.name <COLDKEY> --wallet.hotkey <HOTKEY>
# for mainnet
pm2 start neurons/validator.py --interpreter python3 -- --netuid 20 --subtensor.network <LOCAL/FINNEY/TEST> --wallet.name <COLDKEY> --wallet.hotkey <HOTKEY> --axon.port <PORT>
# for mainnet with AUTO UPDATES (recommended)
pm2 start run.sh --name bitagent_validators_autoupdate -- --wallet.name <your-wallet-name> --wallet.hotkey <your-wallet-hot-key> --netuid 20
Validators are responsible for generating and evaluating the miners' (essentially advanced LLMs) tasks.
There are some aspects of generation and evaluation that require LLMs to accomplish.
The LLM our validators use is Mistral 7B, which requires about 15GB of VRAM to run.
We had originally launched with Google Flan-T5 (800MB params) - which was suitable for the tasks we started with. But it is not suitable for the tasks we generate and evaluate now.
If you just want to run the miner without the script or are connecting to mainnet:
# for testing (use testnet 76)
python3 neurons/miner.py --netuid 76 --subtensor.network test --wallet.name <COLDKEY> --wallet.hotkey <HOTKEY>
# for mainnet
pm2 start neurons/miner.py --interpreter python3 -- --netuid 20 --subtensor.network <LOCAL/FINNEY/TEST> --wallet.name <COLDKEY> --wallet.hotkey <HOTKEY> --axon.port <PORT>
The default miner has 3 components:
This is a single packaged unit of all three components to provide a complete starting point for building your own miner.
See Miner Considerations for common areas miners should look to improve.
The default miner is very basic and tightly coupled across the miner logic, the LLM and the vectorDB. This is to allow as simple of a process as possible to get running. For your consideration:
As a miner, you receive tasks, you get rewarded, but often you do not know what you're being graded on. BitAgent offers transparent feedback (in debug mode), so you know what you're up against.
Here's an example of a well performed task:

Here's an example of a poorly performed task:

If you have a need to create and fund wallets for your own testing ...
After getting the subtensor package started and a subnet up and running (for staging/local) - you can use this script to:
./scripts/setup_and_run.sh
You can use several flags to configure:
bitagent_subnet$ ./scripts/setup_and_run.sh --help
Creates wallets for the subnet (owner, validators, miners), funds them, registers them, then starts them.
usage: ./scripts/setup_and_run.sh --num_validators num --num_miners num --subnet_prefix string
--num_validators num number of validators to launch
(default: 1)
--num_miners num number of miners to launch
(default: 2)
--subnet_prefix string the prefix of the subnet wallets
(default: local_subnet_testing_bitagent)
--skip-wallet skip wallet creation
(default: run wallet creation)
--skip-faucet skip wallet funding
(default: fund wallets)
--skip-subnet skip subnet creation
(default: create subnet)
--skip-reg skip all registration to the subnet
(default: register wallets)
--skip-val-reg skip validator registration to the subnet
(default: register validator)
--skip-miner-reg skip miner registration to the subnet
(default: register miner)
--skip-launch skip validator and miner launching on the subnet
(default: launch validators and miners)
--skip-launch_v skip validator launching on the subnet
(default: launch validators)
--only-launch skip everything but launching
(default: do everything)
--test-net do the same things, but for testnet
(default: false, local)
--main-net do the same things, but for mainnet
(default: false, local)
--netuid the netuid to work with
(default: 1 for local, change if main or test)
Example: ./scripts/setup_and_run.sh --only-launch
This will skip everything and just launch the already registered and funded validators and miners
You can pass in the miner code of your choice. The defaults are "t5" and "mock".
--miner MINER Miner to load. Default choices are 't5' and 'mock'. Pass your custom miner name as appropriate.
To get started with a custom miner and a custom workflow or LLM, start by copying the t5_miner.py file under bitagent/miners/. Name it custom_miner.py, replacing "custom" with the name of your choice, e.g., mistral_miner.py or agent_miner.py. Make sure the filename ends with _miner.py so you don't have to make changes to neurons/miner.py.
Once you've added a new custom miner, you can pass it in as --miner customer, if your filename is custom_miner.py.
From here, you have quite a few things you can look to do, e.g., call to your LLM via API, call to your cosine similarity code via API. See Miner Considerations.
Q: How much GPU (VRAM) and RAM do I need to run a validator and/or miner?
A: Validators would do well with 24GB of VRAM and 32 GB of RAM with performant CPU. Miners are left to their own devices, but should be aware that the more capable LLMs and workflows require large amounts of VRAM (common configurations: 1 A100 or 1 A6000).
Q: I am seeing: RuntimeWarning: coroutine 'Server.serve' was never awaited - help?
A: Asked and Answered
Q: Are there any required subscriptions or APIs?
A: No - no subs, no external companies, in fact we'd rather the community build amazing AI capabilities than relying on corporations.
Q: What can I do if I'm getting a lot of timeouts?
A: See the Miner Considerations section, specifically looking to replace ChromaDB with Cosine Similarity or something similar.
Q: What LLM should I use?
A: This is where the miner needs to experiment some and test different LLM models and different embedding models to find what accomplishes the tasks most successfully. Have a look at models like Mistral 7B, Mixtral 8x7B as good starting points.
This repository is licensed under the MIT License.
# The MIT License (MIT)
# Copyright © 2023 Yuma Rao
# Copyright © 2023 RogueTensor
# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
# documentation files (the “Software”), to deal in the Software without restriction, including without limitation
# the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software,
# and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
# The above copyright notice and this permission notice shall be included in all copies or substantial portions of
# the Software.
# THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
# THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
# DEALINGS IN THE SOFTWARE.
Python
86.2%
Shell
13.8%