[ARC]: Uniswap V3 NFT as collateral for minting GHO

Summary:

Proposal for a GHO Facilitator which accepts Uniswap V3 NFT (LP positions) as collateral and permits minting and burning GHO tokens when borrowing/repaying and getting liquidated.

Motivation:

Uniswap V3 has a current TVL of $2.83 Billion [1] and growing, most of which is currently illiquid for the liquidity providers. Borrowing/minting GHO against Uniswap V3 LP positions makes the liquidity providers illiquid assets be more liquid, thus bringing deep liquidity to the DeFi ecosystem while also helping AAVE gain significant TVL solving the problem.

Specifications:

According to the GHO technical paper [2], there could be many facilitators participating trustlessly in minting and burning of GHO with their own strategies with the initial facilitator being the AAVE DAO.

The goal is to have a separate facilitator which is responsible for accepting Uniswap V3 NFT as collateral and minting/borrowing GHO against it.

To minimise risk exposure only specific Uniswap LP pairs will be allowed to be supplied, which would be voted from the governance or hardcoded as the assets currently being used to supply in AAVE. The facilitator could have a small bucket capacity of $1M to start off, giving room for experimentation with this model while keeping the protocol stable and safe.

Pricing the V3 LP positions:

Every position on Uniswap V3 is non-fungible and has different pricing which constantly changes based on the range in which liquidity is provided.

It’s important for the pricing to be non-manipulative and simple in order for the model to work. The facilitator will be using chainlink oracles and the periphery contracts of Uniswap to help in calculating the price of the NFT.


token0, token1, tickLower, tickUpper, Liquidity = positionManager.positions(tokenId) [3]

sqrtPriceX96 = pool.slot0() [4]

tick = TickMath.getTickAtSqrtRatio(sqrtPriceX96) [5]

amountA, amountB = LiquidityAmounts.getAmountsForLiquidity(
	TickMath.getSqrtRatioAtTick(tick),
	TickMath.getSqrtRatioAtTick(tickLower),
	TickMath.getSqrtRatioAtTick(tickUpper),
	liquidity
); [6]

Using the Uniswap periphery contracts we can fetch the amounts of token0 and token1 which can be then be used to get the total price of the current position in ETH using chainlink oracle, thus giving the accurate price of the position.

The facilitator will depend on external participants for liquidations in case the value of the position (collateral) falls below due to factors such as impermanent loss on the position or the value of assets LP’ed going down.

Conclusion:

This ARC is meant for the community to discuss on the potential integration of UNI V3 into the AAVE ecosystem, there might be some flaws in the model but looking forward at discussing it with the community :)

LFGHO!

[1] GHO Technical Paper
[2] Defillama
[3] Uniswap positions()
[4] Uniswap slot0
[5] Uniswap getsqrtratioattick()
[6] Uniswap getamountsforliquidity()

7 Likes

We think that allowing Uni V3 as collateral will benefit the liquidity in the Defi ecosystem. Uni V3 has proven itself to be the most efficient AMM. Right now, TVL from big pools (DAI/USDC, WBTC/WETH, USDC/WETH) holds almost $1 Billion, which should increase in the future as the ecosystem develop.

The community will need to discuss more on the risk framework for each market, such as the pool size. In the case of liquidation, normally, the collateral assets will sell off on AMM. This does not decrease the pool size. For LP, we need to unwind the position before selling. Unwinding LPs will decrease the liquidity pool, which means price impact will increase for that market.

We support this idea and want to discuss more on the risks. :slight_smile:

2 Likes

@harshpandey

This is definitely an exciting proposal.

