Surprise Masking: Private Data Filtering with Model Likelihoods
Riya Tyagi, Sahra Ghalebikesabi, Vinnie Monaco, Avi Schwarzschild, Om Thakkar
Key points
From the paper's conclusion- We propose Surprise Masking (SM), a simple form of perplexity filtering that uses a publicly available reference model to identify unwanted spans and suppress learning from them while preserving the rest of each example.
Abstract
Data useful for language model (LM) training can contain private or unwanted information that is at risk of being learned or memorized. We propose Surprise Masking (SM), a simple form of perplexity filtering that uses a publicly available reference model to identify unwanted spans and suppress learning from them while preserving the rest of each example. On synthetic code benchmarks, we show SM improves the privacy-utility tradeoff over standard masking methods and PII filtering. In fine-tuning experiments, SM reduces approximate extraction of private values from revealed prefixes from 66.3% to 2.3% and the reproduction of stylistic coding quirks from 23.6% to 1.3%, both while preserving performance on the evaluated coding tasks. We also evaluate SM for sanitizing datasets by directly removing unwanted content. Here, SM outperforms DePA, a perplexity-based defense for detecting poisoned dead code, while specialized detectors perform better on broader credential and PII benchmarks. Across eleven settings, we find that SM's downstream success is predictable from the separation of unwanted and useful content in the distribution, and it is particularly useful with code data. Ultimately, SM is an inexpensive, adaptable method to preserve valuable examples while reducing the learning of unwanted information.
Read the paper
Discussion
Science Skim's AI key points, plus readers' public thoughts
Readers' thoughts
No reader thoughts yet.
Related papers
- Prune the Leaky Neurons: Mitigating Private Data Leakage in Fine-Tuned LLMs via Joint-Embedding-Guided PruningarXiv · 2026
- Do LLMs Really Forget? Hidden-State Leakage in Model Unlearning and How to Fix itarXiv · 2026
- Uncovering the Tells: Efficient Black-Box Audits for LLM Data ContaminationarXiv · 2026
- The Price of Safety: Benign-Case Utility and Token Overhead of Memory-Poisoning Defenses in LLM AgentsarXiv · 2026
- Inadvertent Context Leakage in Language ModelsarXiv · 2026
- Prior Aware Memorization: An Efficient Metric for Distinguishing Memorization from Generalization in Large Language ModelsOpen MIND · 2026