{"id":13711790,"url":"https://github.com/primitivefinance/rmms-py","last_synced_at":"2025-07-10T13:32:54.561Z","repository":{"id":41545821,"uuid":"362112876","full_name":"primitivefinance/rmms-py","owner":"primitivefinance","description":"Python simulator to test implementation of the RMMS paper results.","archived":false,"fork":false,"pushed_at":"2022-04-27T16:39:12.000Z","size":849,"stargazers_count":56,"open_issues_count":0,"forks_count":13,"subscribers_count":10,"default_branch":"master","last_synced_at":"2025-07-06T21:55:08.155Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/primitivefinance.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":"CITATION.cff","codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2021-04-27T12:57:59.000Z","updated_at":"2024-11-23T13:16:52.000Z","dependencies_parsed_at":"2022-08-10T03:10:25.333Z","dependency_job_id":null,"html_url":"https://github.com/primitivefinance/rmms-py","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/primitivefinance/rmms-py","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/primitivefinance%2Frmms-py","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/primitivefinance%2Frmms-py/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/primitivefinance%2Frmms-py/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/primitivefinance%2Frmms-py/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/primitivefinance","download_url":"https://codeload.github.com/primitivefinance/rmms-py/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/primitivefinance%2Frmms-py/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264585371,"owners_count":23632646,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-02T23:01:11.636Z","updated_at":"2025-07-10T13:32:53.078Z","avatar_url":"https://github.com/primitivefinance.png","language":"Python","funding_links":[],"categories":["Projects"],"sub_categories":[],"readme":"# RMMS simulations\n\nThis project is intended to investigate the replication of payoffs using custom Constant Function Market Makers (CFMMs) in the spirit of the 2021 paper from [Angeris, Evans and Chitra.](https://stanford.edu/~guillean/papers/rmms.pdf) For now it only focuses on the Covered Call replication. The project is organized as follows:\n\n``modules`` contains all the simulation toolkit. In particular:\n\n- ``modules/arb.py`` implements the optimal arbitrage logic.\n- ``modules/cfmm.py`` implements the actual CFMM pool logic.\n- ``modules/utils.py`` contains a number of utility functions (math, geometric brownian motion generation).\n- ``modules/simulate.py`` is simply the function used to run an individual simulation.\n- ``modules/optimize_fee.py`` contains the logic required to find the optimal fee given some market and pool parameters.\n\n``simulation.py`` is a script used to run individual simulations whose parameters are specified in the ``config.ini`` file.\n\n``optimal_fees_parallel.py`` is a script to run an actual fee optimization routine for a prescribed parameter space (to be specified within the script itself).\n\n``optimal_fees_visualization.py`` is a script that generates a visual representation of the output of a fee optimization routine.\n\n``error_distribution.py`` is a script to plot the distribution of errors given some market and pool parameters for different fee regimes.\n\nAll the different functions and design choices are documented in a separate document.\n\n## Requirements\n\n``pip install numpy, pip install scipy, pip install matplotlib, pip install joblib``\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fprimitivefinance%2Frmms-py","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fprimitivefinance%2Frmms-py","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fprimitivefinance%2Frmms-py/lists"}