Module glm5_next_mtp

Module glm5_next_mtp 

Source
Expand description

2026-09-25: Load GLM-5.3’s MTP block, model.language_model.layers.{num_hidden_layers}, as the body of the draft proposer.

Owner: model-arch weight loader (GLM-5.3). Invariants:

  • The block is one DSA mixer and one routed MoE with mhc: None, the plain-residual path of crate::glm5next_layer::Glm5NextLayer.
  • Its DSA layer uses attn_layer_idx = 0 of the drafter’s own one-layer KV pool (glm5next_mtp_head), never the target’s.
  • Glm5NextWeightLoader::prune_after_load keeps this layer’s tensors: is_reuploaded matches only layer indices below num_hidden_layers.

Structs§

Glm5NextMtpModule
2026-09-25: The MTP block plus the four tensors around it.

Functions§

load_glm5next_mtp_module
2026-09-25: Build the MTP block, or None when the checkpoint has no layers.{num_hidden_layers}.