Introduction
The standard "pretrain-then-finetune" paradigm leads to a proliferation of large, independent models for each downstream task. Model merging offers a solution by combining these into a single multi-task model without retraining. However, traditional methods like Task Arithmetic or TIES-Merging operate globally, modifying all parameters. This often results in significant task interference, where updates for one task degrade the performance of others.
Methodology: The Localize-and-Stitch Framework
To address task interference, we propose Localize-and-Stitch, a surgical approach to model merging. Instead of global averaging, the framework identifies the minimal set of parameters—typically around 1%—responsible for a task's performance and integrates only those into the base model.
The process consists of two primary steps:
- Localization: A sparse binary mask is identified for each task. This can be done using a small amount of data (e.g., 8-shot optimization with $L_1$ regularization) or via a dataless approach by selecting parameters with the largest magnitude changes.
- Stitching: The identified sparse task vectors are reintegrated into the pretrained base model. In cases of parameter overlap between tasks, values are averaged locally.
Experiments and Results
The framework was evaluated across diverse domains, including NLP (RoBERTa), Vision (CLIP), and generative tasks (GPT2-XL).
The Power of Sparsity
A key finding is the "1% Rule": discarding 99% of fine-tuned weight changes preserves over 99% of task performance. This extreme sparsity drastically reduces the probability of inter-task conflict.
Performance Benchmarks
On 12 NLP tasks, Localize-and-Stitch achieved an average accuracy of 0.759, significantly outperforming Task Arithmetic (0.675) and TIES-Merging (0.621). Furthermore, the method is highly efficient for storage; a 650MB RoBERTa model's task-specific delta can be compressed to approximately 7MB, allowing for massive model compression with minimal overhead.
Discussion
Analysis reveals that localized task-specific regions are not uniform but are concentrated in LayerNorm parameters, suggesting that fine-tuning primarily shifts distributions rather than rewriting core logic. While the method is highly effective, performance in the "Dataless" variant is slightly lower than the data-driven approach. Future work will explore scaling to billion-parameter models and more advanced conflict resolution for overlapping task masks.
Conclusion
Localize-and-Stitch demonstrates that task-specific knowledge is highly localized. By surgically merging these sparse regions, we can create multi-task models that minimize interference, preserve base model capabilities, and enable massive compression.
Summary updated