Skip to content

Commit 736fffe

Browse files
hhk7734KrishnanPrash
authored andcommitted
feat: support HF_HOME/_ENDPOINT env for Hugging Face models (#2642)
Signed-off-by: Hyeonki Hong <hhk7734@gmail.com> Signed-off-by: Krishnan Prashanth <kprashanth@nvidia.com>
1 parent dacbd8a commit 736fffe

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/llm/src/hub.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ fn is_weight_file(filename: &str) -> bool {
4242
pub async fn from_hf(name: impl AsRef<Path>, ignore_weights: bool) -> anyhow::Result<PathBuf> {
4343
let name = name.as_ref();
4444
let token = env::var(HF_TOKEN_ENV_VAR).ok();
45-
let api = ApiBuilder::new()
45+
let api = ApiBuilder::from_env()
4646
.with_progress(true)
4747
.with_token(token)
4848
.high()

0 commit comments

Comments
 (0)