
[02 — Project]
Liquidator
Multi-protocol MEV liquidation bot — Morpho, Euler, Silo, Aave across 3 chains.
- Python 3.12
- Foundry
- Solidity 0.8.27
- Ethereum
- Flashbots
- Morpho
- Aave
- AWS
- SQLite
[Overview]
What it does
Liquidator is a production-grade Ethereum MEV liquidation bot covering four lending protocols (Morpho Blue, Euler v2, Silo v2, Aave V3) across three chains (mainnet, Base, Arbitrum). When a borrower drops below Health Factor 1, the bot detects the position within seconds, plans the optimal liquidation, sources capital via a Morpho flash-loan (fee-free on mainnet), and executes the whole thing in a single atomic transaction.
The Liquidator contract is deployed via CREATE2 inside the first profitable bundle — zero gas wasted on speculative deployment. Seized collateral is swapped back against debt through the KyberSwap aggregator, the flash-loan is repaid, the builder gets paid from the surplus, and net profit is retained.
On the infra side: parallel indexers with cold/warm polling, per-chain isolated SQLite WAL, `eth_callBundle` simulation, and fan-out submission to 5 relays (Flashbots, Titan, Beaver, bloXroute, rsync) across multiple blocks ahead to maximize inclusion.
[Highlights]
Highlights
- 014 parallel indexers: Morpho Blue (108 markets), Euler v2 (26 vaults), Silo v2 (30 silos), Aave V3 (3 pools).
- 02Optimal plan: close-factor, eMode bonus override, dust-vs-full close logic.
- 03Morpho Blue flash-loan (fee-free on mainnet) for capital.
- 04Atomic CREATE2 deployment inside the first profitable bundle.
- 05Flashbots `eth_callBundle` simulation before every submission.
- 065-relay fan-out × N blocks ahead, KyberSwap for the atomic swap-back.