Instructions to use HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-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 HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-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 HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-GGUF:Q4_K_M # Run inference directly in the terminal: llama cli -hf HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-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 HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-GGUF:Q4_K_M # Run inference directly in the terminal: llama cli -hf HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-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 HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-GGUF:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama cli -hf HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-GGUF:Q4_K_M
Use Docker
docker model run hf.co/HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-GGUF:Q4_K_M
- Llama new
- LM Studio
- Jan
- vLLM
How to use HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-GGUF with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-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": "HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-GGUF", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-GGUF:Q4_K_M
- Ollama
How to use HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-GGUF with Ollama:
ollama run hf.co/HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-GGUF:Q4_K_M
- Unsloth Desktop
- Pi
How to use HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-GGUF with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-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": "HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-GGUF:Q4_K_M" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Docker Model Runner
How to use HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-GGUF with Docker Model Runner:
docker model run hf.co/HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-GGUF:Q4_K_M
- Lemonade
How to use HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-GGUF with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-GGUF:Q4_K_M
Run and chat with the model
lemonade run user.GLM-4-9B-Cooking-Assistant-GGUF-Q4_K_M
List all available models
lemonade list
- Hermes Agent
How to use HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-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 HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-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 HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-GGUF:Q4_K_M
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-GGUF with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-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 "HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-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"
GLM-4-9B Cooking Assistant v1
Browse files- .gitattributes +5 -0
- LICENSE +21 -0
- README.md +220 -0
- SHA256SUMS +5 -0
- glm-4-9b-cooking-assistant-v1-BF16.gguf +3 -0
- glm-4-9b-cooking-assistant-v1-Q4_K_M.gguf +3 -0
- glm-4-9b-cooking-assistant-v1-Q6_K.gguf +3 -0
- glm-4-9b-cooking-assistant-v1-Q8_0.gguf +3 -0
- glm-4-9b-cooking-assistant-v1.imatrix.gguf +3 -0
- params +1 -0
- system +1 -0
- template +10 -0
.gitattributes
CHANGED
|
@@ -33,3 +33,8 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
| 36 |
+
glm-4-9b-cooking-assistant-v1-BF16.gguf filter=lfs diff=lfs merge=lfs -text
|
| 37 |
+
glm-4-9b-cooking-assistant-v1-Q4_K_M.gguf filter=lfs diff=lfs merge=lfs -text
|
| 38 |
+
glm-4-9b-cooking-assistant-v1-Q6_K.gguf filter=lfs diff=lfs merge=lfs -text
|
| 39 |
+
glm-4-9b-cooking-assistant-v1-Q8_0.gguf filter=lfs diff=lfs merge=lfs -text
|
| 40 |
+
glm-4-9b-cooking-assistant-v1.imatrix.gguf filter=lfs diff=lfs merge=lfs -text
|
LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
MIT License
|
| 2 |
+
|
| 3 |
+
Copyright (c) 2025 Zhipu AI
|
| 4 |
+
|
| 5 |
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
| 6 |
+
of this software and associated documentation files (the "Software"), to deal
|
| 7 |
+
in the Software without restriction, including without limitation the rights
|
| 8 |
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
| 9 |
+
copies of the Software, and to permit persons to whom the Software is
|
| 10 |
+
furnished to do so, subject to the following conditions:
|
| 11 |
+
|
| 12 |
+
The above copyright notice and this permission notice shall be included in all
|
| 13 |
+
copies or substantial portions of the Software.
|
| 14 |
+
|
| 15 |
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
| 16 |
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
| 17 |
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
| 18 |
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
| 19 |
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
| 20 |
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
| 21 |
+
SOFTWARE.
|
README.md
ADDED
|
@@ -0,0 +1,220 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: mit
|
| 3 |
+
base_model: HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant
|
| 4 |
+
base_model_relation: quantized
|
| 5 |
+
library_name: gguf
|
| 6 |
+
pipeline_tag: text-generation
|
| 7 |
+
language: [en, es, pt, it, fr, nl, de, ru, bn, id, fa, ja, pl, sv, vi, tl, he, ml, tr, zh, ms, th, fi, ar, ta, hi]
|
| 8 |
+
tags: [cooking, recipes, dpo, glm4, gguf, llama.cpp, provenance, abstention]
|
| 9 |
+
datasets: [HumanjavaEnterprises/cooking-assistant-eval]
|
| 10 |
+
---
|
| 11 |
+
|
| 12 |
+
# GLM-4-9B Cooking Assistant (GGUF)
|
| 13 |
+
|
| 14 |
+
A cooking assistant that reads the recipe you give it, and usually asks for the recipe instead of inventing details
|
| 15 |
+
when it can't see one. On questions that need a recipe it wasn't shown, it invents details 9.7% of the time vs
|
| 16 |
+
40.1% for base GLM-4-9B-0414; given the recipe, it answers correctly 96.2% of the time vs
|
| 17 |
+
83.1% (three open judges from other model families, 2 of 3 agreeing). General answers are not improved: on our 82 general cooking questions the full-precision model scored lower than the base (46.3% vs 56.1%; not statistically significant). Trained on 26 languages, evaluated in 21;
|
| 18 |
+
runs fully on an 8 GB GPU (Q4_K_M), or partly offloaded on 4 GB.
|
| 19 |
+
|
| 20 |
+
*Unofficial fine-tune of GLM-4-9B-0414 by Humanjava Enterprises; not made or endorsed by Zhipu AI / Z.ai.*
|
| 21 |
+
|
| 22 |
+
Files for llama.cpp, Ollama and LM Studio. Full-precision safetensors (Transformers, vLLM):
|
| 23 |
+
[HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant](https://huggingface.co/HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant).
|
| 24 |
+
The same recipe on Qwen3-8B:
|
| 25 |
+
[HumanjavaEnterprises/Qwen3-8B-Cooking-Assistant](https://huggingface.co/HumanjavaEnterprises/Qwen3-8B-Cooking-Assistant).
|
| 26 |
+
|
| 27 |
+
It does not memorise recipes: give it the recipe (paste it, or have your app look it up) and it will read it.
|
| 28 |
+
|
| 29 |
+
## Files
|
| 30 |
+
|
| 31 |
+
| File | Size | Use |
|
| 32 |
+
|---|---|---|
|
| 33 |
+
| `glm-4-9b-cooking-assistant-v1-Q4_K_M.gguf` **(default)** | 6.2 GB | 8 GB cards (6.0 GB used at 8k context, q8_0 KV cache); no significant loss against full precision on our checks |
|
| 34 |
+
| `glm-4-9b-cooking-assistant-v1-Q6_K.gguf` | 8.3 GB | 7.8 GB used at 8k context (q8_0 KV cache); no significant loss against full precision on our checks |
|
| 35 |
+
| `glm-4-9b-cooking-assistant-v1-Q8_0.gguf` | 10.0 GB | 10 GB cards and up; no significant loss against full precision on our checks |
|
| 36 |
+
| `glm-4-9b-cooking-assistant-v1-BF16.gguf` | 18.8 GB | full precision, for your own quantisation |
|
| 37 |
+
| `glm-4-9b-cooking-assistant-v1.imatrix.gguf` | 11 MB | importance matrix used for Q4_K_M and Q6_K |
|
| 38 |
+
|
| 39 |
+
Q4_K_M and Q6_K are built with an importance matrix computed on chat-formatted training conversations, stratified by
|
| 40 |
+
question type and by whether a recipe was shown; none of them is in the evaluation set. These files are larger than a Qwen3-8B file of the same name mostly because GLM-4-9B is larger (9.4B parameters;
|
| 41 |
+
the BF16 and Q8_0 files are about 1.15 times Qwen3-8B's). On top of that, GLM-4-9B's feed-forward width does not fit
|
| 42 |
+
the k-quant block size, so llama.cpp stores some down-projection tensors at higher precision (in Q4_K_M, 20 as Q8_0
|
| 43 |
+
and 20 as Q5_0; in Q6_K, all 40 as Q8_0), which adds about 0.4 GB to Q4_K_M.
|
| 44 |
+
Checksums: `SHA256SUMS`.
|
| 45 |
+
|
| 46 |
+
## Quick start
|
| 47 |
+
|
| 48 |
+
```bash
|
| 49 |
+
# llama.cpp
|
| 50 |
+
llama-server -hf HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-GGUF:Q4_K_M --jinja -c 8192
|
| 51 |
+
|
| 52 |
+
# Ollama
|
| 53 |
+
ollama run vveerrgg/glm-4-9b-cooking-assistant
|
| 54 |
+
# or: ollama run hf.co/HumanjavaEnterprises/GLM-4-9B-Cooking-Assistant-GGUF:Q4_K_M (template, system prompt and settings ship in this repo)
|
| 55 |
+
```
|
| 56 |
+
|
| 57 |
+
## Versions
|
| 58 |
+
|
| 59 |
+
The model is one product with dated versions. Each version is a git tag on this repo, so you can pin one with
|
| 60 |
+
`revision="v1"` (Transformers / huggingface_hub) or `ollama run vveerrgg/glm-4-9b-cooking-assistant:v1`.
|
| 61 |
+
|
| 62 |
+
| Version | Date | Invents (no recipe, 2 of 3 judges) | Correct (recipe shown, 2 of 3 judges) | Notes |
|
| 63 |
+
|---|---|---|---|---|
|
| 64 |
+
| **v1** (current) | 2026-11-14 | 9.7% (base 40.1%) | 96.2% (base 83.1%) | first public release |
|
| 65 |
+
|
| 66 |
+
## Prompt format
|
| 67 |
+
|
| 68 |
+
GLM-4-0414 chat template, embedded in every file (`[gMASK]<sop>`, then `<|system|>`, `<|user|>`, `<|assistant|>` turns;
|
| 69 |
+
a turn ends at `<|user|>`). There is no thinking mode. Ollama does not read the embedded template: use the `template`,
|
| 70 |
+
`system` and `params` files in this repo (the `hf.co/...` path does) or the library tag above. Trained with this system prompt, which works best:
|
| 71 |
+
|
| 72 |
+
```
|
| 73 |
+
You are a cooking assistant. You answer questions about dishes, ingredients, techniques and food safety. When you are not sure, you say so.
|
| 74 |
+
```
|
| 75 |
+
|
| 76 |
+
To ask about a specific recipe, put the recipe text in the user turn, then the question.
|
| 77 |
+
|
| 78 |
+
## What it does
|
| 79 |
+
|
| 80 |
+
The fine-tune teaches **behaviour, not facts**:
|
| 81 |
+
|
| 82 |
+
- **Reads the recipe you give it.** Paste a recipe and ask about it; it answers from that text.
|
| 83 |
+
- **Usually asks when the recipe is missing.** "If I double the recipe, how much pepper?" with no recipe gets a request
|
| 84 |
+
for the original quantity; it may add a typical range, marked as typical, but not a number presented as the recipe's.
|
| 85 |
+
- **Answers general cooking questions:** food safety, substitutions, why a dish failed. On our general questions it
|
| 86 |
+
does not beat the base model (see Results).
|
| 87 |
+
|
| 88 |
+
The intended setup is **LoRA for behaviour, retrieval for facts, tools for numbers**: an app looks up the recipe and
|
| 89 |
+
hands it to the model; scaling and unit conversion are calculated, not guessed.
|
| 90 |
+
|
| 91 |
+
It is the second model built with the recipe behind
|
| 92 |
+
[Qwen3-8B Cooking Assistant](https://huggingface.co/HumanjavaEnterprises/Qwen3-8B-Cooking-Assistant): the same training
|
| 93 |
+
data and the same two stages on a different base model family, scored on the same questions.
|
| 94 |
+
|
| 95 |
+
## Results
|
| 96 |
+
|
| 97 |
+
All cooking scores are on the fixed held-out set of 682 questions in 21 languages behind the Qwen3-8B Cooking Assistant
|
| 98 |
+
card, never used in training: 290 with the recipe shown, 10 recall questions with no recipe ("how do you make X?"), 300
|
| 99 |
+
that need a recipe the model is not shown, and 82 general questions. Answers from base GLM-4-9B-0414 and this model
|
| 100 |
+
were scored one at a time by open-weights judges, blind to which model wrote them. None of the headline judges is from
|
| 101 |
+
the GLM or the Qwen family: DeepSeek-V4-Flash (MIT), gpt-oss-120b (Apache-2.0) and Seed-OSS-36B-Instruct (Apache-2.0).
|
| 102 |
+
A rule check removes "invents" verdicts on answers whose every detail was already in the question. 95% confidence
|
| 103 |
+
intervals in brackets.
|
| 104 |
+
|
| 105 |
+
| counted as "invents" when | GLM-4-9B-0414 | this model |
|
| 106 |
+
|---|---|---|
|
| 107 |
+
| at least 2 of 3 judges say so | 40.1% [34.7, 45.8] | **9.7%** [6.8, 13.6] |
|
| 108 |
+
| all three say so | 28.1% | 3.7% |
|
| 109 |
+
| any one says so | 58.9% | 27.1% |
|
| 110 |
+
|
| 111 |
+
(299 of the 300 answers per column count: one base and one model answer lack a verdict from one judge.)
|
| 112 |
+
|
| 113 |
+
2 of 3: 104 questions where only the base invents, 13 where only this model does
|
| 114 |
+
(McNemar p < 1e-18).
|
| 115 |
+
|
| 116 |
+
The same judges on the questions where the recipe **is** shown and the model has to read it (290 questions; 2 of 3
|
| 117 |
+
must agree): GLM-4-9B-0414 correct 83.1% [78.4, 87.0], this model **96.2%**
|
| 118 |
+
[93.3, 97.9] (42 questions only this model gets right, 4 only the base
|
| 119 |
+
does, McNemar p < 1e-8). Two other kinds of question in the set are reported apart: 82 general questions graded
|
| 120 |
+
against a reference answer (56.1% base, 46.3% this model: lower, but not significantly, McNemar p = 0.12 with 14
|
| 121 |
+
questions only the base gets right and 6 only this model; see the quantised files below) and
|
| 122 |
+
10 "how do you make X?" questions with no recipe whose reference is the original 1800s text (20.0% /
|
| 123 |
+
10.0%: the model is built not to recall historical recipes from memory).
|
| 124 |
+
|
| 125 |
+
**A fourth judge.** Qwen3.8-27B (Apache-2.0) also scored every answer. It is a Qwen-family model and wrote the training
|
| 126 |
+
questions, so it is not independent of the training data and is kept out of the headline. With all four judges and 3
|
| 127 |
+
of 4 agreeing: invents 30.1% (base) vs **4.7%**; correct with the recipe shown
|
| 128 |
+
78.6% vs **95.5%**.
|
| 129 |
+
|
| 130 |
+
**Next to the Qwen3-8B sibling** (same questions, same three judges, both models' answers generated the same way):
|
| 131 |
+
|
| 132 |
+
| | invents, no recipe (2 of 3) | correct, recipe shown (2 of 3) |
|
| 133 |
+
|---|---|---|
|
| 134 |
+
| Qwen3-8B → Qwen3-8B Cooking Assistant v1 | 43.0% → 10.3% | 85.9% → 95.5% |
|
| 135 |
+
| GLM-4-9B-0414 → this model | 40.1% → 9.7% | 83.1% → 96.2% |
|
| 136 |
+
|
| 137 |
+
(The Qwen card's own figures come from a four-judge panel that included GLM-4.7-Flash, so they differ from this row.)
|
| 138 |
+
|
| 139 |
+
Model judges tend to make the same mistakes as each other, so three agreeing is less than three independent checks.
|
| 140 |
+
On the no-recipe questions the judges agree less about this model's answers than about the base's (Fleiss kappa 0.33
|
| 141 |
+
vs 0.58).
|
| 142 |
+
|
| 143 |
+
**Quantised files** were scored on the same 682 questions against the full-precision model, same judges:
|
| 144 |
+
|
| 145 |
+
| | Q4_K_M | Q6_K | Q8_0 |
|
| 146 |
+
|---|---|---|---|
|
| 147 |
+
| Invents with no recipe, 2 of 3 judges (full precision) | 10.7% (8.7%) | 11.7% (9.3%) | 9.4% (10.0%) |
|
| 148 |
+
| Correct when the recipe is shown, 2 of 3 judges (full precision) | 95.5% (95.9%) | 95.5% (96.2%) | 95.9% (96.2%) |
|
| 149 |
+
| Difference significant? (McNemar, inventing) | no, p = 0.26 | no, p = 0.14 | no, p = 0.77 |
|
| 150 |
+
|
| 151 |
+
With the three headline judges, no quantised file differs significantly from full precision on inventing (p ≥ 0.14) or on reading a shown recipe (p ≥ 0.5). On the 82 general questions every quantised file scored higher than full precision: Q4_K_M 54.9% vs 46.3% (p = 0.039), Q6_K 53.7% vs 47.6% (p = 0.27), Q8_0 56.1% vs 47.6% (p = 0.065). The full-precision answers are the same text in every comparison; only the judging was re-run for each file, which alone moves their scores by up to 1.3 points. The quantised answers come from llama.cpp and the full-precision ones from vLLM, so the full-precision model's lower general score may be partly a serving or decoding effect (one of three differences has p < 0.05, none after correcting for three comparisons); not settled.
|
| 152 |
+
|
| 153 |
+
**Memorisation.** Training documents from the Wikibooks Cookbook (CC BY-SA) were probed with prefixes of 32 to 128 tokens at several offsets, as raw text and as chat prompts, with greedy decoding. The model never continues a document verbatim (no 50-token match; longest overlap 89 characters, the same as base GLM-4-9B-0414), and its overlap with the true text is no higher than the base's (ROUGE-L 0.158 vs 0.161).
|
| 154 |
+
|
| 155 |
+
## How it was built
|
| 156 |
+
|
| 157 |
+
| | |
|
| 158 |
+
|---|---|
|
| 159 |
+
| Sources | Cooking texts in 26 languages from openly licensed and public-domain sources only: the Wikibooks Cookbook (CC BY-SA 4.0), public-domain cookbooks from Project Gutenberg and the Internet Archive (scans re-read with olmOCR-2), and NHLBI recipes (US government, public domain). Every record carries its source URL, licence and public-domain basis |
|
| 160 |
+
| Excluded | Traditional and Indigenous knowledge, sacred material, outsider-authored books about other cultures, dog-meat recipes, anything without a verified licence |
|
| 161 |
+
| Models used | Open-weights models only, all Apache-2.0 or MIT. **No output from any closed or API model is in the training, evaluation or seed data** |
|
| 162 |
+
| Training | The training data and both stages of Qwen3-8B Cooking Assistant v1, unchanged, on GLM-4-9B-0414: two LoRA stages, each merged: a supervised stage that teaches reading a shown recipe, asking when there is none, and full general answers; then a preference stage that favours asking over inventing and correct over wrong. General chat data is mixed in to limit forgetting |
|
| 163 |
+
| Tooling | LLaMA-Factory, vLLM, llama.cpp |
|
| 164 |
+
|
| 165 |
+
The evaluation set behind every number on this card (all 682 questions, both models' answers, every judge's verdict,
|
| 166 |
+
and per-row source credits) is published so the results can be checked:
|
| 167 |
+
[HumanjavaEnterprises/cooking-assistant-eval](https://huggingface.co/datasets/HumanjavaEnterprises/cooking-assistant-eval),
|
| 168 |
+
config `glm-4-9b-v1`.
|
| 169 |
+
|
| 170 |
+
## What carried over, and what did not
|
| 171 |
+
|
| 172 |
+
- **The data was written for the Qwen model.** Part of the general answers were rewritten by base Qwen3-8B (for the
|
| 173 |
+
Qwen model, its own words), and the preference stage uses answer pairs sampled from the Qwen model, not from this
|
| 174 |
+
one. Both were kept unchanged so that only the base model differs; for GLM-4-9B-0414 they are another model's words.
|
| 175 |
+
- **The two cooking behaviours carried over.** On inventing and on reading a shown recipe this model shows no significant difference from Qwen3-8B Cooking Assistant v1 under the same judges (McNemar p = 0.86 and 0.80). **General answers did not:** where the Qwen model stayed level with its base, this model's full-precision score fell below GLM-4-9B-0414's (not significant; see Results).
|
| 176 |
+
|
| 177 |
+
## Limitations
|
| 178 |
+
|
| 179 |
+
- **Not a source of truth for food safety.** It repeats standard guidance (e.g. 74 °C / 165 °F for poultry) but can be
|
| 180 |
+
wrong; check official sources.
|
| 181 |
+
- **It does not know historical recipes by heart.** It was trained on old cookbooks to read and reason about recipes,
|
| 182 |
+
not to recall them. For a specific historical dish, give it the text.
|
| 183 |
+
- The judges are models. Three open judges from three other families agree on the direction of the changes,
|
| 184 |
+
and we keep checking them against people with Label Test, our blind labelling tool. **Help refine it:** label five
|
| 185 |
+
answers at [label-test.humanjava.com](https://label-test.humanjava.com/?s=cook4&k=cook-9ac741a1e387&src=hf-gguf-glm) (no account; we keep only a name or initials and your labels).
|
| 186 |
+
- Still invents on some no-recipe questions: about 1 in 10 when two of three judges must agree (9.7%), nearly 1 in 4 by the strictest single judge (22.7%).
|
| 187 |
+
- **General answers are not improved.** On 82 general questions the full-precision model scored 46.3% vs the base's 56.1% (not significant, p = 0.12); the quantised files scored 54-56% on the same questions (not compared against the base), so the gap may be partly a serving or decoding effect (one of three differences has p < 0.05, none after correcting for three comparisons); not settled.
|
| 188 |
+
- Best in English and Spanish: it invents on 6.9% and 3.8% of the no-recipe questions there, 12.6% across the other
|
| 189 |
+
languages together (2 of 3 judges).
|
| 190 |
+
- The old public-domain cookbooks reflect their era: measures, techniques, some outdated advice.
|
| 191 |
+
|
| 192 |
+
## Feedback and security
|
| 193 |
+
|
| 194 |
+
- **The model got something wrong** (invented a detail, misread a recipe, unsafe advice): please
|
| 195 |
+
[open a report](https://github.com/HumanjavaEnterprises/glm-4-9b-cooking-assistant/issues/new?template=wrong-answer.yml).
|
| 196 |
+
Real examples are what improve the next version.
|
| 197 |
+
- **Help measure it:** [label five answers](https://label-test.humanjava.com/?s=cook4&k=cook-9ac741a1e387&src=hf-gguf-glm) on Label Test.
|
| 198 |
+
- **Security** (files that don't match `SHA256SUMS`, unexpected embedded content): report privately, see
|
| 199 |
+
[SECURITY.md](https://github.com/HumanjavaEnterprises/glm-4-9b-cooking-assistant/blob/main/SECURITY.md).
|
| 200 |
+
|
| 201 |
+
## Licence and credits
|
| 202 |
+
|
| 203 |
+
Weights: MIT, same as the base model. Base model: GLM-4-9B-0414 by Zhipu AI / Z.ai (MIT); its copyright and permission
|
| 204 |
+
notice is kept in `LICENSE`:
|
| 205 |
+
|
| 206 |
+
> Copyright (c) 2025 Zhipu AI. Permission is hereby granted, free of charge, to any person obtaining a copy of this
|
| 207 |
+
> software and associated documentation files (the "Software"), to deal in the Software without restriction [...]
|
| 208 |
+
> The above copyright notice and this permission notice shall be included in all copies or substantial portions of
|
| 209 |
+
> the Software. (Full text in `LICENSE`.)
|
| 210 |
+
|
| 211 |
+
Training data sources: Wikibooks Cookbook contributors (CC BY-SA 4.0; per-page attribution in the dataset), Project
|
| 212 |
+
Gutenberg and Internet Archive public-domain books, NHLBI. General chat data: NVIDIA
|
| 213 |
+
(Nemotron-Instruction-Following-Chat-v1, ODC-BY 1.0, responses by GPT-OSS-120B and Qwen3-235B-A22B), Hugging Face
|
| 214 |
+
(SmolTalk2, Apache-2.0, responses by Qwen3-32B; prompts from SystemChat-2.0, the Aya Dataset by Cohere For AI, and
|
| 215 |
+
Table-GPT by Microsoft). Teacher: Qwen3.8-27B (Apache-2.0). Rewritten general answers: Qwen3-8B (Apache-2.0).
|
| 216 |
+
Preference-stage answers: Qwen3-8B Cooking Assistant (Apache-2.0). Judges: DeepSeek-V4-Flash (MIT), gpt-oss-120b
|
| 217 |
+
(Apache-2.0), Seed-OSS-36B-Instruct by ByteDance Seed (Apache-2.0), Qwen3.8-27B (Apache-2.0). OCR: olmOCR-2 by Ai2
|
| 218 |
+
(Apache-2.0). Training: LLaMA-Factory. Quantisation: llama.cpp.
|
| 219 |
+
|
| 220 |
+
Built by [Humanjava Enterprises](https://huggingface.co/HumanjavaEnterprises).
|
SHA256SUMS
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
7b8382facf3852614641d35709bfa935a77a678d0d5b8f2f8308658d28805f70 ./glm-4-9b-cooking-assistant-v1-BF16.gguf
|
| 2 |
+
bb34f10b7bb7e59257b3f877538be6581c98f8a436653c063b0652dc3d01d306 ./glm-4-9b-cooking-assistant-v1.imatrix.gguf
|
| 3 |
+
5cadc80275fa5e4ae4b2d82b123963bcbc20d9c03c00a401b789510b460c6eac ./glm-4-9b-cooking-assistant-v1-Q4_K_M.gguf
|
| 4 |
+
42bcc552f7d53808abc0641f3dbdf62254ec792cb04d0e02b1c26e650cc0a228 ./glm-4-9b-cooking-assistant-v1-Q6_K.gguf
|
| 5 |
+
966b7413b1fc1906c45f98a140e6cd55cbf814e586ad019c21bcf218362736ff ./glm-4-9b-cooking-assistant-v1-Q8_0.gguf
|
glm-4-9b-cooking-assistant-v1-BF16.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:7b8382facf3852614641d35709bfa935a77a678d0d5b8f2f8308658d28805f70
|
| 3 |
+
size 18811581536
|
glm-4-9b-cooking-assistant-v1-Q4_K_M.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:5cadc80275fa5e4ae4b2d82b123963bcbc20d9c03c00a401b789510b460c6eac
|
| 3 |
+
size 6166574400
|
glm-4-9b-cooking-assistant-v1-Q6_K.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:42bcc552f7d53808abc0641f3dbdf62254ec792cb04d0e02b1c26e650cc0a228
|
| 3 |
+
size 8266642752
|
glm-4-9b-cooking-assistant-v1-Q8_0.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:966b7413b1fc1906c45f98a140e6cd55cbf814e586ad019c21bcf218362736ff
|
| 3 |
+
size 9999610976
|
glm-4-9b-cooking-assistant-v1.imatrix.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:bb34f10b7bb7e59257b3f877538be6581c98f8a436653c063b0652dc3d01d306
|
| 3 |
+
size 11017312
|
params
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"stop": ["<|user|>", "<|observation|>", "<|endoftext|>"], "temperature": 0.7, "top_p": 0.8, "top_k": 20, "num_ctx": 8192}
|
system
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
You are a cooking assistant. You answer questions about dishes, ingredients, techniques and food safety. When you are not sure, you say so.
|
template
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
[gMASK]<sop>
|
| 2 |
+
{{- range .Messages }}
|
| 3 |
+
{{- if eq .Role "system" }}<|system|>
|
| 4 |
+
{{ .Content }}
|
| 5 |
+
{{- else if eq .Role "user" }}<|user|>
|
| 6 |
+
{{ .Content }}
|
| 7 |
+
{{- else if eq .Role "assistant" }}<|assistant|>
|
| 8 |
+
{{ .Content }}
|
| 9 |
+
{{- end }}
|
| 10 |
+
{{- end }}<|assistant|>
|