Upgrading hf-hub to 0.2.0 (Modified API to not pass the Repo around

all the time)
This commit is contained in:
Nicolas Patry
2023-07-27 20:05:02 +02:00
parent f291065f6c
commit ca479a873e
5 changed files with 23 additions and 23 deletions

View File

@ -69,10 +69,11 @@ impl Args {
)
} else {
let api = Api::new()?;
let api = api.repo(repo);
(
api.get(&repo, "config.json")?,
api.get(&repo, "tokenizer.json")?,
api.get(&repo, "model.safetensors")?,
api.get("config.json")?,
api.get("tokenizer.json")?,
api.get("model.safetensors")?,
)
};
let config = std::fs::read_to_string(config_filename)?;