Want to farm DeFi yield? Here’s what crypto financial institutions need to prepare

This article will outline the key steps and considerations for crypto financial institutions looking to enter the DeFi yield farming space.

Follow us


Authors: Damon Xu, 1Token founder and CEO; Phil Yang, Head of BD of 1Token

DeFi, the abbreviation of Decentralized Finance, in a broad sense refers to blockchain-based finance. Financial activities are conducted based on smart contracts based on blockchain rather than traditional financial institutions such as brokers, exchanges or banks.

A narrow understanding of DeFi is liquidity mining (aka DeFi yield mining) in a decentralized market, a method of earning more crypto asset through the crypto asset held. It encourages liquidity into the market by staking crypto asset into blockchain based “smart contract”, so that on the other side, buy-side crypto lending and trading users can consume the liquidity by paying interest and commission. In return for providing liquidity, the staking party (Liquidity Provider, abbreviated as LP) will receive income such as interest and fees.

Liquidity mining is nothing new in crypto market. In the past, centralized crypto exchange such as FCoin had implemented liquidity mining on order book, and huge amount of coins were rewarded to users who placed orders in the market to incentivize the provision of liquidity. However, liquidity mining on DeFi were not quite popular until 2020 with Compound’s lending / borrowing liquidity incentive program, in which both the crypto lenders and borrowers receive COMP coin rewards. In early stage, coins rewards were even worth more than the interest gap of borrowing and lending. Since users can deposit and borrow their crypto assets at the same time to gain rewards, a group of smart investors smell the chance in DeFi liquidity incentive program, and making it a profession called DeFi yield farming (yield farmers). Since then, other DeFi projects have also introduced schemes to improve the liquidity of their ecosystem, such as YFI, Uniswap, Sushiswap, Pancakeswap, and MDEX…

As mentioned in the previous article “Understanding the institutional market structure of Cryptocurrencies and its asset types”, fund hopes to be invested in good assets to achieve growth; assets need more money to accomplish their goals. DeFi yield mining has now become one of the mainstream assets in the crypto industry. Due to its high yield expectations, more and more projects of various types come one after another. In the early stage, these projects provide annual mining incentives of more than 1000%, and afterwards lands at 10%-50%, far exceeding those of traditional assets. Projects has been developed from Ethereum L1 and Ethereum L2 to BSC and HECO chains; protocols include COMP and AAVE for lending, Yearn for aggregation, and Uniswap, Sushiswap, MDEX for trading, etc. The Total Value Locked (TVL) of Top 10 DeFi smart contract has exceeded $50 billion and is growing continuously. These projects provide great interest-earning assets for crypto institutions that are sensitive to income while having flexible investment terms.

Basic classification of DeFi yield farming

DeFi yield farming can be generally classified into borrowing/lending (single-coin) mining, dual-coin AMM (Automated Market Maker) mining, leveraged mining, smart pool mining. Others include Synthetix on synthetic assets, MCDEX on perpetual contracts, and DYDX order book style trading and staking mining. Following is an introduction to the 4 main types of DeFi yield farming.

Borrowing/lending mining (Single-coin mining)

Borrowing/lending mining, similar to depositing money in a bank to obtain interest, is considered risk-free, meaning that there are no other risks except the technical risk of the smart contract itself (e.g., the contract is hacked). This technical risk inevitably exists in all DeFi protocols.

Borrowing and lending generates interests for mining: the borrower pays interest, which is collected by both the crypto lender and the liquidity provider (LP).

Obviously, the advantage of borrowing/lending mining is its relatively low risk, with the disadvantage of low yield. Therefore, some platforms reward platform coins as LP incentives.

For example: Compound Coin and other lending protocols.

An operation in which the proceeds of borrowing/lending can be obtained over and over again

Generally speaking, borrowing/lending mining is to deposit coins into the corresponding contract to obtain income, and some lending protocols will mint coinss on their own to represent the crypto asset deposited by the user in the system. For example, by depositing DAI in Compound, you can get cDAI (ie Compound DAI); by depositing Ethereum in Compound, you can get cETH. Repeat this operation, you can deposit cDAI into another protocol, which will mint a third coin to represent cDAI which is used to represent DAI, and so on. This type of operation is especially common in borrowing/lending protocol (Curve, Compound and AAVE). The original intention is to gain liquidity in the staked fund. At the same time, because there are farming incentives from both borrowing and lending, advanced players earn multiple interests through repeated operations.

– Dual-coin AMM mining

