Example Python code for running the mango-explorer marketmaker

Overview

๐Ÿฅญ Mango Explorer

๐Ÿ“– Introduction

This guide will show you how to load and run a customisable marketmaker that runs on Mango Markets using the mango-explorer library.

There are plenty of ways to do this. This document shows only one possible approach.

๐Ÿชœ Prerequisites

  1. Installation and Dependencies - shows you how to set up a Python virtual environment and pip install mango-explorer. (Optional - feel free to skip if you're comfortable doing this on your own.)
  2. Devnet Wallet Creation - shows you how to create a Solana Keypair file and prepare it for devnet with some devnet SOL and devnet USDC. (Optional - feel free to skip if you're comfortable doing this on your own.)
  3. Devnet Mango Account Creation - shows you how to create a Mango Account on devnet and deposit devnet USDC into it. (Optional - feel free to skip if you're comfortable doing this on your own.)
  4. Code Walkthrough - takes you through the code in marketmaker.py line by line. (Optional - feel free to skip if you're comfortable doing this on your own.)

๐Ÿƒ Running the Marketmaker

That's a lot of setup to get you to this stage but some of it was skippable if you already had a Python venv, Solana wallet and a Mango Account. And if you didn't, you do now!

You can now start the marketmaker by running:

python marketmaker.py

No parameters are required - all the parameters and options for running the marketmaker are in the code.

When you run it you should see a lot of output, with large 'pulses' of output every 10 seconds or so. (You can tweak the volume of logging and the pulse interval in the code.)

๐Ÿ›ต Next Steps

If you've got this far, congratulations! You're now running a marketmaker on devnet.

Things you can do now:

  • experiment with different parameters to see how that changes the orders.
  • experiment with different Elements to filter orders or bias prices or quantities in certain circumstances. (Want to shift the prices in your orders if you've built up too much inventory? Can do!)
  • create your own custom Elements to change order quantities or prices based on new criteria. (Want to widen the spread when volatility is high? Create a custom Element!)

๐Ÿฆฎ Support

๐Ÿฅญ Mango Markets support is available at: Docs | Discord | Twitter | Github | Email

Owner
Blockworks Foundation
Blockworks Foundation
Build AGNOS, the operating system for your comma three

agnos-builder This is the tool to build AGNOS, our Ubuntu based OS. AGNOS runs on the comma three devkit. NOTE: the edk2_tici and agnos-firmare submod

comma.ai 21 Dec 24, 2022
Explorative Data Analysis Guidelines

Explorative Data Analysis Get data into a usable format! Find out if the following predictive modeling phase will be successful! Combine everything in

Florian Rohrer 18 Dec 26, 2022
An introduction course for Python provided by VetsInTech

Introduction to Python This is an introduction course for Python provided by VetsInTech. For every "boot camp", there usually is a pre-req, but becaus

Vets In Tech 2 Dec 02, 2021
MkDocs plugin for setting revision date from git per markdown file

mkdocs-git-revision-date-plugin MkDocs plugin that displays the last revision date of the current page of the documentation based on Git. The revision

Terry Zhao 48 Jan 06, 2023
Searches a document for hash tags. Support multiple natural languages. Works in various contexts.

ht-getter Searches a document for hash tags. Supports multiple natural languages. Works in various contexts. This package uses a non-regex approach an

Rairye 1 Mar 01, 2022
Type hints support for the Sphinx autodoc extension

sphinx-autodoc-typehints This extension allows you to use Python 3 annotations for documenting acceptable argument types and return value types of fun

Alex Grรถnholm 462 Dec 29, 2022
30 days of Python programming challenge is a step-by-step guide to learn the Python programming language in 30 days

30 days of Python programming challenge is a step-by-step guide to learn the Python programming language in 30 days. This challenge may take more than100 days, follow your own pace.

Asabeneh 17.7k Jan 07, 2023
This is the repository that includes the code material for the ESweek 2021 for the Education Class Lecture A3 "Learn to Drive (and Race!) Autonomous Vehicles"

ESweek2021_educationclassA3 This is the repository that includes the code material for the ESweek 2021 for the Education Class Lecture A3 "Learn to Dr

F1TENTH Autonomous Racing Community 29 Dec 06, 2022
Grokking the Object Oriented Design Interview

Grokking the Object Oriented Design Interview

Tusamma Sal Sabil 2.6k Jan 08, 2023
The Python Dict that's better than heroin.

addict addict is a Python module that gives you dictionaries whose values are both gettable and settable using attributes, in addition to standard ite

Mats Julian Olsen 2.3k Dec 22, 2022
A Power BI/Google Studio Dashboard to analyze previous OTC CatchUps

OTC CatchUp Dashboard A Power BI/Google Studio dashboard analyzing OTC CatchUps. File Contents * โ”œโ”€โ”€โ”€data โ”œโ”€โ”€โ”€old summaries โ”€โ”€โ”€ *.md โ”œ

11 Oct 30, 2022
30 Days of google cloud leaderboard website

30 Days of Cloud Leaderboard This is a leaderboard for the students of Thapar, Patiala who are participating in the 2021 30 days of Google Cloud Platf

Developer Student Clubs TIET 13 Aug 25, 2022
Project documentation with Markdown.

MkDocs Project documentation with Markdown. View the MkDocs documentation. Project release notes. Visit the MkDocs wiki for community resources, inclu

MkDocs 15.6k Jan 02, 2023
Code and pre-trained models for "ReasonBert: Pre-trained to Reason with Distant Supervision", EMNLP'2021

ReasonBERT Code and pre-trained models for ReasonBert: Pre-trained to Reason with Distant Supervision, EMNLP'2021 Pretrained Models The pretrained mod

SunLab-OSU 29 Dec 19, 2022
A simple tutorial to get you started with Discord and it's Python API

Hello there Feel free to fork and star, open issues if there are typos or you have a doubt. I decided to make this post because as a newbie I never fo

Sachit 1 Nov 01, 2021
MonsterManualPlus - An advanced monster manual for Tower of the Sorcerer.

Monster Manual + This is an advanced monster manual for Tower of the Sorcerer mods. Users can get a plenty of extra imformation for decision making wh

Yifan Zhou 1 Jan 01, 2022
Flask-Rebar combines flask, marshmallow, and swagger for robust REST services.

Flask-Rebar Flask-Rebar combines flask, marshmallow, and swagger for robust REST services. Features Request and Response Validation - Flask-Rebar reli

PlanGrid 223 Dec 19, 2022
Pystm32ai - A Python wrapper for the stm32ai command-line tool

PySTM32.AI A python wrapper for the stm32ai command-line tool to analyse deep le

Thibaut Vercueil 5 Jul 28, 2022
NetBox plugin for BGP related objects documentation

Netbox BGP Plugin Netbox plugin for BGP related objects documentation. Compatibility This plugin in compatible with NetBox 2.10 and later. Installatio

Nikolay Yuzefovich 133 Dec 27, 2022
Literate-style documentation generator.

888888b. 888 Y88b 888 888 888 d88P 888 888 .d8888b .d8888b .d88b. 8888888P" 888 888 d88P" d88P" d88""88b 888 888 888

Pycco 808 Dec 27, 2022