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 14, 23:45 UTC
[Bugfix] GGUF: fix AttributeError: 'PosixPath' object has no attribute 'startswith' (#21579)
Signed-off-by: Kebe <mail@kebe7jun.com>
Kebe committed
Jul 25, 2025 at 18:42 UTC
7311f74468d2ba4f89658aa0fedf3811f8769b30
1 file changed
+3
-3
vllm/transformers_utils/config.py
+3
-3
@@ -584,7 +584,7 @@ def get_pooling_config_name(pooling_name: str) -> Union[str, None]:
584
585
586
@cache
587
-def get_sentence_transformer_tokenizer_config(model: str,
587
+def get_sentence_transformer_tokenizer_config(model: Union[str, Path],
588
revision: Optional[str] = 'main'
589
):
590
"""
@@ -592,7 +592,7 @@ def get_sentence_transformer_tokenizer_config(model: str,
592
given Sentence Transformer BERT model.
593
594
Parameters:
595
- - model (str): The name of the Sentence Transformer
595
+ - model (str|Path): The name of the Sentence Transformer
596
BERT model.
597
- revision (str, optional): The revision of the m
598
odel to use. Defaults to 'main'.
@@ -620,7 +620,7 @@ def get_sentence_transformer_tokenizer_config(model: str,
620
if encoder_dict:
621
break
622
623
- if not encoder_dict and not model.startswith("/"):
623
+ if not encoder_dict and not Path(model).is_absolute():
624
try:
625
# If model is on HuggingfaceHub, get the repo files
626
repo_files = list_repo_files(model,