Skip to content

A Statistical Framework for LLM Training Data AuditingA Statistical Framework for Training Data Auditing of Large Language Models

arXiv: 其他 AI 安全论文· arXiv:2611.26264· Shengjie Niu, Yeheng Ge, Jian HuangDepartment of Data Science and Artificial Intelligence, The Hong Kong Polytechnic University; Department of Applied Mathematics, The Hong Kong Polytechnic UniversityIndexed by this site · 4 days ago· Originally publishedAttacks· Its place in the scan record →

Quick read

Analysis and theory

Based on the paper PDF (AI-generated); refer to the original

The authors propose a training data audit statistical framework that uses Cauchy combination to aggregate chunk-level membership evidence, and validate three layers of auditing—document-level, set-level and subset identification—on Pile–arXiv, Cosmopedia and HCM.

Questions
Training data auditing must determine whether a specific document was used to train an LLM, which concerns privacy, copyright and benchmark contamination. The difficulty is that membership signals may be concentrated in only a few passages of a long document, and chunk-level and document-level evidence are correlated with each other; existing methods lack corresponding error-control guarantees.
Methods
The authors propose a multi-level statistical framework: first use logistic regression to combine multiple kinds of chunk-level membership evidence into a single evidence, then aggregate it with Cauchy combination into a document score sensitive to localized signals; empirical calibration gives document-level p-values, the Energy permutation test performs set-level global auditing, and the BH procedure identifies suspicious subsets while controlling FDR, with finite-sample error guarantees under a conditional exchangeability assumption.
Experiments and results
On Pile–arXiv (Pythia-6.9B), Cosmopedia (fine-tuned Pythia-2.8B) and HCM (fine-tuned Llama-3.2-3B-Instruct), this paper's method has mostly better document-level discrimination metrics than the baselines; the Energy test's rejection rate can reach 100% at high member proportions, and the empirical FDR of BH is below the nominal level of 10% in all configurations, but subset identification power on Pile–arXiv is only about 11–13%.
Limitations and future work
The authors state that the open questions include: how to select or reweight reference documents under temporal and domain shift while maintaining error control, and how to allocate documents to improve test power when the reference data budget is limited. The experiments cover three target models and four datasets; set-level experiments use 1,000 sampled sets per configuration; the BookTection results are in the supplementary material, and the main text gives no numbers for them.
Experimental setupPythia-6.9B、Pythia-2.8B et al. · BookTection、Pile–arXiv et al. · AUC、TPR@FPR et al.
Threat model
Black-box setting: the auditor can query the target model with token sequences and obtain the conditional probability of each token, but cannot access the model's internal parameters or the membership labels of target documents; fine-tuning data auditing additionally assumes black-box query access to the reference model used to initialize fine-tuning.
Evaluated models
Pythia-6.9BPythia-2.8BLlama-3.2-3B-Instruct
Benchmarks
BookTectionPile–arXivCosmopediaHealthCareMagic (HCM)
Metrics
AUCTPR@FPRrejection rateempirical powerempirical FDR
AI summaryResearchers propose a unified statistical framework for auditing whether specific data was used to train an LLM, serving privacy auditing, copyright protection, and benchmark contamination detection. Addressing the problem that membership signals may be concentrated in only a few passages of long documents, the framework uses Cauchy combination to aggregate complementary chunk-level membership evidence into document scores, completing document-level membership inference; document scores and calibrated p-values further support overall evaluation of a target dataset and identify suspicious documents through multiple testing. Under exchangeability conditions, the paper proves that document-level p-values have finite-sample validity, that the global audit controls the type I error, and that subset identification controls the false discovery rate (FDR). Case studies on BookTection, Pile-arXiv, Cosmopedia, and HealthCareMagic show that the framework can effectively and reliably audit pretraining and fine-tuning data.

Researchers propose a unified statistical framework for auditing whether specific data was used to train an LLM, serving privacy auditing, copyright protection, and benchmark contamination detection. Addressing the problem that membership signals may be concentrated in only a few passages of long documents, the framework uses Cauchy combination to aggregate complementary chunk-level membership evidence into document scores, completing document-level membership inference; document scores and calibrated p-values further support overall evaluation of a target dataset and identify suspicious documents through multiple testing. Under exchangeability conditions, the paper proves that document-level p-values have finite-sample validity, that the global audit controls the type I error, and that subset identification controls the false discovery rate (FDR). Case studies on BookTection, Pile-arXiv, Cosmopedia, and HealthCareMagic show that the framework can effectively and reliably audit pretraining and fine-tuning data.

