Downloads · 30 days
16
7% of all-time downloads
HPAI-BSC/Aloe-Vision-72B-AR
Aloe-Vision-72B-AR is a visual question answering model from HPAI-BSC. Use it for the visual question answering task on the model card, and read the license before you ship it in a product. The card lists the license as cc-by-nc-sa-4.0.
<p align="center" <img alt="Aloe-Vision" src="https://cdn-uploads.huggingface.co/production/uploads/63a417e70cf4daf6166777a2/xkm30vCSIz1GKK3QIQZ.png" width="25%" </p
Downloads · 30 days
16
7% of all-time downloads
All-time downloads
224
Public
Parameters
73.4B
147 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors147 GB · 100%
From the Hugging Face model README
Aloe-Vision is a medical Large Vision–Language Model built on Qwen2-VL-Instruct, released in 7B and 72B sizes. The model is trained on a ~3.5 M samples balanced mixture across medical vs. general and multimodal vs. text-only sources, rebalanced by loss-contributing assistant tokens to avoid long-answer bias. We implement leakage control of evaluation images in the training data via exact 64-bit image-hash matching, removing any duplicates from the training. Quality filtering of the training data combines (1) LVLM-based sample scoring (1–5 scale) for image–question–answer coherence and relevance and (2) answer perplexity checks to flag trivial or noisy annotations. Thresholds are dataset-specific and manually tuned, leading to the removal of low-quality outliers while preserving clinically meaningful diversity. Furthermore, the model is additionally fine-tuned on 17.2 K adversarially perturbed medical samples to enhance robustness against sycophantic and misleading multimodal cues. The model is released for research purposes under CC BY-NC-SA 4.0.
Intended: research on medical VQA and multimodal reasoning, dataset analysis, academic benchmarking.
Out-of-scope:
Aloe-Vision follows the Qwen2-VL chat template and processor API. Replace the image path(s) and prompt content to suit your use case.
import torch
from transformers import AutoProcessor, AutoModelForVision2Seq
model_id = "HPAI-BSC/Aloe-Vision-72B-AR"
processor = AutoProcessor.from_pretrained(model_id, trust_remote_code=True)
model = AutoModelForVision2Seq.from_pretrained(
model_id,
torch_dtype=torch.bfloat16,
device_map="auto",
trust_remote_code=True,
)
messages = [
{
"role": "user",
"content": [
{"type": "image", "image": "path/to/your_image.png"},
{"type": "text", "text": "What abnormality do you observe? Be concise."}
]
}
]
text = processor.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
image_inputs = processor.process_vision_info(messages)
inputs = processor(
text=[text],
**image_inputs,
return_tensors="pt"
).to(model.device)
generated = model.generate(
**inputs,
max_new_tokens=256,
do_sample=False,
eos_token_id=processor.tokenizer.eos_token_id,
)
output_text = processor.batch_decode(generated, skip_special_tokens=True)[0]
print(output_text.split(text)[-1].strip())
Grounding: Aloe-Vision supports region-referenced grounding using Qwen2-VL box marker tokens.
We construct a balanced mixture across two axes: modality (multimodal vs text-only) and domain (medical vs general). All sources are normalized to a unified trl conversation schema. Medical multimodal includes both global understanding and fine-grained region reasoning.
The dataset can be found in HPAI-BSC/Aloe-Vision-Data.
Aloe-Vision targets comprehensive evaluation across medical multimodal, medical text-only, general multimodal, and general text-only tasks. Benchmarks are run with identical settings for Aloe-Vision and baselines to ensure reproducibility.
Benchmarks:
Evaluation protocol
| Model | OmniMedVQA | GMAI-MMBENCH | PathMMU | ProbMed | SLAKE | MMMU | MultiMedQA | MMLU |
|---|---|---|---|---|---|---|---|---|
| Qwen2-VL-72B (general) | 77.90 | 51.03 | 64.71 | 73.87 | 68.15 | 61.22 | 74.25 | 81.86 |
| InternVL3.5-30B-A3B (general) | 91.60 | 63.91 | 72.07 | 82.21 | <u>79.87</u> | 60.67 | 71.21 | 81.68 |
| Linghsu-32B | 80.20 | 53.54 | 67.60 | <u>80.84</u> | 86.08 | 53.00 | 72.08 | 81.32 |
| HuatuoGPT-Vision-34B | 68.90 | 48.31 | 54.90 | 71.79 | 60.03 | 27.11 | 60.57 | 72.80 |
| Aloe-Vision-72B | <u>85.20</u> | <u>55.12</u> | 70.32 | 77.71 | 69.36 | <u>62.00</u> | 76.35 | <u>82.52</u> |
| Aloe-Vision-72B-AR | 84.00 | 54.79 | <u>71.45</u> | 77.29 | 67.36 | 62.89 | <u>76.24</u> | 82.55 |
To improve robustness against noisy or misleading inputs, we conducted an additional fine-tuning stage focused on adversarial robustness. This stage aimed to mitigate common LVLM vulnerabilities such as sycophantic behavior or misleading multimodal cues. An adversarial benchmark was first created by applying controlled perturbations to existing medical datasets (distinct from those used in evaluation). These perturbations introduced conflicting or false multimodal signals (e.g., mismatched region annotations or incorrect textual hints). Using this adversarially transformed dataset, we trained an Aloe-Vision-72B-AR variant through a single-stage post-training SFT consisting of 17.2K adversarial samples. The adversarial fine-tuning employed the same optimization setup as the base model and ran for 1 epoch. This procedure yielded substantial improvements across all adversarial evaluation categories while preserving performance on standard benchmarks.
The following table reports model accuracy (%) under different adversarial perturbations. Columns correspond to:
| Model | Cls Base | Cap | Pmt | Syc | Det Base | Cap | Pmt | Syc | Leg |
|---|---|---|---|---|---|---|---|---|---|
| Qwen2-VL-72B | 61.2 | 2.1 | 5.1 | 35.6 | 75.9 | 3.7 | 3.6 | 14.7 | 41.1 |
| InternVL3.5-30B | <u>68.3</u> | 7.3 | 5.1 | 35.7 | 73.1 | 35.1 | <u>33.5</u> | 27.5 | 48.1 |
| Lingshu-32B | 68.1 | 4.5 | <u>29.7</u> | 55.4 | <u>80.2</u> | 8.5 | 19.6 | <u>35.0</u> | 60.1 |
| HuatuoGPT-Vision-34B | 59.6 | 22.2 | 10.0 | 16.1 | 64.1 | <u>40.9</u> | 5.6 | 5.2 | 50.7 |
| Aloe-Vision-72B | 64.2 | 4.7 | 6.9 | 73.9 | 69.7 | 3.0 | 1.9 | 8.6 | 37.5 |
| Aloe-Vision-72B-AR | 69.8 | <u>17.0</u> | 50.5 | <u>62.8</u> | 81.8 | 48.6 | 64.0 | 66.3 | <u>53.4</u> |
Recommended practice
Clinical safety: Aloe-Vision is a research model. It must not be used for diagnosis, treatment, or clinical decision-making. Always place a qualified human in the loop.
@InProceedings{pmlr-v315-guasch-marti26a,
title = {Aloe-Vision: Robust Vision-Language Models for Healthcare},
author = {Guasch-Mart\'i, Jaume and Lopez-Cuena, Enrique and Su\'arez-Fern\'andez, Mart\'in and Bayarri-Planas, Jordi and Arias-Duart, Anna and Garcia-Gasulla, Dario},
booktitle = {Proceedings of The 9th International Conference on Medical Imaging with Deep Learning},
pages = {2404--2426},
year = {2026},
volume = {315},
series = {Proceedings of Machine Learning Research},
month = {08--10 Jul},
publisher = {PMLR},
url = {https://proceedings.mlr.press/v315/guasch-marti26a.html},
}
<!--
```
@misc{aloevision2025hpai,
title = {Aloe-Vision: A Medical Large Vision-Language Model},
author = {HPAI - Barcelona Supercomputing Center},
year = {2025},
howpublished = {\url{https://huggingface.co/HPAI-BSC/Aloe-Vision-72B}}
}
```
-->
Developed by the High Performance Artificial Intelligence (HPAI) group at Barcelona Supercomputing Center (BSC). Contact: [email protected].