Instructions to use unsloth/Hermes-4-70B-GGUF with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use unsloth/Hermes-4-70B-GGUF with Transformers:
# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("unsloth/Hermes-4-70B-GGUF", dtype="auto") - llama-cpp-python
How to use unsloth/Hermes-4-70B-GGUF with llama-cpp-python:
# !pip install llama-cpp-python from llama_cpp import Llama llm = Llama.from_pretrained( repo_id="unsloth/Hermes-4-70B-GGUF", filename="BF16/Hermes-4-70B-BF16-00001-of-00003.gguf", )
llm.create_chat_completion( messages = "No input example has been defined for this model task." )
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use unsloth/Hermes-4-70B-GGUF with llama.cpp:
Install from brew
brew install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf unsloth/Hermes-4-70B-GGUF:UD-Q4_K_XL # Run inference directly in the terminal: llama-cli -hf unsloth/Hermes-4-70B-GGUF:UD-Q4_K_XL
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf unsloth/Hermes-4-70B-GGUF:UD-Q4_K_XL # Run inference directly in the terminal: llama-cli -hf unsloth/Hermes-4-70B-GGUF:UD-Q4_K_XL
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 unsloth/Hermes-4-70B-GGUF:UD-Q4_K_XL # Run inference directly in the terminal: ./llama-cli -hf unsloth/Hermes-4-70B-GGUF:UD-Q4_K_XL
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 unsloth/Hermes-4-70B-GGUF:UD-Q4_K_XL # Run inference directly in the terminal: ./build/bin/llama-cli -hf unsloth/Hermes-4-70B-GGUF:UD-Q4_K_XL
Use Docker
docker model run hf.co/unsloth/Hermes-4-70B-GGUF:UD-Q4_K_XL
- LM Studio
- Jan
- Ollama
How to use unsloth/Hermes-4-70B-GGUF with Ollama:
ollama run hf.co/unsloth/Hermes-4-70B-GGUF:UD-Q4_K_XL
- Unsloth Studio
How to use unsloth/Hermes-4-70B-GGUF 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 unsloth/Hermes-4-70B-GGUF 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 unsloth/Hermes-4-70B-GGUF to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for unsloth/Hermes-4-70B-GGUF to start chatting
- Pi
How to use unsloth/Hermes-4-70B-GGUF with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama-server -hf unsloth/Hermes-4-70B-GGUF:UD-Q4_K_XL
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": "unsloth/Hermes-4-70B-GGUF:UD-Q4_K_XL" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Hermes Agent new
How to use unsloth/Hermes-4-70B-GGUF with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama-server -hf unsloth/Hermes-4-70B-GGUF:UD-Q4_K_XL
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 unsloth/Hermes-4-70B-GGUF:UD-Q4_K_XL
Run Hermes
hermes
- Docker Model Runner
How to use unsloth/Hermes-4-70B-GGUF with Docker Model Runner:
docker model run hf.co/unsloth/Hermes-4-70B-GGUF:UD-Q4_K_XL
- Lemonade
How to use unsloth/Hermes-4-70B-GGUF with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull unsloth/Hermes-4-70B-GGUF:UD-Q4_K_XL
Run and chat with the model
lemonade run user.Hermes-4-70B-GGUF-UD-Q4_K_XL
List all available models
lemonade list
Includes Unsloth chat template fixes!
Forllama.cpp, use--jinja
Unsloth Dynamic 2.0 achieves superior accuracy & outperforms other leading quants.
Hermes 4 — Llama-3.1 70B
Model Description
Hermes 4 70B is a frontier, hybrid-mode reasoning model based on Llama-3.1-70B by Nous Research that is aligned to you.
Read the Hermes 4 technical report here: Hermes 4 Technical Report
Chat with Hermes in Nous Chat: https://chat.nousresearch.com
Training highlights include a newly synthesized post-training corpus emphasizing verified reasoning traces, massive improvements in math, code, STEM, logic, creativity, and format-faithful outputs, while preserving general assistant quality and broadly neutral alignment.
What’s new vs Hermes 3
- Post-training corpus: Massively increased dataset size from 1M samples and 1.2B tokens to ~5M samples / ~60B tokens blended across reasoning and non-reasoning data.
- Hybrid reasoning mode with explicit
<think>…</think>segments when the model decides to deliberate, and options to make your responses faster when you want. - Reasoning that is top quality, expressive, improves math, code, STEM, logic, and even creative writing and subjective responses.
- Schema adherence & structured outputs: trained to produce valid JSON for given schemas and to repair malformed objects.
- Much easier to steer and align: extreme improvements on steerability, especially on reduced refusal rates.
Our Mission: Frontier Capabilities Aligned to You
In pursuit of the mission of producing models that are open, steerable and capable of producing the full range of human expression, while being able to be aligned to your values, we created a new benchmark, RefusalBench, that tests the models willingness to be helpful in a variety of scenarios commonly disallowed by closed and open models.
Hermes 4 achieves SOTA on RefusalBench across all popular closed and open models in being helpful and conforming to your values, without censorship.
Benchmarks (Hermes 4 70B)
Full tables, settings, and comparisons are in the technical report.
Prompt Format
Hermes 4 uses Llama-3-Chat format with role headers and special tags.
Basic chat:
<|start_header_id|>system<|end_header_id|>
You are Hermes 4. Be concise and helpful.<|eot_id|>
<|start_header_id|>user<|end_header_id|>
Explain the photoelectric effect simply.<|im_end|>
<|start_header_id|>assistant<|end_header_id|>
Reasoning mode
Reasoning mode can be activated with the chat template via the flag thinking=True or by using the following system prompt:
You are a deep thinking AI, you may use extremely long chains of thought to deeply consider the problem and deliberate with yourself via systematic reasoning processes to help come to a correct solution prior to answering. You should enclose your thoughts and internal monologue inside <think> </think> tags, and then provide your solution or response to the problem.
Note that you can add any additional system instructions before or after this system message, and it will adjust the models policies, style, and effort of thinking, as well as its post-thinking style, format, identity, and more. You may also interleave the tool definition system message with the reasoning one.
When the model chooses to deliberate, it emits:
<|start_header_id|>assistant<|end_header_id|>
<think>
…model’s internal reasoning may appear here…
</think>
Final response starts here…<|eot_id|>
Additionally, we provide a flag to keep the content inbetween the <think> ... </think> that you can play with by setting keep_cots=True
Function Calling & Tool Use
Hermes 4 supports function/tool calls within a single assistant turn, produced after it's reasoning:
System message (example):
<|im_start|>system
You are a function-calling AI. Tools are provided inside <tools>…</tools>.
When appropriate, call a tool by emitting a <tool_call>{...}</tool_call> object.
After a tool responds (as <tool_response>), continue reasoning inside <think> and produce the final answer.
<tools>
{"type":"function","function":{"name":"get_weather","description":"Get weather by city","parameters":{"type":"object","properties":{"city":{"type":"string"}},"required":["city"]}}}
</tools><|im_end|>
Note that you may also simply place tool definitions into the "tools:" field of your messages, and the chat template will parse and create the system prompt for you. This also works with reasoning mode for improved accuracy of tool use.
The model will then generate tool calls within <tool_call> {tool_call} </tool_call> tags, for easy parsing. The tool_call tags are also added tokens, so it makes it easy to parse while streaming! There are also automatic tool parsers built-in to VLLM and SGLang for Hermes, just set the tool parser in VLLM to hermes and in SGLang to qwen25.
Inference Notes
- Sampling defaults that work well:
temperature=0.6, top_p=0.95, top_k=20. - Template: Use the Llama chat format for Hermes 4 70B and 405B as shown above, or set
add_generation_prompt=Truewhen usingtokenizer.apply_chat_template(...).
Transformers example
from transformers import AutoTokenizer, AutoModelForCausalLM
import torch
model_id = "NousResearch/Hermes-4-Llama-3.1-70B"
tokenizer = AutoTokenizer.from_pretrained(model_id, trust_remote_code=True)
model = AutoModelForCausalLM.from_pretrained(
model_id,
torch_dtype=torch.float16,
device_map="auto"
)
messages = [
{"role":"system","content":"You are Hermes 4. Be concise."},
{"role":"user","content":"Summarize CRISPR in 3 sentences."}
]
inputs = tokenizer.apply_chat_template(
messages, add_generation_prompt=True, return_tensors="pt"
).to(model.device)
outputs = model.generate(
**inputs, max_new_tokens=400, temperature=0.6, top_p=0.95, top_k=20, do_sample=True
)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
For production serving on multi-GPU nodes, consider tensor parallel inference engines (e.g., SGLang/vLLM backends) with prefix caching.
Inference Providers:
Nous Portal:
Chutes:
Nebius:
Luminal:
Quantized / Smaller Variants
Hermes 4 is available as BF16 original weights as well as BF16 as well as FP8 variants and GGUF variants by LM Studio.
FP8: https://huggingface.co/NousResearch/Hermes-4-70B-FP8
GGUF (Courtesy of LM Studio team!): https://huggingface.co/lmstudio-community/Hermes-4-70B-GGUF
Hermes 4 is also available in smaller sizes (e.g., 70B) with similar prompt formats.
See the Hermes 4 collection to explore them all: https://huggingface.co/collections/NousResearch/hermes-4-collection-68a731bfd452e20816725728
How to cite
@misc{teknium2025hermes4technicalreport,
title={Hermes 4 Technical Report},
author={Ryan Teknium and Roger Jin and Jai Suphavadeeprasit and Dakota Mahan and Jeffrey Quesnelle and Joe Li and Chen Guang and Shannon Sands and Karan Malhotra},
year={2025},
eprint={2508.18255},
archivePrefix={arXiv},
primaryClass={cs.AI},
url={https://arxiv.org/abs/2508.18255},
}
- Downloads last month
- 3,125
1-bit
2-bit
3-bit
4-bit
5-bit
6-bit
8-bit
16-bit




