Compound PID interest rate controller

An interest-rate-targeting autonomous interest rate model for Compound markets.

Demo Video Live Demo Source Code

Description

My goal with this project was to show that PID controllers are a promising alternative to DeFi interest rate models, in contrast to the static utilization-rate based interest rate controllers used in many applications today. From the experiment, we can see that PID controllers are capable of maintaining a target utilization rate without much fiddling from governance. In the future, I will be fixing edge cases with the agent-based model, writing Solidity code for the IRM, and adding lots of tests for both the smart contract and agent code. I will also try to show more scenarios that demonstrate the robustness of the PID model.

How It's Made

To show this, I wrote an agent-based model to simulate the evolution of interest rates over time in Python in a hypothetical compound market. There are agents that trade on their opinion of what a fair interest rate should be, and there are agents that simply add noise to the market by entering and exiting positions. In both of these cases, I use matplotlib to plot various factors of the market over time and show the performance of each model.

Team

Alexis Anand
← click here to see all projects