Abstract
Visual foundation models (VFMs) like CLIP have become the backbone of modern AI systems, serving as frozen feature extractors for a multitude of downstream tasks. However, upgrading to a more powerful VFM typically necessitates a "cold-plugging" process, where every downstream module must be retrained from scratch to accommodate the new model's unique latent space. We introduce TaCA (Task-agnostic Compatible Adapter), a novel "hot-plugging" paradigm that enables seamless model upgrades. By utilizing a parameter-efficient, task-agnostic adapter, TaCA aligns a new model's features with the existing system's latent space. This approach delivers immediate performance gains across diverse applications—including video retrieval, classification, and multimodal LLMs—with zero downstream retraining.
The Challenge of Model Evolution
In the current modular AI landscape, foundation models are rarely used in isolation. Instead, they act as the "engine" for complex systems, providing features to specialized downstream modules like video decoders or language model connectors.
The release of a superior foundation model (e.g., moving from CLIP-ViT-B to ViT-H) presents a significant bottleneck. Because the new model's internal representations differ from the old one, the entire system must undergo a "cold-plugging" upgrade: retraining every downstream head to understand the new feature set. As the variety of downstream tasks grows, this retraining becomes prohibitively expensive. TaCA addresses this by allowing for a "hot-plugging" upgrade, where the foundation model is swapped without rebuilding the rest of the system.
Methodology: The Task-agnostic Compatible Adapter
TaCA achieves compatibility by inserting lightweight, trainable components into a frozen new foundation model. The goal is to make the new model's output "look like" the old model's output while retaining the superior representational power of the larger architecture.
Key Architectural Components
- Bottleneck Adapters: These are small modules inserted into each Transformer block of the new model. They consist of a down-sampling layer, a non-linear activation function, and an up-sampling layer. These adapters learn to adjust the new model's internal features to match the expected distribution of the old model.
- Dimension Projector: A two-layer Multi-Layer Perceptron (MLP) that ensures the output dimensionality of the new model matches that of the old one, allowing for direct replacement in downstream heads.
Dual Training Objectives
To ensure both feature compatibility and semantic integrity, TaCA is trained using two primary losses:
- Distillation Loss: This forces the new model's visual features to remain close to the old model's features in the latent space, ensuring the downstream modules can still interpret the data.
- Cross-modal Contrastive Loss: This aligns the new visual features with the old model's text features. This is critical for maintaining the zero-shot and cross-modal capabilities inherent in models like CLIP.
Crucially, TaCA is task-agnostic. It is trained once on a general-purpose dataset (LAION-400M) and can then be deployed across any number of downstream tasks without further modification.
Experimental Results
TaCA was evaluated across three major domains, consistently outperforming the original baseline models without any retraining of downstream components:
- Video-Text Retrieval: Upgrading from a ViT-B/16 to a TaCA-enhanced ViT-H/14 resulted in a +5.1% improvement in R@1 on the MSR-VTT dataset.
- Video Classification: On the Kinetics-400 benchmark, the same upgrade path yielded a +2.2% increase in top-1 accuracy.
- Multimodal LLMs: When integrated into the OpenFlamingo framework as a visual tokenizer, TaCA-ViT-H/14 achieved a +0.6% improvement over the standard ViT-L/14 setup on VQAv2.
Beyond performance, TaCA is highly efficient, requiring the training of only approximately 10% of the total parameters of the new foundation model compared to a full fine-tuning approach.
Insights and Future Directions
The authors identified a "Generalization Paradox": training an adapter for a specific task often degrades its performance on others. TaCA avoids this by focusing purely on latent space alignment. While the gains are most significant when upgrading between models with a large capability gap (e.g., Base to Huge), the paradigm proves that compatibility is a vital metric for modular AI evolution.
Future work may explore applying similar "hot-plugging" techniques to text encoders or developing more advanced adapter architectures to further bridge the gap between model generations.
Summary updated