Sampling-based Pseudo-Likelihood for Membership Inference Attacks

Masahiro Kaneko, Youmi Ma, Yuki Wata, Naoaki Okazaki


Abstract
Large Language Models (LLMs) are trained on large-scale web data, which makes it difficult to grasp the contribution of each text. This poses the risk of leaking inappropriate data such as benchmarks, personal information, and copyrighted texts in the training data. Membership Inference Attacks (MIA), which determine whether a given text is included in the model’s training data, have been attracting attention. Previous studies of MIAs revealed that likelihood-based classification is effective for detecting leaks in LLMs. However, the existing likelihood-based methods cannot be applied to some proprietary models like ChatGPT or Claude 3 because the likelihood for input text is unavailable to the user. In this study, we propose a Sampling-based Pseudo-Likelihood (SPL) method for MIA (SaMIA) that calculates SPL using only the text generated by an LLM to detect leaks. The SaMIA treats the target text as the reference text and multiple outputs from the LLM as text samples, calculates the degree of n-gram match as SPL, and determines the membership of the text in the training data. Even without likelihoods, SaMIA performed on par with existing likelihood-based methods.
Anthology ID:
2025.findings-acl.465
Volume:
Findings of the Association for Computational Linguistics: ACL 2025
Month:
July
Year:
2025
Address:
Vienna, Austria
Editors:
Wanxiang Che, Joyce Nabende, Ekaterina Shutova, Mohammad Taher Pilehvar
Venue:
Findings
SIG:
Publisher:
Association for Computational Linguistics
Note:
Pages:
8894–8907
Language:
URL:
https://preview.aclanthology.org/landing_page/2025.findings-acl.465/
DOI:
Bibkey:
Cite (ACL):
Masahiro Kaneko, Youmi Ma, Yuki Wata, and Naoaki Okazaki. 2025. Sampling-based Pseudo-Likelihood for Membership Inference Attacks. In Findings of the Association for Computational Linguistics: ACL 2025, pages 8894–8907, Vienna, Austria. Association for Computational Linguistics.
Cite (Informal):
Sampling-based Pseudo-Likelihood for Membership Inference Attacks (Kaneko et al., Findings 2025)
Copy Citation:
PDF:
https://preview.aclanthology.org/landing_page/2025.findings-acl.465.pdf