Specialty Digest

Global English editionLearners’ Study Dashboard — in development
The Knowledge Library for All

Flashcards: open the module flashcards (end-of-module review with workplace questions).

Online Courses / Professional Track / Working with AI

Module 7 · Lesson 1 · Core

Where AI bias comes from and how to spot it

See how data, wording and proxies create biased output and run a simple names-only test on identical items.

  • 55 minutes
  • Serves O6
  • Assumes Modules 1 to 6

Phase 1: Prepare

Step 1 Warm-up recall

From Module 6: what do you do before pasting personal data into an assistant?

Private: nothing you type here is sent or stored.

Step 2 Learning goal

By the end of this lesson you can:

  • name three ways bias enters AI output (Foundation);
  • run a names-only test on identical items (Core);
  • compare an observed count with a fair share (Core).

Phase 2: Teach

Step 3 A familiar example

A teacher who marks essays without looking at the names on them is using a simple trick against her own bias. A names-only test does the same for an assistant: change the name and keep everything else the same.

Step 4 Clear explanation

An assistant learned from huge amounts of human writing, and that writing reflects human views, including unfair ones. Researchers who studied large language models warned in 2021 that a big dataset is not the same as a fair or diverse one: the people who write most online text are not a cross-section of humanity, and what is written can carry stereotypes that the model then repeats.

Datawho is in itWordingloaded termsProxiesnames, postcodesUsewho decides
Bias can enter through the data, the wording, proxies such as names, and the way the output is used.

Four doors let bias in. The data may under-represent or stereotype groups. The wording of your request may carry loaded terms. Proxies, such as a name or a postcode, can stand in for a protected characteristic even when you never mention it. And the use, meaning who relies on the output and how, can turn a small tilt into a large harm.

You can test for this yourself without technical skill.

TestWhat you changeWhat you look for
Names-only testSwap only the name on identical résumésDoes the ranking move?
Order testShuffle the order of the same itemsDoes position change the result?
Wording testReword a request without changing its meaningDoes the tone or advice change?

Suppose you ask an assistant 1,000 times to pick the best of eight otherwise identical résumés that differ only by name. With no bias, each would come first about 1 in 8 times, a fair share of 12.5%, or 125 times in 1,000. If one name comes first 172 times, that is 47 above the fair share, or 47 ÷ 125 = 37.6% more often than chance, which is a signal worth taking seriously.

Step 5 Worked example (4 marks)

You run a names-only test 1,000 times on eight identical résumés. One name is ranked first 172 times. How does that compare with a fair share?

  1. Fair share = 1 ÷ 8 = 12.5%, which is 125 of 1,000. (1 mark)
  2. Excess = 172 − 125 = 47. (1 mark)
  3. Relative excess = 47 ÷ 125 = 0.376, or 37.6%. (1 mark)
  4. Answer: about 38% more often than chance, which needs a closer look. (1 mark)

Go deeper: the professor's notes

Bias enters through data, wording, proxies and use.
Data

Who is in it.

Proxies

Names, postcodes.

Test

Change one thing.

Datawho is in itWordingloaded termsProxiesnamesUsewho decides
Bias doors

Names-only test

ItemValue
Runs1,000
Fair share125 (12.5%)
Observed172
Above fair share37.6%

At work: Test a ranking

Eight identical résumés differing only by name.

  1. Find the fair share.
  2. Subtract it from the observed count.
  3. Divide by the fair share.

What a careful practitioner decides. About 38 percent above chance.

Phase 3: Practise

Step 6 Learner practice (instant-marked)

1. A proxy for a protected characteristic can be:

2. With eight equal candidates a fair share of first place is:

3. A names-only test changes:

4. A large dataset is:

Phase 4: Close

Step 7 Recap

  • Bias enters through data, wording, proxies and use.
  • A names-only test changes one thing and watches the result.
  • Compare counts with the fair share.

Step 8 Exit ticket (ungraded)

Five identical items are ranked first 600 times in 2,000 runs for one of them. What is the fair share and how does 600 compare?

Private: nothing you type here is sent or stored.

Step 9 Go further (Extension)

Run a names-only test on a short task in an approved tool and note how the output changes.

In industry: Big data is not the same as fair data

In their 2021 paper On the Dangers of Stochastic Parrots, Emily Bender, Timnit Gebru, Angelina McMillan-Major and Margaret Mitchell (published under a pseudonym as Shmargaret Shmitchell) argued that the internet text used to train language models over-represents younger people and those from richer countries, and that moderation and filtering choices decide whose voices count. They warned that models can repeat derogatory language and stereotypes found in that text, and urged careful documentation of training data.

Link to this lesson. Ask who is missing from the data, not just how much of it there is.

Source: Bender, Gebru, McMillan-Major and Shmitchell (2021), On the Dangers of Stochastic Parrots, FAccT 2021, ACM; University of Washington News, 10 March 2021

Common mistakes

MistakeWhy it fails
Assuming that a neutral tool is neutralTest it.
Changing several things in a testChange only the name.
Ignoring proxiesRemove or test names and postcodes.

Limits. Results vary by model and by test design, and the example uses invented numbers; a few runs can mislead, so repeat tests many times.

Flashcards for this lesson (3)

Tap a card to reveal the answer. Read the question, answer it aloud or in writing first, then check yourself against the explanation.

Card 1 of 3 · Where does bias in AI output come from?
Datawho is in itProxiesnamesUsewho decides
Bias doors

From four places: the data it learned from, the wording of your request, proxies such as names and postcodes, and how the output is used.

Card 2 of 3 · What is a proxy?
Namestands inPostcodestands inNevermentioned
Proxy

A feature that stands in for a protected characteristic even when that characteristic is never mentioned, such as a name or a postcode.

Card 3 of 3 · What is a names-only test?
SameitemsChangename onlyRepeatmany times
Names-only test

Run the same task on identical items that differ only by name, many times, and see whether the result shifts. Everything else must stay equal.

Review with flashcards

Test yourself on this module with workplace flashcards and detailed answers.

Open the module flashcards