The goal of the Injective community has always been to create a market leading exchange that is able to surpass centralized exchanges with respect to both user numbers and trading volume. This has led contributors to dive deeper into how Injective can retain the benefits of a layer-2 model while also creating an exchange that is usable by both retail traders and institutions.

This piece will provide a close examination of market challenges that remain pervasive in the DEX sector. It will also lay out the present ideologies behind carrying out a major upgrade to the matching mechanism this past month that utilizes a frequent batch auction model. In the end, Injective contributors have managed to create an entirely new exchange model that in addition to sustaining rapid transaction times is able to tighten spreads with higher liquidity closer to the market price.

The Problem with Continuous Double Auctions

Centralized exchanges offering crypto derivatives and traditional financial markets utilize Continuous Double Auction (CDA).

In this model, orders are processed as soon as they reach the exchange. This is achieved either by immediately filling an order on the opposing side of the order book or by resting on the order book until a matching order is found.

CDA processing of orders creates incentives for speed, and markets with high volatility create tremendous arbitrage opportunities. The role of market-makers (MMs) is to follow the market price of assets and provide depth by placing orders on each side of the order book. As the price moves, MMs must cancel and create orders accordingly.

However, in the time period between externally signaled price updates, there remains an opportunity for high-frequency traders (HFTs) to fill stale MM orders before the MM can cancel them. HFTs are therefore able to collect arbitrage rents. The profits from this stale order sniping game are so large and constant that HFTs invest in advanced technologies such as microwave towers and FPGAs to engage in nanosecond (one billionth of a second) speed competition, leaving MMs at an insurmountable disadvantage.

Due to these salient issues, MMs are often forced to increase their investments into competitive tech solutions that are often indirectly paid for by traders through higher trading fees. In addition, the MMs are often made more risk-averse from providing significant depth close to the market price. Not only does this harm retail traders who want to fill orders at a fair price but it also creates high volatility inside the spread that destabilizes the market on small time scales. Thus, retail traders are frequently forced to enter positions at unattractive prices.

CDA matching engines require high-throughput at unpredictable times while demanding very little at most other times with normal volume. Even when built by centralized institutions, CDA-based exchanges are rarely able to fulfill the market demand for 100% uptime. Matters are further exacerbated within the realm of decentralized exchange protocols which are bound by the constraints of blockchain networks. Therefore, DEXs have much less flexibility in designing how to solve the same challenges that even the most modular centralized exchanges today are not fully capable of solving.

The attempt to haphazardly make insubstantial changes to the CDA-based market design on DEXs has been duly met with dissatisfactory compromises that ultimately hurt retail traders financially. For example, instead of prioritizing orders by submission-time, orders placed with the highest gas fees are executed before those with otherwise reasonable gas fees.

Anyone who has traded aggressively on AMM-based exchange protocols in particular knows the pain of being front-run by bots who pay a slightly higher gas fee to directly profit from the margins of the trader’s slippage tolerance. Since AMMs are designed to cut out the need for institutional MMs, the costs of CDA-related capital inefficiencies are passed directly onto retail traders.

Injective’s Frequent Batch Auctions: A New Era in Trading

The Frequent Batch Auction (FBA) model is commonly proposed in economic journals as the definitive solution to capital inefficiencies relating to the CDA.

An additional benefit of an FBA is a definite provisioning of a more liquid marketplace by eliminating front-running.

The FBA is defined by the following three features:

Feature One: Discrete Time

Orders are accepted over a discrete time period, known as the auction interval. At the end of each auction interval, crossing orders are filled with the following priority:

  • Market orders are filled first
  • Unfilled limit orders from prior auction intervals are filled
  • Limit orders from the most recent auction interval are filled last.

If the quantity differs between bids and asks at the cross, the smaller quantity side fills in full while orders from the higher quantity side are filled pro-rata (evenly and partially).

Feature Two: Uniform Clearing Price

Limit orders are filled at a uniform clearing price where the quantity of crossing orders is highest. If the bids and asks cross with the same quantity, the midpoint price is used for the clearing price.

Feature Three: Sealed Bid

Orders are not published to the order book until the auction interval ends and the batch auction is executed. This eliminates the possibility of front-running and negative spreads.

Market Maker Incentives in Frequent Batch Auctions

The relatively large auction interval provides MMs with ample time to cancel stale orders before HFTs are able to execute on them. This eliminates the risk of MMs having to deal with front-running issues, therefore removing their need to invest capital in advanced technologies.

As a result, MMs are emboldened to provide deeper liquidity closer to market price with tighter spreads. Not only is this a better scenario for retail traders who are trying to fill an order close to a fair price but it also reduces the volatility associated with potential price crashes.

Frequent Batch Auctions aggregate orders for state change or order book inclusion on a set auction interval. Blockchains queue and write transactions in batches to sequentially-produced blocks. The optimal batching interval for FBAs is up for debate, but has been academically reported to be between 0.2 and 0.9 seconds, which falls in line with Injective’s auction interval with batch auctions executing at each endBlock.

The instant finality feature of Tendermint’s BFT-based PoS consensus (on which Injective is built) corresponds startlingly well to FBA executions at the end of each interval. Since the FBA has no concept of time priority within auction intervals, it is the perfect market design for blockchains that operate on the same basis. The market design fits the bespoke Injective infrastructure like a glove.

Conclusion

By replacing the continuous double auction (CDA) with frequent batch auctions (FBA), Injective is adopting a market design that is both technically robust and competitive against centralized exchanges. Injective is able to eliminate predatory front-running while enabling the provisioning of deeper liquidity at tighter spreads by market makers.

The implementation of frequent batch auctions readies Injective for volume competition against institutional-grade, centralized exchanges.

References

[1] Aldrich, Eric M., and Kristian López Vargas. 2018. “Experiments in High-Frequency Trading: Testing the Frequent Batch Auction.”

[2] Budish, Eric, Peter Cramton, and John Shim. 2013. “The High-Frequency Trading Arms Race: Frequent Batch Auctions as a Market Design Response.”

[3] Budish, Eric, Peter Cramton, and John Shim. 2014. “Implementation Details for Frequent Batch Auctions: Slowing Down Markets to the Blink of an Eye.”

[4] Fricke, Daniel and Austin Gerig. 2016. “Too Fast or Too Slow? Determining the Optimal Speed of Financial Markets.”

[5] Jagannathan, Ravi. 2019. “On Frequent Batch Auctions for Stocks.”

About Injective

Injective is the first cross-chain protocol built for decentralized finance applications. On the Injective exchange, anyone can access, create, and trade unlimited DeFi markets such as futures and perpetuals. Developers can also build cross-chain Ethereum-compatible projects that are lightning fast and achieve instant transaction finality. Injective is backed by a prominent group of stakeholders including Binance, Pantera Capital and Mark Cuban.

Website | Telegram | Discord | Blog | Twitter | Learn | Youtube | Facebook | LinkedIn | Reddit | Instagram | Weibo | Orbit Newsletter