Giter VIP home page Giter VIP logo

chainflip-uniswapv3-python's Introduction

Pythonized Uniswap V3

This repository contains a pythonized version of the popular Uniswap V3 AMM.

The goal of this model is not to optimize the original design but rather to mirror the code and allow for easy debugging and further development. Therefore, only a few abstractions have been made for a more comprehensible and simplified model - e.g. using Python dictionary features instead of the BitMap library in Solidity. Moreover, some features that are not essential to the market making logic have been removed - most noticeably the flash and oracle functionality.

This implementation achieves a very high-accuracy model of the original Solidity code and it also includes the full testset.

Dependencies

Setup

First, ensure you have Poetry installed.

git clone [email protected]:chainflip-io/python-uniswap-v3.git
cd python-uniswap-v3
poetry shell
poetry install

Running Tests

Pytest is used to run the tests.

pytest
pytest <testfile-name>::<test-name>

Package Installation

To be able to easily use this code outside the repository itself, it has been included in a Python package that can be easily installed via any Python package manager.

Via Pip:

pip install -i https://pypi.org/simple/ uniswapV3Python

Via Poetry:

poetry add uniswapV3Python

chainflip-uniswapv3-python's People

Contributors

albert-llimos avatar miz1choobi avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.