Manuscript Offprint
arXiv:2611.08054NutriVisRAG: Multimodal Exemplar Grounding for Nutrient Estimation with Vision-Language Models
Lubnaa Abdur Rahman¹,², Ioannis Papathanail², Maria Panagiotou¹,², Nefeli Dimitropoulou³, Margret Harðardóttir³, Elisabeth J. den Brok³, Bastiaan E. de Galan³, and Stavroula Georgia Mougiakakou²
¹ Graduate School for Cellular and Biomedical Sciences, University of Bern, 3012 Bern, Switzerland
² ARTORG Center for Biomedical Engineering Research, University of Bern, 3008 Bern, Switzerland
³ Department of Endocrinology, Maastricht University Medical Centre+, and Cardiovascular Research Institute Maastricht (CARIM), Maastricht University, Maastricht, the Netherlands
Abstract. Diet is a major determinant of health, yet accurate dietary assessment from free-living meal images remains challenging. Existing retrieval-based Vision-Language Model (VLM) approaches to nutrient estimation typically rely on textual food representations, while, to our knowledge, direct grounding on visually similar annotated meals has not been investigated. We present NutriVisRAG, a retrieval-augmented generation framework that uses a vision encoder to retrieve similar meals with known nutritional annotations and provide them as multimodal in-context exemplars for VLM nutrient estimation at inference time, without task-specific fine-tuning. We evaluate NutriVisRAG across four datasets, four VLMs, three retrieval encoders, and two prompting strategies, including free-living meals from adults with insulin-treated diabetes, where carbohydrate estimates are compared against two dietitians' annotations. Across all 96 configurations (4 datasets × 4 VLMs × 3 retrieval encoders × 2 prompting strategies), NutriVisRAG reduced the primary estimation error in 56, with improvements more frequent under whole-meal (35/48) than per-item prompting (21/48). Across the evaluated configurations, the lowest NutriVisRAG error was below the best Vanilla error in 13 of 16 VLM-dataset pairs. For GPT-5.4-mini, under whole-meal prompting, the best-performing retrieval encoder for each dataset reduced the primary error on all four datasets relative to Vanilla, with reductions of 1.7–35.7%. Overall, our results show that grounding in multimodal exemplars comprising images and respective annotations can improve nutrient estimation at inference time without task-specific fine-tuning, although the benefits remain configuration-dependent.
Keywords: Vision-Language Models · Nutrient Estimation · Retrieval-Augmented Generation · Vision-RAG
1 Introduction
Accurate dietary assessment is central to nutritional monitoring and the prevention and management of diet-related chronic diseases, yet conventional self-reported approaches remain burdensome and prone to measurement errors [17]. Advances in computer vision and smartphone technologies have enabled automated dietary assessment from meal images through multi-stage pipelines combining food segmentation, recognition, portion estimation, and nutrient calculation, alongside integrated models that directly predict food quantity and nutritional composition [28, 29, 43, 44, 51]. These approaches have benefited from increasingly large food segmentation and recognition datasets [11, 30, 31, 46]. Errors in either segmentation or recognition can propagate to downstream portion and nutrient estimation, and recognition remains particularly vulnerable to distributions not represented during training [4]. Even when food regions and identities are correctly determined, estimating physical quantity remains a separate challenge, as portion estimation typically relies on depth, geometric reconstruction, or reference cues that require additional acquisition information [2, 28, 29, 43, 51]. End-to-end models instead bypass this by predicting food weight, energy, or macronutrients from visual representations. However, these approaches require large training datasets with quantitative dietary annotations [44, 50, 51].
Large Language Models, pretrained on large-scale text corpora, have demonstrated strong few-shot and in-context learning capabilities across diverse language tasks without task-specific fine-tuning [10, 13]. Extending this foundation-model paradigm to visual inputs, Vision-Language Models (VLMs) combine language modelling with visual representations to support multimodal understanding and generation [6, 45]. Recent studies have evaluated VLMs for food recognition, meal decomposition, portion and weight estimation, calorie estimation, and macronutrient prediction, with performance varying substantially across models and prompting strategies [1, 34, 39, 47, 49, 50, 53, 58]. Task-specific fine-tuning, specialised prediction components, and parameter-efficient adaptation can improve performance, but require additional dietary training data and model adaptation [1, 50, 58]. Nevertheless, quantitative dietary estimation remains challenging because food quantity and nutritional content must still be inferred from limited visual information [8, 34, 39, 49, 50, 53, 55]. Explicitly supplied nutritional information can nevertheless improve nutrient estimation [34, 50].
Structured, retrieval-augmented, and agentic approaches have therefore been explored for VLM-based dietary assessment [1, 8, 16]. Retrieval-Augmented Generation (RAG) provides inference-time access to external evidence without requiring fine-tuning of VLMs [25]. In dietary applications, retrieval has been used to support food identification and nutrient estimation through dietary records, food composition databases, knowledge graphs, and standardised nutritional information [5, 16, 18, 57, 62]. However, current dietary retrieval remains predominantly textual or structured. Image-based approaches first interpret meal images into textual descriptions, candidate foods, or decomposed food items before querying external food composition resources [16, 57]. Multimodal RAG has shown that retrieval can operate directly over visual and heterogeneous representa-

Fig. 1: Overview of the NutriVisRAG pipeline: the top-K visually similar reference meals are retrieved for a query image, and their images and nutritional annotations are added to the prompt as multimodal context for the VLM.
tions [15, 21, 59], while visual retrieval has previously been explored in food computing for image-recipe matching and calorie estimation [33, 48]. To the best of our knowledge, however, VLM-based nutrient estimation applications have yet to investigate the retrieval of visually similar meal images with known nutritional annotations and provide them directly to the VLM for grounding.
We therefore investigate whether simple inference-time grounding with visually similar annotated meals can improve VLM-based nutrient estimation. Our contributions are:
- We introduce NutriVisRAG, an inference-time framework that integrates image-based retrieval with pretrained VLMs, using similar annotated meals as multimodal in-context exemplars for nutrient estimation.
- We systematically evaluate visual exemplar grounding across VLMs, retrieval encoders, prompting strategies, and four dietary datasets, including free-living meals from adults with insulin-treated diabetes evaluated against dietitians' visual estimations.
2.1 NutriVisRAG
Overview NutriVisRAG, illustrated in Figure 1, retrieves visually similar annotated meals directly in the visual embedding space and provides each retrieved meal image together with its available nutritional annotations to a VLM as multimodal context at test time. Retrieval is followed by a single VLM generation step for nutrient estimation. The retrieved meals therefore act as multimodal in-context exemplars carrying both visual and quantitative information [6, 25].
Problem Formulation Let be a query meal image and its vector of available annotated nutritional targets, which is used only for evaluation. Depending on the dataset, contains the available subset of weight, energy, carbohydrate (CHO), protein, and fat. Let denote the VLM and the task prompt. We compare Vanilla VLM estimation with retrieval-grounded estimation:
where is a set of retrieved reference meals , each consisting of a reference image and its available nutritional annotations , which are provided to the VLM as input. The two conditions therefore differ only by the retrieved exemplar context , whose construction is described below.
Index construction. Let denote the frozen visual encoder used for retrieval. Each reference image is mapped to an embedding and stored in the visual index together with its available nutritional annotations. Evaluation query images are excluded from the reference index.
Retrieval. At test time, the query image is embedded using the same visual encoder, and its similarity to each indexed reference image is computed using cosine similarity:
The references with the highest similarity form the candidate set , ordered by decreasing similarity, where denotes the similarity of the -th ranked reference. A minimum similarity threshold is applied, and if no candidate satisfies it, the highest-ranked reference is retained as a fallback:
Thresholding may therefore retain fewer than K exemplars, while the fallback ensures that the VLM always receives at least the nearest reference for grounding. The annotations accompanying each retrieved image are provided at item and meal level where available; unavailable quantities are omitted rather than imputed (e.g., SNAPMe references are presented without meal weight).
2.2 Datasets
We use four dietary image datasets (Table 1).
Nutrition5k [51] contains cafeteria meals acquired under controlled conditions, with ingredient-level food identities and weights and meal-level weight, energy, and macronutrient annotations.
SNAPMe [24] contains free-living meal images captured from smartphones and linked to dietary records collected using the Automated Self-Administered 24-hour
Table 1: Datasets used.
| Dataset | Evaluation queries | Indexed references | Evaluation targets |
|---|---|---|---|
| Nutrition5k [51] | 815 | 2,445 | Weight, energy, CHO, protein, fat |
| SNAPMe [24] | 323 | 1,149 | Energy, CHO, protein, fat |
| MADiMa [7] | 160 (80 meals each at 40 and 60 cm) | - | Weight, energy, CHO, protein, fat |
| EDUCATE [12] | 247 | - | CHO |
Dietary Assessment Tool (ASA24), providing verified self-reported annotations for energy and macronutrients without measured meal weight.
MADiMa [7] contains 80 meals with two to four food items and measured weight, volume, and energy and macronutrient composition. Each meal was captured at 40 cm and 60 cm under a constrained acquisition protocol, yielding 160 images used jointly in the main evaluation. The two acquisition distances are additionally analysed as separate 80-image subsets in Supplementary Section S2.
EDUCATE [12] contains free-living meal images captured using the goFOOD™ Lite mobile application [28] from adults with insulin-treated diabetes in the Netherlands arm of the study [12]. After excluding packaged foods, erroneous entries, and non-food images, de-identified food-only images from 25 participants were retained. CHO content was independently estimated by two dietitians using an annotation tool [3], and model estimates are evaluated against their mean in the absence of measured ground truth.
Nutrition5k and SNAPMe serve as both evaluation query sets and indexed reference corpora. For each of Nutrition5k and SNAPMe, a subset (exact numbers in Table 1) is held out for evaluation, and the remaining are combined into the reference corpus, ensuring that evaluated meals cannot be retrieved as references. Despite annotation provenance differences, the two reference subsets are combined to broaden the range of meal compositions and acquisition conditions represented, spanning controlled and free-living settings. Nutrition5k queries are drawn from overhead, non-empty meals, while SNAPMe queries are selected round-robin at image level with preference for compositionally rich plates. The task-specific Nutrition5k split does not follow the official partition and was designed to retain compositionally richer dishes in the reference corpus.
2.3 Experimental Setup
Models and retrieval encoders. We evaluate the four VLMs listed in Table 2 without task-specific fine-tuning. The open-weight local models are run on an NVIDIA RTX A6000 through Ollama [40], the hosted open-weight models through Ollama Cloud, and GPT through the OpenAI API [41]. Retrieval uses the three frozen image encoders listed in Table 3.
Prompting strategies. We evaluate two prompting strategies differing in the granularity of the requested output. In per-item, the VLM was asked to identify the visible food items and estimate the weight, energy, CHO, protein, and fat of each item separately, with meal-level estimates obtained by summing the returned
Table 2: Vision-language models evaluated.
| Model | Identifier | Weights | Serving |
|---|---|---|---|
| GPT-5.4-mini [42] | gpt-5.4-mini | proprietary | OpenAI API |
| Gemma-4-31b [20] | gemma-4-31b-cloud | open | Ollama Cloud |
| Mistral-Small-3.2 [32] | mistral-small13.2:24b | open | local Ollama |
| GLM-5.3-Flash [60] | glm-5.3-flash:cloud | open | Ollama Cloud |
Table 3: Frozen image encoders used for retrieval.
| Encoder | Checkpoint | Input resolution |
|---|---|---|
| PE-Core-G14 [9] | facebook/PE-Core-G14-448 | 448×448 |
| SigLIP2 [52] | google/siglip2-o400m-patch14-384 | 384×384 |
| Nomic Vision [37] | nomic-ai/nomic-embed-vision-v1.5 | 224×224 |
item-level predictions. In whole-meal, the VLM was asked to directly estimate the corresponding totals for the complete meal without explicit item-level decomposition. For each strategy, the same task instructions and enforced structured JSON output format are used in the Vanilla and grounded conditions. The grounded condition additionally receives the retrieved reference images with their nutritional annotations and a system-prompt description of this reference information. The exact prompt templates are provided in Supplementary Section S1.
Retrieval configuration. The Nutrition5k and SNAPMe reference sets are combined into a single retrieval corpus, with evaluation query images excluded from the index. Visual indices are built using Facebook AI Similarity Search (FAISS) through LlamaIndex [23, 27]. Reference images are embedded once for each encoder and -normalised before retrieval. The main experiments use , a minimum cosine-similarity threshold of with the fallback strategy defined above, and no reranking. The values and were selected from preliminary comparisons with and on fixed 100-query subsets of each query set.
Retrieval ablations. We report the fixed 100-query comparisons used to examine retrieval-parameter sensitivity and select the main retrieval settings. The same queries are reused across configurations to enable paired comparisons under identical evaluation samples. We evaluate these comparisons across all four VLMs under both per-item and whole-meal prompting. We vary the similarity threshold and retrieval depth relative to the default retrieval configuration:
Exploratory retrieval extensions. Beyond these retrieval-parameter ablations, we evaluate two exploratory extensions on the same fixed 100-query subsets. Both extensions are evaluated across all four VLMs. For post-hoc food-composition grounding, we match VLM-predicted food names to food-composition database entries using lexical token-set similarity or one of three text-embedding models: Qwen3-Embedding [61], EmbeddingGemma [54], and Nomic Embed Text v2 (MoE) [36]. The matched nutrient values are scaled by the VLM-predicted food weights and summed to obtain meal-level estimates. This analysis uses per-item predictions, which provide the food identities and corresponding weights required for database lookup. For retrieval reranking, each query retrieves 50 visual candidates, which are rescored using Jina Reranker M0 [22], Qwen3-VL-Reranker-2B [26], or Llama Nemotron Rerank VL 1B v2 [38]. The five highest-ranked references are then provided to the VLM under both prompting strategies. These analyses test whether more selective exemplar ranking or external food-composition lookup improves the base NutriVisRAG estimates, respectively. Full experimental details and results are reported in Supplementary Section S5.
Inference. Query and retrieved reference images are resized to a maximum side length of 800 pixels while preserving aspect ratio, providing a common input scale without upscaling the lowest-resolution images and limiting visual input size. Temperature 0 and a fixed seed of 42 were used to minimise sampling variability, although deterministic outputs are not guaranteed across serving backends. Repeated inference runs were not performed, so run-to-run variance was not independently quantified.
2.4 Evaluation
For each nutritional field , let and denote the target and predicted values for meal . We report the mean absolute error normalised by the mean target value,
Normalising by the mean rather than per meal avoids unstable percentage errors when individual target values are near zero, while keeping nutritional fields of different magnitudes on a comparable scale.
Macronutrient performance is summarised in two ways: %MAE is the unweighted mean of the three macronutrient field errors, giving each equal weight regardless of magnitude, while %MAE pools absolute errors in grams across the three fields before normalising, and is therefore dominated by the macronutrient present in the largest quantity,
where , and denote CHO, protein, and fat, respectively. On EDUCATE, where only CHO is annotated, %MAE is computed against the dietitians' mean annotations. We use %MAE as the primary metric, replaced by %MAE on EDUCATE, and denote this as %MAE.
Statistical testing. Methods are compared using two-sided paired Wilcoxon signed-rank tests on per-meal absolute errors [56]. Multiple comparisons are corrected using the Benjamini–Hochberg procedure within each experiment–outcome family, controlling the false discovery rate at [14]. A family comprises all comparisons of one outcome measure within one experiment, pooled across query sets, VLMs, encoders, and prompting strategies; for example, all %MAE comparisons in the threshold ablation form one family, and all %MAE comparisons of NutriVisRAG against Vanilla form another.
Retrieval diagnostics. Using the full query sets, retrieval benefit is the per-query reduction in pooled absolute macronutrient error from Vanilla to NutriVisRAG, normalised by the query-set mean target macronutrient sum; EDUCATE instead uses absolute CHO error normalised by mean annotated CHO. Visual similarity is the mean cosine similarity of the retrieved exemplars, while nutritional distance is computed retrospectively as the mean absolute query-exemplar difference across the available macronutrients, each normalised by its query-set mean. Associations are quantified by query set, retrieval encoder, and prompting strategy using Spearman's rank correlation, with retrieval benefit averaged across the four VLMs; per-VLM results are in Supplementary Section S4.2.
3 Results and Discussion
3.1 NutriVisRAG versus Vanilla VLM Inference
We first evaluate whether visually retrieved meals with known nutritional annotations improve nutrient estimation relative to Vanilla VLM inference. Table 4 reports the primary error, with complete per-nutrient results in Supplementary Table S1. Across 96 configurations (4 datasets × 4 VLMs × 3 retrieval encoders × 2 prompting strategies), NutriVisRAG reduces the corresponding Vanilla error in 56, with improvements more frequent under whole-meal (35/48) than per-item prompting (21/48). After Benjamini-Hochberg correction, 45 configurations show a significant reduction in error, while 23 show a significant increase. Whole-meal prompting may benefit more from retrieval since exemplar annotations directly match the requested meal-level totals, unlike per-item prompting, which requires additional decomposition and aggregation.
Using the primary %MAE metric, NutriVisRAG reduces error in 13/24 configurations on Nutrition5k, 7/24 on SNAPMe, 22/24 on MADiMa, and 14/24 on EDUCATE. Nutrient-specific effects are broader, particularly for CHO, with improvements in 18/24, 9/24, 24/24, and 14/24 configurations, respectively; on MADiMa, weight and energy also improve in 21/24 and 19/24 configurations (Supplementary Table S1). Despite contributing indexed references, SNAPMe benefits least consistently, while MADiMa and EDUCATE show more frequent gains despite stronger projected separation from the reference corpus under some encoders (Supplementary Fig. S2). Thus, corpus membership and projected embedding overlap alone do not determine retrieval effectiveness. SNAPMe and EDUCATE should be interpreted with their annotation sources in mind: SNAPMe uses verified self-reported dietary estimates, whereas EDUCATE is restricted to CHO compared to dietitians' mean estimates, which are not nutritional ground truth. Across the evaluated configurations, the lowest NutriVisRAG error is below the best Vanilla error in 13 of 16 VLM-query-set pairs. As a retrieval-only control, we predict each nutritional target as the cosine-similarity-weighted mean of the retained exemplar annotations, without VLM inference. The lowest NutriVisRAG error is below the best retrieval-only error on all four query sets, by 5.8, 8.3, 12.7, and 7.1 percentage points on Nutrition5k, SNAPMe, MADiMa, and EDUCATE, respectively. Thus, direct similarity-weighted neighbour averaging does not account for the lowest observed NutriVisRAG errors.
The response to retrieval is strongly VLM-dependent, with improvements in 19/24 configurations for GPT-5.4-mini, 16/24 for GLM-5.3-Flash, 14/24 for Gemma-4-31B, and 7/24 for Mistral-Small-3.2. Mistral-Small-3.2 shows substantial error increases under per-item prompting on Nutrition5k and SNAPMe but benefits from whole-meal grounding on Nutrition5k and MADiMa, whereas GPT-5.4-mini benefits more consistently across prompting strategies on Nutrition5k, MADiMa, and EDUCATE and GLM-5.3-Flash shows strong gains on MADiMa and EDUCATE. Model scale alone does not explain these differences: Mistral-Small-3.2 is a 24B dense model, Gemma-4-31B has 31B parameters, GLM-5.3-Flash has 320B total and 18B active parameters, and GPT-5.4-mini's parameter count is undisclosed, while architecture, training data, and post-training are not independently controlled [20, 32, 42, 60].
No retrieval encoder consistently dominates across individual model-query-set-prompt configurations (Table 4 and Supplementary Table S1). Although cross-dataset means (Supplementary Table S2) favour PE-Core in several VLM-prompt combinations, the best encoder changes across query sets, and the direction of the retrieval effect can also change for the same VLM and prompting strategy. Overall, NutriVisRAG provides clear but configuration-dependent gains, while improvements in %MAE do not extend to every nutritional target. Median query latency increases by 1.4× for GPT-5.4-mini, 1.7× for Gemma-4-31B, 1.3× for Mistral-Small-3.2, and 1.2× for GLM-5.3-Flash, corresponding to +0.7, +1.2, +3.3, and +1.0 s per meal, respectively.
Given the mixed results on EDUCATE (14/24 improvements) and its relevance to free-living CHO estimation in people with diabetes, we further examine whether retrieval improves meal-level agreement with dietitian estimates beyond error. Figure 2 presents GPT-5.4-mini with SigLIP 2 under whole-meal prompting, for which NutriVisRAG significantly reduces %MAE from 58.4 to 43.3. NutriVisRAG reduces mean overestimation from 18.0 to 5.9 g and narrows the 95% limits of agreement from [-28.5, 64.5] to [-34.3, 46.1] g, particularly mitigating large positive errors at higher CHO values. Although individual errors remain, an improved agreement with dietitian estimates is seen; complete analyses across all query sets, VLMs, and encoders are provided in Supplementary Section S4.4.
3.2 Effect of Prompting Strategy
Figure 3 compares per-item and whole-meal prompting under Vanilla VLM inference. Per-item yields lower %MAE (%MAE for EDUCATE) in 12/16 model-dataset pairs, while whole-meal yields lower error for Mistral-Small-3.2 and GLM-5.3-Flash on SNAPMe and MADiMa. On MADiMa, 60 cm images

