Track 06 · Security & risk reviewLesson 04 of 10
Bias and fairness evidence
Measure and report fairness where hiring, lending and public services demand it.
- Specialisation · Financial services
- 40 min read
- 75 min hands-on
- Pro
What you'll be able to do
01- Classify a proposed LLM feature's fairness risk as allocation, quality-of-service or representational harm, and name the groups and proxies that matter for it.
- Choose a fairness metric (demographic parity, equalised odds, equal opportunity, calibration) for a given decision, and explain why the impossibility results force you to choose.
- Implement a counterfactual name or dialect swap test with matched pairs, a noise-floor control, per-group rates and a seeded bootstrap confidence interval.
- Diagnose bias that enters through retrieval and summarisation rather than through the final decision.
- Defend a fairness report and system card in front of a model-risk reviewer, including what you did not test.
Before you start
- Golden datasets and the metrics that matter: stratified test sets and confidence intervals.
- Regression tests and CI gates: where the fairness suite runs.
- Beyond English: language, script and region: per-language quality differences.
- Automated red-teaming: the harness pattern (seeds, mutators, target, scorer) that the counterfactual test here reuses.
- Basic probability: conditional rates, base rates, what a confidence interval means.
The short version
Fairness work is measurement of unequal treatment. You decide which harm you are worried about, which groups could suffer it, and which metric captures it. Then you test in two ways: observationally, by disaggregating real or labelled outcomes by group, and counterfactually, by changing only a group cue (a name, a dialect, a language) and checking whether the system's output changes. You report gaps with confidence intervals against thresholds agreed before the test. You mitigate at the layer where the bias enters, re-test, and write it all down in a system card the customer's model-risk team can sign.
- Three harm families: allocation (who gets the resource), quality of service (who gets a worse system) and representational (how groups are portrayed).
- Removing the protected attribute does not remove bias. Names, language, postcode and writing style are proxies.
- Fairness metrics conflict. When base rates differ, calibration and equal error rates cannot both hold, so the metric choice is a documented decision, not a default.
- For LLMs, counterfactual swap tests are the cheapest strong evidence. Pair them with a noise-floor control or you will report model randomness as bias.
- A point estimate is not evidence. Report intervals, and decide in advance what "inconclusive" means.
Pro lesson
The rest of this lesson is in Pro.
The mental model, worked example, field note, failure table, exercise and self-check, with the voice tutor.
- Every stage and specialisation, in full
- Every lab and every role project
- Halden weeks 2–10, on your record
- Every drill, live in the playground
- All solutions, plus the server judge
- Lab Assistant and every Teach with AI