🤖 AI Summary
Automated Market Makers (AMMs) in DeFi expose liquidity providers (LPs) to arbitrage losses—primarily impermanent loss—due to price lag relative to external markets. Method: This paper proposes an adaptive AMM curve design grounded in the Glosten-Milgrom market microstructure model. It derives, for the first time, the optimal curve differential equation minimizing arbitrage loss; constructs an on-chain, oracle-free real-time market price estimator; and establishes an equivalence between static curve dynamics and optimality conditions. Implementation integrates Kalman filtering, stochastic differential equation modeling, and Uniswap v4’s hook-based programmability for on-chain execution. Contribution/Results: Experiments demonstrate substantial reduction in LP losses, faster price convergence, improved capital efficiency, and strong robustness under high volatility and adversarial conditions.
📝 Abstract
Automated Market Makers (AMMs) are essential in Decentralized Finance (DeFi) as they match liquidity supply with demand. They function through liquidity providers (LPs) who deposit assets into liquidity pools. However, the asset trading prices in these pools often trail behind those in more dynamic, centralized exchanges, leading to potential arbitrage losses for LPs. This issue is tackled by adapting market maker bonding curves to trader behavior, based on the classical market microstructure model of Glosten and Milgrom. Our approach ensures a zero-profit condition for the market maker's prices. We derive the differential equation that an optimal adaptive curve should follow to minimize arbitrage losses while remaining competitive. Solutions to this optimality equation are obtained for standard Gaussian and Lognormal price models using Kalman filtering. A key feature of our method is its ability to estimate the external market price without relying on price or loss oracles. We also provide an equivalent differential equation for the implied dynamics of canonical static bonding curves and establish conditions for their optimality. Our algorithms demonstrate robustness to changing market conditions and adversarial perturbations, and we offer an on-chain implementation using Uniswap v4 alongside off-chain AI co-processors.