Fig. 2: Bland-Altman analysis of CHO estimates for 247 EDUCATE meals using GPT-5.4-mini with SigLIP 2 under whole-meal prompting, without (blue) and with (orange) NutriVisRAG. Differences are computed against the mean dietitian estimate; solid and dashed lines show the mean bias and 95% limits of agreement, respectively.

Fig. 3: Effect of prompting granularity under Vanilla VLM inference. %MAE (lower is better) is reported across VLMs and query sets; (*) for EDUCATE, %MAE against the mean dietitian estimate is shown.
yield lower %MAE and %MAE for GPT-5.4-mini, Gemma-4-31B, and GLM-5.3-Flash under both prompting strategies and for Mistral-Small-3.2 under whole-meal prompting, but not under per-item prompting (Supplementary Fig. S1). Although per-item prompting performs better under Vanilla inference in most pairs, NutriVisRAG improves more frequently under whole-meal prompting, showing that stronger baseline prompt performance does not necessarily imply greater retrieval benefit.
3.3 Exemplar Similarity and Retrieval Benefit
Since retrieval improves estimation in many but not all configurations, we examine whether its benefit is associated with exemplar similarity. A preliminary t-SNE analysis (Supplementary Fig. S2) showed that greater projected query-reference overlap does not correspond to more consistent gains, with MADiMa benefiting strongly despite its separation under PE-Core and SigLIP 2. At the individual-query level, Figure 4 relates retrieval benefit to visual similarity and retrospective nutritional distance under both prompting strategies. Visual similarity shows weak and inconsistent associations with retrieval gains across query sets and encoders.
Table 4: Vanilla versus NutriVisRAG for all retrieval encoders and both prompting strategies, on the full query sets. Values are %MAE_{micro} (%MAE_{CHO} for EDUCATE); lower is better. Bold: lowest error within each prompting strategy per model and query set. * / ▼: significant improvement/degradation over the corresponding Vanilla baseline (paired Wilcoxon signed-rank test, Benjamini–Hochberg corrected, q < 0.05).
| Query set | Model | Per-item | Whole-meal | ||||||
|---|---|---|---|---|---|---|---|---|---|
| NutriVisRAG | NutriVisRAG | ||||||||
| Vanilla | PE-Core | SigLIP2 | Nomic Vision | Vanilla | PE-Core | SigLIP2 | Nomic Vision | ||
| Nutrition5k | Gemma-4-31B | 53.6 | 53.7 | 54.6 | 59.8 | 63.5 | 51.0* | 50.8* | 55.8* |
| GPT-5.4-mini | 58.0 | 42.7* | 43.4* | 47.1* | 58.1 | 43.4* | 44.2* | 48.0* | |
| Mistral-Small-3.2 | 72.1 | 111.2* | 119.5* | 145.1* | 78.7 | 62.3* | 63.3* | 74.3* | |
| GLM-5.3-Flash | 54.0 | 54.1* | 53.4* | 58.6* | 56.2 | 58.8* | 56.8* | 62.2* | |
| SNAPMe | Gemma-4-31B | 41.0 | 46.2* | 44.0 | 45.0* | 43.6 | 42.5 | 40.4* | 41.9 |
| GPT-5.4-mini | 41.4 | 41.7 | 42.2 | 42.8 | 41.7 | 42.8 | 41.0 | 43.0 | |
| Mistral-Small-3.2 | 51.1 | 103.6* | 130.3* | 108.8* | 44.6 | 67.2* | 75.0* | 66.0* | |
| GLM-5.3-Flash | 39.8 | 40.1 | 43.8 | 41.5 | 39.6 | 38.0* | 38.5 | 38.8 | |
| MADiMa | Gemma-4-31B | 54.7 | 50.5* | 47.5* | 50.9* | 70.7 | 62.7* | 63.5* | 60.3* |
| GPT-5.4-mini | 57.4 | 44.5* | 46.5* | 46.4* | 75.7 | 48.7* | 52.9* | 51.6* | |
| Mistral-Small-3.2 | 79.5 | 67.6* | 78.6 | 82.8 | 63.4 | 52.8* | 55.6* | 69.2 | |
| GLM-5.3-Flash | 51.5 | 40.9* | 39.7* | 42.8* | 48.2 | 40.2* | 38.0* | 42.2* | |
| EDUCATE | Gemma-4-31B | 33.0 | 36.5* | 37.8 | 38.5 | 45.4 | 45.0 | 44.5 | 47.0 |
| GPT-5.4-mini | 45.0 | 40.9 | 38.0* | 42.5 | 58.4 | 46.6* | 43.3* | 43.6* | |
| Mistral-Small-3.2 | 51.2 | 153.8* | 151.6* | 147.1* | 51.9 | 82.2* | 92.8* | 81.4* | |
| GLM-5.3-Flash | 53.6 | 47.8* | 47.9* | 53.2 | 54.0 | 44.0* | 44.1* | 42.0* | |
In contrast, nutritional distance is more consistently negatively associated with benefit under whole-meal prompting, most strongly on MADiMa, and less so under per-item prompting. Visual similarity also corresponds to nutritional proximity more clearly on Nutrition5k than on the other query sets (Supplementary Fig. S5). Together, projected embedding overlap and cosine similarity alone therefore do not reliably predict exemplar usefulness. The nutritional-distance analysis is retrospective, as query annotations are unavailable at inference time and are shared with the error metric, so the association is descriptive rather than causal.
3.4 Retrieval Ablations
Effect of Similarity Threshold Table 5 compares the default similarity threshold () with no threshold () under both prompting strategies. Compared with , the default yields lower %MAE_{micro/CHO} in 60/96 configurations, including 32/48 per-item and 28/48 whole-meal configurations. Lower error is seen in 10/24 configurations on Nutrition5k, 18/24 on SNAPMe, 13/24 on MADiMa, and 19/24 on EDUCATE, with seven significant comparisons all favouring the default threshold. Where thresholding does not alter the retained exemplar set, observed differences cannot be attributed to exemplar filtering and may instead reflect inference variability. Similarity filtering benefit many configurations, but its effect remains model-, dataset-, and encoder-dependent, and cosine similarity alone does not guarantee nutritional relevance.
Effect of Retrieval Depth Compared with , the default depth () reduces %MAE_{micro/CHO} in 56/96 configurations, including 18/24 on Nutrition5k, 14/24 on SNAPMe, 10/24 on MADiMa, and 14/24 on EDUCATE. Of the five significant comparisons, four favour and all occur under per-item

