skillfed

ngboost

Library for probabilistic predictions via gradient boosting.

ngboost v0.5.11 179.3K downloads/30d#10,175 on PyPI1,888
Permissive license Apache-2.0 Active released

What it is and what it does

NGBoost is a gradient boosting library that outputs full probability distributions for each prediction rather than single point estimates. Built on scikit-learn, it implements the Natural Gradient Boosting algorithm, allowing you to quantify prediction uncertainty and choose among different distributions and scoring rules to match your problem. The library depends on numpy, scipy, scikit-learn, matplotlib, tqdm, lifelines, and sympy.

You use it like a standard estimator: fit on training data, then call predict() for point estimates or pred_dist() to get the full predictive distribution at each test point. This makes it useful when you need not just a prediction but also a measure of confidence or uncertainty around that prediction, such as in risk-sensitive applications or when building prediction intervals.

Use it for:

  • Build regression models that output prediction intervals and uncertainty estimates alongside point forecasts.
  • Quantify model confidence in high-stakes domains like medical or financial prediction where uncertainty matters.
  • Compare different probability distributions and scoring rules for the same dataset to find the best fit.
  • Extend NGBoost with custom distributions or scoring rules for domain-specific probabilistic prediction tasks.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

NGBoost implements Natural Gradient Boosting for probabilistic prediction, built on scikit-learn, enabling regression models that output full probability distributions rather than point estimates.

Yes. NGBoost is actively maintained, has low install friction, carries a permissive Apache 2.0 license, and fills a clear niche: probabilistic prediction with uncertainty quantification. Install it if you need prediction intervals, distribution outputs, or uncertainty estimates alongside your regression predictions.

Install

ngboost on PyPI

pip

pip install ngboost

uv

uv add ngboost

poetry

poetry add ngboost

Installing ngboost

Before you install

Low friction: pure Python wheel, active maintenance (last commit 2026-07-01), and supports current Python versions (3.9–3.13). Dependencies are all standard scientific stack (scikit-learn, numpy, scipy, matplotlib, tqdm, lifelines, sympy).

License in practice

Apache License 2.0 is permissive; you can use, modify, and distribute ngboost freely in commercial and private projects with minimal restrictions.

Quickstart

pip install ngboost

from ngboost import NGBRegressor

ngb = NGBRegressor().fit(X_train, Y_train)
Y_preds = ngb.predict(X_test)
Y_dists = ngb.pred_dist(X_test)

Verify before relying

  • Whether NGBoost supports classification tasks in addition to regression.
  • Performance characteristics and scalability limits on large datasets.
  • Availability and ease of adding custom distributions or scoring rules beyond built-in options.

Package facts

License Apache-2.0 (permissive)
Python support supports the current Python release (<3.15,>=3.9)
Install friction low — pure-Python wheel
Runtime dependencies 7 — scikit-learn, numpy, scipy, tqdm, lifelines, sympy, matplotlib
Maintenance actively maintained — 49 days since the last release
Last repo commit
First released
Downloads 179,315/month — #10,175 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: ngboost-0.5.11-py3-none-any.whl

License :: OSI Approved :: Apache Software LicenseOperating System :: OS IndependentProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.9

Tags

probabilistic gradient boostingnatural gradient boostinguncertainty quantification regressiondistribution predictionngboost probabilisticgradient boosting with distributionsprediction intervals
probabilistic-mluncertainty-quantificationgradient-boosting

More Artificial Intelligence packages