koute · text · mixture of experts

GLM-4.7-Flash-Derestricted

koute/GLM-4.7-Flash-Derestricted

GLM-4.7-Flash-Derestricted at Q4_K_M is exactly 18,132,722,080 bytes (16.89 GiB / 18.13 GB) — an effective 4.646 bits per weight, not the nominal 4. Its KV cache at 32K is 1.65 GiB.

From the file· summed from 1 file(s)From the file· KV per layer
Parameters
31.2B
total, not active
Architecture
deepseek2
47 layers
Context
202,752
native (config.json)
License
mit

Shipped quantizations

exact bytes, summed from published files
QuantSizeExact bytesEffective bpwTensorsPublisher
I1-IQ1_S5.78 GiB6,201,792,1921.589mradermacher
I1-IQ1_M6.39 GiB6,864,782,0161.759mradermacher
I1-IQ2_XXS7.42 GiB7,969,765,0562.042mradermacher
I1-IQ2_XS8.26 GiB8,869,152,4482.273mradermacher
I1-IQ2_S8.40 GiB9,014,335,1682.310mradermacher
I1-IQ2_M9.22 GiB9,898,321,6002.536mradermacher
I1-Q2_K_S9.53 GiB10,232,122,0482.622mradermacher
Q2_K10.28 GiB11,042,965,9202.830mradermacher
I1-Q2_K10.28 GiB11,042,966,2082.830mradermacher
I1-IQ3_XXS10.85 GiB11,646,142,1442.984mradermacher
I1-IQ3_XS11.50 GiB12,344,307,3923.163mradermacher
Q3_K_S12.14 GiB13,034,401,1843.340mradermacher
I1-IQ3_S12.14 GiB13,034,401,4723.340mradermacher
I1-Q3_K_S12.14 GiB13,034,401,4723.340mradermacher
I1-IQ3_M12.30 GiB13,211,266,7523.385mradermacher
Q3_K_M13.39 GiB14,380,019,1043.685mradermacher
I1-Q3_K_M13.39 GiB14,380,019,3923.685mradermacher
Q3_K_L14.52 GiB15,591,779,7443.995mradermacher
I1-Q3_K_L14.52 GiB15,591,780,0323.995mradermacher
I1-IQ4_XS14.93 GiB16,033,288,8964.108mradermacher
IQ4_XS15.05 GiB16,164,360,6084.142mradermacher
I1-Q4_015.84 GiB17,008,452,2884.358mradermacher
Q4_K_S15.90 GiB17,072,431,5204.375mradermacher
I1-Q4_K_S15.90 GiB17,072,431,8084.375mradermacher
Q4_K_M16.89 GiB18,132,722,0804.646mradermacher
I1-Q4_K_M16.89 GiB18,132,722,3684.646mradermacher
I1-Q4_117.52 GiB18,807,268,0324.819mradermacher
Q5_K_S19.25 GiB20,664,287,6485.295mradermacher
I1-Q5_K_S19.25 GiB20,664,287,9365.295mradermacher
Q5_K_M19.80 GiB21,264,515,4885.449mradermacher
I1-Q5_K_M19.80 GiB21,264,515,7765.449mradermacher
Q6_K22.92 GiB24,614,786,4646.307mradermacher
I1-Q6_K22.92 GiB24,614,786,7526.307mradermacher
Q8_029.66 GiB31,842,800,0328.159mradermacher

KV cache by context

computed per layer
ContextKV cache (f16)Flat formulaOverstated byFull / windowed / recurrent
4,0960.21 GiB3.67 GiB17.78×47 / 0 / 0
8,1920.41 GiB7.34 GiB17.78×47 / 0 / 0
16,3840.83 GiB14.69 GiB17.78×47 / 0 / 0
32,7681.65 GiB29.38 GiB17.78×47 / 0 / 0
65,5363.30 GiB58.75 GiB17.78×47 / 0 / 0
131,0726.61 GiB117.50 GiB17.78×47 / 0 / 0

This model uses multi-head latent attention. No V cache is allocated at all, and the K cache stores a 512-wide latent plus 64 rope dimensions — so reading num_key_value_heads from config.json and multiplying, as every calculator does, overstates the cache by well over an order of magnitude.

Compare with

same modality, comparable size

Will it run on your card?

full quant x context sweep

Why other calculators give a different number

A parameters × bits ÷ 8 estimate puts Q4_K_M at roughly 16.36 GiB. The real file is 16.89 GiB, because a quantization is a mixture and some tensors are always kept at higher precision. The larger discrepancy is the cache: this model allocates no value cache at all, so any formula reading num_key_value_heads overstates it by more than an order of magnitude.

Architecture

from config.json
Layers
47
Attention heads
20
KV heads
20
Head dim
256
Hidden size
2048
Vocab
154,880
Sliding window
none
SWA period
MLA
yes
Experts
64
Experts per token
4
use_sliding_window

Questions people ask

How much VRAM does GLM-4.7-Flash-Derestricted need?
Q4_K_M is exactly 18,132,722,080 bytes (16.89 GiB) in weights. Add the KV cache, which depends on your context length, plus roughly half a gigabyte of runtime overhead.
How large is GLM-4.7-Flash-Derestricted's KV cache?
1.65 GiB at 32K context with an f16 cache, computed per layer. Quantizing the cache to q8_0 roughly halves it, which is often the difference between a context length fitting and not.
Is GLM-4.7-Flash-Derestricted a mixture-of-experts model?
Yes — 64 experts, 4 routed per token. Every expert must be resident, but only the routed ones are read per token, which is why its memory requirement and its speed behave very differently.
Which quantization of GLM-4.7-Flash-Derestricted should I use?
Q4_K_M is the usual default. Pick the largest quantization that fits your card at the context you actually need — the table above gives exact sizes for every one published.