Abstract
Differential Privacy (DP) is the gold standard for protecting sensitive information in datasets, yet applying it to word embeddings often results in a significant loss of utility. This paper introduces Neighbourhood-Aware Differential Privacy (NADP), a mechanism that adaptively adjusts noise levels based on the local density of the embedding space. By applying less noise to words in dense clusters and more to those in sparse regions, NADP achieves a superior balance between privacy and performance in downstream NLP tasks. Empirical evaluations demonstrate that NADP consistently outperforms standard uniform noise mechanisms across word similarity, text classification, and semantic textual similarity benchmarks.
Introduction: The Geometry of Privacy
The core challenge in protecting word embeddings lies in the non-uniform distribution of the vector space. In dense regions, where many words are semantically similar (e.g., "happy," "joyful," "cheerful"), a small amount of noise is sufficient to hide a word among its neighbors. However, in sparse regions, unique or "lonely" words remain exposed unless significantly more noise is applied.
Existing DP mechanisms often apply a uniform level of noise to every word. This creates a major trade-off: adding enough noise to protect isolated words often "blurs" dense regions so much that the embeddings lose their semantic utility for AI tasks.
Methodology
NADP addresses this through a three-step adaptive process:
- Graph Construction: The vocabulary is modeled as a nearest-neighbor graph, where connections are determined by top-K proximity and Jaccard similarity.
- Neighborhood Factorization: The graph is decomposed into connected components, effectively clustering words into semantic neighborhoods.
- Adaptive Gaussian Noise: Instead of a global setting, NADP calculates local sensitivity for each cluster. It applies higher perturbation to words in sparse neighborhoods to ensure they are disguised, while using less noise in dense neighborhoods to preserve semantic precision.
Crucially, the authors provide a formal mathematical proof that this neighborhood-specific approach satisfies the rigorous requirements of $(\epsilon, \delta)$-Differential Privacy.
Experimental Evaluation
The study utilized 300-dimensional GloVe embeddings (trained on 42B tokens) and evaluated utility across several downstream tasks, including word similarity (MEN, SimLex-999), Semantic Textual Similarity (STS Benchmark), text classification (movie and customer reviews), and an "Odd-Man-Out" task.
Key Results and Insights
NADP consistently outperformed existing state-of-the-art mechanisms, such as Mahalanobis DP and standard Gaussian/Laplacian noise, across all evaluated tasks.
As shown in the results, NADP maintains significantly higher accuracy and correlation scores even under strict privacy requirements (low $\epsilon$). Qualitatively, NADP proved more effective at preventing re-identification; while other mechanisms might still leave a sensitive word like "hitler" as a top neighbor of its anonymized version, NADP successfully replaces such words with semantically distant neighbors.
Conclusion
By leveraging the local geometry of word embeddings, NADP provides a more nuanced and effective approach to differential privacy in NLP. Future research will focus on extending this mechanism to contextual embeddings (like BERT) and investigating how noise injection might interact with existing social biases in the data.
Summary updated