Hedging AMM LP Positions

Jack Gillett
3TwelveCapital
Published in
8 min readJun 22, 2022

Introduction

  • Staking liquidity to DEXes offers very attractive headline earnings rates¹
  • However the earnings need to be balanced against impermanent loss and hedging costs
  • In this article we examine the quantitative trade-offs when staking to an AMM DEX
  • We’ve been running liquidity mining on a number of DEXes as a yield strategy for a while and find it a great strategy as part of a diversified portfolio

Throughout this article I’ll use ETH-USDC as an example pair and UniSwap as an example DEX. For simplicity I’m ignoring trading and borrow costs. This is the first part of a multi-part blog, we’ll explore some more advanced topics like concentrated liquidity and gamma hedging with volatility products in later posts.

AMM DEXes

The simplest type of decentralized exchange is the constant product DEX. This will keep track of two pools of tokens, for example x of token ETH vs y of token USDC. The fundamental governing equation for the liquidity pools is

Eq. 1

Any participant can trade against the DEX smart contract, providing some ETH tokens and removing some USDC tokens or vice versa, where the amounts of each token will be determined such that the resulting quantities in the liquidity pool still satisfy Eq. 1. For small trades, this implies trading at a price of roughly p = y/x ; for large trades this will cause slippage away from this price. DEXes will usually charge a fee to traders for this type of transaction and add those fees to the pool as well. This type of transaction will change the proportion of tokens in the pool, but it will not change the constant factor k.

Any participant can deposit ETH and USDC into the pool in the current ratio of x : y in exchange for LP tokens, which grant ownership over a share of the pool and the subsequent fees it receives. This will increase the value of k but will not change the ratio of tokens (ie. the implied price).

Delta Hedging

The current price p(0) of ETH is $3,000, and we have $6,000 capital that we wish to invest in an ETH-USDC LP token. We first exchange half of this into ETH, and then provide both of these coins in exchange for the LP tokens.

As the ETH price moves around and the size of the pools vary, the quantity of ETH and USDC that our LP tokens represent will vary as well, and we will pick up Impermanent Loss (IL) from the variation in size of the coin pools. Unhedged, this can grow very large if the price moves significantly, and we’re highly exposed to the price of ETH coming from the ETH backing our LP token. We might also hedge the initial ETH position using a short ETH perpetual. A comparison of the portfolio PnL in both of these scenarios is shown in Fig. 1. Since the unhedged strategy looks like more of a play on ETH than on the liquidity provision, for the rest of this post we’ll be considering hedged versions of the strategy.

Figure 1: PnL as a function of Spot Price for an unhedged/macro-hedged LP Portfolio

Philosophically, there are two ways to think about the delta hedging:

  1. After our initial trade of half of our dollars into ETH, we put on a ‘macro hedge’ short the 1 ETH that we bought, perhaps using perpetuals on a centralized exchange. Our initial portfolio is now delta neutral at inception. Then at a set frequency we calculate the new delta of our IL, and adjust a separate IL dynamic delta hedge (initially 0)
  2. At the same set frequency, we examine the pool and observe how much ETH we have in our LP position. We hold a negative hedge of the same number of ETH perps

Of course, these two both give exactly the same results, the sum of the macro hedge and the frequent IL re-hedges is the same as the overall hedge calculated in the second framework.

Let’s consider the initial position in the first framework, where we have $6,000 of LP tokens currently representing 1 ETH and 3,000 USDC, and also 1 short ETH ‘macro hedge’ perpetual position on our favorite derivatives exchange².

If we don’t re-hedge, the value C(t) of our LP tokens plus macro hedge portfolio is just our initial capital minus IL, where IL coming from an LP position initially worth C(0) is given by³:

Eq. 2-4

where z(t) represents the ratio of the current price to our initial entry price, p(t)/p(0). The portfolio value of an LP position hedged with an ETH short initially worth $6,000 at ETH price of $3,000 is shown the blue line in Fig. 1 (there is a well-known expression for the ‘IL Ratio’, once adjusted to reflect the IL of an entire portfolio and adding the macro hedge we obtain the expression above).

Differentiating this we get the delta of the portfolio required for our IL delta hedges

Eq. 5

This expression is exactly equal to our current LP’s current effective ETH holding minus the amount of ETH already hedged by our perpetual ‘macro hedge’. And at every rehedging time, we adjust our dynamic hedge to equal this. Some example price paths are shown in Fig. 2 along with the corresponding portfolio IL with and without the dynamic hedge applied (but in all cases with the macro hedge applied). The PnL from the dynamically hedged portfolios is close to identical in all cases, despite the drastic differences in the ETH price paths and the PnL of the corresponding
portfolios with only the macro hedge.

