Article FairRAG: A Privacy-Preserving Framework for Fair Financial Decision-Making Rashmi Nagpal 1,* , Unyimeabasi Usua 1 , Rafael Palacios 2,3 and Amar Gupta 1,4,* 1 Computer Science and Artificial Intelligence Laboratory, Massachusetts Institute of Technology, 32 Vassar St, Cambridge, MA 02139, USA; unyime@mit.edu 2 Cybersecurity at MIT Sloan (CAMS), Massachusetts Institute of Technology, 77 Massachusetts Ave, Cambridge, MA 02139, USA; palacios@mit.edu or rafael.palacios@iit.comillas.edu 3 Institute for Research in Technology, Universidad Pontificia Comillas, Alberto Aguilera 23, 28015 Madrid, Spain 4 AI Institute for Community-Engaged Research (AI-ICER), The University of Texas at El Paso, 500 West University Avenue, El Paso, TX 79968, USA * Correspondence: rnagpal@mit.edu (R.N.); agupta@mit.edu (A.G.) Abstract Customer churn prediction has become crucial for businesses, yet it poses significant chal- lenges regarding privacy preservation and prediction accuracy. In this paper, we address two fundamental questions: (1) How can customer churn be effectively predicted while ensuring robust privacy protection of sensitive data? (2) How can large language models enhance churn prediction accuracy while maintaining data privacy? To address these questions, we propose FairRAG, a robust architecture that combines differential privacy, retrieval-augmented generation, and LLMs. Our approach leverages OPT-125M as the core language model along with a sentence transformer for semantic similarity match- ing while incorporating differential privacy mechanisms to generate synthetic training data. We evaluate FairRAG on two diverse datasets: Bank Churn and Telco Churn. The results demonstrate significant improvements over both traditional machine learning ap- proaches and standalone LLMs, achieving accuracy improvements of up to 11% on the Bank Churn dataset and 12% on the Telco Churn dataset. These improvements were main- tained when using differentially private synthetic data, thus indicating robust privacy and accuracy trade-offs. Academic Editor: Stefano Quer Received: 8 May 2025 Keywords: algorithmic fairness; privacy-preserving machine learning; differential privacy; Revised: 1 July 2025 retrieval-augmented generation Accepted: 4 July 2025 Published: 25 July 2025 Citation: Nagpal, R.; Usua, U.; Palacios, R.; Gupta, A. FairRAG: A 1. Introduction Privacy-Preserving Framework for The use of machine learning as a means to address critical issues in the financial Fair Financial Decision-Making. Appl. domain has transformed our understanding of the underlying patterns in data. However, Sci. 2025, 15, 8282. https://doi.org/ 10.3390/app15158282 in this field, which is highly dependent on user data and personally identifiable information in the decision-making process, it is difficult to ensure that users’ information is protected Copyright: © 2025 by the authors. and that the models are making unbiased decisions. Human-centered problems in finance, Licensee MDPI, Basel, Switzerland. This article is an open access article such as credit approvals and insurance underwriting, have seen an increase in the use of ML distributed under the terms and algorithms [1,2]. Although efficient, these use cases are highly susceptible to discriminatory conditions of the Creative Commons decisions [3]. The existing research attempts to balance model performance with fairness Attribution (CC BY) license and privacy guarantees; it faces challenges to accurately address every potential issue [4,5]. (https://creativecommons.org/ With official regulations such as the European General Data Protection Regulation [6] and licenses/by/4.0/). Appl. Sci. 2025, 15, 8282 https://doi.org/10.3390/app15158282 Appl. Sci. 2025, 15, 8282 2 of 18 the California Consumer Privacy Act [7] becoming increasingly prevalent, organizations must adhere to strict requirements. This ultimately requires significant adjustments to the model training workflows. In general, various studies have highlighted the importance of making informed decisions when working with customer financial data, particularly concerning influencing loan decisions and unfair credit scoring models [1,8]. Instances where bias and data protection were not considered in financial-related ML tasks have led to inequality. Black applicants had their mortgage applications denied at twice the rate of white applicants [9]. Similarly, customer churn models have been found to make different predictions between men and women [10]. Regarding training data privacy, external adversaries use various attacks [11] to obtain information about individuals present in a training dataset [12]. These concerns underscore the need to develop comprehensive frameworks that deliver accurate predictive performance while also addressing fairness, privacy, and regulatory compliance in their output. To confront these concerns, research on privacy-preserving mechanisms, such as differential privacy [1,13], is applied to ensure that individual data contributions remain untraceable and that fairness is promoted throughout both the ML training and post-training processes. As various studies have demonstrated, we can integrate DP with existing models to address privacy and bias [14,15]. Both large language models and retrieval-augmented generation architectures have been individually explored in a DP context [16]. Both frameworks excel at understanding complex datasets; however, LLMs display significant challenges that raise concerns about their suitability for handling sensitive data, such as biases in pre-trained models, hallucinations, and a lack of explainability [17,18]. It is possible to combine RAG with LLM pattern recognition capabilities to address these shortcomings by reducing hallucinations and bias while maintaining high accuracy [19]. We explore the possibility of a customer churn prediction framework that ensures accuracy, addresses fairness metrics, and includes privacy-preserving features on the Bank Churn [20] and Telco Churn [21] customer datasets. Our method introduces a specific FairRAG model: an LLM with an RAG embedding layer trained with DP to generate a fair and privacy-protected synthetic dataset that can be used in a secure ML training pipeline. We build on previous research that leverages randomness in the next token generations of LLMs for DP guarantees [15]. The existing literature on LLMs focuses mainly on generating synthetic text or image data rather than tabular datasets [22–24]. Our framework builds on these methods by utilizing RAG to maintain a knowledge base of the data, enabling more structured application while ensuring the privacy and fairness of training data in downstream tasks. The primary contributions of this work include the following: • The FairRAG architecture enables the generation of synthetic private tabular data for downstream classification tasks while promoting fairness, thus allowing the optimiza- tion of the generation process using an RAG data repository. • Extensive experiments on various churn datasets to evaluate how efficiently private synthetic data can replace real but sensitive data while improving the downstream performance in this domain. This paper is structured as follows: Section 2 provides a detailed literature review that discusses the previous advances in LLMs and RAGs for synthetic data generation, as well as contextualizes churn prediction. Section 3 provides an overview of the FairRAG architecture. Section 4 highlights the FairRAG algorithm breakdown. Section 5 details our experimental setup. Section 6 articulates the research findings of the FairRAG architecture. Section 7 concludes the research. In Section 8, we describe prospective research pathways that could be further explored. Appl. Sci. 2025, 15, 8282 3 of 18 2. Related Work 2.1. Privacy-Preserving Machine Learning Various techniques for handling privacy concerns and information leakage in ML workflows have been thoroughly explored [15,25,26]. In recent years, differential privacy [1] has emerged as the leading method for addressing such issues. ε-differential privacy is a quantifiable measure of privacy. ε governs these trade-offs. Formally, a mechanism M is said to be ε-differentially private if, for any two datasets differing by a single record and for every possible output set S, the probability of obtaining an output is bounded by Pr[M(D) ∈ S] ≤ exp( ) · Pr[M(D′ε ) ∈ S] (1) where D and D′ are adjacent datasets. Lower values of ε provide stronger privacy guar- antees (at the expense of model utility), while higher values allow for improved accuracy with weaker privacy protection [27]. In classification tasks, researchers have explored combining DP with traditional mod- els to address both privacy preservation and algorithmic fairness [14,28]. When it comes to deep learning, it is common for DP to be integrated into these models through one of three approaches: altering the input data as a preprocessing step [29–31], incorporating privacy during model training via methods such as differentially private stochastic gra- dient descent [26,32–34], or applying a post-processing approach that alters the model output [25,35]. Our approach aligns most closely with the second method by introducing Laplace noise during the gradient update step. 2.2. Privacy-Preserving Synthetic Data Generation Synthetic data generation as a method for data security and classification fairness has been extensively studied and has shown promising results. Techniques such as Generative Adversarial Networks [36] and SMOTE [37] have been widely explored to create synthetic datasets that mirror the statistical properties of real-world data without revealing sensitive details. Some of these studies [38] have used GANs to generate synthetic data for sensitive financial contexts such as fraud detection. However, LLMs have demonstrated improved performance in generation and predictive tasks compared to GANs [39,40]. Notably, recent advances have focused on integrating differential privacy into these methods. For example, Google’s work on protecting users with differentially private synthetic training data [15] introduces an approach that uses LLMs and DP mechanisms to generate synthetic training data. They pre-trained an 8B-parameter decoder-only LLM on public text and then privately fine-tuned it using LoRa and prompt-based tuning on disjoint sensitive datasets to generate synthetic data. They relied on a next token prediction framework: p = [TaskName] [LabelNamey] (2) where [LabelNamey] is set to [negative] if y = 0 and [positive] if y = 1. The training example is tokenized into a prefix p = {z1, . . . , zk} and a target sequence x = {zk+1, . . . , zn}. In their unique prefix–LM formulation, the weights for prefix tokens are set to zero (i.e., ∀i ≤ k : wi = 0); thus, they used a modified version of the weighted next token prediction cross-entropy loss: n LPrefixLM (⃗z, w⃗, θ) = − ∑ zi log P(zi | z