Hy4-flash · Maya GGUF

GGUF quants of tencent/Hy4-flash (220B parameters: 155.5B language backbone with 512 experts per layer, 63.5B n-gram "Engram" tables, a vision encoder and the DFly2 drafter; 1M context) made for Project Maya. The files also load in llama.cpp with the Hy4-flash pull request (see "Running it").

Sizes

Size Experts Model file Vision Drafter n-gram table (on SSD)
Maya-XS 2-bit (IQ2_XXS), every layer 44.8 GB 0.8 GB 0.7 GB 63.4 GB
Maya-S 2-bit (IQ2_XXS) on layers 1-23, 3-bit (IQ3_XXS) on layers 24-41 53.0 GB 0.8 GB 0.9 GB 63.4 GB
Maya-M 3-bit (IQ3_XXS), 4-bit (IQ4_XS) on 7 layers 68.4 GB 0.8 GB 0.9 GB 63.4 GB
Maya-L 4-bit (IQ4_XS), 5-bit (Q5_K) on 5 layers 89.5 GB 0.8 GB 0.9 GB 63.4 GB

Every size uses the same n-gram table file. It is Tencent's FP8 table, value for value; it is read from the SSD page by page while the model runs and does not need to fit in memory.

:gear: Usage Guide

Table: Hardware requirements (units = total memory: RAM + VRAM, or unified memory). The n-gram table is not counted: it stays on the SSD.

Maya-XS Maya-S Maya-M Maya-L
56-64 GB 68-80 GB 80-96 GB 104-128 GB
  • Rule of thumb: RAM + VRAM ≈ the model file + the vision file + 4-8 GB for context. With less it still runs, only slower, because parts of the model are then read from disk.
  • Maya-XS is the size for a PC with 64 GB of RAM and one GPU (any size; the more VRAM, the more of the experts run on it), or a 64 GB unified-memory machine.
  • Keep the n-gram table (63.4 GB) on an SSD or NVMe drive, never on a hard disk. Disk space for Maya-XS in total: about 110 GB.
  • Pictures need the vision file; text-only use can skip it.
  • With Project Maya, Maya-S, Maya-M and Maya-L need a graphics card of about 12 GB or more: about 9-10 GB of the model always sits on the card. Maya-XS runs on cards from 8 GB.
  • Graphics cards under about 10 GB: Project Maya's setup picks a Maya-XS file made for them by itself (the same model and experts, with the attention weights at 4 bits so that the part that must sit on the card fits; slightly lower quality than standard Maya-XS). It is Maya-XS-8GB/Hy4-Flash-Maya-XS-8GB-00001-of-00002.gguf_file in this repository and uses Maya-XS's n-gram table.

Recommended Settings

Tencent's defaults, which Project Maya applies by itself when the model is selected:

Parameter Thinking (reasoning_effort high, the default) Direct answers (no_think)
temperature 0.9 0.9
top_p 1.0 1.0
top_k off off
  • Maximum context window: 1,048,576.
  • Thinking has two modes: on (reasoning_effort high, the default) and off (no_think). The model is not made for other levels.
  • Keep the recommended sampling: with greedy decoding (temperature 0) a long thinking phase can start repeating itself, as it can with the original model.

Quality

