Skip to main content

Module model_import

Module model_import 

Source
Expand description

Shared model construction for the local-file and HuggingFace add paths.

build_new_model is the single place that turns a parsed GGUF file into a NewModel row — naming, parameter count, capability detection, and tag generation all happen here exactly once, regardless of how the model was added.

Structs§

HfOrigin
HuggingFace-specific inputs to ModelOrigin::HuggingFace.

Enums§

ModelOrigin
Provenance-specific inputs for build_new_model.

Constants§

MAX_GENERATION_CONFIG_LOOKUPS
How many repos to ask for a generation_config.json before giving up.

Functions§

build_new_model
Build the NewModel row for a model being added, from either the local-file or HuggingFace path.
fetch_published_sampling
Fetch the model author’s published sampling recipe, if one can be found.
filter_hf_tags 🔒
Filter HuggingFace tags using a blocklist.
merge_tags 🔒
Merge GGUF-derived tags with filtered HF tags, removing duplicates.