A Detailed Explanation of THORchain's Non-Custodial Lending: Could It Be a New Model to Transform DeFi?
Author: 0x137, Rhythm
In recent discussions about DeFi, I have repeatedly heard a name—THORchain. This project, which has been silent for months, seems to have gained some traction again recently. Initially, I intended to track it as a hot topic, but after careful study, I became somewhat excited. The upcoming THORFi from THORchain is likely to become a new model for DeFi lending.
THORchain? Is that the project that was hacked?
Before diving into the THORFi rabbit hole, let's first understand what THORchain actually is, as many people still associate it with being "the hacked project."
THORchain is an application chain built using the Cosmos SDK, designed to enable cross-chain trading of various native assets using non-native cryptocurrencies, such as directly exchanging BTC for ETH. This sounds like a cross-chain bridge, but there are significant differences.
Currently, there are mainly two ways to transfer assets across chains: cross-chain bridges and centralized exchanges. Both methods carry varying degrees of centralization or custodial risk, while THORchain's uniqueness lies in creating a completely decentralized "cross-chain" trading channel.
THORSwap is the main application on THORchain; it is more like a cross-chain Uniswap, providing liquidity pools for native tokens of various underlying L1 and L2 chains, allowing users to achieve cross-chain asset transactions through trading. However, unlike Uniswap, which provides liquidity for each trading pair, THORchain's trading logic centers around the RUNE token.
Taking BTC to ETH as an example, users actually first exchange BTC for RUNE in the BTC-RUNE pool, and then use RUNE to exchange for ETH in the ETH-RUNE pool. This logic has the advantage of creating the possibility of capturing protocol value for RUNE.
THORchain's consensus mechanism stipulates that the token ratio in each LP liquidity pool must be 1:1, and the value of RUNE staked by validating nodes must equal or exceed the total value of the LP pool. In other words, the value of RUNE staked on THORchain must be three times that of other assets, and the profits generated by the protocol are distributed proportionally between LP providers and validating nodes.
Image from Multicoin Capital report
The more assets are transferred across chains or traded, the more RUNE is staked. This creates a flywheel effect for capturing RUNE's value and increasing trading volume.
Image from Multicoin Capital report
Additionally, THORchain will use its own revenue reserves to provide impermanent loss protection for LPs, increasing compensation by 1% daily over 100 days, after which LP providers will no longer face impermanent loss.
Image from Delphi Digital report
Sounds interesting, right? However, there is a key issue in THORchain's design that has led it to be viewed as "the project that keeps getting hacked."
The essence of THORchain is still a cross-chain transfer of information. Users send assets from the BTC network to THORchain nodes, and after the nodes confirm receipt of the information, they send an equivalent amount of assets to the user on the ETH mainnet. However, if there is a problem during this routing process, it can lead to asset loss.
The exploit incident in June last year was caused by this. Hackers tricked nodes into believing they had deposited a large amount of ETH, resulting in an erroneous outflow of $140,000. Although the THORchain network responded quickly, and core developers immediately implemented fixes and compensation measures, this incident raised concerns about the code quality of THORchain, leading to a significant drop in the price of RUNE.
Of course, after that, the THORChain team has made many improvements to the protocol to enhance network security, including automatic solvency checkers, validating node checks and power controls, and large fund withdrawal delay mechanisms.
It is important to emphasize that these upgrades and changes have negatively impacted user experience. The THORChain network frequently encounters bugs or updates, causing the network and trading to be forced to pause, with the most recent incident occurring just a few days ago.
Recently, due to the Cosmos team announcing that they would no longer maintain the 0.42.x version of the SDK, THORChain was forced to hard fork to upgrade to the latest 0.45.1 version. How the THORchain network performs post-fork and the team's coding capabilities will still need time to be tested.
Despite this, THORchain has become a hot topic of discussion in the DeFi community recently.
Why has THORchain become popular again?
Opening DeFi Llama, we find that THORchain's TVL has been steadily rising over the past month, thanks to new features launched by THORchain and further cross-chain developments.
THORChain Synthetics
Now that we know that assets on different chains do not actually cross chains on THORchain, this creates a potential minor issue. Take ETH, for example; since assets are always transferred on the Ethereum mainnet, they inevitably face high gas fees, which somewhat hinders the increase in THORchain's trading volume and liquidity.
To address this issue, THORchain has launched its own synthetic assets.
Unlike synthetic assets like WBTC and renBTC, the synthetic assets on THORchain are backed by LP pools within the ecosystem, half in RUNE and the other half in the target asset, making it more like an LP token. Of course, it is also pegged 1:1 to the target asset.
With synthetic assets, users can complete most transactions on THORchain, reducing their gas costs. Additionally, these assets unlock liquidity for LP pools, providing a solid platform for various future "money Legos" on THORchain.
IBC + LUNA
As mentioned earlier, the amount of RUNE staked is positively correlated with the protocol's liquidity and trading volume, so where does the liquidity come from? The answer is naturally new cross-chain assets.
Over the past few months, THORchain has been in an "expansion phase," continuously adding new cross-chain assets to provide liquidity sources for the protocol. In this regard, THORchain has many inherent advantages, as it is also built using the Cosmos SDK, allowing it to integrate more Cosmos-based projects like Osmosis and Kava more quickly.
Recently, the integration with Terra has caught people's attention. As the second-largest ecosystem by TVL, the liquidity that Terra can bring to THORchain is significant.
There is one more thing…
While THORchain Synthetics and the new cross-chain integrations are indeed exciting, in my opinion, THORchain's true ace is the upcoming THORFi.
Although the market prospects for decentralized cross-chain trading are vast, if THORchain only aims to be a trading platform, that would be somewhat limited. We all know that most profits in the financial world come from the lending market, and the development of DeFi and the entire crypto industry also relies on this sector.
Currently, DeFi lending has not created enough space for improving capital utilization and liquidity. First, it requires over-collateralization, and second, the liquidation risk is too high. Many protocols' solutions still revolve around simple looping, which, while improving capital utilization, sacrifices liquidity.
What if we could achieve zero liquidation risk for crypto asset lending? Wouldn't that solve many problems? This sounds like it might be too good to be true, but THORFi has indeed accomplished this, at least theoretically.
It should be noted that THORFi is still in development, and the documentation has just been publicly released for community feedback, but in terms of design, I am indeed attracted.
Without further ado, let's jump into the THORFi rabbit hole together.
THOR.USD
To build its own lending platform, THORchain has created its own stablecoin, THOR.USD. It uses a model similar to UST, where users burn RUNE to mint THOR.USD, and vice versa.
Like LUNA, once the value peg is achieved, the usage rate of THOR.USD will reflect on the price of RUNE, which goes without saying.
Borrowing
Unlike other lending platforms, the collateral accepted by THORFi must be LP assets, which essentially deepens the liquidity pools on THORchain and drives up the price of RUNE.
Another important component is the Collateralized Ratio (CR), which is determined by the depth of the LP pool plus the ratio of LP collateral to borrowed assets. The higher the collateral value, the higher the CR value, with maxCR being the maximum collateralization rate. For example, if the collateral value is $1,000 and the CR value is 200%, the maximum value a user can borrow is $500.
As shown in the figure below, as old loans are continuously repaid and new loans are borrowed, the CR value will keep increasing, allowing the network to gain more revenue. The maxCR can be adjusted after a period to encourage borrowing behavior to remain as active as possible.
With LP assets as collateral, who will provide the loans? This is where THOR.USD comes into play.
Using the data from the previous figure as an example, when the value of the collateralized LP assets is $14,000 and the CR value is 220.04% (red box), the theoretical value the user can borrow is $6,362 (basket).
However, we see that the actual value received by the user is $6,361 (yellow box). This is because THORFi, after determining the borrowable value, will mint an equivalent value of RUNE, then burn it to mint THOR.USD, and charge a certain percentage fee to inject value into THOR.USD, which in this case is $1 (green box). Since the value of THOR.USD and RUNE is always linked, the supply of RUNE still increases after the burn, in this case by 908.93 tokens (purple box).
This step is crucial because it shifts the borrower from the user to the protocol itself. In other words, THORFi takes on the risk of the loan by minting RUNE. Of course, as the borrower, the earnings from the LP assets also belong to the protocol, which in this case is 20% (upper left box).
THORSaving
THORSaving is another core component of THORFi that enables zero-liquidation lending. Simply put, it provides an opportunity for L1 token holders who do not want exposure to RUNE to generate yield.
For example, a BTC maxi who only wants to hold BTC but also wants to earn higher BTC yields through THORchain can deposit their BTC into THORSaving, and the earnings from the LP collateral will be proportionally distributed to these depositors.
There is another key operation here, as native BTC cannot be directly deposited into THORSaving; users actually need to exchange for an equivalent amount of RUNE, then burn it to mint the synthetic asset thourBTC.
Then the magic happens.
In the figure below, we can see that for every deposit of a synthetic asset, a corresponding amount of RUNE is burned (red box), and since the CR value is always greater than 100%, when the deposit value equals the collateral value (green box), the amount of RUNE burned must exceed the amount minted, in this case: 908.93 - 20,000.01 = -19,091.08 tokens (purple box).
Thus, the protocol, as the lender, has achieved risk mitigation at this moment, as the amount of RUNE burned has exceeded the amount minted.
In other words, whether the collateral value is below the borrowing value is no longer relevant, as the loan issued by the protocol has already been repaid in the previous step.
However, there is a problem: if the deposit value in THORSaving is less than the collateral value, it will pose a risk of insufficient burn quantity. How does THORFi solve this problem?
In THORSaving, although the total LP collateral earnings are fixed, they are not fixed for individuals, as the earnings are distributed proportionally.
For example, in the figure below, if there is only $40,000.04 in total deposits in THORSaving, the APY for users will reach 70%, making the 20% APY from the LP pool less attractive. This means that people will be more willing to deposit in THORSaving at this time.
As deposits continue to increase, the APY of THORSaving will gradually decrease, and when the deposit value reaches $140,000, equal to the collateral value, the APY will return to the 20% level of the LP pool, achieving a certain economic balance between both sides.
Self-repaying loans
In the initial documentation of THORFi, the team referred to THORFi's lending function as zero-interest loans. Borrowers forgo the earnings from LP collateral as interest compensation and do not pay any other fees.
To ensure that THORchain can generate sufficient revenue, all loans must remain open for at least 100 days, with an additional 1% fee for each day settled early.
First of all, just the zero-interest loans alone can stimulate quite a bit of liquidity, as THORchain is not targeting a single public chain ecosystem but the entire crypto space. However, during community feedback, the THORFi team decided to change it to negative interest loans, which is extremely important for further popularizing DeFi.
Imagine how an ordinary salary worker can invest in the crypto space without touching their savings. Clearly, a portion of their monthly salary must go towards daily expenses, making it difficult to achieve significant dollar-cost averaging.
But with stable and convenient negative interest loans, the situation changes. The invested assets can be used as collateral to borrow living expenses, while the collateral itself generates interest, which can automatically repay the loan.
For the entire crypto market, this undoubtedly attracts more funds into the space, accelerating the industry's popularization and development.
Although THORFi's zero-liquidation loans still require more practical testing, and the team's previous coding quality has raised some concerns, its wonderful design indeed offers a new perspective for DeFi lending. At least in my view, THORchain is on a correct and promising path.