Measured against the original full-precision model on held-out conversations that were never used for calibration (110,230 answer tokens; the original's own next-token distribution is the reference).

Same top token as the original KL divergence (mean)
Maya-XS 88.5% 0.16
Maya-S 91.8% 0.072
Maya-M 93.6% 0.046
Maya-L 96.6% 0.012

The same measurement as charts, by model file size, next to Tencent's own GGUF files (scored the same way, on the same conversations):

KL divergence from the original model, by file size

Same top token as the original model, by file size

How they were made

  1. Calibration text in Hy4-flash's own chat format, thinking included: a neutral mix of conversations, a large part of it the original model's own answers.
  2. Every expert is rounded with error feedback against its own input statistics, layer after layer, each layer seeing the already-rounded layers before it.
  3. The rounding settings were tuned on this model, and the bits per layer follow its measured sensitivity.
  4. Standard ggml tensor types only, so the files stay loadable by llama.cpp.

Files

File What Size
Maya-XS/Hy4-Flash-Maya-XS-IQ2_XXS-00001-of-00002.gguf the model 44.8 GB
Maya-XS/Hy4-Flash-Maya-XS-IQ2_XXS-00002-of-00002.gguf n-gram table (FP8), same for every size 63.4 GB
Maya-XS/mmproj-Hy4-Flash-Maya-XS.gguf vision encoder 0.8 GB
Maya-XS/Hy4-Flash-Maya-XS-drafter.dfly2 DFly2 drafter, for Project Maya 0.7 GB
Maya-S/Hy4-Flash-Maya-S-IQ2_S-00001-of-00002.gguf the model 53.0 GB
Maya-S/Hy4-Flash-Maya-S-IQ2_S-00002-of-00002.gguf n-gram table (FP8), same for every size 63.4 GB
Maya-S/mmproj-Hy4-Flash-Maya-S.gguf vision encoder 0.8 GB
Maya-S/Hy4-Flash-Maya-S-drafter.dfly2 DFly2 drafter, for Project Maya 0.9 GB
Maya-M/Hy4-Flash-Maya-M-IQ3_XXS-00001-of-00002.gguf the model 68.4 GB
Maya-M/Hy4-Flash-Maya-M-IQ3_XXS-00002-of-00002.gguf n-gram table (FP8), same for every size 63.4 GB
Maya-M/mmproj-Hy4-Flash-Maya-M.gguf vision encoder 0.8 GB
Maya-M/Hy4-Flash-Maya-M-drafter.dfly2 DFly2 drafter, for Project Maya 0.9 GB
Maya-L/Hy4-Flash-Maya-L-IQ4_XS-00001-of-00002.gguf the model 89.5 GB
Maya-L/Hy4-Flash-Maya-L-IQ4_XS-00002-of-00002.gguf n-gram table (FP8), same for every size 63.4 GB
Maya-L/mmproj-Hy4-Flash-Maya-L.gguf vision encoder 0.8 GB
Maya-L/Hy4-Flash-Maya-L-drafter.dfly2 DFly2 drafter, for Project Maya 0.9 GB
mtp/Hy4-Flash-mtp-BF16.gguf_file Tencent's MTP draft block, one file for every size, for Project Maya 7.5 GB

Running it

Project Maya (from v1.1.68):

git clone https://github.com/mw00/project-maya.git && cd project-maya
./setup.sh --setup --model hy4-flash-maya-xs      # Windows: START-MAYA.bat

The script checks the PC, downloads and verifies the files, builds the engine for your GPU and serves a dashboard and an OpenAI- and Anthropic-compatible API at http://127.0.0.1:8080.

  • Drafting is available in Project Maya: it drafts with Tencent's MTP block, which is in mtp/ as a file of its own (one for every size; the setup downloads it where the graphics card has room for it).
  • NVIDIA graphics cards on Linux and Windows, and AMD on Linux, are supported.

llama.cpp: Hy4-flash support is in pull request ggml-org/llama.cpp #32517 (not merged yet). Build that branch, then:

llama-server -m Hy4-Flash-Maya-XS-IQ2_XXS-00001-of-00002.gguf --mmproj mmproj-Hy4-Flash-Maya-XS.gguf \
  --jinja --temp 0.9 --top-p 1.0 --top-k 0 -c 32768 -ngl 99

Both shards must sit in the same folder; llama.cpp finds the second one by itself. The drafter file is not used by llama.cpp.

License

Hy4-flash is released under the Tencent Hy License (Apache-2.0 based, with additional commercial terms for large model-as-a-service providers in its section 10). These files are modified versions of Tencent's weights (quantized; the n-gram table is stored as FP8 codes, the vision encoder and drafter are re-encoded) and are distributed under the same license; a copy is in this repository (LICENSE). "Tencent" and "Hy" are Tencent's names; this is not a Tencent release.

Downloads last month
191,067
GGUF
Model size
219B params
Architecture
hy_v4_flash
Hardware compatibility
Log In to add your hardware

2-bit

3-bit

4-bit

Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for peasantsmith/Hy4-Flash-Maya-GGUF

Quantized
(50)
this model

Space using peasantsmith/Hy4-Flash-Maya-GGUF 1