Table of Contents
Fetching ...

Privacy-Preserving In-Context Learning for Large Language Models

Tong Wu, Ashwinee Panda, Jiachen T. Wang, Prateek Mittal

TL;DR

Addresses privacy leakage in in-context learning (ICL) for large language models by a general Differentially Private In-context Learning (DP-ICL) paradigm that privatizes ICL responses via a noisy consensus over disjoint exemplar sets. It provides a concrete algorithm for private top-$k$ releases on token histograms using $d_k = H_{(k)} - H_{(k+1)}$ and a noisy threshold, linking the approach to the exponential mechanism and Rényi-DP guarantees. The analysis includes privacy amplification by subsampling and limited-domain Renyi-DP bounds, establishing robust privacy protections. Empirically, DP-ICL demonstrates a strong utility-privacy tradeoff on multiple text classification and generation benchmarks.

Abstract

In-context learning (ICL) is an important capability of Large Language Models (LLMs), enabling these models to dynamically adapt based on specific, in-context exemplars, thereby improving accuracy and relevance. However, LLM's responses may leak the sensitive private information contained in in-context exemplars. To address this challenge, we propose Differentially Private In-context Learning (DP-ICL), a general paradigm for privatizing ICL tasks. The key idea for DP-ICL paradigm is generating differentially private responses through a noisy consensus among an ensemble of LLM's responses based on disjoint exemplar sets. Based on the general paradigm of DP-ICL, we instantiate several techniques showing how to privatize ICL for text classification and language generation. We evaluate DP-ICL on four text classification benchmarks and two language generation tasks, and our empirical results show that DP-ICL achieves a strong utility-privacy tradeoff.

Privacy-Preserving In-Context Learning for Large Language Models

TL;DR

Addresses privacy leakage in in-context learning (ICL) for large language models by a general Differentially Private In-context Learning (DP-ICL) paradigm that privatizes ICL responses via a noisy consensus over disjoint exemplar sets. It provides a concrete algorithm for private top- releases on token histograms using and a noisy threshold, linking the approach to the exponential mechanism and Rényi-DP guarantees. The analysis includes privacy amplification by subsampling and limited-domain Renyi-DP bounds, establishing robust privacy protections. Empirically, DP-ICL demonstrates a strong utility-privacy tradeoff on multiple text classification and generation benchmarks.

Abstract

In-context learning (ICL) is an important capability of Large Language Models (LLMs), enabling these models to dynamically adapt based on specific, in-context exemplars, thereby improving accuracy and relevance. However, LLM's responses may leak the sensitive private information contained in in-context exemplars. To address this challenge, we propose Differentially Private In-context Learning (DP-ICL), a general paradigm for privatizing ICL tasks. The key idea for DP-ICL paradigm is generating differentially private responses through a noisy consensus among an ensemble of LLM's responses based on disjoint exemplar sets. Based on the general paradigm of DP-ICL, we instantiate several techniques showing how to privatize ICL for text classification and language generation. We evaluate DP-ICL on four text classification benchmarks and two language generation tasks, and our empirical results show that DP-ICL achieves a strong utility-privacy tradeoff.
Paper Structure (5 sections, 5 theorems, 16 equations, 2 algorithms)

This paper contains 5 sections, 5 theorems, 16 equations, 2 algorithms.

Key Result

Theorem 4

Algorithm alg:rnm-find-k is $\varepsilon$-DP, and $\varepsilon_{EM}(\alpha)$-RDP s.t.

Theorems & Definitions (13)

  • Definition 1: Differential Privacy
  • Definition 2: Rényi Differential Privacy
  • Definition 3: Approximate RDP
  • Theorem 4
  • proof
  • Corollary 5: not used but may be of independent interest
  • Remark
  • proof
  • Theorem 6
  • proof
  • ...and 3 more