Causal fairness is a framework for auditing algorithmic bias that uses structural causal models (SCMs) and directed acyclic graphs to formally distinguish between discriminatory causal pathways and legitimate, non-discriminatory ones in a prediction. Unlike purely statistical definitions, it explicitly models the data-generating process to determine if a protected attribute, such as race or gender, exerts an unfair causal effect on a model's output.
Glossary
Causal Fairness

What is Causal Fairness?
Causal fairness is a framework for defining and auditing algorithmic fairness using the language of causal inference, distinguishing discriminatory pathways from legitimate ones in a model's predictions.
A core technique is counterfactual fairness, which deems a prediction fair if it remains identical in the actual world and a hypothetical world where an individual's protected attribute was different, holding all other causally independent factors constant. This approach resolves the limitations of fairness through unawareness by directly addressing proxy discrimination, where non-protected features like zip code serve as conduits for a protected attribute's causal influence.
Core Characteristics of Causal Fairness
Causal fairness moves beyond statistical parity to examine the mechanisms of discrimination. By using structural causal models, it distinguishes legitimate causal pathways from illegitimate ones, answering not just if a disparity exists, but why.
Structural Causal Models (SCM)
The mathematical backbone of causal fairness. An SCM is a triple (U, V, F) defining exogenous variables (U), endogenous variables (V), and structural equations (F) that assign a causal mechanism to each variable.
- Nodes represent variables (e.g., education, hiring decision).
- Edges represent direct causal relationships.
- Exogenous variables capture unobserved background noise.
This graph allows auditors to explicitly encode assumptions about how the world works before testing for bias.
Counterfactual Fairness
A prediction Ŷ is counterfactually fair if it would remain the same in the actual world and a counterfactual world where an individual's protected attribute (e.g., race) was different, but all other causally independent factors remain unchanged.
- Key Insight: It corrects for the 'red-lining' proxy problem.
- Requirement: A fully specified causal model to compute the intervention.
- Contrast: Unlike demographic parity, it allows legitimate statistical dependence through mediating variables like education if education is not itself a product of discrimination.
Path-Specific Effects
Not all causal paths from a protected attribute to an outcome are discriminatory. Path-specific fairness decomposes the total causal effect into fair and unfair pathways.
- Fair Path: A protected attribute influences a job-relevant skill, which legitimately influences hiring.
- Unfair Path: A protected attribute directly influences hiring via a biased interviewer (direct discrimination).
- Audit Logic: The goal is to nullify the effect along the unfair path while preserving the effect along the fair path, a technique known as path-specific counterfactual inference.
Resolving the Simpson's Paradox
A core motivation for causal fairness is resolving statistical reversals. A model might appear fair in aggregate but be discriminatory in every sub-group, or vice versa.
- Example: A university admissions model might show no gender bias overall, but causal analysis reveals bias against women applying to competitive departments and against men applying to less competitive ones.
- Causal Solution: By conditioning on the correct confounders (applicant qualifications) and analyzing the direct effect of gender, the paradox is resolved, revealing the true discriminatory structure.
No Unresolved Discrimination
A formal causal fairness definition proposed by Kilbertus et al. It states that there should be no directed path from a protected attribute to the outcome, except via a resolving variable.
- Resolving Variable: A feature that society explicitly accepts as a legitimate basis for differential treatment (e.g., physical strength for a firefighter role).
- Audit Process: The auditor specifies the resolving variables. The model is fair if the protected attribute's influence is fully mediated by these variables, blocking all other back-door or direct paths.
Counterfactual vs. Observational Fairness
A critical distinction in auditing. Observational criteria (like Demographic Parity) only look at data correlations. Causal criteria look at mechanisms.
- Observational: 'Are loan rates equal across groups?' (Can be fooled by proxy variables).
- Counterfactual: 'Would this specific applicant have received the loan if they were of a different race, holding all else equal?'
- Power: Causal reasoning allows for individual-level recourse and justification, whereas observational methods only guarantee group-level statistical properties.
Enabling Efficiency, Speed & Accuracy
Intelligent Analysis, Decision & Execution
We build AI systems for teams that need search across company data, workflow automation across tools, or AI features inside products and internal software.
Talk to Us
Search across company data
Give teams answers from docs, tickets, runbooks, and product data with sources and permissions.
Useful when people spend too long searching or get different answers from different systems.

