Frequently asked questions
VaR (Value at Risk) refers to the amount of capital that is found to be insolvent (unable to be liquidated for a position that is below the required collateralization ratio) at the end of a simulation run. Technically, an account i is insolvent if the total value of debt D_i is greater than the total value of collateral C_i owned by the account. The net insolvent amount is defined as the total value of debt minus the total value of collateral, summing over all the insolvent accounts. We run thousands of simulations across varying levels of volatility and the risk parameters in the protocol in order to assess how various rational agents will react under different conditions. After running these simulations for a given set of parameters (i.e. the current parameters in the system, or the parameters Gauntlet is recommending) we then order them by the net insolvent amounts and then take the 95th percentile value. This 95th percentile is the VaR quoted on the dashboard. For more details, please see our blog post on VaR Deepdive.
Whereas VaR is calculated as the 95th percentile net insolvent debt amount, LaR is calculated as the 95th percentile amount of liquidations that occur in our simulations.
Borrow Usage provides information about how aggressively depositors of collateral borrow against their supply. On a per-user level, Borrow Usage answers the question “of the amount a borrower is able to borrow given their collateral supplied, how much of that are they actually borrowing?” On a per-asset level, it is defined as:
Gauntlet addresses “Market Risk.” Decentralized protocols face a number of risks that are more complex than those faced by their centralized counterparts. One of the main reasons for this is that the core function of liquidation, which aims to ensure that assets are always greater than liabilities, involves interactions external to the protocol. Centralized venues simply liquidate underwater collateral themselves without requiring counter-party risk, whereas decentralized protocols usually rely on liquidators competing to provide the service to the protocol. Smart contract audits cover endogenous risk (security risks within a contract) but do not assess market risks that concern exogenous interactions required for proper protocol function. Protocols that allow for supplying and borrowing of cryptoassets are particularly sensitive to price shocks. They require a number of different participants to be sufficiently incentivized to ensure liens are priced and liquidated correctly. Liquidators compete for defaulted collateral and are incentivized to participate by a combination of market forces and discounts provided by the protocol. The primary sources of market risk within decentralized lending protocols usually are:
- Shocks to market prices of collateral that cause the contract to become insolvent due to under-collateralization
- Loss of liquidity in an external market place, leading to a liquidators being disincentivized to liquidate defaulted collateral
- Cascades of liquidations impacting external market prices which in turn lead to further liquidations (i.e. a deflationary spiral)
- Smart contract risk: logic: errors in the smart contract leading to undesirable outcomes
- Governance risk: malicious actors acquiring / using governance power to enact protocol changes Oracle risk: manipulation of oracle prices can lead to exploitative attacks, causing users and the protocol to lose funds
- Custodial risk: although less prevalent in DeFi, centralized organizations may rely on custody solutions
- Regulatory risk
There is always a tradeoff between risk and capital efficiency. Usually, allowing more capital efficiency in the protocol can result in increased market risk. “Too much risk” is dependent on the risk tolerance of the protocol"s stakeholders. Generally, it is useful to compare the risk to the reserves available to backstop potentially losses. Protocols that have large “reserves” to cover potential insolvencies should be able to withstand a greater aggregate amount of insolvencies. Of course, the reserve"s resilience and composition of assets are important factors in determining its ability to withstand market downturns.
After an asset is listed on a lending platform, we analyze borrower behavior and on-chain liquidity data. For our simulations, we usually need to see around 30 days of the asset being listed to form an understanding around volatility, liquidity, and trading data on DEXs over time. This helps prevent the problem of indexing on short-term events. In addition, the newly listed assets will have time to be battle-tested in the market. We always recommend a conservative onboarding approach to lending protocols to ensure that we aren"t exposed to outsized risk from both a mechanism perspective as well as market risk perspective. Once our simulations incorporate the asset, we are able to model how CF increases impact market risk and capital efficiency under a broad range of scenarios, and recommend parameter changes accordingly.
At Gauntlet, we leverage Agent-Based Simulation (ABS) to model tail market events and interactions between different users within DeFi protocols. At a high level, ABS allows a set of "agents" (pieces of code meant to mimic actual user behavior) to make rational actions against DeFi protocols according to some "what-if" market scenario. We run thousands of these scenarios to understand what happens in the case of a catastrophic market event (i.e. a major market crash in crypto).
Our models incorporate the relevant data and analysis in order to simulate our clients" protocols. This may include custom business logic, data pipelines, and analysis of user behavior to drive our agent models.
Our models incorporate the relevant data and analysis in order to simulate our clients" protocols. This may include custom business logic, data pipelines, and analysis of user behavior to drive our agent models.
Since different accounts supply different mixes of collateral assets, each with different collateral factors, the max collateralization ratio will differ between them. Liquidations are triggered when an account"s health score goes below 1, which is partly a function of collateral factors, and partly a function of the total borrow vs collateral supplied.
All else equal, if an account has a lower collateralization ratio, it"s more likely to be liquidated. A similar calculation occurs for CDPs, except that liquidation threshold is calculated in the inverse, known as collateral factor as described by the following equation:
Cascades of liquidations impact external market prices which in turn lead to further liquidations.
To give a concrete example, let"s say there"s collateral asset C, and borrow asset B.
User 1 supplies C and borrows B. Let"s say the price of C falls such that User 1"s account is now liquidatable. A liquidator sees this as an opportunity to profit (to earn the liquidation bonus). The liquidator purchases asset B, pays back the loan, and receives C in return (and may use a flash loan in order to do so). Liquidators usually would immediately sell the asset in order to lock in a profit. This selling pressure on asset C creates further downward pressure on asset C. Asset C falls in price, which causes more accounts to be flagged for liquidation. The process repeats itself.
Eventually, there may not be enough liquidity in the marketplace to absorb liquidations of asset C. Volatility conditions may have become extreme, and spreads on centralized exchanges have widened dramatically. This scenario may also occur in times of high gas fees which make liquidations unprofitable for liquidators. On decentralized exchanges, liquidity may have dried up as well. At this point, the liquidation mechanism (relying on third party liquidators) may fail, because their costs of liquidation (slippage from selling asset C as well as gas costs) may exceed the revenue from liquidation (the liquidation bonus/incentive). When this occurs, accounts can spiral straight to insolvency, which is bad debt for the protocol.
To give a concrete example, let"s say there"s collateral asset C, and borrow asset B.
User 1 supplies C and borrows B. Let"s say the price of C falls such that User 1"s account is now liquidatable. A liquidator sees this as an opportunity to profit (to earn the liquidation bonus). The liquidator purchases asset B, pays back the loan, and receives C in return (and may use a flash loan in order to do so). Liquidators usually would immediately sell the asset in order to lock in a profit. This selling pressure on asset C creates further downward pressure on asset C. Asset C falls in price, which causes more accounts to be flagged for liquidation. The process repeats itself.
Eventually, there may not be enough liquidity in the marketplace to absorb liquidations of asset C. Volatility conditions may have become extreme, and spreads on centralized exchanges have widened dramatically. This scenario may also occur in times of high gas fees which make liquidations unprofitable for liquidators. On decentralized exchanges, liquidity may have dried up as well. At this point, the liquidation mechanism (relying on third party liquidators) may fail, because their costs of liquidation (slippage from selling asset C as well as gas costs) may exceed the revenue from liquidation (the liquidation bonus/incentive). When this occurs, accounts can spiral straight to insolvency, which is bad debt for the protocol.
In addition to that google sheet, here's some blurbs to aid in this
- Given a single asset, lower LT will result in more liquidations
- Once we introduce a many-many relation, this changes
- The order in which collateral is liquidated depends on liquidation thresholds and market dynamics of other assets (not just the collateral asset)
- Liquidators choose which collateral assets to liquidate for an eligible loan based on what"s most profitable (currently what is the largest borrow and supply in the account at the time of liquidation)
- A change in liquidation threshold (which would lead to an earlier liquidation in the first account to be liquidated) could lead to less total liquidations if it leads to a less volatile asset being liquidated in later time steps.
- Example: User deposits 20 WETH, 1 WBTC, and 200 AAVE (at prices of 2,000 WETH, 20,000 WBTC, and 100 AAVE) and borrows 50,000 USDC. In a baseline sim, the user starts with 40,000 USD worth of WETH, 20,000 USD worth of WBTC, and 20,000 USD worth of AAVE. Let"s say that this account gets liquidated at timestep X when the balances are 15,000 USD worth of WETH, 18,000 USD worth of WBTC, and 19,000 USD worth of AAVE. If this account is liquidated, the liquidator would choose to liquidate AAVE against USDC. However, if the liquidation threshold of WETH is lowered, the liquidation could happen at an earlier timestep Y when the balances are 21,000 USD worth of WETH, 19,000 worth of WBTC, and 19,000 worth of AAVE. If this account is liquidated, the liquidator would choose to liquidate WETH against USDC. Since WETH is more liquid than AAVE, the price impact of a selling the assets from a liquidation of WETH are far less than AAVE, so it would lead to less total liquidations.
- Value of collateral is path dependent on liquidator behavior
- Which is why sims are valuable
- Lowering LTs for a collateral will not necessarily increase the amount of that collateral asset liquidated
Gauntlet will not conduct simulations using fake data to assess the risk. Simulations do not lend well to this type of listing when there is no prior data. Gauntlet has in the past used borrower distributions from similar assets to assess risk. However, this has been a weak signal given how different each asset"s usage behavior is when actually incorporated into the lending platform. As such, we will not conduct simulation analysis to predict user behavior ahead of an asset"s listing.