How much of a liquidity provider’s adverse-selection cost comes from a few counterparties?
- Client context
- Own research · Quantum Research Labs · no client
- Starting point
- Standard models treat adverse selection as an average over everyone who trades. On an on-chain order book, both sides of every fill are visible, so the cost can be measured counterparty by counterparty. We set out to do that end to end, with every number reproducible.
- What we built
- A pipeline from raw node data to results: a parser checked against an open academic archive, 2.48M taker trades after folding sweeps, markouts, persistence and identification tests, screening economics, an extended panel of 26M trades, 30 integrity checks and a reproduction notebook.
- Time to deliver
- About three months from topic to first full write-up (June–August 2026); code and data public in October 2026
- Operational result
- Screening the worst 10% of counterparties avoided 91% of adverse-selection cost, against 9.9% for a random 10%.public repository README · 2026-10-22
- What we handed over
- Public: the code under the MIT licence, the dataset on Zenodo with a DOI, and a notebook that downloads the data and re-checks every published number.
- Evidence
- 569 of 569 checks against the published numbers pass on a clean re-run from open data. Zenodo 10.5281/zenodo.23540388 · 2026-10-22
Problem
Anyone who quotes both sides of a market loses some of the time to counterparties who know more. The usual models treat that cost as an average. We wanted to know whether it is concentrated in a few counterparties, whether that holds over time, and whether public order-book data alone could tell them apart. On an on-chain order book where both wallets of every fill are visible, all three questions can be measured directly.
Work
We parsed raw node data and checked it trade by trade against an open academic archive, which turned up duplicates and a gap in that archive. Sweeps were folded into single taker trades: 2.48 million of them. The markout horizon was declared once, in a single settings file. Persistence was tested by ranking counterparties on the first half of the window and checking the ranks on the second. Every result file records the script, input hashes and settings that produced it, and 30 automated checks guard against look-ahead and stale inputs.
Outcome
Adverse selection behaved like a trait of the counterparty: noise-corrected rank correlation between the two halves was 0.78–0.90. Screening the worst 10% of counterparties avoided 91% of the cost, against 9.9% for a random 10%. The paper is a preprint. The code and data are public, and a notebook re-checks all 569 published numbers, so anyone can verify them without asking us.
No investment, trading or clinical outcome is implied. Internal project.