Abstract
Large language models (LLMs) and generative AI have played a transformative role in computer research and applications. Controversy has arisen as to whether these models output copyrighted data, which can occur if the data the models are trained on is copyrighted. LLMs are built on the transformer neural network architecture, which in turn relies on a mathematical computation called Attention that uses the softmax function. In this paper, we observe that large model training and optimization can be seen as a softmax regression problem. We then establish a method of efficiently performing softmax regression, in a way that prevents the regression function from generating copyright data. This establishes a theoretical method of training large language models in a way that avoids generating copyright data.
Introduction
Generative AI models are prone to "memorization"—the tendency to output direct copies or close variants of their training data. This creates significant legal and ethical hurdles when training sets include copyrighted books, articles, and code. Current solutions, such as removing copyrighted data or using post-processing rejection sampling, are often inefficient or degrade model performance.
This paper introduces copyright regression, a new mathematical framework that prevents LLMs from memorizing protected content. By modifying the standard training objective to include an inverse penalty term for copyrighted segments, the authors provide a "plug-and-play" method that guarantees data protection without sacrificing overall model utility.
Methodology
The approach bridges the gap between high-level transformer architectures and classical optimization theory through three key steps:
- Softmax Regression Framing: The authors demonstrate that training the attention mechanism in transformers can be mathematically viewed as a softmax regression problem.
-
Copyright Regression Objective: A modified loss function is introduced. While standard training minimizes the loss $L$ between model output and target data, copyright regression adds an inverse loss term for copyrighted data: $$L_{modified} = L(GeneralData) + \gamma_c \cdot [L(CopyrightData)]^{-1}$$ If the model begins to "memorize" the copyrighted data, the copyright loss becomes very small, causing the inverse term to increase sharply. This creates a mathematical barrier against fitting protected patterns.
-
Theoretical Guarantees: The authors prove that this objective function remains convex and has a Lipschitz-continuous Hessian, ensuring that standard optimization tools like Gradient Descent remain reliable and stable.
Experimental Setup
The method was evaluated using the Wikitext2 dataset. To simulate copyright protection, specific proportions of the dataset (ranging from 10% to 80%) were designated as "copyrighted" data. The goal was to prevent the model from memorizing these specific strings while maintaining learning efficacy on the remainder of the set.
Results and Discussion
The approach was tested on a modified GPT-2 model, termed CR-GPT-2.
Regurgitation Prevention
In baseline GPT-2 models, the difference in loss between copyrighted and non-copyrighted data is near zero. In CR-GPT-2, the "copyright gap" ($\tau_{CE}$) remained stable above 0.5, effectively preventing the model from outputting protected text. As shown in the figures above, increasing the protection parameter $\gamma_c$ directly increases the copyright gap, providing a controllable level of protection.
Stable Performance
Despite the strict protection, the model’s perplexity (a measure of text prediction quality) on the general test set remained stable. This confirms that data can be protected without compromising the AI's core intelligence. The parameter $\gamma_c$ acts as a "protection dial," allowing developers to balance strict copyright guarantees against raw performance.
Efficiency
The time cost per training iteration remained within the same complexity class as standard training, making the method feasible for large-scale applications without requiring separate "filter" models or expensive post-processing.
Limitations and Future Work
While the theoretical foundation is robust, several challenges remain:
- Scaling: Experiments were conducted on GPT-2; testing on "frontier" models with hundreds of billions of parameters is a necessary next step.
- Similarity Definitions: The model uses regression loss as a proxy for infringement, but legal "substantial similarity" may involve paraphrasing or stylistic mimicry not captured by simple math.
- Data Labeling: The method requires prior knowledge of which data is copyrighted, which is a significant challenge for multi-terabyte web-scale datasets.
Summary updated