Expand description
Canonical tensor identities and the preserved FFN precision selection policy.
Structs§
- Tensor
Role - A resolved tensor identity: an engine role + its layer (
P64_LAYER_GLOBALfor non-layer tensors).
Functions§
- canonical_
suffix - Canonical GGUF suffix for a tensor role. Loaders use this to normalize
model-family names before the live prefill path resolves
LayerTensors. - name_
is_ ternary_ eligible - True iff this tensor name resolves to an FFN projection (so it is ternary-eligible). A name we cannot classify is not ternarised (fail safe to high fidelity).
- name_
to_ role - Map a tensor name (GGUF or HF convention) to its engine role + layer, or
Noneif unrecognised. - ternary_
eligible - The §A ternary policy: only the FFN projection weights (
gate/up/down) are eligible for BitNet-1.58b ternary packing. Attention projections, norms, and embeddings stay at higher fidelity — ternarising them destroys coherence.