Doug Colkitt Profile picture
Founder @ambient_finance Ex: Quant
Matthew Mansfield👹 Profile picture Michael Schatzow Profile picture gilow Profile picture Jerome Ku Profile picture Borg77777 Profile picture 10 subscribed
Nov 23, 2023 30 tweets 10 min read
1/ Finished a preliminary deep dive into the Kyber exploit, and think I now have a pretty good understanding of what happened.

This is easily the most complex and carefully engineered smart contract exploit I've ever seen... 2/ First thing to note is this exploit is specific to Kyber's implementation of concentrated liquidity

There's no reason to believe that other reputable concentrated liquidity dexes, like Ambient or Uniswap, are at risk from this exploit. (Though Kyber forks obviously are)
Apr 6, 2023 11 tweets 3 min read
1/ How to lie with statistics advanced edition...

This meta-study claims to overturn the long established pattern that moderate drinkers have lower mortality than abstainers. After adjusting for confounders there was "no significant reduction in mortality". Very misleading... ImageImage 2/ At the bottom of the chart, you see moderate drinkers have a 0.86 RR (i.e. 13% lower mortality). The 95% confidence interval is 0.83-0.88. This is extremely significant

This study then throws in a kitchen sink of confounder variables. Everything from BMI to publication year
Mar 7, 2023 16 tweets 4 min read
1/ A thing I keep hearing more and more is that RFQs are always better for swappers. This is wrong

We can all agree that the RFQ provider has a free option. The value of that option comes at the expense of someone. Most people think it comes entirely from the passive LPs. Not so 2/ The simple mechanics behind pre-chain RFQs is that the RFQ provider is given "first look" at the swap intention. The RFQ provider is given the option to fill at a better price than the indicative on-chain AMM price. If the RFQ provider passes the swap is routed to the AMM.
Jan 20, 2023 10 tweets 2 min read
1/ “Yes, it probably does need a token…”

Recently it’s become fashionable in crypto circles to be critical of that app-layer governance tokens. Builders are encouraged to build public good and carefully think twice whether adding a token is really necessary

This is psyops… 2/ At best the notion is misguided. At worse, it’s proffered by L1 bag holders, cynically trying to retain all value accrual at the chain layer, leaving the app layer out in the cold

Regardless it’s near impossible to build sustainably decentralized apps without a token
Nov 17, 2022 27 tweets 7 min read
1/ There's a lot of debate and speculation on crypto Twitter about how Alameda managed to lose so much money. But this may give a false impression of ambiguity in other aspects

There's one thing that's unambiguously and indisputably true. SBF and Alameda committed fraud. Period. 2/ For anyone who's been close to the chaos, this will seem so obviously true that it may seem laughable that I even have to make a thread to drive the point home. Not a single credible voice in the industry would tell that this wasn't naked, malicious and criminal fraud
Nov 11, 2022 23 tweets 4 min read
1/ Very rough and speculative sketch of what I increasingly think happened at FTX as more info comes out…

The central question is where did the money go? Yes malfeasance and fraud is necessary, but at one point in the cycle cash actually has to go out the door 2/ At 3AC we knew it went to losses on leveraged long positions. At Lehman it went to bad mortgages. At Enron it went to boondoggle mega projects.

Some FTX money obviously went to seed rounds in bad or illiquid projects. But AFAICT nowhere near enough to explain the hole.
Oct 14, 2022 10 tweets 2 min read
1/ IMO settling with the Mango exploiter was the correct move. It's very unlikely the exploiter would have been criminally prosecuted, even if they were doxxed.

To understand why, it's important to distinguish "computer fraud" from "securities fraud". 2/ The vast majority of hackers (crypto or otherwise) are prosecuted under the Computer Fraud and Abuse Act. Computer fraud is very easy to prosecute, and US Attorneys are very comfortable bringing cases, having a clear template for prosecution.
Sep 4, 2022 12 tweets 3 min read
1/ The economics of BSC are really interesting. Anyone trying to build meaningful value accrual in an L1/L2should pay attention

Yes, BSC fills up a lot of blockspace. (About double Ethereum and the rollups combined) But IMO the key driver of BSC is the high floor price for gas 2/ For years, and even today, the default fee model for L1s is a totally free and unrestricted market for gas. This is the model that Ethereum uses. There's no meaningful floor price for gas, and prices keep falling until supply clears.
Sep 2, 2022 7 tweets 2 min read
1/ Toy model showing that MEV extraction from ordinary users will be slightly worse in post-Merge PoS compared to PoW... 2/ Two simplifying assumptions...

First the value of MEV scales with the divergence between on-chain prices and real-time prices at CEXs (this is basically true for CEX-DEX arbitrage, and increasingly true for other MEV which is more stat-arb driven)
Aug 30, 2022 12 tweets 3 min read
1/ IMO there's essentially no way to make the economics of an on-chain order book sustainable. At least in a general purpose chain

IMO the only solution is an order book specific appchain with application aware pricing. A general purpose chain can't profitably host an order book 2/ The issue comes down to order books requiring a tremendous stream of "rebalancing activity" by specialists to create efficient markets and provide reliable liquidity to organic users.