Based on the Automated Market Maker (AMM) model of yield farming, this mining method is to deposit two different crypto assets into the decentralized exchange (DEX) liquidity pool, and thus become a liquidity provider. The pool provides liquidity support for the trading platform, so that other trading users can use the pool to exchange/trade coins and pay transaction fees. LPs can share part of transaction fees and/or platform coin rewards based on their shares. This is the basis of the operation of the AMM. There are also several different formulas by different protocols, such as Uniswap V2, Uniswap V3, Balancer V2, Curve V2, where there’s plenty of public materials so won’t be discussed further in this article.

Here we should mention the concept of Impermanent Loss. During the process of dual-coin AMM, the coins’ relative price’s deviation from the initial price would lead to the respective changes of LP’s two coins (generally, one increases and another decreases). If you use the mixed denominator to calculate the current assets and initial investment (that is, compare the value of LP asset and value of hodl initial investment), you will find that the current assets cannot be fully exchanged back to the initial investment, thus the difference is Impermanence Loss; the greater the price deviation, the greater the impermanence loss. If the price returns to the initial price, meaning the current asset and the initial investment are exactly the same, the impermanence loss will no longer exist. Of course, given AMM’s mining revenue (fees, etc.), DeFi’s yield farmers would expect a surplus after mining revenue subtracts impermanent losses.

The coin pair that is generally expected to have less impermanent loss is the USD stable coin pair between the mine pools, such as Uniswap’s USDC-DAI mine pool, due to their theoretical value of $1. Empirically, the ranking of Impermanent Loss is as followed:

Stablecoin — stablecoin < mainstream coin — mainstream coin (with a certain correlation coefficient) < mainstream coin — stablecoin < non-mainstream coin — stablecoin / mainstream coin (even inverse correlated).

For example: Uniswap. Now a large number of players enter Uniswap V3, and can provide liquidity within a certain price range. Due to the concentration of funds, Farming’s income expectations are higher to even 0.5% per day (180% annualized!), making Uniswap V3 the hottest choice for yield farmers.

Leveraged mining (“single-coin” mining)

“Single-coin” is quoted here because the operation of leveraged farming is different from real single-coin borrowing/lending mining. Say the leveraged farming is called protocol A. User will deposit crypto assets into protocol A, where protocol A borrows more assets through another external lending protocol B to make a combination of asset into protocol C’s single or dual coin mining pool to obtain income. This is essentially like the leveraged trading logic of centralized exchange, where the protocol borrows more assets for mining or investing through a pledge of coin A. For example, one can borrow another coin from a market-preferred borrowing protocol B, matching the amount of two coins into AMM Protocol C. He earns the interest subsidy on the lending protocol B and the AMM commission fee of the protocol C, achieving a higher return.

Theoretical yield = (commission fee on protocol C — interest expenditure on protocol B + interest subsidies on B) / initial unleveraged asset.

The advantage of leveraged mining is its convenience, one-stop service, and multiplied revenue. The disadvantage is that users need to assume multiple risks. One is technical risk: once any of the A / B / C contracts got hacked, leveraged mining will be affected and their asset will be lost. Second, leveraged mining has exposure of crypto margin trading due to a high debt ratio in the lending protocol B. Third, if protocol C is AMM liquidity mining, its impermanent loss will be further magnified by the leverage used. Therefore, investors should understand the liquidation rules of various protocols before providing liquidity, avoid losses caused by large price fluctuations, and be able to hedge properly after impermanent losses occur. In short, the management cost of leveraged mining management is relatively high. For large funds, the overall benefit is not as good as it seems.

E.g. Booster, Alpaca

Aggregator / Smart pool (“single-coin” mining)

The most classic example is the Yearn Finance, launched in 2020. As an aggregator for DeFi’s yield farming service, it provides users with access to all kinds of protocols and the best-rate assets available on the market (not necessarily just a protocol, perhaps a set of operational combinations). Even if interest rates on these assets change, the smart contract will automatically update the current top rate. Other aggregator projects include Coinwind aggregator that appeared in other chains.

There is, of course, a higher risk behind high returns, and the primary risk of such projects is the risk that the DeFi project contract itself will be attacked/stolen, including the aggregator protocol itself and the aggregated protocol.

Risk and corresponding strategy of DeFi yield farming

There is a technical protocol risk for all protocols, and you can search the media for keywords such as “DeFi hacked”. Based on past experience, long-running protocols with high TVL are expected to have lower technical risks.

In addition to the technical risk of protocols, the DeFi risk that is mainly discussed include the risk of liquidation and impermanent loss. The following table summarizes the sources of risk for different types of yield farming:

Risk of forced liquidation:

Forced liquidation is usually appearing on borrowing/lending or leverage protocols, with various mechanism of different protocols. For example, Compound defines Collateral Factor as 75%, meaning that if the pledge rate is below 1.33 (LTV is above 75%), Compound puts the collateral on auction and transfers the creditor’s rights. For another kind of lending protocol AAVE, the risk of forced liquidation varies by different coin.

