diff --git a/llama_stack/distribution/utils/model_utils.py b/llama_stack/distribution/utils/model_utils.py index e104965a5..abd0dc087 100644 --- a/llama_stack/distribution/utils/model_utils.py +++ b/llama_stack/distribution/utils/model_utils.py @@ -4,11 +4,10 @@ # This source code is licensed under the terms described in the LICENSE file in # the root directory of this source tree. -import os +from pathlib import Path from .config_dirs import DEFAULT_CHECKPOINT_DIR def model_local_dir(descriptor: str) -> str: - path = os.path.join(DEFAULT_CHECKPOINT_DIR, descriptor) - return path.replace(":", "-") + return str(Path(DEFAULT_CHECKPOINT_DIR) / (descriptor.replace(":", "-")))