https://github.com/pablodieaco/quant-drl-web
quant-drl-web is a Streamlit-based interactive dashboard for visualizing and interacting with DRL-driven portfolio management models.
https://github.com/pablodieaco/quant-drl-web
deep-reinforcement-learning quantitative-finance quantitative-trading streamlit yfinance
Last synced: about 2 months ago
JSON representation
quant-drl-web is a Streamlit-based interactive dashboard for visualizing and interacting with DRL-driven portfolio management models.
- Host: GitHub
- URL: https://github.com/pablodieaco/quant-drl-web
- Owner: pablodieaco
- License: mit
- Created: 2025-04-03T16:59:57.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2025-04-16T11:40:26.000Z (about 1 year ago)
- Last Synced: 2025-05-25T06:14:00.129Z (about 1 year ago)
- Topics: deep-reinforcement-learning, quantitative-finance, quantitative-trading, streamlit, yfinance
- Language: Python
- Homepage:
- Size: 17.4 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ๐ quant-drl-web
**quant-drl-web** is a Streamlit-based interactive dashboard for visualizing, evaluating, and simulating Deep Reinforcement Learning (DRL) models applied to portfolio management.
It serves as the frontend for the [`quant-drl-core`](https://github.com/pablodieaco/quant-drl-core) research framework, providing a user-friendly interface for financial data exploration, model comparison, and portfolio decision analysis.
> ๐ Developed as part of my **Final Degree Project (TFG)** in the **Double Degree in Mathematics and Computer Engineering** at the **University of Seville**.
---
## โจ Features
- ๐ **Model evaluation & metrics explorer**
- ๐ก **Portfolio simulation and strategy testing**
- ๐ง **Deep RL integration** (PPO, SAC)
- ๐ **Database-backed** via PostgreSQL
- ๐จ **Streamlit** multipage navigation
- ๐ณ Docker & Docker Compose for deployment
- ๐ Examples and demo models included
---
## ๐ผ๏ธ App Preview
### ๐ Financial Information
An overview of each company's economic and financial data.

---
### ๐ Evaluations
#### ๐งช Batch Evaluation
Evaluate multiple simulation at once, and analyse the performance of your model.

#### ๐ Individual Evaluation
Dive deep into the analysis of a single simulation.

---
### ๐ Metrics Analysis
Explore key performance indicators of your trained models.

## ๐ Project Structure
```bash
quant-drl-web/
โโโ web/ # Streamlit app (modular)
โ โโโ app.py # Main entry point
โ โโโ pages/ # UI Pages (Streamlit multipage)
โ โโโ commons/ # Session & layout
โ โโโ db/ # DB scripts and seeders
โโโ examples/ # Sample models and evaluation results
โ โโโ models/ # Pretrained DRL models
โ โโโ results/ # evaluation_results.csv
โโโ docker-compose.yml # Launch web + PostgreSQL
โโโ Dockerfile # Web app container
โโโ build.sh # Script to copy core + build
โโโ requirements.txt # Python dependencies
```
---
## โ๏ธ Requirements
- Docker & Docker Compose
- Python 3.10+ (optional for local runs)
- `quant-drl-core` available locally (used during build) (TODO: It will not be necessary in future releases)
---
## ๐ Quickstart
### 1. Clone the repo
```bash
git clone https://github.com/pablodieaco/quant-drl-web.git
cd quant-drl-web
```
### 2. Create a `.env` file using the sample file `.env.sample`
```bash
cp .env.sample .env
```
Then edit the `.env` file:
```env
POSTGRES_USER=
POSTGRES_PASSWORD=
POSTGRES_DB=
RESULTS_CSV=examples/results/evaluation_results.csv
MODEL_HIERARCHY=examples/models/metadata/hierarchy.json
```
### 3. Run using the latest Docker image (recommended)
This will pull the latest published image from GitHub Container Registry and run the app.
```bash
make run
```
Once running, the app will be available at http://localhost:8501
### 4. Local development mode (with local quant-drl-core)
If you're modifying `quant-drl-web` and want to test changes locally:
```bash
make build
make run-local
```
This will
- Build the Docker image with your local changes
- Launch the app using the new built image
Once running, the app will also be available at http://localhost:8501
---
## ๐งช Example Models
Weโve included pretrained models and example evaluation results inside the `examples/` folder:
- `examples/models/` โ PPO and SAC agents
- `examples/results/evaluation_results.csv`โ model evaluation scores
---
## ๐ง About this project
This dashboard is part of a broader research framework:
๐ Check out `quant-drl-core` for:
- DRL training pipelines (PPO, SAC)
- Custom Gym environments
- Evaluation and visualization logic
- Experiment reproducibility
## ๐ License
This project is licensed under the **MIT License**.
See the [LICENSE](./LICENSE) file for details.
---
## ๐โโ๏ธ Author
Made with โค๏ธ by **Pablo Diego Acosta**
- ๐ผ LinkedIn: [linkedin.com/in/pablodiegoacosta](https://www.linkedin.com/in/pablodiegoacosta)
---
## โจ Todo / Ideas
- [ ] Embed live charts from financial APIs
- [ ] Auto-refresh evaluation dashboard with scheduled updates
- [ ] Live inference from trained DRL models
- [ ] Add functionalities for managing saved portfolios