Skip to main content

bancor3


Bancor Simulator

PyPI bancorml-0.1.0-py3-none-any.whl package in bancorml@Release feed in Azure Artifacts PyPI version Documentation Status


Bancor Simulator is an open-source python package developed by the Bancor Research Team. It aims to assist the design, testing, and validation of Bancor v3 tokenomics.

See official documentation for complete details.

Warning: The docs are a work in progress with potentially broken links, unfinished sections, and a non-exhuastive overview of commands and example usage. Moreover, the entirety of the codebase and documentation is subject to change without warning.


Introduction

All state transition functions and accompanying data structures described in the product specification BIP15: Proposing Bancor 3 are the core system level operations of this library.

Organization

This is the project directory structure:

bancor_analytics/            <------- Tableau Dashboard Project
bancor_emulator/             <------- Solidity Emulation Project
bancor_simulator/            <------- ** Spec & Simulation Project **
├── v3/                      <------- Current Version
│   └── simulation/          <------- Agent-based simulation module
│   │     └── agents.py      <------- Mesa Agent-based implementations of the Bancor protocol.
│   │     └── batch_run.py   <------- Script used to perform a parameter sweep.
│   │     └── model.py       <------- Main Bancor Simulation module interface.
│   │     └── random_walk.py <------- Generalized behavior for random walking
│   │     └── run.py         <------- Runs the simulation server with browser-based UI
│   │     └── server.py      <------- Configures the browser-based interface.
│   │     └── utils.py       <------- Misc utility functions
│   │ 
│   └── spec/                <------- State transition functions and data structures described in BIP15.
│         └── actions.py     <------- Deposit, trade, & withdrawal algorithm logic.
│         └── emulation.py   <------- Verifies solidity result parity.
│         └── network.py     <------- Main BancorNetwork application interface.
│         └── rewards.py     <------- Autocompounding and standard rewards logic.
│         └── state.py       <------- State variables, constants, data structures, and CRUD interfaces.
│         └── utils.py       <------- Misc utility functions
│ 
└── main.py                  <------- Application

** These docs apply.

Notation

Code snippets appearing in this style are to be interpreted as Python 3 code.

Formatting & Style

Code is formatted according to PEP8, which is the official Python style guide. In order to overcome the burden on the developers to fix formatting, we use Black which reports on format errors and automatically fixes them.

Project setup

If you don't already have one, create a virtualenv using these instructions

Install

Bancor3 Simulation is available for Python 3.6+

To install using pypi, run this command:

$ pip install bancor-simulator

Documentation

In addition to the codebase, this repository holds the Jupyter Book source for Bancor v3 Simulation: A hands-on demo of features described in BIP15: Proposing Bancor 3.

To make a change to the jupyter book and update:

  1. Get your copy of this repository:

    git clone https://github.com/bancorprotocol/simulator-v3
    

Build and preview the jupyter-book text locally

To build locally, pip install -r requirements.txt and then jupyter-book build .

Follow the build instructions on the Jupyter Book guide. The guide has information for how to use the Jupyter Book CLI to build this book. You can find the Jupyter Book build instructions here.

Build and preview the text locally

To build locally, pip install -r requirements.txt and then jupyter-book build .

Follow the build instructions on the Jupyter Book guide. The guide has information for how to use the Jupyter Book CLI to build this book. You can find the Jupyter Book build instructions here.

Metadata

Release files for bancor-simulator 1.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for bancor-simulator 1.1.0
File Size Uploaded Provenance
bancor_simulator-1.1.0.tar.gz 76.3 kB Without provenance Details

Release files / bancor_simulator-1.1.0.tar.gz

Download URL bancor_simulator-1.1.0.tar.gz
Size 76.3 kB
Tags Source
SHA-256 checksum
How to use checksums
00d91c0e7edb826568724cbe45f933aa36c0fd238eb28cbdfbe2137ab1d16d7e
BLAKE2b-256 checksum
How to use checksums
d0e9048987d5ce3ff007591fb2514ab65bc34cfbc1d3e2cdf810d1aaac73b377
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.8.0 pkginfo/1.8.2 readme-renderer/33.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.2 keyring/21.8.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.7

Security for bancor-simulator 1.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Release history Release notifications | RSS feed

This release

1.1.0 This release

1 release file No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page