Paper analysis

6 questions; open one to read the full answer

  1. What problem does this paper attempt to solve?

    How to perform document-level, set-level and subset-level auditing with error control on LLM training data under conditions of correlated evidence and localized signals.

    Core question: determine whether a specific document or set of documents was used to train a given LLM (training data audit), and give conclusions with statistical error guarantees when the evidence is mutually correlated.

    • Application scenarios: According to the authors, this concerns privacy auditing, copyright protection and benchmark contamination detection, with typical targets including copyrighted books and scientific papers in pretraining, and synthetic text and medical Q&A records in fine-tuning.
    • Shortcomings of existing methods: The authors argue that the tests and uncertainty estimates used by dataset inference-type methods (e.g., Maini et al. 2024) rely on independence assumptions and lack validity guarantees for correlated document sets; moreover, most give only set-level conclusions and lack a per-document suspicious list.
    • Core observation: Membership signals may be concentrated in only a few passages of a long document, and simple averaging dilutes local signals; chunk evidence within the same document and document scores within the same set are correlated because they share fitting rules and calibration data.
    • What the paper proposes: A unified statistical framework covering three goals—document-level membership inference (Problem 1), global audit of a target set (Problem 2), and suspicious subset identification with FDR control (Problem 3)—with finite-sample error guarantees under a conditional exchangeability assumption.
    • Audit setting (model access):
      • Goal: determine whether a document/set entered the target model's training set.
      • Knowledge: black-box—token conditional probabilities can be queried, with no internal parameters or membership labels.
      • Capability: obtain probabilities via a token-scoring API or a self-hosted interface; fine-tuning audits can additionally query the reference model used to initialize fine-tuning.
      • Victim system: the target LLM after pretraining or fine-tuning (in the experiments, the Pythia and Llama series).
  2. What related research exists?

    Related work falls into three categories: membership inference and evidence statistics, dataset-level inference, and statistical tools for multiple testing and combining tests.

    Membership inference (MIA) and evidence statistics

    • Shokri et al. (2017) proposed membership inference attacks; Carlini et al. (2022) gave likelihood-ratio-based membership inference; Yeom et al. (2018) used perplexity for overfitting and privacy risk analysis.
    • Shi et al. (2024) proposed Min-K% for detecting pretraining data; Xie et al. (2024)'s Recall uses relative conditional log-likelihood; Chen et al. (2026) studied window-based membership inference against fine-tuned LLMs, which this paper cites to show that the signal is concentrated in local passages.
    • Puerto et al. (2025) studied when large-scale membership inference succeeds; its Mann–Whitney U aggregation is used in this paper as a comparison method.

    Dataset-level inference

    • Maini et al. (2024) proposed dataset inference, which tests whether members of a target dataset were used for training; the paper points out that the test in such methods relies on an independence assumption and lacks validity guarantees for correlated document sets.
    • Duarte et al. (2024)'s DE-COP detects copyrighted content in training data and proposes the BookTection benchmark; the paper points out that its simple averaging of chunk evidence dilutes local signals.
    • Oren et al. (2023) studied proving test-set contamination of black-box language models.

    Statistical tools

    • Liu & Xie (2020)'s Cauchy combination test can combine p-values under arbitrary correlation structures; Székely & Rizzo (2013)'s energy statistics provide a distance-based two-sample discrepancy measure.
    • Benjamini & Hochberg (1995)'s BH procedure controls FDR, and Benjamini & Yekutieli (2001) gives FDR control under positive correlation; Bates et al. (2023) points out that shared calibration data causes empirical p-values to be correlated.

    Baselines and benchmarks: The document-level discrimination baselines are PPL, Min-K%, Mean-evidence, Mann–Whitney U (Pile–arXiv) and Ref-Difference, Ref-Ratio, ICP-MIA-SP, ICP-MIA-Ref (Cosmopedia, HCM); the benchmarks are BookTection, Pile–arXiv, Cosmopedia, HealthCareMagic.

    The authors position this paper as: integrating these statistical tools into a unified audit framework that retains finite-sample error guarantees under evidence correlation, and supplementing existing dataset-level methods with the per-document suspicious list they lack.

  3. How does the paper address this problem?

    First synthesize chunk-level evidence, then combine it into a document score using Cauchy; empirical calibration, the Energy permutation test and BH support the three levels of auditing respectively.

    Overall approach: with documents as the inference unit and chunks as the operation unit, multiple membership evidence statistics are combined into chunk-level evidence, aggregated into a document score sensitive to local signals, and then used respectively to support individual tests, a global two-sample test, and FDR-controlled subset identification (Figure 1).

    Problem Formulation

    • Three goals: Problem 1 tests H0,i for each document: not in the training set; Problem 2 tests whether the document score distributions of the target set and a known non-member calibration set are the same (H0glob: Ptarget = Pcal); Problem 3 controls FDR at a preset level q over m document hypotheses and returns a set of suspicious documents.
    • Required data: an auxiliary fitting set Rfit with known membership labels, a base set Rbase of known non-members (chunk-level calibration), and a held-out non-member calibration set Rcal (document-level calibration and global comparison).

    Chunk-level Evidence Combination

    • Evidence statistics: d evidence statistics are computed for each chunk, such as perplexity (smaller means more member-like) and Min-K% (the average over the ρ% tokens with the lowest log probabilities; larger means more member-like); the remaining statistics are given in supplementary material S1.
    • Logistic combination: a logistic regression Pr{y(c)=1} = σ(β0 + ∑r βr er(c)) is fitted on the chunk–label pairs from Rfit, frozen, and its logit is taken as the combined evidence ecom(c); the authors note that this logit approximates the log-likelihood ratio of the member and non-member evidence distributions.

    Cauchy Document Score and Individual Calibration

    • Chunk-level p-values: empirical right-tail p-values of ecom are computed using the nbase non-member chunks in Rbase.
    • Cauchy aggregation: the document score is T_{Cauchy}(d_i) = \frac{1}{J(d_i)} \sum_j \cot(\pi [p^{ck}_{ij}]_\varepsilon), where [p]ε truncates p to [ε, 1−ε]; small chunk p-values are mapped to large positive contributions, allowing a few signal-bearing chunks to dominate the document score.
    • Individual p-values: empirical right-tail calibration of the document score using the ncal non-member documents in Rcal; H0,i is rejected when pi ≤ α.

    Global Audit and Subset Identification

    • Energy permutation test: Cauchy scores are transformed to (0,1) via u(d) = 1/2 − arctan(T)/π, the energy discrepancy is used to measure the difference between the target and calibration distributions, and B uniform permutations yield pglobal; the authors argue that, compared with the t-test used by Maini et al. (2024), the energy discrepancy also responds to changes in dispersion and shape.
    • BH subset identification: BH is run at level q on the m document-level p-values, returning a set of suspicious documents.

    Theoretical Guarantees

    • Three theorems: under the conditional exchangeability of Assumption 4.2, document-level p-values are finite-sample valid (Theorem 4.3), the Energy test controls the global type I error (Theorem 4.4), and BH controls FDR (Theorem 4.5).
    • Robustness: Theorem 4.6 gives that when exchangeability is violated, each error bound increases by at most the total variation distance δ of the joint distribution. Proposition 4.1 quantitatively characterizes the contribution of local evidence to the Cauchy score.
  4. What experiments did the paper conduct?

    Three main-text case studies (Pile–arXiv, Cosmopedia, HCM) cover the three levels of auditing; this paper's method has mostly better document-level metrics than the baselines, and the empirical FDR of BH is below the nominal 10% in all cases.

    Experimental setup

    • Models tested: Pythia-6.9B (Pile–arXiv pre-training audit), Pythia-2.8B (Cosmopedia fine-tuning audit, 10,000 documents trained for 10 epochs), Llama-3.2-3B-Instruct (HCM fine-tuning audit, 89,732 records, checkpoint at epoch 2).
    • Datasets: Pile–arXiv (79,046 training shard articles, 4,841 held-out articles, 8 chunks of 1,024 tokens per article); Cosmopedia web_samples_v2 (10,345,867 entries, first 512 tokens per document, no chunking); HCM (112,165 question-answer records); BookTection (165 books, Medium setting with 128-token passages, results in supplementary material S5).
    • Baselines: on Pile–arXiv, PPL, Min-K%, Mean-evidence, Mann–Whitney U; on Cosmopedia and HCM, Ref-Difference, Ref-Ratio, ICP-MIA-SP, ICP-MIA-Ref.
    • Metrics: individual auditing reports AUC and TPR@1%, 5% FPR; global auditing reports rejection rate at α=0.05; subset identification reports empirical power and empirical FDR at q=0.10.
    • Set-level protocol: 1,000 target sets sampled per configuration, set size m ∈ {30, 50, 100}, member proportions 10%–100%, plus all-non-member sets to evaluate false positives.

    Main results

    Swipe horizontally to read the table

    Dataset (model)MethodTPR@1%TPR@5%AUC
    Pile–arXiv (Pythia-6.9B)Cauchy (OURS)15.6023.0075.54
    Pile–arXiv (Pythia-6.9B)Mean-evidence7.4019.8076.04
    Cosmopedia (fine-tuned Pythia-2.8B)OURS15.2039.0084.80
    Cosmopedia (fine-tuned Pythia-2.8B)Ref-Ratio10.8230.0480.69
    HCM (fine-tuned Llama-3.2-3B-Instruct)OURS53.4582.1197.00
    HCM (fine-tuned Llama-3.2-3B-Instruct)ICP-MIA-SP29.3467.5693.48

    (Units %; based on Tables 1–3, only this paper's method and the strongest baseline are listed per dataset.)

    • The authors state that on Pile–arXiv, Cauchy outperforms PPL and Min-K% on all three metrics, with higher TPR than Mann–Whitney U; AUC is slightly lower than Mean-evidence (75.54% vs. 76.04%), but TPR@1% FPR rises from 7.40% to 15.60%.
    • The authors state that on Cosmopedia, this paper's method improves AUC and TPR@1% FPR by 4.11 and 4.38 percentage points respectively over the strongest baseline, Ref-Ratio.
    • The authors state that on HCM, this paper's method has TPR@1% FPR 24.11 percentage points higher than the strongest baseline, ICP-MIA-SP; the strongest baseline changes from Ref-Ratio on Cosmopedia to ICP-MIA-SP on HCM, indicating that the relative roles of reference-model comparison and contextual evidence vary with the scenario.

    Global auditing (Energy permutation test)

    • What was measured: rejection rates under different member proportions and set sizes (Figures 2, 4, 6).
    • Results: on Pile–arXiv the rejection rate rises with member proportion and set size, from about 75% at set size 30 to about 100% at set size 100 at 50% member proportion; on Cosmopedia it rises from 9.1–26.2% at 10% member proportion to 96.7–100% at 50%; on HCM the rejection rate reaches 100% for all set sizes at 50% member proportion.
    • Authors' interpretation: even when single-document discrimination is modest, accumulated evidence within a set can produce a detectable distribution shift.

    Suspicious subset identification (BH, q=0.10)

    • What was measured: empirical power and empirical FDR of BH under each configuration (Figures 3, 5, 7).
    • Results: the empirical FDR on all three datasets is below the nominal 10%; on Pile–arXiv power is only about 11–13% even for all-member sets, and at 50% member proportion BH identifies fewer than 10% of members; on Cosmopedia power is below one third throughout; on HCM power is about 75% at 50% member proportion and above 90% at higher proportions.
    • Authors' interpretation: the gap between global detection and subset identification is clear—a set may be judged to contain members while only a small fraction of them can be identified; the strong document-level signals on HCM also support more complete member recovery.

    Other ablations and analyses

    • Calibration set size (HCM, supplementary material S7): at m=30, calibration sets of 1,000, 5,000 and 10,000 documents show similar BH performance at most member proportions.
    • Calibration answer-length composition (HCM, S7): as the share of long answers increases, power and empirical FDR rise together; under long-answer-heavy conditions, FDR at 10% member proportion exceeds q=0.10.
    • Other comparisons of document scoring rules are given in the BookTection case (supplementary material S5); the main text reports no numbers.
  5. What are some points that can be further explored?

    The authors propose two follow-up problems: reference document selection/reweighting and finite-budget allocation; the experiments cover three models and four datasets.

    Limitations and future directions noted by the authors

    • Reference document selection (Section 6): how to select or reweight reference documents to cope with temporal and domain shift while maintaining error control; the authors state this requires further study.
    • Reference data budget allocation (Section 6): when the reference data budget is limited, how to allocate documents to improve detection power; the authors state this requires further study.
    • Calibration population representativeness (Section 5.4): the authors point out that interpreting distribution shift as evidence of training use requires a suitable non-member control population; differences in topic, time or source may affect scores without training exposure.
    • Deployment prerequisites (Section 5.4): the authors point out that the reported performance corresponds to specific model access and auxiliary data conditions, and deployment requires corresponding model outputs, a reference model, auxiliary labels for fitting, and held-out non-members.
    • Effect of training exposure (Section 5.4): the authors believe that audit performance should be interpreted together with training exposure; limited identification may reflect weak observable signals left by the target document rather than method failure.

    Scope of experiments

    • The models tested are Pythia-6.9B, Pythia-2.8B and Llama-3.2-3B-Instruct, 3 in total.
    • The datasets are BookTection, Pile–arXiv, Cosmopedia and HCM, 4 in total; the BookTection results are in supplementary material S5, and the main text gives no numbers for them.
    • Set-level experiments use 1,000 sampled sets per configuration, m ∈ {30, 50, 100}, member proportions 10%–100%, plus all-non-member sets.
    • Fine-tuning auditing covers two epoch settings (Cosmopedia 10 epochs, HCM the checkpoint at epoch 2).
    • The paper does not report the number of permutations B for the Energy permutation test, the size of the chunk-level calibration set Rbase, or the size of the fitting set Rfit for each case.
  6. Summarize the main content of the paper

    A three-layer training data audit statistical framework: Cauchy aggregation of local evidence, with empirical calibration, the Energy test and BH each yielding conclusions with error guarantees.

    This is a statistical methods paper on LLM training data auditing—determining whether a document was used for pre-training or fine-tuning—serving privacy, copyright and benchmark contamination scenarios.

    • Problem: membership signals are often concentrated in a few passages of long documents, and chunk evidence and document scores are correlated because they share fitting rules and calibration data; the authors believe existing dataset inference methods rely on independence assumptions, lack validity guarantees, and rarely provide per-document suspicious lists.
    • Method: use logistic regression to combine statistics such as perplexity and Min-K% into chunk-level evidence, and Cauchy combination to aggregate it into a document score sensitive to localized signals; empirical calibration gives document-level p-values, the Energy permutation test performs set-level global auditing, and BH identifies suspicious subsets while controlling FDR; under a conditional exchangeability assumption it gives finite-sample p-value validity, global type I error control and FDR control, with error inflated by at most δ when the assumption is violated.
    • Document-level results: on Pile–arXiv (Pythia-6.9B), Cauchy's TPR@1% FPR is 15.60%, higher than Mean-evidence's 7.40%, with slightly lower AUC (75.54% vs. 76.04%); Cosmopedia (fine-tuned Pythia-2.8B) AUC 84.80%; HCM (fine-tuned Llama-3.2-3B-Instruct) AUC 97.00%, TPR@1% FPR 53.45%, 24.11 percentage points higher than the strongest baseline.
    • Set-level and subset results: on Cosmopedia at 50% member proportion the Energy rejection rate is 96.7–100%, and on HCM it reaches 100%; the empirical FDR of BH is below the nominal 10% in all configurations, but power on Pile–arXiv is only about 11–13%, and on HCM at 50% member proportion it is about 75%.
    • Authors' conclusions: global detection and subset identification are goals of different difficulty; a set may be judged to contain members without most members being identifiable; fine-tuning data leave stronger document-level signals than pre-training data; audit conclusions should be interpreted together with training exposure and the representativeness of the non-member control population.
Read originalarxiv.org