Liquidity Provision & LP Inventory Management

The Nunchi Vault is the smart contract system that manages collateral deposits, and maintains the hedges. It is what powers the AMM in the CLOB/AMM mechanism. Its mechanics ensure the system stays solvent and stable through various market conditions. Key aspects of the vault dynamics include:

Dual Liquidity Sources: Liquidity providers can contribute in two ways:

  1. Limit Order Providers (LOB LPs): Professional market makers or algorithms can place limit orders on-chain, providing liquidity at specific prices. These LPs earn the bid-ask spread and maker fees when their orders execute.

  2. AMM Liquidity Providers (Pool LPs): Users can contribute assets to the AMM pool (e.g., a stETH/USDC perpetual pool). The AMM uses these pooled assets to market-make continuously, and LPs earn trading fees from AMM fills (plus potentially a share of funding payments, see below).

LP Capital Efficiency: The protocol is optimized so that LPs, especially in the AMM, get maximum utility from deposited capital. Key design choices include:

  • Concentrated Liquidity: Instead of a traditional constant product AMM spread across all prices, we implement a Liquidity Book / Uniswap v3 style model where LPs concentrate liquidity in certain price ranges. Liquidity is discretized into “bins” or ranges. For example, an LP providing stETH/USDC liquidity can allocate funds only in the price range near the current price (e.g., $1,800-$2,200 for stETH), which yields higher fee earnings and less unused capital. This model reduces slippage and improves capital efficiency by focusing liquidity where trading happens.

  • Dynamic Range Orders: LPs can adjust their liquidity range or “shape” based on market conditions. For instance, if an LP expects low volatility, they might narrow their range around the current price to earn more fees. If expecting a big move, they widen the range to avoid getting taken out. The protocol could offer an automated rebalancer or recommended ranges to simplify this.

  • Yield-Bearing Deposits: Crucially, LPs can deposit yield-bearing versions of assets. For example, instead of raw ETH, LPs deposit stETH into the pool. Instead of USD, they might deposit a T-bill token earning 4% APY. This means LPs continue to earn the native yield on the underlying even while it’s being used for liquidity. The smart contracts would be designed to recognize the accruing value of these tokens (e.g., stETH increasing in value vs ETH, cTokens accumulating interest) and automatically update balances. Thus, LP returns = trading fees + funding payments + underlying yield. This feature unlocks additional revenue streams for LPs, making it attractive to supply liquidity for yield-bearing markets.

  • Unified Liquidity for Perps and Yield Markets: Since MegaETH supports atomic composability, LP assets can simultaneously be used across multiple protocol components. For example, a portion of AMM liquidity (say in USDC) could also be lent out on a money market between trades, or used as collateral for cross-margin. The design envisions a universal liquidity pool where LP funds not needed for immediate AMM trades can earn yield elsewhere (like MegaETH’s native money market), then be pulled back to the AMM when needed. This is facilitated by MegaETH’s high TPS allowing rapid reallocation. Essentially, idle liquidity is minimized – every asset is always working either providing depth or earning yield.

Inventory Management: One challenge of an AMM in perps is inventory risk – e.g., the AMM could end up net long or short if trades are unbalanced (this is analogous to impermanent loss). Our design mitigates this in several ways:

  • External Balancers (Active Makers): The presence of the order book allows external market makers to step in and take the other side of imbalances. For instance, if the AMM has accumulated a large net long position (lots of traders bought from the AMM), arbitrageurs can place limit sell orders on the CLOB at slightly above index price to offload the AMM’s inventory at a profit. This mechanism transfers risk from the AMM (and its LPs) to arbitrageurs whenever the AMM’s price deviates from the fair market price. The hybrid model inherently encourages this rebalancing, because any divergence in AMM price invites CLOB orders to fill the gap.

  • Dynamic Funding & Pricing: (Detailed in the next section) – if the AMM/pool is net long (more longs than shorts in the perp market), the funding rate will adjust to make long positions pay shorts, which in effect incentivizes traders to take the opposite side (go short) and bring the system back to equilibrium. The protocol’s pricing engine could also widen the AMM’s quoted spread if imbalance grows, discouraging further stress on the inventory. These economic levers push the market toward neutrality (long open interest ≈ short open interest).

  • Hedging and Insurance: The protocol can automatically hedge some of the AMM’s exposure. For example, if the AMM is long 100 stETH perps (meaning traders are short against the AMM), the protocol’s treasury or a dedicated insurance fund could short 100 stETH on an external venue or on its own platform via the order book. This way, LPs are protected from directional moves (the hedge covers losses if price drops). The insurance fund accumulates reserves (from a portion of trading fees or protocol token rewards) to finance such hedging or to cover any residual losses if extreme events exhaust the pool. Additionally, LPs could be given the option to provide single-sided liquidity (e.g., only contribute USDC to mainly take on short exposure or only stETH to take on long exposure) depending on their risk preference, and the protocol’s risk engine can pair these appropriately.

LP Returns and Exposure: LPs in the AMM effectively act as passive market makers. Their position is like short an option straddle – if price remains in their range, they earn fees; if price trends, they end up holding more of one asset (exposed to price risk). However, because our assets themselves yield interest, even an imbalanced LP position has some offsetting gain:

  • Example: An LP provides equal valued stETH and USDC. Suppose traders buy a lot of stETH from the pool, leaving the LP with mostly USDC (and a short stETH perp position). While the LP is short stETH (losing if ETH price rises), the USDC he holds can be parked in a yield strategy (earning, say, 5% via T-bills). Conversely, if traders sell heavily to the AMM, the LP ends up holding extra stETH (long stETH position), which yields ~5% staking rewards. These yields act as a natural buffer against moderate funding payments or price moves – a novel benefit when the underlying is yield-bearing. Ethena’s research confirms that combining staking yield (~3-5% on stETH) with perp funding can significantly reduce net negative revenue days. In our design, this means LPs are more likely to at least break-even or profit despite some inventory skew, as the sum of trading fees + funding + yield tends to be positive in the long run.

Cross-Margin for LPs: We extend universal cross-margin to LP accounts as well. An LP can use their liquidity provider tokens or staked assets as collateral to borrow or leverage within the protocol. For instance, an LP who deposited $1M of liquidity might be allowed to take on a $200k short perps position as a hedge, using their LP shares as collateral. This flexibility, enabled by MegaETH’s composability, means LPs can actively manage risk while providing liquidity, all within one platform. It also increases capital efficiency (the same capital secures LP positions and margin positions concurrently).

Delta-Neutral LP Positions

Nunchi’s vault effectively operates a delta-neutral liquidity position for each collateral type. “Delta-neutral” means the portfolio’s value doesn’t change with the underlying asset’s price movements consensys.ioarrow-up-right. The vault goes long on the collateral asset and short on an equivalent amount of the asset (via perp or derivative), resulting in a net zero exposure to price. This setup can be viewed as a form of providing liquidity or a basis trade: the protocol holds the asset and its short, which is similar to a dealer holding an asset and shorting futures against it.

This delta-neutral position yields profit equal to the basis (the difference between collateral yield and short cost). If the collateral yields more than the cost of shorting, the vault earns a positive carry; if less, there’s a negative carry. In many cases (like staking yields or positive perp funding), the carry is positive medium.comarrow-up-right, which is beneficial. The vault’s design is analogous to other delta-neutral stablecoins like Ethena’s USDe or UXD on Solana, which use perpetual futures to hedge and issue a stablecoinmedium.comarrow-up-rightconsensys.ioarrow-up-right.

Last updated

Was this helpful?