Automate internal workflows
Use AI to route work, draft outputs, trigger actions, and keep approvals and logs in place.
Useful when repetitive work moves across multiple tools and teams.

Add AI to products and internal tools
Build assistants, guided actions, or decision support into the software your team or customers already use.
Useful when AI needs to be part of the product, not a separate tool.
Frequently Asked Questions
Clear, technically precise answers to the most common questions about using causal inference to audit and enforce fairness in machine learning systems.
Causal fairness is a framework for defining and auditing algorithmic fairness using the language of causal inference and Structural Causal Models (SCMs). Unlike statistical fairness definitions—such as Demographic Parity or Equalized Odds—which only examine correlations between a protected attribute and a model's output, causal fairness explicitly models the data-generating process. It distinguishes between discriminatory causal pathways (e.g., the direct effect of race on a hiring decision) and legitimate causal pathways (e.g., the effect of race mediated through a job-relevant qualification). This allows a practitioner to block unfair effects while preserving fair ones, solving the proxy discrimination problem that statistical methods often miss. The core tool is the causal graph, a directed acyclic graph encoding assumptions about how variables influence one another.
Related Terms
Understanding causal fairness requires fluency in the broader taxonomy of algorithmic bias. These concepts define the statistical, legal, and structural dimensions of equitable machine learning.
Proxy Discrimination
A form of algorithmic bias where a non-protected feature, such as zip code or browser type, serves as a stand-in for a protected attribute like race. Causal graphs are essential for identifying and blocking these indirect discriminatory pathways.
- Redlining is a classic historical example
- Fairness through unawareness fails to prevent it
- Causal mediation analysis can quantify the proxy effect
Disparate Impact
A legal doctrine and quantitative metric identifying facially neutral practices that disproportionately harm a protected group. Often measured by the 80% rule: the selection rate for a disadvantaged group must be at least 80% of the rate for the advantaged group.
- Focuses on outcomes, not intent
- Does not distinguish between legitimate and illegitimate causal pathways
- Causal fairness decomposes disparate impact into explainable components
Equalized Odds
A separation-based fairness metric requiring a classifier to have equal True Positive Rates (TPR) and equal False Positive Rates (FPR) across sensitive groups. This ensures errors are distributed equally, but can clash with calibration when base rates differ.
- Mathematically: P(Ŷ=1|Y=y, A=a) = P(Ŷ=1|Y=y, A=b)
- Enforces equality of opportunity for both qualified and unqualified individuals
- Causal fairness often relaxes this to focus on specific causal pathways
Intersectional Fairness
A paradigm examining bias against subgroups defined by the combination of multiple protected attributes, such as Black women, rather than treating race and gender in isolation. Causal models can capture the complex interactions between multiple sensitive nodes.
- Aggregate group fairness can mask severe intersectional harms
- Requires sufficient data for statistically powered subgroup analysis
- Multicalibration is a leading technical framework to address this
Algorithmic Recourse
The ability for an individual negatively affected by an algorithmic decision to understand the reasons and take actionable steps to reverse that decision. Causal fairness is foundational here, as it identifies which features an individual can actually change to flip a prediction.
- Contrastive explanations: 'You were denied because X. If you change Y, you will be approved.'
- Requires distinguishing mutable features from immutable ones
- Actionable recourse is the practical application of counterfactual generation

About the author
Prasad Kumkar
CEO & MD, Inference Systems
Prasad Kumkar is the CEO & MD of Inference Systems and writes about AI systems architecture, LLM infrastructure, model serving, evaluation, and production deployment. Over 5+ years, he has worked across computer vision models, L5 autonomous vehicle systems, and LLM research, with a focus on taking complex AI ideas into real-world engineering systems.
His work and writing cover AI systems, large language models, AI agents, multimodal systems, autonomous systems, inference optimization, RAG, evaluation, and production AI engineering.
Partnered with leading AI, data, and software stack.
How We Work
Custom AI workflows for your Business
One-fit-all AI don't work for modern businesses. At Inferensys, we aim to understand your business & custom requirements; which we use to define most efficient agentic workflows, the data, and the tools for your business.
01
Review the use case
We understand the task, the users, and where AI can actually help.
Read more02
Pick the right approach
We define what needs search, automation, or product integration.
Read more03
Build the first useful version
We implement the part that proves the value first.
Read more04
Improve from there
We add the checks and visibility needed to keep it useful.
Read moreThe first call is a practical review of your use case and the right next step.
Talk to Us