AI agents that find the best DeFi yield, assess risk via ENS reputation, and execute swaps on chain.
RelayX is an intent-centric DeFi execution engine powered by multi-agent orchestration. You type a natural language intent like "get best yield on ETH" and three specialized AI agents collaborate to execute it:
Every decision produces a structured trace entry , the entire reasoning chain is visible and auditable. The system uses ENS tiers (strong/neutral/weak) that shift risk thresholds, AXL peer approval ratios that adjust confidence scores, and optional LLM reasoning via Groq for human-readable explanations. When the user approves, a real Uniswap V3 swap executes on Sepolia testnet, moving tokens on-chain.
RelayX is built on a Next.js 16 (React 19) frontend with Tailwind CSS 4 for styling, Zustand for state management, Framer Motion for animations, and ethers.js for wallet interaction. The backend runs on Node.js with Express 5 and TypeScript, using ethers.js and viem for on-chain logic, backed by a 140+ test suite written in Vitest. The core of RelayX is a custom-built orchestration layer, no LangChain, no off-the-shelf agent framework. We built this deliberately for deterministic execution and low latency. The pipeline runs four specialized agents. YieldAgent parses user intent and fetches real-time protocol data from DefiLlama. RiskAgent evaluates transaction safety using ENS reputation signals, AXL consensus, and historical agent memory. ExecutorAgent generates real Uniswap V3 SwapCalldata and quotes directly via QuoterV2. BaseAgent handles shared tracing and logging across the entire pipeline. ENS is integrated via viem to resolve wallet names and fetch on-chain text records including linked Twitter and GitHub accounts. The RiskAgent uses these social signals to compute a Reputation Score between 0.0 and 1.0. If the signals are weak or absent, the agent automatically raises the risk threshold, potentially rejecting the transaction entirely or requiring a higher AXL consensus confidence before proceeding. We are not just using ENS for name resolution, we are using it as a decentralized credit scoring layer for DeFi risk assessment. Gensyn AXL is wired into the pipeline via a custom AXLAdapter that connects to the Gensyn AXL P2P binary running at 127.0.0.1:9002. When the RiskAgent evaluates a transaction, it broadcasts a risk_request to the AXL peer network and waits for consensus signals from peers before computing a final “Local + Network” confidence score. For development environments without the full P2P binary, we built a Simulation Node fallback that mirrors the consensus behavior locally. Frontend and backend communicate via a RESTful API, specifically POST /analyze and POST /execute/confirm. The backend handles all heavy computation including quoting, risk analysis, and calldata generation, then returns a fully prepared payload that the frontend passes directly to MetaMask via eth_sendTransaction. This server-side quotation approach is what enables the genuine one-click experience, no complex swap logic lives on the client at all. Two things we built that are worth highlighting specifically. First, using ENS Text Records as a decentralized reputation signal for DeFi risk is unconventional, ENS is almost universally used just for name resolution and we repurposed its social graph as a financial trust layer. Second, instead of a traditional database for agent memory, we use the 0G Galileo Testnet as a persistent decentralized memory layer to store execution records and confidence scores across sessions, meaning the agents get smarter over time without any centralized storage dependency.

