{ "format": "bitnest-package-v1", "model": "llama3.2_3b", "arch": "llama", "source_model": "meta-llama/Llama-3.2-3B", "rotation": "R.bin", "group_size": 128, "pack": "unsigned+8", "weight_planes": { "hi": "GPTQ-W4 码 q4∈[-8,7] 存 u=q4+8", "lo": "有符号残差 qr∈[-8,7] (q4=-8 时 ∈[0,7]) 存 u=qr+8", "byte_layout": "uint8 [N, K/2]: 字节 j 的低 4 位 = 列 2j, 高 4 位 = 列 2j+1", "draft": "W4 = (hi-8) * scale (scale 为 fp16 [N,K/128] 组尺度, 沿 K 每 128 列一组)", "target": "W8 = (16*(hi-8) + (lo-8)) * scale/16", "int8_code": "q8 = 16*q4 + qr ∈ [-128,119]" }, "activation": { "scheme": "对称 int8, clip 1.0, 逐 token (amax/127); o_proj 输入按 head_dim=128 分组逐 token", "per_layer_group": { "model.layers.0.self_attn.q_proj": -1, "model.layers.0.self_attn.k_proj": -1, "model.layers.0.self_attn.v_proj": -1, "model.layers.0.self_attn.o_proj": 128, "model.layers.0.mlp.gate_proj": -1, "model.layers.0.mlp.up_proj": -1, "model.layers.0.mlp.down_proj": -1, "model.layers.1.self_attn.q_proj": -1, "model.layers.1.self_attn.k_proj": -1, "model.layers.1.self_attn.v_proj": -1, "model.layers.1.self_attn.o_proj": 128, "model.layers.1.mlp.gate_proj": -1, "model.layers.1.mlp.up_proj": -1, "model.layers.1.mlp.down_proj": -1, "model.layers.2.self_attn.q_proj": -1, "model.layers.2.self_attn.k_proj": -1, "model.layers.2.self_attn.v_proj": -1, "model.layers.2.self_attn.o_proj": 128, "model.layers.2.mlp.gate_proj": -1, "model.layers.2.mlp.up_proj": -1, "model.layers.2.mlp.down_proj": -1, "model.layers.3.self_attn.q_proj": -1, "model.layers.3.self_attn.k_proj": -1, "model.layers.3.self_attn.v_proj": -1, "model.layers.3.self_attn.o_proj": 128, "model.layers.3.mlp.gate_proj": -1, "model.layers.3.mlp.up_proj": -1, "model.layers.3.mlp.down_proj": -1, "model.layers.4.self_attn.q_proj": -1, "model.layers.4.self_attn.k_proj": -1, "model.layers.4.self_attn.v_proj": -1, "model.layers.4.self_attn.o_proj": 128, "model.layers.4.mlp.gate_proj": -1, "model.layers.4.mlp.up_proj": -1, "model.layers.4.mlp.down_proj": -1, "model.layers.5.self_attn.q_proj": -1, "model.layers.5.self_attn.k_proj": -1, "model.layers.5.self_attn.v_proj": -1, "model.layers.5.self_attn.o_proj": 128, "model.layers.5.mlp.gate_proj": -1, "model.layers.5.mlp.up_proj": -1, "model.layers.5.mlp.down_proj": -1, "model.layers.6.self_attn.q_proj": -1, "model.layers.6.self_attn.k_proj": -1, "model.layers.6.self_attn.v_proj": -1, "model.layers.6.self_attn.o_proj": 128, "model.layers.6.mlp.gate_proj": -1, "model.layers.6.mlp.up_proj": -1, "model.layers.6.mlp.down_proj": -1, "model.layers.7.self_attn.q_proj": -1, "model.layers.7.self_attn.k_proj": -1, "model.layers.7.self_attn.v_proj": -1, "model.layers.7.self_attn.o_proj": 128, "model.layers.7.mlp.gate_proj": -1, "model.layers.7.mlp.up_proj": -1, "model.layers.7.mlp.down_proj": -1, "model.layers.8.self_attn.q_proj": -1, "model.layers.8.self_attn.k_proj": -1, "model.layers.8.self_attn.v_proj": -1, "model.layers.8.self_attn.o_proj": 128, "model.layers.8.mlp.gate_proj": -1, "model.layers.8.mlp.up_proj": -1, "model.layers.8.mlp.down_proj": -1, "model.layers.9.self_attn.q_proj": -1, "model.layers.9.self_attn.k_proj": -1, "model.layers.9.self_attn.v_proj": -1, "model.layers.9.self_attn.o_proj": 128, "model.layers.9.mlp.gate_proj": -1, "model.layers.9.mlp.up_proj": -1, "model.layers.9.mlp.down_proj": -1, "model.layers.10.self_attn.q_proj": -1, "model.layers.10.self_attn.k_proj": -1, "model.layers.10.self_attn.v_proj": -1, "model.layers.10.self_attn.o_proj": 128, "model.layers.10.mlp.gate_proj": -1, "model.layers.10.mlp.up_proj": -1, "model.layers.10.mlp.down_proj": -1, "model.layers.11.self_attn.q_proj": -1, "model.layers.11.self_attn.k_proj": -1, "model.layers.11.self_attn.v_proj": -1, "model.layers.11.self_attn.o_proj": 128, "model.layers.11.mlp.gate_proj": -1, "model.layers.11.mlp.up_proj": -1, "model.layers.11.mlp.down_proj": -1, "model.layers.12.self_attn.q_proj": -1, "model.layers.12.self_attn.k_proj": -1, "model.layers.12.self_attn.v_proj": -1, "model.layers.12.self_attn.o_proj": 128, "model.layers.12.mlp.gate_proj": -1, "model.layers.12.mlp.up_proj": -1, "model.layers.12.mlp.down_proj": -1, "model.layers.13.self_attn.q_proj": -1, "model.layers.13.self_attn.k_proj": -1, "model.layers.13.self_attn.v_proj": -1, "model.layers.13.self_attn.o_proj": 128, "model.layers.13.mlp.gate_proj": -1, "model.layers.13.mlp.up_proj": -1, "model.layers.13.mlp.down_proj": -1, "model.layers.14.self_attn.q_proj": -1, "model.layers.14.self_attn.k_proj": -1, "model.layers.14.self_attn.v_proj": -1, "model.layers.14.self_attn.o_proj": 128, "model.layers.14.mlp.gate_proj": -1, "model.layers.14.mlp.up_proj": -1, "model.layers.14.mlp.down_proj": -1, "model.layers.15.self_attn.q_proj": -1, "model.layers.15.self_attn.k_proj": -1, "model.layers.15.self_attn.v_proj": -1, "model.layers.15.self_attn.o_proj": 128, "model.layers.15.mlp.gate_proj": -1, "model.layers.15.mlp.up_proj": -1, "model.layers.15.mlp.down_proj": -1, "model.layers.16.self_attn.q_proj": -1, "model.layers.16.self_attn.k_proj": -1, "model.layers.16.self_attn.v_proj": -1, "model.layers.16.self_attn.o_proj": 128, "model.layers.16.mlp.gate_proj": -1, "model.layers.16.mlp.up_proj": -1, "model.layers.16.mlp.down_proj": -1, "model.layers.17.self_attn.q_proj": -1, "model.layers.17.self_attn.k_proj": -1, "model.layers.17.self_attn.v_proj": -1, "model.layers.17.self_attn.o_proj": 128, "model.layers.17.mlp.gate_proj": -1, "model.layers.17.mlp.up_proj": -1, "model.layers.17.mlp.down_proj": -1, "model.layers.18.self_attn.q_proj": -1, "model.layers.18.self_attn.k_proj": -1, "model.layers.18.self_attn.v_proj": -1, "model.layers.18.self_attn.o_proj": 128, "model.layers.18.mlp.gate_proj": -1, "model.layers.18.mlp.up_proj": -1, "model.layers.18.mlp.down_proj": -1, "model.layers.19.self_attn.q_proj": -1, "model.layers.19.self_attn.k_proj": -1, "model.layers.19.self_attn.v_proj": -1, "model.layers.19.self_attn.o_proj": 128, "model.layers.19.mlp.gate_proj": -1, "model.layers.19.mlp.up_proj": -1, "model.layers.19.mlp.down_proj": -1, "model.layers.20.self_attn.q_proj": -1, "model.layers.20.self_attn.k_proj": -1, "model.layers.20.self_attn.v_proj": -1, "model.layers.20.self_attn.o_proj": 128, "model.layers.20.mlp.gate_proj": -1, "model.layers.20.mlp.up_proj": -1, "model.layers.20.mlp.down_proj": -1, "model.layers.21.self_attn.q_proj": -1, "model.layers.21.self_attn.k_proj": -1, "model.layers.21.self_attn.v_proj": -1, "model.layers.21.self_attn.o_proj": 128, "model.layers.21.mlp.gate_proj": -1, "model.layers.21.mlp.up_proj": -1, "model.layers.21.mlp.down_proj": -1, "model.layers.22.self_attn.q_proj": -1, "model.layers.22.self_attn.k_proj": -1, "model.layers.22.self_attn.v_proj": -1, "model.layers.22.self_attn.o_proj": 128, "model.layers.22.mlp.gate_proj": -1, "model.layers.22.mlp.up_proj": -1, "model.layers.22.mlp.down_proj": -1, "model.layers.23.self_attn.q_proj": -1, "model.layers.23.self_attn.k_proj": -1, "model.layers.23.self_attn.v_proj": -1, "model.layers.23.self_attn.o_proj": 128, "model.layers.23.mlp.gate_proj": -1, "model.layers.23.mlp.up_proj": -1, "model.layers.23.mlp.down_proj": -1, "model.layers.24.self_attn.q_proj": -1, "model.layers.24.self_attn.k_proj": -1, "model.layers.24.self_attn.v_proj": -1, "model.layers.24.self_attn.o_proj": 128, "model.layers.24.mlp.gate_proj": -1, "model.layers.24.mlp.up_proj": -1, "model.layers.24.mlp.down_proj": -1, "model.layers.25.self_attn.q_proj": -1, "model.layers.25.self_attn.k_proj": -1, "model.layers.25.self_attn.v_proj": -1, "model.layers.25.self_attn.o_proj": 128, "model.layers.25.mlp.gate_proj": -1, "model.layers.25.mlp.up_proj": -1, "model.layers.25.mlp.down_proj": -1, "model.layers.26.self_attn.q_proj": -1, "model.layers.26.self_attn.k_proj": -1, "model.layers.26.self_attn.v_proj": -1, "model.layers.26.self_attn.o_proj": 128, "model.layers.26.mlp.gate_proj": -1, "model.layers.26.mlp.up_proj": -1, "model.layers.26.mlp.down_proj": -1, "model.layers.27.self_attn.q_proj": -1, "model.layers.27.self_attn.k_proj": -1, "model.layers.27.self_attn.v_proj": -1, "model.layers.27.self_attn.o_proj": 128, "model.layers.27.mlp.gate_proj": -1, "model.layers.27.mlp.up_proj": -1, "model.layers.27.mlp.down_proj": -1 } }, "online_hadamard": { "note": "R4: down_proj 输入先做分块 Hadamard (K×2^k 结构, hadK 见 aux.had_K., 归一化 1/sqrt(dim)); R1/R2 已离线融合进权重/embed/lm_head", "layers": { "model.layers.0.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.1.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.2.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.3.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.4.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.5.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.6.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.7.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.8.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.9.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.10.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.11.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.12.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.13.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.14.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.15.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.16.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.17.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.18.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.19.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.20.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.21.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.22.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.23.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.24.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.25.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.26.mlp.down_proj": { "K": 1, "fp32": false }, "model.layers.27.mlp.down_proj": { "K": 1, "fp32": false } } }, "norms": { "fused": true, "decoder_norms_identity": true, "note": "RMSNorm 权重已融合进相邻 Linear (fuse_layer_norms), 层内 norm 权重 = 1; 终 norm 融进 lm_head, final_norm 亦保存" }, "kv": { "nesting": "K/V 写入 cache 时 per-token 尺度 s=max|x|/7, q4=clip(round(x/s)), qr=clip(round((x-q4 s)/(s/16))); draft 读 q4 (KV4), target 读 16q4+qr (KV8)", "per_channel_offset": "无 bias, 不需要偏移", "r3": "可选: K/Q 写入/查询前做 per-head 归一化 Hadamard (Qwen 建议开)" }, "rope": { "theta": 500000.0, "scaling": { "factor": 32.0, "high_freq_factor": 4.0, "low_freq_factor": 1.0, "original_max_position_embeddings": 8192, "rope_type": "llama3" }, "max_position_embeddings": 131072 }, "layers": { "model.layers.0.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.0.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.0.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.0.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.0.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.0.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.0.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.1.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.1.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.1.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.1.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.1.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.1.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.1.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.2.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.2.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.2.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.2.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.2.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.2.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.2.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.3.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.3.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.3.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.3.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.3.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.3.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.3.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.4.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.4.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.4.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.4.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.4.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.4.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.4.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.5.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.5.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.5.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.5.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.5.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.5.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.5.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.6.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.6.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.6.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.6.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.6.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.6.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.6.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.7.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.7.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.7.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.7.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.7.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.7.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.7.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.8.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.8.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.8.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.8.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.8.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.8.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.8.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.9.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.9.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.9.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.9.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.9.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.9.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.9.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.10.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.10.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.10.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.10.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.10.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.10.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.10.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.11.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.11.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.11.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.11.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.11.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.11.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.11.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.12.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.12.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.12.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.12.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.12.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.12.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.12.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.13.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.13.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.13.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.13.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.13.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.13.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.13.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.14.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.14.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.14.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.14.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.14.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.14.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.14.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.15.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.15.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.15.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.15.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.15.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.15.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.15.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.16.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.16.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.16.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.16.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.16.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.16.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.16.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.17.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.17.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.17.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.17.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.17.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.17.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.17.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.18.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.18.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.18.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.18.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.18.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.18.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.18.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.19.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.19.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.19.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.19.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.19.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.19.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.19.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.20.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.20.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.20.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.20.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.20.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.20.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.20.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.21.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.21.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.21.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.21.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.21.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.21.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.21.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.22.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.22.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.22.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.22.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.22.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.22.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.22.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.23.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.23.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.23.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.23.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.23.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.23.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.23.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.24.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.24.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.24.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.24.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.24.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.24.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.24.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.25.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.25.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.25.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.25.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.25.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.25.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.25.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.26.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.26.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.26.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.26.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.26.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.26.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.26.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "model.layers.27.self_attn.q_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.27.self_attn.k_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.27.self_attn.v_proj": { "shape": [ 1024, 3072 ], "groups": 24, "has_bias": false }, "model.layers.27.self_attn.o_proj": { "shape": [ 3072, 3072 ], "groups": 24, "has_bias": false }, "model.layers.27.mlp.gate_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.27.mlp.up_proj": { "shape": [ 8192, 3072 ], "groups": 24, "has_bias": false }, "model.layers.27.mlp.down_proj": { "shape": [ 3072, 8192 ], "groups": 64, "has_bias": false }, "lm_head": { "shape": [ 128256, 3072 ], "groups": 24, "has_bias": false } }, "embed_note": "embed_tokens 为 8-bit RTN 反量化后的 bf16 (与 GPU runner 一致), 已含 R1 旋转", "reference": { "loader": "bitnest/reference_model.py (pure PyTorch dequantizing loader, runs on CPU)", "gpu_runner": "bitnest/generate.py" }, "lm_head_note": "lm_head 为 RTN 双平面 (W4 高位 + 残差, gs128, 无 GPTQ): draft 读 W4 / target 读 W8, 激活逐 token A8; 残差饱和率 3.1026%, W8 最大相对误差 8.45e-03, W4 相对 F 范数误差 0.117; 已含 R1 旋转与终 norm 融合" }