Machine Unlearning in 2023: Where We Are and Where It’s Headed
Last Updated on July 25, 2023 by Editorial Team
Author(s): Suyang Li
Originally published on Towards AI.
A summary of machine unlearning paradigms and methods, the motivation for machine unlearning, current challenges, and future outlook.
Have you ever lied awake at night, kept up by your brain replaying a clip of that one horribly embarrassing memory you wish you could just forget? Keeping certain memories in our minds can be unpleasant, counterproductive, or even harmful. If only our human brain has the ability to forget anything, we wanted to.
Well, it turns out machines and ML models face the same challenge: forgetting counterproductive or harmful memories isn’t always as smooth and easy as a simple click on “delete
”.
So, what is this field that helps machines forget?
Table of Contents
- Introduction to Machine Unlearning
- Applications and Motivations
- Algorithms and Evaluation
- Current Challenges
Introduction to Machine Unlearning
What is machine unlearning and how does it differ from machine learning? Why do we need machine unlearning and what value can it unlock? What is the intuition underlying existing methods and paradigms for machine unlearning?
Machine unlearning is a relatively new field that essentially teaches a trained model to “forget” a certain subset of the input dataset that it was trained on, without significantly affecting performance. There’s a variety of motivations: some personal information is no longer available per updates in data privacy policies; some data is proven to be outdated or inaccurate and is counterproductive for the model; or a model is inadvertently trained on data that perpetuates biases and we want to remove the specific bias-inducing subset.
You may be wondering: this sounds like a simple task of dropping the problematic data subset and retraining a model using the updated dataset. Why complicate it?
As it turns out, many models, such as Large Language Models like ChatGPT, often require vast computational resources to train in the first place. The forget set often constitutes only a small fraction of the total training set; thus the “retrain from scratch” approach becomes an excessively expensive and repetitive solution, necessitating a better algorithm that removes the forget set while preserving the performance of the original model.
Applications and Motivations
What are some use cases motivating the development of machine unlearning? How does machine unlearning uniquely contribute to these fields and tasks? What potential future applications are being explored, and what can we expect?
We’ve mentioned the idea that due to scaling computational resources, the advantage that machine unlearning holds over a full retrain-from-scratch is much more significant on larger datasets, often in real-life applications.
Let’s look at a few of the top application areas necessitating machine unlearning:
- Fair and ethical models (bias removal): When trained on massive real-world data, sometimes models pick up on the biases inherent to the dataset. As the model scales, the algorithm can sometimes amplify the bias. In some cases the consequence of model bias can be especially harmful, such as in models used for predictive policing in preventing crimes or hiring from a candidate pool. When these biases are identified, they should be immediately removed, and machine unlearning offers a potential way to do this and mitigate harm.
- Data updates (lifelong learning): Data for a model can become outdated after corrections or updates are made to the dataset for a variety of reasons. Through unlearning and forgetting these counterproductive data points, models can adapt to these changes and produce more accurate predictions. This is especially useful in dynamic learning models such as lifelong learning; offloading outdated or incorrect data improves both the accuracy and efficiency of computation.
- Data privacy (the right to be forgotten): This is perhaps what machine unlearning has been most commonly associated with. In a rapidly changing digital world, the laws and regulations governing digital practices are constantly updated. Forgetting certain attributes of personal data helps models stay compliant with regulations such as GDPR³ by safeguarding against data leaks or anonymization concerns.
Algorithms and Evaluation Metrics
What are the main algorithmic paradigms in machine unlearning and how are they implemented? What are the strengths and weaknesses of each? What metrics have been proposed to assess machine unlearning performance?
Methods
Essentially the logic behind removing data without completely retraining is to decrease the correlation between certain features and the output. Let’s look at a main technique, known as “data poisoning”:
- This is where we intentionally add inaccurate data to “confuse” the model about a certain feature or attribute.
Here’s an example: a model trained on a dataset of crime reports observes a trend where people between 50–60 years old are highly likely to commit crimes. As a result, it unfairly targets the 50–60 age group in future predictive crime detection. To mitigate this bias, we may generate a synthetic dataset of crime statistics among other age groups, matching that of the 50–60 age group without interfering with other features. This weakens the strength of the correlation between conviction and the 50–60 age group.
Evaluation metrics
Since this is a relatively new field, many evaluation standards are still being proposed every day to better assess machine unlearning performance. Below, we highlight a few of the proposed evaluation metrics to measure the quality and effectiveness of machine unlearning methods:
- Forgetting rate: measures the proportion of data samples that originally belonged to a dataset but are no longer recognized after the unlearning process.
- Membership Inference Attack: measures the degree to which an adversary can correctly infer whether a data sample is part of the training set for the model. This metric is especially relevant in security contexts.
Current Challenges
What are the major challenges facing the Machine Unlearning field as a whole? What are the challenges that emerge in specific contexts or applications?
Machine unlearning can be quite an intricate task for a number of reasons. In fact, in July 2023 Google launches a public competition with the aim of unifying and advancing effective machine unlearning methods.
- Lack of standardized evaluation. Although a number of publications have addressed the notion of a unified assessment metric by using well-known datasets such as CIFAR10 and CIFAR100 as benchmarks, there lacks a universal evaluation standard that can unify the results produced by different researchers in the field.
In fact, this is one of the aims of Google’s recent machine unlearning challenge — to provide a platform to compare different methods “apple-to-apple”². - Susceptibility to adversarial attacks. Research has found that models that have been taught to unlearn some data subsets can fall prey to camouflaged attacks because of the poisoning mechanism involved in unlearning.
Future directions
These current obstacles provide potential directions for interesting future research questions:
- How do we train models to defend against camouflaged poisoning attacks?
- How can we leverage computational resources to optimize unlearning efficiency?
- How can we effectively clean and generate data to overcome the lack of training data?
- How can we unify a set of standards to assess unlearning algorithms to ensure consistent evaluation?
Conclusion
Thanks for sticking with me this far! In this article, we walked through the field of machine unlearning, including its main motivations and application areas, existing methods and paradigms, and current challenges.
Later in this series, we will take a deeper dive into the technical aspects of existing unlearning algorithms and Python implementations with real statistical and image datasets. Happy codingU+270CU+1F3FC!
Bibliography
[1] Shaik, T., Tao, X., Xie, H., Li, L., Zhu, X., & Li, Q. (2023). Exploring the Landscape of Machine Unlearning: A Comprehensive Survey and Taxonomy. https://doi.org/10.48550/ARXIV.2305.06360
[2] Announcing the first Machine Unlearning Challenge. (2023, June 29). Ai.googleblog.com. https://ai.googleblog.com/2023/06/announcing-first-machine-unlearning.html
[3] European Union Agency for Fundamental Rights. (2019). The General Data Protection Regulation: One year on civil society: awareness, opportunities, and challenges. Publications Office. https://data.europa.eu/doi/10.2811/538633
Join thousands of data leaders on the AI newsletter. Join over 80,000 subscribers and keep up to date with the latest developments in AI. From research to projects and ideas. If you are building an AI startup, an AI-related product, or a service, we invite you to consider becoming a sponsor.
Published via Towards AI