Downloads · 30 days
19
3% of all-time downloads
SirSahOl/glm-edge-1.5b-chat-mlx-16bit
glm-edge-1.5b-chat-mlx-16bit is a text generation model from SirSahOl. Use it when you need the model to write or continue text. It is set up for mlx. The card lists the license as other.
This repository contains Zhipu AI's GLM-Edge-1.5B-Chat in its original unquantized 16-bit float (bfloat16) precision. It is compiled natively for Apple Silicon under the MLX framework.
Downloads · 30 days
19
3% of all-time downloads
All-time downloads
758
Public
Parameters
1.5B
2.9 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors2.9 GB · 100%
From the Hugging Face model README
This repository contains Zhipu AI's GLM-Edge-1.5B-Chat in its original unquantized 16-bit float (bfloat16) precision. It is compiled natively for Apple Silicon under the MLX framework.
16-bit precision operates with 0% quantization loss. It preserves the exact mathematical weights of the original model.
Install the MLX LM package.
pip install mlx-lm
Chat with the model in your terminal.
mlx_lm.chat --model SirSahOl/glm-edge-1.5b-chat-mlx-16bit
Load and generate text programmatically.
from mlx_lm import load, generate
model, tokenizer = load("SirSahOl/glm-edge-1.5b-chat-mlx-16bit")
messages = [{"role": "user", "content": "Explain quantum superposition."}]
prompt = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
response = generate(model, tokenizer, prompt=prompt, verbose=True)
Evaluate your hardware budget and choose the optimal precision:
| Variant | Disk Size | VRAM Footprint | M1 Speed | Key Advantage |
|---|---|---|---|---|
| 4-bit MLX | ~800 MB | ~0.87 GB | ~72.5 tokens/sec | Maximum speed, lowest RAM. |
| 8-bit MLX | ~1.56 GB | ~1.56 GB | ~48.5 tokens/sec | Lossless balance, highly stable reasoning. |
| 16-bit MLX (This Repo) | ~2.94 GB | ~3.00 GB | ~32.5 tokens/sec | Raw full-precision, absolute peak quality. |
If you load this model in LM Studio, you must configure custom Stop Strings to prevent the model from entering an infinite self-dialogue loop.
You can create a custom prompt preset to configure all settings automatically. Create a JSON file named GLM-Edge.json inside your LM Studio config directory:
~/.lmstudio/config-presets/GLM-Edge.json%USERPROFILE%\.lmstudio\config-presets\GLM-Edge.jsonAdd the following JSON content:
{
"name": "GLM-Edge",
"inference_params": {
"pre_prompt": "You are a helpful, direct, and honest assistant.",
"input_prefix": "<|user|>\n",
"input_suffix": "\n<|assistant|>\n",
"pre_prompt_prefix": "<|system|>\n",
"pre_prompt_suffix": "\n",
"antiprompt": [
"<|user|>",
"<|observation|>",
"<|endoftext|>"
],
"stopStrings": [
"<|user|>",
"<|observation|>",
"<|endoftext|>"
],
"temperature": 0.7,
"max_tokens": 2048
}
}
Restart LM Studio, open a Chat session, and select "GLM-Edge" from the Prompt Template dropdown.
Alternatively, configure the settings manually in the Advanced Configuration sidebar:
<|user|>, <|observation|>, and <|endoftext|><|user|>\n\n<|assistant|>\n<|system|>\n\n