Skip to content

nicoware-dev/hivex

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

HiveX: MultiversX DeFi Agent Swarm

HiveX Logo

Revolutionizing MultiversX DeFi with AI-Powered Agent Swarms

Simplify your MultiversX DeFi experience with the power of Multi-Agent Systems (MAS)

Discord X Demo Video Linktree Website Gitbook

💥 MultiversX AI Agent Hackathon 💥

📚 Table of Contents

🌟 Overview

HiveX is an innovative open-source project revolutionizing the MultiversX DeFi landscape through AI-powered agent swarms. By employing a sophisticated multi-agent system, HiveX streamlines and automates DeFi operations, offering users a seamless and efficient experience on MultiversX. Its modular design ensures scalability and adaptability, empowering users to navigate the complexities of DeFi with ease and confidence.

You can find detailed information in our system overview, and complete whitepaper.

Why Multi-Agent Systems (MAS)?

Our platform leverages a Multi-Agent System architecture where each agent specializes in specific tasks—from fetching metrics to executing trades—enabling modular, scalable, and efficient operations. This approach ensures:

  • 🎯 Specialization: Optimized performance through task-specific agents
  • 📈 Scalability: Easy addition of new agents and features
  • 🛡️ Robustness: Continued operation even if individual agents fail
  • ⚡ Efficiency: Parallel task execution for improved performance
  • 🔄 Adaptability: Seamless integration with new protocols and APIs

Learn more about our agent system in the agents documentation.

HiveX Architecture

HiveX Architecture

✨ Features

Core Features

  • 💬 Natural language processing
  • 🔍 RAG (Retrieval-Augmented Generation) Knowledge Base
  • 🤖 Multi-Agent System (MAS): 18 AI Agents included.
  • 🔅 Integrated Website & Web App
  • 🛠️ Full-featured Discord, Twitter and Telegram connectors
  • 🔗 Support for every model (Llama, Grok, OpenAI, Anthropic, etc.)
  • 👥 Multi-agent and room support
  • 📚 Easily ingest and interact with your documents
  • 💾 Retrievable memory and document store
  • 💰 Real-time prices using CoinGecko API
  • 🚀 Real-time TVL using DefiLlama API
  • 📊 Real-time Pools data using GeckoTerminal
  • 📝 Text generation and analysis
  • 🎨 Image generation and description
  • 🗣️ Speech synthesis and recognition
  • 📊 Data visualization
  • 🌐 Web browsing capabilities
  • 🚀 Highly extensible - create your own actions and clients

MultiversX Features

  • 💰 Wallet management and balance tracking
  • 💸 Token transfers (EGLD and ESDT tokens on MultiversX)
  • 🔍 Transaction and block explorer functionality
  • 📊 Swap operations on AshSwap & xExchange
  • 💵 Lending & Borrowing on Hatom
  • 📈 Real-time price tracking via CoinGecko integration
  • 🌐 Network statistics and blockchain metrics
  • 💹 DeFi protocol analytics via DefiLlama integration
  • 🔐 MultiversX wallet generator for AI agents

🖥️ Web App Features

  • 🚀 Landing page
  • 🎨 Modern, responsive design
  • 📄 Agents Directory
  • 🤖 Chat with Agent Swarm through web interface
  • 👛 MultiversX wallet connector (WIP)
  • 📊 Portfolio & Analytics dashboard (WIP)
  • 📝 Transaction History (TBD)
  • 🌐 Token Gating (TBD)
HiveX Client Interface

HiveX Web Client

🧰 Tech Stack

  • ElizaOS
  • Vite
  • TailwindCSS
  • ShadcnUI
  • Typescript
  • Python
  • NodeJS
  • n8n (Workflow Automation and agent orchestration)

🤖 Agent Categories

For complete details about each agent's capabilities and use cases, see our agents documentation.

🏢 Internal Agents (Platform Operations)

  1. 💼 Sales Agent: Customer relations and onboarding
  2. 🎨 Meme Agent: Social media marketing agents promoting HiveX
  3. 🎮 Demo Agent: Interactive platform demonstration and feature showcase

🌐 Public Agents (Shared Services)

  1. 📊 Metrics Agent: Provides protocol TVL, prices, and performance metrics
  2. 🔍 Alpha Agent: Market opportunities, Twitter and Web Scraping
  3. 📈 Analyst Agent: Risks, performance, and market analysis
  4. 🖼️ NFTs Agent: NFT intelligence and market analysis
  5. 📣 KOL Agent: Social media service
  6. 📝 Token Deployer: Token and liquidity pool deployment
  7. 🎨 NFT Deployer: NFT Collection deployment
  8. 🔷 MultiversX Expert: Documentation, resources, tips and advice for MultiversX users and devs
  9. 🎮 Predictions Agent: Trend analysis and predictions

