Saved in:
Bibliographic Details
Main Authors: Fu, Shuhao, Goldberg, Esther, Wu, Ying Nian, Lu, Hongjing
Format: Preprint
Published: 2025
Subjects:
Online Access:https://arxiv.org/abs/2510.02528
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866918531812032512
author Fu, Shuhao
Goldberg, Esther
Wu, Ying Nian
Lu, Hongjing
author_facet Fu, Shuhao
Goldberg, Esther
Wu, Ying Nian
Lu, Hongjing
contents Large Multimodal Models (LMMs) demonstrate impressive in-context learning abilities from few multimodal demonstrations, yet the internal mechanisms supporting such task learning remain opaque. Building on prior work of Large Language Models, we show that a small subset of attention heads in Large Multimodal Models is responsible for transmitting representations of visual relations. The activations of these attention heads, termed function vectors, can be extracted and manipulated to alter an LMM's performance on relational tasks. First, using synthetic and real image datasets, we apply causal mediation analysis to identify attention heads that strongly influence relational predictions, and extract multimodal function vectors that improve zero-shot accuracy at inference time. We further demonstrate that these multimodal function vectors can be fine-tuned with a modest amount of training data, while keeping LMM parameters frozen, to significantly outperform in-context learning baselines. Finally, we show that relation-specific function vectors can be linearly combined to solve analogy problems involving novel and untrained visual relations, highlighting the strong generalization ability of this approach. Through experiments on two LMMs, including OpenFlamingo and Qwen3-VL, our results show that these models encode visual relational knowledge within localized internal structures, which can be systematically extracted and optimized, thereby advancing our understanding of model modularity and enhancing control over relational reasoning in LMMs.
format Preprint
id arxiv_https___arxiv_org_abs_2510_02528
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle Multimodal Function Vectors for Visual Relations
Fu, Shuhao
Goldberg, Esther
Wu, Ying Nian
Lu, Hongjing
Artificial Intelligence
Machine Learning
Large Multimodal Models (LMMs) demonstrate impressive in-context learning abilities from few multimodal demonstrations, yet the internal mechanisms supporting such task learning remain opaque. Building on prior work of Large Language Models, we show that a small subset of attention heads in Large Multimodal Models is responsible for transmitting representations of visual relations. The activations of these attention heads, termed function vectors, can be extracted and manipulated to alter an LMM's performance on relational tasks. First, using synthetic and real image datasets, we apply causal mediation analysis to identify attention heads that strongly influence relational predictions, and extract multimodal function vectors that improve zero-shot accuracy at inference time. We further demonstrate that these multimodal function vectors can be fine-tuned with a modest amount of training data, while keeping LMM parameters frozen, to significantly outperform in-context learning baselines. Finally, we show that relation-specific function vectors can be linearly combined to solve analogy problems involving novel and untrained visual relations, highlighting the strong generalization ability of this approach. Through experiments on two LMMs, including OpenFlamingo and Qwen3-VL, our results show that these models encode visual relational knowledge within localized internal structures, which can be systematically extracted and optimized, thereby advancing our understanding of model modularity and enhancing control over relational reasoning in LMMs.
title Multimodal Function Vectors for Visual Relations
topic Artificial Intelligence
Machine Learning
url https://arxiv.org/abs/2510.02528