Introduction

PepperDEX will be running it's native market maker to provide liquidity on the orderbooks. Although it might seem simple, it has a few unique properties we're excited about

  • Bootstrap liquidity on our / Hxro Network's books.

  • Make orderbooks great again with increased liquidity and execution capacity.

  • Enabling the layman user to market-make on derivatives orderbooks without significant knowledge via Vaults.

  • Eliminate impermanent loss for depositors with well-thought-out pricing and spread models.

  • Enables advanced risk management via hedging, funding arbitrage, high-fidelity order updating, and cancellation.

  • Additionally, the portfolio-based cross-margining system of Hxro Network further boosts capital efficiency.

  • If successful, the market maker can be ported to other derivatives platforms, leveraging our partnerships with Zeta Markets.

Properties of the Market Maker

Primary Pricing and Volatility Models

In this model, PepperDEX uses candles of a specific period, say 15 min, for example, for 14 consecutive periods, to determine a range in which the price was observed to be in the 14 15-min periods. This acts as a method of determining the price variance over a given period. The time period is extremely crucial here, as taking too small of a time frame may over-represent volatility. On the other hand, using too large of a time frame may under-represent intraday volatility. Thus, using a strip of timeframes designed to consider intra-hour, intra-day, and inter-day variances is necessary.

The reservation price can be calculated using this estimation of variance/volatility. PepperDEX's reservation is a linear-volume-inverse-confidence-weighted-average-price. This can be a mouthful; let's break it down. PepperDEX's pricing engine aggregates prices from various sources, including centralized and decentralized exchanges. Then, it applies weights to each of these prices according to the volume done and the variance of the price offered by the exchange.

Drawback of candlestick-based variance

The main drawback of candlestick-based variance systems is that they are not extensible for determining the variance of precise timeframes. Using traditional forms of determining variance, such as standard deviations (more on this below), allows for determining the variance of sufficiently large timeframes without ignoring intraday variance, i.e., they can be extrapolated to various timeframes.

Candlestick ranges limit this, as data, i.e., candlestick data used to calculate a true range of a price over a 14 X-min period, cannot be extended to calculate a true range of the same price over a 14 Y-min period, wherein X & Y are different timeframes, like 15 minutes and a year.

Secondary Pricing and volatility model

This model acts as a sidekick, yet an independent model of arriving at variance and the reservation price. Here, the reservation price is simple. It's a median of a dataset of all of the aggregated prices from the various data sources. A crucial detail is that the dataset is not just a dataset of current prices offered by various exchanges. Still, for every price obtained from a source, there are two separate prices, representing the price minus and the price plus the candlestick variance divided by half. This subtle yet simple change allows the secondary pricing engine to be cognisant of the varying levels of accuracy of the prices aggregated from various data sources.

The variance is a derivative of traditional variance models and uses standard deviations to arrive at variance. Like candlestick-based variance, the standard deviation must be modeled to neither under-represent volatility nor over-represent volatility. Overrepresenting variance and quoting wider is practically better than under-representing variance and quoting tighter. The best example of this is EVM-based CEX-DEX arbitrage by HFT block-builders. They can observe changes in centralized markets and react to them in decentralized markets faster than on-chain market makers, who would have quoted tighter previously in their stale quotes. The result is then obvious -- market makers get selectively picked off. That is why it's important to consider intraday variance, as well as interday variance, even in standard deviations, along with combining variances of different sources to arrive at a market-neutral variance that is aware of centralized market conditions, as well as decentralized market conditions.

Quoting on Orderbooks

The market maker would be quoting on derivatives orderbooks, such as PepperDEX/Hxro Network and Zeta Markets. The market maker quotes at asymmetrical spreads around the bid-ask spread and updates its quotes extremely frequently, such that it never misses minor price movements, as well as increases in order-flow imbalance/variance, etc. The level of asymmetry of the spreads depends upon the levels of order-flow imbalance of the market.

Capital Efficiency and Inventory Management

The market maker tries to strike the right balance between its longs and shorts for two reasons: increased capital efficiency and the low-risk profile of the entire portfolio. A tight balance of longs and shorts means that the margining system, which looks at the portfolio as a whole, tends to make lesser initial margin requirements for new positions as the portfolio is balanced and has a very low delta profile. This increases capital efficiency as sufficiently large positions can be opened with sufficiently low initial margin requirements. This can also be applied to a balanced and near-zero-delta portfolio, wherein all shorts offset longs, allowing the market maker to hedge in the same instrument artificially.

Liquidations and Funding Rate Exposure

The market maker separately runs a liquidation strategy along with a set of market-making strategies. The liquidation is simple yet a bit complex. The idea is to liquidate positions with insufficient margins in return for a part of the collateral of the liquidatee. The way liquidations work in Hxro Network, as specified in liquidations, positions with maintenance margin level below the threshold of 1.5 * 1d_standard_deviation * order_size is opened to be liquidated by liquidators. The liquidation price is set to 1 * 1d_standard_deviation * order_size. So, liquidators theoretically get the difference between the maintenance margin threshold and the liquidation price as the reward, which is 0.5 * 1d_standard_deviation * order_size. However, a crucial point to consider is that the above liquidation concept is designed without considering market forces such as slippage, orderbook depth, and latency.

To ensure robustness and maximal return, the proprietary client run by the protocol to execute liquidations accounts for low orderbook depth, high slippage, or extreme congestion faced by the Solana network, leading to increased latency. Currently, the liquidation capacity (measured by liquidation size and the time to liquidate it) is expected to be extremely low as we deal with slippage and low orderbook depth. However, this situation will improve as the market maker progressively adds liquidity to the books, significantly improving the liquidation capacity of the liquidator.

The funding rate is yet another critical problem that the market maker faces. In its pursuit to have a well-balanced portfolio for capital efficiency and drastically reduced delta, it may end up paying as much as 20-30% of its total APR in funding payments, thus reducing its total APR by a lot. Therefore, to tackle this, the market maker not only sets significantly short times for the settlement of positions (in the factor of minutes), but it also helps the market achieve efficiency by arbitraging the funding rate and returning the theoretically lost APR.

Last updated