Lune

ICLR2024Top-tier venue

Privacy-Preserving In-Context Learning for Large Language Models

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

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.

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

28 top-tier papers have cited it since. Know what they found before your reviewers do.

Questions to start from

Lune can draw on

the full paper · the top-tier papers that cite it · related work

Get the answer

Free to start. No credit card required.

Lineage

  • DP-OPT: Make Large Language Model Your Privacy-Preserving Prompt Engineer cites Language Models are Few-Shot Learners
  • DP-OPT: Make Large Language Model Your Privacy-Preserving Prompt Engineer cites Deep Learning with Differential Privacy
  • DP-OPT: Make Large Language Model Your Privacy-Preserving Prompt Engineer cites Privacy-Preserving In-Context Learning with Differentially Private Few-Shot Generation
  • Open LLMs are Necessary for Current Private Adaptations and Outperform their Closed Alternatives cites Large Language Models Can Be Strong Differentially Private Learners
  • Open LLMs are Necessary for Current Private Adaptations and Outperform their Closed Alternatives cites Language Models are Few-Shot Learners
  • Open LLMs are Necessary for Current Private Adaptations and Outperform their Closed Alternatives cites Deep Learning with Differential Privacy
  • Open LLMs are Necessary for Current Private Adaptations and Outperform their Closed Alternatives cites Privacy-Preserving In-Context Learning with Differentially Private Few-Shot Generation
  • PrE-Text: Training Language Models on Private Federated Data in the Age of LLMs cites Large Language Models Can Be Strong Differentially Private Learners
  • PrE-Text: Training Language Models on Private Federated Data in the Age of LLMs cites Privacy-Preserving Instructions for Aligning Large Language Models
  • PrE-Text: Training Language Models on Private Federated Data in the Age of LLMs cites Deep Learning with Differential Privacy
  • PrE-Text: Training Language Models on Private Federated Data in the Age of LLMs cites Privacy-Preserving In-Context Learning with Differentially Private Few-Shot Generation
  • Rethinking the Role of Demonstrations: What Makes In-Context Learning Work? cites Language Models are Few-Shot Learners
  • Rethinking the Role of Demonstrations: What Makes In-Context Learning Work? cites Calibrate Before Use: Improving Few-shot Performance of Language Models
  • Large Language Models Can Be Strong Differentially Private Learners cites Deep Learning with Differential Privacy
  • Privacy-Preserving Instructions for Aligning Large Language Models cites DP-OPT: Make Large Language Model Your Privacy-Preserving Prompt Engineer
  • Privacy-Preserving Instructions for Aligning Large Language Models cites Large Language Models Can Be Strong Differentially Private Learners
  • Privacy-Preserving Instructions for Aligning Large Language Models cites Language Models are Few-Shot Learners
  • Privacy-Preserving Instructions for Aligning Large Language Models cites Deep Learning with Differential Privacy
  • Privacy-Preserving Instructions for Aligning Large Language Models cites Privacy-Preserving In-Context Learning with Differentially Private Few-Shot Generation
  • Privacy-Preserving In-Context Learning with Differentially Private Few-Shot Generation cites Rethinking the Role of Demonstrations: What Makes In-Context Learning Work?
  • Privacy-Preserving In-Context Learning with Differentially Private Few-Shot Generation cites Large Language Models Can Be Strong Differentially Private Learners
  • Privacy-Preserving In-Context Learning with Differentially Private Few-Shot Generation cites Language Models are Few-Shot Learners
  • Privacy-Preserving In-Context Learning with Differentially Private Few-Shot Generation cites Deep Learning with Differential Privacy
  • Calibrate Before Use: Improving Few-shot Performance of Language Models cites Language Models are Few-Shot Learners
Builds onCited byLeft to right by year; the more cited, the higher.

Cited by top-tier papers28

  1. Privacy-Preserving In-Context Learning with Differentially Private Few-Shot GenerationXinyu Tang, Richard Shin, Huseyin A. Inan, Andre Manoel et al.ICLR 2024 · 111 citations
  2. DP-OPT: Make Large Language Model Your Privacy-Preserving Prompt EngineerJunyuan Hong, Jiachen T. Wang, Chenhui Zhang, Zhangheng Li et al.ICLR 2024 · 70 citations
  3. Privacy-Preserving Instructions for Aligning Large Language ModelsDa Yu, Peter Kairouz, Sewoong Oh, Zheng XuICML 2024 · 41 citations
  4. PrE-Text: Training Language Models on Private Federated Data in the Age of LLMsCharlie Hou, Akshat Shrivastava, Hongyuan Zhan, Rylan Conway et al.ICML 2024 · 30 citations
  5. Open LLMs are Necessary for Current Private Adaptations and Outperform their Closed AlternativesVincent Hanke, Tom Blanchard, Franziska Boenisch, Iyiola E. Olatunji et al.NeurIPS 2024 · 27 citations

Builds on14

  1. Language Models are Few-Shot LearnersTom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah et al.NeurIPS 2020 · 64,255 citations
  2. Deep Learning with Differential PrivacyMartín Abadi, Andy Chu, Ian J. Goodfellow, H. Brendan McMahan et al.CCS 2016 · 7,620 citations
  3. Calibrate Before Use: Improving Few-shot Performance of Language ModelsZihao Zhao, Eric Wallace, Shi Feng, Dan Klein et al.ICML 2021 · 1,843 citations
  4. Rethinking the Role of Demonstrations: What Makes In-Context Learning Work?Sewon Min, Xinxi Lyu, Ari Holtzman, Mikel Artetxe et al.EMNLP 2022 · 634 citations
  5. Large Language Models Can Be Strong Differentially Private LearnersXuechen Li, Florian Tramèr, Percy Liang, Tatsunori HashimotoICLR 2022 · 502 citations

Related papers

  1. Public Data Assisted Differentially Private In-Context LearningSeongho Joo, Hyukhun Koh, Kyomin JungEMNLP Findings 2025
  2. Data-adaptive Differentially Private Prompt Synthesis for In-Context LearningFengyu Gao, Ruida Zhou, Tianhao Wang, Cong Shen et al.ICLR 2025
  3. Privacy Preserving In-Context-Learning Framework for Large Language ModelsBishnu Bhusal, Manoj Acharya, Ramneet Kaur, Colin Samplawski et al.AAAI 2026 · 1 citation
  4. Plausible Token Amplification for Improving Accuracy of Differentially Private In-Context Learning Based on Implicit Bayesian InferenceYusuke Yamasaki, Kenta Niwa, Daiki Chijiwa, Takumi Fukami et al.ICML 2025
  5. Private prediction for large-scale synthetic text generationKareem Amin, Alex Bie, Weiwei Kong, Alexey Kurakin et al.EMNLP Findings 2024 · 5 citations
Dusk over the sea between two cliffs drawn in fine vertical lines