Fig. 4: Association of exemplar similarity with NutriVisRAG retrieval benefit under per-item and whole-meal prompting. Spearman correlations () relate retrieval benefit to mean visual similarity (left) and retrospective nutritional distance (right), by query set and retrieval encoder. Filled markers indicate Benjamini–Hochberg-corrected ; open markers indicate non-significant associations. Positive visual-similarity correlations indicate greater benefit for more visually similar exemplars, whereas negative nutritional-distance correlations indicate greater benefit for nutritionally closer exemplars.
prompting, whereas the single comparison favouring occurs for Mistral-Small-3.2 with PE-Core on EDUCATE under whole-meal prompting. Increasing retrieval depth also raises latency for every VLM, by 0.1–2.0s per query under whole-meal and 0.4–18.6s under per-item prompting. Overall, increasing retrieval depth provides no consistent accuracy benefit while incurring additional inference cost, supporting as the default.
Exploratory Retrieval Extensions For each post-hoc food-composition matching method, we evaluate 48 configurations (4 query sets 4 VLMs 3 visual encoders) using per-item predictions. Post-hoc food-composition grounding increases relative to the default NutriVisRAG predictions. Lexical matching, EmbeddingGemma, and Nomic Embed Text v2 increase the error in all 48 configurations, while Qwen3-Embedding increases it in 46/48. For energy, which is available for three query sets, the original NutriVisRAG predictions also yield lower error in 34/36 configurations (3 query sets 4 VLMs 3 visual encoders). No matching method yields a significant improvement, while significant degradations occur in 45/48 configurations for lexical matching, 30/48 for Qwen3-Embedding, 47/48 for EmbeddingGemma, and 42/48 for Nomic Embed Text v2. Because these stages were not evaluated independently, the degradations may reflect cumulative pipeline errors rather than inadequate matching models.
For reranking, each prompting strategy comprises 144 comparisons (4 query sets 4 VLMs 3 visual encoders 3 rerankers), corresponding to 36 comparisons per query set. Under per-item prompting, reranking reduces in 73/144 comparisons, including 24/36 on MADiMa, 19/36 on Nutrition5k, 17/36
Table 5: Retrieval ablations on the fixed 100-query subsets, with per-item and whole-meal prompting side by side (%MAE, lower is better). Default is the main configuration ( , K = 5); the other columns remove the threshold ( ) or increase depth (K = 10). %MAE /CHO is %MAE for Nutrition5k, SNAPMe, and MADIMa and %MAE for EDUCATE; dashes mark unavailable targets. Bold: lowest error within each group of three. / : significantly lower/higher error than Default (paired Wilcoxon signed-rank test, Benjamini–Hochberg corrected, q < 0.05).
| Query set | Model | Encoder | Per-item | Whole-meal | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| %MAE_weight | %MAE_micro | %MAE_weight | %MAE_micro | |||||||||||||
| Def. K=10 | Def. K=10 | Def. K=10 | Def. K=10 | Def. K=10 | Def. K=10 | |||||||||||
| Nutrition5k | Gemma-4-31B | PE-Core | 68.6 | 64.0 | 68.4 | 53.7 | 50.1 | 53.0 | 60.1 | 60.4 | 61.8 | 60.9 | 50.7 | 70.5 | 52.8 | |
| SigLIP2 | 70.8 | 45.7 | 75.7 | 54.2 | 44.8 | 60.4 | 61.1 | 49.8 | 73.1 | 64.0 | 47.9 | 53.3 | 55.3 | |||
| Nomic Vision | 66.6 | 64.4 | 66.7 | 79.7 | 72.2 | 103.9 | 87.8 | 80.7 | 102.8 | 70.5 | 52.5 | 64.9 | 75.0 | |||
| GPT-5.4-mini | PE-Core | 31.1 | 38.5 | 34.9 | 28.6 | 32.8 | 32.8 | 32.9 | 40.0 | 36.1 | 30.3 | 35.8 | 31.1 | 34.0 | ||
| SigLIP2 | 33.1 | 33.1 | 31.4 | 31.4 | 30.2 | 32.2 | 36.0 | 35.6 | 38.1 | 31.8 | 34.9 | 33.0 | 36.3 | |||
| Nomic Vision | 28.2 | 31.1 | 40.5 | 30.6 | 29.9 | 40.5 | 37.4 | 37.6 | 47.7 | 33.1 | 38.2 | 37.2 | 36.6 | |||
| Mistral-Small-3.2 | PE-Core | 279.4 | 273.4 | 703.8 | 253.3 | 244.8 | 049.0 | 261.4 | 259.9 | 656.5 | 78.6 | 78.6 | 55.1 | 70.0 | 70.0 | |
| SigLIP2 | 327.9 | 337.1 | 823.8 | 281.0 | 283.1 | 761.8 | 300.4 | 306.5 | 773.0 | 89.2 | 89.2 | 72.3 | 78.5 | 78.5 | ||
| Nomic Vision | 364.4 | 373.3 | 914.2 | 394.1 | 418.6 | 989.3 | 387.4 | 410.9 | 972.7 | 102.5 | 104.5 | 98.3 | 117.9 | 117.6 | ||
| GLM-5.3-Flash | PE-Core | 32.9 | 55.0 | 29.8 | 30.7 | 50.8 | 30.5 | 33.1 | 52.5 | 32.5 | 30.3 | 41.5 | 44.6 | 34.9 | 38.4 | |
| SigLIP2 | 31.5 | 46.5 | 50.9 | 32.8 | 36.5 | 36.6 | 34.8 | 40.7 | 41.3 | 39.5 | 34.1 | 40.2 | 31.8 | 30.5 | ||
| Nomic Vision | 39.3 | 37.8 | 61.5 | 39.6 | 36.3 | 76.2 | 42.1 | 42.0 | 80.9 | 35.6 | 38.1 | 76.8 | 37.4 | 36.2 | ||
| SNAPMe | Gemma-4-31B | PE-Core | - | - | - | 36.0 | 38.8 | 37.5 | 42.6 | 44.2 | 45.7 | - | - | 39.5 | 38.1 | 38.8 |
| SigLIP2 | - | - | - | 42.4 | 37.9 | 40.9 | 43.0 | 44.4 | 49.1 | - | - | 39.8 | 36.8 | 35.6 | ||
| Nomic Vision | - | - | - | 36.9 | 39.3 | 42.2 | 44.5 | 46.4 | 49.1 | - | - | 41.0 | 36.3 | 36.0 | ||
| GPT-5.4-mini | PE-Core | - | - | - | 37.7 | 34.5 | 33.4 | 44.0 | 42.0 | 41.4 | - | - | 36.0 | 33.0 | 33.1 | |
| SigLIP2 | - | - | - | 34.5 | 34.5 | 34.3 | 43.6 | 42.4 | 43.3 | - | - | 34.6 | 33.6 | 36.0 | ||
| Nomic Vision | - | - | - | 34.0 | 36.1 | 35.4 | 40.8 | 42.4 | 42.7 | - | - | 37.7 | 36.3 | 35.4 | ||
| Mistral-Small-3.2 | PE-Core | - | - | - | 118.4 | 90.9 | 140.3 | 126.4 | 99.3 | 150.9 | - | - | 71.1 | 57.5 | 48.9 | |
| SigLIP2 | - | - | - | 134.4 | 126.5 | 202.2 | 140.8 | 133.7 | 208.7 | - | - | 71.9 | 66.3 | 48.2 | ||
| Nomic Vision | - | - | - | 110.1 | 108.0 | 175.4 | 114.6 | 113.2 | 181.6 | - | - | 62.1 | 59.5 | 44.4 | ||
| GLM-5.3-Flash | PE-Core | - | - | - | 37.7 | 32.5 | 34.9 | 42.7 | 38.0 | 39.0 | - | - | 32.6 | 30.8 | 32.5 | |
| SigLIP2 | - | - | - | 34.2 | 35.8 | 34.3 | 40.0 | 41.9 | 39.1 | - | - | 33.2 | 33.7 | 32.7 | ||
| Nomic Vision | - | - | - | 37.5 | 35.5 | 64.8 | 41.8 | 40.2 | 69.4 | - | - | 32.2 | 32.4 | 37.8 | ||
| MADIma | Gemma-4-31B | PE-Core | 40.2 | 39.5 | 39.9 | 36.6 | 36.7 | 35.9 | 45.4 | 46.2 | 45.1 | 74.4 | 74.3 | 73.1 | 57.1 | 57.4 |
| SigLIP2 | 38.6 | 37.7 | 37.5 | 36.1 | 34.8 | 33.7 | 43.5 | 42.5 | 43.1 | 74.5 | 70.3 | 73.1 | 57.9 | 56.6 | ||
| Nomic Vision | 44.8 | 42.4 | 44.5 | 37.8 | 37.0 | 38.8 | 46.1 | 45.1 | 46.1 | 81.0 | 76.9 | 78.8 | 55.5 | 52.2 | ||
| GPT-5.4-mini | PE-Core | 27.9 | 26.8 | 28.8 | 33.1 | 32.3 | 34.3 | 42.7 | 42.1 | 43.2 | 40.4 | 43.1 | 40.6 | 39.1 | 37.6 | |
| SigLIP2 | 28.4 | 29.1 | 26.2 | 33.1 | 32.0 | 32.6 | 43.3 | 43.1 | 41.9 | 41.3 | 42.9 | 35.3 | 41.8 | 45.2 | ||
| Nomic Vision | 35.7 | 31.6 | 32.4 | 36.0 | 33.2 | 32.3 | 45.9 | 42.3 | 44.0 | 54.7 | 58.2 | 54.2 | 40.0 | 41.8 | ||
| Mistral-Small-3.2 | PE-Core | 27.5 | 52.2 | 31.6 | 39.9 | 48.6 | 42.2 | 55.3 | 63.5 | 56.1 | 30.7 | 34.8 | 31.3 | 38.2 | 40.7 | |
| SigLIP2 | 34.2 | 62.7 | 38.6 | 48.0 | 59.8 | 52.5 | 59.4 | 74.1 | 61.7 | 31.9 | 34.1 | 28.2 | 40.8 | 38.7 | ||
| Nomic Vision | 62.2 | 59.0 | 57.1 | 67.5 | 53.6 | 69.6 | 86.7 | 67.5 | 83.5 | 44.2 | 43.5 | 38.2 | 41.1 | 50.7 | ||
| GLM-5.3-Flash | PE-Core | 31.2 | 32.6 | 31.1 | 30.4 | 30.4 | 30.1 | 37.9 | 37.3 | 37.2 | 31.7 | 33.6 | 33.4 | 29.2 | 29.8 | |
| SigLIP2 | 32.6 | 32.0 | 31.8 | 31.6 | 29.5 | 29.3 | 38.2 | 38.4 | 37.9 | 32.0 | 32.4 | 34.0 | 29.4 | 29.6 | ||
| Nomic Vision | 37.4 | 34.9 | 37.5 | 31.2 | 31.7 | 32.1 | 39.4 | 37.6 | 39.5 | 38.0 | 38.3 | 36.6 | 31.7 | 31.2 | ||
| EDUCATE | Gemma-4-31B | PE-Core | - | - | - | - | - | 38.8 | 38.5 | 42.4 | - | - | - | - | - | 40.1 |
| SigLIP2 | - | - | - | - | - | - | 41.2 | 41.9 | 42.8 | - | - | - | - | 47.6 | ||
| Nomic Vision | - | - | - | - | - | - | 41.2 | 40.4 | 39.9 | - | - | - | - | 47.5 | ||
| GPT-5.4-mini | PE-Core | - | - | - | - | - | 41.7 | 36.1 | 44.0 | - | - | - | - | - | 49.9 | |
| SigLIP2 | - | - | - | - | - | - | 42.4 | 38.0 | 40.4 | - | - | - | - | 44.6 | ||
| Nomic Vision | - | - | - | - | - | - | 42.1 | 41.9 | 44.4 | - | - | - | - | 54.7 | ||
| Mistral-Small-3.2 | PE-Core | - | - | - | - | - | 172.2 | 118.0 | 181.5 | - | - | - | - | - | 112.7 | |
| SigLIP2 | - | - | - | - | - | 208.7 | 134.5 | 174.4 | - | - | - | - | - | 115.3 | ||
| Nomic Vision | - | - | - | - | - | 161.9 | 140.3 | 193.6 | - | - | - | - | - | 101.3 | ||
| GLM-5.3-Flash | PE-Core | - | - | - | - | - | 54.0 | 51.9 | 56.4 | - | - | - | - | - | 47.7 | |
| SigLIP2 | - | - | - | - | - | - | 53.2 | 52.5 | 55.3 | - | - | - | - | 46.1 | ||
| Nomic Vision | - | - | - | - | - | - | 53.5 | 55.1 | 62.0 | - | - | - | - | 45.0 | ||
on EDUCATE, and 13/36 on SNAPMe. Eight per-item improvements and two degradations remain significant. Under whole-meal prompting, reranking reduces error in 76/144 comparisons, including 28/36 on MADIMa, 21/36 on EDUCATE, 17/36 on SNAPMe, and 10/36 on Nutrition5k. Six whole-meal improvements and four degradations remain significant after correction. Reranking can therefore recover more useful exemplars in some configurations, but the rerankers optimise general multimodal relevance rather than nutritional equivalence, so a semantically more relevant meal is not necessarily a better quantitative reference. Reranking additionally adds a median of 5.3–11.7s per meal, increasing end-to-end latency by depending on the reranker and VLM. Overall, its variable accuracy gains and additional computational cost do not support incorporating reranking into the default NutriVisRAG pipeline.
14 L. Abdur Rahman et al.
3.5 Limitations and Future Work
The findings remain specific to the evaluated VLMs, retrieval encoders, and combined reference corpus, whose coverage may not represent the diversity of real-world meals and whose annotations combine measured Nutrition5k quantities with participant-reported SNAPMe quantities. Broader evaluation across VLM families, visual representations, and larger, more diverse reference corpora is needed, particularly as MADiMa and EDUCATE remain entirely outside the indexed corpus and EDUCATE is evaluated only for CHO against dietitians' visual estimates rather than measured ground truth. Ablations were conducted on fixed 100-query subsets rather than the full query sets, and their observed effects may not generalise to complete datasets. Matched textual-retrieval and random-exemplar controls were not evaluated, limiting attribution of the observed gains specifically to visual similarity-based grounding. We also fix the VLM input image size; future work should evaluate query and exemplar resolution independently to determine whether finer visual detail justifies greater visual-token usage and inference latency. Our similarity analysis indicates that visual similarity is an imperfect proxy for exemplar usefulness, motivating more adaptive retrieval or reranking criteria that capture ingredient, portion, compositional, and quantitative relevance using information available at inference.
4 Conclusion
We introduced NutriVisRAG, an inference-time framework that grounds pretrained VLMs with visually retrieved meals and their nutritional annotations as multimodal quantitative exemplars, without task-specific fine-tuning. Across four dietary datasets, four VLMs, three retrieval encoders, and two prompting strategies, the lowest observed NutriVisRAG error was below the best Vanilla error in 13 of 16 VLM-dataset pairs. More importantly, our investigation shows that retrieval effectiveness is configuration-dependent and cannot be explained by visual similarity alone: benefits vary across VLMs and prompting strategies, while visually closer exemplars do not consistently correspond to greater downstream improvement or nutritional proximity. The more consistent gains under whole-meal prompting further suggest that exemplar usefulness depends not only on what is retrieved, but also on how the retrieved evidence is presented and used by the VLM. Retrieval ablations reinforce this interpretation, showing that similarity filtering is often beneficial while increasing retrieval depth provides no consistent accuracy benefit, and additional post-hoc grounding and reranking provide no consistently better alternative. Future work should therefore investigate inference-time retrieval or reranking criteria that better capture exemplar usefulness without requiring query nutrient annotations, alongside finer-grained analyses of query-exemplar correspondence and evaluation using larger and more diverse reference corpora.
Acknowledgements This work was partly funded by the European Commission and the Swiss State Secretariat for Education, Research and Innovation (SERI) within the MELISSA project (101057730) and BETTER4U (101080117).
References
-
Abdur Rahman, L., Dedousis, V., Papathanail, I., Poursoleyman, R., Kafyra, M., Kalafati, I.P., Mougiakakou, S.G.: Generative ai in precision nutrition: a review of current developments and future directions. Nutrients 18(6), 938 (2026)
-
Abdur Rahman, L., Papathanail, I., Brigato, L., Mougiakakou, S.: A comparative analysis of sensor-, geometry-, and neural-based methods for food volume estimation. In: Proceedings of the 8th International Workshop on Multimedia Assisted Dietary Management. pp. 21–29 (2023)
-
Abdur Rahman, L., Papathanail, I., Brigato, L., Mougiakakou, S.: A SAM based tool for semi-automatic food annotation. In: ECAI 2024. pp. 4475–4478. IOS Press (2024). https://doi.org/10.3233/FAIA241033
-
Abdur Rahman, L., Papathanail, I., Brigato, L., Mougiakakou, S.: Benchmarking post-hoc unknown-category detection in food recognition. In: Pattern Recognition. ICPR 2024 International Workshops and Challenges. pp. 3–18. Springer Nature Switzerland (2025). https://doi.org/10.1007/978-3-031-88217-3_1
-
Abdur Rahman, L., Papathanail, I., Mougiakakou, S.: Introducing the swiss food knowledge graph: Ai for context-aware nutrition recommendation. In: Proceedings of the 1st International Workshop on Multi-modal Food Computing. pp. 27–36. Association for Computing Machinery, New York, NY, USA (2025). https://doi.org/10.1145/3746264.3760494
-
Alayrac, J.B., Donahue, J., Luc, P., Miech, A., Barr, I., Hasson, Y., Lenc, K., Mensch, A., Millican, K., Reynolds, M., Ring, R., Rutherford, E., Cabi, S., Han, T., Gong, Z., Samangooei, S., Monteiro, M., Menick, J.L., Borgeaud, S., Brock, A., Nematzadeh, A., Sharifzadeh, S., Binkowski, M., Barreira, R., Vinyals, O., Zisserman, A., Simonyan, K.: Flamingo: A visual language model for few-shot learning. In: Advances in Neural Information Processing Systems. vol. 35, pp. 23716–23736 (2022)
-
Allegra, D., Anthimopoulos, M., Dehais, J., Lu, Y., Stanco, F., Farinella, G.M., Mougiakakou, S.: A multimedia database for automatic meal assessment systems. In: New Trends in Image Analysis and Processing – ICIAP 2017. Lecture Notes in Computer Science, vol. 10590, pp. 471–478. Springer (2017). https://doi.org/10.1007/978-3-319-70742-6_46
-
Bhatambarekar, G., Sarkar, A.: An agentic vision-language pipeline for interactive nutritional estimation from food images. In: Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition. pp. 9492–9500 (2026)
-
Bolya, D., Huang, P.Y., Sun, P., Cho, J.H., Madotto, A., Wei, C., Ma, T., Zhi, J., Rajasegaran, J., Rasheed, H., Wang, J., Monteiro, M., Xu, H., Dong, S., Ravi, N., Li, D., Dollár, P., Feichtenhofer, C.: Perception encoder: The best visual embeddings are not at the output of the network. arXiv preprint arXiv:2504.13181 (2025)
-
Bommasani, R., Hudson, D.A., Adeli, E., et al.: On the opportunities and risks of foundation models. arXiv preprint arXiv:2108.07258 (2021)
-
Bossard, L., Guillaumein, M., Van Gool, L.: Food-101: Mining discriminative components with random forests. In: European Conference on Computer Vision. pp. 446–461 (2014). https://doi.org/10.1007/978-3-319-10599-4_29
-
den Brok, E.J., Hornborg-Svensson, C., Dimitropoulou, N.M., Broeng-Mikkelgaard, S., Olsen, M.T., Abdur Rahman, L., Papathanail, I., Wiede, A., Peters, J., Mertens, P.R., Zikou, E., Karamanakos, G., Athanasopoulos, S., Mitrakou, A., Makrilakis, K., van Kuijk, S.M.J., Mougiakakou, S., van Greevenbroek, M.M.J., Pedersen-Bjergaard, U., de Galan, B.E., Dingena, C.F., MELISSA consortium: Study protocol for exploring diabetes numeracy and health literacy across europe (EDUCATE): A multicentre cross-sectional study. Diabetic Medicine 42(11), e70140 (2025). https://doi.org/10.1111/dme.70140
-
Brown, T.B., Mann, B., Ryder, N., et al.: Language models are few-shot learners. In: Advances in Neural Information Processing Systems. vol. 33, pp. 1877–1901 (2020)
-
Chen, S.Y., Feng, Z., Yi, X.: A general introduction to adjustment for multiple comparisons. Journal of thoracic disease 9(6), 1725 (2017)
-
Chen, W., Hu, H., Chen, X., Verga, P., Cohen, W.: Murag: Multimodal retrieval-augmented generator for open question answering over images and text. In: Proceedings of the 2022 Conference on Empirical Methods in Natural Language Processing. pp. 5558–5570. Association for Computational Linguistics (2022). https://doi.org/10.18653/v1/2022.emltp-main.375
-
Coburn, B., Yue, J., Ma, J., Raghavan, S., Vinod, G., Zhu, F.: Open-knead: Knowledge-grounded nutrition estimation via agentic decomposition. arXiv preprint arXiv:2607.12911 (2026)
-
Dalakleidi, K.V., Papadelli, M., Kapolos, I., Papadimitriou, K.: Applying image-based food-recognition systems on dietary assessment: a systematic review. Advances in Nutrition 13(6), 2590–2619 (2022)
-
Dhaliwal, M., Hua, A., Pullela, L., Burke, R., Qin, Y.: Nutribench: A dataset for evaluating large language models in nutrition estimation from meal descriptions. In: International Conference on Learning Representations (2025)
-
Fukagawa, N.K., McKillop, K.A., Pehrsson, P.R., Moshfegh, A.J., Harnly, J., Finley, J.W.: Usda's fooddata central: What is it? and why is it needed today? The American Journal of Clinical Nutrition 115(3), 619–624 (2022). https://doi.org/10.1093/ajcn/nqab397
-
Gemma Team: Gemma 4 Technical Report (2026), https://arxiv.org/abs/2607.02770
-
Hu, Z., Iscen, A., Sun, C., Wang, Z., Chang, K.W., Sun, Y., Schmid, C., Ross, D.A., Fathi, A.: Reveal: Retrieval-augmented visual-language pre-training with multi-source multimodal knowledge memory. In: Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition. pp. 23369–23379 (2023). https://doi.org/10.1109/CVPR52729.2023.02238
-
Jina AI: jina-reranker-m0: Multilingual multimodal document reranker. Hugging Face model repository (2025), https://huggingface.co/jinaai/jina-reranker-m0
-
Johnson, J., Douze, M., Jégou, H.: Billion-scale similarity search with gpus. IEEE Transactions on Big Data 7(3), 535–547 (2021). https://doi.org/10.1109/TBDATA.2019.2921572
-
Larke, J.A., Chin, E.L., Bouzid, Y.Y., Nguyen, T., Vainberg, Y., Lee, D.H., Pirsiavash, H., Smilowitz, J.T., Lemay, D.G.: Surveying nutrient assessment with photographs of meals (SNAPMe): A benchmark dataset of food photos for dietary assessment. Nutrients 15(23), 4972 (2023). https://doi.org/10.3390/nu15234972
-
Lewis, P., Perez, E., Piktus, A., Petroni, F., Karpukhin, V., Goyal, N., Küttler, H., Lewis, M., Yih, W.t., Rocktäschel, T., Riedel, S., Kiela, D.: Retrieval-augmented generation for knowledge-intensive nlp tasks. In: Advances in Neural Information Processing Systems. vol. 33, pp. 9459–9474 (2020)
-
Li, M., Zhang, Y., Long, D., Chen, K., Song, S., Bai, S., Yang, Z., Xie, P., Yang, A., Liu, D., Zhou, J., Lin, J.: Qwen3-VL-Embedding and Qwen3-VL-Reranker: A unified framework for state-of-the-art multimodal retrieval and ranking. arXiv preprint arXiv:2601.04720 (2026), https://arxiv.org/abs/2601.04720
-
Liu, J.: LlamaIndex. https://github.com/run-llama/llama_index (Nov 2022), software
-
Lu, Y., Stathopoulou, T., Vasiloglou, M.F., Pinault, L.F., Kiley, C., Spanakis, E.K., Mougiakakou, S.: gofood : An artificial intelligence system for dietary assessment. Sensors 20(15), 4283 (2020). https://doi.org/10.3390/s20154283
-
Meyers, A., Johnston, N., Rathod, V., Korattikara, A., Gorban, A., Silberman, N., Guadarrama, S., Papandreou, G., Huang, J., Murphy, K.P.: Im2calories: Towards an automated mobile vision food diary. In: Proceedings of the IEEE International Conference on Computer Vision. pp. 1233–1241 (2015)
-
Min, W., Liu, L., Wang, Z., Luo, Z., Wei, X., Wei, X., Jiang, S.: ISIA Food-500: A dataset for large-scale food recognition via stacked global-local attention network. In: Proceedings of the 28th ACM International Conference on Multimedia. pp. 393–401 (2020). https://doi.org/10.1145/3394171.3414031
-
Min, W., Wang, Z., Liu, Y., Luo, M., Kang, L., Wei, X., Wei, X., Jiang, S.: Large scale visual food recognition. IEEE Transactions on Pattern Analysis and Machine Intelligence 45(8), 9932–9949 (2023). https://doi.org/10.1109/TPAMI.2023.3237871
-
Mistral AI: Mistral Small 3.2 24B Instruct. Model Card (June 2025), https://huggingface.co/mistralai/Mistral-Small-3.2-24B-Instruct-2506
-
Miyazaki, T., de Silva, G.C., Aizawa, K.: Image-based calorie content estimation for dietary assessment. In: 2011 IEEE International Symposium on Multimedia. pp. 363–368. IEEE (2011). https://doi.org/10.1109/ISM.2011.66
-
Mu, Y., Sun, J., He, J.: Benchmarking and improving foundation model dietary estimates from meal images. In: Proceedings of the ACM International Conference on Bioinformatics, Computational Biology and Health Informatics (2025). https://doi.org/10.1145/3765612.3767255
-
National Institute for Public Health and the Environment (RIVM): NEVO-online version 2025/9.0 (2025), dutch Food Composition Database
-
Nussbaum, Z., Duderstadt, B.: Training sparse mixture of experts text embedding models. arXiv preprint arXiv:2502.07972 (2025)
-
Nussbaum, Z., Duderstadt, B., Mulyar, A.: Nomic embed vision: Expanding the latent space. arXiv preprint arXiv:2406.18587 (2024)
-
NVIDIA: Llama Nemotron Rerank VL 1B v2. Hugging Face model repository (2025), https://huggingface.co/nvidia/llama-nemotron-rerank-v1-1b-v2
-
O'Hara, C., Kent, G., Flynn, A.C., Gibney, E.R., Timon, C.M.: An evaluation of chatgpt for nutrient content estimation from meal photographs. Nutrients 17(4), 607 (2025). https://doi.org/10.3390/nu17040607
-
Ollama: Ollama. https://github.com/ollama/ollama, last accessed 22 September 2026
-
OpenAI: Openai api. https://openai.com/api/, last accessed 22 September 2026
-
OpenAI: GPT-5.4 Mini. OpenAI API Model Documentation (2026), https://developers.openai.com/api/docs/models/gpt-5.4-mini
-
Papathanail, I., Abdur Rahman, L., Brigato, L., Bez, N.S., Vasiloglou, M.F., van der Horst, K., Mougiakakou, S.: The nutritional content of meal images in free-living conditions—automatic assessment with gofood . Nutrients 15(17), 3835 (2023). https://doi.org/10.3390/nu15173835
-
Qi, H., Zhu, B., Ngo, C.W., Chen, J., Lim, E.P.: Advancing food nutrition estimation via visual-ingredient feature fusion. In: Proceedings of the International Conference on Multimedia Retrieval. pp. 1091–1099 (2025). https://doi.org/10.1145/3731715.3733269
-
Radford, A., Kim, J.W., Hallacy, C., Ramesh, A., Goh, G., Agarwal, S., Sastry, G., Askell, A., Mishkin, P., Clark, J., Krueger, G., Sutskever, I.: Learning transferable visual models from natural language supervision. In: Proceedings of the 38th International Conference on Machine Learning. vol. 139, pp. 8748–8763 (2021)
-
Rodríguez-De-Vera, J.M., Estepa, I.G., Bolaños, M., Nagarajan, B., Radeva, P.: LOFI: Long-tailed fine-grained network for food recognition. In: Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition Workshops. pp. 3750–3760 (2024)
-
Romero-Tapiador, S., Tolosana, R., Lacruz-Pleguezuelos, B., Marcos-Zambrano, L.J., Bazán, G.X., Espinosa-Salinas, I., Fierrez, J., Ortega-Garcia, J., de Santa Pau, E.C., Morales, A.: Are vision-language models ready for dietary assessment? exploring the next frontier in ai-powered food image recognition. In: Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition Workshops. pp. 430–439 (2025). https://doi.org/10.1109/CVPRW67362.2025.00047
-
Salvador, A., Hynes, N., Aytar, Y., Marin, J., Ofli, F., Weber, I., Torralba, A.: Learning cross-modal embeddings for cooking recipes and food images. In: Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition. pp. 3020–3028 (2017). https://doi.org/10.1109/CVPR.2017.327
-
Sterling, S., Berube, L.T., Glenn, A.J., Shaukat, A., Barua, S., Grams, M.E., Tsirigos, A.: Vision-language models for image-based dietary assessment: A benchmark of accuracy, cost, and prompt strategies across ten models. bioRxiv (2026). https://doi.org/10.64898/2026.07.26.740845
-
Tanabe, H., Yanai, K.: Reasoning-driven food energy estimation via multimodal large language models. Nutrients 17(7), 1128 (2025). https://doi.org/10.3390/nu17071128
-
Thames, Q., Karpur, A., Norris, W., Xia, F., Panait, L., Weyand, T., Sim, J.: Nutrition5k: Towards automatic nutritional understanding of generic food. In: Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition. pp. 8903–8911 (2021). https://doi.org/10.1109/CVPR46437.2021.00879
-
Tschannen, M., Gritsenko, A., Wang, X., Naeem, M.F., Alabdulmohsin, I., Parthasarathy, N., Evans, T., Beyer, L., Xia, Y., Mustafa, B., Hénaff, O., Harmsen, J., Steiner, A., Zhai, X.: SigLIP 2: Multilingual vision-language encoders with improved semantic understanding, localization, and dense features. arXiv preprint arXiv:2502.14786 (2025)
-
Vedovelli, L., Pugnaloni, S., Lanera, C., Sabbatini, D., Bhuyan, M.J., Lorenzoni, G., Gregori, D.: Model architecture dominates nutritional estimation accuracy in vision-language systems. Scientific Reports (2026). https://doi.org/10.1038/s41598-026-58755-w
-
Vera, H.S., Dua, S., Zhang, B., Salz, D., Mullins, R., Panyam, S.R., Smoot, S., Naim, I., Zou, J., Chen, F., et al.: Embeddingemma: Powerful and lightweight text representations. arXiv preprint arXiv:2509.20354 (2025)
-
Wang, S., Sheng, G., Yan, H., Min, W., Jiang, S.: A comparative study of vision-language models for food ingredient recognition and nutrient estimation. Current Research in Food Science 12, 101405 (2026). https://doi.org/10.1016/j.crfs.2026.101405
-
Woolson, R.F.: Wilcoxon signed-rank test. Wiley encyclopedia of clinical trials pp. 1–3 (2007)
-
Yan, R., Luo, H., Lu, J., Liu, D., Posluszny, H., Dhaliwal, M.P., MacLeod, J., Qin, Y., Yang, C., Hartman, T.J., Hu, X.: Dietai24 as a framework for comprehensive nutrition estimation using multimodal large language models. Communications Medicine 5(1), 458 (2025). https://doi.org/10.1038/s43856-025-01159-0
-
Yin, Y., Qi, H., Zhu, B., Chen, J., Jiang, Y.G., Ngo, C.W.: Foodlmm: A versatile food assistant using large multi-modal model. IEEE Transactions on Multimedia 27, 6949–6961 (2025). https://doi.org/10.1109/TMM.2025.3590924
-
Yu, S., Tang, C., Xu, B., Cui, J., Ran, J., Yan, Y., Liu, Z., Wang, S., Han, X., Liu, Z., Sun, M.: Visrag: Vision-based retrieval-augmented generation on multi-modality documents. In: International Conference on Learning Representations (2025)
-
Z.ai: GLM-5.3-Flash/FlashX. https://docs.z.ai/guides/vlm/glm-5.3-flash, accessed: 23 September 2026
-
Zhang, Y., Li, M., Long, D., Zhang, X., Lin, H., Yang, B., Xie, P., Yang, A., Liu, D., Lin, J., et al.: Qwen3 embedding: Advancing text embedding and reranking through foundation models. arXiv preprint arXiv:2506.05176 (2025)
-
Zhou, H., Chow, L., Harnack, L., Panda, S., Manoogian, E.N.C., Li, M., Xiao, Y., Zhang, R.: Nutrirag: Unleashing the power of large language models for food identification and classification through retrieval methods. Journal of the American Medical Informatics Association 33(4), 802-811 (2026). https://doi.org/10.1093/jamia/ocag003
Supplementary Material: NutriVisRAG
S1 Exact Prompt Templates
This section reproduces the textual prompt templates used for Vanilla and NutriVisRAG inference. Angle-bracketed elements indicate query-dependent images or annotations inserted programmatically and are not literal text tokens. For NutriVisRAG, the retrieved exemplars are inserted in descending similarity order before the query image. The prompt wording is reproduced verbatim; only the typesetting is adapted for readability.
S1.1 Vanilla VLM Inference
| Vanilla per-item | |
|---|---|
| System | |
| You are a meal image nutritional analysis tool.You are given a user QUERY meal image.Estimate the item-level weight, energy, and macronutrientsTo do this, think step by step as follows:1. Detect all visually distinguishable edible food items using visual cues such as colour, texture, shape, and spatial boundaries.2. Give each detected food item the most specific food label the image visually supports, as lowercase words separated by underscores (e.g., mashed_potatoes, beef_stroganoff, chicken_rice_pilaf).3. Estimate the weight (in grams), energy (in kcal), carbohydrates (in grams), protein (in grams), and fat (in grams) for each detected food item.4. Assign each food item a confidence score between 0 and 1 reflecting your overall confidence in the food identification and nutritional estimate.5. For each food item, briefly explain the visual evidence supporting the food identification and nutritional estimate.Return structured JSON only — no prose, no markdown. | |
| User | |
| 〈query image〉For this meal image, identify each visible food item and estimate its weight (in grams), energy (in kcal), carbohydrates (in grams), protein (in grams) and fat (in grams), and give each a confidence score (0-1) and a brief justification of the visual evidence. | |
| Vanilla whole-meal | |
| System | |
| You are a meal image nutritional analysis tool. | |
You are given a user QUERY meal image.
Estimate the total weight of the whole meal in grams, then the whole-meal totals for energy (in kcal), carbohydrates (in grams), protein (in grams), and fat (in grams).
Provide an overall confidence score between 0 and 1 and a brief justification of the visual evidence.
Return structured JSON only — no prose, no markdown.
User
〈query image〉
For this meal image, estimate the total meal weight (in grams), then the total energy (in kcal), carbohydrates (in grams), protein (in grams) and fat (in grams), give an overall confidence score (0-1) and a brief justification of the visual evidence.
S1.2 NutriVisRAG Inference
The main experiments retrieve from the combined Nutrition5k and SNAPMe reference corpus. Because all retrieved exemplars contain energy and macronutrient annotations but measured weight is available only for Nutrition5k exemplars, the system prompt explicitly communicates this distinction to the VLM.
NutriVisRAG per-item
System
You are a meal image nutritional analysis tool.
You are given a user QUERY meal image and reference images, each labeled with energy (in kcal), carbohydrates (in grams), protein (in grams), and fat (in grams) at meal and meal-item level.
Additionally, in certain cases, weight (in grams) of meal and meal-item level is given to you.
Use the provided reference information as guidance, whenever possible, to estimate the item-level weight, energy, and macronutrients. To do this, think step by step as follows:
-
Detect all visually distinguishable edible food items using visual cues such as colour, texture, shape, and spatial boundaries.
-
Give each detected food item the most specific food label the image visually supports, as lowercase words separated by underscores (e.g., mashed_potatoes, beef_stroganoff, chicken_rice_pilaf).
-
Estimate the weight (in grams), energy (in kcal), carbohydrates (in grams), protein (in grams), and fat (in grams) for each detected food item.
-
Assign each food item a confidence score between 0 and 1 reflecting your overall confidence in the food identification and nutritional estimate.
-
For each food item, briefly explain the visual evidence supporting the food identification and nutritional estimate.
Return structured JSON only — no prose, no markdown.
User
Here are similar dishes for your reference to help you with the estimations:
<reference image 1>
<reference 1 nutritional annotations>
<reference image 2>
<reference 2 nutritional annotations>
:
<reference image K> <reference K nutritional annotations> <query image>For this meal image, identify each visible food item and estimate its weight (in grams), energy (in kcal), carbohydrates (in grams), protein (in grams) and fat (in grams), and give each a confidence score (0-1) and a brief justification of the visual evidence.
NutriVisRAG whole-meal
System
You are a meal image nutritional analysis tool.
You are given a user QUERY meal image and reference images, each labeled with energy (in kcal), carbohydrates (in grams), protein (in grams), and fat (in grams) at meal and meal-item level.
Additionally, in certain cases, weight (in grams) of meal and meal-item level is given to you.
Use the provided reference information as guidance, whenever possible, to estimate the total weight of the whole meal in grams, then the whole-meal totals for energy (in kcal), carbohydrates (in grams), protein (in grams), and fat (in grams).
Provide an overall confidence score between 0 and 1 and a brief justification of the visual evidence.
Return structured JSON only — no prose, no markdown.
User
Here are similar dishes for your reference to help you with the estimations:
<reference image 1>
<reference 1 nutritional annotations>
<reference image 2>
<reference 2 nutritional annotations>
:
<reference image K> <reference K nutritional annotations> <query image>For this meal image, estimate the total meal weight (in grams), then the total energy (in kcal), carbohydrates (in grams), protein (in grams) and fat (in grams), give an overall confidence score (0-1) and a brief justification of the visual evidence.
S1.3 Retrieved-Exemplar Annotation Format
The nutritional annotation inserted after each retrieved image depends on the source dataset. Measured weight is included for Nutrition5k exemplars and omitted for SNAPMe exemplars rather than estimated or imputed.
Nutrition5k exemplar
Reference — Items: . Meal total: .
SNAPMe exemplar
Reference — Items: . Meal total: .
S2 Effect of Acquisition Distance on MADiMa in Vanilla-Inference
MADiMa provides meal images acquired at both 40 cm and 60 cm, allowing performance to be compared across acquisition distances. Figure S1 reports %MAE and %MAE for the two prompting strategies across the four evaluated VLMs. The 60 cm images yield lower %MAE and %MAE for GPT-5.4-mini, Gemma-4-31B, and GLM-5.3-Flash under both prompting strategies, and for Mistral-Small-3.2 under whole-meal prompting. No corresponding improvement is observed for Mistral-Small-3.2 with per-item prompting.
S3 Complete NutriVisRAG Results
Unless otherwise stated, %MAE values in the supplementary tables and accompanying text are rounded to one decimal place. Table S1 reports the complete NutriVisRAG results for both prompting strategies and all evaluated retrieval encoders. Table 4 of the main paper reports the primary comparison metric (%MAE for Nutrition5k, SNAPMe, and MADiMa; %MAE for EDUCATE), while Table S1 additionally reports the error for each available nutritional target.
Furthermore, to provide a compact cross-dataset summary, Table S2 reports the unweighted mean of the dataset-level %MAE values across Nutrition5k, SNAPMe, and MADiMa. An unweighted mean is used so that each benchmark contributes equally rather than allowing the larger Nutrition5k query set to

