Expand description
Resolve a model reference to fetchable bytes.
hearth aggregates catalogs it does not own: Ollama’s curated few hundred, and HuggingFace’s hundreds of thousands of GGUFs. Neither is the product — the serving is. This crate is the seam between “what a person typed” and “these exact bytes, with this digest”.
Everything here is pure. Reference parsing, layer selection, quantization choice and multi-part detection are all rules, and rules are testable without a network. The HTTP that actually moves bytes lives elsewhere and contains no decisions.
use hearth_resolve::Reference;
assert_eq!(
Reference::parse("llama3").unwrap().key(),
"ollama/library/llama3:latest",
);Re-exports§
pub use plan::available_quants;pub use plan::pick_gguf;pub use plan::plan_from_hf_files;pub use plan::plan_from_ollama_manifest;pub use plan::quant_of;pub use plan::total_parts;pub use plan::Blob;pub use plan::FetchPlan;pub use plan::HfSource;pub use plan::QuantChoice;pub use plan::RepoFile;pub use plan::ResolveError;pub use plan::OLLAMA_MODEL_MEDIA_TYPE;pub use plan::QUANT_PREFERENCE;pub use reference::ParseError;pub use reference::Reference;