Instructions to use nace-ai/Hy4-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 nace-ai/Hy4-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 nace-ai/Hy4-GGUF:Q4_K_M # Run inference directly in the terminal: llama cli -hf nace-ai/Hy4-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 nace-ai/Hy4-GGUF:Q4_K_M # Run inference directly in the terminal: llama cli -hf nace-ai/Hy4-GGUF:Q4_K_M
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 nace-ai/Hy4-GGUF:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama cli -hf nace-ai/Hy4-GGUF:Q4_K_M
Use Docker
docker model run hf.co/nace-ai/Hy4-GGUF:Q4_K_M
- Llama new
- LM Studio
- Jan
- vLLM
How to use nace-ai/Hy4-GGUF with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "nace-ai/Hy4-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": "nace-ai/Hy4-GGUF", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/nace-ai/Hy4-GGUF:Q4_K_M
- Ollama
How to use nace-ai/Hy4-GGUF with Ollama:
ollama run hf.co/nace-ai/Hy4-GGUF:Q4_K_M
- Unsloth Desktop
- Pi
How to use nace-ai/Hy4-GGUF with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf nace-ai/Hy4-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:9931/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "nace-ai/Hy4-GGUF:Q4_K_M" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Docker Model Runner
How to use nace-ai/Hy4-GGUF with Docker Model Runner:
docker model run hf.co/nace-ai/Hy4-GGUF:Q4_K_M
- Lemonade
How to use nace-ai/Hy4-GGUF with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull nace-ai/Hy4-GGUF:Q4_K_M
Run and chat with the model
lemonade run user.Hy4-GGUF-Q4_K_M
List all available models
lemonade list
- Hermes Agent
How to use nace-ai/Hy4-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 nace-ai/Hy4-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:9931/v1 hermes config set model.default nace-ai/Hy4-GGUF:Q4_K_M
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use nace-ai/Hy4-GGUF with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf nace-ai/Hy4-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:9931/v1 \ --custom-model-id "nace-ai/Hy4-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"
Hy4 GGUF
We introduce Hy4 GGUF from Nace.AI: Tencent's Hy4 as one 447.5 GB Q4_K_M file for llama.cpp, plus the 2.7 GB vision projector.
A 228.3 GB STQ1_0 version, which needs a custom llama.cpp runtime, is in STQ1_0.
Results
- 447.5 GB:
Hy4-Q4_K_M.gguf, 4.65 bits per weight. - 0.068 mean KL from the BF16 model on held-out text, with the same next token as BF16 at 91.8% of 5,621 positions.
- Lower KL than the public 4-bit Hy4 files we measured: AngelSlim's Q4_K_M (470.2 GB, KL 0.091) and Xylolabs' MLX 4-bit (447.6 GB, KL 0.091).
KL measures how far the quantized model's next-token probabilities drift from BF16; lower is closer. The chart shows the files we scored on the same 11 held-out texts in November 2026. Sizes are the text-model weight files; the MLX and FP8 points use their published weight shards.
Nace Weight Space Quantization
Four-bit routed experts, higher precision for the rest.
Routed-expert weights in all 77 MoE layers are stored at 4 bits. Attention, shared experts, the dense first-layer FFN, embeddings and the output layer use 8 bits. The KV expansion matrices stay in BF16, and routers and norms keep full precision.
Run it
Hy4 needs the llama.cpp build from PR #32517, commit f8d4cc4.
git clone https://github.com/Little0o0/llama.cpp && cd llama.cpp
git checkout f8d4cc414546b8320a281f4c1364aba5f07d4149
cmake -B build -DGGML_CUDA=ON && cmake --build build --config Release -j
hf download nace-ai/Hy4-GGUF Hy4-Q4_K_M.gguf mmproj-HY4-VL-BF16.gguf LICENSE --local-dir ./Hy4-GGUF
build/bin/llama-server -m ./Hy4-GGUF/Hy4-Q4_K_M.gguf --jinja -c 8192 -ngl 99
--jinja is required: Hy4's chat template matches no built-in llama.cpp template.
License
Tencent Hy License, Version 1.0, including its Section 10 commercial terms for large Model-as-a-Service operators.
- Downloads last month
- -
4-bit
Model tree for nace-ai/Hy4-GGUF
Base model
tencent/Hy4