Skip to main content

Module weight_format

Module weight_format 

Source
Expand description

Dim 3 polymorphism point — weight-format detection for the executor factory.

Sibling of source::ModelFormat. The difference:

  • source::ModelFormat is a “what kind of files did we just download” hint used for cache classification and progress bars. It carries no path.
  • WeightFormat is a “loader recipe” — it carries the resolved path AND tells the executor factory which WeightLoader<B> to instantiate. New formats (AWQ, EXL2, HQQ, …) plug in by adding a variant + a WeightLoader<B> impl in ferrum-quantization, with no special-casing in LlmExecutorFactory.

Replaces the is_gguf_path short-circuit in ferrum-engine::registry::CandleExecutorFactory with a real polymorphism point matching the 5-dim architecture (see docs/architecture-refactor-status.md).

Enums§

WeightFormat
Resolved weight format + path. Produced by WeightFormat::detect from a user-supplied path (HF cache snapshot, local dir, or a .gguf file).