From 98fe51f3a220d85ed8faaa25f9c508c09a457b48 Mon Sep 17 00:00:00 2001 From: Frank Liu Date: Sat, 20 Jul 2024 20:34:48 -0700 Subject: [PATCH] [wlm] Fixes retrieve config.json error Handle git-ls case --- wlm/src/main/java/ai/djl/serving/wlm/LmiUtils.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wlm/src/main/java/ai/djl/serving/wlm/LmiUtils.java b/wlm/src/main/java/ai/djl/serving/wlm/LmiUtils.java index 18df917e2..725dad6a1 100644 --- a/wlm/src/main/java/ai/djl/serving/wlm/LmiUtils.java +++ b/wlm/src/main/java/ai/djl/serving/wlm/LmiUtils.java @@ -282,7 +282,7 @@ private static URI getHuggingFaceHubConfigUri(String modelId) { } for (String configFile : possibleConfigFiles) { URI configUri = - URI.create("https://huggingface.co/" + modelId + "/raw/main/" + configFile); + URI.create("https://huggingface.co/" + modelId + "/resolve/main/" + configFile); try (InputStream is = Utils.openUrl(configUri.toURL(), headers)) { is.transferTo(OutputStream.nullOutputStream()); return configUri;