File tree Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -67,8 +67,8 @@ def _get_test_model_path() -> List[Path]:
67
67
68
68
69
69
def _get_read_only_weight_caches () -> List [Path ]:
70
- if "MLC_LLM_READONLY_WEIGHT_CACHES " in os .environ :
71
- return [Path (p ) for p in os .environ ["MLC_LLM_READONLY_WEIGHT_CACHES " ].split (os .pathsep )]
70
+ if "MLC_LLM_READONLY_WEIGHT_CACHE " in os .environ :
71
+ return [Path (p ) for p in os .environ ["MLC_LLM_READONLY_WEIGHT_CACHE " ].split (os .pathsep )]
72
72
return []
73
73
74
74
@@ -80,6 +80,6 @@ def _get_read_only_weight_caches() -> List[Path]:
80
80
81
81
MLC_DOWNLOAD_POLICY = os .environ .get ("MLC_DOWNLOAD_POLICY" , "ON" )
82
82
MLC_LLM_HOME : Path = _get_cache_dir ()
83
- MLC_LLM_READONLY_WEIGHT_CACHES = _get_read_only_weight_caches ()
83
+ MLC_LLM_READONLY_WEIGHT_CACHE = _get_read_only_weight_caches ()
84
84
85
85
_check ()
Original file line number Diff line number Diff line change 16
16
from .constants import (
17
17
MLC_DOWNLOAD_POLICY ,
18
18
MLC_LLM_HOME ,
19
- MLC_LLM_READONLY_WEIGHT_CACHES ,
19
+ MLC_LLM_READONLY_WEIGHT_CACHE ,
20
20
MLC_TEMP_DIR ,
21
21
)
22
22
from .style import bold
@@ -147,7 +147,7 @@ def download_and_cache_mlc_weights( # pylint: disable=too-many-locals
147
147
domain = "hf"
148
148
149
149
readonly_cache_dirs = []
150
- for base in MLC_LLM_READONLY_WEIGHT_CACHES :
150
+ for base in MLC_LLM_READONLY_WEIGHT_CACHE :
151
151
cache_dir = base / domain / user / repo
152
152
readonly_cache_dirs .append (str (cache_dir ))
153
153
if (cache_dir / "mlc-chat-config.json" ).is_file ():
@@ -170,7 +170,7 @@ def download_and_cache_mlc_weights( # pylint: disable=too-many-locals
170
170
raise RuntimeError (
171
171
f"Cannot find cache for { model_url } , "
172
172
"cannot proceed to download as MLC_DOWNLOAD_POLICY=READONLY, "
173
- "please check settings MLC_LLM_READONLY_WEIGHT_CACHES , "
173
+ "please check settings MLC_LLM_READONLY_WEIGHT_CACHE , "
174
174
f"local path candidates: { readonly_cache_dirs } "
175
175
)
176
176
You can’t perform that action at this time.
0 commit comments