ASI:BlockAgent

A real-time whale detection and trading intelligence system for Hyperliquid

ASI:BlockAgent

Created At

ETHOnline 2025

Project Description

A cutting-edge AI-powered system that detects and analyzes large cryptocurrency deposits ("whale activity") on Hyperliquid in real-time, providing traders with instant intelligence about market-moving events.

🎯 What It Does

  • Real-Time Whale Detection : Monitors Ethereum mainnet for large deposits (>$100k) to the Hyperliquid bridge using Blockscout MCP integration
  • Instant Position Analysis : Automatically fetches whale trading positions, leverage, and liquidation prices from Hyperliquid APIs
  • AI-Powered Chat Interface : Natural language queries like "Show me recent whales" or "What positions do large traders have?"
  • ASI:ONE Integration : Connects to Agentverse agents for advanced AI capabilities with fallback to local processing

How it's Made

🔧 Technical Architecture & Implementation

Core Technologies Stack

  • Frontend : Next.js 14 with TypeScript, Tailwind CSS, Lucide React icons
  • Backend : Python with uAgents framework for multi-agent orchestration
  • Blockchain Integration : Blockscout MCP (Model Context Protocol) for Ethereum monitoring
  • AI Integration : ASI:ONE protocol connecting to Agentverse agents
  • APIs : Direct integration with Hyperliquid's trading APIs

Multi-Agent System Design

  1. Local Mailbox Agent ( whale_agent_mailbox.py )
  • Built with uAgents framework running on port 8001
  • Implements two core tools:
    • get_recent_whales() : Queries Blockscout MCP for large bridge deposits
    • enrich_wallet() : Fetches position data from Hyperliquid APIs
  • Handles natural language processing for whale detection queries
  1. HTTP Server Agent ( whale_agent_http_server.py )
  • FastAPI server on port 8002 providing REST endpoints
  • Bridges between the frontend and the mailbox agent
  • Enables stateless operation without database persistence
  1. ASI:ONE Integration ( asi-one.ts )
  • Custom TypeScript client for ASI:ONE protocol
  • Implements agent discovery and message routing
  • Fallback mechanism: tries ASI:ONE first, then local agents

Blockchain Monitoring Innovation

Blockscout MCP Integration :

# Custom MCP client for real-time whale detection
async def get_recent_whales(threshold_usd: float = 100000, lookback_minutes: int = 60):
    # Query Hyperliquid bridge contract: 0x2Df1c51E09aECF9cacB7bc98cB1742757f163dF7
    # Decode deposit events using verified ABI
    # Filter transactions above threshold

Particularly Hacky & Notable :

  1. Stateless Architecture : No database! Everything processes live data from APIs
  2. Hybrid Agent Routing : Frontend intelligently routes between local and cloud agents based on preferLocal setting
  3. Real-time Bridge Monitoring : Direct integration with Blockscout's MCP to catch whale deposits as they happen

Frontend Architecture

Chat Interface ( chat-interface.tsx ):

  • React hooks for real-time message streaming
  • Dual-mode operation: local vs ASI:ONE agents
  • Connection status monitoring with automatic fallbacks
  • Quick action buttons for common queries
background image mobile

Join the mailing list

Get the latest news and updates