Lune

NeurIPS2025Top-tier venue

Variational Task Vector Composition

Boyuan Zhang, Yingjun Du, Xiantong Zhen, Ling Shao

Abstract

Task vectors capture how a model changes during fine-tuning by recording the difference between pre-trained and task-specific weights. The composition of task vectors, a key operator in task arithmetic, enables models to integrate knowledge from multiple tasks without incurring significant additional inference costs. In this paper, we propose variational task vector composition (VTVC), where composition coefficients are taken as latent variables and estimated in a Bayesian inference framework. Unlike previous methods that operate at the task level, our framework focuses on sample-specific composition. Motivated by the observation of structural redundancy in task vectors, we introduce a Spike-and-Slab prior that promotes sparsity and aims to preserve the most informative components. To further address the high variance and sampling inefficiency in sparse, high-dimensional spaces, we develop a gated sampling mechanism that constructs a controllable posterior by filtering the composition coefficients based on both uncertainty and importance. This yields a more stable and interpretable variational framework by deterministically selecting reliable task components, reducing sampling variance while improving transparency and generalization. Experimental results demonstrate that our method achieves state-of-the-art average performance across a diverse range of benchmarks, including image classification and natural language understanding. These findings highlight the practical value of our approach, offering a new, efficient, and effective framework for task vector composition.

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

Questions to start from

Lune can draw on

the full paper · related work

Get the answer

Free to start. No credit card required.

Lineage

  • TIES-Merging: Resolving Interference When Merging Models cites Task Arithmetic in the Tangent Space: Improved Editing of Pre-Trained Models
  • TIES-Merging: Resolving Interference When Merging Models cites An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale
  • TIES-Merging: Resolving Interference When Merging Models cites Learning Transferable Visual Models From Natural Language Supervision
  • Task Arithmetic in the Tangent Space: Improved Editing of Pre-Trained Models cites An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale
  • Task Arithmetic in the Tangent Space: Improved Editing of Pre-Trained Models cites Learning Transferable Visual Models From Natural Language Supervision
  • Learning Transferable Visual Models From Natural Language Supervision cites An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale
Builds onCited byLeft to right by year; the more cited, the higher.

Builds on26

  1. Learning Transferable Visual Models From Natural Language SupervisionAlec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh et al.ICML 2021 · 47,906 citations
  2. An Image is Worth 16x16 Words: Transformers for Image Recognition at ScaleAlexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn et al.ICLR 2021 · 21,477 citations
  3. TIES-Merging: Resolving Interference When Merging ModelsPrateek Yadav, Derek Tam, Leshem Choshen, Colin A. Raffel et al.NeurIPS 2023 · 999 citations
  4. Language Models are Super Mario: Absorbing Abilities from Homologous Models as a Free LunchLe Yu, Bowen Yu, Haiyang Yu, Fei Huang et al.ICML 2024 · 605 citations
  5. Task Arithmetic in the Tangent Space: Improved Editing of Pre-Trained ModelsGuillermo Ortiz-Jiménez, Alessandro Favero, Pascal FrossardNeurIPS 2023 · 272 citations

Related papers

  1. Distilling Linearized Behavior into Non-linear Fine-Tuning for Effective Task ArithmeticThomas Sommariva, Francesca Morandi, Simone Calderara, Angelo PorrelloICML 2026 · 2 citations
  2. In-Context Compositional Learning vis Sparse Coding TransformerWei Chen, Jingxi Yu, Zichen Miao, Qiang QiuNeurIPS 2025
  3. Variational Multi-Task Learning with Gumbel-Softmax PriorsJiayi Shen, Xiantong Zhen, Marcel Worring, Ling ShaoNeurIPS 2021 · 42 citations
  4. Efficient Model Editing with Task-Localized Sparse Fine-tuningLeonardo Iurada, Marco Ciccone, Tatiana TommasiICLR 2025
  5. BayesTune: Bayesian Sparse Deep Model Fine-tuningMinyoung Kim, Timothy M. HospedalesNeurIPS 2023 · 10 citations
Dusk over the sea between two cliffs drawn in fine vertical lines