# QLAMMP: A Q-Learning Agent for Optimizing Fees on Automated Market Making Protocols

arXiv: https://arxiv.org/abs/2211.14977 · HTML: https://mlsanity.com/paper/2211.14977/

## Key facts

- Cited by 2 papers in the map (data through 14 Oct 2026).
- Builds on 4 of its 27 references that are in the map.
- First posted on arXiv 28 Nov 2022.

## Builds on (most cited first, 4 of 4)

- [OpenAI Gym](https://mlsanity.com/paper/1606.01540/) (2016)
- [SoK: Decentralized Exchanges (DEX) with Automated Market Maker (AMM) Protocols](https://mlsanity.com/paper/2103.12732/) (2021)
- [Improved Price Oracles: Constant Function Market Makers](https://mlsanity.com/paper/2003.10001/) (2020)
- [Automated Market Makers for Decentralized Finance (DeFi)](https://mlsanity.com/paper/2009.01676/) (2020)

## Built on by (most cited first, 2 of 2)

- [ZeroSwap: Data-driven Optimal Market Making in DeFi](https://mlsanity.com/paper/2310.09413/) (2023)
- [SoK: A Systematic Bidirectional Literature Review of AI & DLT Convergence](https://mlsanity.com/paper/2605.10515/) (2026)

## Abstract (arXiv)

Automated Market Makers (AMMs) have cemented themselves as an integral part of the decentralized finance (DeFi) space. AMMs are a type of exchange that allows users to trade assets without the need for a centralized exchange. They form the foundation for numerous decentralized exchanges (DEXs), which help facilitate the quick and efficient exchange of on-chain tokens. All present-day popular DEXs are static protocols, with fixed parameters controlling the fee and the curvature - they suffer from invariance and cannot adapt to quickly changing market conditions. This characteristic may cause traders to stay away during high slippage conditions brought about by intractable market movements. We propose an RL framework to optimize the fees collected on an AMM protocol. In particular, we develop a Q-Learning Agent for Market Making Protocols (QLAMMP) that learns the optimal fee rates and leverage coefficients for a given AMM protocol and maximizes the expected fee collected under a range of different market conditions. We show that QLAMMP is consistently able to outperform its static counterparts under all the simulated test conditions.
