← back to Exo
reusing helper function to get cached directory
de09e2a831acccc6b149d62843afcc1b213336a7 · 2024-11-13 15:10:25 -0800 · cadenmackenzie
Files touched
Diff
commit de09e2a831acccc6b149d62843afcc1b213336a7
Author: cadenmackenzie <cadenmackenzie@gmail.com>
Date: Wed Nov 13 15:10:25 2024 -0800
reusing helper function to get cached directory
---
exo/api/chatgpt_api.py | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/exo/api/chatgpt_api.py b/exo/api/chatgpt_api.py
index 08e68ce4..d0ee3d1b 100644
--- a/exo/api/chatgpt_api.py
+++ b/exo/api/chatgpt_api.py
@@ -18,6 +18,7 @@ from exo.orchestration import Node
from exo.models import build_base_shard, model_cards, get_repo, pretty_name
from typing import Callable
import os
+from exo.download.hf.hf_helpers import get_hf_home
class Message:
@@ -205,7 +206,7 @@ class ChatGPTAPI:
if DEBUG >= 2:
print(f"\nChecking if model {model_name} is downloaded:")
- cache_dir = Path.home() / ".cache" / "huggingface" / "hub"
+ cache_dir = get_hf_home() / "hub"
repo = get_repo(model_name, self.inference_engine_classname)
if DEBUG >= 2:
← c7dd3126 adding logic to check which models are downloaded
·
back to Exo
·
removing uneccesary console logs and fixing order of variabl 7d7bdd83 →