SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2406.15334 · NeurIPS · 2024

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

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

arXiv · PDF · Open in the Atlas

Code that ran

16 of 19 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (0 of them constructed an object rather than computing a result; 5 honoured the contract we drafted, 2 violated it and 1 has no contract verdict; 8 failures of our instrument; 3 no recorded run), measured 2026-11-22; repository links from the Papers with Code archive attributed under CC BY-SA, no affiliation; bodies inline only under a permissive licence as GitHub detects it. Not a reproduction of the paper's results.

"Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results. This record, dated, as JSON: /api/ran/2406.15334.json · badge: /api/ran/2406.15334.svg

Each repository's role is a label: a classifier's output recorded on the link, or, where no role is recorded, what the Papers with Code archive marked. The line under it names its basis. Neither says who wrote the code.

RepositoryRoleRan
Brandon3964/MultiModal-Task-Vector canonical (classifier label)
classifier basis: census
11 ran · 3 no recorded run
brandon3964/multimodal-task-vector reimplementation (classifier label)
classifier basis: classifier_2025
5 ran · 0 no recorded run
FunctionStatusWhere it lives
add_extra_stop_words Ran
ran on a synthesized input
Brandon3964/MultiModal-Task-Vector/openai_api.py
pointer only (licence: NONE) · get_code("385a35a03fe04cde")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, Brandon3964/MultiModal-Task-Vector when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

box_iou Ran
ran, honoured the contract we drafted
Brandon3964/MultiModal-Task-Vector/eval_mm/evaluate_grounding.py
pointer only (licence: NONE) · get_code("ce749f837424dd8c")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, Brandon3964/MultiModal-Task-Vector when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

collate_fn Ran
ran; our contract draft was wrong, not the code
Brandon3964/MultiModal-Task-Vector/eval_mm/evaluate_caption.py
pointer only (licence: NOASSERTION) · get_code("a7ddf937ddb1ba60")
How it ran

The body of this sample is withheld: GitHub could not classify the licence of this paper's repository, Brandon3964/MultiModal-Task-Vector (NOASSERTION). The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

collate_fn Ran
ran; our contract draft was wrong, not the code
Brandon3964/MultiModal-Task-Vector/eval_mm/evaluate_grounding.py
pointer only (licence: NOASSERTION) · get_code("d19fe23145498c35")
How it ran

The body of this sample is withheld: GitHub could not classify the licence of this paper's repository, Brandon3964/MultiModal-Task-Vector (NOASSERTION). The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

collate_fn Ran
ran; our contract draft was wrong, not the code
Brandon3964/MultiModal-Task-Vector/eval_mm/evaluate_multiple_choice.py
pointer only (licence: NOASSERTION) · get_code("37a27553c04d476e")
How it ran

The body of this sample is withheld: GitHub could not classify the licence of this paper's repository, Brandon3964/MultiModal-Task-Vector (NOASSERTION). The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

evaluate_exact_match_accuracy Ran
ran, honoured the contract we drafted
brandon3964/multimodal-task-vector/eval_mm/evaluate_vqa.py
pointer only (licence: NOASSERTION) · get_code("e159a001bd4cbfaa")
How it ran

The body of this sample is withheld: GitHub could not classify the licence of this paper's repository, brandon3964/multimodal-task-vector (NOASSERTION). The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

evaluate_relaxed_accuracy Ran
ran, honoured the contract we drafted
brandon3964/multimodal-task-vector/eval_mm/evaluate_vqa.py
pointer only (licence: NOASSERTION) · get_code("4ffcad52354b4806")
How it ran

The body of this sample is withheld: GitHub could not classify the licence of this paper's repository, brandon3964/multimodal-task-vector (NOASSERTION). The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

format_vizwiz Ran
ran; our contract draft was wrong, not the code
Brandon3964/MultiModal-Task-Vector/MTV/preprocess.py
pointer only (licence: NOASSERTION) · get_code("d3495f004eb282e1")
How it ran

The body of this sample is withheld: GitHub could not classify the licence of this paper's repository, Brandon3964/MultiModal-Task-Vector (NOASSERTION). The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

levenshtein_distance Ran
ran, honoured the contract we drafted
Brandon3964/MultiModal-Task-Vector/eval_mm/infographicsvqa_eval.py
pointer only (licence: NOASSERTION) · get_code("90a8e73fa6de72a4")
How it ran

The body of this sample is withheld: GitHub could not classify the licence of this paper's repository, Brandon3964/MultiModal-Task-Vector (NOASSERTION). The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

