Expand description
Helpers shared by more than one model’s CLI module.
Enums§
- Dtype
Arg - Shared
--dtypeflag. BF16 is deliberately absent: the in-workspace GGUF reader used by every model’s owninferloader handles F32/F16/Q8_0, so a bf16 file would fail to load back through the same model’sinfercommand. The format-agnosticzsfm convertpath supports BF16 for other consumers.
Functions§
- delete_
cached_ model - Delete a model’s cached files (canonical GGUF + config) and optionally an
output GGUF. Thin wrapper over
zsfm_hub::delete_cached_modelso all CLI modules share one import path (crate::common). - inspect_
tensors - Shared
inspect-tensorsimplementation: print every tensor’s name, shape, and dtype from a local checkpoint file. Format is auto-detected — works whether the model’s raw download is safetensors (most models), a raw PyTorch pickle.ckpt(lag_llama, tirex), or a GGUF file, via the same format-agnostic loaderzsfm convert/zsfm inspectuse. - median_
index - Index of the median (q0.5) quantile level, with center fallback.
- try_
recast_ from_ cache - Return the canonical cache path, recasting from cache when present.