🔒 Private Agents (Custom Deployments)

  1. 🎨 Coordinator Agent: Advanced orchestration system implemented in n8n for multi-agent operations. Features voice and text interactions via Telegram, with the ability to delegate tasks to specialized agents across different frameworks.
  2. 💱 DeFi Agent: Manages DeFi operations (Staking, etc.)
  3. 📈 Trading Agent: Manages trading operations (position management, rebalancing, strategies, etc.)
  4. 👛 Wallet Agent: Manages MultiversX wallet operations (Transfers, Signatures, etc.)
  5. 🏛️ DAO Agent: Manages DAO operations (Treasury management, proposal management, DAO metrics, etc.)
  6. 💡 Advisor Agent: Manages strategy planning and provides advice

🏠 Self-Hosting (Recommended)

HiveX is and will always be open source! We strongly encourage users to self-host their own instance of HiveX. This gives you full control over your data and agents while learning about the technology.

For detailed implementation guidance, see our plugin documentation.

Requirements for Self-Hosting

  • Server or cloud instance (e.g., AWS, DigitalOcean, or your local machine)
  • API keys for required services.
  • Basic knowledge of TypeScript/Node.js for customization

Support

While self-hosting is a DIY approach, we provide:

  • Detailed documentation
  • Community support via Discord
  • GitHub issues for bug reports
  • Basic setup guidance

Service Packages

Note: The following service packages are not yet launched but will be available soon through early access. For now, we recommend self-hosting your own instance!

For detailed service descriptions and future offerings, see our services documentation.

🚀 Quick Start

Prerequisites

Note for Windows Users: WSL 2 and Visual Studio Build Tools are required.

Installation

# Clone the repository
git clone https://github.com/nicoware-dev/hivex
cd hivex/eliza

# Install dependencies
pnpm install --no-frozen-lockfile

# Copy environment file
cp .env.example .env

Configuration

Edit .env file and add your credentials:

# Required for MultiversX operations
MVX_PRIVATE_KEY=your_private_key
MVX_NETWORK=mainnet  # or devnet or testnet

# Choose an API provider and add the API_KEY on the env file
OPENAI_API_KEY=                # OpenAI API key, starting with sk-
ANTHROPIC_API_KEY=             # For Claude (optional)

# Client Configuration
DISCORD_APPLICATION_ID=        # Discord bot ID
DISCORD_API_TOKEN=             # Discord bot token
TELEGRAM_BOT_TOKEN=            # Telegram bot token
TWITTER_USERNAME=              # Twitter username
TWITTER_PASSWORD=              # Twitter password
TWITTER_EMAIL=                 # Twitter email

# Web Search (Optional)
TAVIL_API_KEY=                 # Tavil API key

Running the Agent

# Build the project
pnpm build

# Start a single agent (Recommended for testing)
pnpm start:debug --characters="characters/demo1-agent.character.json"

# Start demo agents (5)
pnpm start --characters="characters/demo-agent.character.json,characters/metrics-agent.character.json,characters/sales-agent.character.json,characters/meme-agent.character.json,characters/multiversx-expert-agent.character.json"

# Start all agents (18)
pnpm start --characters="characters/coordinator.character.json,characters/metrics-agent.character.json,characters/sales-agent.character.json,characters/meme-agent.character.json,characters/nfts-agent.character.json,characters/alpha-agent.character.json,characters/analyst-agent.character.json,characters/trading-agent.character.json,characters/wallet-agent.character.json,characters/dao-agent.character.json,characters/defi-agent.character.json,characters/demo-agent.character.json,characters/kol-agent.character.json,characters/token-deployer-agent.character.json,characters/nft-deployer-agent.character.json,characters/multiversx-expert-agent.character.json,characters/predictions-agent.character.json,characters/advisor-agent.character.json"

Running the Web Client

In a new terminal, run the following command:

cd client
pnpm run dev

🧪 How to use?

For comprehensive usage examples and advanced features, see our plugin documentation.

Interact with the agents with these example prompts:

Network Information

What is MultiversX?

Web Search

Search the web for latest news on MultiversX and its Ecosystem

TVL Metrics (DefiLlama)

Show me MultiversX's TVL
What are the top 5 protocols on MultiversX by TVL?
What's the tvl of Hatom?
What's the tvl of xExchange?

Price Metrics (CoinGecko)

Get prices for ETH, BTC and EGLD
Get EGLD price