Forced liquidation of DeFi protocol can be very costly, with commission fees up to 10% of the liquidation value. Therefore, users should take the initiative to avoid risks in advance, keep sufficient collateral, monitor the real-time pledge rate in each lending protocol, and add collateral in time to avoid being liquidated.

Impermanent loss:

Impermanent loss is the enemy of DeFi AMM farming, as introduced earlier. Let’s walk through a quantitative analysis and compare the impermanence loss of Uniswap V2 (classic constant formula) with that of Uniswap V3 to determine which one has the highest impermanent loss at present, assuming that the commission fee income is not considered. Uniswap V3 means that by keeping the price range within a small interval, concentrated liquidity produces greater returns along with higher risk of impermanent loss.

Deposit 10 ETH and 20K USDC when the current ETH price is $2000, and calculate the net value of initial assets based on 10 ETH and 20K USDC on a mixed standard when the ETH price drops to $1000 or rises to $3000:

From the above examples, we see that impermanent loss level of liquidity provided by dual-coin AMM mining pool in a certain price range will be multiplied compared with the infinite range. Therefore, it is necessary to use centralized exchanges for hedging at the same time and monitor the overall profit, loss and exposure.

For risk control of impermanent losses, the mainstream way in the market nowadays is to hedge Delta through centralized exchanges (such as Binance) on the crypto OTC spot/derivatives desk. The principle of hedging strategy is to set risk control parameters such as exposure, or thresholds for the rise and fall of coin prices, and run automatic hedging strategy on centralized exchange according to positions in DEX. Hedging strategies are generally divided into three steps:

Step 1: Make assumption of the future trends of the market (in what range will the coin price fluctuates in the next mining cycle, and what will the highest and lowest points be);

Step 2: Set the parameters of automatic hedging strategy based on the back test results of the market assumptions;

Step 3: Develop counter measures when the market trend goes beyond assumptions.

There are quant teams in the market that provide hedging services for impermanent risk. They usually charge fixed annualized interest or a share of the mining net income. For example, charging annually 10–25% of AUM and hedge on spot/perpetual/futures/options hedging).

How institutional investors operate in DeFi yield farming

Institutional investors share the following characteristics:

– There are various sources of fund

Different sources of fund have different preferences on risk appetite or flexibility.

E.g. some investors are long-term investors of 5 years expected investment period, while some adjust their portfolio every 3–6 months.

Some want stable return with lower risk, while some want to maximize expected return while bearing higher risk.

– They may only raise fund in one coin during fundraising phase (such as the first-phase USD denominated fund or the single-coin denominated fund), and they need to balance their positions to handle dual-coin mining

– The asset-side investment is diverse

They invest in different mining sites, such as single-coin/dual-coin, current/fixed-term, large coin/small coin, UDS denominated/Coin denominated, depending on different fund they possess. For all different types of assets, the followings are required:

  • Bookkeeping, to have a comprehensive understanding of the asset side
  • Risk control
  • Settlement, receivables and payables and profit distribution

– The overall risk preference is conservative with a hope not to assume any technical risk. They can bear controllable impermanent loss yet do not want to bear any liquidation loss, so they will

  • Mine in developed pools such as Compound and Sushiswap to minimize the technical risks of contracts
  • Hedge impermanent losses and reduce exposure
  • Excessive pledge and monitoring the crypto real time market data to avoid forced liquidation

For example, the first-phase DeFi yield farming fund team raised 5 million USDT (assuming 1 ETH=2500 USDT at that time), and the goal was to enter the ETH-USDT mining pool in Sushiswap for liquidity mining. Funds were divided into the following parts:

* Because of futures’ price premium, buying spot with USDT futures and hedging on quarterly futures on crypto OTC spot/derivatives desks is the common approach to gain liquidity on coins (BTC, ETH…).

On the other hand, when fund is denominated in coins, and need liquidity on USDT, it is recommended to use crypto collateral lending. For example, if only ETH is raised, you can go to MakerDao or centralized collateral crypto lending platform to exchange DAI, and then use ETH + DAI to mine in Uniswap.

Portfolio and risk management tasks in DeFi yield farming include:

  1. Monitor net value, exposure and leverage ratio
  2. Hedge impermanent loss after exposure reaches a certain threshold
  3. After the leverage ratio reaches a certain threshold, make up or reduce net positions
  4. Calculate realized and unrealized income of DeFi yield farming, and present net value and expected income to investors

Schematic diagram of complex DeFi yield farming fund structure

DeFi yield farming tools

There are already DeFi aggregator tools in the market that provide mining suggestions through public data, or read wallets in blockchain addresses. Several common websites are listed:

