DeleGator.AI
DeleGator.AI is an AI-powered portfolio automation agent that lets users automate crypto strategies (like rebalance, swap, take profit, or buy the dip) — while retaining full custody through MetaMask
ビデオ
説明
🤖 DeleGator.AI
Autonomous, Non-Custodial Portfolio Automation Agent powered by AI, MetaMask Smart Accounts, Envio, and Monad.
🚀 Overview
DeleGator.AI is an AI-powered portfolio automation agent that lets users automate crypto strategies (like rebalance, swap, take profit, or buy the dip) — while retaining full custody through MetaMask Smart Accounts and Delegations.
It transforms manual portfolio management into a secure, autonomous experience powered by AI, real-time oracles, and delegated smart contract execution.
🎯 Problem
Manual portfolio management is inefficient and error-prone:
- Users must constantly track price movements and rebalancing thresholds. 
- Missed “buy the dip” or “take profit” opportunities lead to losses. 
- Centralized bots require custody of funds, creating trust and security risks. 
- DeFi users lack intelligent, autonomous agents that act on their behalf without surrendering control. 
💡 Solution — DeleGator.AI
DeleGator.AI solves this by combining AI intelligence, MetaMask Smart Account delegation, and on-chain automation to create an autonomous yet non-custodial portfolio manager.
- Users define strategies using natural language. 
- AI translates it into executable logic (e.g. triggers, conditions, actions). 
- The system executes automatically via MetaMask Delegations on Monad Testnet. 
- All funds remain in the user’s smart account — revocable anytime. 
🧠 Core Features
| Feature | Description | 
|---|---|
| AI Strategy Builder | Convert plain English instructions into structured strategy logic using OpenAI LLM. | 
| Visual Canvas | Drag-and-drop UI for creating conditional automation workflows. | 
| Delegated Execution | Uses MetaMask Smart Accounts + Delegation to authorize bots securely. | 
| Real-Time Monitoring | Envio-powered indexer tracks portfolio events on-chain in real time. | 
| Non-Custodial | No funds ever leave the user’s smart account — delegation is permissioned and revocable. | 
| Cross-Chain Ready | Runs on Monad Testnet, extensible to Base and other EVMs. | 
🧩 Example Strategies
| Use Case | Example | 
|---|---|
| Rebalancing | “Maintain 70% ETH / 30% USDC; rebalance if drift > 5%.” | 
| Buy the Dip | “Buy 10% more ETH if ETH price drops 15%.” | 
| Take Profit | “Transfer 20% profits to main wallet if portfolio > $10,000.” | 
| Yield Extraction | “Every Sunday, move staking rewards to main vault.” | 
| Stop Loss | “Convert everything to USDC if ETH drops below $1,500.” | 
⚙️ How It Works
1️⃣ Define Strategy (AI Layer)
User inputs a strategy in natural language:
“Rebalance to 70% ETH and 30% USDC if drift > 5%.”
🧩 AI Processing:
OpenAI’s LLM converts this into an executable JSON schema:
{
  "trigger": "price_update",
  "condition": "drift > 5%",
  "action": "rebalance(70% ETH, 30% USDC)"
}
👁️ Visual Builder:
Displayed on the drag-and-drop canvas in the frontend.
2️⃣ Create Delegation (MetaMask Smart Account Integration)
When automation is enabled:
- DeleGator.AI creates a MetaMask Smart Account (ERC-7710 compatible). 
- The user delegates permission to a RebalanceExecutor bot, limited to: - Execute specific strategy actions (e.g., rebalance/swap) 
- No withdrawals outside the user’s control 
 
- Delegation permissions are revocable anytime via MetaMask. 
🔐 This ensures complete user custody — the bot never holds funds.
3️⃣ Monitor and Execute (Envio + Monad Layer)
Envio Indexer continuously tracks:
- Portfolio balances 
- Oracle prices (via Pyth Network) 
- Trigger conditions (e.g., drift, thresholds) 
Once conditions are met:
- RebalanceExecutor validates the delegation caveats 
- Executes the transaction via UniswapHelper / Monorail DEX on Monad Testnet 
- Updates user’s allocation automatically 
Example Execution Flow:
Condition met: drift = 6.3% > 5%
↓
Envio Indexer triggers BotWorker
↓
DelegationManager verifies permissions
↓
RebalanceExecutor performs rebalance swap
↓
Portfolio rebalanced to 70.2% ETH / 29.8% USDC
🧱 Architecture
┌──────────────────────────────────────────────────────────────┐
│ FRONTEND (Next.js + OpenAI)                                  │
│ • AI chat & strategy builder                                 │
│ • Visual drag-drop canvas                                    │
│ • Delegation setup wizard (MetaMask SDK)                     │
└───────────────┬──────────────────────────────────────────────┘
                │
                ▼
