How rektpunk/mqboost works
MQBoost is a Python library for jointly estimating multiple quantiles with LightGBM or XGBoost while preventing quantile crossing. The user-facing workflow is to prepare an MQDataset, configure an MQRegressor, fit it, and request quantile predictions. Internally, dataset transformation stacks examples and adds a quantile feature; constraint configuration enforces monotonicity in that feature, while the objective supplies gradients and evaluation metrics to the selected boosting engine. The source index and excerpts support the main runtime links; unsampled behavior is not inferred.
Main entry points: regressor.py MQRegressor · dataset.py MQDataset · base.py Backend types · constraints.py Monotone constraints
Components 9
User API
- MQDataset
src/mqboost/dataset.py - MQRegressor
src/mqboost/regressor.py
Data Preparation
- Stacked data
src/mqboost/dataset.py - Backend types
src/mqboost/base.py
Training Logic
- Monotone constraints
src/mqboost/constraints.py - Quantile objectives
src/mqboost/objective.py
Boosting Backends
- LightGBM
- XGBoost
Other components
- Library user
Connections 9
- Library user → MQDataset: prepares data
README.md - Library user → MQRegressor: configures model
README.md - MQDataset → Stacked data: stacks examples
src/mqboost/dataset.py - MQDataset → Backend types: selects formats
src/mqboost/dataset.py - MQRegressor → MQDataset: fits and predicts
src/mqboost/regressor.py - MQRegressor → Monotone constraints: configures constraints
src/mqboost/regressor.py - MQRegressor → Quantile objectives: creates callbacks
src/mqboost/regressor.py - MQRegressor → LightGBM: trains or predicts
src/mqboost/regressor.py - MQRegressor → XGBoost: trains or predicts
src/mqboost/regressor.py