– DeFiPulse, APY999, summarizes market interest rate levels and guides asset allocation to gain crypto wealth via registered investment advisors

– Debank, DeFiBox, summarizes the fundamental analysis of the market, and provides DeFi asset reading

– Messari, online database for the crypto industry that provides data insights and research on crypto-assets through an open-source library of information

The above website provides useful information, but it is not enough for institutional investors.

1. Comprehensive bookkeeping and flexible clearing and settlement from fundraising side to asset side

Fundraising side

Share of funds entered by different investors in different periods;

Tranched funds (senior tranche / subordinated fund);

Record and calculate all kinds of cost items;

Real-time analysis of profit and loss and clearing and settlement of share income

Asset side

Only need to bind the DeFi address (public key) to real-time monitor the asset status and impermanent losses on DeFi, and the hedging positions and assets on the centralized exchanges;

Combine DeFi with centralized exchange accounts, and even external trades / assets or collateral / loans, and calculate the profit and loss based on initial investment, and finally calculate revenue share based on complex clearing and settlement terms.

2. Risk control of various assets, both DeFi and CeFi assets

– Futures-spot hedging account leverage ratio & risk of forced liquidation;

– Margin call monitor and alert for single-coin borrowing/lending protocols;

– Impermanent losses and exposure of different coin types in AMM mining due to coin price fluctuations;

– Calculate the exposure after hedging of impermanent losses;

– Unrealized and realized profit and loss, (accumulated) net value, based on crypto real time market data, like coin price and position.

3. Transaction execution/intelligent algorithm hedging tool

– If the risk control threshold is triggered, either an alarm is issued for the manager to manually hedge, or automatically hedge on the spot or futures in the centralized exchange or on the crypto OTC spot/derivatives desks based on the pre-defined hedging conditions/threshold (parameters can be adjusted, automatic/semi-automatic hedging); For example, if the Delta exposure of a coin reaches the threshold, it can be set to hedge all or part of the Delta exposure; it can also be set to delay x minutes (to avoid repeated hedging during fast market conditions);

– 1Token also provides back-testing service based on historical data, and carries out back-testing of different parameters according to the assumed market trends, so as to ensure that customers can get crypto wealth via investment advisors to select the most appropriate parameters.

In a word, 1Token’s crypto customer-facing interface covers the front, middle, back office from the fundraising side to the asset side, and fully serves financial institutions with DeFi yield farming as the asset side, so that investors can monitor the crypto real time data of investment share and unrealized profit and loss. Managers can clearly understand the status and risks of all asset portfolio through crypto portfolio management infrastructure, and control the impermanent losses and liquidation losses.

1Token provides one-stop system solutions for various crypto-finance institutions

1Token CAM system provides front, middle and back stages software system support for middle/large financial institutions in the global crypto industry.

At present, the leading financial institutions in China, such as FOF/MOM fund of Bixin, FOF/MOM fund of Matrixport, asset management of FBGOne, quantitative trading fund of BitLink, multi-strategy fund, FOF/MOM, and prime brokers of the United States and Europe, all are customers of 1Token CAM system.

The CAM system has 3 coverings:

Covering all kinds of institutions, including crypto buyers, sellers and custodian banks. Specific business such as wealth management / asset management, DeFi yield farming, FoF / MoM, PB, structured product sellers, lending platforms, mining pools, institutional miners, manual / quantitative funds, and OTC liquidity providers;

Covering all major modules, including trading, clearing and settlement, portfolio, risk control, quote, transfer/wallet, accounting and reporting, etc.;

Covering all kinds of assets in the crypto industry, including funds, (structured) derivatives, lending / allocation, DeFi yield farming, computing power/mining machines, etc., as well as traditional securities and derivatives assets.

Width

1Token teams has lending, financing, derivatives system experience in traditional market and quant fund, brokerage and mining system in cryptocurrency market

1Token core team previously worked at Scivantage (acquired by refinitiv), a well-known financial system provider in US traditional finance market, serving Bank of America, Deutsche Bank, Vanguard, Scottrade and other well-known sell-side institutions

1Token system has covered front- to -back office modules of various assets through 10 years of experience, also customization is possible based on client demand

Depth

1Token system has proven robustness by serving daily $300 million trading volume via broker system and prop trading system, with peak volume $800 million

1Token system supports local deployment, uses separate open-source module to keep confidential information (e.g. API key) and make regular 3rd party penetration test by leading digital security firms to address large-mid institutional clients’ concern on data security

Reference resources

https://defipulse.com/

https://debank.com/

https://decentyields.com/impermanent-loss-calculator

https://docs.aave.com/faq/liquidations

https://compound.finance/markets/USDC

https://app.uniswap.org/#/pool

https://v1.yearn.finance/earn

https://1token.trade/