GLM-4.7 Flash (30B-A3B MoE)

MoE · 3B active

30B mixture of experts model with about 3B active parameters and a 200K context window.

Z.ai·31.2B params·47 layers / 20 KV heads·Max 198K ctx·MIT
Local Run Command
Q4_K_M minimum memory: 20.1 GB at 16K context.
Artificial Analysis Benchmarkartificialanalysis.ai ↗
Intelligence Index
—
Cloud API median
135 tok/s

Independent benchmark scores sourced from Artificial Analysis.

OpenRouter API & Cloud GPUOpenRouter ↗
Input / 1M
$0.06
Output / 1M
$0.40

VRAM by Quantization (16K context)

Q4_K_M (4-bit)17.7 GB
real file size
0.8 GB20.1 GB19.7 GBBest speed-to-quality balance for local inference (~98% quality)
ollama run glm-4.7-flash
Q6_K (6-bit)23.0 GB
estimate
0.8 GB25.6 GB25.2 GBNear-lossless quality with ~35% larger footprint than Q4
Q8_0 (8-bit)29.7 GB
estimate
0.8 GB32.6 GB32.1 GBVirtually indistinguishable from FP16 for coding & reasoning
FP16 / BF16 (16-bit)55.8 GB
estimate
0.8 GB59.9 GB59.5 GBFull native precision; standard for production GPU serving

Layer and head counts are read from the published config.json. KV cache is an approximation for this architecture: multi-head latent attention: assumes the runtime caches the compressed latents.

Run GLM-4.7 Flash (30B-A3B MoE) with Ollama, LM Studio, llama.cpp, MLX or vLLM

Command
Ollama
Q4_K_M
glm-4.7-flash
17.7 GB
real file size
LM Studio
Q4_K_M
unsloth/GLM-4.7-Flash-GGUF
17.1 GB
real file size
llama.cpp
Q4_K_M
unsloth/GLM-4.7-Flash-GGUF
17.1 GB
real file size
MLX
4-bit
mlx-community/GLM-4.7-Flash-4bit
15.7 GB
real file size
vLLM
INT4
18.9 GB
estimate
No INT4 build of this model found for vLLM.

Each runtime loads its own build of the model, so download sizes differ. Sizes marked as real are file sizes read from the Ollama registry or Hugging Face.

Hardware Compatibility Matrix (Q4_K_M · 16K context)

