https://github.com/pythonlessons/finrock
Reinforcement Learning package for Finance
https://github.com/pythonlessons/finrock
Last synced: 8 months ago
JSON representation
Reinforcement Learning package for Finance
- Host: GitHub
- URL: https://github.com/pythonlessons/finrock
- Owner: pythonlessons
- License: apache-2.0
- Created: 2023-10-23T07:44:54.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-04-08T12:14:30.000Z (over 1 year ago)
- Last Synced: 2025-04-09T10:33:46.750Z (9 months ago)
- Language: Python
- Size: 582 KB
- Stars: 117
- Watchers: 12
- Forks: 29
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# FinRock
Reinforcement Learning package for Finance
# Environment Structure:
### Install requirements:
```
pip install -r requirements.txt
pip install pygame
pip install .
```
### Create sinusoid data:
```
python bin/create_sinusoid_data.py
```
### Train RL (PPO) agent on discrete actions:
```
experiments/training_ppo_sinusoid.py
```
### Test trained agent (Change path to the saved model):
```
experiments/testing_ppo_sinusoid.py
```
### Environment Render:
## Links to YouTube videos:
- [Introduction to FinRock package](https://youtu.be/xU_YJB7vilA)
- [Complete Trading Simulation Backbone](https://youtu.be/1z5geob8Yho)
- [Training RL agent on Sinusoid data](https://youtu.be/JkA4BuYvWyE)
- [Included metrics and indicators into environment](https://youtu.be/bGpBEnKzIdo)
# TODO:
- [ ] Train model on `continuous` actions (control allocation percentage)
- [ ] Add more indicators
- [ ] Add more metrics
- [ ] Add more reward functions
- [ ] Add more scalers
- [ ] Train RL agent on real data
- [ ] Add more RL algorithms
- [ ] Refactor rendering, maybe move to browser?