ContextLeak: Auditing Leakage in Private In-Context Learning Methods

Fuente: arXiv
Salvato in:
Dettagli Bibliografici
Autori principali: Choi, Jacob, Cao, Shuying, Dong, Xingjian, Banayeeanzade, Amin, Zhu, Wang Bill, Jia, Robin, Karimireddy, Sai Praneeth
Natura: Preprint
Pubblicazione: 2025
Soggetti:
Accesso online:
Tags: Aggiungi Tag
Nessun Tag, puoi essere il primo ad aggiungerne!!
_version_ 1866917424321789952
author Choi, Jacob
Cao, Shuying
Dong, Xingjian
Banayeeanzade, Amin
Zhu, Wang Bill
Jia, Robin
Karimireddy, Sai Praneeth
author_facet Choi, Jacob
Cao, Shuying
Dong, Xingjian
Banayeeanzade, Amin
Zhu, Wang Bill
Jia, Robin
Karimireddy, Sai Praneeth
contents In-Context Learning (ICL) has become a standard technique for adapting Large Language Models (LLMs) to specialized tasks by supplying task-specific exemplars within the prompt. However, when these exemplars contain sensitive information, reliable privacy-preserving mechanisms are essential to prevent unintended leakage through model outputs. Many privacy-preserving methods have been proposed to protect against information leakage in this context, but there are fewer efforts on how to audit these methods. We introduce ContextLeak, the first framework to empirically measure the worst-case information leakage in ICL. ContextLeak uses canary insertion, embedding uniquely identifiable tokens in the sensitive dataset and crafting targeted queries to detect their presence. We apply ContextLeak across a range of private ICL techniques, including both heuristic prompt-based defenses and differentially private methods with formal guarantees. We show that ContextLeak reliably detects leakage across methods, and the leakage increases monotonically with the theoretical privacy budget, offering a practical signal of worst-case privacy risk. Our analysis further reveals that existing methods strike poor privacy-utility trade-offs, either completely leaking sensitive information or severely degrading performance.
format Preprint
id arxiv_https___arxiv_org_abs_2512_16059
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle ContextLeak: Auditing Leakage in Private In-Context Learning Methods
Choi, Jacob
Cao, Shuying
Dong, Xingjian
Banayeeanzade, Amin
Zhu, Wang Bill
Jia, Robin
Karimireddy, Sai Praneeth
Cryptography and Security
Computation and Language
In-Context Learning (ICL) has become a standard technique for adapting Large Language Models (LLMs) to specialized tasks by supplying task-specific exemplars within the prompt. However, when these exemplars contain sensitive information, reliable privacy-preserving mechanisms are essential to prevent unintended leakage through model outputs. Many privacy-preserving methods have been proposed to protect against information leakage in this context, but there are fewer efforts on how to audit these methods. We introduce ContextLeak, the first framework to empirically measure the worst-case information leakage in ICL. ContextLeak uses canary insertion, embedding uniquely identifiable tokens in the sensitive dataset and crafting targeted queries to detect their presence. We apply ContextLeak across a range of private ICL techniques, including both heuristic prompt-based defenses and differentially private methods with formal guarantees. We show that ContextLeak reliably detects leakage across methods, and the leakage increases monotonically with the theoretical privacy budget, offering a practical signal of worst-case privacy risk. Our analysis further reveals that existing methods strike poor privacy-utility trade-offs, either completely leaking sensitive information or severely degrading performance.
title ContextLeak: Auditing Leakage in Private In-Context Learning Methods
topic Cryptography and Security
Computation and Language
url https://arxiv.org/abs/2512.16059