Selectively Answering Visual Questions (2024)

Abstract: Recently, large multi-modal models (LMMs) have emerged with the capacity to perform vision tasks such as captioning and visual question answering (VQA) with unprecedented accuracy. Applications such as helping the blind or visually impaired have a critical need for precise answers. It is specially important for models to be well calibrated and be able to quantify their uncertainty in order to selectively decide when to answer and when to abstain or ask for clarifications. We perform the first in-depth analysis of calibration methods and metrics for VQA with in-context learning LMMs. Studying VQA on two answerability benchmarks, we show that the likelihood score of visually grounded models is better calibrated than in their text-only counterparts for in-context learning, where sampling based methods are generally superior, but no clear winner arises. We propose Avg BLEU, a calibration score combining the benefits of both sampling and likelihood methods across modalities.

## introduction reliable visual question answering (vqa) systems should provide a confidence estimate of their own predictions. this introspective skill allows users to decide when to trust or double check its outputs, or lets the system itself selectively decide when to gather more information in order to provide accurate responses. while this problem has been studied extensively for classification models @xcite and more recently also for text generation @xcite , vqa systems have been under-explored. the combination of multiple input modalities can introduce different sources of uncertainty due to incorrectly framed or focused images. this is specially true when images are taken by people with no or limited vision, as is the case for the vizwiz-vqa dataset @xcite . furthermore the questions in vizwiz-vqa are spoken and there- please can you tell me what this item is? lmm p 1 baxters soup p 2 soup p 3 butternut squash & red pepper p 4 squash & pepper soup p 1 baxters soup calibration methods for best answer: baxters soup sampling repetition: 2 / 5 likelihood: p 1 sampling diversity: 1 -4 / 5 avg bleu: avg i sum j (p j bleu(a i , a j )) llm ••• ••• ••• ••• ••• caption: a hand holding a can of baxters soup. please can you tell me what this item is? our goal is to study which methods from the literature can help calibrate state-of-the-art vqa systems, and build a selective vqa setup that can trust its confidence estimates when answering. we many are not answerable due to low quality images. sometimes the intent of the question poser, and therefore the correct answer, cannot be inferred. see this as a necessary step towards systems that can be used in real life scenarios. figure 1 @xcite . our contributions can be summarized as follows: (a) through the use of several metrics, we study how the calibration methods from text qa perform when applied in two vqa answerability benchmarks and find that likelihood based scoring is better for lmms than llms, without a clear winner. (b) we propose a new sampling based method that tackles limitations and improves all metrics significantly. concretely, it improves coverage at 80% accuracy by 5 points for the best lmm and coverage at 70% accuracy by 8 points for the best llm. ## related work our paper studies vqa systems with unanswerable question through the vizwiz-vqa @xcite and unk-vqa @xcite datasets. we show some examples in figure 2 . through the introduction of unanswerable responses from the annotators, gurari et al. study a possible form of calibration as binary detection of such images. this setting is however limited in that a model (or person) can assess a question as answerable and be uncertain about whether the answer is a good one, as observed by @xcite . on the topic of estimating uncertainty, several approaches appear in the literature. @xcite incorporate a latent trainable variable for the covariance matrix among classes. the use of additional binary classifiers-so-called selectorswas investigated for text qa @xcite @xcite . this approach was extended to vqa by @xcite and @xcite . they focus on fine-tuned models and the use of selectors. we argue that, with the increasing availability and adop-tion of lmms, it is important to study calibration in zero and few-shot scenarios, which pose unique challenges for evaluation @xcite . @xcite study different samplingbased methods to calibrate llms in a zero-shot fashion. it focuses on entity based qa, where there is little differences in the surface form of equivalent answers. due to the open-ended problem, the answers in vizwiz-vqa and unk-vqa can vary, as illustrated in figure 1 . this variation needs to be considered when designing schemes to measure uncertainty when evaluating multiple samples. ## methods a qa system is said to be well-calibrated when each prediction has a confidence score which can help assess how often it is correct. formally, the paradigm of selective qa uses a scoring function s that attaches to each qa pair (q, a) a numeric score s(q, a). the score can be compared with a threshold τ so that the system answers-aka triggers-when s(q, a) > τ or abstains otherwise. as shown in figure 1 , various scoring methods can be used. we present first the methods from @xcite for text-only qa, and then our proposal. likelihood the likelihood-based calibration uses the output language model score p(a|q) computed using the chain rule: p(a|q) = n @xmath0, • • • , t i-1 , q) where the t i are the tokens that form the answer a. @xcite 's variation ratio we compute the frequency of the most sampled output divided by the total number of samples, which coincides with the probability of the mode of the empirical distribution. when more samples agree with each other, the answer can be considered to be more trustworthy. ## experiments in our experiments, we use the validation split of vizwiz-vqa with 4k instances. each question has up to 10 crowd-worker answers. examples can be seen in figure 2 . we consider a question answerable if at least one crowd-worker annotated it as such. this corresponds to 75% of the questions. we also include the validation set of unk-vqa @xcite , consisting of 1k examples, synthetically constructed by modifying the images or text from vqa v2 @xcite . on the modeling side, we chose stateof-the-art lmms llava @xcite , flamingo @xcite , and blip-2 @xcite . to compare the calibration of lmms with llms, we leverage the human written captions for vizwiz images provided by @xcite . we chose to use gold captions to control the additional errors and uncertainty which could arise from model written ones. nevertheless we run a study in section 4.1 using captions from pali-x @xcite and found that similar results hold. we evaluate state-of-the-art llms palm-2 @xcite and falcon @xcite . we sample ten responses with a tem-perature of 0.7. we consider the model to trigger if the most likely answer (greedy) does not contain the sequence "unanswerable". the full prompts and blip-2 results can be seen in appendix a. to simplify the analysis while staying consistent with the official metric defined in @xcite , we consider a model answer correct if it matches at least one (instead of three) of the gold answers. we evaluate the different scoring methods defined in the previous section with intrinsic and extrinsic metrics that we introduce below, over the set of examples where each model triggers a response. expected calibration error (ece) predictions are bucketed into ten same-sized bins, ranked by the confidence. we compute the mean absolute value of the distance between the average confidence score and the accuracy of predictions in each bin, averaged across all non empty bins. this intrinsic evaluation interprets a confidence score to represent a probability, so it computes the difference in the predicted probability of being correct from the observed probability of being correct. ece is therefore noisy and sensitive to re-scaling. roc-auc area under the receiver operating characteristic curve measures the ability as a binary classifier for correct and incorrect predictions by integrating over the curve of the rates of true and false positives. it can be interpreted as the probability that the score of a correct output chosen at random is higher than that of an incorrect output. coverage@acc while ece and roc-auc assess absolute and relative calibration respectively, we want a metric closely aligned with selective qa. therefore, we compute the triggering rate the model can achieve if forced to maintain a certain accuracy among the responses where it triggers. formally, c@ acc is the maximum coverage such that the accuracy on the c% of most-confident predictions is at least acc %. for example, if c@70 = 30, then the system is 70% or more accurate on the top 30% most-confident predictions. we take 100 coverage to mean not all of the examples, but where the model produced an answer. we show the overall results for vizwiz in we also evaluated model-based measures of semantic similarity in section 4.2 beyond bleu, but interestingly, we found that bleu has strong performance while requiring negligible compute. ## conclusions we studied scoring methods to assess the confidence in the predictions of a vqa system in the vizwiz and unk-vqa datasets. we observed that, as shown previously, sampling based methods might present an advantage over likelihood based estimates in text models, but the picture changes for text-image models. open ended question with non-entity answers present additional challenges for sampling methods, so the equivalence among possible sampled answers needs to be incorporated as well. our avg bleu score is able to capture the spread of possible samples in a soft way and accomplishes the best results on the calibration evaluations we measured, combining the advantages of sampling and likelihood-based methods.