FairHealth: An Open-Source Python Library for Trustworthy Healthcare AI in Low-Resource Settings
Farjana Yesmin · 2026
Read FairHealth: An Open-Source Python Library for Trustworthy Healthcare AI in Low-Resource Settings by Farjana Yesmin (2026) in the Tower of Babel, a free online library of public-domain works preserved in clean, searchable text. No sign-up. The full text is served as a plain-text file at a predictable URL, where text is present: https://antarctic-labs.com/tower-of-babel/arxiv-2605-08198.txt.
Introduction
Farjana Yesmin presents FairHealth, an open-source Python library. It supports trustworthy medical machine learning in low-resource settings such as Bangladesh. The author argues that current toolkits miss four things at once. They lack fairness audits for biosignals and clinical tables. They lack private federated learning that fits normal workflows. They lack explainability tools for low-bandwidth clinics. And they lack coverage of Global South datasets.
FairHealth is built from five peer-reviewed studies. It ships six modules. They cover federated learning with homomorphic encryption and intersectional fairness metrics. They also cover a hybrid fuzzy-SHAP explainability tool. The library gives clinics in low-income countries one modular place to build fairer, more private health models.
Catalog record
| CREATOR | Farjana Yesmin |
|---|---|
| YEAR | 2026 |
| COLLECTION | PAPERS |
| FORMAT | TXT |
| FILE SIZE | 16 KB |
| LICENSE | http://creativecommons.org/licenses/by/4.0/ |
| RIGHTS | CC BY |
| SOURCE | arXiv |
Source: https://arxiv.org/abs/2605.08198
Browse the full library · About the Tower of Babel
Full text
The opening of the work, from the library's hosted text:
FairHealth: An Open-Source Python Library for Trustworthy Healthcare AI in Low-Resource Settings Farjana Yesmin Abstract We present FairHealth , an open-source Python library that provides a unified, modular framework for trustworthy machine learning in healthcare applications, with particular focus on low-resource and low-income country (LMIC) settings such as Bangladesh. FairHealth addresses four critical gaps in existing healthcare AI toolkits: (1) the absence of integrated fairness auditing for biosignals and clinical tabular data; (2) the lack of privacy-preserving federated learning tools compatible with standard ML workflows; (3) missing explainability tools tailored for low-bandwidth clinical decision support; and (4) no existing toolkit covering Global South healthcare datasets. Built from five peer-reviewed research contributions, FairHealth provides six modules covering federated learning with homomorphic encryption ( fairhealth.federated ), intersectional fairness metrics ( fairhealth.fairness ), hybrid fuzzy-SHAP explainability ( fairhealth.explain ), multilingual dengue triage ( fairhealth.lowresource ), equitable disaster aid allocation ( fairhealth.equity ), and public dataset loaders ( fairhealth.datasets ). All datasets used are publicly available without institutional data use agreements. FairHealth is installable via pip install fairhealth and available at https://github.com/Farjana-Yesmin/fairhealth . 1 Introduction Machine learning has demonstrated substantial promise in healthcare applications [ 9 ] , yet three structural problems limit its real-world impact, particularly in low-resource settings: Demographic bias. Models trained on population-level data frequently underperform for minority demographic groups. For ECG-based myocardial infarction detection, uncorrected models achieve a disparate impact ratio of 0.23 across sex groups — well below the 0.80 threshold considered equitable in algorithmic fairness literature [ 5 ] . Privacy. Healthcare records are legally protected in most jurisdictions. Training ML models across hospitals without sharing raw patient data requires federated learning, yet no existing Python library provides federated learning with cryptographic homomorphic encryption (HE) in a form accessible to healthcare ML researchers. Explainability in low-resource settings. Clinical decision support tools deployed in Bangladesh and similar LMIC settings must operate with minimal connectivity, support local languages, and provide explanations clinicians can interpret without ML expertise. Existing explainability libraries (SHAP, LIME) provide no clinical workflow integration. Existing healthcare AI toolkits such as PyHealth [ 18 ] provide broad coverage of EHR datasets and clinical tasks but do not address fairness auditing, federated learning, or LMIC-specific deployment. FairHealth is designed as a complementary layer: it focuses exclusively on the trustworthiness dimension that PyHealth deliberately leaves open. FairHealth makes the following contributions: 1. A unified, pip-installable Python library with six modules spanning federated learning, fairness, explainability, low-resource tools, equity, and datasets. 2. The first healthcare AI toolkit built entirely on publicly available datasets, requiring no institutional data use agreements. 3. A curated collection of Bangladesh-specific health datasets (maternal health, dengue surveillance, flood PDNA) not available in any existing ML library. 4. Open implementations of five peer-reviewed methods, enabling reproducibility and extension. 2 Related Work Healthcare AI toolkits. PyHealth [ 18 ] is the most comprehensive open-source healthcare ML library, covering 20+ EHR datasets and 33+ clinical models. However, it does not include fairness metrics, federated learning, or differential privacy. FATE [ 12 ] provides federated learning infrastructure but is not healthcare-specific and requires significant engineering overhead. IBM AIF360 [ 2 ] provides fairness metrics but does not integrate with healthcare-specific datasets or federated workflows. FairHealth fills the intersection of these three spaces. Trustworthy AI for LMICs. Healthcare AI research overwhelmingly focuses on datasets from North America and Europe — MIMIC-III, eICU, UK Biobank — which require institutional data use agreements inaccessible to independent researchers. FairHealth is the first toolkit to curate and standardize openly accessible health datasets from South Asia, including Bangladesh maternal health records, dengue surveillance data, and official government flood damage assessments. 3 Library Design 3.1 Architecture FairHealth follows a modular architecture where each submodule corresponds to a distinct research contribution (Figure 1). Modules are loosely coupled: a user can import only fairhealth.fairness without installing the federated learning dependencies. ⬇ pip install fairhealth # core pip install "fairhealth[federated]" # adds TenSEAL for HE pip install "fairhealth[explain]" # adds SHAP, LIME, skfuzzy pip install "fairhealth[all]" # everything 3.2 Design Principles Public data only. Every dataset loader in fairhealth.datasets downloads from publicly available sources. No institutional affiliation or DUA is required. This is a deliberate design choice enabling reproducibility for independent researchers in any country. Paper-anchored modules. Each module is anchored to a specific peer-reviewed publication, with the paper’s key results documented in the module docstring. This enables users to trace every implementation decision to a citable source. Clinical framing. Fairness metrics, explanations, and triage outputs are framed in clinical language rather than ML jargon, following feedback from the 14-clinician validation study documented in [ 14 ] . 4 Modules 4.1 fairhealth.fairness — Fairness Metrics for Biosignals Motivation. ECG-based disease prediction models in wearable systems exhibit significant demographic bias. Evaluated on the PTB-XL dataset [ 11 ] (4,367 records, 20% subsample), an uncorrected CNN classifier achieves disparate impact (DI) of 0.23 across sex groups — far below the equitable threshold of 0.80. After adversarial debiasing using a gradient reversal layer [ 6 ] , DI improves to 0.71 while AUROC is maintained at 0.8472 [ 16 ] . Implementation. The module provides: ⬇ from fairhealth . fairness . metrics import ( demographic_parity_diff , # DPD equalized_odds_diff , # EOD disparate_impact , # DIR intersectional_fairness , # multi-attribute fairness_summary , # all metrics in one call ) # Example: audit ECG model across sex groups dpd = demographic_parity_diff ( y_pred , sensitive = sex_array ) # Returns float in [0,1]; 0 = perfect parity All metrics accept numpy arrays and are model-agnostic. The intersectional_fairness function extends standard parity metrics to multiple simultaneous sensitive attributes (e.g., sex \times age group), addressing the intersectionality gap identified in [ 16 ] . 4.2 fairhealth.explain — Hybrid Fuzzy-XGBoost Explainability Motivation. Black-box models create trust deficits in clinical settings, particularly in resource-constrained environments where clinicians cannot consult ML specialists [ 10 ] . A clinician validation study (N=14 healthcare professionals) demonstrated that 71.4% preferred the hybrid Fuzzy+SHAP explanation over SHAP-only (24%) or score-only (5%) explanations across three clinical cases [ 14 ] . Implementation. The hybrid Fuzzy-XGBoost model achieves 88.67% accuracy (ROC-AUC=0.9703) on the UCI Maternal Health Risk dataset [ 4 ] , outperforming the best baseline (Gradient Boosting: 86.21%) by 2.46 percentage points. The module provides both ante-hoc (fuzzy rules) and post-hoc (SHAP) explanations: ⬇ from fairhealth . explain . fuzzy import get_fired_rules , score_to_label # Ante-hoc explanation: which clinical rules fired? rules = get_fired_rules ( age =42, sbp =145, bs =12.0, hr =88) for r in rules : print ( f "Rule ␣ {r[’id’]}: ␣ {r[’condition’]} ␣ -> ␣ {r[’outcome’]}" ) # Rule 1: High BP AND High Blood Sugar -> HIGH RISK # Rule 5: High Heart Rate AND High BP -> HIGH RISK Fairness analysis revealed equitable regional performance ( \sigma =0.0766 across 8 Bangladesh divisions), with a counter-intuitive negative correlation (r= - 0.876) between healthcare access score and model accuracy — suggesting the model performs best precisely where specialist expertise is most scarce [ 14 ] . 4.3 fairhealth.federated — Privacy-Preserving Federated Learning Motivation. Sharing patient data across hospitals is legally prohibited in most jurisdictions. Standard federated learning (FedAvg [ 7 ] ) transmits gradient updates that remain vulnerable to membership inference