TL;DR
Standard PII filters fail to catch "contextual leakage," where a combination of individually harmless attributes (like age, occupation, and location) can uniquely identify an individual in a RAG system's output. This paper introduces a Privacy Policy Enforcement (PPE) framework using dual one-class density estimators (T3+OCSVM) to detect these hidden privacy risks at millisecond latency. By exposing a critical "case-style confound"—where models mistake professional tone for data leaks—the authors demonstrate how training with borderline-safe data achieves a robust AUROC of $\ge$ 0.93 across medical, financial, and legal domains.
What Problem Does This Paper Address?
Retrieval-Augmented Generation (RAG) has become the gold standard for deploying Large Language Models (LLMs) in data-sensitive fields like medicine, finance, and law. Traditional privacy defenses (Layer 1) focus on direct identifiers—redacting Social Security numbers, names, or email addresses using regular expressions and Named Entity Recognition (NER).
However, these filters are completely blind to contextual leakage (Layer 2). Consider the description: "a 52-year-old female litigator from Omaha with two children and a recent custody filing." No single token violates privacy laws, yet the specific conjunction of these quasi-identifiers (QIs) can uniquely re-identify a real person.
Existing distribution-based guardrails assume that unsafe content looks anomalous. But in professional RAG systems, a leaky answer sounds exactly like a normal, professional case note or legal brief. The core challenge is distinguishing between safe professional text and text whose specific composition of attributes leaks private identities.
Methods
The authors propose a Privacy Policy Enforcement (PPE) framework built around a dual one-class density estimator:
- Embedding Stack: The system fuses three distinct text encoders—Qwen3-Embedding-0.6B, BGE-M3, and E5-large-v2—into a single 3,072-dimensional feature vector. This allows the model to simultaneously capture surface phrasing, semantic content, and register.
- Dual One-Class SVM (T3+OCSVM): Instead of using a standard binary classifier (which can overfit to stylistic shortcuts), the framework trains two one-class Support Vector Machines in parallel. One maps the safe distribution (augmented with borderline-safe data), and the other maps the unsafe distribution.
- Calibrated Abstain Region: If an input text is out-of-distribution (OOD) for both safe and unsafe densities, the system triggers an "abstain" action, routing the query to human review rather than making an unreliable guess.
Datasets
Because real-world RAG breach data is rare and highly sensitive, the authors developed an axis-stratified, multi-LLM synthetic data generation pipeline to create training and evaluation data:
- Seed Corpora: Public datasets across three domains were used as the safe baseline, including MedQuAD (Medical), FinQA (Finance), and MMLU-Law (Law).
- Synthetic Generation: Using three distinct LLMs (Qwen2.5-7B, Mistral-7B, and Phi-3-medium), they generated unsafe Q&A pairs by combinatorially sampling from an 8-class QI taxonomy (Age, Location, Occupation, etc.).
- Borderline-Safe Stress Test: Crucially, they generated a counterfactual negative dataset—text that perfectly mirrors the professional "case voice" but is entirely stripped of identifying QI clusters. A fourth model lineage (Yi-1.5-9B) was entirely held out to evaluate cross-generator robustness.
Key Insights and Ideas
- The Case-Style Confound: Traditional anomaly detection baselines (like Gaussian Mixture Models) achieved near-perfect within-distribution AUROC ($\ge$ 0.94) but completely collapsed (to 0.72–0.79) when evaluated against the borderline-safe stress test. The detectors weren't learning privacy violations; they were simply latching onto the professional tone of the text.
- Why OCSVM Beats GMM: GMMs partition feature space into Gaussian basins where log-likelihoods drop exponentially away from cluster means, causing them to misclassify borderline-safe text as unsafe. OCSVM defines a support boundary with linear distance scores, making it much more robust to stylistic overlap.
- The Failure of Alternative Architectures: Supervised MLP classifiers suffer from a bimodal score distribution, forcing them to abstain on 69–85% of borderline cases to maintain accuracy. Meanwhile, LLM-as-a-judge baselines (like Qwen-14B) cannot be calibrated to specific operational thresholds and introduce massive latency and cost penalties ($10^4\times$ more expensive).
Key Results
- Robust Stress-Test Recovery: The proposed T3+OCSVM configuration, augmented with 4,000 borderline-safe records during training, recovered the borderline AUROC to $\ge$ 0.93 across all three domains.
- Drastic Error Reduction: The model lowered the borderline false positive rate at a 95% true positive rate ($\text{FPR}_{95}$) by 44 to 55 percentage points.
- Operational Feasibility: It successfully stabilized the review queue, keeping abstention rates below 11% for medical text and $\le$ 3.7% for finance and law.
- Efficiency: The entire pipeline operates at single-digit millisecond latency, making it viable for inline production guardrails.
Limitations and Future Work
- Domain and Language Scope: The evaluation was restricted to English-language text. Performance on other clinical modalities (like radiology reports or structured EHRs) or non-US regulatory frameworks (like GDPR) remains unmeasured.
- Quantitative Overlap in Finance: The finance domain retained a higher residual borderline false positive rate (36%). This is because cohort-level quantitative data (e.g., tax brackets, investment limits) looks stylistically identical to single-client leaks in embedding space, requiring future domain-specific pre-filtering.
- Unmodeled Leakage Types: The framework does not yet address verbatim-source leakage (direct quotes from the source text) or multi-turn leakage (where QIs are leaked incrementally across a conversation).
Summary updated