Text Generation
GGUF
rocmfpx
rocmiq
strix-halo
amd
Mixture of Experts
hy4-flash
agentic
tool-calling
low-memory
imatrix
conversational
Instructions to use Harsha001/Hy4-flash-ROCmFPX 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 Harsha001/Hy4-flash-ROCmFPX 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 Harsha001/Hy4-flash-ROCmFPX:IQ1_S_ROCMIQ # Run inference directly in the terminal: llama cli -hf Harsha001/Hy4-flash-ROCmFPX:IQ1_S_ROCMIQ
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf Harsha001/Hy4-flash-ROCmFPX:IQ1_S_ROCMIQ # Run inference directly in the terminal: llama cli -hf Harsha001/Hy4-flash-ROCmFPX:IQ1_S_ROCMIQ
Build from source code
git clone https://github.com/ggml-org/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-app # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama serve -hf Harsha001/Hy4-flash-ROCmFPX:IQ1_S_ROCMIQ # Run inference directly in the terminal: ./build/bin/llama cli -hf Harsha001/Hy4-flash-ROCmFPX:IQ1_S_ROCMIQ
Use Docker
docker model run hf.co/Harsha001/Hy4-flash-ROCmFPX:IQ1_S_ROCMIQ
- Llama new
- LM Studio
- Jan
- vLLM
How to use Harsha001/Hy4-flash-ROCmFPX with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Harsha001/Hy4-flash-ROCmFPX" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Harsha001/Hy4-flash-ROCmFPX", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/Harsha001/Hy4-flash-ROCmFPX:IQ1_S_ROCMIQ
- Ollama
How to use Harsha001/Hy4-flash-ROCmFPX with Ollama:
ollama run hf.co/Harsha001/Hy4-flash-ROCmFPX:IQ1_S_ROCMIQ
- Unsloth Desktop
- Pi
How to use Harsha001/Hy4-flash-ROCmFPX with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf Harsha001/Hy4-flash-ROCmFPX:IQ1_S_ROCMIQ
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:9931/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "Harsha001/Hy4-flash-ROCmFPX:IQ1_S_ROCMIQ" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Docker Model Runner
How to use Harsha001/Hy4-flash-ROCmFPX with Docker Model Runner:
docker model run hf.co/Harsha001/Hy4-flash-ROCmFPX:IQ1_S_ROCMIQ
- Lemonade
How to use Harsha001/Hy4-flash-ROCmFPX with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull Harsha001/Hy4-flash-ROCmFPX:IQ1_S_ROCMIQ
Run and chat with the model
lemonade run user.Hy4-flash-ROCmFPX-IQ1_S_ROCMIQ
List all available models
lemonade list
- Hermes Agent
How to use Harsha001/Hy4-flash-ROCmFPX with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf Harsha001/Hy4-flash-ROCmFPX:IQ1_S_ROCMIQ
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:9931/v1 hermes config set model.default Harsha001/Hy4-flash-ROCmFPX:IQ1_S_ROCMIQ
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use Harsha001/Hy4-flash-ROCmFPX with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf Harsha001/Hy4-flash-ROCmFPX:IQ1_S_ROCMIQ
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:9931/v1 \ --custom-model-id "Harsha001/Hy4-flash-ROCmFPX:IQ1_S_ROCMIQ" \ --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"
File size: 7,199 Bytes
ec233e5 a8c9558 ec233e5 a8c9558 ec233e5 6fe60ab f2fcd3e 6fe60ab a8c9558 6fe60ab a8c9558 6fe60ab a8c9558 6fe60ab a8c9558 6fe60ab ec233e5 a8c9558 6fe60ab ec233e5 a8c9558 6fe60ab a8c9558 ec233e5 a8c9558 ec233e5 a8c9558 ec233e5 a8c9558 6fe60ab ec233e5 a8c9558 ec233e5 a8c9558 ec233e5 a8c9558 ec233e5 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 | ---
license: other
license_name: tencent-hy-license
license_link: LICENSE
base_model: tencent/Hy4-flash
base_model_relation: quantized
pipeline_tag: text-generation
tags:
- gguf
- rocmfpx
- rocmiq
- strix-halo
- amd
- moe
- hy4-flash
- agentic
- tool-calling
- low-memory
---
# Hy4-flash ROCmFPX: runs on every Strix memory size (32 / 64 / 96 / 128 GB)
> ## NEW (29 November 2026): Hy4-flash now fits 32 GB and 64 GB machines
>
> Two new low-bit quants made with our **ROCmIQ** formats for AMD GPUs. Together with the Q4_0 builds, Hy4-flash
> now supports **every AMD Strix memory configuration**, not only the 128 GB one.
>
> | Your machine (unified memory) | Download this folder | Memory the model needs |
> |---|---|---|
> | **Strix Halo 32 GB** (also Strix Point / Ryzen AI 300 laptops with 32 GB) | **`IQ1_S_ROCMIQ-E328/`** (new) | **25.81 GB** |
> | **Strix Halo 64 GB** (also Strix Point / Ryzen AI 300 with 64 GB) | **`IQ2_XXS_ROCMIQ/`** (new) | **45.33 GB** |
> | **Strix Halo 96 GB** | **`IQ2_XXS_ROCMIQ/`** (new), leaves room for long context | **45.33 GB** |
> | **Strix Halo 128 GB** | `Q4_0_STRIX/` (best quality) or `Q4_0_STRIXFAST/` (faster) | 84.7 / 80.4 GiB |
>
> The big Engram lookup table stays on the SSD and is read row by row, so it does not count against your memory.
> Pick the biggest build your machine can hold. Setup for each size is under [Running](#running).
>
> **We would love your feedback, especially from low-memory devices.** If you run one of these on a 32 GB, 64 GB or
> 96 GB machine (Strix Halo, Strix Point, other Ryzen AI laptops or mini PCs, or any other AMD GPU), please tell us
> in the [Community tab](https://huggingface.co/Harsha001/Hy4-flash-ROCmFPX/discussions): your device and memory,
> the speed (`llama-bench` pp512 / tg128), how much memory it used, and how the answers look. Happy building!
Hardware-aware GGUF quants of [tencent/Hy4-flash](https://huggingface.co/tencent/Hy4-flash), built with the
[ROCmFPX](https://github.com/HarshaVardhan3002/ROCmFPX) formats for AMD GPUs and sized for a named amount of unified
memory: 32 GB, 64 GB, 96 GB or 128 GB.
Hy4-flash: 220B parameters in total, of which 64B are the Engram lookup table, 12B active per token, 42 layers,
512 experts with top-16 routing. Text only here (the vision encoder and the DFly2 drafter are not included yet).
## Files
| Folder | Experts | Everything else | Must fit in memory | Engram table (SSD / CPU) | For |
|---|---|---|---|---|---|
| `IQ1_S_ROCMIQ-E328/` **(new)** | 328 of 512 per layer, gate/up ROCmIQ1_S (1.56 bit), down ROCmIQ2_XXS (2.06 bit) | Q8_0_ROCMFPX, attention output and gate Q4_0_ROCMFP4 | **25.81 GB** | Q4_0, read from the SSD | **32 GB** machines |
| `IQ2_XXS_ROCMIQ/` **(new)** | all 512 per layer, ROCmIQ2_XXS (2.06 bit) | Q8_0_ROCMFPX | **45.33 GB** | Q4_0, read from the SSD | **64 GB** and **96 GB** machines |
| `Q4_0_STRIX/` | all 512, Q4_0_ROCMFP4 | Q8_0_ROCMFPX | 84.7 GiB | Q4_0, 33 GiB | 128 GB (recommended there) |
| `Q4_0_STRIXFAST/` | all 512, Q4_0_ROCMFP4_FAST (faster kernel) | Q8_0_ROCMFPX | 80.4 GiB | Q4_0, 33 GiB | 128 GB, speed pick |
Each folder holds a split GGUF (parts of at most 45 GB). Point llama.cpp at the `-00001-of-` file. "Must fit in
memory" is every tensor except the Engram table and the token embedding, which are only read row by row.
**Quality of the new quants** on held-out agentic chats (assistant tokens only), compared with our Q8_0 of the same
model (lower KL divergence is better):
| Folder | KL divergence | Same top token | Perplexity |
|---|---|---|---|
| `IQ2_XXS_ROCMIQ` (64 GB) | 0.10291 | 94.50% | 1.7852 |
| `IQ1_S_ROCMIQ-E328` (32 GB) | 0.18494 | 92.02% | 1.7495 |
| `IQ1_S_ROCMIQ-E360` (not uploaded, for comparison) | 0.18969 | 91.25% | 1.8034 |
Q8_0 itself is close to the original BF16 model but not identical (Hy4-flash is sensitive to rounding). The 32 GB
build has to drop experts to fit, and Hy4-flash spreads its work over many experts, so it is clearly weaker than the
64 GB one: use the biggest build your machine can hold.
How it was made:
- importance matrix from **agentic text**: coding agent runs, tool calls, function calling, shell and database tasks,
rendered with the model's own chat template (tool schemas included). These quants are tuned for agent work, tool
calling and coding, not for essays. English first.
- ROCmFPX tensor scales on, token embedding kept at Q8_0.
- **ROCmIQ2_XXS and ROCmIQ1_S** are our low-bit formats for AMD GPUs: codebook quants with a per-tensor scale,
decoded without the large lookup grids of the standard IQ types.
- **32 GB build:** the experts each layer uses least were removed, ranked by the REAP score (router-weighted expert
activation) on the same agentic text. 328 of 512 experts are kept per layer, 80.4% of the routing weight. The list is in `keep/`.
- the new files use Tencent's updated config of 26 November 2026 (the Engram lookup is no longer rounded through fp8,
new chat template; the weights are the same).
- the Engram table is only read by row lookups, one row per token, so it does not need GPU memory.
## Running
Hy4-flash support (architecture `hy_v4_flash`, with ROCmFPX tensor scales and the ROCmIQ types) is in `main` of the
ROCmFPX fork of llama.cpp. Build it with Vulkan or ROCm/HIP:
```
git clone https://github.com/HarshaVardhan3002/ROCmFPX
cd ROCmFPX
cmake -B build -DGGML_VULKAN=ON -DCMAKE_BUILD_TYPE=Release
cmake --build build --config Release -j
```
32 GB, 64 GB or 96 GB machine (pick the folder from the table):
```
hf download Harsha001/Hy4-flash-ROCmFPX --include "IQ2_XXS_ROCMIQ/*" --local-dir .
./build/bin/llama-server -m IQ2_XXS_ROCMIQ/Hy4-flash-IQ2_XXS_ROCMIQ-00001-of-00002.gguf \
-ngl 99 -lm mmap -ot "per_layer_token_embd=CPU" -c 16384 --jinja \
--chat-template-kwargs '{"reasoning_effort":"no_think"}'
```
For 32 GB use `--include "IQ1_S_ROCMIQ-E328/*"` and `IQ1_S_ROCMIQ-E328/Hy4-flash-IQ1_S_ROCMIQ-E328-00001-of-00002.gguf`.
128 GB machine:
```
./build/bin/llama-server -m Q4_0_STRIX/Hy4-flash-Q4_0_STRIX-00001-of-00003.gguf \
-ngl 99 -ot "per_layer_token_embd=CPU" -c 65536 --jinja \
--chat-template-kwargs '{"reasoning_effort":"no_think"}'
```
Notes for low-memory machines:
- **Keep `-lm mmap`.** Without it the runtime turns memory mapping off on integrated GPUs and reads the whole Engram
table into RAM, which does not fit. With it the table stays in the file on the SSD and only the rows each token
needs are read. Keep the files on a fast NVMe drive.
- Give the GPU as much of the memory as the system can spare (BIOS / AMD Software on Windows, the GTT limit on
Linux), and close other programs.
- Start with a small context (`-c 8192` to `-c 16384`) and raise it if memory allows.
- ROCmIQ types are made for the GPU (Vulkan). They also run on the CPU, but slowly.
`reasoning_effort` takes `"high"` (thinking, the default) or `"no_think"`.
Every file passed a smoke test before upload.
## Licence
Tencent Hy License, Version 1.0 (see `LICENSE`, copied from the original repo). It is derived from Apache 2.0 with
extra commercial terms for large Model-as-a-Service businesses (section 10). All credit for the model goes to Tencent.
|