All projects

Base L2 · DeFi · MEV-protected execution

Cross-DEX Arbitrage System

A full arbitrage pipeline for Base L2: a scanner streams pool reserves from multiple decentralised exchanges, a pricing engine ranks spreads after gas and slippage, and an on-chain executor settles profitable routes atomically with flash-loaned capital.

Year
2025
Role
Solo engineer - contracts, backend, dashboard
Focus
Solidity, Base L2, Node.js

Screenshots

  • Operator dashboard - live spreads, executions and win rate.

Problem

Price inefficiencies across DEXs vanish in milliseconds and are routinely front-run by MEV bots.

Solution

Built a scanning engine with an execution layer that atomically borrows via flash loans and settles arbitrage in a single MEV-protected transaction.

Result

End-to-end pipeline from opportunity detection to on-chain settlement, with a live dashboard visualising spreads and executions.

What it does

  • Multi-DEX reserve scanner with sub-second refresh
  • Profitability model accounting for gas, slippage and fees
  • Atomic flash-loan execution in a single transaction
  • MEV-aware submission to reduce front-running
  • Live dashboard for spreads, trades and win rate

Scope of work

  • Smart-contract executor for atomic flash-loan arbitrage
  • Off-chain scanner streaming reserves from multiple Base DEXs
  • Profitability engine modelling gas, slippage and pool fees
  • Operator dashboard for spreads, executions and win rate

Timeline

  1. Weeks 1-2

    Research

    Mapped Base L2 liquidity, DEX routers and realistic spread windows.

  2. Weeks 3-5

    Contracts

    Built and tested the flash-loan executor with atomic revert safety.

  3. Weeks 6-8

    Scanner

    Streamed pool reserves sub-second and ranked opportunities after costs.

  4. Weeks 9-10

    Dashboard

    Shipped the live operator view and MEV-aware submission path.

Outcomes

Sub-second

Opportunity refresh across tracked pools

1 tx

Borrow, swap and repay settled atomically

End-to-end

Detection through on-chain settlement

Tech stack

SolidityBase L2Node.jsTypeScriptFlash LoansWeb3