Methods of payment Abuse

GaiaNet. Installing the node

20.09.2024, 13:59

GaiaNet is a decentralized network providing censorship-resistant, secure and monetizable artificial intelligence (AI) agents. With a large investment ($10,000,000) and the support of funds such as Mirana Ventures and Mantle, the project aims to build a secure infrastructure for AI.

Minimum and recommended requirements

  • Minimum: 4 CPUs, 8 GB RAM, 200 GB SSD

  • Recommended: 8 CPUs, 24 GB RAM, 200 GB SSD

Server rent

You can use servers from the following providers to work with GaiaNet:

  • PQ.Hosting

  • AEZA

  • Hetzner

  • Contabo

Installing the GaiaNet node

GaiaNet offers a handy installation script to simplify the node deployment process.

Installation steps

  1. Install MobaXterm to connect to the server.

  2. Connect to the leased server via SSH using root.

  3. Run the following commands to upgrade the system:

sudo apt update -y
sudo apt-get update
  1. Download and execute the installation script for the node:

curl -sSfL 'https://github.com/GaiaNet-AI/gaianet-node/releases/latest/download/install.sh' | bash
  1. After installation, update the configuration:

source ~/.bashrc
  1. Initialize the node with the configuration:

gaianet init --config https://raw.githubusercontent.com/GaiaNet-AI/node-configs/main/qwen2-0.5b-instruct/config.json
  1. Start the node with the command:

gaianet start
  1. To obtain the Node ID and Device ID, execute:

gaianet info

Copy data and store it in a safe place.

Binding a node to a profile

  1. Go to the GaiaNet website and connect the EVM wallet.

  2. In the profile, we link social networks.

  3. Click the "Add Node" button on the right, enter the previously obtained data (Node ID and Device ID).

  4. Node will be successfully added after clicking on "Join".

Receiving awards

After adding a node, you will be able to track its status and earn points. It is important to interact with the bot regularly, communication is also rewarded with points. Complete tasks on Galxe to get additional rewards.

Interaction with bot

Once the node has been successfully launched, follow the link that was generated in the terminal and click "Chat with this node". The bot will start the interaction and you will be credited with points for communication.

Automating communication with the bot

To simplify the process of communicating with the bot and automate it, you can use a script. Follow the instructions below.

  1. Update and install the necessary packages:

sudo apt update -y
sudo apt install python3-pip -y
sudo apt install nano -y
sudo apt install screen -y
  1. Installing the Python libraries:

pip install requests
pip install faker
  1. Create a script:

nano ~/random_chat_with_faker.py
  1. Insert the following code:

import requests
import random
import logging
import time
from faker import Faker
from datetime import datetime
node_url = "https://АДРЕСВАШЕГОКОШЕЛЬКА.us.gaianet.network/v1/chat/completions"
faker = Faker()
headers = {
    "accept": "application/json",
    "Content-Type": "application/json"
}
logging.basicConfig(filename='chat_log.txt', level=logging.INFO, format='%(asctime)s - %(message)s')
def log_message(node, message):
    logging.info(f"{node}: {message}")
def send_message(node_url, message):
    try:
        response = requests.post(node_url, json=message, headers=headers)
        response.raise_for_status()
        return response.json()
    except requests.exceptions.RequestException as e:
        print(f"Failed to get response from API: {e}")
        return None
def extract_reply(response):
    if response and 'choices' in response:
        return response['choices'][0]['message']['content']
    return ""
while True:
    random_question = faker.sentence(nb_words=10)
    message = {
        "messages": [
            {"role": "system", "content": "You are a helpful assistant."},
            {"role": "user", "content": random_question}
        ]
    }
    question_time = datetime.now().strftime("%Y-%m-%d %H:%M:%S")
    response = send_message(node_url, message)
    reply = extract_reply(response)
    reply_time = datetime.now().strftime("%Y-%m-%d %H:%M:%S")
    log_message("Node replied", f"Q ({question_time}): {random_question} A ({reply_time}): {reply}")
    print(f"Q ({question_time}): {random_question}\nA ({reply_time}): {reply}")
    delay = random.randint(60, 180)
    time.sleep(delay)

Don't forget to replace your PURCHASE ADDRESS with your own address.

  1. Save the file: press CTRL + X, then Y and Enter.

  2. Run the script:

screen -S faker_session
python3 ~/random_chat_with_faker.py

To exit the screen without stopping the script, press CTRL + A, then D.

You can return to the session with the command:

screen -r faker_session


Conclusion

GaiaNet is a promising project that provides a decentralized infrastructure for AI agents. Node installation is fast, thanks to convenient scripts, and interaction with the bot and participation in tasks allows users to earn points.