Thinking Fast and Slow: Data-Driven Adaptive DeFi Borrow-Lending Protocol

Authors Mahsa Bastankhah , Viraj Nadkarni , Chi Jin , Sanjeev Kulkarni , Pramod Viswanath



PDF
Thumbnail PDF

File

LIPIcs.AFT.2024.27.pdf
  • Filesize: 1.32 MB
  • 23 pages

Document Identifiers

Author Details

Mahsa Bastankhah
  • Princeton University, NJ, USA
Viraj Nadkarni
  • Princeton University, NJ, USA
Chi Jin
  • Princeton University, NJ, USA
Sanjeev Kulkarni
  • Princeton University, NJ, USA
Pramod Viswanath
  • Princeton University, NJ, USA

Cite AsGet BibTex

Mahsa Bastankhah, Viraj Nadkarni, Chi Jin, Sanjeev Kulkarni, and Pramod Viswanath. Thinking Fast and Slow: Data-Driven Adaptive DeFi Borrow-Lending Protocol. In 6th Conference on Advances in Financial Technologies (AFT 2024). Leibniz International Proceedings in Informatics (LIPIcs), Volume 316, pp. 27:1-27:23, Schloss Dagstuhl – Leibniz-Zentrum für Informatik (2024)
https://doi.org/10.4230/LIPIcs.AFT.2024.27

Abstract

Decentralized finance (DeFi) borrowing and lending platforms are crucial to the decentralized economy, involving two main participants: lenders who provide assets for interest and borrowers who offer collateral exceeding their debt and pay interest. Collateral volatility necessitates over-collateralization to protect lenders and ensure competitive returns. Traditional DeFi platforms use a fixed interest rate curve based on the utilization rate (the fraction of available assets borrowed) and determine over-collateralization offline through simulations to manage risk. This method doesn't adapt well to dynamic market changes, such as price fluctuations and evolving user needs, often resulting in losses for lenders or borrowers. In this paper, we introduce an adaptive, data-driven protocol for DeFi borrowing and lending. Our approach includes a high-frequency controller that dynamically adjusts interest rates to maintain market stability and competitiveness with external markets. Unlike traditional protocols, which rely on user reactions and often adjust slowly, our controller uses a learning-based algorithm to quickly find optimal interest rates, reducing the opportunity cost for users during periods of misalignment with external rates. Additionally, we use a low-frequency planner that analyzes user behavior to set an optimal over-collateralization ratio, balancing risk reduction with profit maximization over the long term. This dual approach is essential for adaptive markets: the short-term component maintains market stability, preventing exploitation, while the long-term planner optimizes market parameters to enhance profitability and reduce risks. We provide theoretical guarantees on the convergence rates and adversarial robustness of the short-term component and the long-term effectiveness of our protocol. Empirical validation confirms our protocol’s theoretical benefits.

Subject Classification

ACM Subject Classification
  • Theory of computation → Market equilibria
Keywords
  • Defi borrow-lending
  • adaptive market design
  • decentralized finance

Metrics

  • Access Statistics
  • Total Accesses (updated on a weekly basis)
    0
    PDF Downloads

