Causal Auditing of RL Loan Pricing Policies Using Process Mining
A lender deployed an RL agent to set loan prices but could not explain why applicants with similar profiles received different offers. I built a causal auditing pipeline that reconstructs decision journeys from event logs, estimates heterogeneous treatment effects, and flags policy paths where price uplift is not causally justified.
- 1.4B
- Event logs processed
- 17
- Unjustified price paths found
- -63%
- Disparity gap reduced
- 4.2h → 22m
- Audit runtime
The challenge
The pricing agent optimised margin against a simulator, so its live behaviour drifted into segments where uplift correlated with proxies for protected attributes. Compliance needed evidence, not intuition: which decision paths cause a higher price, and by how much.
Approach
- Reconstructed end-to-end applicant journeys from raw servicing and underwriting events into conformant event logs with PM4py, then mined variants and conformance deviations against the intended policy model.
- Modelled each mined variant as a treatment and estimated conditional average treatment effects on offered APR with EconML doubly-robust and causal-forest learners, including refutation tests for unobserved confounding.
- Built the batch feature and log-normalisation layer as Apache Beam pipelines so the same code powers backfills and daily incremental audits.
- Packaged the audit as a Kubeflow pipeline on Kubernetes with versioned artefacts, so every regulatory report is reproducible from a single run ID.
- Shipped a reviewer dashboard that ranks policy paths by effect size and confidence, letting risk officers accept, contest, or escalate each finding.
Outcome
Seventeen policy paths were shown to raise price without a causally defensible driver. Retraining with the audit as a constraint cut the disparity gap by 63% while holding portfolio margin flat, and the pipeline now runs nightly as a standing control.
Results in detail
Figures are from the delivered engagement, normalised where data is confidential.
Estimated treatment effect on offered APR
Doubly-robust CATE per mined process variant (basis points). Positive bars are price uplift; flagged variants lacked a causal driver.
Disparity gap after audit-constrained retraining
Max pairwise APR gap between matched applicant cohorts, per retraining round.
Related projects
AI platform / Infrastructure
LLM Fine-Tuning, Compiling and Serving Benchmarks
An end-to-end benchmark harness for choosing how to align, compile, and serve open-weight models under real cost limits.
Supply chain / Operations research
Reinforcement Learning for Multi-Echelon Supply Chain Optimization
RL agents that match classical optimal stock policies on fixed lead-times and outperform them when lead-times vary.
Automotive / Supply chain quality
Weakly-Supervised Anomaly Detection for Supply Chain Operations
A hybrid deep-learning and classic-ML anomaly detection platform that flags supply-chain irregularities and recommends classification.