Instructions to use batiai/GLM-5.3-Flash-GGUF with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use batiai/GLM-5.3-Flash-GGUF with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf batiai/GLM-5.3-Flash-GGUF:Q4_K_M # Run inference directly in the terminal: llama cli -hf batiai/GLM-5.3-Flash-GGUF:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf batiai/GLM-5.3-Flash-GGUF:Q4_K_M # Run inference directly in the terminal: llama cli -hf batiai/GLM-5.3-Flash-GGUF:Q4_K_M
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf batiai/GLM-5.3-Flash-GGUF:Q4_K_M # Run inference directly in the terminal: ./llama-cli -hf batiai/GLM-5.3-Flash-GGUF:Q4_K_M
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf batiai/GLM-5.3-Flash-GGUF:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama-cli -hf batiai/GLM-5.3-Flash-GGUF:Q4_K_M
Use Docker
docker model run hf.co/batiai/GLM-5.3-Flash-GGUF:Q4_K_M
- LM Studio
- Jan
- vLLM
How to use batiai/GLM-5.3-Flash-GGUF with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "batiai/GLM-5.3-Flash-GGUF" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "batiai/GLM-5.3-Flash-GGUF", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/batiai/GLM-5.3-Flash-GGUF:Q4_K_M
- Ollama
How to use batiai/GLM-5.3-Flash-GGUF with Ollama:
ollama run hf.co/batiai/GLM-5.3-Flash-GGUF:Q4_K_M
- Unsloth Desktop
- Pi
How to use batiai/GLM-5.3-Flash-GGUF with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf batiai/GLM-5.3-Flash-GGUF:Q4_K_M
Configure the model in Pi
# Install Pi: npm install -g @earendil-works/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "batiai/GLM-5.3-Flash-GGUF:Q4_K_M" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Docker Model Runner
How to use batiai/GLM-5.3-Flash-GGUF with Docker Model Runner:
docker model run hf.co/batiai/GLM-5.3-Flash-GGUF:Q4_K_M
- Lemonade
How to use batiai/GLM-5.3-Flash-GGUF with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull batiai/GLM-5.3-Flash-GGUF:Q4_K_M
Run and chat with the model
lemonade run user.GLM-5.3-Flash-GGUF-Q4_K_M
List all available models
lemonade list
- Hermes Agent
How to use batiai/GLM-5.3-Flash-GGUF with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf batiai/GLM-5.3-Flash-GGUF:Q4_K_M
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default batiai/GLM-5.3-Flash-GGUF:Q4_K_M
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use batiai/GLM-5.3-Flash-GGUF with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf batiai/GLM-5.3-Flash-GGUF:Q4_K_M
Configure OpenClaw
# Install OpenClaw: npm install -g openclaw@latest # Register the local server and set it as the default model: openclaw onboard --non-interactive --mode local \ --auth-choice custom-api-key \ --custom-base-url http://127.0.0.1:8080/v1 \ --custom-model-id "batiai/GLM-5.3-Flash-GGUF:Q4_K_M" \ --custom-provider-id llama-cpp \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
- GLM-5.3-Flash GGUF โ Quantized by BatiAI
- โ ๏ธ Read this first โ you need a specific llama.cpp build
- ๐ฆ Sizes and measured speed
- โ
Verified โ every quant, including the lowest
- ๐ง Tool calling works โ but
tool_callswill be empty - ๐งช imatrix โ what it took, and which quants have it
- โ๏ธ License โ MIT, genuinely
- ๐ Usage
- ๐ What is not here
- โจ What BatiAI did differently
- โ ๏ธ Read this first โ you need a specific llama.cpp build
GLM-5.3-Flash GGUF โ Quantized by BatiAI
320B parameters. 18B active. MIT licensed.
Quantized from Z.ai's official weights. Korean output and tool calling verified on every quant โ captured transcripts below, including the tier most likely to break.
โ ๏ธ Read this first โ you need a specific llama.cpp build
glm5next is a new architecture and is not in mainline llama.cpp yet. Stock builds,
Ollama and LM Studio cannot load these files today.
git clone https://github.com/ggml-org/llama.cpp && cd llama.cpp
git fetch origin pull/27752/head:pr27752 && git checkout pr27752
cmake -B build && cmake --build build -j
We will publish Ollama tags once the PR lands in mainline.
๐ฆ Sizes and measured speed
Split into 48 GB shards because Hugging Face caps a single file at 50 GB.
Download every shard of a quant โ llama.cpp opens -00001-of-0000N and finds the rest.
| Quant | Size | Shards | Generation (tg16) |
|---|---|---|---|
Q4_K_M โญ |
175.7 GiB (188.7 GB) | 4 | 7.16 tok/s |
IQ3_XXS |
112.4 GiB (120.7 GB) | 3 | 6.45 tok/s |
IQ2_XXS |
76.6 GiB (82.2 GB) | 2 | 7.50 tok/s |
Q3_K_M |
138.8 GiB (149.1 GB) | 4 | 7.24 tok/s |
Q2_K |
106.3 GiB (114.2 GB) | 3 | 7.66 tok/s |
llama-bench -ngl 0 -n 16 -r 1 on 2ร Intel Xeon Gold 6442Y (48 cores / 96 threads, 503 GB RAM).
CPU only, no GPU offload โ the honest floor, not a best case. On Apple Silicon's unified memory
these go up substantially; we publish those numbers only once measured on the actual hardware.
Why generation speed barely moves across tiers: only ~18B of 320B parameters are active per
token (288 experts, top-8), so at -ngl 0 you are bound by compute on the active slice, not by
reading the whole file. Pick the tier by the RAM you have, not by expected speed.
โ Verified โ every quant, including the lowest
| Quant | Korean | Han / kana | Tool call |
|---|---|---|---|
Q4_K_M |
65.8% Hangul, 263 chars | 0 / 0 | โ |
Q3_K_M |
64.5% Hangul, 276 chars | 0 / 0 | โ |
Q2_K |
63.7% Hangul, 204 chars | 0 / 0 | โ |
IQ3_XXS |
67.2% Hangul, 259 chars | 0 / 0 | โ |
IQ2_XXS |
66.0% Hangul, 97 chars | 0 / 0 | โ (needs 12k budget) |
Captured output (Q4_K_M, temp 0)
**์์ธ**: ์์ธ์ ๋ํ๋ฏผ๊ตญ์ ์๋๋ก, 600๋
์ญ์ฌ๋ฅผ ์ง๋ ๊ณ ๊ถ๊ณผ ์ ํต ํ์ฅ์ด ํ๋์ ์ธ
๋ง์ฒ๋ฃจ์ K์ปฌ์ฒ ์์์ ์ด์ฐ๋ฌ์ง ๋งค๋ ฅ์ ์ธ ๋์์
๋๋ค.
**๊น์น**: ๊น์น๋ ๋ฐฐ์ถ, ๋ฌด ๋ฑ์ ์ฑ์๋ฅผ ๊ณ ์ถง๊ฐ๋ฃจ, ๋ง๋, ์ ๊ฐ๋ก ์๋
ํด ๋ฐํจ์ํจ ํ๊ตญ์
๋ํ ๋ฐํจ ์์์ผ๋ก, ๊ฑด๊ฐ์์ผ๋ก์ ์ ์ธ๊ณ์ ์ผ๋ก ์ฌ๋๋ฐ๊ณ ์์ต๋๋ค.
**๋น๋น๋ฐฅ**: ๋น๋น๋ฐฅ์ ๋ฐ๋ปํ ๋ฐฅ ์์ ๊ฐ์ข
๋๋ฌผ๊ณผ ๊ณ ๊ธฐ, ๊ณ๋์ ์ฌ๋ ค ๊ณ ์ถ์ฅ๊ณผ ํจ๊ป...
[Tool call, raw from /completion]
</think><tool_call>get_weather<arg_key>city</arg_key><arg_value>๋ถ์ฐ</arg_value></tool_call>
Why Q2_K matters here. With no importance matrix (see below), the lowest tier is where damage
would appear first โ and in Korean before English. It did not: 0 Han characters, 0 kana, and a
correct tool call. That is the tier that fits a 128 GB machine, so it is the one we checked hardest.
๐ง Tool calling works โ but tool_calls will be empty
GLM-5.3 emits tool calls in its own XML-ish format, not the JSON that llama.cpp's OpenAI-compatible endpoint knows how to parse:
<tool_call>get_weather<arg_key>city</arg_key><arg_value>๋ถ์ฐ</arg_value></tool_call>
So /v1/chat/completions returns tool_calls: [] even though the model behaved correctly. This is
a parser gap in llama.cpp, not a defect in these files โ we confirmed it by reading raw
/completion output, quoted above.
Until llama.cpp adds the format, parse it yourself from the content:
import re
m = re.search(r"<tool_call>(\w+)((?:<arg_key>\w+</arg_key><arg_value>[^<]*</arg_value>)+)</tool_call>", text)
if m:
name = m.group(1)
args = dict(re.findall(r"<arg_key>(\w+)</arg_key><arg_value>([^<]*)</arg_value>", m.group(2)))
Run the server with --jinja โ without it the model's own chat template is not applied and tool
prompting degrades.
๐งช imatrix โ what it took, and which quants have it
IQ3_XXS and IQ2_XXS are imatrix-quantized. The K-quants (Q4_K_M, Q3_K_M, Q2_K) are not โ they were
built first, before we had a working importance matrix. Here is the honest history, because the
failure is more useful to you than the success.
Our first attempts all died at the same tensor:
collect_imatrix: non-finite values detected in blk.7.attn_v_b.weight
Four configurations on PR #27752: head
8a8d0bc, rebased head 20de496, GPU attention with -ot exps=CPU, and a build with
attn_k_b/attn_v_b pinned to F32. blk.7 is one of the 11 MLA layers (the other 34 are KDA
linear attention). The weights were fine โ we decoded the tensor from the BF16 conversion and got
nan=0, inf=0, absmax=0.104 โ and inference was fine, so the fault was in the graph, not the file.
Re-converting with PR #27754 fixed it. Same
weights, same corpus, no non-finite values. The two PRs also use incompatible metadata schemas
(#27754 wants a per-layer attention.head_count_kv array), so you cannot just swap runtimes on an
existing file โ the conversion has to be redone.
One more practical note: the re-converted BF16 is 584 GiB and our machine has 468 GiB of RAM.
Running imatrix directly on it would re-read the shortfall from disk every chunk โ we measured that
path at roughly 63 hours for 200 chunks. Going through a Q8_0 intermediate (310 GiB, fits in
RAM) brought it down to about four.
Calibration corpus
| Total | 4.90 M characters |
| Hangul | 20.09% |
| Han | 0.17% |
| Code markers | 3,318 |
Korean OCR labels, Korean technical prose, source code, and English wikitext. Run with
--chunks 200.
We report composition as measured numbers because we once wrote "mixed code + English + Korean
- Chinese corpus" on our cards and later measured that corpus at 0.51% Korean. Numbers, not adjectives.
โ๏ธ License โ MIT, genuinely
The base model is MIT. No revenue thresholds, no separate license for assistant products, no gated form. That is unusual at this scale and worth stating: unlike some frontier open-weight releases, you can ship this in a commercial product.
๐ Usage
hf download batiai/GLM-5.3-Flash-GGUF \
--include "GLM-5.3-Flash-Q4_K_M-*" --local-dir ./glm53
./llama-server -m ./glm53/GLM-5.3-Flash-Q4_K_M-00001-of-00004.gguf \
-ngl 0 -c 8192 -b 512 -ub 512 -np 1 --jinja --port 8080
Budget tokens for reasoning. This model always opens with <think> โ its chat template has no
enable_thinking switch, and passing one is silently ignored. A three-sentence Korean answer used
~1,700 characters of reasoning at Q4_K_M before any content appeared. Give max_tokens room or
you will get an empty content and mistake it for a broken quant. We made exactly that mistake and
nearly discarded a good file over it.
IQ2_XXS needs more room than the rest โ use max_tokens 12,000+. At 4,000 it failed our gate
with 0 characters of content and 5,555 of reasoning. We re-ran it and found the model was fine: a
short question ("ํ๊ตญ์ ์๋๋?") answered in 97 characters with 66.0% Hangul and zero Han
characters, and tool calling worked. On the longer prompt it had already written all three
sentences inside its reasoning, then went back to polish them โ 15,822 characters, ending in
"Let me refine:" โ and ran out of budget before emitting anything. Self-revision gets longer at
2 bits. Give it room and it answers.
๐ What is not here
- Vision โ see below.
- Ollama tags โ blocked on PR #27752 landing in mainline.
- Vision โ GLM-5.3-Flash is natively multimodal, but PR #27752 is text-only. We have not converted or verified the vision tower, so we do not ship it.
- Apple Silicon speeds โ we publish only numbers measured on the actual hardware.
โจ What BatiAI did differently
| ๐ฐ๐ท Korean verified per quant | Down to Q2_K, with character counts โ not a claim. |
| ๐ Tool calling actually tested | Including reading raw output when the parser said zero. |
| ๐ Numbers, not adjectives | Sizes, speeds, and the failed imatrix diagnosis are all measured. |
| ๐ง Gaps published | No imatrix, no IQ quants, no vision โ said plainly instead of omitted. |
| ๐ From the source | Quantized from Z.ai's official weights, never a re-quant. Signed general.author: BatiAI. |
Who we are. BatiAI builds on-device Korean AI. BatiFlow runs chat, speech-to-text, document OCR and speaker diarization entirely on a Mac. Full line: huggingface.co/batiai
- Downloads last month
- 1,768
2-bit
3-bit
4-bit
Model tree for batiai/GLM-5.3-Flash-GGUF
Base model
zai-org/GLM-5.3-Flash
Install from pip and serve model
# Install vLLM from pip: pip install vllm# Start the vLLM server: vllm serve "batiai/GLM-5.3-Flash-GGUF"# Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "batiai/GLM-5.3-Flash-GGUF", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'