Skip to content

PFE-Dynamic-Hedging/Vision

Repository files navigation

Vision V2 — Dynamic Collar Hedging SaaS

Projet de Fin d'Études — ECE Paris × EY Paris Stack : FastAPI (Python 3.10+) + React 18 + Vite + TypeScript + PostgreSQL/SQLite License : MIT — Copyright (c) 2025 PFE Dynamic Hedging

À propos

Ce projet est un PFE (Projet de Fin d'Études) développé par cinq étudiants de l'ECE Paris : Robin Denis, Cyril Kfouri, Mohammed Zeddou, Nil Guyot, et Joseph Giraud, supervisé par Alban Kamga, en partenariat avec EY Paris. Objectif : développer une plateforme de couverture dynamique (dynamic hedging) pour compagnies d'assurance et banques, avec moteur de pricing multi-modèles (Black-Scholes, Heston, Hull-White) et stratégies de collar dynamique.

Note traçabilité : ce projet est extrait du framework ELYSIUM (mono-repo interne). Les références SIGIL-NNNN que vous croiserez dans les commentaires / commits sont des identifiants de traçabilité doctrinale (équivalents à des ADR — Architecture Decision Records — numérotés). Elles peuvent être ignorées sans incidence fonctionnelle.

Démarrage ultra-rapide (mode DEV — sans PostgreSQL ni NAS)

# Backend — SQLite mock + auto-seed
python run_dev.py
# → http://127.0.0.1:8000/docs
# → login: dev@ey.com / admin123

# Frontend (autre terminal)
cd frontend
npm install
npm run dev
# → http://localhost:5173

Le mode DEV bascule automatiquement sur SQLite (backend/database/vision_dev.db) via DB_MODE=dev. Aucune configuration PostgreSQL requise.

Pour passer en PROD (PostgreSQL/NAS) : renseigner backend/database/.env avec RDS_HOST et définir DB_MODE=prod.

Modes d'exécution

Mode DB Fichier Activation
DEV SQLite mock vision_dev.db DB_MODE=dev OU RDS_HOST vide
PROD PostgreSQL RDS/NAS DB_MODE=prod + .env rempli

Introduction

[translate:This is a final year project developed by five students from ECE Paris: Robin Denis, Cyril Kfouri, Mohammed Zeddou, Nil Guyot, and Joseph Giraud. The project is supervised by Alban Kamga and conducted in partnership with EY in Paris, aiming to develop a dynamic hedging strategy for insurance companies and banks.]

Project Structure

A brief overview of the organized project architecture:

  • /app: Dash application entry point and utility functions.
  • /models: Pricing models including Heston, Black-Scholes, and Hull-White.
  • /simulation: Monte Carlo simulation engine and path generators.
  • /risk: Risk metrics (VaR, Sharpe Ratio, Drawdown).
  • /database: Database connection and query utilities.
  • /data: Raw and cleaned market data.
  • /notebooks: Analysis notebooks and research.
  • /tests: Unit tests for models, simulations, and risk metrics.

Overview

This project focuses on the development and analysis of dynamic collar hedging strategies using the Heston stochastic volatility model. The goal is to optimize risk management and risk-return trade-offs for portfolios exposed to financial market fluctuations, while addressing regulatory requirements and real-world constraints.

Key Features

  • Heston Model Calibration
    Robust calibration of stochastic volatility parameters based on market implied volatility surfaces to ensure accurate option pricing.

  • Static Collar Implementation
    Construction of a baseline collar strategy with fixed strike prices, selected based on premium budgets and protection thresholds.

  • Dynamic Collar Development
    Adaptive rebalancing of collar strike levels at regular intervals, responding to market changes and risk indicators such as VaR and Tail-VaR.

  • Monte Carlo Simulations & Stochastic Modeling
    Simulation of thousands of paths for underlying assets and stochastic volatility, allowing comprehensive risk and performance assessment.

  • Backtesting & Stress Testing
    Evaluation of hedging strategies on historical crisis scenarios (e.g., 2008 financial crisis, Covid-19 pandemic) to validate robustness and regulatory compliance.

  • Performance Analysis
    Automated reporting of key metrics including VaR, Tail-VaR, maximum drawdown, conditional Sharpe ratio, and strategy comparisons.

  • Cloud Deployment & Interactive Interface
    Fully deployed on Microsoft Azure with an interactive dashboard developed using Python’s Dash library, enabling real-time exploration and analysis of results.

Technologies

  • Full Python software stack for modeling, simulation, and analysis
  • Backend wrapped in a Docker image for portability and ease of deployment
  • Cloud deployment on Microsoft Azure for scalability and reliability
  • Interactive visualization and control via Dash web framework

Installation & Usage

1. Prerequisites

  • Node.js (for the frontend)
  • Python 3.10+ (for the backend)

2. Backend Setup

Navigate to the backend directory, install dependencies, and start the FastAPI server:

cd backend
pip install -r requirements.txt
uvicorn main:app --reload

The API will be available at http://localhost:8000.

3. Frontend Setup

Navigate to the frontend directory, install dependencies, and start the Vite development server:

cd frontend
npm install
npm run dev

The application will be available at http://localhost:5173.

4. Running with Docker (Recommended)

You can run the entire application (Frontend + Backend) using a single Docker command:

docker-compose up --build

This will:

  1. Build the React frontend.
  2. Setup the FastAPI backend.
  3. Serve both on http://localhost:8000.

5. Database Configuration

Ensure you have a .env file in backend/database/.env with the necessary credentials.


This project bridges rigorous quantitative finance modeling with practical implementation, offering a powerful tool for financial institutions to enhance their market risk hedging processes.

About

Dynamic Collar Hedging — PFE ECE Paris × EY Paris. Multi-models pricing (Black-Scholes, Heston, Hull-White, SABR), Greeks engine, backtesting, FastAPI + React.

Topics

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors