1/

Uniswap v3 provides the only possible "solution" to impermanent loss and price impact

It also lets you reduce total price risk while increasing your impermanent loss (relative to v2) with concentrated liquidity

This might need a blogpost but I'll try a long thread first
2/

"Impermanent loss" (IL) refers to the fact that if you sell a token before it rises in value it would have been better to hold it and sell more at the higher price

Similarly, if you buy a token and it drops in value it would also have been better to hold
3/

The "impermanent" part refers to the fact that if you sell a token and it rises in value you, but buy it back as it falls in value you are back to where you started

IL is only "impermanent" if prices eventually revert to where they started. Then all fees are pure profit
4/

"price impact" is often mistakenly called "slippage"

Price impact refers to how much a trade moves the market price, based on the depth of the market

(slippage is the difference between what you expect to get vs what you actually get due to other trades executing first)
5/

Put simply, a higher price impact means getting a worse rate than the market price due to lack of liquidity at that price

So, to tie it all together - "price impact" and "impermanent loss" exist in direct opposition to each other
6/

The more an LP is willing to sell close to the market price the more imp loss they experience

The less LPs are willing to sell close to the market price, the worse rates (higher price impacts) traders experience

There is an iron-law tradeoff between the two
7/

An LPs only job is to sell tokens close to the market price, this is why they earn fees

The better rates they offer, the more volume they receive, the more fees they earn

It is quite literally impossible for LPs to offer traders better rates without taking on more IL
8/

Concentrated liquidity solves this problem the only way direct tradeoffs can be solved: exposing the tradeoff spectrum to users

LPs can choose for themselves how much liquidity they want to create close to the market price, by increasing the concentration of their liquidity
9/

There is no free lunch. Higher risk / higher return. The more concentrated your liquidity, the higher your fees, the more IL you experience.

"But Hayden you said it is possible to reduce total price risk while increasing impermanent loss"
10/

This holds true and is part of why Uniswap v3 is the best AMM ever designed :)

IL is price risk related to tokens you end up selling.

But there is another type of price risk in AMMs: inventory risk
11/

Inventory risk is price risk you take on by holding less of your wealth in your preferred store of value

If you prefer ETH, the more DAI you hold the greater your inventory risk

If you prefer DAI, the more ETH you hold the greater your inventory risk
12/

Or you could be a DAI/ETH LPs who's preferred store of value is leveraged SOCKS and any unnecessary DAI or ETH held in reserve increases your inventory risk

Inventory risk is often far worse for LPs than impermanent loss
13/

Example: You provide $1000 liquidity to Uniswap v2 ETH/USDC (50% ETH, 50% DAI) when the price of ETH is $1500

This means you put up $500 of DAI to buy ETH as it calls from the current price to 0 and $500 of ETH to sell from the current price to infinity
14/

If ETH doubles in value from $1500 to $3000, your main problem isn't impermanent loss from selling some of your ETH for USDC on the way up.

Your main problem is you were holding 50% of your inventory in USDC reserved for buying ETH below $1000
15/

If the USDC reserved for buying ETH below $1500 was held in your wallet as ETH it would have 2x'd in value and you would not have lost out on any trading fees

The IL from this price move was 5.6%. The downside for not holding more ETH was losing a 2x on 50% of your capital
16/

Of course ETH could have gone down, in which case the opposite position would have been better.

The point is, by allowing you to provide liquidity to custom price ranges, concentrated liquidity provision lets you significantly increase exposure to preferred assets
17/

I hope this helps explain why concentrated liquidity is such a powerful feature.

There is no single right way to provide liquidity - it simple depends on your risk tolerance, your asset preference, and your expectations of future price movements
18/

Exposing these tradeoffs, and allowing LPs to choose for themselves, is the only way to increase the efficiency and usefulness of AMMs

Uniswap v3 does this, making it the most efficient AMM ever designed 🚀
19/

There is a lot to unpack with v3. Will do my best to continue putting out educational content.

Also happy to answer any questions people have.

Thanks for coming to my T̶E̶D̶ ̶t̶a̶l̶k̶ SBF length twitter thread.

• • •

Missing some Tweet in this thread? You can try to force a refresh
 

Keep Current with Hayden Adams 🦄

Hayden Adams 🦄 Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @haydenzadams

23 Mar
1/

A surreal moment, I can't believe it's finally ready.

🧠 Uniswap v3 was born out of @danrobinson's research into ways of improving AMM efficiency which began 18 months ago

Without him, v3 would not exist
2/

It also would not exist without @sendmoodz and @NoahZinsmeister - who have been working on implementing v3 since the launch of v2

3/

Developers like to call difficult tasks "non-trivial"

But to describe what they pulled off as "non-trivial" would be an absurd understatement

Implementing v3 efficiently in solidity is an incredibly difficult task.

Seriously, just look at the code:
github.com/Uniswap/uniswa…
Read 5 tweets
27 Dec 20
UP003 - a proposal to establish a UNI grants program is the first @UniswapProtocol governance proposal to meet quorum and pass!

And it wasn't even close, exceeding the approval threshold by more than 20M votes:

✅ YES - 60,088,813 (99.99%)
❌ NO - 9,300 (0.01%)
Thrilled that this is the first proposal to pass.

A resounding message from the Uniswap community in favor of funding developers and contributors.

Which reminds me - everyone complaining about slow governance is either concern trolling or missing the point.
On-chain governance is not a panacea. It opens up new risks and trust assumptions that do not exist in immutable, automated systems.

This is why Uniswap is highly automated and governance-minimized.

It's no coincidence the biggest project on Ethereum follows this ethos.
Read 4 tweets
2 Dec 20
1/

Mind-blowing results from @_charlienoyes @danrobinson @dave_white_ and @MartinTassy

TLDR: super bullish for AMMs/Uniswap

Will share some of the interesting results and some thoughts below
2/

Result 1:
"If the volatility of an asset is high enough relative to its average rate of return, LPs on Uniswap will do better than HODLers over time, even when the only incoming trades are arbs."

TLDR: LPing can be good without "retail" volume and arb is not bad for LPs
3/

Result 2:
In a zero latency, zero network fee, arbitrage-only (no "retail") world, the profit-optimizing LP fee approaches (but never touches) 0.

This was one of the more shocking results

TLDR: Lower fees = more profitable arb trades = more total fee revenue Image
Read 7 tweets
30 Nov 20
1/

I disagree with a few things here.

First, the number of unique price sources is quite meaningless on its own.

For example, if 95% of a tokens volume and liquidity is one one exchange, averaging in 4 others could lower the quality of the price feed.
2/

Second, you can’t directly compare manipulation resistance of entirely on-chain oracles that pulls from dex with something like chainlink that reports off-chain data

The attack surfaces and trust assumptions are very different
3/

Uniswap TWAPs report 100% accurate average of Uniswap price (at start of block) across arbitrary time periods with perfect reliability and accuracy.

The cost of manipulating is whatever is lost to arbitrage by moving the average market price across this period
Read 7 tweets
1 Sep 20
1/

Can't tell who is pretending and who legitimately doesn't understand that the $1B TVL deposited in an incredibly high risk investment on a single days notice is mostly massive whales

Anyone talking about community vs VC here is either delusional or intentionally misleading.
2/

This is not YFI. Andre built something new and real, that has value.

Sushi is one days effort by any competent dev at most.

It's just whales playing whale games trying to cash in on a hype cycle and the value created by Uniswap.

3/

Not surprised to see @iamDCinvestor talking about this, he's one of seemingly few people on crypto twitter who seems to understand the games whales play when the stakes are raised (and tries to explain them).

Read 4 tweets
17 May 19
1/

@Iiterature Sure!

@UniswapExchange has different functions for ETH-ERC20 and ERC20-ERC20 trades.

This gives the UX improvement of using ETH directly and not having to wrap it first.
2/

Some projects use WETH to pull ETH from your address via approve/transferFrom - something not yet supported with ETH.

(recent vitalik thread on the topic: ethereum-magicians.org/t/brainstormin…)

But most do it b/c they don't want to write separate functions to handle ETH.
3/

Uniswap creates exchanges between ETH and ERC20s. Since WETH is an ERC20, this allows for an ETH<>WETH pair.

Profit in Uniswap come from fees on trading volume.

Loss come from the difference in relative value of the assets from when liquidity is added to when it is removed.
Read 9 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Too expensive? Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal Become our Patreon

Thank you for your support!

Follow Us on Twitter!