[Bugfix] Fix LLaVA-NeXT (#5380)

This commit is contained in:
Cyrus Leung
2024-06-10 15:38:47 +00:00
committed by GitHub
parent 774d1035e4
commit 2c0d933594
2 changed files with 25 additions and 1 deletions
+1 -1
View File
@@ -77,7 +77,7 @@ def get_full_image_text_prompt(image_prompt: str, text_prompt: str,
"""Combine image and text prompts for vision language model depending on
the model architecture."""
if config.hf_config.model_type == "llava":
if config.hf_config.model_type in ("llava", "llava_next"):
full_prompt = f"{image_prompt}\n{text_prompt}"
else:
raise ValueError(