Instructions to use clxudfast/huihui4-8b-a4b-v2-Q4_K_M 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 clxudfast/huihui4-8b-a4b-v2-Q4_K_M 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 clxudfast/huihui4-8b-a4b-v2-Q4_K_M:Q4_K_M # Run inference directly in the terminal: llama cli -hf clxudfast/huihui4-8b-a4b-v2-Q4_K_M:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf clxudfast/huihui4-8b-a4b-v2-Q4_K_M:Q4_K_M # Run inference directly in the terminal: llama cli -hf clxudfast/huihui4-8b-a4b-v2-Q4_K_M: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 clxudfast/huihui4-8b-a4b-v2-Q4_K_M:Q4_K_M # Run inference directly in the terminal: ./llama-cli -hf clxudfast/huihui4-8b-a4b-v2-Q4_K_M: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 clxudfast/huihui4-8b-a4b-v2-Q4_K_M:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama-cli -hf clxudfast/huihui4-8b-a4b-v2-Q4_K_M:Q4_K_M
Use Docker
docker model run hf.co/clxudfast/huihui4-8b-a4b-v2-Q4_K_M:Q4_K_M
- LM Studio
- Jan
- Ollama
How to use clxudfast/huihui4-8b-a4b-v2-Q4_K_M with Ollama:
ollama run hf.co/clxudfast/huihui4-8b-a4b-v2-Q4_K_M:Q4_K_M
- Unsloth Studio
How to use clxudfast/huihui4-8b-a4b-v2-Q4_K_M with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for clxudfast/huihui4-8b-a4b-v2-Q4_K_M to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for clxudfast/huihui4-8b-a4b-v2-Q4_K_M to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for clxudfast/huihui4-8b-a4b-v2-Q4_K_M to start chatting
- Pi
How to use clxudfast/huihui4-8b-a4b-v2-Q4_K_M with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf clxudfast/huihui4-8b-a4b-v2-Q4_K_M:Q4_K_M
Configure the model in Pi
# Install Pi: npm install -g @mariozechner/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "clxudfast/huihui4-8b-a4b-v2-Q4_K_M:Q4_K_M" } ] } } }Run Pi
# Start Pi in your project directory: pi
- OpenClaw new
How to use clxudfast/huihui4-8b-a4b-v2-Q4_K_M with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf clxudfast/huihui4-8b-a4b-v2-Q4_K_M: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 "clxudfast/huihui4-8b-a4b-v2-Q4_K_M: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"
- Docker Model Runner
How to use clxudfast/huihui4-8b-a4b-v2-Q4_K_M with Docker Model Runner:
docker model run hf.co/clxudfast/huihui4-8b-a4b-v2-Q4_K_M:Q4_K_M
- Lemonade
How to use clxudfast/huihui4-8b-a4b-v2-Q4_K_M with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull clxudfast/huihui4-8b-a4b-v2-Q4_K_M:Q4_K_M
Run and chat with the model
lemonade run user.huihui4-8b-a4b-v2-Q4_K_M-Q4_K_M
List all available models
lemonade list
- Hermes Agent
How to use clxudfast/huihui4-8b-a4b-v2-Q4_K_M with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf clxudfast/huihui4-8b-a4b-v2-Q4_K_M: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 clxudfast/huihui4-8b-a4b-v2-Q4_K_M:Q4_K_M
Run Hermes
hermes
- Atomic Chat
Huihui4-8B-A4B-v2-Q4_K_M
This is a 4-bit quantized version of Huihui4-8B-A4B-v2 converted to GGUF format for use with llama.cpp.
Model Details
- Base Model: Huihui4-8B-A4B-v2
- Quantization: Q4_K_M (4-bit, medium quality)
- File Size: 5.42 GB
- Parameters: 8.10 B
- Architecture: Gemma4 with 30 layers, 16 attention heads
- Context Length: 262,144 tokens (training), 4,096 tokens (inference)
Quantization Details
The model was quantized using llama.cpp's q4_k_m quantization method:
- Weight Quantization: 4-bit K-quants
- Activation Quantization: 6-bit (mixed)
- Memory Usage: ~4 GB VRAM on GPU, ~2.6 GB on CPU
- Performance: ~15-20 tokens/second on GTX 1060 6GB
Hardware Requirements
Minimum (CPU Only)
- RAM: 8 GB
- Storage: 6 GB
Recommended (GPU Acceleration)
- GPU: NVIDIA GTX 1060 6GB or better
- VRAM: 6 GB
- RAM: 16 GB
- Storage: 6 GB
Vulkan Backend (Tested)
- GPU: NVIDIA GTX 1060 6GB
- Driver: NVIDIA 535+
- Vulkan: 1.3+
Usage
With llama.cpp (CLI)
# Download the model
huggingface-cli download clxudfast/huihui4-8b-a4b-v2-Q4_K_M huihui4-8b-a4b-v2-Q4_K_M.gguf --local-dir ./models
# Run inference
./llama-cli -m ./models/huihui4-8b-a4b-v2-Q4_K_M.gguf -p "Hello, how are you?" -n 100
With llama-server (HTTP API)
# Start the server
./llama-server -m ./models/huihui4-8b-a4b-v2-Q4_K_M.gguf --port 8080 --host 0.0.0.0
# Query via HTTP
curl -X POST http://localhost:8080/completion -H "Content-Type: application/json" -d '{"prompt": "The meaning of life is", "n_predict": 50}'
With Python (llama-cpp-python)
from llama_cpp import Llama
llm = Llama(
model_path="./models/huihui4-8b-a4b-v2-Q4_K_M.gguf",
n_ctx=4096,
n_gpu_layers=31, # Offload all layers to GPU
verbose=False
)
output = llm.create_completion(
"The meaning of life is",
max_tokens=50,
temperature=0.7
)
print(output["choices"][0]["text"])
Performance Benchmarks
GTX 1060 6GB (Vulkan Backend)
- Load Time: ~30 seconds
- Inference Speed: 15-20 tokens/second
- VRAM Usage: ~4.5 GB
- GPU Utilization: 70-90%
CPU (Intel i7-12700K)
- Load Time: ~15 seconds
- Inference Speed: 3-5 tokens/second
- RAM Usage: ~6 GB
Conversion Process
- Downloaded Huihui4-8B-A4B-v2 from Hugging Face
- Built llama.cpp with Vulkan backend support
- Converted model to GGUF format using
convert_hf_to_gguf.py - Quantized to Q4_K_M using
quantizetool - Tested inference on GTX 1060 6GB GPU
Limitations
- Context limited to 4,096 tokens during inference (vs 262,144 training)
- Quantization may reduce accuracy for complex reasoning tasks
- Vulkan backend may have compatibility issues with some GPU drivers
License
Apache 2.0 (same as base model)
Original Model
- Hugging Face: huihui-ai/Huihui4-8B-A4B-v2
- License: Apache 2.0
Contributing
Issues and pull requests welcome at the original model repository.
- Downloads last month
- 4
4-bit
Model tree for clxudfast/huihui4-8b-a4b-v2-Q4_K_M
Base model
google/gemma-4-26B-A4B