Fig. S1: Effect of acquisition distance on Vanilla VLM inference for MADiMa. %MAE and %MAE (lower is better) are shown at 40 cm and 60 cm for per-item and whole-meal prompting across the four evaluated VLMs.
dominate the summary. These values are descriptive and should not be interpreted as pooled micro errors or as evidence that a single retrieval encoder is uniformly best across query sets. EDUCATE is excluded because only CHO is available, whereas the cross-dataset summary is based on %MAE. Across the eight VLM-prompt combinations, PE-Core has the lowest descriptive mean in four, SigLIP 2 in three, and Vanilla in one. These aggregate differences do not establish consistent superiority across individual query sets.
S4 Retrieval Diagnostics
Unless otherwise stated, the exemplar-level diagnostics use the main retrieval configuration with , , and the closest-reference fallback. Retrieval benefit is defined as the per-query reduction in pooled absolute macronutrient error relative to Vanilla, normalised by the query-set mean target macronutrient sum; EDUCATE instead uses absolute CHO error normalised by mean annotated CHO. Visual similarity is the mean cosine similarity between the query and its retrieved exemplars. Nutritional distance is the mean absolute query-exemplar difference across the available macronutrients after normalising each nutrient by its query-set mean; EDUCATE uses CHO only. Associations are quantified using Spearman's rank coefficient ().
S4.1 Visual Retrieval Space
Figure S2 qualitatively examines whether projected query-reference overlap in the visual retrieval embedding space corresponds to downstream NutriVisRAG gains. For each encoder, t-SNE (perplexity 30, PCA initialisation, random seed 0) is applied with cosine distance jointly to the reference corpus and all query sets. PE-Core and SigLIP 2 show stronger dataset-level separation, particularly for MADiMa and EDUCATE, whereas Nomic Vision shows greater mixing between queries and references. However, projected overlap does not correspond directly to
Table S1: Complete nutrient-estimation results with and without NutriVisRAG (%MAE, lower is better), for both prompting strategies side by side. Dashes indicate unavailable evaluation targets for the corresponding dataset. Bold: lowest Macro and Micro (or CHO) error within each model block and prompting strategy; arrows: increase (↑) or decrease (↓) relative to the Vanilla baseline of the same prompting strategy. * marks a statistically significant improvement over that baseline and ▼ a statistically significant degradation (paired Wilcoxon signed-rank test on per-meal absolute errors, Benjamini–Hochberg corrected, q < 0.05); the Macro column is an average of per-nutrient errors and is therefore not tested. Arrows indicate the direction of change based on unrounded values; displayed values are rounded to one decimal place.
| Query set | Model | Setting | Per-item | Whole-meal | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Weight | Energy | CHO | Protein | Fat | Macro | Micro | Weight | Energy | CHO | Protein | Fat | |||
| Nutrition&Gemma-4-31B | Vanilla | 36.3 | 47.7 | 56.0 | 44.3 | 63.3 | 54.5 | 53.6 | 49.2 | 58.4 | 69.6 | 46.4 | 78.4 | 64.8 |
| NutrVisRAG (PE-Core) | 48.4* | 46.0 | 61.0 | 45.8 | 52.9 | 53.2 | 53.7 | 47.4 | 44.9 | 55.9 | 43.9 | 53.4 | 51.0 | |
| NutrVisRAG (SigLIP2) | 47.6* | 47.8 | 58.6 | 47.1 | 58.8 | 54.9 | 54.6 | 46.7 | 45.3 | 54.6 | 43.5 | 55.1 | 51.1 | |
| NutrVisRAG (Nomic Vision) | 46.3* | 51.4 | 59.8 | 55.5 | 60.6 | 60.5 | 59.8 | 46.5 | 49.6 | 56.5 | 51.2 | 61.4 | 56.4 | |
| GPT-5.4-mini | Vanilla | 35.8 | 47.2 | 66.2 | 45.8 | 62.2 | 58.0 | 58.0 | 40.1 | 48.1 | 60.8 | 47.2 | 69.9 | 59.3 |
| NutrVisRAG (PE-Core) | 31.7 | 36.7 | 44.3 | 37.7 | 47.4 | 43.1 | 42.7 | 34.2 | 36.3 | 45.7 | 39.0 | 46.0 | 43.5 | |
| NutrVisRAG (SigLIP2) | 31.6 | 36.4 | 46.2 | 37.4 | 47.4 | 43.7 | 43.4 | 34.5 | 36.9 | 46.8 | 40.0 | 46.0 | 44.3 | |
| NutrVisRAG (Nomic Vision) | 33.7 | 38.8 | 49.2 | 42.5 | 50.9 | 47.4 | 47.1 | 36.2 | 40.5 | 48.3 | 44.0 | 53.6 | 48.6 | |
| Matral-Small-3.2 | Vanilla | 46.0 | 56.2 | 85.4 | 58.8 | 69.3 | 71.2 | 72.1 | 62.2 | 60.8 | 97.5 | 60.0 | 74.3 | 77.3 |
| NutrVisRAG (PE-Core) | 117.8* | 99.5* | 140.7* | 86.0* | 98.4 | 108.4 | 111.2* | 52.9 | 53.1 | 74.3 | 50.4 | 59.8 | 61.5 | |
| NutrVisRAG (SigLIP2) | 124.7* | 109.7 | 144.4* | 94.6* | 114.1* | 117.7 | 119.5* | 53.9 | 55.0 | 72.0 | 51.5 | 66.2 | 63.2 | |
| NutrVisRAG (Nomic Vision) | 134.3* | 137.2* | 164.7* | 126.0* | 140.1* | 143.6 | 145.1* | 54.6 | 65.1 | 79.5 | 65.1 | 79.3 | 74.6 | |
| GLM-5.3-Flash | Vanilla | 38.0 | 45.6 | 62.5 | 40.6 | 59.2 | 54.1 | 54.0 | 42.0 | 47.8 | 65.5 | 41.9 | 61.5 | 56.3 |
| NutrVisRAG (PE-Core) | 52.8 | 47.2 | 61.4 | 48.8 | 49.8 | 53.3 | 54.1 | 59.8 | 53.6 | 62.8 | 55.5 | 56.9 | 58.4 | |
| NutrVisRAG (SigLIP2) | 51.9 | 46.5 | 59.4 | 48.5 | 50.4 | 52.8 | 53.4 | 56.9 | 51.1 | 61.4 | 52.2 | 55.9 | 56.5 | |
| NutrVisRAG (Nomic Vision) | 51.7 | 53.0 | 60.6 | 55.7 | 59.5 | 58.6 | 58.6 | 56.1 | 56.7 | 62.8 | 61.0 | 62.8 | 62.2 | |
| SNAPMe | Vanilla | - | 35.8 | 38.0 | 39.6 | 38.4 | 42.0 | 41.0 | - | 39.3 | 41.4 | 40.8 | 51.0 | 44.4 |
| NutrVisRAG (PE-Core) | - | 41.4 | 45.9 | 43.2 | 50.2 | 46.4 | 46.2 | - | 37.6 | 40.4 | 39.9 | 49.3 | 43.2 | |
| NutrVisRAG (SigLIP2) | - | 38.2 | 41.1 | 42.9 | 50.5 | 44.9 | 44.0 | - | 35.6 | 38.1 | 38.6 | 46.9 | 41.2 | |
| NutrVisRAG (Nomic Vision) | - | 38.8 | 43.5 | 43.6 | 49.4 | 45.5 | 45.0 | - | 36.3 | 39.6 | 40.0 | 48.1 | 42.6 | |
| GPT-5.4-mini | Vanilla | - | 35.0 | 39.4 | 40.1 | 46.5 | 42.0 | 41.4 | - | 35.5 | 40.1 | 38.9 | 48.0 | 42.3 |
| NutrVisRAG (PE-Core) | - | 36.3 | 38.5 | 41.1 | 48.4 | 42.7 | 41.7 | - | 37.4 | 40.9 | 40.7 | 48.7 | 43.4 | |
| NutrVisRAG (SigLIP2) | - | 35.8 | 40.5 | 41.1 | 46.6 | 42.7 | 42.2 | - | 35.1 | 38.9 | 39.4 | 46.6 | 41.6 | |
| NutrVisRAG (Nomic Vision) | - | 37.1 | 39.2 | 42.4 | 50.1 | 43.9 | 42.8 | - | 36.8 | 41.7 | 41.7 | 46.9 | 43.4 | |
| Matral-Small-3.2 | Vanilla | - | 42.0 | 47.8 | 49.8 | 58.6 | 52.1 | 51.1 | - | 37.3 | 41.0 | 43.7 | 52.5 | 45.7 |
| NutrVisRAG (PE-Core) | - | 93.7 | 107.7 | 105.3 | 94.0 | 102.4 | 103.0 | - | 58.4 | 66.1 | 64.7 | 71.9 | 67.6 | |
| NutrVisRAG (SigLIP2) | - | 120.3 | 138.3 | 128.4 | 117.0 | 127.9 | 130.3 | - | 64.9 | 74.1 | 72.3 | 79.8 | 75.4 | |
| NutrVisRAG (Nomic Vision) | - | 97.5 | 118.0 | 103.8 | 96.8 | 106.2 | 108.8 | - | 57.2 | 64.2 | 63.9 | 71.9 | 66.7 | |
| GLM-5.3-Flash | Vanilla | - | 34.0 | 36.9 | 38.6 | 46.5 | 40.7 | 39.8 | - | 34.6 | 37.9 | 38.1 | 44.7 | 40.2 |
| NutrVisRAG (PE-Core) | - | 35.0 | 37.2 | 39.4 | 46.2 | 41.0 | 40.1 | - | 33.1 | 35.2 | 38.0 | 43.4 | 38.9 | |
| NutrVisRAG (SigLIP2) | - | 38.5 | 40.6 | 44.5 | 49.2 | 44.8 | 43.8 | - | 33.2 | 36.1 | 38.2 | 43.4 | 39.2 | |
| NutrVisRAG (Nomic Vision) | - | 37.2 | 38.5 | 40.2 | 48.5 | 42.4 | 41.5 | - | 33.6 | 35.5 | 39.0 | 44.7 | 39.8 | |
retrieval benefit: MADiMa improves in 22/24 configurations despite its separation under PE-Core and SigLIP 2, while SNAPMe improves in only 7/24 despite its training split contributing to the reference corpus. Likewise, Nomic Vision's greater mixing does not yield more consistent MADiMa gains, improving 6/8 configurations compared with 8/8 for PE-Core and SigLIP 2. Because t-SNE can distort neighbourhood and global structure, this analysis is interpreted qualitatively and motivates the exemplar-level analyses below.
S4.2 VLM-Specific Similarity–Benefit Associations
The main paper summarises the association between retrieval benefit and exemplar similarity after averaging retrieval benefit across the four VLMs. Figures S3 and S4 show the corresponding associations separately for each VLM under per-item and whole-meal prompting.
Visual similarity remains weak and inconsistent across VLMs, query sets, and retrieval encoders under both prompting strategies. Nutritional distance shows more consistently negative associations under whole-meal prompting, particularly on MADiMa, whereas the relationship is weaker and less consistent under per-item prompting. The VLM-specific results further show that retrieval benefit
Table S1: (continued) Complete nutrient-estimation results with and without NutriV-isRAG.
| Query set | Model | Setting | Per-item | Whole-meal | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Weight | Energy | CHO Protein | Fat | Macro | Micro | Weight | Energy | CHO Protein | Fat | Macro | Micro | |||||
| MADIMa | Gemma-4-31B | Vanilla | 51.2 | 49.1 | 60.1 | 38.9 | 64.2 | 54.4 | 54.7 | 76.5 | 69.5 | 76.4 | 48.5 | 89.1 | 71.3 | 70.7 |
| NutrivisRAG (PE-Core) | 38.81* | 40.51* | 54.61* | 41.71 | 52.71* | 49.71 | 50.51* | 71.91* | 62.41* | 64.91* | 43.11* | 85.81 | 64.61 | 62.71* | ||
| NutrivisRAG (SigLIP2) | 38.31* | 38.81* | 51.11* | 37.51 | 53.31* | 47.31 | 47.51* | 69.71* | 64.61* | 62.21* | 45.11 | 93.81 | 67.01 | 63.51* | ||
| NutrivisRAG (Nomic Vision) | 41.51* | 40.11* | 53.81* | 40.81* | 58.31 | 51.01 | 50.91* | 74.31 | 57.51* | 64.11* | 40.81* | 79.21* | 61.41 | 60.31* | ||
| GPT-5.4-mini | Vanilla | 53.8 | 45.0 | 75.8 | 32.8 | 46.9 | 51.8 | 57.4 | 93.0 | 76.4 | 89.2 | 38.5 | 96.2 | 74.6 | 75.7 | |
| NutrivisRAG (PE-Core) | 27.51* | 31.91* | 50.71* | 33.21 | 45.21 | 43.01 | 44.51* | 42.31* | 39.91* | 56.51* | 34.51 | 50.01* | 47.01 | 48.71* | ||
| NutrivisRAG (SigLIP2) | 29.11* | 31.91* | 51.81* | 35.91 | 48.91 | 45.51 | 46.51* | 41.21* | 44.21* | 60.81* | 36.71 | 56.51* | 51.31 | 52.91* | ||
| NutrivisRAG (Nomic Vision) | 31.71* | 32.71* | 52.51* | 33.61 | 49.61 | 45.21 | 46.41* | 55.61* | 43.31* | 58.21* | 35.11 | 59.01* | 50.81 | 51.61* | ||
| Mistral-Small-3.2 | Vanilla | 39.7 | 56.8 | 105.5 | 45.1 | 63.8 | 71.5 | 79.5 | 55.5 | 38.5 | 77.6 | 38.6 | 63.7 | 60.0 | 63.4 | |
| NutrivisRAG (PE-Core) | 48.61* | 50.11 | 75.51* | 55.91 | 64.81 | 65.41 | 67.61* | 37.81* | 40.31 | 52.61* | 47.91* | 60.51 | 53.71 | 52.81* | ||
| NutrivisRAG (SigLIP2) | 65.51* | 64.71 | 71.91* | 84.61* | 86.91* | 81.11 | 78.61 | 33.51* | 42.01 | 52.21* | 52.61* | 68.61 | 57.81 | 55.61* | ||
| NutrivisRAG (Nomic Vision) | 61.91* | 66.41 | 90.21* | 69.01* | 84.51 | 81.21 | 82.81 | 44.41* | 53.41 | 72.61* | 59.31 | 75.11 | 69.01 | 69.21 | ||
| GLM-5.3-Flash | Vanilla | 50.5 | 41.9 | 60.5 | 41.5 | 43.6 | 48.5 | 51.5 | 51.5 | 37.7 | 58.4 | 34.5 | 42.4 | 45.1 | 48.2 | |
| NutrivisRAG (PE-Core) | 32.91* | 31.91* | 42.91* | 36.51 | 42.31 | 40.61 | 40.91* | 33.41* | 31.51* | 42.61* | 34.51 | 42.71 | 39.91 | 40.21* | ||
| NutrivisRAG (SigLIP2) | 31.61* | 29.91* | 43.11* | 33.41* | 40.31 | 38.91 | 39.71* | 32.51* | 31.11* | 41.91* | 32.41 | 41.01 | 38.41 | 38.91* | ||
| NutrivisRAG (Nomic Vision) | 35.31* | 33.31* | 49.21* | 31.01* | 43.91 | 41.41 | 42.81* | 37.31* | 33.41* | 47.11* | 33.81 | 42.21 | 41.11 | 42.21* | ||
| EDUCATE Gemma-4-31B | Vanilla | - | - | 53.0 | - | - | - | - | - | - | 45.4 | - | - | - | - | |
| NutrivisRAG (PE-Core) | - | - | 36.51* | - | - | - | - | - | - | 45.01 | - | - | - | - | ||
| NutrivisRAG (SigLIP2) | - | - | 37.81* | - | - | - | - | - | - | 44.51 | - | - | - | - | ||
| NutrivisRAG (Nomic Vision) | - | - | 38.51 | - | - | - | - | - | - | 47.01 | - | - | - | - | ||
| GPT-5.4-mini | Vanilla | - | - | 45.0 | - | - | - | - | - | - | 58.4 | - | - | - | - | |
| NutrivisRAG (PE-Core) | - | - | 40.91 | - | - | - | - | - | - | 46.61* | - | - | - | - | ||
| NutrivisRAG (SigLIP2) | - | - | 38.01* | - | - | - | - | - | - | 43.31* | - | - | - | - | ||
| NutrivisRAG (Nomic Vision) | - | - | 42.51 | - | - | - | - | - | - | 43.61* | - | - | - | - | ||
| Mistral-Small-3.2 | Vanilla | - | - | 51.2 | - | - | - | - | - | - | 51.9 | - | - | - | - | |
| NutrivisRAG (PE-Core) | - | - | 153.81* | - | - | - | - | - | - | 82.21* | - | - | - | - | ||
| NutrivisRAG (SigLIP2) | - | - | 151.61* | - | - | - | - | - | - | 92.81* | - | - | - | - | ||
| NutrivisRAG (Nomic Vision) | - | - | 147.11* | - | - | - | - | - | - | 81.41* | - | - | - | - | ||
| GLM-5.3-Flash | Vanilla | - | - | 53.6 | - | - | - | - | - | - | 54.0 | - | - | - | - | |
| NutrivisRAG (PE-Core) | - | - | 47.81* | - | - | - | - | - | - | 44.01* | - | - | - | - | ||
| NutrivisRAG (SigLIP2) | - | - | 47.91* | - | - | - | - | - | - | 44.11* | - | - | - | - | ||
| NutrivisRAG (Nomic Vision) | - | - | 53.21 | - | - | - | - | - | - | 42.01* | - | - | - | - | ||
Table S2: Descriptive unweighted cross-dataset mean %MAE for each VLM, prompting strategy, and inference setting across Nutrition5k, SNAPMe, and MADIMa (lower is better).
| VLM | Prompt | Vanilla | PE-Core | SigLIP 2 | Nomic Vision |
|---|---|---|---|---|---|
| Gemma-4-31B | Per-item | 49.8 | 50.1 | 48.7 | 51.9 |
| Whole-meal | 59.3 | 52.1 | 51.6 | 52.6 | |
| GPT-5.4-mini | Per-item | 52.2 | 43.0 | 44.0 | 45.4 |
| Whole-meal | 58.5 | 45.0 | 46.0 | 47.5 | |
| Mistral-Small-3.2 | Per-item | 67.5 | 94.1 | 109.5 | 112.2 |
| Whole-meal | 62.2 | 60.8 | 64.7 | 69.9 | |
| GLM-5.3-Flash | Per-item | 48.4 | 45.0 | 45.6 | 47.6 |
| Whole-meal | 48.0 | 45.7 | 44.7 | 47.7 |
varies across models despite using the same retrieved evidence, consistent with the configuration-dependent effects observed in the main experiments.
S4.3 Visual Similarity and Nutritional Proximity
Because each retrieved meal image is provided together with its nutritional annotations, we additionally examine whether visually closer exemplars are also nutritionally closer to the query. This analysis is independent of prompting strategy because the retrieved exemplars are fixed before VLM prompting. Figure S5 shows that the relationship varies substantially across query sets. Visual similarity is more strongly associated with nutritional proximity on Nutrition5k, with weaker associations on SNAPMe and MADIMa and little association on EDUCATE. Thus, visually similar retrieval does not uniformly imply quantitatively similar nutritional annotations across datasets. This provides additional

