Skip to content

Commit

Permalink
readme update
Browse files Browse the repository at this point in the history
  • Loading branch information
liampauling committed Nov 14, 2024
1 parent f3e254a commit 9485ada
Showing 1 changed file with 41 additions and 18 deletions.
59 changes: 41 additions & 18 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,20 @@

![Build Status](https://github.com/betcode-org/flumine/actions/workflows/test.yml/badge.svg) [![Coverage Status](https://coveralls.io/repos/github/liampauling/flumine/badge.svg?branch=master)](https://coveralls.io/github/liampauling/flumine?branch=master) [![PyPI version](https://badge.fury.io/py/flumine.svg)](https://pypi.python.org/pypi/flumine) [![Downloads](https://pepy.tech/badge/flumine)](https://pepy.tech/project/flumine)

Betting trading framework with a focus on:
flumine is an open-source, event-based trading framework for sports betting, designed to simplify the development and execution of betting strategies on betting exchanges. flumine provides efficient handling of data streams, risk management, and execution capabilities.

- simplicity
- modular
- pythonic
- rock-solid
- safe
## overview

![Backtesting Analysis](docs/images/jupyterloggingcontrol-screenshot.png?raw=true "Jupyter Logging Control Screenshot")
- Event-based Execution: Real-time execution of trading strategies based on incoming market events
- Custom Strategy Implementation: Easily define and implement trading strategies
- Risk Management: Integrated risk management tools to monitor and limit exposure
- Modular Design: Easily extendable and customizable components
- Simulation: Simulate strategies/execution using historical data
- Paper Trading: Test strategies in a simulated environment before going live
- Data: Support for market, order and custom streaming data
- Exchanges: Betfair, Betdaq (dev) and Betconnect

Support for market, order and custom streaming data.
![Backtesting Analysis](docs/images/jupyterloggingcontrol-screenshot.png?raw=true "Jupyter Logging Control Screenshot")

[docs](https://betcode-org.github.io/flumine/)

Expand All @@ -39,18 +42,38 @@ flumine requires Python 3.8+
Get started...

```python
import betfairlightweight
from flumine import Flumine, clients

trading = betfairlightweight.APIClient("username")
client = clients.BetfairClient(trading)
from flumine import Flumine, BaseStrategy
from betfairlightweight.filters import streaming_market_filter

framework = Flumine(
client=client,
# Define your strategy here
class MyStrategy(BaseStrategy):
def check_market_book(self, market, market_book) -> bool:
# process_market_book only executed if this returns True
return True

def process_market_book(self, market, market_book):
# Your strategy logic
pass

# Initialize the framework
framework = Flumine()

# Add your strategy to the framework
framework.add_strategy(
MyStrategy(
market_filter=streaming_market_filter(
event_type_ids=["7"],
country_codes=["GB"],
market_types=["WIN"],
)
)
)

# Start the trading framework
framework.run()
```

Example strategy:
Example strategy with logic and order execution:

```python
from flumine import BaseStrategy
Expand Down Expand Up @@ -114,7 +137,7 @@ Run framework:
framework.run()
```

## Features
## features

- Streaming
- Multiple strategies
Expand All @@ -125,7 +148,7 @@ framework.run()
- Event simulation (multi market)
- Middleware and background workers to enable Scores / RaceCard / InPlayService

## Dependencies
## dependencies

flumine relies on these libraries:

Expand Down

0 comments on commit 9485ada

Please sign in to comment.