load_image Ran
ran, violated the contract we drafted
brandon3964/multimodal-task-vector/MTV/models.py
pointer only (licence: NOASSERTION) · get_code("3275ed06c9e635d8")
How it ran

The body of this sample is withheld: GitHub could not classify the licence of this paper's repository, brandon3964/multimodal-task-vector (NOASSERTION). The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

load_images Ran
ran, honoured the contract we drafted
brandon3964/multimodal-task-vector/MTV/models.py
pointer only (licence: NOASSERTION) · get_code("8f69c6173ca1fadb")
How it ran

The body of this sample is withheld: GitHub could not classify the licence of this paper's repository, brandon3964/multimodal-task-vector (NOASSERTION). The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

open_data Ran
ran; our contract draft was wrong, not the code
Brandon3964/MultiModal-Task-Vector/MTV/preprocess.py
pointer only (licence: NOASSERTION) · get_code("c62b6812691c4ecc")
How it ran

The body of this sample is withheld: GitHub could not classify the licence of this paper's repository, Brandon3964/MultiModal-Task-Vector (NOASSERTION). The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

preprocess Ran
ran; our contract draft was wrong, not the code
Brandon3964/MultiModal-Task-Vector/finetune.py
pointer only (licence: NONE) · get_code("8b733c9fc590e4c1")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, Brandon3964/MultiModal-Task-Vector when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

relaxed_correctness Ran
ran, violated the contract we drafted
brandon3964/multimodal-task-vector/eval_mm/evaluate_vqa.py
pointer only (licence: NOASSERTION) · get_code("b3c8680ebd8739af")
How it ran

The body of this sample is withheld: GitHub could not classify the licence of this paper's repository, brandon3964/multimodal-task-vector (NOASSERTION). The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

split_activations_by_head Ran
ran; our contract draft was wrong, not the code
Brandon3964/MultiModal-Task-Vector/MTV/mtv_utils.py
pointer only (licence: NOASSERTION) · get_code("d4db6c913fb49a77")
How it ran

The body of this sample is withheld: GitHub could not classify the licence of this paper's repository, Brandon3964/MultiModal-Task-Vector (NOASSERTION). The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

trim_stop_words Ran
ran; our contract draft was wrong, not the code
Brandon3964/MultiModal-Task-Vector/openai_api.py
pointer only (licence: NONE) · get_code("469cf12b400c2c5a")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, Brandon3964/MultiModal-Task-Vector when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

evaluate_method Not yet run
unverified (harvested, no recorded run)
Brandon3964/MultiModal-Task-Vector/eval_mm/infographicsvqa_eval.py
pointer only (licence: NOASSERTION) · get_code("b90651bcc771b76f")
How it ran

The body of this sample is withheld: GitHub could not classify the licence of this paper's repository, Brandon3964/MultiModal-Task-Vector (NOASSERTION). The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. No invocation recorded.

get_format_func Not yet run
unverified (harvested, no recorded run)
Brandon3964/MultiModal-Task-Vector/MTV/preprocess.py
pointer only (licence: NOASSERTION) · get_code("9d2410fb29f7ac7e")
How it ran

The body of this sample is withheld: GitHub could not classify the licence of this paper's repository, Brandon3964/MultiModal-Task-Vector (NOASSERTION). The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. No invocation recorded.

load_model Not yet run
unverified (harvested, no recorded run)
Brandon3964/MultiModal-Task-Vector/MTV/mtv_utils.py
pointer only (licence: NOASSERTION) · get_code("2534a18f2f56fd6c")
How it ran

The body of this sample is withheld: GitHub could not classify the licence of this paper's repository, Brandon3964/MultiModal-Task-Vector (NOASSERTION). The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. No invocation recorded.

Also present in other papers' code

Of 19 samples lifted from this paper's linked repositories, 19 carry a function identity and 0 do not. Of the 19 distinct functions with an identity, 9 are also present in other papers whose code we hold (6 with at least one paper dated earlier, 4 the same month, 9 later) and 10 are only here among the 52,977 papers whose code Syntology holds (as of 2026-09-26).

Only here means: among the 52,977 papers whose code Syntology holds (51,887 with lifted samples, 1,090 through their assemblies only), as of 2026-09-26, no other paper's lifted samples or current assembly bricks contain an identical function body after normalisation.

