Lotus IRMs: Interest Rate Models

Lotus is an IRM agnostic protocol.

Lotus Interest Rate Models are responsible for computing tranche borrow rates based on utilization.

Lotus IRM's must implement an initialize() function to be called during market creation and a getTrancheBorrowRate() function for initialized markets

interface IIrm {
    function initialize(
        Id id,                    // The id of the market.
        bytes calldata irmParams  // ABI-encoded params expected by the IRM implementation.
    ) external;

    function getTrancheBorrowRate(
        Id id,                       // The id of the market.
        uint256 trancheIndex,        // The index of the tranche.
        uint256 trancheUtilization,  // The borrow utilization of the tranche in wad (0 to 1e18).
        bytes calldata irmData       // Custom data to be passed to the IRM implementation.
    ) external returns (uint256 trancheBorrowRate);
}

The Lotus admin can enable IRMs on the protocol. After that any market may be created using this IRM. IRMs cannot be disabled by the Lotus admin.

function enableIrm(address irm) external onlyOwner;

Parameters for the market's IRM are passed in during market creation.

function createMarket(
    MarketParams memory newMarketParams,  // The MarketParams for the new market.
    bytes calldata irmParams,             // The parameters for the IRM.
    bytes calldata liquidationParams      // The parameters for the liquidation module.
) external;

Last updated