Skip to content

LibraryMarkets2021Design paperCorpus record

The Time-Weighted Average Market Maker

TWAMM. Dave White and Dan Robinson.

Execute a large order as if it were split into infinitely many tiny trades across an interval, without paying gas for each piece. Settlement is lazy. This is an order schedule, not a price oracle, despite the nearby acronym TWAP.

A TWAMM splits a large order into a continuous flow over an interval and settles it lazily against a constant-product pool, so the trader does not send a transaction for every slice.
Evidence
Primary paper
Re-measured
No
Assumptions
4
Records linked
6

Code

Source, repository, and what is actually hosted

  • Paradigm, 2021https://www.paradigm.xyz/2021/07/twamm
  • The source URL is not a GitHub repository. No code remote is invented.
  • Full text is not mirrored. Public availability is not a licence to copy the file onto this site.
  • Add to a reading list

01 Claim ledger

What the paper is allowed to say

Each row is a sentence already in the study. The status is the same on every row: a model claim, not a live measurement.

  1. Claim 01 · Paper model

    It is an order, not an oracle

    The nearby acronym TWAP is a measurement of past prices. A TWAMM is a commitment to sell over time. Using one name for the other inverts the direction of the data.

  2. Claim 02 · Paper model

    Lazy does not mean unfinished

    The pool does not tick every block. When anyone interacts, the contract catches the virtual order up to the present with a closed form. The result is defined. The reserves on chain may look stale in between.

  3. Claim 03 · Paper model

    Impact is reduced only by time and opposite flow

    A large order still moves the price. Stretching it out helps if other trades arrive while it runs. If the pool is quiet, the order walks the curve anyway, just in one settlement.

  4. Claim 04 · Paper model

    Gas is the practical claim

    The user pays to open and close, not per slice. That is why the construction can live on a chain where a thousand small swaps would not.

02 Three cuts

Observation, model, falsifier

A desk does not stop at the summary. Each claim is cut three ways, using only this study's own assumptions and checks. Nothing here is a new figure.

  1. 01 It is an order, not an oracle

    Observation

    What the study says

    The nearby acronym TWAP is a measurement of past prices. A TWAMM is a commitment to sell over time. Using one name for the other inverts the direction of the data.

    Model

    What has to hold

    The order's interval and size are what the user signed. A hook can change the meaning of those fields.

    Falsifier

    What would retire it

    Is this a schedule to trade, or a report of past prices?

  2. 02 Lazy does not mean unfinished

    Observation

    What the study says

    The pool does not tick every block. When anyone interacts, the contract catches the virtual order up to the present with a closed form. The result is defined. The reserves on chain may look stale in between.

    Model

    What has to hold

    Someone interacts often enough if the application cannot tolerate stale reserves. The math is defined either way. The readers of storage may not be.

    Falsifier

    What would retire it

    What pool curve is the closed form written for?

  3. 03 Impact is reduced only by time and opposite flow

    Observation

    What the study says

    A large order still moves the price. Stretching it out helps if other trades arrive while it runs. If the pool is quiet, the order walks the curve anyway, just in one settlement.

    Model

    What has to hold

    The order's interval and size are what the user signed. A hook can change the meaning of those fields.

    Falsifier

    What would retire it

    What pool curve is the closed form written for?

  4. 04 Gas is the practical claim

    Observation

    What the study says

    The user pays to open and close, not per slice. That is why the construction can live on a chain where a thousand small swaps would not.

    Model

    What has to hold

    Cancellation rules are the ones in the contract. The note's early-withdraw behaviour is part of the design, not a default of every fork.

    Falsifier

    What would retire it

    What does the trader receive if they cancel halfway?

03 Sequence

One action, as an operating tape

  1. 01A trader deposits the asset they want to sell and names an interval.
  2. 02The order joins the virtual flow of that direction.
  3. 03As time passes, the flow is treated as trading continuously against the pool and against the opposite flow.
  4. 04The next person who touches the pool updates the lazy state to the current time.
  5. 05At the end, the trader withdraws what the flow bought. They can cancel early, on the note's terms, and take what has executed.

04 Load-bearing

