Introducing Mochi Protocol
Autonomously Governed Decentralized Stable Currency Protocol Fully-Backed by Long-Tail and Yield-Bearing Asset Markets
Mochi Protocol unlocks productivity in long-tail, staked, wrapped, and yield-bearing collateral assets by extending access to USDM stablecoin credit.
Mochi dynamically groups collateral assets into Risk Factor Categories then determines vault parameters, stability fees and algorithmic credit caps using a variety of reliable and stress-tested data sources.
Mochi is a cross-chain autonomous algorithmic lending protocol that enables permissionless listing of collateral assets and automatically adjusts collateral specific vault parameters (collateral factor, liquidation factor, credit cap, and stability fees) based on CSSR data to provide the most capital-efficient overcollateralized loans to users by minting the USDM stablecoin while minimizing the insolvency risk of a shortfall for the protocol. This allows a wide variety of collateral, including long-tail, staked/wrapped, and yield-bearing assets to be collateralized, unlocking new value in DeFi.
Mochi Vault Mechanics
The Mochi vault allows its users to leverage over-collateralized loans by depositing listed tokens as collateral and generating the USDM stablecoin. Users can use the listed collateral types to open vaults. If the collateral factor drops below the liquidation factor, the collateral is liquidated.
Adding a new collateral
New collateral assets will be added on Mochi, provided they meet or exceed certain onboarding conditions.
Algorithmic Vault Parameters
Mochi vault parameters are algorithmically set and dynamically updated based on CSSR data and other sources. Protocols are grouped into Risk Factor Categories which determine the Collateral Factor and Liquidation Factor.
Risk Factor Categories
The protocols listed on Mochi are classified into Risk Factors Categories (RFC) on a scale of 1–6, with 1 being the lowest risk and 6 being the highest.
Collateral Factor (CF)
A Vault’s Collateral Factor (CF) or Loan-to-value (LTV) is the ratio of the USDM borrowed and the value of deposited collateral (in USD).
- The CF is capped based on the token’s Risk Factor Category(RFC)
- The CF is calculated in real-time
- A Vault will remain liquid only when CF>LF
At loan initiation, the max CF is achieved when the user withdraws the largest loan possible against the deposited collateral. A safety buffer is maintained between max CF and LF to protect users against liquidations due to normal volatility.
Liquidation Factor (LF)
The Liquidation Factor is the Collateral Factor at which the vault will be liquidated. CF should be maintained below LF to maintain the Vault. Here is an example to see how it works:
- User deposits $1000 worth of Coin X as collateral into their Coin X Vault, which has a Liquidation Factor of 50%
- User borrows/mints $400 of USDM
- The user has a Collateral Factor of 40%
- The value of deposited collateral drops to $800
- User’s coin X vault is (partially) liquidated (400/800 = 50%)
The LF for each RFC is set conservatively so that Mochi can recover debts in the worst-case scenario where the asset crashes.
Credit Cap represents the maximum amount of $USDM debt that can be assigned to a protocol or collateral type across all vaults. It is algorithmically set for each protocol as a proportion of the combined liquidity depth (LD) across major decentralized exchange (DEX) pool pairs.
- Accepted DEXes: Uniswap, Sushi, PancakeSwap, Quickswap
- Accepted pairs: WBTC, ETH/WETH, BNB, USDT, USDC, DAI
Stability Fees are an annual amount in USDM owed on minted USDM to maintain protocol robustness. Mochi implements a variable stability fee mechanism that adjusts according to the Risk Factor Category and Utilization.
Utilization (u)- represents the ratio of borrowed USDM to the maximum USDM debt that can be assigned to a protocol (credit cap).
The minFee and maxFee are set by the DAO for each RFC.
The stability fee function aims to satisfy the following conditions:
Impact of Utilization (u):
- When the Utilization of a Vault is low, the stability fees are low. This is to incentivize users to lock in their assets and drive the adoption of Mochi.
- As utilization goes up and a Vault gains adoption, the stability fees go up linearly.
- Impact of RFC: Higher risk categories are charged higher fees.
Stability Fee at Loan Origination and Accrual
- On loan origination, 0.5% of the total loan amount is added to the user’s debt and accrues as protocol fees.
- From then on, Mochi Protocol waits until the stability fees hit 0.5% and then starts calculating additional debt accrual after that which is automatically added to the user’s debt amount.
So, if the Stability Fee is 10% per year then:
- 10% of 365 days = 36.5 days
- 0.5% fee is accumulated in 18.25 days
- Mochi waits for 18.25 days to start accruing debt
Liquidation recovers debt from collateralized assets to $USDM. In Mochi protocol, every $USDM is overcollateralized which minimizes shortfall risk and ensures peg stability.
- If CF=LF, the user’s vault will be subject to liquidation.
- Anyone can trigger a liquidation directly via the smart contract interface, by sending a trigger transaction.
- Liquidation bots monitor Vaults and trigger liquidations if the Token Price meets the User’s Vault Liquidation Price or lower.
A liquidation fee is assigned to the total outstanding debt when a Vault reaches Liquidation Factor (LF). This is a fixed fee based on the Risk Factor Category. Mochi Vaults are separated into 6 different Risk Factor Categories with parameters listed in the table below:
When a Vault is triggered for liquidation, the following happens:
- A Dutch auction starts for underlying collateral with a linear decrease in price.
- The auction starts at market price (the price reduces every block until bought)
- Users can buy the collateral for the current price by paying the $USDM debt for a liquidated Vault.
USDM Flash Loans
A flash loan allows a user to borrow tokens without collateral, provided they are returned within the same transaction. If the borrowed tokens aren’t paid back by the end of the transaction, the transaction reverts, effectively canceling the loan. This reduces insolvency risks and protects the Mochi Protocol by ensuring in the case of liquidation, that collateral of any size can always be liquidated smoothly and efficiently.
- All Mochi Vaults will support flash loans
- Liquidator keepers will receive a variable fee from 0.5% — 3% of the vaults debt — based on the vaults token class.
- Users can borrow USDM to buy the collateral, liquidate the collateral and repay the USDM debt in a single transaction.
- This ensures efficient liquidations and protects the protocol from shortfall risk.
What Happens After Collateral Realization?
Collateral realization happens when the debt position has been successfully sold to a bidder. This is what happens after that:
- All outstanding balance left after repaying the borrowed USDM amount plus the Liquidation Fee and flash loan fee is kept by the liquidator.
- The User’s $USDM debt is burned; and
- The liquidation fee is sent to the governance pool address for fee distribution.
Chain-State Storage Relay (CSSR)
The Mochi Chain-State Storage Relay (CSSR) model ensures that any relevant token state is committed to on-chain data availability. It does so by separating the process into:
- Saving the StateProof.
- Observing the data.
Bifurcating the process ensures that StateProof can open up access to chain-states, saving the state of previous blocks to help support a diverse range of token data. This expands the limitations of current forms of historical data access since a pair can only submit data once in every 256 blocks.
Below describes how the StorageProof CSSR works:
- A queries to get the data of X in block #10000 when the latest block is #10100. This will record a small hint (block state) about block #10000.
- B wants to access the data of Y in block #10000 when the latest block is #10300 (which is not possible in other approaches as it is more than 256 blocks).
- B can use A’s hint stored in the CSSR and find the right price.
With the StorageProof CSSR, it is easy to access accurate historical on-chain data of long-tail assets, which has not been possible before.
Since Mochi allows users to deposit LP tokens as collateral, calculating the LP token’s critical data is required. We can use the CSSR Router to route through multiple layers and unwrap the data of the underlying token.
Let’s say we want to calculate the price of the “ETH<>BTC Uniswap V2 LP token.”:
- CSSR Router routes the query request to “Uniswap V2 LP Adapter CSSR.”
- The Uniswap V2 LP Adapter CSSR finds the total locked ETH and BTC amount in the “ETH<>BTC Uniswap Pair” and queries ETH and BTC price data to the CSSR Router.
- CSSR Router routes the ETH and BTC price data query request to the Chainlink oracle and returns the result.
- “Uniswap V2 LP Adapter CSSR” calculates the total price of assets locked in the LP pool and calculates the LP token price based on it.
For more details, read the Mochi whitepaper here.