Hugging Face Hub
5 nodes
On this page 5
Cache Folder
FunctionThe folder downloaded models are kept in.
Signature
CacheFolder() -> Text
string CacheFolder()
Returns
| Folder | Text |
- Ships with
- Divooka Compute
- Graph kinds
- Flows Function Events Routine Constructs StateMachineState
- Declared by
- Hugging Face Hub
- Package
- Machine Learning
Downloaded Models
FunctionThe model repositories in the cache, with how much disk each takes.
Signature
DownloadedModels() -> (Repositories: Text Array, sizes: Number Array)
string[] DownloadedModels(out double[] sizes)
Returns
| Repositories | Text Array |
| sizes | Number Array |
- Ships with
- Divooka Compute
- Graph kinds
- Flows Function Events Routine Constructs StateMachineState
- Declared by
- Hugging Face Hub
- Package
- Machine Learning
Download File
FunctionDownloads one file of a repository into the cache and answers with its path.
Signature
DownloadFile -> Text
repository: Text
fileName: Text
revision: Textstring DownloadFile(
string repository,
string fileName,
string revision)Parameters
| name | type | default | description |
|---|---|---|---|
| repository | Text | — | The repository id. |
| fileName | Text | — | The file's path inside the repository, such as config.json. |
| revision | Text | — | A branch, tag or commit; empty for main. |
Returns
| Path | Text |
- Ships with
- Divooka Compute
- Graph kinds
- Flows Function Events Routine Constructs StateMachineState
- Declared by
- Hugging Face Hub
- Package
- Machine Learning
Download Model
FunctionDownloads a whole repository, or the files of it that match some patterns, into the cache, and answers with its folder. Files already there are not downloaded again.
Signature
DownloadModel -> Text
repository: Text
patterns: Text Array
revision: Textstring DownloadModel(
string repository,
string[] patterns,
string revision)Parameters
| name | type | default | description |
|---|---|---|---|
| repository | Text | — | The repository id, such as HuggingFaceTB/SmolLM2-135M-Instruct. |
| patterns | Text Array | — | File patterns to download, such as *.json or unet/*.safetensors; empty for every file. |
| revision | Text | — | A branch, tag or commit; empty for main. |
Returns
| Folder | Text |
- Ships with
- Divooka Compute
- Graph kinds
- Flows Function Events Routine Constructs StateMachineState
- Declared by
- Hugging Face Hub
- Package
- Machine Learning
Is Downloaded
FunctionWhether a repository has anything in the cache.
Signature
IsDownloaded(repository: Text) -> Truth
bool IsDownloaded(string repository)
Parameters
| name | type | default | description |
|---|---|---|---|
| repository | Text | — | The repository id. |
Returns
| Downloaded | Truth |
- Ships with
- Divooka Compute
- Graph kinds
- Flows Function Events Routine Constructs StateMachineState
- Declared by
- Hugging Face Hub
- Package
- Machine Learning