Lion Cipher Lab

Test an AI model for bias with Fairlearn

Why it matters

Models increasingly make or shape decisions about people — who gets flagged, screened, approved, or shown something — and a model that looks accurate overall can still fail one group badly, because the single accuracy number hides that. The skill that matters is not training a model but interrogating it: breaking its performance apart by group and reading whether it treats people evenly. Fairlearn is a free, open-source tool built for exactly this, and doing the measurement yourself — rather than trusting a vendor's claim that a system is fair — is the difference between assuming fairness and…

What you'll learn

Steps in this lab

  1. Why a model can be biased in the first place
  2. Two fairness metrics — and why they can disagree
  3. Install Fairlearn
  4. Load a sample dataset and train a quick model
  5. Evaluate the model by group with MetricFrame
  6. Read a disparity metric: demographic parity difference
  7. The honest limits — no single number is "fair"
  8. What to carry out of this

Open the full interactive lab →