01 / 21

Computing
Bias

Explore how human biases get embedded in computing systems, why it matters, and how to identify and mitigate bias in algorithms and data.

AP Computer Science Principles

What Is Computing Bias?

Computing bias occurs when a computer system systematically produces unfair outcomes that privilege certain groups over others. This can happen at every stage: from how data is collected, to how algorithms are designed, to how results are interpreted.

Why Does Bias Matter?

Real Harm
Biased algorithms affect hiring, lending, criminal justice, and healthcare: decisions with life-changing consequences.
Scale
A biased algorithm can discriminate against millions of people simultaneously, far beyond what one person could.
Hidden Nature
Computing bias is often invisible: users trust "objective" computer decisions without questioning underlying assumptions.

Sources of Computing Bias

Computing Bias Data Bias Algorithmic Bias Selection Bias Interaction Bias Confirmation Bias Exclusion Bias

Core Types of Bias

1
Data Bias: Training data that doesn't accurately represent the target population. Over-represents some groups, under-represents others.
2
Algorithmic Bias: The logic or rules in the algorithm itself introduce or amplify unfair patterns, even with balanced data.
3
Selection Bias: The method used to collect or sample data systematically excludes certain groups.
4
Confirmation Bias: Developers unconsciously design systems that reinforce their pre-existing beliefs.

The Bias Pipeline

Data Collection Algorithm Design Deployment Outcomes Bias can enter Bias can enter Bias can enter Feedback loop amplifies bias

Intentional vs. Unintentional Bias

Intentional Bias Unintentional Bias
Origin Deliberate design choices Overlooked assumptions
Awareness Developer knows about it Developer is unaware
Example Filtering search results by region Training data lacks diversity
Fix Difficulty Moderate: change the rule Hard: requires auditing data
Frequency Less common Very common

How to Identify Bias

1
Examine the data: Ask who is represented and who is missing. Look for imbalances in demographic categories.
2
Test across groups: Run the algorithm on different demographic groups separately. Compare error rates and outcomes.
3
Seek diverse perspectives: Include people from different backgrounds in the design and testing teams.
4
Check proxy variables: Identify if seemingly neutral variables (like zip code) are proxies for protected characteristics (like race).
5
Monitor outcomes: Continuously track the real-world impact after deployment. Bias can emerge over time.

Example: Facial Recognition Bias

Training Data Distribution 78% Light-skinned Males 15% Light-skinned Females 5% Dark-skinned Males 2% Dark-skinned Females

Example: Hiring Algorithm Bias

A major tech company built an AI-powered resume screening tool that was trained on 10 years of hiring data. The system learned to penalize resumes that included words associated with women.

The Data
Past hires were predominantly male, reflecting historical industry demographics.
The Result
The algorithm learned that "male" patterns predicted hiring, downranking female applicants.

A hiring system observes outcomes only for the people it selects

Applicants pass through a recruitment process, with selected and unselected routes.A hiring system records later workplace outcomes for the applicants it selects. Outcomes for rejected applicants remain unobserved, which matters when those records are used for future decisions.

Selection changes which outcomes are observed

Ten numbered applicants split into six selected and four unselected; only the selected branch has observed outcomes and a conditional retraining loop.Suppose ten applicants are considered and six are selected. The system records workplace outcomes for those six; the other four outcomes remain unobserved. If later training uses only recorded outcomes, this selection boundary affects the available evidence.

Example: Search Engine Bias

Search: "CEO" → Image Results Male Male Male Male Male ~89% male images ~11% female images Results reflect web content bias, not real-world CEO demographics

Strategies to Mitigate Bias

Diverse Data
Ensure training data represents all relevant demographic groups proportionally.
Diverse Teams
Include people from different backgrounds in the design, development, and testing process.
Bias Audits
Regularly test systems for disparate impact across different groups before and after launch.
Transparency
Make algorithms and data sources accessible so external researchers can identify bias.

The Problem of Proxy Variables

Race (Protected) Zip Code School Name First Name Algorithm Uses "neutral" variables that correlate with protected attributes

Crowdsourcing and Interaction Bias

When systems rely on user-generated content or feedback, the biases of the user base get amplified. If most users are from one demographic, the system optimizes for that group's preferences and perspectives.

Autocomplete
Search suggestions reflect the most common queries, which may include stereotypes and biased associations.
Recommendation
If users from one group engage more, the system learns to serve their preferences, creating filter bubbles.

Common Mistakes

✕ "Algorithms Are Neutral"
Algorithms encode the values and biases of their creators and training data. They are never purely objective.
✕ "More Data Fixes Bias"
More biased data just means more bias. Quality and representativeness matter more than quantity.
✕ "Removing Protected Variables Removes Bias"
Proxy variables can still carry the same discriminatory signal even when protected attributes are excluded.

Summary of Key Concepts

Concept Definition Example
Data Bias Unrepresentative training data Facial recognition accuracy gap
Algorithmic Bias Unfair logic in the code itself Resume screener penalizing women
Proxy Variable Neutral variable correlated with protected class Zip code as proxy for race
Feedback Loop Biased output reinforces biased input Predictive policing
Filter Bubble Personalization narrows diversity News recommendation algorithms

Question 1 of 5

A facial recognition system performs well on light-skinned faces but poorly on dark-skinned faces. What is the most likely source of this bias?

Question 2 of 5

A lending algorithm does not use race as an input variable but still denies loans to minority applicants at higher rates. What concept best explains this?

Question 3 of 5

A news recommendation algorithm shows users only articles that align with their existing viewpoints. This is an example of:

Question 4 of 5

Which of the following is the most effective strategy for reducing computing bias?

Question 5 of 5

A predictive policing algorithm sends more officers to neighborhoods with historically high arrest rates, leading to more arrests in those areas, which then reinforces the algorithm's predictions. This is an example of: