Lixir Mechanics

Lixir
6 min readApr 17, 2021

Overview

Lixir’s goal is to allow efficient allocation of capital to Uniswap v3 liquidity pools, as well as similar pools that may appear on other AMMs. Allocation is directly tied to ROI: the less capital you can lock up to earn a certain return, the better ROI you have.

To do this, you want to constantly have your capital allocated to the narrowest range that consistently earns fees. The more capital you have concentrated outside that range, the less you earn.

The differences of small optimizations can be dramatic. As an example, imagine you are choosing whether to concentrate liquidity to the DAI/USDC pair in the 0.99–1.01 price range, or the 0.95–1.05 range. The former range is 5 times more efficient, meaning that if the price spends more than even 20% of its time in that range, that’s a better place to allocate.

The problem, of course, is that if the price moves outside your range, you earn 0 fees. Ideally, we’d like to earn both when the price is 0.99–1.01 and when it moves outside that. For all but the most committed power users, that optimization will require automation and off-loading to a service provider who manages those concentrations for you.

Below, we go into high-level detail about how Lixir manages your concentrations to achieve the best ROI.

Basic Mechanics

Initially, Lixir will feel like Compound, where the Lixir DAO votes on Uniswap v3 pairs to add, and then manages those pairs going forward. However, the actual pool mechanics differ significantly from lending platforms and require explanation. The pools work as follows:

  1. The DAO votes to add a pair, and sets its target price range (e.g. $2350-$2750 for USDC/ETH) as well as a re-pricing limit (a number like 10%, explained in “Re-Pricing and Adding Capital” below).
  2. Users add liquidity to a pair of their choice, and receive minted tokens representing their share of the pool. (This mechanic is familiar to people who have used Uni V2).
  3. The pool maintains a Uni V3 NFT representing a certain price range.
  4. Over time, that NFT earns fees, most of which is profit that pool members can claim, and part of which will be used to rebuy LIX and increase its value.
  5. A fixed amount of $LIX rewards will be available to mine at intervals, and will be released to each pool. The more liquidity/users in a pool, the lower its rewards will be. This mechanic will have to be balanced basec on real-world usage patterns and as such is subject to tweaking.
  6. As the price of a pool gets closer to the edges of its range, users can reset the price range by adding capital to one side of the pool, or can get rewards for calling a re-pricing function when the re-pricing limit has been reached. This is explained below in the “Re-Pricing & Adding Capital” section.

Re-Pricing & Adding Capital

Inevitably, Uni V3 pools move away from the center of the price range chosen. For example, if an USDC/ETH pool has a $2350–2750 range, and the price is $2550 initially, eventually the price could easily be $2420 — near the edge of the range.

There are two ways that pools can “reset” at a new “center” of their range. The first is re-pricing, and the second is adding capital. While adding capital is preferred and more highly rewarded, both are important to understand.

Re-Pricing

When a pool is created, the DAO sets a re-pricing limit for it. This is a percentage that represents how close to the edge of the range the pool can be before rewards are given for re-pricing it. In our example above, let’s assume that limit is 10%. The range is $400 wide, so that is $40, meaning that when the price goes below $2390 or above $2710, the pool is outside the limit.

When the pool is outside the limit, $LIX rewards are given for calling the Uni V3 re-pricing function. This function market-sells the over-represented asset and buys the under-represented one in order to bring the pool back to the center of its range.

Note that the re-pricing function can only be called when the pool’s price is outside the re-pricing limit, in order to limit re-pricing events and gas usage.

Adding Capital

he second way to reset price is by adding capital. In our example, if USDC/ETH has moved to $2700, the pool now has more USDC than ETH. To make $2700 the new “center” of the range, the pool needs ETH to be added.

The contract calculates the amount of one side needed in order to reset the price to the new range or to move it closer, and rewards users in $LIX for contributing capital that moves the pool closer to this range.

At any given time, some pools may be further out of range than others, and more $LIX is given for adding capital to a pool that is further out of range.

Rewards

Lixir rewards aim to incentivize getting pools back to a balanced price range. Rewards are earned for:

  • Providing capital needed to re-balance pool price ranges.
  • Calling the re-pricing function.
  • Keeping capital in a pool while it is in range — no rewards are earned when the price has moved out of the pool’s range, incentivizing rebalances.

Lixir takes a small percentage of the fees earned from each pool to market buy $LIX, which allows it to go back into the ecosystem and pay the rewards above.

At the moment, Lixir does not plan to have a staking mechanism, since we currently see it as increasing capital costs, defeating the purpose of the platform. We may, however, add one in the future if it makes sense, as we see how the market plays out and assess various aspects of the system.

Risks

  • No fees: If the price moves out of a pool’s range, no fees can be earned until capital is added or removed in order to re-balance. Lower ROI pools will stay in range for longer. This can be thought of as an opportunity cost risk.
  • Impermanent loss(IL): When a pool moves out of range, users own 100% of the lower-priced pair. For narrow ranges, this is not a huge problem, since the price of each token will be closer to each other, but it is still worth noting.

Although Uniswap v3 liquidity concentration has been compared to leverage, the comparison fails in that liquidation is not an issue. All that happens when the price moves out of range is that you suffer a bit of IL and don’t earn fees.

Governance

Governance features may be added over time, but the primary initial ones are:

  • Adding new pairs.
  • Setting pair price range size targets.
  • Setting pair re-pricing limits.
  • Approving new volatility pools for existing pairs

One example of a governance feature planned after the initial launch is the ability to propose and vote on burning events of circulating $LIX. The community would help decide if occasional deflationary pressure would be healthy for the platform.

Future Features

As users get comfortable with the platform, we will add more features over time. Some initial improvements we are targeting are:

  • A reserve fund for each pool that users can contribute to, whose assets are used as the first re-pricer when the pool goes out of balance.
  • Multiple volatility pools for each pair, in order to let users get more or less consistent fee-taking.
  • Reward amounts for each pool will need to be balanced and optimized as we gain experience with how Lixir is used in practice.

Next Steps

We are currently implementing the above features and polishing code, and will release the contracts publicly on Github when they are ready for feedback.

We are also arranging a full code and mechanics audit, and will publish the results when complete.

If you have questions or comments on the above features, please reach out to us on Telegram or Discord.

Website
Telegram
Discord
Twitter

--

--