Abstract
Continual Learning (CL) aims to enable AI models to accumulate knowledge over time, yet neural networks frequently suffer from catastrophic forgetting. Existing solutions often require storing large model copies or sensitive training data, posing storage and privacy challenges. We present a framework for Learning with Lightweight Snapshots, which utilizes tiny parameter modules called adapters to create efficient "snapshots" of previous tasks. By combining these snapshots with a novel Exponential Mean Squared Error (E-MSE) distillation loss and representation recalibration, our method achieves superior performance in Class-Incremental Learning (Class-IL) while requiring only a fraction of the storage typically needed for large-scale language models.
Introduction
In the field of Natural Language Processing (NLP), Continual Learning (CL) is essential for developing systems that can adapt to new domains without losing previously acquired skills. However, standard fine-tuning leads to "catastrophic forgetting," where new task updates overwrite weights critical for past tasks. This is particularly problematic in Class-Incremental Learning (Class-IL), where the model must distinguish between all classes seen across multiple tasks without knowing the task identity at test time.
Current approaches generally fall into two categories: exemplar-based methods, which replay old data (raising privacy concerns), and regularization methods, which often require storing full model checkpoints for every task—a prohibitive requirement for large models like BERT.
Methodology: Learning with Lightweight Snapshots
The proposed framework addresses these limitations through three primary components: lightweight snapshots, calibrated distillation, and representation recalibration.
1. Lightweight Snapshots via Adapters
Instead of saving a full copy of the backbone model (e.g., BERT) for every task, the authors utilize Adapters. These are small, two-layer bottleneck modules inserted into the transformer blocks. Once a task is completed, its corresponding adapter is frozen and stored as a "snapshot." These snapshots occupy only approximately 0.8% of the original model's parameters (0.89M vs. 110M for BERT-base), making it feasible to store knowledge for hundreds of tasks.
2. Knowledge Distillation with E-MSE
To transfer knowledge from past snapshots to the current "Global Model," the framework employs distillation. Traditional KL-divergence often fails in Class-IL because it does not preserve the absolute magnitude of predictions across different tasks. To solve this, the authors introduce Exponential Mean Squared Error (E-MSE). This loss function forces the global model to match the high-confidence "pseudo-labels" generated by the snapshots, ensuring that the model's confidence remains calibrated across the entire task sequence.
3. Representation Recalibration
Class-IL models often struggle with overlapping feature spaces between tasks. To mitigate this, an orthogonality loss ($L_{orth}$) is applied to the classification weights. This pushes the representations of different tasks to be perpendicular in the vector space, creating distinct boundaries between domains like "Finance" and "Technology."
Experimental Evaluation
The method was evaluated on diverse benchmarks, including THU-Seq (Chinese news), Mix-Seq (multi-dataset, multi-lingual), and SNIPS (sequence tagging).
Key Results
- Accuracy: On the Mix-Seq benchmark, the Snapshot method reached 64.1% accuracy, significantly outperforming standard regularization methods like EWC (60.4%) and MAS (60.2%).
- Efficiency: The storage requirement is minimal, adding less than 1MB per task.
- Stability: The model showed high robustness to task ordering and sequence length, avoiding the "performance cliffs" seen in baseline methods.
The impact of representation recalibration is clearly visible in feature space visualizations. As shown in the t-SNE plots, the recalibration mechanism prevents the "merging" of clusters from different tasks, which is a primary cause of confusion in Class-IL scenarios.
Discussion and Conclusion
The "Learning with Lightweight Snapshots" framework provides a scalable and privacy-preserving solution for continual text classification. By leveraging adapters for storage efficiency and E-MSE for calibrated knowledge transfer, it overcomes the primary hurdles of catastrophic forgetting and storage overhead. Future work may explore optimizing the adapter bottleneck size to prevent overfitting and further reducing the training overhead associated with processing multiple snapshots.
Summary updated