mlsanityData to 7 Oct 2026

Extracting books from production language models

arXiv 2601.02671 ↗First posted 6 Jan 2026cs.CL cs.AI cs.LGcited by 16

On the map: LLM safety and security → Machine unlearning

Abstract (arXiv)

Many unresolved legal questions over LLMs and copyright center on memorization: whether specific training data have been encoded in the model's weights during training, and whether those memorized data can be extracted in the model's outputs. While many believe that LLMs do not memorize much of their training data, recent work shows that substantial amounts of copyrighted text can be extracted from open-weight models. However, it remains an open question if similar extraction is feasible for production LLMs, given the safety measures these systems implement. We investigate this question using a two-phase procedure: (1) an initial probe to test for extraction feasibility, which sometimes uses a Best-of-N (BoN) jailbreak, followed by (2) iterative continuation prompts to attempt to extract the book. We evaluate our procedure on four production LLMs -- Claude 3.7 Sonnet, GPT-4.1, Gemini 2.5 Pro, and Grok 3 -- and we measure extraction success with a score computed from a block-based approximation of longest common substring (nv-recall). With different per-LLM experimental configurations, we were able to extract varying amounts of text. For the Phase 1 probe, it was unnecessary to jailbreak Gemini 2.5 Pro and Grok 3 to extract text (e.g, nv-recall of 76.8% and 70.3%, respectively, for Harry Potter and the Sorcerer's Stone), while it was necessary for Claude 3.7 Sonnet and GPT-4.1. In some cases, jailbroken Claude 3.7 Sonnet outputs entire books near-verbatim (e.g., nv-recall=95.8%). GPT-4.1 requires significantly more BoN attempts (e.g., 20X), and eventually refuses to continue (e.g., nv-recall=4.0%). Taken together, our work highlights that, even with model- and system-level safeguards, extraction of (in-copyright) training data remains a risk for production LLMs.

Key facts. Cited by 16 papers in the map (data through 7 Oct 2026). Placed in Machine unlearning, one of 12 directions in LLM safety and security. Builds on 25 of its 73 references that are in the map. First posted on arXiv 6 Jan 2026.

Builds on

25 of 73 references.

Closest ancestors · 2

Same direction, newest first

  1. 2025Hubble: a Model Suite to Advance the Study of LLM Memorization22 Oct
  2. 2024Rethinking LLM Memorization through the Lens of Adversarial Compression23 Apr

Other references · 23

  1. 2022Training language models to follow instructions with human feedbackcited by 15,712
  2. 2021Evaluating Large Language Models Trained on Codecited by 8,053
  3. 2017Deep reinforcement learning from human preferencescited by 3,846
  4. 2021Finetuned Language Models Are Zero-Shot Learnerscited by 3,747
  5. 2024Gemini 1.5: Unlocking multimodal understanding across millions of tokens of contextcited by 3,175
  6. 2023Universal and Transferable Adversarial Attacks on Aligned Language Modelscited by 2,914
  7. 2020Extracting Training Data from Large Language Modelscited by 2,144
  8. 2019Fine-Tuning Language Models from Human Preferencescited by 2,124
  9. 2023Pythia: A Suite for Analyzing Large Language Models Across Training and Scalingcited by 1,734
  10. 2023Jailbroken: How Does LLM Safety Training Fail?cited by 1,565
  11. 2022Quantifying Memorization Across Neural Language Modelscited by 755
  12. 2021Deduplicating Training Data Makes Language Models Bettercited by 705
11 more
  1. 2019Does Learning Require Memorization? A Short Tale about a Long Tailcited by 452
  2. 2023Scalable Extraction of Training Data from (Production) Language Modelscited by 415
  3. 2021Unsolved Problems in ML Safetycited by 291
  4. 2025Constitutional Classifiers: Defending against Universal Jailbreaks across Thousands of Hours of Red Teamingcited by 172
  5. 2023Talkin' 'Bout AI Generation: Copyright and the Generative-AI Supply Chaincited by 45
  6. 2024Measuring memorization in language models via probabilistic extractioncited by 40
  7. 2025Extracting memorized pieces of (copyrighted) books from open-weight language modelscited by 27
  8. 2024The Files are in the Computer: On Copyright, Memorization, and Generative AIcited by 20
  9. 2024Context-Aware Membership Inference Attacks against Pre-trained Large Language Modelscited by 20
  10. 2025Exploring the limits of strong membership inference attacks on large language modelscited by 20
  11. 2023Report of the 1st Workshop on Generative AI and Lawcited by 12

Built on by

Cited by year (2026 to 7 Oct)

Citing papers per year: 2026: 16.

16 papers.

Sort:

By area:

  1. 2026Alignment Whack-a-Mole : Finetuning Activates Verbatim Recall of Copyrighted Books in Large Language Modelscited by 6
  2. 2026Characterizing Memorization in Diffusion Language Models: Generalized Extraction and Sampling Effectscited by 3
  3. 2026Memorization Dynamics in Knowledge Distillation for Language Modelscited by 2
  4. 2026Merlin: Deterministic Byte-Exact Deduplication for Lossless Context Optimization in Large Language Model Inferencecited by 2
  5. 2026Copyright Detective: A Forensic System to Evidence LLMs Flickering Copyright Leakage Riskscited by 1
  6. 2026Both Ends Count! Just How Good are LLM Agents at "Text-to-Big SQL"?cited by 1
  7. 2026LLMs Can Leak Training Data But Do They Want To? A Propensity-Aware Evaluation of Memorization in LLMscited by 1
  8. 2026IDP-Bench: Benchmarking ability of LLMs to protect personal information in interdependent privacy contextscited by 1
  9. 2026Learning to Detect Language Model Training Data via Active Reconstructioncited by 0
  10. 2026Overcoming Copyright Barriers in Corpus Distribution Through Non-Reversible Hashingcited by 0
  11. 2026FindMyText: Robust, Scalable Detection of Text Containment in Large Web-Crawled Corporacited by 0
  12. 2026Extractable Memorization From First Principlescited by 0
4 more
  1. 2026Reasoning or Memorization: Can LLMs Understand and Generate Chinese Xiehouyu Riddles?cited by 0
  2. 2026What to Forget in Unlearning? Forget Set Curation for Language Modelscited by 0
  3. 2026CopyShield: A Cross-Level Benchmark of Copyright Defenses in LLMscited by 0
  4. 2026Detecting Pretraining Data in Large Language Models from a Free-Energy Perspectivecited by 0