Introduction
Large-scale Vision-Language Models (VLMs) like CLIP have transformed computer vision by learning from hundreds of millions of image-text pairs. While CLIP demonstrates impressive "zero-shot" capabilities, adapting it to specialized downstream tasks—such as medical imaging or satellite data—remains a significant challenge.
Traditional fine-tuning often fails in "few-shot" scenarios, where labeled data is scarce. Updating all model parameters can lead to catastrophic forgetting, where the model loses its general-purpose knowledge and overfits to the small training set. Manual prompt engineering (e.g., "a photo of a [class]") is a tedious, trial-and-error process. This paper reviews the evolution of learnable prompts, which treat prompts as continuous vectors optimized via gradient descent to balance task-specific accuracy with broad generalization.
Methodologies in Prompt Learning
The landscape of prompt learning is categorized into several distinct architectural strategies:
- Text-only Prompting (T): Pioneered by CoOp, this replaces fixed words with learnable vectors in the text encoder. While it boosts accuracy on training classes, it often struggles with unseen categories.
- Conditional Prompting: Methods like CoCoOp address CoOp's overfitting by making prompts "instance-aware." The prompt changes dynamically based on the input image, improving generalization to novel categories.
- Visual Prompting (V): Techniques like VPT add learnable tokens directly to the image encoder (Vision Transformer) layers, focusing on adapting visual representations.
- Multimodal Prompting (T + V): Modern approaches like MaPLe and QNet tune both text and image branches simultaneously. This ensures both modalities stay aligned, typically yielding superior generalization.
- Regularization-based Methods: Methods like KgCoOp and PromptSRC use "anchors," constraining learnable prompts to stay close to original hand-crafted prompts to preserve pre-trained general knowledge.
Evaluation Benchmarks
The review evaluates these methods across a rigorous benchmark of 15 datasets, categorized into three main tasks:
- Base-to-Novel Generalization: Splitting a dataset into seen ("base") and unseen ("novel") classes.
- Cross-Dataset Generalization: Training on ImageNet and testing on 10 diverse datasets (e.g., Caltech101, OxfordPets, StanfordCars, Food101, etc.).
- Domain Generalization: Testing robustness against style shifts using ImageNet variants like ImageNet-V2, Sketch, Adversarial (A), and Renditions (R).
Key Insights and Analysis
- The Overfitting Paradox: Early learnable prompt methods like CoOp significantly outperformed zero-shot CLIP on training data but performed worse on novel, unseen classes. This highlights that learning performance does not always equate to generalization.
- Multimodal Synergy: Tuning only the text branch creates a modality mismatch because the frozen image encoder cannot adapt to the new textual context. Multimodal methods (tuning both branches) are now considered the gold standard for robustness.
- The Power of Hand-crafted Priors: Keeping learnable prompts "near" simple hand-crafted ones (via KL loss or distance constraints) is highly effective in preventing the model from forgetting its pre-trained knowledge.
Performance Comparison
The state-of-the-art has evolved significantly. While the original zero-shot CLIP scores 74.22% on novel classes, early methods like CoOp dropped to 67.99%. Modern methods like CPL and CoPrompt have pushed this back up to over 77%. To measure the balance between base and novel performance, researchers use the Harmonic Mean (HM). The state-of-the-art HM has moved from CLIP's 71.70 to over 80.00 (e.g., CPL at 80.66).
Future Directions
Despite recent progress, several challenges remain:
- Performance Plateaus: Performance on "base" classes has largely plateaued; future gains must focus on "novel" class recognition and domain robustness.
- Hard Domain Shifts: Improvements on challenging shifts (like ImageNet-A or ImageNet-R) remain relatively small compared to original CLIP.
- Beyond Classification: Most research is currently focused on image classification. The next frontier includes applying generalizable prompt learning to image segmentation, 3D detection, and Visual Question Answering (VQA).
- Extreme Few-Shot Learning: There is a need for more research on 1-shot or 2-shot scenarios, as most current benchmarks rely on 16-shot settings.
Summary updated