┌──────────────────────────────────────────────────────────────┐
│ BACKEND (NestJS)                                             │
│ • REST API for strategy CRUD                                 │
│ • Bot Worker for monitoring triggers                         │
│ • Delegation handler for execution                           │
│ • Envio Indexer integration for event tracking               │
└───────────────┬──────────────────────────────────────────────┘
                │
                ▼
┌──────────────────────────────────────────────────────────────┐
│ SMART CONTRACTS (Solidity on Monad)                          │
│ • DelegationManager - MetaMask delegation logic              │
│ • RebalanceExecutor - Executes user strategies               │
│ • StrategyRegistry - Stores user-created automations         │
│ • PythOracle - Fetches real-time price feeds                 │
│ • UniswapHelper - DEX trade executor                         │
└───────────────┬──────────────────────────────────────────────┘
                │
                ▼
┌──────────────────────────────────────────────────────────────┐
│ INTEGRATIONS                                                 │
│ • MetaMask DeleGator SDK - Delegation & permissions           │
│ • Monad Testnet - Smart account execution layer               │
│ • Envio HyperIndex - On-chain data & event indexing           │
│ • OpenAI API - Natural language strategy generation           │
│ • Pyth Network - Oracle for live token prices                 │
└──────────────────────────────────────────────────────────────┘
🔗 Integrations
| Component | Role | 
|---|---|
| MetaMask Smart Accounts (DeleGator SDK) | Enables delegation, permissions, and revocation of automation authority. | 
| Monad Testnet | Deployment environment for all contracts. | 
| Envio HyperIndex | Indexes portfolio and strategy events for instant responsiveness. | 
| Pyth Oracle | Real-time price data for condition triggers. | 
| OpenAI API | AI-powered natural language → strategy logic transformation. | 
| Uniswap / Monorail | Executes on-chain swaps and rebalances. | 
🔐 Security Model
- Non-Custodial: Funds always stay in user’s smart account. 
- Fine-Grained Delegation: Each permission limited to method and target contract. 
- ERC-7710 Compliant: Built using MetaMask’s latest delegation framework. 
- Revocable: One-click revoke at any time. 
- Reentrancy & Slippage Protection: Prevents unsafe operations. 
- Oracle Validation: Rejects stale or manipulated price data. 
🧠 Why DeleGator.AI Wins the Hackathon
| Hackathon Track | How DeleGator.AI Excels | 
|---|---|
| 🥇 Best AI Agent | AI-powered portfolio logic builder with delegated on-chain execution | 
| 🥇 Best On-Chain Automation | Fully automated rebalancing and trading on Monad using smart account delegation | 
| 🥇 Most Innovative Use of Delegations | Introduces “AI Delegator” — an adaptive agent that acts only within safe delegated limits | 
| 🥇 Best Use of Envio | Uses Envio HyperIndex for live event-driven automation | 
| 🥇 Best Consumer App | No-code visual strategy builder for everyone | 
🧩 Repository Structure
deleGator-ai/
├── frontend/         # React/Next.js UI with AI chat and visual canvas
│   ├── src/          # Components, pages, hooks
│   └── docs/         # Frontend documentation
│
├── backend/          # NestJS backend (API + bot worker)
│   ├── apps/
│   │   ├── api/      # API server for user strategies
│   │   ├── bot/      # Execution bot
│   │   └── indexer/  # Envio-powered blockchain indexer
│   └── docs/
│
├── contract/         # Solidity smart contracts on Monad
│   ├── src/          # Contract implementations
│   ├── script/       # Deployment scripts
│   └── docs/
└── README.md
🧰 Setup & Run
1️⃣ Contracts
cd contract
forge install
cp .env.example .env
forge script script/DeployAll.s.sol --rpc-url $MONAD_RPC --broadcast
2️⃣ Backend
cd backend
npm install
cp .env.example .env
npx prisma migrate dev
npm run start:bot
3️⃣ Frontend
cd frontend
npm install
npm run dev
📊 Future Roadmap
- ✅ AI Learning Loop — adaptive strategies that improve over time 
- 🌉 Cross-Chain Mode — Base + Monad unified automation 
- 📱 Farcaster Mini App — social trading dashboards 
- 🧠 DAO-curated strategy marketplace 
- 📡 Envio Notifications — portfolio alerts in real time 
🔗 References
- Envio HyperIndex 
- Monad Testnet 
🏁 Summary
DeleGator.AI redefines DeFi automation by blending AI intelligence, delegated smart accounts, and on-chain execution into a seamless, non-custodial experience.
Built on Monad, powered by MetaMask Smart Accounts, and indexed by Envio, it delivers the next generation of autonomous, trustless portfolio agents.
“DeleGator.AI — The AI that acts, but never takes custody.” 🧠
ハッカソンの進行状況
currently in deploying stage
テックスタック
資金調達の状況
na