sumasamurai / predictor-challenge

MIT License
3 stars 5 forks source link

Research Uniswap V4 #19

Open sumasamurai opened 9 months ago

sumasamurai commented 9 months ago

Research Uniswap V4 and the functionality of creating a liquidity pool for each new round will likely require some time and practical testing. Here's how you can approach this task:

  1. Study Uniswap V4: The first step is to study Uniswap V4 and its documentation. A fundamental understanding of how Uniswap V4 works and how to create liquidity pools is necessary for further exploration.

  2. Create a Liquidity Pool: Create your own test project to explore creating a liquidity pool using Uniswap V4. Try to create a pool, add assets, and configure pool parameters.

  3. Practical Testing: Launch several test rounds, each of which creates a new liquidity pool. Evaluate how long it takes to create a pool, how easy it is to configure parameters, and how the functionality expands for each new round.

  4. Distributing Winnings: Develop a mechanism for distributing winnings to each winner. Keep in mind that Uniswap V4 may require you to develop your own smart contract to manage winnings.

  5. Performance Evaluation: Assess the performance of the system, especially as the number of rounds and pool creations increases. Check how convenient it is to manage all this functionality.

  6. Documentation: It's important to thoroughly document all the steps, results, and issues encountered during your research.

  7. Conclusions and Recommendations: Based on your research, draw conclusions and provide recommendations for using Uniswap V4 to create liquidity pools for each new round.

luloxi commented 9 months ago

I wanted to share some links I've found and think may be useful:

Introduction:

V4 is not deployed yet, but there is a testnet called Conduit Testnet where we can deploy Uniswap v4 and deploy hooks

v4-core and tutorials on Uniswap V4 Documentation are made using Foundry (maybe we should consider switching from Hardhat to Foundry)

If we're gonna keep using Hardhat, we should set it up for EIP 1153 opcodes

I've watched and coded along this lesson, although I don't think I've grasped it all the math yet:

Here are some links I'm thinking of exploring next:

sumasamurai commented 9 months ago

Thank you, we have received answers to many questions and I have checked various things based on them.

Is it possible to add liquidity to the pool for the totalAmount in the closeRound function?