A market-making and arbitrage system for an on-chain trading vault: one core tracks prices across three chains, and validators must agree before capital moves.
A shared trading vault can't trust a single bot. Prices move across chains every few seconds, and one faulty or compromised signer should never be able to move capital on its own.
The story
01
New blocks on three chains
Every three seconds the core reads the latest state on Ethereum, BNB Chain and Base, with RPC failover on every read.
02
Read every pool
BTC/USDC prices come straight from Uniswap and PancakeSwap pool state on-chain, not from a third-party feed.
03
Find the pattern
Each market keeps a five-minute TWAP, one-hour volatility and its deviation, so validators trade the trend, not one tick.
04
Spot the spread
Same asset, two pools, two prices. Validators flag arbitrage only when it's still profitable after gas on both legs.
05
Quote in layers
For market making, spreads widen with volatility and lean against inventory, split across tight, medium and defensive layers.
06
Gate, then three signatures
Capital, exposure tier and risk limits are checked; then three validators must each sign the exact swap. (Signing designed)
07
Execute on-chain
The vault swaps, the trade lands in the next block, the nonce advances and the cycle summary goes to Telegram.
What we built
The work that made it.
A core that never sleeps
Every three seconds it reads pool prices and vault balances on Ethereum, BNB Chain and Base, and keeps TWAP and volatility for every market in one place.
Failover built into every read
Each chain has a pool of RPC endpoints. When one hits a rate limit, reads rotate to the next, so a single provider never stalls the sync.
Market making with discipline
Spreads widen with volatility and lean against inventory skew, and capital is split across tight, medium and defensive layers.
Arbitrage only after gas
Validators compare the same asset across pools and only flag a trade if it is still profitable once both legs' gas is paid.
A decision gate before any capital
Every opportunity is checked against available capital, a BTC-price-based exposure tier and risk limits before capital is reserved.
Three signatures, by design
We designed the full flow: one validator proposes and signs the exact swap, two others recompute it independently and co-sign, and stale proposals expire with the vault nonce.
How it works
Step by step.
01
Sync
The core pulls prices and balances from three chains every three seconds.
02
Detect
Validators look for market-making and arbitrage opportunities every 30 seconds.
03
Gate
Capital, exposure tier and risk limits are checked before anything is reserved.
04
Co-sign
Three independent signatures before the vault executes, by design.
Built: the three-second core sync with RPC failover, cycle summaries to Telegram, and the validators' market-making and arbitrage detection. Designed: the decision gate, three-validator signing, execution and reconciliation.