References

  1. Aave. Aave finance governance. https://app.aave.com/governance/. Accessed: 2023-05.
  2. Aave. Aave whitepaper. https://github.com/aave/aave-protocol/blob/master/docs/Aave_Protocol_Whitepaper_v1_0.pdf. Accessed: 2024-02.
  3. Aave. Interest rate curve in aave. https://docs.aave.com/risk/liquidity-risk/borrow-interest-rate . Accessed: 2023-05.
  4. Ajna. Ajna whitepaper. https://www.ajna.finance/pdf/Ajna_Protocol_Whitepaper_01-11-2024.pdf. Accessed: 2023-05.
  5. Jean Barthélemy, Clément Delaneau, Thomas Martignon, Benoît Nguyen, Marten Riho Pallum, and Salim Talout Zitan. Interest rates in decentralised finance. https://www.banque-france.fr/en/publications-and-statistics/publications/interest-rates-decentralised-finance#:~:text=The%20setting%20of%20interest%20rates%20in%20DeFI&text=The%20formula%20is%20simple%3A%20the,interest%20rates%20cannot%20be%20negative., 2023. Accessed: 2023-05.
  6. Mahsa Bastankhah, Viraj Nadkarni, Xuechao Wang, Chi Jin, Sanjeev Kulkarni, and Pramod Viswanath. Thinking fast and slow: Data-driven adaptive defi borrow-lending protocol, 2024. URL: https://arxiv.org/abs/2407.10890.
  7. Kush Bhatia, Prateek Jain, and Purushottam Kar. Robust regression via hard thresholding, 2015. URL: https://arxiv.org/abs/1506.02428.
  8. Sylvain Carre and Franck Gabriel. Security and efficiency in defi lending. Université Paris-Dauphine Research Paper, 2023. Google Scholar
  9. Tarun Chitra, Peteris Erins, and Kshitij Kulkarni. Attacks on dynamic defi interest rate curves. arXiv preprint, 2023. URL: https://arxiv.org/abs/2307.13139.
  10. Jonathan Chiu, Emre Ozdenoren, Kathy Yuan, and Shengxing Zhang. On the fragility of defi lending. Available at SSRN 4328481, 2022. Google Scholar
  11. Samuel N Cohen, Marc Sabate-Vidales, Lukasz Szpruch, and Mathis Gontier Delaunay. The paradox of adversarial liquidation in decentralised lending. Available at SSRN 4540333, 2023. Google Scholar
  12. Samuel N Cohen, Leandro Sánchez-Betancourt, and Lukasz Szpruch. The economics of interest rate models in decentralised lending protocols. Available at SSRN, 2023. Google Scholar
  13. Compound. Compound finance governance. https://compound.finance/governance. Accessed: 2023-05.
  14. Compound. Compound whitepaper. https://compound.finance/documents/Compound.Whitepaper.pdf. Accessed: 2024-02.
  15. Compound. Impermanent loss in defi lending. https://docs.compound.finance/interest-rates/. Accessed: 2023-05.
  16. ethereum.org. Opcodes for the evm, 2024. URL: https://ethereum.org/en/developers/docs/evm/opcodes/.
  17. Gauntlet. Arfc aave v3 interest rate curve recommendations from gauntlet, 2023. Accessed: 2024-05-20. URL: https://governance.aave.com/t/arfc-aave-v3-interest-rate-curve-recommendations-from-gauntlet-2023-04-27/12921.
  18. Mohak Goyal, Geoffrey Ramseyer, Ashish Goel, and David Mazières. Finding the right curve: Optimal design of constant function market makers, 2023. URL: https://arxiv.org/abs/2212.03340.
  19. Gauntlet Research Group. Aave market risk analysis. URL: https://gauntlet.network/reports/aave.
  20. Gauntlet Research Group. Compound market risk analysis. URL: https://assets-global.website-files.com/648bdc0d4b8ce322f27da0af/651f146b6a1c8cc78e6c9cac_Gauntlet%20-%20Compound%20Market%20Risk%20Assessment.pdf.
  21. Lewis Gudgeon, Sam Werner, Daniel Perez, and William J Knottenbelt. Defi protocols for loanable funds: Interest rates, liquidity and market efficiency. In Proceedings of the 2nd ACM Conference on Advances in Financial Technologies, pages 92-112, 2020. Google Scholar
  22. Thomas Kailath. Linears Systems. Prentice-Hall, 1980. Google Scholar
  23. Will Kenton. Market distortion. https://www.investopedia.com/terms/m/marketdistortion.asp. Accessed: 2023-05.
  24. Ariah Klages-Mundt and Andreea Minca. (in) stability for the blockchain: Deleveraging spirals and stablecoin attacks. PubPub, 2021. Google Scholar
  25. Arthur D Kuo. A least-squares estimation approach to improving the precision of inverse dynamics computations. ASME digital collection, 1998. Google Scholar
  26. Brian McWilliams, Gabriel Krummenacher, Mario Lucic, and Joachim M Buhmann. Fast and robust least squares estimation in corrupted linear models. Advances in Neural Information Processing Systems, 27, 2014. Google Scholar
  27. Jason Milionis, Ciamac C. Moallemi, and Tim Roughgarden. Automated market making and arbitrage profits in the presence of fees, 2023. URL: https://arxiv.org/abs/2305.14604.
  28. Morpho. Morpho whitepaper. https://whitepaper.morpho.xyz/, 2023. Accessed: 2023-05.
  29. Viraj Nadkarni, Jiachen Hu, Ranvir Rana, Chi Jin, Sanjeev Kulkarni, and Pramod Viswanath. Zeroswap: Data-driven optimal market making in defi. arXiv preprint, 2023. URL: https://arxiv.org/abs/2310.09413.
  30. Pedro M. Negron. Navigating risks in defi lending. https://medium.com/intotheblock/navigating-risks-in-defi-lending-a034dbf83b54. Accessed: 2023-05.
  31. Board of governors of the federal reserve systems. Capital planning at large bank holding companies: Supervisory expectations and range of current practice. https://www.federalreserve.gov/bankinforeg/stress-tests/ccar/august-2013-estimation-methodologies-for-losses-revenues-and-expenses.htm. Accessed: 2023-05.
  32. Kaihua Qin, Liyi Zhou, Pablo Gamito, Philipp Jovanovic, and Arthur Gervais. An empirical study of defi liquidations: Incentives, risks, and instabilities. In Proceedings of the 21st ACM Internet Measurement Conference, pages 336-350, 2021. Google Scholar
  33. Thomas J Rivera, Fahad Saleh, and Quentin Vandeweyer. Equilibrium in a defi lending market. Available at SSRN 4389890, 2023. Google Scholar
  34. Kanis Saengchote. Decentralized lending and its users: Insights from compound. Journal of International Financial Markets, Institutions and Money, 87:101807, 2023. URL: https://doi.org/10.1016/j.intfin.2023.101807.
  35. Lukasz Szpruch, Jiahua Xu, Marc Sabate-Vidales, and Kamel Aouane. Leveraged trading via lending platforms. Available at SSRN, 2024. Google Scholar
  36. Eli Tan. Impermanent loss in defi lending. https://www.coindesk.com/learn/defi-lending-3-major-risks-to-know/. Accessed: 2023-05.
  37. Yue Xing, Ruizhi Zhang, and Guang Cheng. Adversarially robust estimate and risk analysis in linear regression. In International Conference on Artificial Intelligence and Statistics, pages 514-522. PMLR, 2021. Google Scholar
  38. Aviv Yaish, Maya Dotan, Kaihua Qin, Aviv Zohar, and Arthur Gervais. Suboptimality in defi. Cryptology ePrint Archive, 2023. Google Scholar
  39. Xiao Zhang and Feng Ding. Adaptive parameter estimation for a general dynamical system with unknown states. International Journal of Robust and Nonlinear Control, 30(4):1351-1372, 2020. Google Scholar
  40. Stephan Zheng, Alexander Trott, Sunil Srinivasa, David C. Parkes, and Richard Socher. The AI economist: Optimal economic policy design via two-level deep reinforcement learning. CoRR, abs/2108.02755, 2021. URL: https://arxiv.org/abs/2108.02755.
Questions / Remarks / Feedback
X

Feedback for Dagstuhl Publishing


Thanks for your feedback!

Feedback submitted

Could not send message

Please try again later or send an E-mail