Composable Architecture
Last updated
Last updated
Concentrated liquidity comes has marked a significant advancement over the traditional constant product (i.e., x*y=k) design. It offers better capital efficiency for liquidity providers and diminishes price impact for traders. However, prior to the release of the Liquidity Book, concentrated liquidity had one big flaw — its lack of composability.
For example, on Uniswap V3, each position is represented by the ERC-721 NFTs rather than the fungible tokens users are accustomed to. This not only makes Uniswap LP tokens cumbersome to manage but harms their adoption in wider DeFi.
Liquidity Book takes a different approach with specifically designed liquidity position contracts that function like standard ERC-20 tokens.
Maintaining concentrated liquidity positions demands constant attention from depositors. To continue accruing fees and prevent their LP from becoming "inactive," they must frequently rebalance their price ranges, particularly if they're targeting very narrow or unique ranges to maximize fee capture.
With NFTs, each case of rebalancing requires multiple transactions - withdrawing, redefining parameters and depositing again. This might seem like an insignificant difference at first - what are a couple of transactions in the grand scheme of things? However, because of NFT positions being represented as NFTs, users might hold multiple different ones, even for the same pair. So a couple transactions might quickly turn into four, six, eight or more, making managing liquidity a time-consuming and expensive task.
Liquidity Book simplifies this process to a single transaction for rebalancing. All liquidity within its bins, which are essentially bundled constant sum pools, is fungible, eliminating the need to navigate the complexities associated with multiple NFTs.
Even without juggling multiple transactions, deploying liquidity on Uniswap V3 is a complex task. To do it effectively, Users must weigh various factors, such as current price and expected volatility. For some, managing liquidity on Uniswap V3 can feel like a full-time job requiring a degree in math or finance.
Studies indicate that many Uniswap V3 liquidity providers incur losses due to Impermanent Loss, even after fees are considered. This necessitates increasingly sophisticated strategies to maintain profitability, which can be daunting for average users seeking passive, stable returns.
Liquidity Book makes building custom strategies and deciding what to do with tokens much easier for regular users, thanks to its innovative bin design and liquidity tokens following the ERC-1155 standard (with ERC-721 functionality removed). Besides that, it also compensates liquidity providers for the IL through variable fees.
Decentralized finance thrives on composability. Users can leverage their LP tokens to earn additional yield or as collateral in lending protocols. With positions represented as NFTs, this becomes hard because of how many variations are possible.
One user might choose to provide liquidity for the ETH-USDC pair in the $1000-$3000 range, while another might pick the $1500-$2500 range for their position. So vaults must be built to standardize LP ranges, manage all the rebalancing, and wrap positions into fungible ERC-20 tokens. These tokens can then be used in a broader DeFi ecosystem, for example, as collateral to mint stablecoins.
With Liquidity Book's inherently fungible tokens, developing various vaults and protocols becomes easier. Some of them might cater to people looking for something risky, with tighter ranges and risk of IL, and some - towards those who like to play it safe, with wide margins and less exposure to price spikes. The possibilities are practically endless.
Imagine there exists Alice, who has 1000 USDC and 20 JOE in her wallet. She wants to earn a yield on these assets and decides that she wants to supply them to a decentralized exchange.
On a traditional AMM, this would be pretty trivial. Assuming one JOE is worth 50 USDC, she would just need to deposit her tokens into an JOE-USDC pair smart contract and come back to check prices once in a while. However, Alice wants to use a DEX with a concentrated liquidity model, as it wants to benefit from its capital efficiency. But how does she go about that?
First, she has to decide the prices she wants to LP, and then she has to create positions. After that, the hardest part is still ahead - she needs to constantly keep an eye on prices and rebalance liquidity as needed. The gas fees from rebalancing potentially undercutting her profits., making the whole thing not worth it.
Alternatively, Alice could invest in a vault built atop the Liquidity Book, which would handle these complexities. It would deploy and rebalance liquidity while distributing fees among all participants.
While Uniswap V3 certainly brought a lot of innovation with its implementation of concentrated liquidity, it inadvertently restricted liquidity provision to larger players like whales and institutions. Its cumbersomeness, complexity, steep learning curve, and limited DeFi composability make it less accessible to the average user.
Liquidity Book solves these and many other problems. It preserves the benefits of concentrated liquidity while keeping it as user-friendly as possible, so even less-sophisticated users can benefit from all of the innovations.