Skip to main content
This page covers concepts specific to the Exponent CLMM. For shared protocol concepts, see:

APY-Based Tick System

Unlike traditional CLMMs where ticks represent price points, the Exponent CLMM uses ticks keyed by APY scaled by 10^6. The tick key maps to a spot price via: [TODO] For example, a tick key of 80000 corresponds to 8% APY. Ticks are stored in a red-black tree with a maximum of 1000 active nodes. The tick_space parameter determines the minimum distance between tick boundaries.
Ticks represent APY levels, not price levels. A tick key of 50000 means 5% APY — not a price of 50,000.

Fee Model

The CLMM uses a time-weighted fee decay model where fees decrease as maturity approaches. The protocol takes a cut of swap fees defined by treasury_fee_bps. Remaining fees accrue to LPs via Q64.64 fixed-point fee growth tracking — see the MarketThree account reference for details.

YT Trading via Flash Swaps

The pool only holds PT and SY — YT cannot be traded directly. Instead, YT trades use flash swaps: the pool temporarily lends tokens, the instruction strips or merges them, and repayment happens atomically within the same transaction. Buy YT: The pool flash-lends SY to the trader. That SY is stripped into PT + YT. The YT goes to the trader, the PT is sold back through the CLMM for SY, and the proceeds repay the flash loan. Sell YT: The pool flash-lends PT to the trader. That PT is merged with the trader’s YT into SY. The SY goes to the trader, a portion is used to buy PT back through the CLMM, and the purchased PT repays the flash loan. The trader keeps the remaining SY. Because the PT leg of a flash swap is just facilitating the YT trade, fees are charged on the YT value rather than the full PT amount — resulting in lower fees for YT trades compared to equivalent PT swaps. The lower-level buyYt and sellYt instructions handle the flash swap directly using SY. The SDK’s wrapper instructions (ixWrapperBuyYt, ixWrapperSellYt) add base asset conversion on top, so developers can trade YT from any supported token in a single transaction.

Swap Routing

PT swaps route through active liquidity at the current tick. Two directions are supported: SY → PT (buying PT) and PT → SY (selling PT). Both exact-in and exact-out variants exist. An optional priceSpotLimit parameter provides anti-sandwich protection by aborting the swap if the price moves beyond the specified threshold.

Key Accounts

MarketThree

The onchain account holding all CLMM state — token mints, escrows, tick configuration, financials, emissions, and status flags. See the MarketThree Account Reference.

LpPosition

A per-user position account tracking LP balance, fee accruals, and farm emissions within a specific tick range. See the LpPosition Account Reference.

LpFarm

Manages liquidity mining rewards — up to 3 concurrent emission tokens distributed to LP providers proportionally. See the LpFarm Account Reference.