Lending
THORFi Lending within THORChain
Last updated
THORFi Lending within THORChain
Last updated
Since Sept-2024, the opening of new loans has been disabled as per Node consensus. Since 04 Jan 2025 closing of loans has been disabled. See for more information.
Lending allows users to deposit native collateral, and then create a debt at a collateralization ratio (CR). The debt is always denominated in USD (aka TOR
), regardless of what L1 asset the user receives.
All loans have 0% interest, no liquidations, and no expiration. Since ADR 012 was implemented in Feb-2024, a flat 200% CR (or 50% Loan-to-Value, LTV) was implemented. Risk by:
Limits on collateral for the network and each pool
Slip-based fees when opening and closing loans
A circuit breaker on RUNE total supply
Lending allows users to:
Create a loan using native assets as collateral
Hold a loan without the risk of liquidation
Be short on USD and long on crypto assets such as Bitcoin
Lending benefits the protocol by:
Increased capital efficiency of the pools which increases system income and real yield.
Increased trading volume
Increased total bonded, allowing THORChain to scale.
Providing an attractive sink for capital
Collateral will be restricted to BTC and ETH only on launch. The Minimum Loan Term will be 30 days on launch.
The user provides Bitcoin collateral and can receive the debt in any asset however it is all accounted for in TOR.
The user sends in collateral (BTC.BTC -> RUNE, RUNE -> THOR.BTC)
THOR.BTC is held as collateral in the Lending module
Convert THOR.BTC value to TOR terms
Calculate debt in TOR based on CR and collateral TOR value
Mint TOR
TOR -> RUNE, RUNE -> L1 out (e.g. - ETH)
Users can repay loans at any time, with any amount in any asset. Repayment is converted into TOR.
L1 -> RUNE (optional, user can also pay back with RUNE)
RUNE -> Mint TOR
Burn TOR (amount deducted from loan debt)
Burn Derived Asset (THOR.BTC) (amount is the same percentage of collateral as a percentage of loan debt paid) -> Mint RUNE
RUNE -> BTC.BTC (loan originator)
Collateral is not returned until the loan is fully repaid. The user will always have the right to have their returned collateral if they repay the loan.
Derived pools are created for each derived asset, including TOR, to allow swapping between L1 assets and derived assets va RUNE. Their depths expand and contract to throttle the amount of slippage users pay when swapping from an L1 asset to a derived asset. In periods of volatility, pool depth contracts to increase the slippage on swaps during this period of time. This incentivises users to wait for a period of lower volatility to exit/enter lending and protects the system against pool manipulation.
The TOR pool is a derived asset pool and operates the same as other derived asset pools except the TOR price comes from the medium of the four pools instead of one L1 Asset Pool.
The totalRuneDepth
is the sum of all RUNE in anchor pools (i.e. - USDC, USDT, BUSD-BD1 for TOR or just BTC.BTC for the L1)
MaxAnchorBlocks
Protocol Setting, blocks to accumulate slip
DerivedMinDepth
Protocol Setting, Min derived pool depth
DerivedDepthBasisPts
Protocol Setting, increase/decrease derived pool depth
MaxAnchorSlip
Protocol Setting, Max allowed slip on derived pool
Update RUNE depth to constrict based on slip:
Where r
is the RUNE depth of the pool and health
is derived_depth_bps.
The derivedPoolRuneDepth
and derivedPoolAssetDepth
can then be used to calculate the swap output for the derived pool.
The difference between the swap outputs of the derived and L1 pools quantifies the reduction due to the variable depth of the derived pool.
Lending is capped by limited the collateral that can be received by the protocol. The lendingLever
throttles the amount of RUNE available for lending, in basis points.
totalAvailableRuneForProtocol
is distributed among pools available for lending based on their RUNE depth. For each lending pool, the totalAvailableRuneForPool
(tarfp
) is:
totalAvailableAssetForPool
is converted from RUNE to Asset value. This imposes a collateral holding limit for each pool, a new loan cannot be opened if the new gross collateral exceeds this amount.
Since Feb-2024, a flat CR of 200% has been implemented by setting both MinCR and MaxCR to 200%.
A dynamic CR increases as loans are opened within a pool and reduces as loans are repaid.
a
Current pool collateral + new loan collateral
b
TotalAvailableAssetForPool
MinCR
Ratio in basis points, (LTV = 1/CR)
MaxCR
Basis points, protocol setting
Debt is calculated based on the collateral provided and the CR of the pool.
CollateralValueInTOR
Collateral Value in TOR
CR
Collateralization ratio
The TOR debt is swapped to the requested L1 asset and then sent to the user, slip fees apply.
The protocol setting loanRepaymentMaturity
defines the number of blocks before a loan can be repaid/closed. There is no option for repayment before this period.
The formula to calculate MaxLoanStreamingQty
is as follows:
This gives the following effect:
100%: Infinite
99.99%: 10,000
99.9%: 1,000
99%: 100
98%: 50
95%: 20 (20 streams means a $1m loan is 50BPS)
90%: 10
80%: 5
70%: 3
60%: 2
50%: 2
0-50%: 1 (e.g., no streaming)
This limits the streaming swap for Lending for open and closing loans during highly volatile times.
Opening new loans creates a deflationary effect on the $RUNE asset, whereas closing loans creates an inflationary effect on $RUNE.
If the value of $RUNE relative to $BTC is the same when the loan is opened and closed, there is no net inflationary effect on $RUNE (same amount burned as minted minus the swap fee). However, if the value of the collateral asset increases relative to $RUNE between the time the loan is opened and closed, there will be net inflation of $RUNE supply.
Lending controls are in place to address these concerns.
Block Science reviewed the lending mechanisms exhaustively. The Output of their research includes:
with full Lending details was released and approved by Node Operators.
- setting CR to flat 200%, and burning Standby Reserve to increase collateral cap.
Derived assets, such as thor.btc
andthor.tor
, are algorithmic coins that are backed by the liquidity of RUNE, and the liquidity of that is based on the RUNE-ASSET pair. Derived assets are swapped from or swap to L1 assets, via RUNE, using that are based on the equivalent L1 pools. Unlike, Synthetic Assets, derived assets are independent of Liquidity Pools and all swap fees are burnt. Derived assets are for accounting and there are no plans for them to be exportable or held by users.
TOR (thor.tor
) is a non-transferable unit of account within THORChain designed to match the value of $1 USD and has been in use since . It cannot be exported anywhere and always has a market cap of $0. TOR is valued by taking the median price of the active USD pools.
All collateral, debt and repayments within Lending are converted to and accounted for in TOR. To understand TOR in depth, go to the dedicated .
The depth of the derived pool will fluctuate depending on the amount of the trading volume within a time window determined by the variable , currently about 15 hours. This will reduce the output of swaps from derived pools compared to L1 pools. The API endpoint contains 'derived_depth_bps
' which shows the derived pool depth relative to the L1 pool depth. For example, 'derived_depth_bps:9091
' this means the pool is 90.91% depth of the L1 Bitcoin pool. To quantify the impact this has to swaps across the derived pool, you first need to calculate the derived pool's RUNE depth using the following formula:
Next, multiply derivedPoolRuneDepth
by (the ratio of RUNE to Asset) to determine the derivedPoolAssetDepth
.
are enabled on Lending; however, the number of streaming sub-swaps is subject to the maximum loan streaming quantity which determined by the health of the system. The loan streaming quantity (MaxLoanStreamingQty
) is calculated based on the health of the system, represented by the ratio of to real depth (x
).
Loan Streaming Swap Interveral is set to 1 via