Wallet Operations

Show me my MultiversX wallet info
Show my portfolio

Token Transfers

Send 0.001 EGLD to erd1jpwn5nmjpmph0lu7h50q0a98w34cm9jjt2acaz64mlumd6phc3us360s7k
Send 0.01 USDC to erd1jpwn5nmjpmph0lu7h50q0a98w34cm9jjt2acaz64mlumd6phc3us360s7k

Create a new token

Create a token named TestToken with ticker TST and supply of 1000000

Explorer Provider

Get info for wallet erd1jpwn5nmjpmph0lu7h50q0a98w34cm9jjt2acaz64mlumd6phc3us360s7k
Show me network stats

Swap Tokens

Swap 0.001 EGLD for USDC on AshSwap

Lending & Borrowing

Supply 0.01 EGLD to Hatom
Add 0.1 HEGLD as collateral to Hatom
Borrow 0.0001 USDC from Hatom
Repay 0.0001 USDC to Hatom
Remove 0.1 HEGLD as collateral from Hatom
Redeem 0.1 HEGLD from Hatom

Wallet Generator

# Generate a new MultiversX wallet for your AI agent
cd multiversx-wallet
python3 wallet_generator.py

# Load an existing wallet
python3 load_wallet.py --file wallet_data/wallet.json

# Sign a transaction
python3 sign_transaction_example.py wallet_data/wallet.json <receiver_address> <amount>

🔍 Important Notes

  • Ensure you have sufficient funds for transaction fees.
  • Always double-check addresses and amounts before executing transactions.
  • The MultiversX wallet generator creates wallets that can be used by your AI agents to interact with the MultiversX blockchain. Keep your private keys secure.
  • For more details on the wallet generator, see the multiversx-wallet/README.md file.

Project Structure

README.md                             # This file
docs/                                 # Documentation
  ├── pitch-deck.pdf                      # HiveX Pitch Deck
  ├── agents.md                           # Agents documentation
  ├── branding.md                         # Branding guidelines
  ├── contributing.md                     # Contribution guidelines
  ├── deployment.md                       # Deployment guide
  ├── faqs.md                            # Frequently Asked Questions
  ├── features.md                         # Features documentation
  ├── index.md                           # Documentation home
  ├── integrations.md                    # Integration guides
  ├── links.md                           # Important links
  ├── multi-agent-system.md              # MAS architecture details
  ├── n8n.md                             # n8n workflow documentation
  ├── overview.md                         # Project overview
  ├── plugin.md                          # Plugin documentation
  ├── quick-start.md                     # Quick start guide
  ├── self-hosting.md                    # Self-hosting instructions
  ├── services.md                        # Services documentation
  ├── system-overview.md                 # System architecture overview
  ├── user-guide.md                      # User guide
  ├── whitepaper.md                      # Project whitepaper
  └── resources/                         # Documentation resources
assets/                               # Branding Assets & Guidelines
multiversx-wallet/                    # MultiversX wallet generator for AI agents
  ├── wallet_generator.py                # Generate new MultiversX wallets
  ├── load_wallet.py                     # Load existing wallets
  ├── sign_transaction_example.py        # Example for signing transactions
  └── README.md                          # Wallet generator documentation
eliza/                                # Eliza project
  ├── packages/
  │   ├── core/                       # Eliza core functionality
  │   ├── plugin-hivex/               # MultiversX integration
  │   │   ├── src/
  │   │   │   ├── actions/      
  │   │   │   │   ├── esdtTransfer    # ESDT Transfer Action
  │   │   │   │   ├── transfer-egld   # EGLD Transfer Action
  │   │   │   │   └── portfolio       # Portfolio Action
  │   │   │   ├── providers/    
  │   │   │   │   ├── coingecko       # CoinGecko Provider
  │   │   │   │   ├── defillama       # DefiLlama Provider
  │   │   │   │   └── wallet          # MultiversX Wallet Provider
  │   │   │   └── ...
  │   │   ├── templates/    
  │   │   ├── types/        
  │   │   └── utils/        
  └── client/                         # Custom Web App
n8n/                       # n8n workflow configurations
  ├── coordinator-agent.json         # Main coordinator agent workflow
  ├── eliza-agent-tool.json         # Eliza agent integration
  ├── COORDINATOR_SYSTEM.md         # Coordinator system documentation
  └── other/                        # Additional workflow configurations

🤝 Contributing

  1. Fork the repository
  2. Create your feature branch
  3. Commit your changes
  4. Push to the branch
  5. Create a Pull Request

Built with ❤️ by the HiveX team

Discord X