Software
RiskLabAI provides open-source libraries for quantitative finance and financial machine learning in Python and Julia. Python is the current reference implementation. The Julia library is actively being expanded to narrow the remaining differences in coverage and interface.
The reference implementation: a mature, tested library covering the full method stack, with numba-accelerated hot paths and an extensible component registry.
pip install RiskLabAI
import RiskLabAIAn implementation for numerical and scientific computing. Work is continuing to expand its methods and align its interface with the Python reference.
pkg> add https://github.com/RiskLabAI/RiskLabAI.jl
using RiskLabAIWhat's inside
The libraries implement techniques from Marcos López de Prado's Advances in Financial Machine Learning, Machine Learning for Asset Managers and Causal Factor Investing, alongside original extensions developed at RiskLab.
Financial data science
- •Information-driven bars (tick, volume, dollar, imbalance & run bars)
- •Labeling: triple-barrier, meta-labeling and trend-scanning
- •Sample weights from label uniqueness and concurrency
- •Fractional differentiation (standard & fixed-width FFD)
- •Covariance denoising & detoning (Marčenko–Pastur, NERCOME)
Feature engineering
- •Distance metrics & codependence (KSG mutual information, distance correlation)
- •Optimal clustering (ONC)
- •Feature importance: MDI, MDA, SFI and debiased variants
- •Structural breaks: CUSUM, SADF/GSADF and PELT
- •Entropy and market-microstructure features
Modeling & backtesting
- •Ensemble methods for financial models
- •Purged K-Fold and Combinatorial Purged Cross-Validation
- •Leakage-aware hyper-parameter tuning
- •Backtest statistics, PSR/DSR and Probability of Backtest Overfitting
- •Bet sizing and strategy-risk analysis
Optimization & advanced
- •Hierarchical Risk Parity (HRP)
- •Nested Clustered Optimization (NCO)
- •PCA-based hedging
- •Deep-BSDE solver for financial PDEs
- •High-performance multiprocessing utilities
Learn and explore
Lessons
Mathematical ideas, visual explanations and worked examples.
MIF notebooks
Public notebooks for the Machine Intelligence for Finance lessons.
CIM notebooks
Public notebooks for the Causal Investment Management lessons.
GitHub organization
Source code, issues and releases for all RiskLabAI projects.