transformer_lens.model_bridge.supported_architectures.glm module¶
GLM architecture adapter.
Z.ai’s dense GLM-4 family (GlmForCausalLM: glm-4-9b-*-hf, glm-edge):
llama-shaped GQA decoder with GLM’s adjacent-pair interleaved RoPE at a
partial rotary factor, attention biases, and a Phi3-style combined
gate_up_proj MLP.
- class transformer_lens.model_bridge.supported_architectures.glm.GlmArchitectureAdapter(cfg: Any)¶
Bases:
ArchitectureAdapterArchitecture adapter for GlmForCausalLM models.
- __init__(cfg: Any) None¶
Initialize the GLM architecture adapter.