lorenzo-stoakes / janus

A toolset for betfair trading.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Janus

Status

I am unlikely to be able to continue development on this project so I offer it up as-is. Some of the code is OK, some of it is pretty rough and ready, but it should be fairly easy to adapt.

Note that I've updated and adapted sajson to parse data in a decimal representation (i.e. no weird rounding errors) as well as to be capable of parsing int64's, which some might find handy.

Description

Janus is a betfair sports trading toolset consisting of the following components:

  • jupiter: Reads a live market data stream and transmits it to other components while writing the data for future analysis.
  • neptune: Converts existing market data JSON to a binary file format for efficient analysis by other components.
  • osiris: GUI giving an insight into what janus is doing and allowing for manual/semi-automatic trading.
  • apollo: Backtesting framework for testing strategies against binary files generated by neptune.
  • mars: Live trading framework that uses jupiter's market data combined with strategy code to execute trades in the market (INCOMPLETE).

It is currently only designed to interact with betfair but is designed to be flexible enough to be portable to other markets.

Building

Install the following shared components:

  • cmake - Meta-build system used to generate ninja build files.
  • Ninja - Fast build system which can be used with cmake.
  • Google test - Unit testing framework.
  • clang format - Auto code linter/formatter.
  • clang tidy - Static analysis tool.
  • cppcheck - Another static analysis tool.
  • Address sanitizer - Memory error detection tool.
  • qt - UI framework, used for osiris.

After that, simply run make in the root directory and binaries should appear in build/.

To run tests run make test, and to run benchmarks run make bench.

3rd-party components

  • sajson - Used and modified under an MIT license.
  • snappy - Fast compressor/decompressor used as a library under a BSD license.
  • mbedtls - Efficient TLS implementation used under an Apache license.
  • spdlog - Fast header-only C++ logging implementation used under an MIT license.

Additional tools

  • benchmark: Run 'make bench' to run benchmarks. Currently this just runs the original sajson benchmarks.
  • checker: This allows checking of the JSON parsing and universe update applying logic. This is compiled as a tool in the binary 'checker'.

License

Janus is MIT licensed meaning you can basically do what you want with it but don't expect any support/warranty.

About

A toolset for betfair trading.

License:MIT License


Languages

Language:C++ 97.4%Language:Hack 1.8%Language:CMake 0.7%Language:Makefile 0.1%Language:Shell 0.0%