⚠️ Γ Alert ⚠️

What does part of Paul Milgrom's 2020 Nobel Memorial Prize have to do with 🦍-ing into pool 2?

2nd part of our series on CFMM shape looks at:

💹 How do you compare LP return from different pools?
🤼 Quantifying adverse selection in CFMMs

medium.com/gauntlet-netwo…
Post 1 tl;dr: Curvature controls pool price stability

Post 2: Curvature *directly* controls:
- LP profits when asset pairs are mean reverting
- ∃ a magic formula relating LP profit to adverse selection (probability α of LP realizing IL), curvature, and fees for *any* CFMM!
These results generalize Glosten & Milgrom (1984), Kyle (1985) to arbitrary CFMMs

This seminal work shows the shape of the order book represents the amount of adverse selection a market maker feels, leading to strategies where they remove liquidity to avoid adverse selection
Inspired by Jun Aoyogi's work on Uniswap adverse selection, we generalized his results to @CurveFinance & more

Similar to Jun, we construct a game between LPs 🐳, informed traders 🦍, & arbs 🧙 to find an equilibrium condition

But our game is different in a couple key ways 🔮
1. We model roundtrip trades: This is when an 🦍 makes a trade but ends up being wrong, this leads to 🐳, 🧙 profits

2. Our game more carefully connects impermanent loss to the shape of the CFMM as we explicitly consider the effects of changes in marginal price on LP share value
This shows that protective CFMMs like @BreederDodo and any CFMM @hosseeb says needs an oracle simply by reducing LP adverse selection by adjusting curvature

But this also intimates you can do this endogenously *without* an oracle if you are willing to store more on-chain state
So what does this mean for the future of CFMM design?
1. Curvature is dual to adverse selection (e.g. stablecoin-stablecoin trades aren't v. adverse, so you don't need much curvature)
2. Dynamic updates to a CFMM, either by an oracle or endogenously, need to account for shape
Designing dynamic update rules will inevitably be tied to designing the correct gradient flow that adjusts a CFMM's curvature

Given the centuries of work in differential geometry on such flows, it is inevitable that we will see them (and control theory) interacting with CFMMs
What's next? 🔮

The final post (and the release of the paper) will show how curvature and yield farming incentives (especially pool 2!) interact

We'll illustrate the optimization problem for *optimally* choosing farming rewards for pool 2
Thanks go out to:

Collaborators (@GuilleAngeris, @alexhevans)
Feedback: @_prestwich and @ciamac
Protocols that inspired this: @NotionalFinance @yield @BreederDodo @MonteCarloDEX @ShellProtocol

✌️🏿✌️🏿✌️🏿
P.S. If you're designing options AMMs (@0mllwntrmt3, @anisimov_andrei, @AndreCronjeTech, @opyn_) all of this advice about curvature applies doubly so — next week's post will go more into curvature + Greeks
*simply works

• • •

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

Keep Current with Tarun Chitra

Tarun Chitra 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 @tarunchitra

24 Nov
What does Gauss's Theorema Egregium (1827) have to do with getting rug pulled in Uniswap?

This post (1 out of 3) introduces (only w/ pictures!) new work on understanding constant function MMs (CFMMs) as the primary market for an asset

Part I: Curvature

link.medium.com/RVPG7R85Fbb
Why curvature?

@CurveFinance made it clear that some assets perform better on 'flatter' CFMMs and others on 'sharper' CFMMs

But what does it mean to be 'better'?

Our paper studies what happens when traders arbitrage btw. two CFMMs and look at the max their prices differ by
When we dug into this a little more, it became clear that Gaussian curvature controls a lot of facets of CFMMs:

1. Price synchronization between two CFMMs
2. Adverse Selection for LP returns
3. Price stability
4. Optimal incentives for yield farming
Read 7 tweets
2 Nov
As much as I love the Penrose tiling and long-range order (I used to do glass research!), this seems like a terrible idea

1. Diverge correlation times/lengths means time to verify of a single transaction’s validity could take way longer than block propagation

😬😬😬
2. If you want to anonymize a transaction graph by using a lattice with dense spectra (like the Penrose tiling) to define a DAG, note that you aren’t guaranteed that there isn’t *any* local structure that an adversary can find — only that no tx ordering will be unique
2. (cont.) It is possible that prefixes of tx ordering overlap an arbitrary amount, so there isn’t as much transaction ordering entropy as there is from cryptographic graph traversals (e.g. expander graph walks in supersingular isogeny signatures, lattice based crypto)
Read 5 tweets
2 Nov
Alpha leak: Adverse selection in Uniswap

This beautifully simple paper proves what @theyisun and I called the “noise trader conjecture”:

Strategic LP strategies only profitable if fees are high enough, ∃ many noise traders, and low signal information

papers.ssrn.com/sol3/papers.cf…
This effectively looks at a mean-field, agent-based model of:
1. Noise traders
2. Informed traders
3. Strategic LPs

It shows that as the # of LPs goes to ♾, ∃ a sharp phase transition in LP profits as a function of the number of informed traders (defined via simple signals)
There’s also a kind of curious stability result that is vaguely reminiscent of “rugpull” dynamics: there’s only a stable equilibrium when there are < 4 LPs, if there’s more you have sharp edge equilibria that you can oscillate between (akin to the “last LP holds the bag”)
Read 4 tweets
11 Sep
The VC vs. trader “war” of crypto is reminiscent of the previous talent “war” between HFT and online ads: All of these boil down to latency vs. bandwidth trade-offs where "event-driven" investing depends on the condition number of a participants' value function
Trader: need max and min eigenval. of value fn. to be "close" (low condition number) because of regret minimization between your worst and best case outcomes

If your value function is smooth, this gives uniform bounds on the max/min eigenval. of hessian of your val. function
VC: need max eigenval. of value function to optimized

Things like the Tracy-Widom law force you to chase fat tails, terrible Sharpe, and anomalous portfolio construction
Read 8 tweets
30 Aug
The number of traditional finance chads (e.g. @arbitragegoth) asking me questions about DeFi LP staking is 📈📈 📈

Here's what it is:
1. @synthetix_io / @kaiynne pioneered paying users for liquidity by staking CFMM LP shares
2. CFMM LP shares replicate options portfolios

👇🏾
∴ LP staking is equivalent to collateralizing a leg of an interest rate swap with future expected cash flows from an options portfolio

This is actually *really* hard to execute in normal finance — especially because the CFMM replication is a continuous combination of strikes
Traditional finance has focused on swaps as
a. In-kind (e.g. interest for interest)
b. Purely Synthetic (e.g. variance swaps, VIX)

DeFi let's you combine the two — in-kind on one side in exchange for synthetic on the other

Impossible to do this without non-custodial assets!
Read 4 tweets
22 Jun
Big Short 2.0: PoS and DeFi are mortgage-backed securities!

@alexhevans & I tried to find grand unified theory for the financial derivatives hidden in PoS and DeFi ➡️ uncovered mathematical equiv. to MBSs.

Why? Same payoffs and income inequality!
👇🏾
medium.com/gauntlet-netwo…
tl;dr:
- Synthetic levered assets in PoS and DeFi are MBSs.
- Improvements over meatspace/2008 MBS:
- Used to reduce inequality
- Avoid lending competition in PoS
- Numerical, probabilistic methods are key to correct design of these systems
The post motivates and provides background for our paper which just hit arXiv

The following are equivalent as portfolios

❇️ PoS w/ derivatives
❇️ Leveraged DeFi
❇️ Mortgage-Backed Securities

arxiv.org/abs/2006.11156
Read 23 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!