Expand description
The Hugging Face Hub calls the speaking model’s install makes: the repository’s current revision, its blobs with their LFS digests, and the download of one pinned file.
The token is carried for a gated repository; the speaking model’s own repository is open, so an absent token changes nothing.
Re-exports§
use std::io::Write;🔒use std::path::Path;🔒use std::time::Duration;🔒use serde::Deserialize;🔒use serde::Deserialize;🔒use sha2::Digest;🔒use sha2::Sha256;🔒
Structs§
- Hub
- A Hub client with the optional token every request carries.
- HubBlob
- One file the repository publishes.
- Lfs 🔒
- Model
Info 🔒 - Speaking
Files - The files one speaking variant is made of.
- Tree
Entry 🔒
Constants§
- CONNECT_
TIMEOUT 🔒 - The Hub’s connect and read bounds, a whole-request backstop sized so the largest variant (325 MB at 0.4 Mbps) still finishes, and the page cap on one listing before the install gives up.
- MAX_
TREE_ 🔒PAGES - READ_
TIMEOUT 🔒 - TOTAL_
TIMEOUT 🔒
Functions§
- finish_
file - Check a finished download and move it into place, or remove it.
- next_
page - The next page a
Linkheader names, when it names one. - parse_
blobs - The files a tree listing carries, directories dropped.
- part_
path 🔒 - Where a download is written while it is being checked.
- speaking_
files - The model file and the style files one variant is made of.
- tree_
url - The listing URL for one revision: recursive, because the model and its
voices sit under
onnx/andvoices/. - verify_
release - Refuse a listing whose model file disagrees with the compiled variant.
- voice_
id - The voice id a style file’s path names. Every named voice carries a
<language><gender>_<name>stem; the repository’svoices/af.binblend does not, and is not one of the model’s named voices.