Fig. S2: t-SNE visualisation of the retrieval embedding spaces for PE-Core-G14, SigLIP 2, and Nomic Vision. Gray points represent the combined Nutrition5k-SNAPMe reference corpus, while coloured points represent evaluation queries from Nutrition5k, SNAPMe, EDUCATE, and MADiMa.
context for the weak and inconsistent relationship between cosine similarity and downstream retrieval benefit.
Nutritional distance is calculated retrospectively from annotated query nutrients and is therefore unavailable as an inference-time retrieval criterion. Moreover, nutritional distance and estimation error both depend on the annotated query targets, so their association with retrieval benefit should be interpreted descriptively rather than causally.
S4.4 Meal-Level Error and Agreement Analysis
Having characterised the retrieved evidence and its association with estimation benefit, we next examine how these effects are distributed across individual meals. We analyse NutriVisRAG at the meal level under both per-item and whole-meal prompting. Whole-meal prompting shows more consistent retrieval benefits in the main experiments, reducing the primary error in 35 of 48 configurations compared with 21 of 48 under per-item prompting. To avoid selecting a particular retrieval representation or VLM, the analysis includes all three visual encoders, all four VLMs, and all four query sets. For the paired-error analysis, the per-meal quantity underlying %MAE is the pooled absolute macronutrient error, , expressed in grams; for EDUCATE, the corresponding quantity is absolute CHO error. For the Bland-Altman analysis, the corresponding pooled predicted and reference macronutrient quantities, and , are compared in grams, while EDUCATE uses predicted and reference CHO. The analysis uses the main retrieval configuration throughout: the combined Nutrition5k-SNAPMe reference corpus, , and the similarity threshold with the closest-reference fallback where applicable.
Figures S6 and S8 compare the absolute estimation error of Vanilla and NutriVisRAG for each meal under per-item and whole-meal prompting, respectively. Whole-meal prompting yields a larger number of individually improved meals than per-item prompting in 37 of the 48 matched VLM-encoder-query-set panels. More than half of the meals improve in 36/48 whole-meal panels compared with
26/48 per-item panels, consistent with the greater aggregate benefit of whole-meal retrieval. However, the number of improved meals does not necessarily determine the aggregate error because %MAE also depends on the magnitude of individual errors. For example, GLM-5.3-Flash under whole-meal prompting improves more than half of Nutrition5k meals for all three retrieval encoders despite increasing the aggregate primary error in all three configurations. The paired plots therefore show that retrieval can benefit a majority of meals while a smaller number of large degradations dominate the aggregate error.
Figures S7 and S9 provide complementary Bland-Altman analyses of the corresponding predictions under per-item and whole-meal prompting, respectively. The plots show that retrieval affects not only average error but also systematic bias and dispersion, with several configurations exhibiting increasing disagreement at larger meal magnitudes. This magnitude-dependent behaviour is particularly pronounced for Mistral-Small-3.2 on SNAPMe and EDUCATE, where large positive deviations remain visible across retrieval encoders. Substantial between-meal dispersion and isolated large errors are also present in configurations with lower aggregate error, showing that improved average performance does not imply uniformly improved agreement. The limits of agreement are therefore interpreted descriptively because the differences are right-skewed in several configurations and can be strongly influenced by large-error meals. For SNAPMe, the reference nutrients are verified self-reported dietary estimates, whereas EDUCATE uses the mean CHO estimate of two dietitians; disagreement on these datasets therefore also incorporates uncertainty in the reference annotations. Together, the paired-error and agreement analyses show that the effect of visual exemplar grounding depends on both how many meals improve and how strongly individual meal errors change.
S5 Exploratory Analyses
In addition to the main retrieval experiments and ablations, we investigate two exploratory extensions across all four evaluated VLMs. Post-hoc food-composition grounding replaces VLM-predicted nutrient values with database-derived estimates based on predicted food identities and weights, and is therefore evaluated under per-item prompting, which provides these predictions. Retrieval reranking instead modifies exemplar selection by rescoring visually retrieved candidates and is evaluated under both prompting strategies.
S5.1 Post-Hoc Food-Composition Grounding
We investigate whether nutrient estimation can be improved by replacing the VLM-predicted nutrient values with values derived from a food-composition database. This procedure requires individually identified foods and their estimated quantities, so the analysis is restricted to per-item predictions. Each VLM-predicted food name and weight are retained; the food name is matched to a food-composition entry and scaled by the predicted weight, and the resulting item-level values are summed to obtain meal-level estimates.
Food-name matching. We compare one lexical and three embedding-based matching strategies. Lexical matching selects the database entry with the highest token-set similarity to the VLM-predicted food name. The embedding-based strategies encode the predicted food name and database entry names and select the entry with the highest cosine similarity. We evaluate Qwen3-Embedding [61], EmbeddingGemma [54] and Nomic Embed Text v2 (MoE) (Nomic Text) [36]. For all strategies, the highest-scoring database entry is accepted without an additional threshold.
Food-composition databases. For Nutrition5k, SNAPMe, and MADiMa, nutrient values are obtained from the U.S. Department of Agriculture (USDA) FoodData Central (FDC) [19]. For EDUCATE, the predicted food name is first matched against the Dutch Food Composition Database (NEVO) [35], with FDC used as a fallback when the highest NEVO matching score is below 0.5. This NEVO-based configuration yields lower CHO error than FDC-only lookup across the evaluated EDUCATE configurations and is therefore reported in Table S3.
Experimental setup. The analysis uses the same fixed 100-query subsets as the retrieval ablations, with and . The same source prediction is used for the original NutriVisRAG estimate and all post-hoc variants, so only the food-name matching and nutrient-substitution step changes between conditions. Embedding models are run locally on an NVIDIA RTX A6000.
Table S3 reports the resulting %MAE and %MAE. The analysis covers 48 model-encoder-query-set configurations (). The original NutriVisRAG estimate achieves the lowest %MAE in 46/48 configurations and the lowest %MAE in 34/36 configurations where energy is available. Lexical, EmbeddingGemma, and Nomic Text matching increase %MAE in all 48 configurations, while Qwen3 increases it in 46/48. After Benjamini–Hochberg correction, significant degradations occur in 45/48 configurations for lexical matching, 30/48 for Qwen3, 47/48 for EmbeddingGemma, and 42/48 for Nomic Text, with no significant improvement for any matching method. Because food identification, database-match correctness, and item-weight estimation are not evaluated independently, these findings characterise the end-to-end post-hoc pipeline rather than the matching models alone. Post-hoc food-composition grounding therefore provides no statistically significant improvement over the original NutriVisRAG predictions. Furthermore, it adds little computational overhead: embedding-based matching takes about 150 ms per predicted food item, while lexical matching takes about 1.5 ms. Its exclusion is therefore driven by degraded accuracy rather than computational cost.
S5.2 Retrieval Reranking
We additionally investigate whether reranking a larger pool of visually retrieved candidates improves nutrient estimation. Rather than directly presenting the five nearest neighbours returned by the visual encoder, we retrieve a larger candidate pool and apply a multimodal relevance model before selecting the final exemplars provided to the VLM.
Reranking strategies. For each query, the visual encoder first retrieves 50 candidate reference meals. We evaluate three multimodal rerankers: Jina Reranker M0 [22], Qwen3-VL-Reranker-2B [26], and Llama Nemotron Rerank VL 1B v2 [38]. Jina and Qwen3 perform image-to-image reranking by scoring the query meal image against each candidate image. Nemotron performs text-to-image reranking, for which the query meal is first converted into a short food and portion description using the same VLM used for nutrient estimation. Each reranker rescores the 50 candidates and retains the five highest-ranked references.
Experimental setup. The analysis uses the same fixed 100-query subsets as the retrieval ablations and evaluates both per-item and whole-meal prompting. The evaluated checkpoints are jinaai/jina-reranker-m0, Qwen/Qwen3-VL-Reranker-2B, and nvidia/llama-nemotron-rerank-vl-1b-v2. The initial candidate pool contains 50 references, which are reranked to the five exemplars presented to the VLM. All remaining retrieval and inference settings are kept unchanged from the corresponding NutriVisRAG configuration. The default NutriVisRAG result without reranking serves as the baseline for each model-encoder-query-set-prompt combination. The rerankers are run locally on an NVIDIA RTX A6000.
Table S4 reports the resulting %MAE and %MAE.
Under per-item prompting, reranking reduces %MAE in 73/144 comparisons, with eight significant improvements and two significant degradations after Benjamini-Hochberg correction. Improvements occur in 24/36 comparisons on MADiMa, 19/36 on Nutrition5k, 17/36 on EDUCATE, and 13/36 on SNAPMe. Jina improves 23/48 per-item comparisons, Qwen3 improves 30/48, and Nemotron improves 20/48. Under whole-meal prompting, reranking reduces %MAE in 76/144 comparisons, with six significant improvements and four significant degradations after correction. Improvements occur in 28/36 comparisons on MADiMa, 21/36 on EDUCATE, 17/36 on SNAPMe, and 10/36 on Nutrition5k. Jina improves 30/48 whole-meal comparisons, while Qwen3 and Nemotron each improve 23/48. These results indicate that reranking can reduce nutrient-estimation error in certain configurations, but its effects depend on the dataset, prompting strategy, VLM, and reranker. Reranking adds a median of 5.3–11.7 s per meal, increasing end-to-end latency by 2.6×–5.1×, depending on the reranker and VLM. Given the variable accuracy gains and additional computational cost, reranking is retained as an exploratory extension rather than incorporated into the default NutriVisRAG pipeline.

