@tduncan / Nvidia-Optimization-Stack-VLLM Mirror · read-only / commits / 94de871546
Fork 0

A high-throughput and memory-efficient inference and serving engine for LLMs

Mirrored from https://github.com/tduncan-lum/Nvidia-Optimization-Stack---VLLM.git

Synced Nov 8, 14:13 UTC

[Misc] allow specify is_mm_prefix_lm in hf_config (#34215)

Phúc H. Lê Khắc committed Feb 10, 2026 at 18:16 UTC 94de871546e8da687c08ed8a7e0a26531500d4bd
1 file changed +3
vllm/config/model.py
+3
@@ -1119,6 +1119,9 @@ class ModelConfig:
1119 @cached_property
1120 def is_mm_prefix_lm(self) -> bool:
1121 """Whether to use bidirectional attention for mm positions."""
1122 + if hasattr(self.hf_config, "is_mm_prefix_lm"):
1123 + return bool(self.hf_config.is_mm_prefix_lm)
1124 + # fallback to list of known models
1125 MM_PREFIX_LM_MODELS = (
1126 "gemma3",
1127 "molmo2",