Today, we are ecstatic to introduce the Replicating Market Maker ("RMM-01"), a spot exchange and derivative protocol.
While derivatives in traditional finance are massive, DeFi derivatives have yet to grow to a comparative scale. This is in part because they are bottle-necked by their dependence on oracle systems and high collateralization requirements.
Oracles are one of the largest sources of smart contract vulnerabilities and perhaps the largest centralization vector, so we sought out an architecture that excluded them.
Primitive is an oracle-free solution to scalable and efficient on-chain derivatives, reflecting our belief that the future of decentralized finance should not depend on expensive (and often brittle) oracles.
The protocol is slated to launch December 2021 on Ethereum L1 mainnet, Arbitrum L2, and Optimism L2.
The features on launch include:
The protocol can be used for:
Out of the box, Primitive is the base infrastructure for an oracle-free DeFi and the future of on-chain derivatives.
Read on to learn about "derivative tokens" and how the pools concentrate liquidity as an AMM.
Every liquidity provider to the popular automated market makers ("AMMs") has, implicitly or explicitly, held an underlying derivative: the liquidity pool token ("LPT").
Primitive is not an AMM that trades derivatives, the LPT is the derivative. This specific niche of derivative market has seen some early growth, but has yet to reach the spotlight. For example, there are a few protocols that leverage the LPT as a derivative: Onboarding Uniswap V2 LPTs, Aave AMM Markets Released, Balancer as a portfolio manager, and the idea of "Pool 2", Yield Farmer's Guide.
Primitive leans into this market as an AMM whose primary use-case is having financially useful LPTs. This makes the protocol different when compared to other AMMs, which have arbitrary LPTs that are not the most straightforward to value.
Using RMM liquidity pool tokens, virtually any derivative payoff can be offered or created. For example, in a decentralized lending market like Fuse, these LPTs can be shorted, expanding the possible derivative payoff range to call and put options, and therefore nearly any derivative payoff one could imagine. Structured product and liquidity strategy protocols, like Ribbon and Charm, can use a basket of LPTs to make novel products for any token on any EVM chain. Binary options can be created by selling the rights to one side of the LPT, as researched in Replicating Monotonic Payoffs. A basket of these binary options can be used to replicate an unlimited number of instruments!
All of the liquidity which backs these LPT derivatives is productively used as a spot exchange for tokens, just like any other AMM. Better yet, concentrated liquidity curves make these swap rates competitive within the DEX ecosystem, which captures more trading flow and generates fees for liquidity providers.
Liquidity providers are exposed to the price risk of the underlying assets and are not neutral. While the swap fees compensate for the risk, being an LP on Primitive is almost the same as market making covered call options. With this complexity, positions will be optimally managed in a more active way and ideally delegated from most users to vault products like Yearn and Charm.
Liquidity within the RMM is not tokenized itself, enabling higher level smart contracts to make the decision on their own. This allows any token standard to be used: ERC-20, ERC-721, ERC-1155, etc.
Primitive's Manager contract uses the ERC-1155 standard to tokenize liquidity. This comes with several important features:
The core smart contracts can hold internal balances, allowing liquidity to be moved in and out of pools without paying the gas cost of transferring tokens. These token transfer costs are usually 1/3 of the total gas cost for providing liquidity to AMMs. Now liquidity can be moved in and out of pools (for the same pair) with much lower friction.
The state of reserves for these pools are valuable on-chain resources which can be weaponized into TWAP oracles. This is done by utilizing the cumulative reserves of a pool and viewing it over a select time range.
While this oracle would be for spot prices, a TWAP oracle for volatility can also be created using the cumulative liquidity of a pool. Mapping the most liquid pools to their respective volatility curves gives incredible insight into the implied volatility of the token pair.
Although ideally, oracles wouldn't be needed in an RMM world.
Several professional smart contract security firms were engaged to review the core and peripheral contracts of the Protocol:
While we believe such a range of serious audits is the absolute minimum safety measure in the DeFi, the complexity of the protocol and the ecosystem means that a completely bug free codebase can't ever be guaranteed.
As such, an open bug bounty of $250,000 is offered through Immunefi to anyone who finds a critical bug within the smart contracts.
The Primitive Protocol will be deployed to testnet during the week of December 7, 2021, allowing anyone to use the protocol in advance of the launch.
For launch to go smoothly, we will focus during the remainder of December on these priorities:
Go tell your friends about the oracle-free derivative protocol launching this month with concentrated and fungible liquidity.
To meet the rest of us, join the Primitive discord.
Read this post on mirror: mirror.primitive.eth.
Read this on the Primitive blog: blog.