MCGrad is a Python library designed to address the challenge of multicalibration in machine learning models, particularly where models may appear calibrated on average but perform poorly for specific data segments. The tool aims to improve the calibration quality of predictions across a wide range of segments, helping to ensure that model outputs are reliable not just overall, but within subgroups defined by features such as country, content type, or age.
Key features of MCGrad include a state-of-the-art approach to multicalibration, a user-friendly interface that allows users to pass features directly without needing to define segments manually, and high scalability suitable for web-scale datasets. The tool is designed for efficient training and low inference overhead, making it practical for large-scale applications. It also incorporates safety measures such as likelihood-improving updates and validation-based early stopping to help prevent overfitting or degraded performance during calibration.
MCGrad can be installed via pip and integrated into Python workflows. Users prepare their data in a pandas DataFrame, specifying base model predictions, ground truth labels, and attributes that define segments. The library provides methods for fitting the calibration model and generating multicalibrated predictions on new data, supporting both categorical and numerical features for segment definition.
The tool is attributed to Meta Platforms, Inc. according to its copyright notice.
MCGrad is an Other data science & ML project. It focuses on improving the calibration of machine learning models across multiple data segments for more reliable predictions. It is built as an open-source project for machine learning engineers and data scientists. MCGrad is open source under the MIT license. It runs on the web and the command line, and it can be self-hosted.
MCGrad first shipped in 2026. Development happens publicly on GitHub with 36 stars and 47 commits in the last 90 days. Among its 5 catalogued features are multicalibration, segmented calibration, and Python API.
Summary written by a language model from the project’s public pages.
What PulseGate has recorded for this listing
Same category — not a similarity match