In modern TradFi, the ratio of HFT messaging to organic activity is at least 25:1
Jul 27, 2022 7 tweets 2 min read
1/ For entertainment’s sake let’s assume Chandler Guo’s ETHPOW fork gets any traction… Some fun consequences to imagine when forking a chain with active DeFi activity. (ETC was well before any real on-chain applications) 2/ First consequence. USDC and USDT on the ETHPOW chain is immediately worthless after the fork, because it won’t be recognized by the Circle/Tether. DAI is more complicated, but similar story because DAI is largely backed by USDC.
Jul 2, 2022 14 tweets 3 min read
1/ Been thinking about value accrual models for L1 tokens…

An L1 is essentially a business that sells the product of blockspace. For investors trying to value L1 tokens, the question is how much value can the chain extract from consumer demand for that blockspace 2/ Note this is a different question than what’s the best model for end-users

Of course you need a product that attracts consumers. But business is filled with examples where the best monetization model is not the most consumer friendly model. Eg SaaS vs shrink-wrapped software
Jun 8, 2022 12 tweets 2 min read
1/ Recently the SEC proposed replacing wholesale PFOF with an open auction on a per order basis.

This is very non-intuitive, but paradoxically could lead to substantially worse price improvement for retail users. Or even eliminate it entirely. 2/ First, let’s take a step back and ask why PFOF wholesalers can offer better prices compared to public markets like NASDAQ.

The reason is because that order flow is “non-toxic”. In other words retail stock traders aren’t very good, and therefore are very easy to trade against
May 9, 2022 4 tweets 1 min read
1/ Fascinating little phenomenon happening in the Uniswap UST/USDC pool right now... The price in the pool is basically "stuck" at $0.952, despite the actual market price being $0.93. ImageImage 2/ The reason is because the pool price has reached the end of any meaningful concentrated liquidity. There's not enough liquidity below $0.95 to justify the gas cost of selling below this price.

*But* you can't add more liquidity without taking an instant loss.
Apr 22, 2022 7 tweets 2 min read
1/ It seems pretty likely we’re about to experience a Cambrian explosion of algo stablecoins.

It might be a really interesting time to build protocols mimicking CDO instruments from TradFi. 2/ You’d start by constructing a pool from a diversified set of yield earning algo stables. The protocol would then slice that pool into a series of tranches with the classic “waterfall loss” model.
Apr 8, 2022 12 tweets 3 min read
1/ This research from @0xfbifemboy is a real glass half-full/half-empty results for concentrated liquidity.

The short summary is that contrary to folk wisdom, simply moving setting your UniV3 ranges correctly is not a source of alpha. 2/ Not a single wallet seems to generate sustained alpha. Regardless of how actively a wallet manages their LP position, everyone in the pool seems to get the same, mostly mediocre returns after IL. There is no silver bullet. (Besides JIT...)
Mar 14, 2022 11 tweets 3 min read
1/ Why I'm not interested in price oracle AMMs as a long-term solution.

(Even if they may be the right approach...)

🧵 2/ An interesting question is what is the role of an AMM when you have a trusted, reliable, accurate on-chain price oracle that's resistant to manipulation and front-running?

(A big if, but for now let's hand wave it away for now) Image
Feb 20, 2022 5 tweets 1 min read
1/ Could wallet software prevent OpenSea type exploits by explicitly telling the user what the tx they’re signing will do to their tokens/NFTs?

Unfortunately, no. As any MEV searcher who’s interacted with salmonella tokens will tell you. Things aren’t that easy… 2/ The way a wallet works is by taking the proposed tx and applying it to a local fork of the chain starting from the most recent block.

The problem is the state of the chain is not guaranteed to be the same by the time your tx is actually mined.
Jan 28, 2022 14 tweets 3 min read
1/ There's a misconception that a Flashbots-like open market for MEV eliminates the profit advantage from integrating searchers with validators. That as long as there's an open market for MEV, searchers will no longer need to run captive validators.

This is not strictly true... 2/ There's an effect known as the Winner's Curse. In a game of rivalrous private information, winning a Dutch Auction (like Flashbots) always comes with -EV adverse selection costs. Essentially competing in an auction means fading your opponents' alpha.…
Jan 22, 2022 5 tweets 2 min read
1/ Don’t understand how people can say that recent market moves show the crypto inflation hedge narrative is dead.

Over the past 6 months, BTC price has moved eerily in line with CPI breakevens. Both peaked in mid-November and have crashed since. 2/ The “Bitcoin has failed to hedge inflation” thesis is confusing headline inflation numbers with long-term market expectations.

Yes, the recent CPI print was high. But that was already baked into market expectations given that CPI breakevens have precipitpusly *fallen*
Dec 21, 2021 8 tweets 2 min read
1/ Been thinking a lot about the relationship between web2 and web3. Feels a lot like the first vs. second industrial revolutions.

The second industrial revolution wasn't successful because it rejected the first. It was a force multiplier on stacked *on top* of the first 2/ The first IR built up the raw technical capacity for hyper-scalability with regards to physical production. The problem was that capability and know-how remained siloed in a few hyper-productive manufacturing hubs, primarily around Manchester.