File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
vllm/model_executor/models Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -227,12 +227,14 @@ def get_replacement_qwen2_audio(item_idx: int):
227227 ]
228228
229229 def _always_apply_prompt_replacements (self ) -> bool :
230- # HF never applies prompt replacements, so we have to do it ourselves.
230+ # Qwen2-Audio processor will start inserting placeholder tokens
231+ # in an upcoming release:
232+ # https://github.com/huggingface/transformers/pull/35534
231233 # NOTE: `_find_placeholders_by_modality` may incorrectly think that HF
232234 # has already performed processing for multi-audio input when the input
233235 # audios are short (the corresponding placeholders may take up fewer
234236 # tokens than the number of audio items)
235- return True
237+ return not hasattr ( self . _get_hf_processor (), "audio_token" )
236238
237239
238240@MULTIMODAL_REGISTRY .register_processor (Qwen2AudioMultiModalProcessor )
You can’t perform that action at this time.
0 commit comments