Continual Learning Using Only Large Language Model Prompting

Jiabao Qiu, Zixuan Ke, Bing Liu

Abstract

Continual Learning (CL) aims to enable models to learn a sequence of tasks without suffering from catastrophic forgetting. Traditional methods often rely on parameter updates, which are inapplicable to black-box Large Language Models (LLMs) accessed via APIs. This paper introduces CLOB (Continual Learning Over Black-box LLMs) and a novel method called CIS (Incremental Summarization). CIS leverages the inherent summarization and reasoning capabilities of LLMs to maintain concise textual representations of classes. By updating these summaries instead of model weights, CIS effectively eliminates parameter-based forgetting. Experimental results across four benchmarks demonstrate that CIS significantly outperforms traditional fine-tuning-based CL baselines, achieving state-of-the-art performance in both clear and "blurry" task settings.

Introduction

The primary challenge in Continual Learning is Catastrophic Forgetting (CF), where learning new information leads to the degradation of previously acquired knowledge. While various techniques like parameter isolation or replay buffers exist for small models, they are unsuitable for modern "Black-box" LLMs (e.g., GPT-4, Llama 3) where weights are fixed or inaccessible. Furthermore, the finite context window of LLMs prevents simply prepending all historical data to every prompt.

This work addresses these challenges by proposing a prompt-based CL framework. Instead of modifying the model, the approach focuses on managing the knowledge provided in the context. We specifically investigate "blurry" task boundaries, a realistic scenario where data for different classes arrives in an interleaved stream rather than discrete, well-defined tasks.

Methodology: Incremental Summarization (CIS)

The proposed CIS framework manages class knowledge through three primary components:

  1. The Reflector (Summary Generator): Upon encountering a new class, the LLM generates a concise summary (up to 3 sentences) based on a few initial examples.
  2. The Updator: In dynamic or "blurry" settings where additional data for an existing class arrives, the Updator prompts the LLM to integrate this new information into the existing summary, ensuring the class representation remains comprehensive.
  3. The Solver (Inference): To handle classification across many classes while respecting token limits, a two-step process is employed. First, class summaries are partitioned into chunks, and the LLM provides confidence scores for each. Second, the top-$k$ classes are selected for a final, fine-grained classification.
Overview of the CIS framework, illustrating the Training (Reflector, Updator) and Testing (Solver) phases.

Experimental Results

The CIS framework was evaluated on four text classification benchmarks: Banking-77, CLINC-80, DBpedia-14, and Reuters-14. The evaluation focused on accuracy and the forgetting rate in "blurry" settings.

Performance Comparison

CIS demonstrates a substantial performance lead over traditional CL baselines such as EWC, LAMOL, and VAG. For instance, on the Banking-77 dataset, CIS (using Llama 3.1) achieved approximately 79% accuracy, whereas the strongest parameter-updating baseline (VAG) only reached 55%, even when VAG was provided with the full dataset.

Comparative performance of CIS against Joint learning and various Continual Learning baselines across four datasets.

Key Insights

  • Elimination of Weight Forgetting: Since the LLM weights remain static, the model never "forgets" its underlying linguistic capabilities. Forgetting is limited to potential degradation in the quality of textual summaries.
  • Summaries as Efficient Representations: Textual summaries serve as human-interpretable embeddings that are compact enough for large-scale classification yet descriptive enough to resolve fine-grained differences between classes.
  • Robustness to Noise: CIS often performs better in incremental settings than when presented with all raw data at once. This suggests that the summarization process acts as a filter, reducing "in-context noise" that can distract LLMs during few-shot prompting.

Conclusion

This research demonstrates that effective Continual Learning can be achieved through intelligent prompting and incremental summarization without any parameter updates. CIS provides a scalable and robust solution for black-box LLMs, significantly outperforming traditional fine-tuning methods. Future work will explore extending this paradigm to multi-modal data and optimizing the inference cost associated with the multi-step Solver process.

Summary updated

BibTeX
@inproceedings{qiu2025continual,
  author = {Jiabao Qiu and Zixuan Ke and Bing Liu},
  title = {{Continual Learning Using Only Large Language Model Prompting}},
  booktitle = {International Conference on Computational Linguistics},
  year = {2025},
}
Figure