Skip to content

Latest commit

 

History

History
65 lines (46 loc) · 1.4 KB

File metadata and controls

65 lines (46 loc) · 1.4 KB

GhostFund AI

Autonomous AI trading agent on Base L2 that executes trades on Uniswap V3 using LLM sentiment analysis and on-chain data.

Features

  • Local LLM: Llama 3.2 via Ollama for news sentiment analysis
  • Whale Watcher: Monitors USDC transfers >$100k on BaseScan
  • Autonomous Trading: Direct Uniswap V3 integration with Web3.py
  • Real-time Dashboard: React + Tailwind with live updates

Tech Stack

Backend: Python, FastAPI, Web3.py, Ollama
Frontend: React, TypeScript, Vite, Wagmi, Reown AppKit
Network: Base Sepolia Testnet

Quick Start

Backend

cd backend
pip install fastapi uvicorn web3 requests python-dotenv ollama

# Create .env with:
# ALCHEMY_RPC_URL, PRIVATE_KEY, BASE_SCAN_API_KEY, CRYPTOPANIC_API_KEY

ollama pull llama3.2
uvicorn api_server:app --reload

Frontend

cd ghostfund-web
npm install
npm run dev

Expose Backend

ngrok http 8000
# Update VITE_API_URL in frontend with ngrok URL

Usage

  1. Start Ollama (ollama serve)
  2. Launch backend and frontend
  3. Connect wallet (MetaMask/WalletConnect)
  4. Click "Initialize Analysis"
  5. Review consensus score
  6. Execute trade

Consensus Score

  • 50% LLM sentiment from news
  • 30% On-chain whale activity
  • 20% Fear & Greed Index

Score >70 = Buy | <30 = Sell

Disclaimer

Educational purposes only. Testnet only. Do not use real funds. Not financial advice.