Papers
Topics
Authors
Recent
Search
2000 character limit reached

Query-Adaptive Offset Optimization in LVLMs

Updated 12 January 2026
  • QAO is a targeted method that refines LVLM activation editing by applying query-specific correction offsets based on image-text context.
  • It employs a lightweight MLP-based offset estimator to adjust the general factual steering vector, mitigating hallucination without altering the backbone model.
  • Implemented within the AFTER framework, QAO achieves up to a 16.3% reduction in hallucination, offering precise and scalable correction of model activations.

Query-Adaptive Offset Optimization (QAO) is a mechanism designed to refine the activation editing of Large Vision-LLMs (LVLMs) by introducing query-specific correction vectors. QAO operates within the AFTER framework, which addresses object hallucination caused by language bias in LVLMs. Unlike generic activation editing approaches, QAO enables precise, per-query steering of internal model representations by leveraging a lightweight offset estimator, thereby mitigating the risk of over- or under-correction for diverse user queries (Wang et al., 5 Jan 2026).

1. Motivation and Problem Formulation

LVLMs exhibit vulnerability to object hallucination—erroneously generating mentions of objects, attributes, or relations not grounded in the provided image data. The prevalence of hallucination stems from language bias, which can induce systematic misalignment between visual evidence and textual output. AFTER’s Factual-Augmented Activation Steering (FAS) computes a general steering vector dˉ\bar{\mathbf{d}} that moves internal model activations toward fact-augmented semantics, regardless of the query context. However, because each query qq may reference distinct visual or conceptual entities, applying a uniform edit can insufficiently address instance-specific hallucination. QAO responds by introducing a query-conditioned residual offset Δ(q)\Delta(q), modulating the editing vector for each incoming query, thereby adaptively refining the intervention.

2. Query-Aware Offset Estimator Architecture

The central component of QAO is a single-layer Multi-Layer Perceptron (MLP) G\mathcal{G}, parameterized by WW and bb, which projects the self-attention head activations z\mathbf{z} (already encoding the visual-textual “query” context) into predicted offset vectors:

G(z)=Wz+b\mathcal{G}(\mathbf{z}) = W\mathbf{z} + b

Optionally, a ReLU nonlinearity may be incorporated. This design avoids modifying the backbone LVLM parameters, preserving the overall model structure and relying solely on z\mathbf{z} (the attention output at a given layer) as the implicit encoder for the query context. A plausible implication is that this design streamlines deployment and minimizes computational overhead.

3. Mathematical Formulation

QAO is formulated atop the FAS steering vector and introduces mechanisms to extract, estimate, and apply query-specific offsets:

  • General steering vector:

dˉ=1nXxXi=1n(zi+zi)\bar{\mathbf{d}} = \frac{1}{n|\mathbf{X}|} \sum_{x\in\mathbf{X}} \sum_{i=1}^n (\mathbf{z}_i^+ - \mathbf{z}_i)

where qq0 is the activation from the model fed a trusted, fact-augmented text qq1 and query qq2, while qq3 is the original activation from qq4.

  • Query-specific optimal vector and residual:

qq5

  • Offset estimator and final edited activation:

qq6

qq7

qq8

When editing multiple attention heads indexed by qq9, the update is:

Δ(q)\Delta(q)0

4. Optimization Objective and Training

The offset estimator Δ(q)\Delta(q)1 is trained to minimize the squared Δ(q)\Delta(q)2 norm between its predicted offset and the target residual offset for each annotated instance:

Δ(q)\Delta(q)3

Crucially, FAS’s Δ(q)\Delta(q)4 provides general factual guidance, while QAO’s Δ(q)\Delta(q)5 specializes in refining the “residual” offset Δ(q)\Delta(q)6 associated with each query, mitigating the propensity for inappropriate overcorrection. No additional regularization terms are introduced on Δ(q)\Delta(q)7 in the referenced implementation. Training employs a single-layer projection of dimension Δ(q)\Delta(q)8, typical learning rate of Δ(q)\Delta(q)9, and batches comprising roughly G\mathcal{G}0 COCO images times G\mathcal{G}1 queries, iterated over several epochs.

5. Integration with FAS and Editing Workflow

The end-to-end operation of QAO within AFTER proceeds as follows:

  1. Sampling a small set G\mathcal{G}2 of images (e.g., from the COCO dataset).
  2. For each image G\mathcal{G}3, generating fact-augmented text G\mathcal{G}4 via a factuality function G\mathcal{G}5.
  3. For image-query pairs, computing activations G\mathcal{G}6 from G\mathcal{G}7 and G\mathcal{G}8 from G\mathcal{G}9.
  4. Computing the general steering vector WW0 (FAS step).
  5. Determining the query-specific disparity WW1, forming offsets WW2, and training the MLP WW3.
  6. At inference, collecting each head's WW4 for a new WW5, applying the edit WW6, and updating the hidden state WW7.

This pipeline allows for plug-and-play, inference-time mitigation of hallucination in LVLMs without retraining or fine-tuning the backbone model.

6. Implementation Details

Key parameters and routines are as follows:

  • Hidden state dimension WW8
  • Quantity of edited heads WW9
  • Editing strength bb0
  • Offset estimator bb1: single linear layer, mapping bb2

The simplified pseudocode below summarizes the operational mechanics:

bb3

7. Significance and Empirical Impact

QAO, as instantiated in AFTER, advances the granularity and adaptability of activation editing for LVLM hallucination mitigation. By moving from a coarse, query-agnostic steering vector to fine-grained, query-adaptive offsets, AFTER achieved up to a 16.3% reduction in hallucination relative to baseline on the AMBER benchmark, measured over three widely adopted LVLMs. A plausible implication is that QAO's modularity and low-cost deployment facilitate scalable improvement of factual reliability in cross-modal AI systems without costly retraining (Wang et al., 5 Jan 2026).

Definition Search Book Streamline Icon: https://streamlinehq.com
References (1)

Topic to Video (Beta)

No one has generated a video about this topic yet.

Whiteboard

No one has generated a whiteboard explanation for this topic yet.

Follow Topic

Get notified by email when new papers are published related to Query-Adaptive Offset Optimization (QAO).