Hindsight

Verdict hook flags 0x1044 not yet deployed

Uniswap v4 hook · Verdict

The fee is decided
afterwards.

Every automated market maker charges the same fee to two people doing completely different things. This one holds a bond, waits, reads its own price, and then works out which of the two you were.


§1 Same fee, two different people

Exhibit A

The uninformed trade

Somebody saw a price on a screen, decided they wanted the token, and bought it. They have no idea where the price is going. When they are gone the price is roughly where it was.

The provider who filled them is straightforwardly better off. They collected a fee for standing still.

Exhibit B

The informed trade

Somebody knows something. A listing, a print on another venue, a liquidation about to hit. They buy, the price moves, and it stays moved, because what moved it was true.

The provider is worse off by almost exactly the distance the price travelled, and no fee at the rates anybody charges comes close to covering it.

This is not a marginal effect. It is the dominant term in what a liquidity provider actually earns. It has a name — loss-versus-rebalancing — and every dashboard in this industry reports fee APR as though it did not exist. Fee APR is a gross number. Nobody publishes the net one, because nobody measures which trades were which.


§2 Every existing answer is a guess made first

  • By volatility Charge more when the tape is moving. Retail trades in volatility too.
  • By size Charge more for size. The best-informed trade of the day can be small.
  • By address Charge more for addresses that look like bots. A fresh EOA costs nothing to make.

Every one of them is a proxy. Every proxy is gameable. And all of them end up taxing the retail buyer in order to insure against the arbitrageur.


You cannot tell an informed trade from an uninformed one when it arrives.

You can tell perfectly well an hour later.

If the price came back, the trade was noise. If the price stayed, the trade was information. That is not a heuristic and not a model — it is the definition, and it is legible in the pool's own state, with no oracle, no committee, and nothing that can be lied to.

§3 So the pool stops guessing. It waits.

  1. A bond, on top of the ordinary fee

    Every swap posts BOND_BPS basis points, taken in afterSwap from the currency you did not name. It is held, not taken.

  2. The pool writes down what happened

    The tick before your swap, the tick after, and the block number. Nothing else. It has no opinion about you.

  3. After WINDOW blocks, anybody can settle

    The hook reads its own current tick and asks one question: how much of your impact came back?

  4. The bond splits on the answer

    All of it came back — the whole bond returns to you. None of it — the whole bond is donated to the providers who were in range. Some of it — split, in proportion.

  5. Collect it promptly, or it decays

    A verdict collected within GRACE blocks of becoming available is worth all of itself. After that it decays in a straight line to nothing at DEADLINE. refund = bond × ratio × weight.

A retail buyer the market shrugs off gets everything back, and has paid the ordinary fee and nothing else — less than they would pay in any pool priced to survive arbitrageurs. An arbitrageur who moves the price and is right pays the bond, to precisely the people they took it from. Nobody is banned. Nobody is scored on how they look. The pool never needs to know who you are, because it finds out what you did.

Drag the price and watch the verdict change.

Notice

What this costs, said plainly

Your capital is held for WINDOW blocks.
That is a real cost and there is no way around it. A verdict that arrived instantly would be a guess again.
You must come back and settle, and reasonably promptly.
Anyone can call settle for you. Nobody is paid to. In practice you settle your own, and you pay that gas. Leave it past the grace period and the refund starts decaying; leave it to DEADLINE and there is nothing left to collect.
The swap costs about 59 000 more gas.
Measured on a mainnet fork against an identical pool with no hook: 109 938 against 51 220 in steady state. That is the price of two storage slots and a transfer, and it is not free.
The window is a parameter, not a truth.
Too short and slow information looks like noise. Too long and ordinary drift looks like information. It is fixed at construction and cannot be changed by anyone, including whoever deployed it.
You choose when the price is read, and that is a real option.
The verdict has to be read live — nothing on chain can read a tick from a block that has already passed. So a trader can wait for a friendlier reading, and over a long enough deadline ordinary drift will eventually supply one. That option cannot be removed. It is priced: waiting past GRACE costs more than the better reading is worth. Inside the grace window it still exists.
The receipt is issued to tx.origin.
Through a normal wallet that is you. Through a smart-contract account — a 4337 bundle, a Safe module fired by a keeper — it is not you, and the bond is not yours to reclaim. Swap from an EOA.
A forfeit with nobody in range is parked, not returned.
If the donation has no in-range liquidity to land on, the value becomes stranded and anyone can call sweepStranded() later to retry. It never goes back to the trader.

§4 What it deliberately does not do

It does not gate beforeInitialize and it does not gate liquidity. The hook flags are 0x1044afterInitialize, afterSwap and afterSwapReturnsDelta — and nothing else. Every one of them fires after the thing it observes has already happened, so none of them can refuse anything. The Uniswap interface can open this pool, mint a real position, and let the provider leave whenever they like. A hook that can refuse a withdrawal is a hook whose promises are worth nothing.

There is no owner. There is no upgrade path. There is no address anywhere in the contract that can be changed after it is deployed.

Status Nothing is deployed. There are no contract addresses to publish, no pool to trade, and no numbers on this page that came from a chain.