DocsMechanism

Mark price and the vAMM

Ten thin markets on people would not fill an order book on day one. A virtual AMM gives every market deep, deterministic liquidity from the first trade, with no market makers to recruit and nothing to run out of.

Why a virtual AMM

The reserves are virtual: nobody deposits into them and nobody withdraws. They are a pricing function. A long adds quote and removes base; a short does the opposite; the mark is always quote divided by base. Because the curve never runs dry, every order fills, and the cost of size is price impact rather than a missing counterparty. An order book is a v2 candidate if volume justifies it.

How the curve prices a trade

before: mark 100.00after a $200k buy: 102.01base reserve (virtual)quote reserve (virtual)x · y = kmark = y ÷ xA long adds quote and removes base.A short does the opposite.Impact of a buy of N against quote Q:(1 + N ÷ Q)² − 1$20M virtual quote per market:$100k moves the mark about 1%.$1M moves it about 10%.Each keeper tick re-pegs the curve 15% ofthe way back toward the index.
A buy moves along the curve: base leaves, quote enters, the mark rises. The average price of the trade sits between the mark before and after.

Buying with N of quote against a quote reserve Q raises the mark by (1 + N ÷ Q)² − 1. Selling mirrors it. Unit-sized orders trade an exact base amount along the same curve. The round trip is exact: buy and sell back and the reserves return to where they were, so fees are the only cost of a wash.

Depth and price impact

Every market has $100M of virtual quote liquidity. The depth ladder in the terminal shows what each size would do; the table below is the same math.

Order sizePrice impactMark after, from 100.00
$10,0000.02%100.02
$50,0000.10%100.10
$100,0000.20%100.20
$250,0000.50%100.50
$500,0001.00%101.00
$1,000,0002.01%102.01
$2,000,0004.04%104.04
Slippage guard

Market orders are rejected when their price impact would exceed your max slippage, 3% by default in the terminal. Change it from the settings chip on the order panel.

Anchored to the index

On an order-book perpetual, arbitrageurs keep the market price near the index. A demo venue has none, so the engine does the job itself. The mark is defined as index × (1 + premium), where the premium comes from the market's open-interest skew: a market that is net long trades at a premium, a market that is net short trades at a discount, and a balanced market trades at the index. The premium is capped at ±0.5% and reaches the cap at $1M of net open interest.

The curve is re-anchored to that price every second and again immediately before any fill, so the price you see is the price you trade from. Your own order still walks the curve and pays impact for its size; that impact is not carried into the next trader's price, because the position it left behind is already expressed through the skew premium. The result is a mark that is deterministic given the index and the book, on any number of servers.

What this replaces

Earlier builds let trades move the curve and pulled it back toward the index a fraction at a time. Between pulls the displayed mark could sit well away from the index, so a market order filled far from the price on screen. That is gone.

What mark is used for

  • Fills execute on the curve, so the mark is where you trade.
  • Unrealized PnL and the positions table are marked at the mark.
  • Funding compares the mark to the index; see Funding.
  • Take profit, stop loss and trigger orders fire on the mark.
  • Liquidations do not. They read the index, so a thin curve cannot be pushed to liquidate anyone. See Liquidations.
Last updated 17 September 2026 · Perps are volatile. Traders are worse. Nothing here is advice.