--- license: mit metrics: - accuracy - roc_auc - demographic_parity - equalized_odds - equal_opportunity pipeline_tag: tabular-classification tags: - tabular - fairness - TFM base_model: - FairTFM-0.7-epoch_10000.pt --- # Model Card: FairTFM ## Model Description FairTFM is a **tabular foundation model** for fairness-aware, in-context prediction on tabular data. It is a transformer-based architecture (built on components from [nanoTabPFN](https://github.com/automl/TFM-Playground)) that jointly embeds features, targets, and a **sensitive attribute** via a dedicated `SensitiveAttributeEncoder`, then predicts labels for unseen (test) rows conditioned on a small set of in-context training rows — no per-dataset fine-tuning required. - **Architecture:** Transformer encoder stack with separate feature/target/sensitive-attribute embeddings, decoded to per-row logits. Memory-chunked attention/MLP for efficient inference. - **Task type:** Binary classification with a fairness objective over a specified sensitive attribute. - **Release type:** Inference-only. ### Model Sources - **Repository:** https://github.com/patrikken/FairTFM-inference - **Paper:** https://openreview.net/forum?id=ajIvCEbadL ## Checkpoints Four checkpoints are provided, corresponding to different fairness-regularization strengths (λ) used to trace a fairness/accuracy Pareto front: **λ = 0.7, 1.0, 10, 25**. Higher λ trades predictive performance for lower fairness-metric disparity. ## Intended Use - Fair classification on tabular datasets where a sensitive attribute (e.g., sex, race, age) is known at both train and inference time. - Includes benchmark support for the folktables **ACS PUMS** tasks (income, employment, mobility, public coverage, travel time), among other tabular fairness datasets. - Sensitive attributes evaluated: `SEX`, `RAC1P` (race, White/Black), `AGEP` (age, median-binarized). ## Limitations - Restricted to binary sensitive attributes and binary classification targets in current released checkpoints. - Fairness metrics are computed with respect to the single sensitive attribute provided at inference; intersectional fairness is not directly modeled. ## How to Use ```python from fairtfm import FairTFMClassifier, compute_fairness_metrics # Load checkpoint classifier = FairTFMClassifier(model="path/to/checkpoint") # Fit on training data classifier.fit(X_train, y_train, s_train) # Predict predictions = classifier.predict(X_test, s_test) probabilities = classifier.predict_proba(X_test, s_test) # Fairness metrics (returns dict with performance metrics) compute_fairness_metrics(X_test, y_test, s_test) ``` ## Citation ```bibtex @inproceedings{ kenfack2026training, title={Training Fair Tabular Foundation Models}, author={Patrik Kenfack and Jesse C. Cresswell and Anthony L. Caterini and Samira Ebrahimi Kahou and Ulrich A{\"\i}vodji}, booktitle={2nd ICML Workshop on Foundation Models for Structured Data}, year={2026}, url={https://openreview.net/forum?id=ajIvCEbadL} } ```