Welcome to Aelix | Monad AI Agentβan open-source, AI-powered assistant crafted to supercharge your interactions with the Monad Testnet blockchain! π Aelix is your smart sidekick, capable of autonomously executing 10+ blockchain actions with finesse. π
- π Set up and manage your wallet effortlessly
- π° Check your MONAD token balance in a snap
- π€ Send MONAD tokens to any address
- βοΈ Sign messages with top-notch security
- π Peek into your recent transaction history
- β½ Fetch live gas price estimates
- πΉ Get real-time token prices (powered by CoinGecko)
- π₯ Explore trending tokens on Monad Testnet
- πͺ Launch your own tokens on the testnet
- π§ Grab testnet MON tokens from the faucet
- And more awesomeness awaits... β¨
Built for everyoneβfrom AI wizards in San Francisco to crypto hustlers worldwideβAelix brings the Monad ecosystem to your fingertips. π No matter your background, this agent makes blockchain exploration simple, smart, and fun! π‘
Check out the agent in action on our website:
π Aelix AI
-
Wallet & Token Operations
- π Set up and manage wallets on Monad Testnet
- π° Check your MONAD token balance instantly
- π€ Transfer MONAD tokens to any address
- πͺ Create and deploy your own tokens on Monad Testnet
- π§ Request testnet MON tokens from the Monad faucet
- βοΈ Sign messages securely with your wallet
-
Blockchain Insights
- π Fetch recent transaction history with explorer links
- β½ Get real-time gas price estimates
- πΉ Retrieve live token prices via CoinGecko
- π₯ Discover trending tokens on Monad Testnet
-
LangChain Integration
- π οΈ Built-in LangChain tools for seamless blockchain operations
- βοΈ Autonomous agent support with React framework
- π§ Persistent memory for smooth, context-aware interactions
- π‘ Streaming responses for real-time feedback
-
Vercel Deployment
- π Hosted on Vercel for fast and reliable access
- π§© Framework-agnostic design with easy frontend integration
- β‘ Quick setup with environment variable support
-
Agent Modes
- π¬ Interactive chat mode for guided blockchain operations
- π€ Autonomous mode for independent task execution
- π‘οΈ Built-in error handling for robust performance
-
AI-Powered Tools
- π Natural language processing for intuitive blockchain commands
- πΉ Price feed integration for token market insights
- βοΈ Automated decision-making to simplify complex actions
You can view the full documentation of the kit at Aelix Agent Documentation
Setting up Aelix | Monad AI Agent locally is super simple. Follow these steps:
# Clone the repository
git clone https://github.com/nikhilraikwar-aelix/aelix.git
cd aelix
# Install dependencies
npm install
## Quick Start
```typescript
import { ChatOpenAI } from "@langchain/openai";
import { StateGraph, END } from "@langchain/langgraph";
import { HumanMessage, AIMessage, BaseMessage } from "@langchain/core/messages";
import { ToolNode } from "@langchain/langgraph/prebuilt";
import { z } from "zod";
import { StructuredTool } from "@langchain/core/tools";
import { ethers } from "ethers";
import * as dotenv from "dotenv";
import express, { Request, Response, RequestHandler } from "express";
import bodyParser from "body-parser";
import axios from "axios";
import * as cheerio from "cheerio";
import { Logger } from "tslog";
import cors from 'cors';
dotenv.config();
// Environment variables
const OPENAI_API_KEY = process.env.OPENAI_API_KEY || "";
const COINGECKO_API_KEY = process.env.COINGECKO_API_KEY || "";
const DEXSCREENER_API_KEY = process.env.DEXSCREENER_API_KEY || "";
const MONAD_RPC_URL = process.env.MONAD_RPC_URL || "https://testnet-rpc.monad.xyz";
const MONAD_EXPLORER_URL = "https://monad-testnet.socialscan.io";
const MONAD_FAUCET_URL = "https://testnet.monad.xyz/";
// Logger setup
const log = new Logger({ name: "MonadAgent" });# π Backend Setup
### Step 1: Navigate to the Backend Directory
Run the following command to move into the backend directory:
```bash
cd monadagent
### Step 2: Install Backend Dependencies
Use the following command to install all necessary dependencies:
npm install
### Step 3: Set up environment variables (create a .env file in monadagent/):
OPENAI_API_KEY=your-openai-api-key
COINGECKO_API_KEY=your-coingecko-api-key
MONAD_RPC_URL=https://testnet-rpc.monad.xyz
### Step 4: Run the backend:
npx ts-node monadAgent.ts
### Step 5: Test Backend using curl command:
$ curl -X POST http://localhost:3000/agent -H "Content-Type: application/json" -d '{"input": "help"}'
# π Frontend Setup
### Step 1: Return to the Root Directory
cd ..
### Step 2: Install frontend dependencies
npm install
### Step 3: Set up environment variables (create a .env file in root)
VITE_API_ENDPOINT=http://localhost:3000/agent
VITE_PRIVY_APP_ID=your-privy-app-id
### Step 4: Run the frontend
npm run dev
- Open http://localhost:5173/dashboard in your browser and connect your wallet via Privy.
- π Your Aelix AI Agent is now up and running! π
Aelix | Monad AI Agent accepts commands through its chat interface (src/components/ChatInterface.tsx). Here are the operations with examples:
Set your Monad Testnet wallet:
- Command:
setWallet <your-private-key> - Response:
Wallet set to address: 0xYourWalletAddress
Check your wallet's MONAD balance:
- Command:
getBalance - Response:
Balance: 10 MONAD
Send MONAD tokens to any address:
- Command:
transferTokens <recipient-address> 1 - Response:
Successfully transferred 1 MONAD to <recipient-address>. Transaction hash: 0x...
Fetch real-time token price (via CoinGecko):
- Command:
getTokenPrice MONAD - Response:
MONAD price: $0.50 USD
Create a new token on Monad Testnet:
- Command:
createToken MyToken MTK 1000 - Response:
Token MyToken (MTK) created with 1000 supply. Token address: 0x...
Weβve used these key libraries:
@langchain/openai- For AI model integrationethers- For Monad Testnet blockchain interactionsexpress- For the API serveraxios- For HTTP requests (e.g., CoinGecko)cors- For cross-origin requests
react- UI framework@privy-io/react-auth- Wallet authentication@tanstack/react-query- Data fetchingshadcn/ui- UI componentstailwindcss- Styling
Contributions are welcome! Please feel free to submit a Pull Request.
This project is licensed under the MIT License - see the LICENSE file for details.
Handle private keys with care and never share them. Store sensitive data in .env files and add them to .gitignore.
