common: support remote preset (#18520)

* arg: support remote preset

* proof reading

* allow one HF repo to point to multiple HF repos

* docs: mention about multiple GGUF use case

* correct clean_file_name

* download: also return HTTP status code

* fix case with cache file used

* fix --offline option
This commit is contained in:
Xuan-Son Nguyen
2026-01-08 22:35:40 +01:00
committed by GitHub
parent 046d5fd44e
commit 8ece3836b4
6 changed files with 324 additions and 82 deletions
+8
View File
@@ -65,6 +65,14 @@ bool common_download_model(
// returns list of cached models
std::vector<common_cached_model_info> common_list_cached_models();
// download single file from url to local path
// returns status code or -1 on error
int common_download_file_single(const std::string & url,
const std::string & path,
const std::string & bearer_token,
bool offline,
const common_header_list & headers = {});
// resolve and download model from Docker registry
// return local path to downloaded model file
std::string common_docker_resolve_model(const std::string & docker);