GLM 5.1

753.9B total, 51.7B active · 198k context · MIT · released 2026-04-03

agenticcodingreasoningchat

In short

GLM 5.1 is an open model from Z.ai with 753.9B parameters (51.7B active per token). At MXFP4, GLM 5.1 needs about 421 GB of memory at 8k context and 424 GB at 32k, counting the weights, the KV cache and runtime buffers. Nothing we price in the UK runs GLM 5.1 fully in memory at 32k context at a usable speed; see the table for what comes closest.

Updated . Speeds are estimates; how they are worked out.

What to run it on in the UK

Fully in memory at 32k context, priced at retailers today.

Nothing we price holds this model fully in memory.

All hardware that runs it

Everything we price, best value first. Two cards split the model by layers.

Nothing we price can run it at this context.

Memory needed

Weights, KV cache and runtime buffers at each context length (KV cache at fp16).

QuantFile@8k@32k@64k@128k
MXFP4gguf419.9 GB421.4 GB423.6 GB426.5 GB432.4 GB
UD-Q4_K_Mgguf432.6 GB434.0 GB436.2 GB439.2 GB445.0 GB
UD-Q5_K_Mgguf520.1 GB521.5 GB523.7 GB526.7 GB532.5 GB
UD-Q6_Kgguf578.7 GB580.1 GB582.3 GB585.2 GB591.1 GB
Q8_0gguf746.3 GB747.7 GB749.9 GB752.9 GB758.7 GB

Run it

Copy a command for the runtime you use.

  • MXFP4
    • Ollamaollama run hf.co/unsloth/GLM-5.1-GGUF:MXFP4
    • LM Studiolms get unsloth/GLM-5.1-GGUF@mxfp4
    • llama.cppllama-server -hf unsloth/GLM-5.1-GGUF:MXFP4
  • UD-Q4_K_M
    • Ollamaollama run hf.co/unsloth/GLM-5.1-GGUF:UD-Q4_K_M
    • LM Studiolms get unsloth/GLM-5.1-GGUF@ud-q4_k_m
    • llama.cppllama-server -hf unsloth/GLM-5.1-GGUF:UD-Q4_K_M
  • UD-Q5_K_M
    • Ollamaollama run hf.co/unsloth/GLM-5.1-GGUF:UD-Q5_K_M
    • LM Studiolms get unsloth/GLM-5.1-GGUF@ud-q5_k_m
    • llama.cppllama-server -hf unsloth/GLM-5.1-GGUF:UD-Q5_K_M
  • UD-Q6_K
    • Ollamaollama run hf.co/unsloth/GLM-5.1-GGUF:UD-Q6_K
    • LM Studiolms get unsloth/GLM-5.1-GGUF@ud-q6_k
    • llama.cppllama-server -hf unsloth/GLM-5.1-GGUF:UD-Q6_K
  • Q8_0
    • Ollamaollama run hf.co/unsloth/GLM-5.1-GGUF:Q8_0
    • LM Studiolms get unsloth/GLM-5.1-GGUF@q8_0
    • llama.cppllama-server -hf unsloth/GLM-5.1-GGUF:Q8_0

Notes

Local serving requires SGLang v0.5.10+, vLLM v0.19.0+, xLLM v0.8.0+, or KTransformers v0.5.3+. Positioned as a flagship model for long-horizon agentic engineering; the card does not state a context length. Sparse or compressed attention: KV read per token is estimated as full attention.

Questions

How much VRAM does GLM 5.1 need?
At MXFP4, GLM 5.1 needs about 421 GB of memory at 8k context and 424 GB at 32k, counting the weights, the KV cache and runtime buffers.
Can I run GLM 5.1 on a 16 GB GPU?
No: it does not fit in 16 GB at 32k context, even with system RAM.
Can I run GLM 5.1 on a 24 GB GPU?
No: it does not fit in 24 GB at 32k context, even with system RAM.
How do I run GLM 5.1 locally?
With Ollama: ollama run hf.co/unsloth/GLM-5.1-GGUF:MXFP4 (the MXFP4 build). LM Studio and llama.cpp commands are on this page.
What licence is GLM 5.1 released under?
MIT, which allows commercial use.