Details
11.5 GBToo large——GLM-4.7 Flash (30B-A3B MoE) on M1 16GB →
48.0 GBFits comfortably54–90 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M1 Max 64GB →
98.0 GBFits comfortably61–128 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M1 Ultra 128GB →
18.0 GBPartial offload8.2–19.2 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M2 24GB →
48.0 GBFits comfortably51–106 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M2 Max 64GB →
152 GBFits comfortably89–148 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M2 Ultra 192GB →
27.0 GBFits comfortably25–52 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M3 Pro 36GB →
48.0 GBFits comfortably51–106 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M3 Max 64GB →
98.0 GBFits comfortably51–106 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M3 Max 128GB →
11.5 GBToo large——GLM-4.7 Flash (30B-A3B MoE) on M4 16GB →
24.0 GBFits comfortably20–42 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M4 32GB →
36.0 GBFits comfortably40–82 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M4 Pro 48GB →
48.0 GBFits comfortably40–82 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M4 Pro 64GB →
48.0 GBFits comfortably61–127 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M4 Max 64GB →
98.0 GBFits comfortably61–127 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M4 Max 128GB →
98.0 GBFits comfortably61–127 tok/s—GLM-4.7 Flash (30B-A3B MoE) on Studio M4 Max 128GB →
204 GBFits comfortably84–140 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M3 Ultra 256GB →
430 GBFits comfortably84–140 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M3 Ultra 512GB →
24.0 GBFits comfortably33–54 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M1 Pro 32GB →
24.0 GBFits comfortably32–65 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M2 Pro 32GB →
27.0 GBFits comfortably42–88 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M3 Max 36GB →
11.5 GBToo large——GLM-4.7 Flash (30B-A3B MoE) on Air M4 16GB →
24.0 GBFits comfortably20–42 tok/s—GLM-4.7 Flash (30B-A3B MoE) on Air M4 32GB →
18.0 GBPartial offload18.3–43 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M4 Pro 24GB →
11.5 GBToo large——GLM-4.7 Flash (30B-A3B MoE) on Air M5 16GB →
24.0 GBFits comfortably26–53 tok/s—GLM-4.7 Flash (30B-A3B MoE) on Air M5 32GB →
48.0 GBFits comfortably43–89 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M5 Pro 64GB →
98.0 GBFits comfortably65–136 tok/s—GLM-4.7 Flash (30B-A3B MoE) on M5 Max 128GB →
24.0 GBFits comfortably28–58 tok/s—GLM-4.7 Flash (30B-A3B MoE) on mini M6 32GB →
48.0 GBFits comfortably43–89 tok/s—GLM-4.7 Flash (30B-A3B MoE) on mini M5 Pro 64GB →
98.0 GBFits comfortably65–136 tok/s—GLM-4.7 Flash (30B-A3B MoE) on Studio M5 Max 128GB →
430 GBFits comfortably88–183 tok/s—GLM-4.7 Flash (30B-A3B MoE) on Studio M5 Ultra 512GB →
11.2 GBToo large—2×GLM-4.7 Flash (30B-A3B MoE) on RTX 3060 12GB →
9.2 GBToo large—3×GLM-4.7 Flash (30B-A3B MoE) on RTX 3080 10GB →
22.8 GBTight fit114–191 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on RTX 3090 24GB →
15.0 GBToo large—2×GLM-4.7 Flash (30B-A3B MoE) on RTX 4060 Ti 16GB →
15.0 GBToo large—2×GLM-4.7 Flash (30B-A3B MoE) on RTX 4070 Ti S 16GB →
15.0 GBToo large—2×GLM-4.7 Flash (30B-A3B MoE) on RTX 4080 S 16GB →
22.8 GBTight fit159–265 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on RTX 4090 24GB →
15.0 GBToo large—2×GLM-4.7 Flash (30B-A3B MoE) on RTX 5070 Ti 16GB →
15.0 GBToo large—2×GLM-4.7 Flash (30B-A3B MoE) on RTX 5080 16GB →
30.5 GBFits comfortably210–350 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on RTX 5090 32GB →
22.8 GBTight fit124–258 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on RX 7900 XTX 24GB →
15.0 GBToo large—2×GLM-4.7 Flash (30B-A3B MoE) on RX 9070 XT 16GB →
10.2 GBToo large—3×GLM-4.7 Flash (30B-A3B MoE) on RTX 2080 Ti 11GB →
7.3 GBToo large—3×GLM-4.7 Flash (30B-A3B MoE) on RTX 3060 Ti 8GB →
7.3 GBToo large—3×GLM-4.7 Flash (30B-A3B MoE) on RTX 3070 8GB →
11.2 GBToo large—2×GLM-4.7 Flash (30B-A3B MoE) on RTX 3080 Ti 12GB →
22.8 GBTight fit131–273 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on RTX 3090 Ti 24GB →
7.3 GBToo large—3×GLM-4.7 Flash (30B-A3B MoE) on RTX 4060 8GB →
7.3 GBToo large—3×GLM-4.7 Flash (30B-A3B MoE) on RTX 4060 Ti 8GB →
11.2 GBToo large—2×GLM-4.7 Flash (30B-A3B MoE) on RTX 4070 12GB →
11.2 GBToo large—2×GLM-4.7 Flash (30B-A3B MoE) on RTX 4070 S 12GB →
11.2 GBToo large—2×GLM-4.7 Flash (30B-A3B MoE) on RTX 4070 Ti 12GB →
15.0 GBToo large—2×GLM-4.7 Flash (30B-A3B MoE) on RTX 4080 16GB →
15.0 GBToo large—2×GLM-4.7 Flash (30B-A3B MoE) on RTX 5060 Ti 16GB →
11.2 GBToo large—2×GLM-4.7 Flash (30B-A3B MoE) on RTX 5070 12GB →
15.0 GBToo large—2×GLM-4.7 Flash (30B-A3B MoE) on RX 7800 XT 16GB →
18.9 GBPartial offload12.0 tok/s2×GLM-4.7 Flash (30B-A3B MoE) on RX 7900 XT 20GB →
15.0 GBToo large—2×GLM-4.7 Flash (30B-A3B MoE) on RX 9070 16GB →
15.0 GBToo large—2×GLM-4.7 Flash (30B-A3B MoE) on RX 9060 XT 16GB →
46.2 GBFits comfortably121–251 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on RTX A6000 48GB →
46.2 GBFits comfortably135–281 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on RTX 6000 Ada 48GB →
93.0 GBFits comfortably229–381 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on PRO 6000 96GB →
15.0 GBToo large—2×GLM-4.7 Flash (30B-A3B MoE) on RTX A4000 16GB →
22.8 GBTight fit111–231 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on RTX A5000 24GB →
18.9 GBPartial offload12.0 tok/s2×GLM-4.7 Flash (30B-A3B MoE) on RTX 4000 Ada 20GB →
30.5 GBFits comfortably103–213 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on RTX 5000 Ada 32GB →
46.2 GBFits comfortably157–325 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on PRO 5000 48GB →
46.2 GBFits comfortably104–217 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on PRO W7900 48GB →
30.5 GBFits comfortably101–209 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on AI PRO R9700 32GB →
22.8 GBTight fit63–130 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on L4 24GB →
46.2 GBFits comfortably128–267 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on L40S 48GB →
38.5 GBFits comfortably166–344 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on A100 40GB →
77.5 GBFits comfortably156–324 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on A100 80GB →
77.5 GBFits comfortably180–375 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on H100 80GB →
137 GBFits comfortably219–455 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on H200 141GB →
175 GBFits comfortably234–485 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on B200 180GB →
15.0 GBToo large—2×GLM-4.7 Flash (30B-A3B MoE) on T4 16GB →
46.2 GBFits comfortably106–221 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on A40 48GB →
46.2 GBFits comfortably128–267 tok/s1×GLM-4.7 Flash (30B-A3B MoE) on L40 48GB →
115 GBFits comfortably55–114 tok/s—GLM-4.7 Flash (30B-A3B MoE) on DGX Spark 128GB →
96.0 GBFits comfortably48–99 tok/s—GLM-4.7 Flash (30B-A3B MoE) on Ryzen AI Max+ 395 128GB →
48.0 GBFits comfortably48–99 tok/s—GLM-4.7 Flash (30B-A3B MoE) on Ryzen AI Max+ 395 64GB →

Frequently asked questions

How much VRAM does GLM-4.7 Flash (30B-A3B MoE) require?

At Q4_K_M quantization with a 16K context window, GLM-4.7 Flash (30B-A3B MoE) needs 20.1 GB total VRAM (17.7 GB weights + 0.8 GB KV cache + runtime overhead). In full FP16 precision, it requires 59.9 GB.

Can an RTX 4090 (24 GB) run GLM-4.7 Flash (30B-A3B MoE)?

Yes. At Q4_K_M with 16K context GLM-4.7 Flash (30B-A3B MoE) needs 20.1 GB, which fits a single 24 GB RTX 4090 at an estimated 159–265 tok/s.

How do I run GLM-4.7 Flash (30B-A3B MoE) locally with Ollama?

Install Ollama and run `ollama run glm-4.7-flash` in your terminal. Make sure your GPU or Apple Silicon unified memory meets the 20.1 GB Q4_K_M requirement.