Figure 2: PnL as a function of Spot Price for a macro-hedged LP Portfolio. Note that different
paths lead to very different PnL profiles for the macro-hedged-only portfolios, but the dynamically
delta hedged portfolios display almost identical performance in all cases

How frequently we should re-hedge is a good question. In a Black-Scholes style world with constant volatility parameter and zero costs, we can re-hedge very frequently and reduce the volatility of our PnL (although it will still be negative). In the real world, we have hedging costs, block times, and short-term vs. long-term volatility to think about.

We see from the delta hedging strategies discussed before that we expect to generate a approximately deterministic loss from the dynamic hedge, which is very standard for negative convexity portfolios. Again we make the crude Black-Scholes approximations, which risks dropping vol-of-vol cross terms etc. but gives us an intuitive idea of what is going on.

Gamma Bleed

For the portfolio we’ve been considering so far, we can differentiate one more time to get the portfolio gamma

Eq. 6

The delta and gamma for the portfolio considered before are shown in Fig. 3.

Figure 3: Portfolio delta and gamma for a macro-hedged LP Portfolio

For a portfolio with gamma γ, the PnL for a dynamically delta-hedged portfolio coming from the hedging strategy is given approximately by

Eq. 7

which is negative for a negative γ portfolio, proportional to the time interval, and increases as σ^2 as vol σ increases.

Combining these two expressions we can calculate our approximate initial rate of ‘gamma bleed’ (ie. the slope of the orange lines in Fig. 2)

Eq. 8

and putting in a rough σ of 80%⁴ we estimate a gamma bleed of 8% of our capital over a year. This compares very favorably to many of the advertised yields on AMMs available as mentioned before.

If we believe the expression for gamma PnL given in Eq. 7, the yield for the LP staking is giving us the market’s estimate of the price volatility that will be realized in the near future. If the market yield is currently K% per year, the market is implying a vol of

Eq. 9

and any time that we expect a realized vol of lower than this over a forward-looking period, an LP staking strategy with dynamic delta hedging could work very well for us. Just to plug some numbers in for context, readily available yields on LP tokens from the market imply very high vols. A 30% yield implies that it’s worth staking coins unless the vol is likely to realize over 150%…

Closing Thoughts

All of this will sound very familiar to anybody who has managed an options book in traditional finance — our LP tokens are a short gamma instrument and in some ways look very similar to options. One interesting thing here though is that our idealized LP tokens are free to enter and exit at any time and pay a continuous yield. We are exposed to gamma losses coming from realized vol increasing, but we have *NO* sensitivity to implied vol (ie. vega) because in our simplified model and assuming an efficient market, any changes in expected future realized vol will be reflected almost instantly in a change of the yield our LP tokens accrue.

We haven’t talked about governance token rewards, but of course we need our net fees received to match our negative gamma costs, or the cost of hedging out this gamma, for it to be worth staking coins. If we receive airdrops of governance tokens too, this lowers the hurdle rate for the strategy discussed above.

We’ve got some more coming shortly on other ways to think about hedging LP tokens, and on some of the more interesting DEX innovations such as UniSwap V3-style concentrated liquidity.

About 3Twelve Capital

A private crypto VC fund specializing in incubating early stage web3 projects. Led by earliest employees at FTX, we have a collective experience in a series of investments and advisory covering DeFi, Infrastructure and GameFi projects including Solana, Magic Eden, Raydium, Star Atlas and more. Our team is dedicated to fostering the next generation of web3 entrepreneurs that we believe is the true driving force behind what defines the future of an open economy. We work alongside our portfolio to provide broad and pragmatic insights that strive for long term success every step of the way.

Jack Gillett —Quantitative Researcher at 3Twelve Capital

Quant with a background in systematic derivatives pricing and trading in crypto and tradfi. Very excited about the waves of innovation coming out of Crypto and DeFi. Foodie, trail runner and IPA fan.

[1] 25% apy for SOL-USDC on raydium.io at time of writing…

[2] Mango Markets

[3] There is a well-known expression for the `IL Ratio’, once adjusted to reflect the IL of an entire portfolio and adding the macro hedge we obtain the expression above

[4] Eyeballed from Deribit for ETH

--

--