Fig. S3: VLM-specific Spearman associations between retrieval benefit and mean visual similarity (left) or retrospective nutritional distance (right) under per-item prompting. Rows represent VLMs, and markers represent retrieval encoders. Filled markers indicate Benjamini–Hochberg-corrected ; open markers indicate non-significant associations.

Fig. S4: VLM-specific Spearman associations between retrieval benefit and mean visual similarity (left) or retrospective nutritional distance (right) under whole-meal prompting. Rows represent VLMs, and markers represent retrieval encoders. Filled markers indicate Benjamini–Hochberg-corrected ; open markers indicate non-significant associations.

Fig. S5: Mean visual similarity versus normalised nutritional distance between queries and retrieved exemplars. Rows represent query sets and columns represent PE-Core, SigLIP 2, and Nomic Vision. Lower nutritional distance indicates greater nutritional proximity.
NutriVisRAG error (g)
Fig. S6: Meal-level absolute error of Vanilla versus NutriVisRAG under per-item prompting. Error is in grams (absolute CHO error for EDUCATE). Rows: query sets; columns: retrieval encoders, each with Gemma-4-31B, GPT-5.4-mini, Mistral-Small-3.2, and GLM-5.3-Flash. Points below the diagonal favour NutriVisRAG, and each panel reports the number of improved meals. Both axes are logarithmic, with g added to all errors so that zero errors remain visible.


