Profiting with the Tulip Protocol: Part 1 — Leveraging Long
Original: https://thesolanagrapevine.substack.com/p/profiting-with-tulip-protocol-part?justPublished=true by The Solana Grapevine
Translation: Copycat ฅ^•ﻌ•^ฅ ( Twitter ) | copycat.sol
We thank Alpaca Finance's Docs for providing most of the explanatory material in this article.
Leveraged yield farming (abbreviated: LYF) provides a unique way to profit and capture interest rates, making the LYF protocol an essential DeFi Lego building block in any ecosystem. Take the leading LYF protocols on Ethereum (Alpha Finance) and BSC (Alpaca Finance), each with over $1 billion in TVL. In a short period of time, the Tulip protocol — the leading LYF protocol on Solana — also recently reached over $1 billion in TVL.
LYF is especially profitable when liquidity mining rates for token pairs are very high. The Solana ecosystem is particularly ripe for a profitable LYF strategy, as there are many token pairs with high APY currently (and likely in the future).
In this series about the Tulip protocol, we will try our best to give a more efficient explanation of the different strategies for profiting with LYF on the Tulip protocol.
What is leveraged liquidity mining?
In LYF, users deposit a token as collateral, borrow tokens with up to 3x leverage (eg: deposit $1,000 worth of tokens and borrow $2,000 worth of tokens), and then trade in a DEX (eg: Raydium or Orca) get transaction fee rewards and mining rewards, which are automatically compounded — done with one click.
If you haven’t mined on DEX before, maybe don’t jump straight into leveraged liquidity mining. First, provide liquidity on Raydium or Orca and put your LP tokens into their pools. Going through this process will help you understand what mining is and what LYF is.
Below is an example:
1. Bob invested in the ORCA-USDC pool on the Tulip protocol
Liquidity Mining APR — Orca Aquafarms’ liquidity mining reward (relative to the value of deposited tokens)
Transaction Fee APR — Transaction fee reward from Orca trading activity (relative to the value of the deposited tokens)
Borrow Interest APR — Interest on borrowed USDC (relative to the value of the deposited tokens)
2. Bob deposits $3000 worth of ORCA and borrows $6000 worth of USDC (3x leverage)
After clicking "Farm", the protocol will automatically exchange $1500 worth of USDC for $1500 worth of ORCA (using Orca DEX) to open a 50:50 token pair ($4500 USDC + $4500 ORCA). This liquidity will then be redirected to Orca, LP tokens will be placed on Aquafarms, and all rewards will be automatically compounded.
Because the $1,500 worth of borrowed USDC was exchanged for ORCA, Bob's position is now $4,500 worth of ORCA. Compared to his original holding of $3,000 worth of ORCA, he now holds 1.5x leverage in tokens. So if you are bullish on the coin, this is a good strategy.
In terms of liquidity mining rate, Bob received 3 times the liquidity mining reward. That is, he earned 1x the liquidity mining reward with $9,000. But since his assets are only $3000, he actually gets 3x the reward, which is 1000% APY of $3000. LYF is especially profitable for high APY token pairs when used properly. So read on to learn more about LYF and the associated risks.
3. Bob can check the current position in "Your Positions"
If you mouse over "i", the definition of each title is shown:
Position value — the value of your LP tokens in the DEX
Debt value - the value of your debt
Asset Value — the estimated asset value you will receive if you close the position
Kill Buffer - liquidation threshold (85%) - debt ratio (debt value/position value). If the Kill Buffer reaches 0%, the position is liquidated.
Congratulations! You just learned how to open your first LYF position. Generally speaking, the best strategy is to hold positions for a long time to earn high yields.
It is very important to understand the initial risk of your assets
When doing LYF, it is important that you understand the risk of the coins you are mining — that is, the coins and amounts you are bullish and bearish, so that you understand your market risk. Luckily, calculating your initial market risk is pretty easy: you're long tokens in the LP and short your borrowed tokens*. Your net exposure is the net value of the two.
*You are bullish on the tokens in the LP because you hold them during mining. You are bearish on borrowed tokens because you sell them to create LP tokens. This may not technically be an accurate way to use the word "bearish", so please understand when we use this word to explain in the calculations below.
The tokens you deposit will not affect your initial token exposure position. If Bob deposited $3000 worth of USDC instead of $3000 worth of ORCA (borrowed $6000 worth of USDC in both cases), his LP would have the same composition and his borrowed tokens would be remains the same; therefore, his net exposure will be the same — $4,500 worth of ORCA. However, the tokens he deposits do matter in terms of saving on Swap costs. If Bob deposits $3000 worth of USDC (and borrows $6000 worth of USDC), then the $4500 USDC will be exchanged for $4500 worth of ORCA. So depositing $3000 worth of ORCA (assuming Bob already has it somewhere) will minimize his Swap fees.
Strategy
Alright, enough introductions. Let's walk through a demonstration to understand how to use $10,000 to profit on the Tulip protocol. LYF strategies can be divided into four types: leveraged long, short, hedged pseudo-delta neutral and unleveraged mining.
Strategy #1: Go long with leverage
If you are bullish on a token (eg: ORCA), you can use the Tulip (Tulip) protocol to create a leveraged long position on the token (ORCA) and earn multiple liquidity mining rates in two ways:
1) Open an ORCA-Stablecoin (USDC) liquidity mining position and borrow the stablecoin with >2x leverage
Bob opens an ORCA-USDC mining position, deposits $10,000 worth of tokens (preferably using ORCA to minimize swap fees), and borrows $20,000 worth of USDC (3x leverage). After clicking "Farm", $5,000 USDC will be exchanged for $5,000 ORCA, resulting in a 50:50 mining ratio ($15,000 ORCA + $15,000 USDC). Bob's market exposure will be:
- Long $15,000 in ORCA (LP token)
- Long USDC (LP token) by $15,000
- Short $20,000 USDC (borrowed token)
His initial net exposure will be long $15,000 in ORCA (long/short stablecoins are neutral as they typically stay at 1). Compared to his original holding of $10,000 in ORCA, he now holds 1.5x leverage in tokens. In addition, he will get 3x liquidity mining rate + 1000% APY transaction fee!
The advantages of using the Tulip protocol compared to going long on CEX are that 1) Bob may pay less interest than CEX and 2) he invests his funds in mining for a decent yield, rather than putting They are locked in CEX.
2) Open a liquidity mining position of ORCA-crypto assets (eg: SOL), and use >2x leverage to borrow crypto assets
Bob opens an ORCA-SOL mining position, deposits $10,000 worth of tokens (preferably ORCA to minimize swap fees), and borrows $20,000 worth of SOL (3x leverage). After clicking "Farm", $5,000 in SOL will be exchanged for $5,000 in ORCA, resulting in a 50:50 mining ratio ($15,000 in ORCA + $15,000 in SOL). Bob's market exposure will be:
- Long $15,000 in ORCA (LP token)
- Long $15,000 in SOL (LP token)
- Short $20,000 of SOL (borrowed tokens)
His initial net exposure will be a long $15,000 ORCA and a short $5,000 SOL. Compared to his original holding of $10,000 in ORCA, he now holds 1.5x leverage in tokens. However, he will also be short SOL at $5,000. In order to make more profit than the first example (opening an ORCA-USDC liquidity mining position), Bob needs to bet 1) the value of SOL will decrease, or 2) the liquidity mining rate of ORCA-SOL is higher than that of ORCA- USDC so that it can make up for the loss of SOL rising.
During this period, Bob will get 3x the mining yield of the asset + transaction fee or 1000% APY!
Remember that you can adjust the leverage level. If Bob used 2.5x leverage in the above two examples, he would be long on ORCA with 1.25x leverage. If he uses 2.2x leverage, he will be 1.1x leveraged long on ORCA.
In summary, if you want to go long tokens (eg: ORCA), you can open an ORCA-stablecoin mining or an ORCA-crypto-assets (SOL) mining to borrow the tokens opposite ORCA with >2x leverage. If the encrypted asset (SOL) goes up, the first kind of mining will be more profitable; if the encrypted asset (SOL) goes down, the second kind of mining will be more profitable. If you think crypto assets will remain stable (like stablecoins), then just choose a pool with a higher APY.
Simulate assets over time
LPs will rebalance when the price of non-borrowed tokens (ORCA) or borrowed tokens (USDC or SOL) changes. If the price of ORCA rises relative to USDC or SOL, the LP will contain less ORCA and more USDC or SOL. If the price of ORCA falls relative to USDC or SOL, the LP will contain more ORCA and less USDC and SOL.
It's easy to calculate your new market exposure when prices change. Just apply the same formula: long tokens in LP + short borrowed tokens. On the Tulip protocol, this information can be seen in the "Your Position" option.
In the above positions, the user is long 606 ORCA, long 11,147 USDC, and short 809 ORCA. Therefore, the user's current market exposure position is to short 203 ORCAs.
The graph below simulates how your asset value (100% = $10,000) will change when non-borrowed and borrowed tokens move.
Gray dotted line - Bob's assets if he just held $10,000 worth of ORCA in his wallet. His assets will fall/rise linearly with the price of ORCA (non-borrowed tokens).
Black dashed line - if Bob is long $15,000 in ORCA (1.5x leverage) on CEX.
Black line - Bob's mining pool for ORCA-USDC with 3x leverage (borrowing USDC) without considering the liquidity mining rate. At time = 0, he has 1.5x ORCA long leverage. Due to impermanent losses, his net worth will always be below the black dotted line.
Purple line — Bob mines ORCA-USDC mining pool with 3x leverage (borrowing USDC), including liquidity mining rates. If the liquidity mining rate is high, he will usually make more profit than simply using CEX's 1.5x leverage (this does not take into account the interest borrowed on CEX). However, this takes time, which is why LYF is a long-term strategy. This line simulates the change in ORCA-SOL with 3x leverage (borrowing SOL) if SOL remains flat (ie behaves like a stablecoin).
Green line - Bob's mining pool for ORCA-SOL with 3x leverage (borrowing SOL), including the liquidity mining rate. Because he is slightly short SOL, if the value of SOL increases by 20%, his equity will be less than the purple line. If the ORCA value increases by about 90% (where the green and purple lines intersect), the LP will rebalance to include more SOL until he no longer holds a short SOL position.
Red line — Bob mines ORCA-SOL’s mining pool with 3x leverage (borrowed SOL), including the liquidity mining rate. Because he is slightly short SOL, if the value of SOL decreases by 20%, his assets will exceed the purple line. If the ORCA value increases by about 60% (where the red and purple lines intersect), the LP will rebalance to include more SOL until he no longer holds a short SOL position.
liquidation risk
The liquidation threshold (maximum loan-to-value ratio; LTV) for all leveraged mining on the Tulip protocol is 85%. Meaning, if your debt ratio (debt value/position value) exceeds 85%, you risk being liquidated. When you mine with 3x leverage, your debt ratio will start at 66.67% ($20,000/$30,000). If you mine with 2.5x leverage, your debt ratio will start at 60% ($15,000/$25,000). The Kill Buffer displayed on the Tulip Dashboard is equal to 85% minus the debt ratio. When the Kill Buffer reaches 0%, you risk being liquidated.
How much can ORCA fall before facing liquidation risk? This calculation can be complicated, so we've provided you with a cheat sheet below. If you mine the ORCA-USDC/SOL pool with 3x leverage (borrow USDC or SOL), then ORCA may drop relative to the borrowed token (ORCA/USDC or ORCA/SOL) before you face liquidation risk 38.5%. This table can be used at any time during your mining period. Be especially careful if the price of a borrowed token (eg: SOL) goes up, as this will speed up the liquidation price ratio.
What if you use <2x leverage?
Well, just use the same simple process as above to calculate your initial net exposure position. If you start an ORCA-SOL mining pool, deposit $10,000 worth of tokens (preferably $7,500 ORCA and $2,500 SOL to minimize swap fees) and borrow SOL with 1.5x leverage ( Borrow $5,000 in SOL), then you will be mining liquidity with $7,500 ORCA + $7,500 SOL. Your market exposure position will be:
- Long $7,500 in ORCA (LP token)
- Long $7,500 in SOL (LP token)
- Short $5,000 in SOL (borrowed tokens)
Your initial net exposure would be $7,500 long ORCA and $2,500 long SOL. Your $10,000 capital is unleveraged because you still have $10,000 in token exposure. However, you will get 1.5x the liquidity mining rate! As a general rule, when mining with <2x leverage, you will be long both coins you hold, only you will be long borrowing fewer coins.
What if you just use 2x leverage?
If you start an ORCA-stablecoin mining pool and borrow ORCA with 2x leverage, you will be minimally affected by any market changes, so we classify it as a pseudo-delta neutral strategy (see article 3, Strategy #3). If you start a mining pool that mines ORCA-stablecoins or ORCA-crypto-assets, and borrows stablecoins or crypto-assets with 2x leverage, we call this a “mining without leverage” strategy (see Part IV, Strategy #4 ).
Summarize
LYF lets you deposit tokens, borrow tokens with up to 3x leverage, and deposit all deposited and borrowed tokens into the DEX while automatically compounding their rewards — all in one click. LYF has four main strategies — leveraged long (Part 1), short (Part 2), hedging pseudo-delta neutral (Part 3), and unlevered mining (Part 4). In all four strategies, your capital will be multiplied by mining earnings instead of locking them up on CEX or DeFi protocols for margin trading. Part 5 will explain how the Tulip protocol continuously generates revenue through its lending pool. Stay tuned for articles in this series and be the first to read articles 2-4.
If you think the article is well translated ^ↀᴥↀ^ If you are willing to invite me for a cup of coffee, you can also send it to copycat.sol
Welcome to the unofficial Solana Chinese telegram group Discuss more about the big and small of the Solana ecosystem
Like my work? Don't forget to support and clap, let me know that you are with me on the road of creation. Keep this enthusiasm together!
- Author
- More