The argument, and where a pitch drops it

  1. The closed form is the invention

    The cut

    Anyone can split an order by hand. The paper's content is executing that split without a transaction per piece, using the mathematics of a constant-product pool plus a constant rate. A hook that simply places ten swaps is not this design.

    Why it carries weight

    If this cut is skipped, the paper's name is being used without the mechanism that makes the name mean anything.

    Where it is dropped

    A TWAMM is not Uniswap's time-weighted average price oracle. One is an order. One is a measurement.

  2. Stale reserves are a footgun

    The cut

    Integrators who read reserves between updates see a pool that has not yet absorbed the virtual order. A price built on that read is wrong in a way the contract will correct at the next touch. The note has to be read by whoever treats reserves as a live quote.

    Why it carries weight

    If this cut is skipped, the paper's name is being used without the mechanism that makes the name mean anything.

    Where it is dropped

    Lazy settlement means the on-chain reserves can be stale until someone transacts. Integrators who read reserves mid-interval have to understand that.

05 Register

What has to be true

  • Model · Not re-measured

    The embedded pool is constant-product, or the closed form does not apply. A concentrated-liquidity pool needs a different derivation.

  • Model · Not re-measured

    Someone interacts often enough if the application cannot tolerate stale reserves. The math is defined either way. The readers of storage may not be.

  • Model · Not re-measured

    The order's interval and size are what the user signed. A hook can change the meaning of those fields.

  • Model · Not re-measured

    Cancellation rules are the ones in the contract. The note's early-withdraw behaviour is part of the design, not a default of every fork.

06 Divergence

What happened after the paper

TWAMM ideas showed up in research prototypes and as candidate Uniswap v4 hooks. A hook that advertises the name may execute a simpler schedule. The 2021 note is the citation for lazy continuous execution against a constant-product pool. It is not Uniswap's time-weighted oracle, which is a different object in the v2 paper.

A later client, parameter set, or reward formula is a different object. Cite this paper for the mechanism. Cite a primary release for the network. This desk has not re-run the proof.

07 Pre-mortem

What to check before you use the idea

  1. 0 of 4 marked on this browser. A mark is a reading note, not a pass, a rating, or a recommendation.

08 Anatomy

The paper, in the order a builder needs

The problem it names

A single swap against a constant-product pool moves the price by the whole size at once. Splitting it by hand costs gas and leaks the schedule. The TWAMM wants the split without the transactions.

What the design proposes

  • Users submit long-term orders: sell this much of A for B between two times.
  • The pool virtually executes those orders continuously against its reserves.
  • Anyone who touches the pool brings the lazy accounting up to date.

How the mechanism is specified

  • Between interactions, the closed form of the constant-product curve plus a constant flow can be computed without iterating every block.
  • Gas stays on the order of a normal swap, not on the order of the number of slices.
  • Price impact falls only if opposite flow, or time, actually absorbs the order. The paper does not cancel impact.

What this page does not treat as proven

  • A TWAMM is not Uniswap's time-weighted average price oracle. One is an order. One is a measurement.
  • Lazy settlement means the on-chain reserves can be stale until someone transacts. Integrators who read reserves mid-interval have to understand that.
  • The note is a design. A hook that claims to be a TWAMM can be a different formula.

Why the desk still reads it

If a product says TWAP, ask whether it is reporting a past price or selling an asset over time. Those are opposite directions of data flow.

09 Lexicon

Terms, opened into the record

Virtual order
An order the contract treats as trading continuously, without a transaction at each moment.
Lazy settlement
Bringing that virtual trading up to date only when someone next touches the pool.

10 Repository

Every linked record on this page

Underlined words open a page that already exists: a concept, a protocol profile, a failure record, or another paper. If a word is not underlined, this desk does not have a record for it.

This is Blockchain Lab's reading of a public design paper. It is not the paper, not a copy of it, and not an offer of tokens, equity, custody or a partnership. Later network behaviour can diverge from the text. Nothing here is investment, legal or technical advice.

Research status: Design paper. Last reviewed: 1 October 2026. This is a reading of a public paper, not investment, legal or security advice.