Milton - AMM
I think that nothing is so important for freedom as recognizing in the law each individual’s natural right to property and giving individuals a sense that they own something that they’re responsible for, that they have control over, and that they can dispose of.Milton Friedman
Milton is a central and most important contract for IPOR Interest Rate Swaps. It is in charge of issuing swaps, delegating funds, and managing the risk and state of the derivatives portfolio. Milton is divided into several parts responsible for aspects of this large set of functionalities. It has been built for modularity to evolve and improve as the market for interest rate derivatives evolves and matures.
The main part is a
Milton.sol- it is responsible mainly for opening interest rate swaps. To fulfill that function, it keeps balances, tracks the performance of the derivative portfolio via S.O.A.P, and delegates things such as spread calculation and asset management.
Milton, like many other contracts in IPOR Protocol, is issued per stablecoin. In other words, for each stablecoin, there is a version of Milton. It helps with gas optimisation as well as security.
For implementation refer to the deployed contract of Milton.