Risk Underwriting Mechanism

Published on Jul 14, 2023Updated on May 15, 20247 min read

(i) Background

The high volatility of the perpetual swap riveting spot index may result in additional risk to market volatility. Sudden changes to oracle price may cause the users' position value to become less than zero, resulting in a risk of margin call.

Thus, OKX-DEX has set up an insurance fund and ADL (Auto-deleveraging) as a risk underwriting under extreme market volatility. Details are as follows:

  1. Step 1 (Insurance Fund): The insurance fund will be prioritized to cover losses brought by risk exposure, while bearing the additional loss for the users, and allowing them to avoid the risk of fund recovery.

  2. Step 2 (ADL): The platform is exposed to risks relating to fund savings and market liquidity. When such risks continue to rise, ADL may be activated to relieve the margin call accounts, and ensuring market stability.

(ii) Insurance Fund

The insurance fund is the first line of defense used by the OKX-DEX platform to resist the risk of massive liquidation. The platform acts as a credit guarantee to help users underwrite losses brought by liquidation risks, and mainly composed of the fund provided by OKX and the liquidation surplus from the liquidation orders.

  • USDC is used as a dimension for OKX-DEX on chain. Click here to view balance in real time. The insurance fund is not decentralized for the time being. OKX-DEX will be responsible for private keys to operate deposits and withdrawals. For subsequent iterations, we aim to decentralize it to higher degrees through POR and other forms; however, nevertheless, our current focus is to ensure that losses incurred by any risks can be compensated in a timely manner.

  • To combat against extreme market risk, the insurance fund for individual underlying swaps continues to suppress risk, and the insurance fund for different underlying swaps and currencies are independent of each other. The specific rules are as follows:

Classification Dimension of Insurance Fund Rules of Insurance Fund Example
Level 1 Dimension of Overall Settlement Currency USDC-Margined: Insurance fund for all underlying perpetual swaps are paid in USDC.
Common insurance funding pool on the chain
Insurance fund for BTCUSDC perpetual swaps are in USDC.
Insurance fund for ETHUSDC perpetual swaps are in USDC.
Summation of different USDC pool
Level 2 Dimension of Single Underlying Swap USDC-Margined: Insurance fund for all underlying perpetual swaps are paid in USDC.
Pools are independent of each other and act as a trigger for ADL.
Insurance fund for BTCUSDC perpetual swaps are paid in USDC. Separate statistics shall be created for different funding size.
Insurance fund for ETHUSDC perpetual swaps are paid in USDC. Separate statistics shall be created for different funding size.

All losses or yield brought by forced reduction and liquidation orders in the market are either transferred out from or injected into the insurance fund account, which is recorded as loss of margin call and liquidation. We will provide regular updates (every hour) on the snapshot data based on the latest data.

(iii) Auto-deleveraging (ADL)

(How to select ADL counterparties? Select generic ADL counterparties. Users also need to take their yields and ranking into consideration.)

Auto-deleveraging, abbreviated as ADL, refers to a mechanism for liquidation of counterparty positions to control the platform's overall risk under extreme market conditions or force majeure that lead to the rise of the following two risks. The risk type and triggering mechanisms are as follows:

1. Fund Saving Risk: Insufficient or rapid decline in insurance fund for overall/single underlying swap. (Currently, "rapid decline" refers to a straight-line decline in insurance fund by 30% from the peak within 8 hours for single underlying swap, or 50% decline (within 8 hours), or a complete depletion of insurance fund for overall settlement currency, which may be adjusted by the platform according to market conditions.)

2. Liquidity Risk: Due to the lack of market liquidity, a single underlying swap cannot be filled in a timely manner. (Currently, "lack of market liquidity" refers to the margin call orders which cannot be executed in the market for a long time, leading to the scale of loss and higher unilateral risk.)

Solution(s): Once ADL is triggered, the platform shall no longer place any pending orders on the market and awaits for a suitable price to liquidate user's positions (either partially or fully). Instead, it will directly find the counterparty account with the highest ranking and execute with the bankruptcy price of the margin call user with its counterparty account. Upon the execution, the counterparty position will be closed. The profits from the position will be added to the account balance. ADL execute positions using the bankruptcy price of a margin call user with its counterparty account, with zero trading fee.

User Protection: In order to protect counterparty users from potential excess losses incurred when trading at bankruptcy prices, we have set a cap on the amount of losses that can be borne by a single user. We plan to utilize platform funds to provide some ADL compensation to counterparties in subsequent iterations.

Sorting Rules: The counterparty sorting of ADLs is determined by combining the account risk or position risk, and the profits of the position in that contract. The specific rules are as follows:

Position Mode Calculation of Leverage Profits Counterparty Sorting Rules
Single-currency Cross Margin Profiting Positions: Leverage Profit = Position Profit Ratio / Account Margin Ratio
Losing Positions: Leverage Profit = Position Profit Ratio / Account Margin Ratio
Sorted by leverage profits in descending order

Signal light displays: Users can see their own ADL risk level in real-time through the signal lights on the page. The signal light has 5 grids. When all 5 grids are on, it means that the ADL risk is at the highest level.

According to the above mentioned rules on leverage profits, the ADL risk is higher when the counterparty's rank is more towards the top end; when only 1 grit is on, it means the counterparty's ranking of its position is towards the bottom and the ADL risk is lower. Also, accounts with higher yields and lower position margin ratio are more likely to be used as ADL counterparties and faced the ADL risk.

8

Please note that higher liquidity risk (i.e., when the liquidity risk of an individual contract is higher), the risk of the contract executed with ADL shall increase as well.

Users can reduce the probability of ADL by:

  1. closing (partially or entirely) positions with higher yields, or

  2. lowering leverage and rising margin ratio.

Upon executing ADL on a position, user will receive an email/push notification informing him/her of the reduced position and its price. Users may also check the billing for the reduced position on the Report Center page, with the billing type stated as "ADL".

Example of Risk Underwriting: Assuming the initial margin is 300%, and the maintenance margin ratio is 250%. User A holds a short position of 20,000 USDC and -1BTC with 5x leverage. His/her average opening price is at 23,800 USDC/BTC, and an estimated liquidation price of 24,000 USDC/BTC. User's margin call has been triggered when the price rose to 24,500 USDC/BTC.

  1. Scenario 1: If the platform's fund savings risk is lower, the insurance fund shall be sufficient. The latter shall compensate the user for his/her balance of the margin call position, and may view the amount and compensation amount of the margin call position in the billing details.

  2. Scenario 2: If the platform's fund savings risk is higher, the insurance fund shall be insufficient, and the above mentioned condition shall be triggered. Assuming the following is the profit ranking of the counterparty leverage when ADL is triggered,

Users Signal Lights Grits
B |||||
C |||
D ||
E ||

User A will first match User B's position and execute ADL, and transfers 20,000 USDC and -1 BTC to User B (if User B takes too high a loss, his position will be matched automatically with the next user).

Upon the ADL, User A's underlying position will be closed entirely.