DeFi Series | Lending, Spot and Margin Trading: The Syllogism of Decentralized Finance (I)
Author: Scott Winges
Translation: Flash Chan
Source: Encrypted Valley
In 2019, the term “DeFi” (decentralized finance) became more and more popular among crypto asset enthusiasts and developers.
Encryption Valley has long been concerned about the development of decentralized financial markets. It has previously published feature articles to introduce and discuss them.
Despite the scope of DeFi, the field currently consists of three main components:
These functions are the cornerstone of a prosperous economy, so they dominate most of DeFi's markets.
In this "Trilogy" series, we will detail how these functions work in a decentralized world, how they relate to each other, and why they are so powerful.
Let's start with decentralized lending, because it is probably the easiest to understand in the above categories. The premise of borrowing is simple:
- Spot Trading;
- Margin trading;
Most of us have made some kind of borrowing outside of cryptographic assets. Whether you are lending money to a friend, a student loan, or a mortgage, these are the basic forms of lending. The main difference in DeFi is that all of these operations must be done without any information about the parties to the loan.
Although crypto assets can be lend to others in a variety of ways, the most popular form of lending in DeFi is through a pool of decentralized loans.
In the loan pool, all market-specific lenders deposit their assets into a smart contract. Borrowers can get loans from these assets rather than individual lenders. The interest paid by the borrower is shared by all lenders based on the amount they deposit into the pool. The interest rate paid by the borrower is usually based on an algorithm of supply and demand (more borrowing demand = higher interest rate, more supply = lower interest rate).
There are currently several decentralized loan products in use, such as Compound, dydx and Fulcrum. There are even websites to track interest rate changes between these platforms: https://loanlist.io/asset/dai.
For those who are not familiar with these systems, it is natural to ask a question:
“If these loans are decentralized, how can I be sure that the borrowers will repay my loan? How can I guarantee that they will not flee with money?”
Before allowing users to borrow from these pools, they must first deposit some form of collateral into a smart contract. The collateral is held by the lender to ensure that the borrower does not abscond with the money. In a mortgage, your collateral is the house itself. If you don't pay the mortgage fee, your house will be confiscated by the bank.
A no-credit loan is only valid if the loan is over-guaranteed. In other words, the value of the collateral is higher than the loan itself. Here's a simple example of its decentralized world:
Bob wants to do something with DAI, but his personal wallet only has ETH. Bob decided to deposit 2 ETH as a collateral in a loan pool (currently at 180 DAI each) and get a 180 DAI loan at 10% per annum. After a few months, Bob no longer needs DAI, and now he owes 5 DAI interest. He repaid his 180 DAI loan + 5 DAI interest and redeemed his 2 ETHs, very good.
In the above example, the loan pool is very happy because Bob has 2 ETH (worth 360 DAI) mortgage deposits, and they only lend him 180 DAI. Even if he does not repay 180 DAI, his collateral is worth more than the loan, so the loan pool is safe. In this example, he did repay the loan to recover the mortgage, and the loan pool received 5 DAI interest, which was allocated in the pool. Bob is happy because he doesn't have to sell his ETH, but he can still use the borrowed DAI. This kind of interaction is completely trust-free: even if Bob's information is unknown, the system works.
However, there is a slightly more complicated issue to consider here: What if the price of ETH-DAI changes drastically?
If the value of your collateral falls sharply relative to the assets you borrowed, you will find that your loan is worth more than your collateral. This is not a good situation for the lender: if the collateral can no longer cover the loan, the borrower has no reason to return the loan and the lender will lose money. Because lending platforms must ensure that their lenders don't lose money, they have a way to prevent this from happening: liquidation.
If your collateral starts to approach the value of the assets you borrow, these platforms will sell (liquidate) your collateral to repay the loan in full.
In general, there is an additional security margin in the smart contracts of these platforms, typically between 15% and 20%, depending on the asset class.
So let's revisit Bob's example again.
So, Bob once again saved twice the collateral to borrow 180 DAI. At the time, 1 ETH was 180 DAI, so Bob had about 360 DAI of collateral to borrow 180 DAI assets (with a mortgage rate of 200%). In his opinion everything is fine until the price of ETH suddenly dive!
When the value of 1 ETH reaches 105 DAI, Bob's collateral is now worth only 210 DAI: very close to his 180 DAI loan (the mortgage rate is 117%). The margin of safety of the loan pool is 20%, so it began to liquidate Bob's 2 times collateral to avoid a loss in the loan pool. Once the liquidation is triggered, Bob loses the right to use the collateral. He kept his 180 DAI loan, but his 2 ETHs have been lost!
The way the loan pool handles these collaterals varies from platform to platform. Some platforms use different discounts for auctions, some have established reserve pools, discounted internally, and some directly transfer them to decentralized exchanges. These pools of funds try to ensure that even if the price of collateral falls rapidly, they can still sell collateral to fully recover the loan.
Note: Many people pay close attention to these liquidation because it can form a profitable arbitrage opportunity.
But let's take a step back and think about it… Why would someone want to borrow money instead of just using a decentralized exchange to trade? There will be a lot of speculation about use cases in the future, but the main use case for borrowing crypto assets is to open positions in the market (margin transactions).
For example, if I believe that ETH will add value, I will do more ETH. If I firmly believe that ETH will depreciate, I will short ETH. With loans, you can leverage margin trading to leverage these positions to effectively increase your earnings or losses as asset prices change.
Loan institutions enable margin traders to gain purchasing power beyond their funds, or bet that the price of assets will fall. Without a lender, margin traders cannot survive!
Lenders want others to participate in margin trading to increase their profits. Margin traders want more people to lend so they can borrow at a lower interest rate.
In the second part of this series, we will show you how to use a loan to establish a position in the market and the advantages and disadvantages of using DeFi for margin trading. (To be continued)
- Encrypted assets placed in a regular wallet do not generate any interest (similar to a basic bank checking account);
- One way to earn interest is to lend your assets to someone else (like a bank savings account);