Spin up a validator

Start the AI Service

Prerequisite

Must have conda installed, follow the instruction here.

Clone the uomi-node-ai repo

Installation Steps

1. Set up Conda Environment

First, open a terminal and create a new conda environment:

conda create -n uomi-ai python=3.10 -y

If you've just installed Miniconda/Anaconda, initialize conda in your shell:

# For bash users
source ~/miniconda3/etc/profile.d/conda.sh
# For zsh users
source ~/miniconda3/etc/profile.d/conda.sh

# Activate the environment
conda activate uomi-ai

2. Install PyTorch with CUDA Support

Install PyTorch and related packages:

Verify the installation:

This should print True if CUDA is properly installed.

3. Install CUDA Development Tools

Install CUDA toolkit and NVCC compiler:

Verify the installation:

4. Install Additional Dependencies

Install the required Python packages:

Troubleshooting

Common Issues

  1. CUDA Not Found

    • Verify NVIDIA drivers are installed: nvidia-smi

    • Check CUDA installation: nvcc --version

    • Ensure PyTorch CUDA is properly installed: python -c "import torch; print(torch.version.cuda)"

  2. Build Failures

    • Ensure you have build tools installed:

    • For Auto-GPTQ issues, try installing from source:

  3. Version Conflicts

    • If you encounter package conflicts, try creating a fresh environment

    • Consider using pip install --no-deps for problematic packages

Verification

To verify the complete setup, run this test script:

Create the service

  1. Create a new systemd service file for the AI component:

  1. Add the following content to the service file:

Important Notes:

  • The WorkingDirectory path (/home/uomi/uomi-node-ai) should be adjusted to match your actual installation directory

  • The ExecStart command assumes:

    • Miniconda is installed in /home/uomi/miniconda3

    • A conda environment named uomi-ai exists

    • The main Python script is named uomi-ai.py

  • Modify these paths and names according to your specific setup

  1. Enable and start the AI service:

  1. Verify the service is running:

  1. Monitor the AI service logs:

Set-up the validator Node

Download the binary

Make sure to download the uomi bin and genesis file on your machine from: https://github.com/Uomi-network/uomi-node/releases/latest

Directory Structure Setup

Create the necessary directories and set appropriate permissions:

Binary and Genesis Setup

Get available peers at https://app.uomi.ai/peers

Add copied peers inside the genesis.json file:

Then install binary and genesis files:

  1. Copy the Uomi binary to the correct location:

  1. Copy the genesis file:

Create validator account

This account is the one that will validate blocks and will save output from Agents

You will get something like:

Generate Ed25519 key for GRANDPA using the same seed phrase:

you'll need the secret phrase and the secret seed later.

Systemd Service Configuration

Create a systemd service file at /etc/systemd/system/uomi.service:

Enable and start the service:

Add your key to your node

Once your node is running, insert your keys:

This data will be stored on your local node, no one can have access to them.

Add the account

Now you can import the account you created previously with SECRET_PHRASE to your wallet extension and fund it with the tokens you want to bond

Verify synchronization

Before jumping to the next steps, you have to wait until your node is fully synchronized. This can take a long time depending on the chain height.

Check the current synchronization:

Session Keys

Author session keys

Run the following command to author session keys:

The result will look like this (you just need to copy the result):

Register as validator

Go to the Polkadot.js portal and connect to the network.

Go to Network > Staking > Accounts and then select Validator on the right

Select the account you funded previously, the amount you want to bond and the payment method and click next.

Now insert the key you copied before and follow the instructions, click "bond & validate" and then submit the transaction.

INFO Onboarding takes place at n+1 session.

You can now set your identity.

Last updated