FunctionAlso present inEarliest-datedOthers named
box_iou 24 other papers
17 dated earlier, 6 later, 1 undated · 5 only as an assembly brick
2103.12115 (2021-03)
End-to-End Trainable Multi-Instance Pose Estimation with Transformers
2104.00969 (2021-04)
TubeR: Tubelet Transformer for Video Action Detection
2112.05375 (2021-12)
Rethinking the Two-Stage Framework for Grounded Situation Recognition
and 21 more not named here
load_images 20 other papers
3 dated earlier, 2 the same month, 14 later, 1 same year, order not determinable
2312.14867 (2023-12)
VIEScore: Towards Explainable Metrics for Conditional Image Synthesis Evaluation
2024.findings-emnlp.268 (2024 (year only))
Math-LLaVA: Bootstrapping Mathematical Reasoning for Multimodal Large Language Models
2403.13805 (2024-03)
RAR: Retrieving And Ranking Augmented MLLMs for Visual Recognition
and 17 more not named here
preprocess 8 other papers
3 dated earlier, 1 the same month, 4 later
2311.09198 (2023-11)
Never Lost in the Middle: Mastering Long-Context Question Answering with Position-Agnostic Decompositional Training
2401.10935 (2024-01)
SeeClick: Harnessing GUI Grounding for Advanced Visual GUI Agents
2402.11905 (2024-02)
Learning to Edit: Aligning LLMs with Knowledge Editing
and 5 more not named here
evaluate_relaxed_accuracy 6 other papers
1 the same month, 5 later
2406.08487 (2024-06)
Beyond LLaVA-HD: Diving into High-Resolution Large Multimodal Models
2407.01976 (2024-07)
A Bounding Box is Worth One Token: Interleaving Layout and Text in a Large Language Model for Document Understanding
2410.16261 (2024-10)
Mini-InternVL: A Flexible-Transfer Pocket Multimodal Model with 5% Parameters and 90% Performance
and 3 more not named here
relaxed_correctness 6 other papers
1 the same month, 5 later
2406.08487 (2024-06)
Beyond LLaVA-HD: Diving into High-Resolution Large Multimodal Models
2407.01976 (2024-07)
A Bounding Box is Worth One Token: Interleaving Layout and Text in a Large Language Model for Document Understanding
2410.16261 (2024-10)
Mini-InternVL: A Flexible-Transfer Pocket Multimodal Model with 5% Parameters and 90% Performance
and 3 more not named here
evaluate_exact_match_accuracy 4 other papers
4 later
2410.16261 (2024-10)
Mini-InternVL: A Flexible-Transfer Pocket Multimodal Model with 5% Parameters and 90% Performance
2412.03324 (2024-12)
A Stitch in Time Saves Nine: Small VLM is a Precise Guidance for Accelerating Large VLMs
2412.05185 (2024-12)
LinVT: Empower Your Image-level Large Language Model to Understand Videos
and 1 more not named here
trim_stop_words 3 other papers
2 dated earlier, 1 later
2402.11905 (2024-02)
Learning to Edit: Aligning LLMs with Knowledge Editing
2403.07691 (2024-03)
ORPO: Monolithic Preference Optimization without Reference Model
2507.11953 (2025-07)
IAM: Efficient Inference through Attention Mapping between Different-scale LLMs
add_extra_stop_words 2 other papers
1 dated earlier, 1 later
2402.11905 (2024-02)
Learning to Edit: Aligning LLMs with Knowledge Editing
2507.11953 (2025-07)
IAM: Efficient Inference through Attention Mapping between Different-scale LLMs
levenshtein_distance 2 other papers
1 dated earlier, 1 later
2312.08578 (2023-12)
A Picture is Worth More Than 77 Text Tokens: Evaluating CLIP-Style Models on Dense Captions
2407.01523 (2024-07)
MMLONGBENCH-DOC: Benchmarking Long-context Document Understanding with Visualizations

Presence, not direction: an identical function body in two papers' repositories does not say who wrote it, which came from which, or that either paper's method rests on it. Matching is exact after normalisation, so a renamed or edited function is not matched. Dates are when papers appeared, not when code was written. Only .py files the harvester lifted are covered; notebooks are not read. A new-style arXiv id YYMM.NNNN dates a paper to the month 20YY-MM; otherwise Paper.year dates it to the year; otherwise it is undated. Dates are when the paper appeared, not when the code was written. Read 2026-11-22.

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

The recent success of interleaved Large Multimodal Models (LMMs) in fewshot 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 * Denotes Equal Contribution 38th Conference on Neural Information Processing Systems (NeurIPS 2024).

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("2406.15334")
get_code_for_paper("2406.15334")
have("2406.15334")

The run record, dated, one paper per request, free:

curl https://syntology.ai/api/ran/2406.15334.json

A badge for a README (the split and the date, never a ratio):

[![Syntology run record](https://syntology.ai/api/ran/2406.15334.svg)](https://syntology.ai/paper/2406.15334)

Connect an agent — have() is free.