Share your thoughts, 1 month free Claude Pro on usSee more
WorkDL logo mark

Multimodal Task Vectors Enable Many-Shot Multimodal In-Context Learning

About

The recent success of interleaved Large Multimodal Models (LMMs) in few-shot learning suggests that in-context learning (ICL) with many examples can be promising for learning new tasks. However, this many-shot multimodal ICL setting has one crucial problem: it is fundamentally limited by the model's context length set at pretraining. The problem is especially prominent in the multimodal domain, which processes both text and images, requiring additional tokens. This motivates the need for a multimodal method to compress many shots into fewer tokens without finetuning. In this work, we enable LMMs to perform multimodal, many-shot in-context learning by leveraging Multimodal Task Vectors (MTV) -- compact implicit representations of in-context examples compressed in the model's attention heads. Specifically, we first demonstrate the existence of such MTV in LMMs and then leverage these extracted MTV to enable many-shot in-context learning for various vision-and-language tasks. Our experiments suggest that MTV can scale in performance with the number of compressed shots and generalize to similar out-of-domain tasks without additional context length for inference. Code: https://github.com/Brandon3964/MultiModal-Task-Vector

Brandon Huang, Chancharik Mitra, Assaf Arbelle, Leonid Karlinsky, Trevor Darrell, Roei Herzig• 2024

Related benchmarks

TaskDatasetResultRank
Visual Question AnsweringOK-VQA
Accuracy62
260
Image ClassificationFlowers (test)
Accuracy89.8
173
Visual Question AnsweringTextVQA (test)
Accuracy51
124
Multitask Language UnderstandingMMLU-Pro
Accuracy34.07
118
Visual Question AnsweringChartQA (test)
Accuracy34.9
86
ClassificationCUB (test)
Accuracy89.8
79
Natural Language InferenceaNLI
Accuracy34.7
65
Visual Question AnsweringVizwiz (val)
VQA Score55.2
51
ReasoningBig-Bench Hard (BBH)
Accuracy42.54
33
TranslationEnglish-Spanish
Accuracy76.7
15
Showing 10 of 13 rows

Other info

Code

Follow for update