
Auditing AI in Criminal Justice
Project Description
A hands-on ethical AI project (Colab) that teaches students to audit a real-world criminal-justice algorithm for racial bias. Using ProPublica’s COMPAS dataset of 7,000+ Broward County defendants, students learn the six principles of Responsible AI (fairness, transparency, privacy, safety, robustness, alignment), then put them into practice: they build their own “race-blind” recidivism model, run a formal fairness audit, and discover firsthand why removing a protected attribute does not remove bias. The project culminates in the Impossibility Theorem — the result that calibration and equal error rates cannot both hold when base rates differ — and uses SHAP explainability to open the black box on individual predictions. The framing throughout is that fairness is not a single number but a set of competing definitions, and that the choice between them is an ethical decision, not just a technical one.
Dataset
ProPublica’s COMPAS “two-year recidivism” dataset, loaded live from GitHub (no download needed): compas-scores-two-years.csv. It covers defendants scored by COMPAS in Broward County, Florida (2013–2014) and tracked for two years. Key columns include age, sex, race, priors_count, charge degree, juvenile-offense counts, the COMPAS decile_score, and the ground-truth two_year_recid label. Identifying columns (name, dob, id) are dropped immediately as a data-minimization (privacy) exercise.
Relevant Skills You May Apply
Python and pandas (loading, filtering, grouping tabular data), basic statistics and probability, introductory machine learning concepts (features, train/test split, classification), data visualization with matplotlib/seaborn, and comfort running Colab notebooks.
Skills You May Gain
Responsible/Ethical AI auditing, fairness metrics (demographic parity, false positive/negative rates, equalized odds, calibration) and the fairness impossibility theorem, training and evaluating a Decision Tree classifier with scikit-learn, reproducing a landmark bias investigation, model explainability with SHAP (global feature importance and per-defendant waterfall plots), data minimization for privacy, and writing a Model Card to document a model’s limitations.
Total Time
Approximately 8–12 hours, self-paced.
Milestones
- Milestone 1: Why Does Ethical AI Matter? — three landmark bias cases (COMPAS, Amazon hiring, Gender Shades) and the six principles of Responsible AI; environment setup.
- Milestone 2: Data Collection — load COMPAS live from ProPublica’s GitHub and drop identifying columns as a privacy exercise.
- Milestone 3: Data Preprocessing & Cleaning — apply ProPublica’s exact filtering criteria and select audit-relevant features.
- Milestone 4: Exploratory Data Analysis — score distributions, recidivism rates, and age/priors by race; are “neutral” inputs really neutral? (written questions).
- Milestone 5: Building the Blind Model — train a race-blind Decision Tree and test whether dropping race removes bias.
- Milestone 6: The Fairness Audit — compute formal fairness metrics, reproduce ProPublica’s findings, and confront the Impossibility Theorem (written question).
- Milestone 7: Open the Black Box — explainability with SHAP, global importance and a single false-positive defendant, plus a white-defendant comparison (TODO).
- Milestone 8: The Model Card — document what was built, its limitations, and responsible-use guidance.
Deliverables
A completed notebook with the blind model trained and audited, written answers for the EDA, fairness, and SHAP questions, the white-defendant false-positive waterfall plot (Milestone 7 TODO) completed, and a finished Model Card. Save a copy to personal Drive before starting.