Fig. S7: Bland-Altman analysis of Vanilla and NutriVisRAG predictions under per-item prompting. The analysed quantity is CHO + PROT + FAT in grams (CHO for EDUCATE); panel layout as in Fig. S6. Each point shows the difference (predicted minus reference) against the mean of the two. For each condition, solid and dashed lines show the mean difference and SD limits of agreement, respectively.
NutriVisRAG error (g)
Fig. S8: Meal-level absolute error of Vanilla versus NutriVisRAG under whole-meal prompting. Error is in grams (absolute CHO error for EDUCATE). Rows: query sets; columns: retrieval encoders, each with Gemma-4-31B, GPT-5.4-mini, Mistral-Small-3.2, and GLM-5.3-Flash. Points below the diagonal favour NutriVisRAG, and each panel reports the number of improved meals. Both axes are logarithmic, with g added to all errors so that zero errors remain visible.


Fig. S9: Bland-Altman analysis of Vanilla and NutriVisRAG predictions under whole-meal prompting. The analysed quantity is CHO + PROT + FAT in grams (CHO for EDUCATE); panel layout as in Fig. S8. Each point shows the difference (predicted minus reference) against the mean of the two. For each condition, solid and dashed lines show the mean difference and 1.96 SD limits of agreement, respectively.
Table S3: Post-hoc food-composition grounding under per-item prompting on the fixed 100-query subsets (%MAE, lower is better). NutriVisRAG denotes the original prediction; the other columns are the matching approaches defined in the text. Dashes indicate unavailable evaluation targets for the corresponding dataset. Bold indicates the lowest error per row and metric; */▼ indicate significant improvements/degradations relative to NutriVisRAG (paired Wilcoxon signed-rank test, Benjamini–Hochberg corrected, q < 0.05).
| Query set | Model | Encoder | Energy | Micro / CHO | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| NutriVisRAG | Lexical | Qwen3 | Gemma | Nomic | Text | NutriVisRAG | Lexical | Qwen3 | Gemma | Nomic | ||
| Nutrition5k | GPT-5.4-mini | PE-Core | 32.8 | 96.0 | 57.9 | 90.6 | 78.3 | 40.0 | 131.9 | 61.5 | 132.9 | 83.4 |
| SigLIP2 | 30.2 | 147.3 | 48.2 | 82.7 | 77.7 | 35.6 | 172.7 | 54.3 | 126.8 | 86.0 | ||
| Nomic Vision | 29.9 | 127.7 | 54.5 | 90.4 | 80.8 | 37.6 | 161.2 | 57.0 | 137.4 | 81.5 | ||
| Gemma-4-31B | PE-Core | 50.1 | 144.4 | 70.1 | 117.9 | 82.9 | 60.4 | 176.2 | 84.5 | 164.5 | 96.4 | |
| SigLIP2 | 44.8 | 128.7 | 59.0 | 80.5 | 74.2 | 49.8 | 147.6 | 64.0 | 106.5 | 82.2 | ||
| Nomic Vision | 72.2 | 185.6 | 78.6 | 126.0 | 134.1 | 80.7 | 206.8 | 91.1 | 164.3 | 124.4 | ||
| Mistral-Small-3.2 | PE-Core | 244.8 | 384.4 | 249.5 | 394.1 | 311.9 | 259.9 | 418.2 | 266.9 | 482.6 | 346.3 | |
| SigLIP2 | 283.1 | 401.7 | 269.6 | 514.0 | 386.5 | 306.5 | 434.9 | 304.0 | 641.2 | 445.4 | ||
| Nomic Vision | 418.6 | 541.8 | 400.1 | 600.7 | 489.3 | 410.9 | 524.7 | 405.5 | 715.1 | 491.8 | ||
| GLM-5.3-Flash | PE-Core | 50.8 | 148.7 | 88.2 | 110.5 | 90.1 | 52.5 | 181.8 | 81.6 | 156.2 | 90.7 | |
| SigLIP2 | 36.5 | 112.4 | 59.1 | 108.6 | 61.2 | 40.7 | 147.9 | 61.3 | 161.6 | 67.7 | ||
| Nomic Vision | 36.3 | 101.6 | 42.2 | 99.5 | 62.3 | 42.0 | 134.3 | 56.8 | 139.1 | 69.4 | ||
| SNAPMe | GPT-5.4-mini | PE-Core | 34.5 | 84.0 | 71.2 | 58.3 | 69.3 | 42.0 | 109.4 | 82.3 | 78.7 | 78.6 |
| SigLIP2 | 34.5 | 100.6 | 69.0 | 64.3 | 74.8 | 42.4 | 119.0 | 85.0 | 81.7 | 84.0 | ||
| Nomic Vision | 36.1 | 80.6 | 74.5 | 61.1 | 73.7 | 42.4 | 105.1 | 85.5 | 82.6 | 84.8 | ||
| Gemma-4-31B | PE-Core | 38.8 | 96.5 | 72.3 | 54.6 | 67.6 | 44.2 | 112.8 | 86.6 | 75.7 | 76.0 | |
| SigLIP2 | 37.9 | 86.0 | 65.7 | 51.8 | 66.2 | 44.4 | 105.4 | 78.4 | 68.6 | 74.5 | ||
| Nomic Vision | 39.3 | 95.0 | 74.2 | 60.7 | 79.1 | 46.4 | 113.5 | 88.9 | 77.7 | 92.4 | ||
| Mistral-Small-3.2 | PE-Core | 90.9 | 157.6 | 139.2 | 131.0 | 131.0 | 99.3 | 157.9 | 141.1 | 149.6 | 145.9 | |
| SigLIP2 | 126.5 | 217.4 | 219.3 | 172.2 | 174.6 | 133.7 | 220.7 | 219.0 | 191.4 | 182.6 | ||
| Nomic Vision | 108.0 | 154.9 | 175.6 | 148.8 | 144.3 | 113.2 | 163.5 | 180.7 | 169.2 | 159.1 | ||
| GLM-5.3-Flash | PE-Core | 32.5 | 44.6 | 47.9 | 47.8 | 48.4 | 38.0 | 62.5 | 59.0 | 64.9 | 57.8 | |
| SigLIP2 | 35.8 | 49.9 | 52.2 | 50.2 | 53.6 | 41.9 | 62.8 | 66.7 | 66.1 | 62.3 | ||
| Nomic Vision | 35.5 | 49.8 | 60.8 | 56.0 | 59.7 | 40.2 | 63.6 | 72.9 | 71.2 | 65.6 | ||
| MADIa | GPT-5.4-mini | PE-Core | 32.3 | 121.4 | 109.8 | 71.6 | 77.7 | 42.1 | 129.0 | 122.0 | 94.0 | 82.7 |
| SigLIP2 | 32.0 | 140.5 | 111.5 | 72.9 | 85.7 | 43.1 | 133.0 | 128.8 | 100.5 | 85.4 | ||
| Nomic Vision | 33.2 | 114.5 | 119.4 | 75.7 | 90.8 | 42.3 | 115.9 | 132.1 | 104.0 | 92.0 | ||
| Gemma-4-31B | PE-Core | 36.7 | 157.6 | 125.2 | 82.2 | 91.1 | 46.2 | 147.6 | 128.5 | 102.5 | 90.1 | |
| SigLIP2 | 34.8 | 138.2 | 118.5 | 75.7 | 94.2 | 42.5 | 135.4 | 124.4 | 98.9 | 93.8 | ||
| Nomic Vision | 37.0 | 158.2 | 118.3 | 82.3 | 90.7 | 45.1 | 150.8 | 125.2 | 104.4 | 91.6 | ||
| Mistral-Small-3.2 | PE-Core | 48.6 | 130.3 | 109.9 | 72.6 | 98.3 | 63.5 | 143.9 | 114.4 | 87.5 | 101.3 | |
| SigLIP2 | 50.8 | 118.4 | 135.6 | 85.7 | 95.0 | 74.1 | 120.1 | 137.0 | 105.8 | 98.6 | ||
| Nomic Vision | 53.6 | 93.2 | 115.4 | 83.5 | 90.1 | 67.5 | 105.7 | 128.0 | 111.5 | 102.7 | ||
| GLM-5.3-Flash | PE-Core | 30.4 | 62.0 | 94.9 | 50.8 | 48.8 | 37.3 | 69.6 | 97.5 | 66.4 | 65.8 | |
| SigLIP2 | 29.5 | 82.0 | 93.4 | 54.7 | 57.6 | 38.4 | 85.1 | 98.8 | 71.3 | 75.1 | ||
| Nomic Vision | 31.7 | 66.4 | 95.2 | 50.5 | 44.7 | 37.6 | 70.8 | 97.8 | 67.8 | 61.3 | ||
| EDUCATE | GPT-5.4-mini | PE-Core | - | - | - | - | - | 36.1 | 108.4 | 45.7 | 105.7 | 103.3 |
| SigLIP2 | - | - | - | - | - | 38.0 | 98.1 | 45.0 | 119.1 | 110.7 | ||
| Nomic Vision | - | - | - | - | - | 41.9 | 105.8 | 64.4 | 108.0 | 108.4 | ||
| Gemma-4-31B | PE-Core | - | - | - | - | - | 38.5 | 99.4 | 46.9 | 107.8 | 109.8 | |
| SigLIP2 | - | - | - | - | - | 41.9 | 87.3 | 47.2 | 108.4 | 99.3 | ||
| Nomic Vision | - | - | - | - | - | 40.4 | 97.6 | 46.9 | 116.2 | 113.9 | ||
| Mistral-Small-3.2 | PE-Core | - | - | - | - | - | 118.0 | 133.4 | 123.5 | 165.2 | 188.8 | |
| SigLIP2 | - | - | - | - | - | 134.5 | 139.6 | 156.7 | 168.4 | 161.9 | ||
| Nomic Vision | - | - | - | - | - | 140.3 | 153.7 | 152.8 | 184.0 | 169.9 | ||
| GLM-5.3-Flash | PE-Core | - | - | - | - | - | 51.9 | 137.9 | 61.6 | 92.1 | 81.1 | |
| SigLIP2 | - | - | - | - | - | 52.5 | 123.8 | 57.2 | 77.6 | 76.4 | ||
| Nomic Vision | - | - | - | - | - | 55.1 | 147.6 | 58.5 | 94.9 | 88.3 | ||
Table S4: Multimodal reranking on the fixed 100-query subsets, with per-item and whole-meal prompting side by side (%MAE, lower is better); 50 candidates are reranked to five exemplars. NutriVisRAG denotes the default configuration without reranking. Dashes indicate unavailable evaluation targets for the corresponding dataset. Bold indicates the lowest error per row and metric; */▼ indicate significant improvements/degradations relative to NutriVisRAG (paired Wilcoxon signed-rank test, Benjamini–Hochberg corrected, q < 0.05).
| Query set | Model | Encoder | Per-item | Whole-meal | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Energy | Micro / CHO | Energy | Micro / CHO | |||||||||||||
| Default | Jina Qwen3 | Nem. | Default | Jina Qwen3 | Nem. | Default | Jina Qwen3 | Nem. | Default | Jina Qwen3 | Nem. | |||||
| Nutrition&GPT-5.4-mini | PE-Core | 32.8 | 29.9 | 28.7 | 38.5 | 40.0 | 35.2 | 35.6 | 43.5 | 34.7 | 31.5 | 36.8 | 47.4 | 40.4 | 36.9 | |
| SigLIP2 | 30.2 | 33.0 | 30.6 | 30.2 | 35.6 | 41.7 | 34.2 | 36.7 | 36.6 | 33.1 | 34.6 | 37.6 | 39.9 | 39.7 | ||
| Nomic Vision | 29.9 | 30.5 | 27.6 | 37.6 | 37.6 | 38.2 | 36.6 | 45.1 | 40.1 | 38.5 | 36.6 | 39.6 | 46.8 | 44.1 | ||
| Gemma-4-31B | PE-Core | 50.1 | 57.1 | 51.5 | 71.9 | 60.4 | 63.9 | 55.3 | 77.8 | 44.0 | 50.4 | 50.5 | 65.5 | 50.0 | 57.1 | |
| SigLIP2 | 44.8 | 65.7 | 60.4 | 72.9 | 49.8 | 71.3 | 65.9 | 79.2 | 44.3 | 50.4 | 55.6 | 69.7 | 48.4 | 60.6 | ||
| Nomic Vision | 72.2 | 77.7 | 67.8 | 69.9 | 80.7 | 84.9 | 76.2 | 77.3 | 55.7 | 66.9 | 56.2 | 57.6 | 62.5 | 71.1 | ||
| Mistral-Small-3.2 | PE-Core | 244.8 | 89.0 | 109.1 | 186.7 | 259.9 | 107.3 | 126.9 | 200.6 | 70.0 | 79.2 | 85.4 | 88.5 | 82.3 | 89.5 | |
| SigLIP2 | 283.1 | 94.7 | 136.5 | 231.6 | 306.5 | 108.5 | 147.2 | 224.1 | 78.5 | 84.0 | 88.0 | 107.5 | 86.6 | 93.1 | ||
| Nomic Vision | 418.6 | 154.3 | 158.1 | 233.3 | 410.9 | 174.1 | 169.0 | 237.4 | 117.6 | 108.9 | 92.5 | 118.4 | 124.0 | 110.2 | ||
| GLM-5.3-Flash | PE-Core | 50.8 | 38.1 | 41.1 | 53.7 | 52.5 | 41.4 | 42.9 | 53.9 | 38.4 | 36.5 | 44.3 | 53.2 | 39.8 | 39.1 | |
| SigLIP2 | 36.5 | 42.5 | 36.3 | 55.4 | 40.7 | 44.8 | 40.8 | 57.4 | 30.5 | 38.1 | 31.3 | 46.9 | 33.5 | 40.5 | ||
| Nomic Vision | 36.3 | 45.1 | 35.3 | 39.0 | 42.0 | 48.0 | 37.5 | 44.8 | 36.2 | 33.3 | 39.0 | 38.2 | 40.9 | 37.8 | ||
| SNAPMe | GPT-5.4-mini | PE-Core | 34.5 | 37.4 | 35.3 | 37.7 | 42.0 | 42.9 | 43.3 | 42.8 | 33.0 | 39.1 | 37.5 | 34.5 | 41.3 | |
| SigLIP2 | 34.5 | 34.6 | 36.2 | 35.2 | 42.4 | 42.2 | 42.7 | 42.0 | 33.6 | 34.9 | 36.2 | 36.9 | 41.5 | 41.6 | ||
| Nomic Vision | 36.1 | 34.2 | 36.0 | 34.9 | 42.4 | 42.3 | 43.5 | 42.6 | 36.3 | 35.4 | 36.6 | 38.6 | 43.1 | 42.7 | ||
| Gemma-4-31B | PE-Core | 38.8 | 39.3 | 42.9 | 42.9 | 44.2 | 45.6 | 48.2 | 46.5 | 38.1 | 38.6 | 38.6 | 37.9 | 42.5 | ||
| SigLIP2 | 37.9 | 45.8 | 36.2 | 42.4 | 44.4 | 51.1 | 43.0 | 49.5 | 36.8 | 36.9 | 37.1 | 36.6 | 41.2 | 41.1 | ||
| Nomic Vision | 39.3 | 37.3 | 35.8 | 37.2 | 46.4 | 42.7 | 42.6 | 44.9 | 36.3 | 34.8 | 37.1 | 35.3 | 41.5 | 40.2 | ||
| Mistral-Small-3.2 | PE-Core | 90.9 | 120.2 | 90.6 | 98.3 | 99.3 | 123.6 | 95.3 | 105.1 | 57.5 | 59.8 | 53.2 | 59.4 | 66.6 | 66.5 | |
| SigLIP2 | 126.5 | 116.8 | 113.9 | 142.8 | 133.7 | 125.2 | 123.0 | 146.3 | 66.3 | 60.2 | 54.2 | 57.5 | 76.0 | 70.9 | ||
| Nomic Vision | 108.0 | 138.5 | 95.9 | 110.5 | 113.2 | 145.4 | 100.0 | 115.1 | 59.5 | 61.7 | 51.7 | 49.2 | 67.4 | 69.5 | ||
| GLM-5.3-Flash | PE-Core | 32.5 | 34.9 | 32.8 | 34.2 | 38.0 | 40.6 | 38.5 | 39.1 | 30.8 | 32.8 | 34.7 | 34.2 | 35.8 | 38.0 | |
| SigLIP2 | 35.8 | 34.8 | 39.4 | 32.8 | 41.9 | 39.8 | 44.5 | 38.8 | 33.7 | 33.4 | 33.0 | 38.4 | 39.0 | 38.4 | ||
| Nomic Vision | 35.5 | 35.5 | 44.1 | 39.5 | 40.2 | 40.9 | 47.1 | 43.9 | 32.4 | 36.3 | 33.2 | 33.6 | 38.5 | 40.5 | ||
| MADiMa | GPT-5.4-mini | PE-Core | 32.3 | 31.2 | 33.4 | 32.7 | 42.1 | 41.7 | 41.7 | 42.8 | 37.6 | 37.0 | 39.2 | 33.9 | 44.6 | 44.9 |
| SigLIP2 | 32.0 | 30.4 | 31.0 | 33.5 | 43.1 | 40.5 | 40.7 | 43.4 | 45.2 | 38.4 | 38.1 | 38.6 | 53.0 | 46.3 | ||
| Nomic Vision | 33.2 | 32.4 | 35.2 | 31.9 | 42.3 | 40.5 | 42.8 | 42.1 | 41.8 | 37.9 | 41.9 | 36.9 | 47.9 | 46.0 | ||
| Gemma-4-31B | PE-Core | 36.7 | 38.6 | 35.8 | 35.7 | 46.2 | 46.2 | 44.4 | 44.8 | 57.4 | 54.0 | 53.3 | 53.0 | 59.3 | 56.7 | |
| SigLIP2 | 34.8 | 38.4 | 35.2 | 36.6 | 42.5 | 46.1 | 42.4 | 46.3 | 56.6 | 55.9 | 51.4 | 51.4 | 58.2 | 57.7 | ||
| Nomic Vision | 37.0 | 35.0 | 34.8 | 37.2 | 45.1 | 43.8 | 41.6 | 45.2 | 52.2 | 47.4 | 45.1 | 48.5 | 55.3 | 52.2 | ||
| Mistral-Small-3.2 | PE-Core | 48.6 | 42.8 | 48.7 | 44.2 | 63.5 | 57.8 | 59.1 | 55.3 | 40.7 | 40.8 | 41.8 | 36.4 | 49.5 | 49.9 | |
| SigLIP2 | 59.8 | 47.5 | 48.7 | 45.5 | 74.1 | 58.7 | 59.3 | 52.8 | 38.7 | 39.4 | 41.1 | 42.1 | 54.0 | 50.2 | ||
| Nomic Vision | 53.6 | 48.0 | 58.1 | 50.8 | 67.5 | 59.7 | 72.9 | 61.3 | 50.7 | 57.5 | 42.8 | 40.5 | 66.0 | 46.4 | ||
| GLM-5.3-Flash | PE-Core | 30.4 | 30.2 | 29.4 | 30.0 | 37.3 | 38.7 | 38.1 | 37.1 | 29.8 | 31.1 | 30.2 | 31.2 | 37.9 | 37.0 | |
| SigLIP2 | 29.5 | 31.1 | 27.4 | 29.4 | 38.4 | 38.1 | 36.4 | 36.2 | 29.6 | 29.8 | 27.4 | 29.8 | 36.9 | 35.4 | ||
| Nomic Vision | 31.7 | 32.8 | 28.7 | 31.5 | 37.6 | 41.4 | 36.4 | 38.3 | 31.2 | 30.4 | 29.2 | 29.4 | 37.5 | 37.5 | ||
| EDUCATE | GPT-5.4-mini | PE-Core | - | - | - | 36.1 | 46.0 | 36.4 | 43.8 | - | - | - | - | 41.1 | 42.4 | |
| SigLIP2 | - | - | - | - | 38.0 | 42.6 | 40.1 | 36.5 | - | - | - | - | 41.6 | 47.5 | ||
| Nomic Vision | - | - | - | - | 41.9 | 42.9 | 40.8 | 44.3 | - | - | - | - | 42.9 | 43.3 | ||
| Gemma-4-31B | PE-Core | - | - | - | 38.5 | 32.1 | 38.0 | 34.4 | - | - | - | - | 40.8 | 39.5 | ||
| SigLIP2 | - | - | - | 41.9 | 29.8 | 39.4 | 37.4 | - | - | - | - | 48.3 | 33.0 | |||
| Nomic Vision | - | - | - | 40.4 | 40.7 | 41.0 | 39.0 | - | - | - | - | 50.5 | 37.8 | |||
| Mistral-Small-3.2 | PE-Core | - | - | - | 118.0 | 110.8 | 98.2 | 120.5 | - | - | - | - | - | 91.0 | 56.5 | |
| SigLIP2 | - | - | - | 134.5 | 116.7 | 119.3 | 115.1 | - | - | - | - | - | 96.8 | 62.2 | ||
| Nomic Vision | - | - | - | 140.3 | 111.7 | 126.8 | 147.8 | - | - | - | - | - | 90.7 | 60.0 | ||
| GLM-5.3-Flash | PE-Core | - | - | - | 51.9 | 57.2 | 53.9 | 56.8 | - | - | - | - | - | 46.7 | 41.5 | |
| SigLIP2 | - | - | - | 52.5 | 61.4 | 55.1 | 66.0 | - | - | - | - | - | 46.2 | 49.5 | ||
| Nomic Vision | - | - | - | 55.1 | 55.1 | 56.6 | 51.5 | - | - | - | - | - | 44.0 | 43.5 | ||