Models now help decide who gets a loan, a job interview or medical attention. Because these decisions affect people, machine learning carries ethical responsibilities.
Bias and Fairness
A model learns from past data, and if that data reflects historic prejudice or under-represents a group, the model repeats and may amplify the unfairness. A well-known case is a recruitment tool that learned to prefer male candidates because past hires were mostly male. Bias may enter through the sample (who is in the data), the labels (who judged them), the features (proxies such as postcode for a protected attribute) or the objective. Fairness is checked by comparing outcomes across groups, for example the selection rate for each group. The four-fifths rule treats a ratio of selection rates below 0.8 as a warning of disparate impact.
Privacy and Consent
Models are trained on personal data such as health, location and purchases. Ethical use requires consent, collecting only what is needed, protecting data by anonymisation and security, and following law such as India's Digital Personal Data Protection Act, 2023. A model may also leak training data, so privacy must be considered after training too.
Transparency, Accountability and Safety
Many models, especially deep networks, are black boxes. People affected by a decision have a reasonable claim to an explanation, and tools such as feature-importance scores support explainability. Someone must be accountable for a model's errors, a human should be able to review high-stakes decisions, and models should be monitored for drift after deployment. Other concerns are misuse (deepfakes), security (adversarial inputs) and job displacement.
Definition: Algorithmic bias. Systematic and repeatable errors in a model's output that create unfair outcomes for particular groups, usually arising from biased data or design choices.
Table 4.6: Ethical issues and responses
| Issue | Example | Response |
|---|---|---|
| Bias | Hiring tool favours one gender | Audit data and outcomes by group |
| Privacy | Health data used without consent | Consent, anonymisation, law |
| Transparency | Loan refused with no reason | Explainable models, explanations |
| Accountability | Nobody owns an error | Human review, clear ownership |
| Safety | Model degrades after launch | Monitoring and retraining |
Example 4.6: Checking disparate impact
Problem: A loan model approves 40 of 100 applicants from Group A and 20 of 100 from Group B. Compute the selection rates and the disparate impact ratio, and apply the four-fifths rule.
Solution:
- Selection rate of Group A = 40 / 100 = 0.40; of Group B = 20 / 100 = 0.20.
- The disparate impact ratio is the lower rate divided by the higher: 0.20 / 0.40 = 0.5.
- Since 0.5 is below 0.8, the model fails the four-fifths rule and shows possible disparate impact.
- The model, its data and its features must be reviewed before use.
Result: The ratio is 0.5 (below 0.8), so there is a warning of bias against Group B.
approved = {"A": 40, "B": 20}
total = {"A": 100, "B": 100}
rate = {g: approved[g] / total[g] for g in approved}
ratio = min(rate.values()) / max(rate.values())
print("selection rates:", rate)
print("disparate impact ratio:", ratio)
print("passes four-fifths rule:", ratio >= 0.8)
Output
selection rates: {'A': 0.4, 'B': 0.2}
disparate impact ratio: 0.5
passes four-fifths rule: False
Common mistakes
- Believing that a model is objective because it is mathematical.
- Dropping the protected attribute and ignoring proxies such as postcode.
- Collecting more personal data than the task needs.
- Deploying a high-stakes model with no human review or monitoring.
Key takeaways
- Bias comes from data, labels, features and objectives.
- Four-fifths rule: a selection-rate ratio below 0.8 warns of disparate impact.
- Respect privacy and consent; follow the DPDP Act 2023 in India.
- Provide transparency, accountability and monitoring.
Practice questions
- What is algorithmic bias?
- What does the four-fifths rule check?
- Why is explainability important?
Answers to the practice questions
- Systematic errors in a model that produce unfair outcomes for some groups.
- Whether the lower selection rate is at least 80 percent of the higher rate.
- People affected by a decision may need to understand and challenge it.
Sources
- Official BCA syllabus Introduction to Machine Learning, course code 26BCA404DSE21, Unit IV
