1) Can you fix AMMs?
2) NOT INVESTMENT ADVICE. NOT MARKET MAKING ADVICE.
3) The premise here is a little odd:

Providing in AMMs has made people millions this summer.

How are they broken?
4) Well, let's see how we got here.

First, why do AMMs exist in the first place?

Because most blockchains don't have the throughput to support orderbooks, so they _have_ to use AMMs instead.

OK, well how are they doing?

Until this summer, very little usage.
5) Now, though, there's way more.

But it's not all "natural".

Most volume--and TVL--in DeFi comes from yield farms, one way or another: projects dropping their tokens on their users.

Whatever you think of it, it means that the reported usage numbers are heavily incentivized.
6) People are using AMMs because they're being actively paid to.

But that doesn't have to be unique to AMMs: you could also drop yield on an orderbook, or stakers, or pretty much anything else.

And once that yield goes away, how much volume and TVL will remain?

It's unclear.
7) Anyway--most people see the big problem with AMMs being "impermanent loss".

What's IL? It's the fact that, if you provide liquidity in an AMM and prices move, you lose value.

It's "Impermanent" in that, if you keep providing and prices revert, you get your value back.
8) Lots of projects are trying to fix IL.

Some change the curve.

Some have insurance, or options, or hedging.

Many have yield.

Do these help? Maybe, but probably not much.

Do they fix IL? Nope.
9) Why is that?

Because IL isn't some misparamaterization.

IL is just a PC euphemism for "doing bad trades".

Here's where IL really comes from.

------

Say that you put 1 ETH and 400 USDC in an AMM, and currently ETH is worth $400. Say it's 30bps taker, 30bps maker rebate.
10) You're announcing to the world:

"Hey! Anyone want to buy at $401.20 or sell at $398.8? If so, go for it!"

So what happens?

Well, you sit there, and wait. And wait some more.

And then ETH moves down 60bps, so selling at $398.8 is good.

So someone sells to you.
11) You're a sitting duck: making an unmoving two-sided market 60bps wide, expensive and slow to cancel, and waiting for market to move more than 30bps.

At which point your market is now bad, and someone trades against it.

That's "impermanent" loss.
12) In a normal orderbook, the bids are people who actively want to buy at that price.

In an AMM, the bids are... everyone in the pool, at the market price, no matter what that price is. Not people expressing an opinion about the price. Just sitting ducks.
13) Hedging, options, etc. don't help.

The problem isn't "risk" per se. It's that you're doing bad trades; trades with negative expected value.

Paying fees to hedge can't fix bad trades, it can just even the outcomes: locking in a small loss.

The curve doesn't change this.
14) The only saving grace here is that the takers pay you 30bps on all trades.

So rather than _constantly_ getting picked off, it only happens when markets move more than 30bps.

30bp fees are way higher than most exchanges! But they _have_ to be, or else IL would skyrocket.
15) This means that any "benign" taker -- someone who just needs to put on a position at a reasonable price -- has to pay that same 30bps. It's really inefficient.

What if an algo set the price?

Well either:
16)

a) that algo is a CEX oracle --> just trade on the CEX
b) that algo is on-chain tradeable --> that algo is the DEX, recurse on it
c) that algo is something else, and likely garbage.

So how can AMMs even exist then? It basically has to be one of the following.
17)

a) The liquidity providers are making a mistake, and bleeding to IL but don't realize it.

b) Volatility is so low that IL is close to 0, so fees can be small too. E.g. Curve.

c) There's _so_ much random taker flow that it's > IL. But still AMM/IL is worse than orderbooks
18) or, finally:

d) someone is paying you to use the AMM, e.g. yield.

So in summary, either the LPs are losing; the retail takers are losing; or someone is paying the system to compensate for those.

And when that yield goes away, you're back where you started.
19) What if you just really need easy liquidity?

Yeah, that's totally legit.

That's the clearest use case for AMMs:

You have a token, you want liquidity for it. You don't want to bother with an MM. So you just put some tokens in an AMM and don't worry about it.
20) You lose some money on it, but sure, that's fine, it's the price of liquidity.

What if you program an AMM to do "smart" pricing/trades/etc.?

If it's really custom -- it's not really an AMM, it's an on-chain algo trading firm.

Which is awesome!
21) Note that reducing gas costs and blockchain latency does help some: it at least makes it cheap to add/remove liquidity, so you can stop providing when you want if markets start moving.

But overall:

The problems with AMMs run deep.
22) AMMs force you to always make two-sided markets at mid.

That strategy does not generally do so well.

And throwing math at it, or synthetic hedges, or whatever, doesn't really help.

So much yield has gone to them that we forget they weren't popular before.
23) But in the end, except in a few cases that play to their strengths (stablecoin<>stablecoin, new project that needs easy liquidity, etc.)--

--you can't really fix AMMs, you can just make them a bit less bad.

The past is orderbooks. So, I think, is the future.
You can follow @SBF_Alameda.
Tip: mention @twtextapp on a Twitter thread with the keyword “unroll” to get a link to it.

Latest Threads Unrolled: