$npx skillfedfor your agent

fairlearn

A Python package to assess and improve fairness of machine learning models.

Worth itPyPI Artificial IntelligenceReleased Jun 2026209.3K downloads / mopermissive licensePure Python

Decision gist · record as of 2026-08-14

pure-Python wheel — fairlearn-0.14.0-py3-none-any.whl
v0.14.0 · released 2026-06-07 · Python >=3.10 · 5 runtime deps: narwhals, numpy, pandas, scikit-learn, scipy

Yes. Fairlearn is actively maintained, has low install friction, carries a permissive license, and addresses a real need in responsible AI development. It is appropriate for teams building production ML systems that must account for fairness across demographic groups. The package is mature enough for practical use (Alpha status reflects ongoing development, not instability) and has substantial adoption. Install it if fairness assessment or mitigation is part of your model development workflow.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Low install friction with a pure Python wheel and five well-established dependencies (numpy, pandas, scikit-learn, scipy, narwhals).
  • Active maintenance with a release 68 days ago and ongoing repository activity.

License · maintenance · safety

permissive license (permissive) — Permissive license allows unrestricted use, modification, and distribution in commercial and private projects without copyleft obligations.

last release 2026-06-07 (68 days) · last repo commit 2026-08-13 · 2,268 stars

0 known vulnerabilities (OSV.dev, 2026-08-14) · 209,288 downloads/mo, #9,516 on PyPI

Verify before relying

pip install fairlearn

from fairlearn.metrics import MetricFrame
from fairlearn.postprocessing import ThresholdOptimizer
import pandas as pd

# Assess fairness across groups
metric_frame = MetricFrame(metrics={...}, y_true=y, y_pred=y_pred, groups=groups)

# Mitigate unfairness
mitigator = ThresholdOptimizer(estimator=model, constraints='demographic_parity')
mitigator.fit(X_train, y_train, sensitive_features=sensitive_train)
  • Whether narwhals is used as a dataframe abstraction layer or for a specific feature
  • Specific fairness constraint types and mitigation algorithms available beyond the description
  • Performance characteristics when applied to large datasets or high-dimensional sensitive features
Same gist for agents: .md · .json

What it is and what it does

Fairlearn is a Python package for assessing and mitigating fairness in AI systems, focusing on harms that occur when models treat different groups of people unequally. It operationalizes fairness through a group fairness approach, asking which groups are at risk for experiencing harms—either allocation harms (when opportunities or resources are withheld) or quality-of-service harms (when a system works differently for different people). The package provides two main components: metrics for identifying which groups are negatively impacted by a model and comparing models across fairness and accuracy trade-offs, and mitigation algorithms that reduce unfairness across various AI tasks and fairness definitions.

The package depends on standard data science libraries (numpy, pandas, scikit-learn, scipy) and narwhals, and supports Python 3.10 through 3.13. It is actively maintained with a release history dating back to 2018, and the repository shows recent activity. The package acknowledges that fairness is fundamentally a sociotechnical challenge—quantitative metrics alone cannot capture all aspects like justice or due process, and not all fairness metrics can be satisfied simultaneously. Its role is to enable practitioners to assess different mitigation strategies and make trade-offs appropriate to their specific scenario.

Use it for

  • Assess hiring or lending models to detect whether they systematically disadvantage protected groups before deployment
  • Measure and compare fairness metrics across multiple candidate models to inform model selection decisions
  • Apply post-processing mitigation algorithms to adjust model predictions to satisfy fairness constraints like demographic parity
  • Evaluate quality-of-service fairness to ensure a recommendation or classification system works equally well across demographic groups
  • Generate fairness reports for stakeholders to document which groups experience harms and what trade-offs were made

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

Worth it

Yes.

Fairlearn is actively maintained, has low install friction, carries a permissive license, and addresses a real need in responsible AI development. It is appropriate for teams building production ML systems that must account for fairness across demographic groups. The package is mature enough for practical use (Alpha status reflects ongoing development, not instability) and has substantial adoption. Install it if fairness assessment or mitigation is part of your model development workflow.

Install

fairlearn on PyPI

Before you install

Low install friction with a pure Python wheel and five well-established dependencies (numpy, pandas, scikit-learn, scipy, narwhals). Active maintenance with a release 68 days ago and ongoing repository activity.

License in practice

Permissive license allows unrestricted use, modification, and distribution in commercial and private projects without copyleft obligations.

Quickstart

pip install fairlearn

from fairlearn.metrics import MetricFrame
from fairlearn.postprocessing import ThresholdOptimizer
import pandas as pd

# Assess fairness across groups
metric_frame = MetricFrame(metrics={...}, y_true=y, y_pred=y_pred, groups=groups)

# Mitigate unfairness
mitigator = ThresholdOptimizer(estimator=model, constraints='demographic_parity')
mitigator.fit(X_train, y_train, sensitive_features=sensitive_train)

Verify before relying

  • Whether narwhals is used as a dataframe abstraction layer or for a specific feature
  • Specific fairness constraint types and mitigation algorithms available beyond the description
  • Performance characteristics when applied to large datasets or high-dimensional sensitive features

Package facts

Licensepermissive license permissive
Python supportSupports the current Python release >=3.10
Install frictionLow. Pure-Python wheel
Runtime dependencies
5 packages
narwhalsnumpypandasscikit-learnscipy
MaintenanceActively maintained 68 days since the last release
Last repo commit
First released
Downloads209,288 / month, #9,516 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14
Classifiers
Development Status :: 3 - AlphaLicense :: OSI Approved :: MIT LicenseOperating System :: OS IndependentProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13

Evidence: fairlearn-0.14.0-py3-none-any.whl

Tags

Capabilities
machine learning fairness assessmentbias detection and mitigationgroup fairness metricsalgorithmic fairness toolsmodel fairness evaluationAI bias mitigationfairness constraints for ML
Topics
fairness-biasmodel-evaluationresponsible-ai

Let your AI agent find packages like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.

wish › “machine learning fairness assessment”

  • fairlearnFairlearn assesses and mitigates fairness issues in machine learning…
  • interpret-coreTrains interpretable machine learning models and explains blackbox…
  • interpretInterpretML provides interpretable machine learning models and…

Give your agent the search over MCP, or paste the wish link into any chat.

More Artificial Intelligence packages

litellm With conditions
PyPI · Artificial Intelligence · released Aug 2026

LiteLLM provides a unified Python interface to call 100+ LLM providers (OpenAI, Anthropic, Gemini, Bedrock, Azure, and others) using OpenAI-compatible API format, available as both a Python SDK and a self-hosted AI Gateway proxy server.

Install it if you need to work with multiple LLM providers or want to centralize LLM routing in your organization.

MITcompiled wheel
682.8Mdownloads / mo
huggingface-hub Worth it
PyPI · Artificial Intelligence · released Aug 2026

Client library and CLI tool for downloading, uploading, and managing models, datasets, and repositories on the Hugging Face Hub platform.

Install it if you work with Hugging Face Hub models or datasets.

Apache-2.0pure Python · 3.10.0+
442.4Mdownloads / mo
langchain Worth it
PyPI · Python Modules · released Aug 2026

LangChain provides a framework for building agents and LLM-powered applications by composing language models, tools, and memory through a unified API that abstracts over multiple model providers.

MITpure Python
315.4Mdownloads / mo
hf-xet With conditions
PyPI · Artificial Intelligence · released Aug 2026

hf-xet provides chunk-based deduplication and efficient file transfer for the Hugging Face Hub, enabling faster uploads and downloads of large files with local disk caching.

Apache-2.0compiled wheel · 3.8+
258.4Mdownloads / mo
tokenizers Worth it
PyPI · Artificial Intelligence · released Apr 2026

Tokenizers converts raw text into token sequences for NLP models, with support for training custom vocabularies and using pre-built tokenizers (BPE, WordPiece) optimized for speed via Rust.

Apache-2.0compiled wheel · 3.10+
222.9Mdownloads / mo
transformers Worth it
PyPI · Artificial Intelligence · released Aug 2026

Transformers provides a unified framework for loading, fine-tuning, and running state-of-the-art pretrained models across text, vision, audio, video, and multimodal tasks using PyTorch, JAX, or TensorFlow.

Install it if you need to run or train any transformer-based model for NLP, vision, audio, or multimodal tasks.

permissive licensepure Python · 3.10.0+
186.6Mdownloads / mo

See also empirical-calibration · arthur-client · tslearn · pyannote-metrics · pyiqa · moocore · imagededup · river · learnosity-sdk · psmpy

Further reading