Class-Incremental Learning (CIL) requires models to continually acquire knowledge of new classes without forgetting old ones. Despite Pre-trained Models (PTMs) have shown excellent performance in CIL, catastrophic forgetting still occurs as the model learns new concepts. Existing work seeks to utilize lightweight components to adjust the PTM, while the forgetting phenomenon still comes from {\em parameter and retrieval} levels. Specifically, iterative updates of the model result in parameter drift, while mistakenly retrieving irrelevant modules leads to the mismatch during inference. To this end, we propose MOdel Surgery (MOS) to rescue the model from forgetting previous knowledge. By training task-specific adapters, we continually adjust the PTM to downstream tasks. To mitigate parameter-level forgetting, we present an adapter merging approach to learn task-specific adapters, which aims to bridge the gap between different components while reserve task-specific information. Besides, to address retrieval-level forgetting, we introduce a training-free self-refined adapter retrieval mechanism during inference, which leverages the model's inherent ability for better adapter retrieval. By jointly rectifying the model with those steps, MOS can robustly resist catastrophic forgetting in the learning process. Extensive experiments on seven benchmark datasets validate MOS's state-of-the-art performance. Code is available at: https://github.com/sun-hailong/AAAI25-MOS
翻译:类增量学习要求模型能够持续学习新类别知识而不遗忘旧类别。尽管预训练模型在类增量学习中展现出优异性能,但在学习新概念时仍会发生灾难性遗忘。现有研究试图通过轻量级组件调整预训练模型,但遗忘现象仍存在于参数与检索两个层面。具体而言,模型的迭代更新会导致参数漂移,而错误检索无关模块则引发推理过程中的失配问题。为此,我们提出模型外科手术方法,以挽救模型对先前知识的遗忘。通过训练任务特定适配器,我们持续调整预训练模型以适应下游任务。为缓解参数层面遗忘,我们提出适配器融合方法学习任务特定适配器,旨在弥合不同组件间的差距同时保留任务特定信息。此外,针对检索层面遗忘,我们在推理阶段引入无需训练的自优化适配器检索机制,利用模型固有能力实现更优的适配器检索。通过联合实施这些步骤对模型进行校正,MOS能够在学习过程中稳健抵抗灾难性遗忘。在七个基准数据集上的大量实验验证了MOS的先进性能。代码发布于:https://github.com/sun-hailong/AAAI25-MOS