โœจFermi DEX: Features

Never-seen-before stuff you can do on Fermi DEX

Context: Fermi DEX is a fully functional DEX built on a Central-Limit Orderbook (CLOB), that allows you to efficiently swap tokens, place limit orders (Bids & Asks), and cancel those orders, in multiple markets. Here we highlight the new features that Fermi brings to the table to enhance capital utilisation - in addition to all the normal DEX functionality that it supports.

1. Express an intention to trade without locking up capital

On Fermi DEX, liquidity is not debited when you place a Limit order. Thus, you can post an arbitrary number of orders - allowing you to be optimally placed for any moves in the market, or any arbitrage opportunities. This is in contrast to traditional on-chain orderbooks, which lock up the liquidity from the moment of order creation.

2. Provide liquidity "Just in Time" to finalise matched orders

Unlike Serum/Openbook DEX, Fermi only debits funds from your wallet, after a match has been found, and your order has been filled. This setup of "Just in Time" liquidity allows you to participate efficiently in multiple trades, without having to keep collateral locked for each trade in advance of finding a match. Notably, in case an order is only partially filled, only the required liquidity for the amount matched will be transferred, and not the entire liquidity. In case the counterparty fails to post the funds, the trade fails and funds are returned.

Centralised exchanges also follow this setup of debit-upon-filling, and we believe that in the future, this would be the standard model utilised by DeFi applications as well. However, we go a step further, and enable cross-application liquidity abstraction too - which unlocks a level of composibility uniquely possible only in DeFi. More:

๐Ÿ‘ฝpageJust In Time Liquidity

3. Specify Liquidity Management Programs (LMPs) to supply liquidity upon order matching

Optionally, users can specify an LMP with custom logic, which gets called by Fermi DEX when an order is filled. These programs can control the user's positions on other platforms, and can supply the liqudity as and when needed to a trade on Fermi. More:

๐ŸชpageTransfer Hooks Redefined

4. Orders can be finalised atomically

Since order finalisation on Fermi DEX is non-deterministic (accounting for the possibilities of a counterparty failing to post JIT liquidity), trades are finalised atomically, by calling the "FinaliseMatch" method. This is somewhat akin to cranking in Serum, but since it is sequence independent, it cheap and easy for any user to perform.

More:

๐ŸคpageMatching Logic

5. Order failure is minimized by use of penalties and reputation scores

In case a counterparty fails to provide liquidity when called upon, the users can invoke cancel_with_penalty to cancel the order and issue the marginal deposit placed upfront (~1% of trade value) to the honest party as a penalty. In the longer term, reputation scores can be used to eliminate market makers with finalization rates below a certain threshold (say 98%) from participating in the matching process, at the option of the trader.

More:

๐Ÿ‘ฉโ€๐ŸŽคpageActors and Incentives

Last updated