Overview for Trader's and LPs


Traders have the ability to use their altcoins as collateral for a perpetual contract on an underlying asset. In order to enter a trade, a trader must submit their altcoins as collateral, ensuring the collateralized altcoin has a corresponding liquidity pool to facilitate the trade. Traders have a wide variety of trade options, with the ability to choose the underlying asset they wish to speculate on (BTC initially), the price direction they seek to speculate on (long/short), the desired leverage for their position, and the type of trade (limit or not). Following the opening of their trades, traders either make a profit or loss, or are liquidated.


When initiating a trade, the associated profits and losses (PnL) are directly influenced by movements in the price of the underlying asset with PnL settlements being paid out in the collateral token provided. Any change in the underlying assets value price in USD value has a direct proportional impact on the PnL payouts denominated in the altcoin collateral token. Given leverage increases exposure in trades, such impacts are multiplied by the leverage.

Rough Conceptual Formulas for PnL Calculation

p = diff * 100 * leverage /openPrice

Longs: diff = currentPrice - openPrice

Short: diff = openPrice - currentPrice

Total Realized PnL:

profit = (collateral in altcoin units * percentProfit)


In quanto derivatives, the type of collateral does not directly influence the calculation of the liquidation price. This is crucial in ensuring that fluctuations in the collateral's value do not affect the stability of the position. The formulas are designed to isolate the liquidation mechanism from such external factors. Liquidations occur when BTC price movements result in a 90 percent loss - with a liquidation price distance being calculated to identify how much of a price movement of BTC in USD would result in such liquidations. Given leverage amplifies profits and losses, leverage is also taken into account in liquidation formulas. Below are rough conceptual formulas to calculate liquidations.

Liquidation Price Distance:

Liq price distance = openPrice * altcoin collateral * (90/100) / (altcoin collateral* leverage)

simplifying it more:

Liq price distance = openPrice * (90/100)/Leverage

This formula computes the price movement needed from the open price to trigger liquidation. It considers only the percentage of the original position at risk (90%) and the leverage, simplifying the calculation by removing any dependency on the nature or behavior of the collateral. Based on your directional bet of long or short, a liquidation price is set using the liquidation price distance in USD value. Once that price is met, liquidation occurs.

Final Liquidation Price:

Long liq price = openPrice - liqPriceDistance

Short liq price = open price + liqPrice distance


LP also needs to pledge alt coin to the collateral pool. Unlike the trader, LP does not need to choose a direction but directly acts as the counterparty to the trader. Additionally, LP earns yield from trading fees. Unlike artificially inflationary LPs that may simply mint tokens as yield, Krav's LPs earn real yield, meaning yield is generated from real fees generated from trading fees.

A liquidity provider may add liquidity to an existing altcoin pool, or create their own altcoin liquidity pool. Creating pools is permissionless, meaning anyone can create a pool. After creating a pool, anyone can provide the corresponding token as LP or create trades, with the corresponding token as collateral.

Last updated