The community has approved Balance LP tokens as collateral in an AMM market (ARC: Staked ATokens, A New Aave Primitive Exploring Vote-Escrow Economies & [ARC] - ERC4626 Strategies as Productive Collateral - #10 by MatthewGraham)

Would it not make sense for @Llamaxyz or @AaveLabs post the above Balancer implementation to expand the AMM market to include Uniswap V3 NFT as collateral in the AMM market? Potentially that AMM market could become a GHO facilitator.

Wonder what @Llamaxyz and @AaveLabs think?

2 Likes

Given Aave is designed to work with ERC-20 tokens and UniV3 are NFTs, hoping to see Gelato G-UNI (now Arrakis) vaults to enable this use case!

4 Likes

A very interesting proposal! We are actively working on this at the moment as a project from members of the Blockchain Student Association at EPFL (very early stage, focussing on the tech). We’d like to submit an official proposal to become GHO faciliators for this kind of use case as for now Aave only supports ERC20 tokens and we don’t think they will be shifting focus off of that for a while. The goal of GHO is to decentralize stablecoin minting to multiple protocols and we aim to do just that as a facilitator with new kinds of collateral with very deep liquidity. We believe the locked potential of UniV3 LPs should be made available for anyone providing liquidity to the UniV3 pools by increasing the capital efficiency of their positions. Additionally our project implements very interesting liquidation mechanisms that are perfectly adapted for the type of collateral we would be handling with regards to UniV3 LP positions. We would love to get more insight from the community as we have almost finished the PoC and will be releasing documentation very soon. LFGHO

8 Likes

This is an exciting proposal, allowing LP’s utilize a position to access liquidity through GHO is an excellent idea.
A significant concern with this arrangement would be the possible risks, therefore I am interested in seeing this proposal fleshed out with the methodology that would be used in determining which Uniswap LP pairs will be allowed to be supplied, before putting the selected pools to a governance vote.

1 Like

It is quite exciting to read this proposal. The virtues of Uni V3 has been gradually recognized over the past year, but the NFT aspect has hindered its integration to the greater DeFi ecosystem. It’s great that Aave community see the opportunity of using Uni V3 LP NFTs as collaterals for GHO.

As some have mentioned, the architecture of facilitators is designed for ERC20, so some technical reworks are needed if Aave is to take a Uni V3 NFT as collateral. Reworks often also means additional risks, which probably is not what a new protocol, such as GHO should take.

An intermediate solution such as Arrakis (formerly G-UNI) can be an appealing option here.

First of all, the non-fungible aspect of Uni V3 positions is already resolved by Arrakis, i.e. no NFT is created when using an Arrakis vault because the vault interacts with Uni V3 vanilla contract directly, and the vault is then tokenized into ERC20.

Second of all, the product has been fully audited and battled tested for more than a year with significant TVL.

Additionally, the fact that no NFT is created in the workflow can mean an easier / better execution when it comes to liquidation.

Would like to hear some feedbacks and see where the discussion goes.

3 Likes

I like the concept of this proposal. Could definitely get a lot of traction going for GHO liquidity via recursive borrowing / providing.

I also provided a solution here using Gamma Strategies. It’s essentially the same concept, except it makes it easier on the infrastructure by using an ERC-20 wrapper around the position. It may also be something that can be used in Aave v3 emode. I also added details regarding risk, audits, and parameters.

Here’s the ARC regarding our proposal. Would love to get the community’s feedback!

1 Like

The risks of introducing LP tokens as collateral is not trivial. Please see gauntlet’s analysis.

TLDR: LP shares as collateral can impose meaningful additional risk beyond simply providing the underlying assets directly as collateral.

Furthermore I have not seen any demand to use LP tokens as collateral. The Aave AMM market has ~$140k LP tokens supplied, a trivial amount.

1 Like

Hey there!

I wanted to mention the Bunni Oracle, a gas-optimized price oracle specifically designed for Bunni LP and Uniswap v3 positions. It’s resilient against flashloan attacks and uses a combination of Chainlink and Uniswap v3 TWAP oracles to accurately compute LP prices. This oracle supports pools where only one token has a Chainlink oracle, broadening its applicability.

I have a couple of questions for you:

  1. Could the Bunni Oracle be useful for Aave and the proposed GHO Facilitator?
  2. Would it be possible to get support from the Aave community and DAO grant to review and audit the Bunni Oracle code?

You can find the contract and repository links below:

I’d love to hear your thoughts on that.

LFGHO!

3 Likes