Skip to content

Checking your reading list…

Retry

Stay curious. Build better.

Appearance

Choose how BestHub looks on this device.

Changes apply immediately.

Search articles

Open Discover with these filters

Suggested searches

Hy4 Flash Quantized: 410GiB→125GiB, 24GB GPU Hits 58 tok/s via Offload — Can Your Hardware Run It?

Tencent's Hy4 flash 224B model quantized by AngelSlim from 410GiB to 125GiB, enabling 24GB GPU (4090D) to achieve 58 tok/s via Strata offload and 64GB Mac M4 Pro 18 tok/s, with Q3_K accuracy within 0.4 points of original, but speeds are official self-test peaks and require custom llama.cpp patches.

Quantization Reduces Hy4 Flash from 410GiB to 125GiB

The full-precision BF16 weights of Hy4 flash occupy 410.27 GiB . AngelSlim released four quantization tiers:

Q4_K_M (156.79 GiB) : general-purpose tier, includes Engram lookup tables, tested on M5 Max.

Q3_K (144.70 GiB) : ~35% of original size; the 50 tok/s result on M5 Max comes from this tier.

IQ2-AH (125.73 GiB) : smallest tier, ~69% storage reduction (≈285 GiB saved).

SPARK-4Bit / SPARK-4Bit-Fast : two 4-bit variants optimized for the Spark inference engine.

Even the smallest tier remains >100 GiB, so a 24GB GPU cannot hold the entire model in VRAM — this motivates the Strata offload approach.

Accuracy Impact: ≤0.4 Point Gap on Four Benchmarks

Official self-tests (no third-party replication) on four tasks show minimal degradation:

Q3_K vs. original: all four scores differ by ≤0.4 points.

DeepSWE v1.1: 64.6 → 64.3.

SPARK-4Bit on PPTGenBench: 54.1 vs. 54.0 (0.1 point gap).

The author cautions that untested scenarios (complex reasoning, long-document consistency) may degrade more.

Four Speed Claims, Two Distinct Technical Paths

The reported peak speeds belong to two separate inference stacks:

llama.cpp Path (model fits entirely in unified memory)

Spark: up to 39 tok/s — Tencent patched Spark's compute and weight preloading, raising generation from 13.8 to 28.8 tok/s; adding DFly2 speculative decoding pushes code scenarios to 40+ tok/s.

128GB Mac M5 Max: up to 50 tok/s — measured with Q3_K, 4K context, MTP speculative decoding. Apple-side patches (compute-graph reuse, decode optimization, operator fusion) lifted single-stream generation from 27 to 39 tok/s; DFly2 brings it to ~47 tok/s (~1.7×). Without speculative decoding at 48K context, pure generation is 37.2 tok/s — a different scenario.

Strata Path (offload when memory is insufficient)

24GB RTX 4090D: up to 58 tok/s — 126 GiB weights cannot fit in 24GB VRAM. Strata dynamically loads required weights from system memory/SSD and routes cache-miss expert computations to CPU during decode. This 58 tok/s reflects the offload mechanism, not native 24GB VRAM capacity.

64GB Mac M4 Pro: 18 tok/s — also Strata offload; 64GB Mac mini is also on the verification list.

The author emphasizes: the first two are "I have enough memory, run directly"; the last two are "I don't have enough memory, rely on scheduling to cope". Comparing the numbers directly is misleading because the engineering difficulty differs by orders of magnitude.

Four Caveats Before You Try

"Peak" values only. All figures (39/50/58/18) are official self-test upper bounds, not stable averages. Longer context, disabling speculative decoding, or different hardware will lower throughput — M5 Max dropping from 50 to 37 tok/s is a concrete example.

llama.cpp patches not in mainline. The Mac/Spark optimizations require Tencent's custom Metal patches; stock llama.cpp will fail. You must check out the corresponding branch and compile yourself.

125 GiB is weight size only. KV cache, runtime overhead, and Engram table access strategies add extra memory. No local tests exist for 1M context; official data maxes at 32K.

GGUF labeled for "end-to-end testing". Official notes indicate production deployment should use FP8 + multi-GPU. License terms have previously shown both Hy License and Apache 2.0 — check the repository LICENSE before use.

Hardware Decision Guide

24GB GPU (e.g., 4090D) : 58 tok/s is tempting but requires accepting Strata offload + dynamic expert routing complexity. Suitable for code completion and short documents; treat as experimental for primary workloads.

64GB Mac (M4 Pro / Mac mini) : 18 tok/s is usable but slow, sustained by offload. Good for trial and light tasks; don't expect it to replace the 128GB tier.

128GB unified-memory Mac / DGX Spark : Both paths validated. llama.cpp runs Q3_K / Q4_K_M directly at 39–50 tok/s with least friction and most stability.

32GB and below : Even the smallest quant (125 GiB) exceeds capacity. Wait for further compression or use API.

If local inference isn't mandatory, compare API pay-as-you-go cost against the hardware upgrade required to run the model — that calculation often outweighs spec-sheet comparisons.

The barrier has shifted but not vanished. On 20 Nov the author stated "activated 12B only governs speed, 224B total params is the ticket"; AngelSlim cut the ticket from 410 GiB to 126 GiB — real progress. Yet 126 GiB remains a gate; Strata offload merely hands you a "climb through the window" pass. What you can do inside and how stable it is still depend on your hardware and patience.

All speeds are official self-test peaks, not third-party verified; quantization sizes and accuracy data come from AngelSlim model card and official technical notes. Exact commands, weights, and code repositories are linked in the original article.

About this article

For questions about attribution, corrections or content rights, please contactadmin@besthub.devand we will review it promptly.

quantizationspeculative decodingLLM inferencellama.cpphardware requirementsAngelSlimHy4 flashStrata offload

Discussion 0

Questions, practical examples and thoughtful responses.

Open full discussion