From: zai-org <huggingface.co/zai-org>Newsgroups: alt.freeweights.glmSubject:

GLM-Image

Date: 2026-11-14Commit: 2c433ccSigned: 2DC28CC7B26A283B ✓

Text to image model with 6.9B parameters. Safetensors weights, 35.8 GB in all. Published by zai-org under MIT.

6.9B params35.8GBGLM-Imagesafetensorspermissive
FactsParams6.9BSize35.8 GBFormatssafetensorsTasktext to imageLicenseMITFrom sourcepermissive
$ fw get zai-org/GLM-Image
# manifest sha256 39b77f12f421… · 35.8 GB · 27 files
$ fw verify ./GLM-Image zai-org/GLM-Image
From sourceHosted (signed)zai-org/GLM-ImageLast check: 2026-11-14 21:26 UTC

Get help: custom fine-tune or private deploy. We review your setup before we quote.

Works with

Overview

Size
35.8 GB
Weights
35.8 GB (safetensors)
Parameters
6.9B
Formats
safetensors
Task
text to image
License
MIT (permissive)
Files
27, each with a sha256
Publisher
zai-org
Added
2026-11-14
Section
alt.freeweights.glm
Lineage

Original release from the publisher.

Where these bytes come from
Publisher at the pinned commit→You

Sources are tried in order. A file counts only when its size and sha256 match the manifest. Sources are checked when you ask for them, not on a timer.

Sources
BadgeHostLast checkResult
From sourcehuggingface.co2026-11-14 21:26 UTCpassed

Model card

From the publisher at commit 2c433cc. Shown as plain text with links; images open at the publisher.

GLM-Image#

Image: image

👋 Join our WeChat and Discord community

📖 Check out GLM-Image's Technical Blog and Github

📍 Use GLM-Image's API

Image: show_case

Introduction#

GLM-Image is an image generation model adopts a hybrid autoregressive + diffusion decoder architecture. In general image generation quality, GLM‑Image aligns with mainstream latent diffusion approaches, but it shows significant advantages in text-rendering and knowledge‑intensive generation scenarios. It performs especially well in tasks requiring precise semantic understanding and complex information expression, while maintaining strong capabilities in high‑fidelity and fine‑grained detail generation. In addition to text‑to‑image generation, GLM‑Image also supports a rich set of image‑to‑image tasks including image editing, style transfer, identity‑preserving generation, and multi‑subject consistency.

Model architecture: a hybrid autoregressive + diffusion decoder design.

Image: architecture_1

  • Autoregressive generator: a 9B-parameter model initialized from GLM-4-9B-0414, with an expanded vocabulary to incorporate visual tokens. The model first generates a compact encoding of approximately 256 tokens, then expands to 1K–4K tokens, corresponding to 1K–2K high-resolution image outputs.
  • Diffusion Decoder: a 7B-parameter decoder based on a single-stream DiT architecture for latent-space image decoding. It is equipped with a Glyph Encoder text module, significantly improving accurate text rendering within images.

Image: architecture_2

Post-training with decoupled reinforcement learning: the model introduces a fine-grained, modular feedback strategy using the GRPO algorithm, substantially enhancing both semantic understanding and visual detail quality.

  • Autoregressive module: provides low-frequency feedback signals focused on aesthetics and semantic alignment, improving instruction following and artistic expressiveness.
  • Decoder module: delivers high-frequency feedback targeting detail fidelity and text accuracy, resulting in highly realistic textures as well as more precise text rendering.

GLM-Image supports both text-to-image and image-to-image generation within a single model.

  • Text-to-image: generates high-detail images from textual descriptions, with particularly strong performance in information-dense scenarios.
  • Image-to-image: supports a wide range of tasks, including image editing, style transfer, multi-subject consistency, and identity-preserving generation for people and objects.

You can find the full GLM-Image Model implementation in the transformers and diffusers libraries here.

Showcase#

T2I with dense text and knowledge#

Image: show_case_t2i

I2I#

Image: show_case_i2i

Quick Start#

transformers + diffusers Pipeline#

Install transformers and diffusers from source:

pip install git+https://github.com/huggingface/transformers.git
pip install git+https://github.com/huggingface/diffusers.git
  • Text to Image Generation
import torch
from diffusers.pipelines.glm_image import GlmImagePipeline

pipe = GlmImagePipeline.from_pretrained("zai-org/GLM-Image", torch_dtype=torch.bfloat16, device_map="cuda")
prompt = "A beautifully designed modern food magazine style dessert recipe illustration, themed around a raspberry mousse cake. The overall layout is clean and bright, divided into four main areas: the top left features a bold black title 'Raspberry Mousse Cake Recipe Guide', with a soft-lit close-up photo of the finished cake on the right, showcasing a light pink cake adorned with fresh raspberries and mint leaves; the bottom left contains an ingredient list section, titled 'Ingredients' in a simple font, listing 'Flour 150g', 'Eggs 3', 'Sugar 120g', 'Raspberry puree 200g', 'Gelatin sheets 10g', 'Whipping cream 300ml', and 'Fresh raspberries', each accompanied by minimalist line icons (like a flour bag, eggs, sugar jar, etc.); the bottom right displays four equally sized step boxes, each containing high-definition macro photos and corresponding instructions, arranged from top to bottom as follows: Step 1 shows a whisk whipping white foam (with the instruction 'Whip egg whites to stiff peaks'), Step 2 shows a red-and-white mixture being folded with a spatula (with the instruction 'Gently fold in the puree and batter'), Step 3 shows pink liquid being poured into a round mold (with the instruction 'Pour into mold and chill for 4 hours'), Step 4 shows the finished cake decorated with raspberries and mint leaves (with the instruction 'Decorate with raspberries and mint'); a light brown information bar runs along the bottom edge, with icons on the left representing 'Preparation time: 30 minutes', 'Cooking time: 20 minutes', and 'Servings: 8'. The overall color scheme is dominated by creamy white and light pink, with a subtle paper texture in the background, featuring compact and orderly text and image layout with clear information hierarchy."
image = pipe(
    prompt=prompt,
    height=32 * 32,
    width=36 * 32,
    num_inference_steps=50,
    guidance_scale=1.5,
    generator=torch.Generator(device="cuda").manual_seed(42),
).images[0]

image.save("output_t2i.png")
  • Image to Image Generation
import torch
from diffusers.pipelines.glm_image import GlmImagePipeline
from PIL import Image

pipe = GlmImagePipeline.from_pretrained("zai-org/GLM-Image", torch_dtype=torch.bfloat16, device_map="cuda")
image_path = "cond.jpg"
prompt = "Replace the background of the snow forest with an underground station featuring an automatic escalator."
image = Image.open(image_path).convert("RGB")
image = pipe(
    prompt=prompt,
    image=[image],  # can input multiple images for multi-image-to-image generation such as [image, image1]
    height=33 * 32, # Must set height even it is same as input image
    width=32 * 32, # Must set width even it is same as input image
    num_inference_steps=50,
    guidance_scale=1.5,
    generator=torch.Generator(device="cuda").manual_seed(42),
).images[0]

image.save("output_i2i.png")
SGLang Pipeline#

Install transformers and diffusers from source:

pip install "sglang[diffusion] @ git+https://github.com/sgl-project/sglang.git#subdirectory=python"
pip install git+https://github.com/huggingface/transformers.git
pip install git+https://github.com/huggingface/diffusers.git
  • Text to Image Generation
sglang serve --model-path zai-org/GLM-Image

curl http://localhost:30000/v1/images/generations \
  -H "Content-Type: application/json" \
  -d '{
    "model": "zai-org/GLM-Image",
    "prompt": "a beautiful girl with glasses.",
    "n": 1,
    "response_format": "b64_json",
    "size": "1024x1024"
  }' |  python3 -c "import sys, json, base64; open('output_t2i.png', 'wb').write(base64.b64decode(json.load(sys.stdin)['data'][0]['b64_json']))"
  • Image to Image Generation
sglang serve --model-path zai-org/GLM-Image

curl -s -X POST "http://localhost:30000/v1/images/edits" \
-F "model=zai-org/GLM-Image" \
-F "image=@cond.jpg" \
-F "prompt=Replace the background of the snow forest with an underground station featuring an automatic escalator." \
-F "response_format=b64_json"  | python3 -c "import sys, json, base64; open('output_i2i.png', 'wb').write(base64.b64decode(json.load(sys.stdin)['data'][0]['b64_json']))"
Note#
  • Please ensure that all text intended to be rendered in the image is enclosed in quotation marks in the model input and We strongly recommend using GLM-4.7 to enhance prompts for higher image quality. Please check our github script for more details.
  • The AR model used in GLM‑Image is configured with do_sample=True, a temperature of 0.9, and a topp of 0.75 by default. A higher temperature results in more diverse and rich outputs, but it can also lead to a certain decrease in output stability.
  • The target image resolution must be divisible by 32. Otherwise, it will throw an error.
  • Because inference optimizations for this architecture are currently limited, the runtime cost is still relatively high. You can set enable_model_cpu_offload=True to run it with ~23GB of GPU memory, at the cost of slower inference.
  • vLLM-Omni and SGLang (with AR speedup) support is currently being integrated — stay tuned. For inference cost, you can check in our github.

Model Performance#

Text Rendering#

| Model | Open Source | CVTG-2K | LongText-Bench

| Word Accuracy | NED | CLIPScore | AVG | EN | ZH

| Seedream 4.5 | ✗ | 0.8990 | 0.9483 | 0.8069 | 0.988 | 0.989 | 0.987

| Seedream 4.0 | ✗ | 0.8451 | 0.9224 | 0.7975 | 0.924 | 0.921 | 0.926

| Nano Banana 2.0 | ✗ | 0.7788 | 0.8754 | 0.7372 | 0.965 | 0.981 | 0.949

| GPT Image 1 [High] | ✗ | 0.8569 | 0.9478 | 0.7982 | 0.788 | 0.956 | 0.619

| Qwen-Image | ✓ | 0.8288 | 0.9116 | 0.8017 | 0.945 | 0.943 | 0.946

| Qwen-Image-2512 | ✓ | 0.8604 | 0.9290 | 0.7819 | 0.961 | 0.956 | 0.965

| Z-Image | ✓ | 0.8671 | 0.9367 | 0.7969 | 0.936 | 0.935 | 0.936

| Z-Image-Turbo | ✓ | 0.8585 | 0.9281 | 0.8048 | 0.922 | 0.917 | 0.926

| GLM-Image | ✓ | 0.9116 | 0.9557 | 0.7877 | 0.966 | 0.952 | 0.979

Text-to-Image#

| Model | Open Source | OneIG-Bench | TIIF-Bench | DPG-Bench

| EN | ZH | short | long

| Seedream 4.5 | ✗ | 0.576 | 0.551 | 90.49 | 88.52 | 88.63

| Seedream 4.0 | ✗ | 0.576 | 0.553 | 90.45 | 88.08 | 88.54

| Nano Banana 2.0 | ✗ | 0.578 | 0.567 | 91.00 | 88.26 | 87.16

| GPT Image 1 [High] | ✗ | 0.533 | 0.474 | 89.15 | 88.29 | 85.15

| DALL-E 3 | ✗ | - | - | 74.96 | 70.81 | 83.50

| Qwen-Image | ✓ | 0.539 | 0.548 | 86.14 | 86.83 | 88.32

| Qwen-Image-2512 | ✓ | 0.530 | 0.515 | 83.24 | 84.93 | 87.20

| Z-Image | ✓ | 0.546 | 0.535 | 80.20 | 83.01 | 88.14

| Z-Image-Turbo | ✓ | 0.528 | 0.507 | 77.73 | 80.05 | 84.86

| FLUX.1 [Dev] | ✓ | 0.434 | - | 71.09 | 71.78 | 83.52

| SD3 Medium | ✓ | - | - | 67.46 | 66.09 | 84.08

| SD XL | ✓ | 0.316 | - | 54.96 | 42.13 | 74.65

| BAGEL | ✓ | 0.361 | 0.370 | 71.50 | 71.70 | -

| Janus-Pro | ✓ | 0.267 | 0.240 | 66.50 | 65.01 | 84.19

| Show-o2 | ✓ | 0.308 | - | 59.72 | 58.86 | -

| GLM-Image | ✓ | 0.528 | 0.511 | 81.01 | 81.02 | 84.78

License#

The overall GLM-Image model is released under the MIT License.

This project incorporates the VQ tokenizer weights and VIT weights from X-Omni/X-Omni-En, which are licensed under the Apache License, Version 2.0.

The VQ tokenizer and VIT weights remains subject to the original Apache-2.0 terms. Users should comply with the respective licenses when using this component.

Files

27 files · 35.8 GBWeights 35.8 GB (safetensors). Sizes and sha256 from the signed manifest.
Show all 27 files with their sha256
FileSizesha256
.gitattributes1.58 KB2159b96f67a348657f1224be06c151b4a3202ad865cbb4723a61f1f49baa736f
README.md31.3 KBfc5861c29cda8b542b0f258a55d9bb8b44d56e9592a021c74f4eeebf7a159ce0
model_index.json619 B67b2c0934a43c6821c7862b1999fc10f7d7a1b9b89ccb3a01bd908a46e8035f2
processor/chat_template.jinja435 Bfc5ffeb5867c85630da91cca05db7c46167189d7f6066a615d435e4ec3154a57
processor/preprocessor_config.json431 Bbc8b8af6f487435d02a32e8ea4996493457a5ac94f85c16f546ec45ba95f20a5
processor/tokenizer.json23.8 MB7626ee04802e81cadec0dbb983f2278aa24240b3b5c86a0b7831199ef25c6652
processor/tokenizer_config.json4.93 KB5b212b0fa405480adc080ba1af5b9c5365e54b65d20d65277a93c8178fca5aeb
scheduler/scheduler_config.json482 Bed2f73067894ed3d8d9341036ceb7607ad9df1753bd4a0b15ed7cf1c528f758e
text_encoder/config.json781 Bf63c1c853b48d04e6b4ed28911a320ab8cdd8333399a08571053303eec567411
text_encoder/model.safetensors871 MBaa1ce00ffb0fe8912dfe32c11ba235b87511604298b605ef95314668a02f2bbf
tokenizer/added_tokens.json3.02 KB0004781309423057d33b9edf50d2669253d4347873ea33d4e7755cb866f23883
tokenizer/special_tokens_map.json3.09 KB3c2572df5f4ec60a476e5d90a1f52a989f9eefbbf381d358924a44a648bf0edb
tokenizer/tokenizer_config.json25.6 KB3be33c710b17ac8686cd2b82ec044b0cd1122ff92c651d7170bfe1af8256ebfb
transformer/config.json349 Bed79f81e11e9e485580c8ede7b7a09c8fb6811f5ac0ae4ce748acf6804aa97a0
transformer/diffusion_pytorch_model-00001-of-00003.safetensors4.97 GBf58e49fd4f181d80aa4ea22de425e7f49a9e1d0f35415fe53634e722670eec55
transformer/diffusion_pytorch_model-00002-of-00003.safetensors4.98 GB828d8aa45a4ded6d32e5018d36af9f234929966df3066cbc2b77afe22e4fa59a
transformer/diffusion_pytorch_model-00003-of-00003.safetensors3.90 GB209b6fa82bd9632e44e9a2daea8727bd3f8206331dd20d784f5cdc39a65a035f
transformer/diffusion_pytorch_model.safetensors.index.json44.6 KBd957778edf4b6757a2df2a464cae988ebdc35788fe146588a52ec221fa39698d
vae/config.json1.25 KB3dd3fd1e352eb444a5bdaa657946e17af8c2ab2790969b0a63296e383ab81da7
vae/diffusion_pytorch_model.safetensors812 MBa80a129b649cdb6d74d9c2b5bb060f3b882b7826b63a732306a7d3393deedbc0
vision_language_encoder/config.json1.47 KB816382abb020842b3ba8f54bd64a54f39455ac80223bdfe732d3c78d831beb6b
vision_language_encoder/generation_config.json201 B34a0bb3aae9ef1313ffc06c54b7710273f2c7db1fa90999f4f4438162b84a03a
vision_language_encoder/model-00001-of-00004.safetensors5.30 GB8575ed7148893c4fb390ad84c51d9c3800b0f960af6f977c6f6fd6d1708c8c4d
vision_language_encoder/model-00002-of-00004.safetensors5.30 GBd074e03e7bf01b4a3150adec5afb968303a0310ce701c3eae47f3e78e58b0fc5
vision_language_encoder/model-00003-of-00004.safetensors5.30 GBc0b8360e705e473233b2f176bfee7ced2f1654e38d24215ae8f5515891312300
vision_language_encoder/model-00004-of-00004.safetensors4.33 GB24ba0474ffbb11163465a2961c45f2a12d88e91840214f93f355851d7d303d0a
vision_language_encoder/model.safetensors.index.json90.3 KB539e0dc83c362e45b15b2be4f4dc0cdb75631176bf329f95e183e38a32586c4f
VersionsEach time the pinned upstream commit or file list changed in this repo. Newest first.
Upstream commitDateContents
2c433cc0cb pinned now manifest updated, same commit2026-11-14 21:26 UTC27 files · 35.8 GB
2c433cc0cb2026-11-14 21:26 UTC27 files · 35.8 GB

Use it

$ fw get zai-org/GLM-Image
# manifest sha256 39b77f12f421… · 35.8 GB · 27 files
$ fw verify ./GLM-Image zai-org/GLM-Image
fw.pyChecks the signature and every sha256, tries each source in order, resumes.
$ python3 fw.py get https://freeweights.allternit.com/manifests/zai-org/GLM-Image.json --dir ./GLM-Image $ python3 fw.py verify ./GLM-Image ./zai-org__GLM-Image.json
hfThe Hugging Face CLI with one setting. Same repo id.
$ HF_ENDPOINT=https://freeweights.allternit.com hf download zai-org/GLM-Image --revision 2c433cc0cbc293bde2ac8ca9624f279b5d23fcf4 --local-dir ./GLM-Image
diffusersRun the pipeline with diffusers.
import os os.environ["HF_ENDPOINT"] = "https://freeweights.allternit.com" from diffusers import DiffusionPipeline pipe = DiffusionPipeline.from_pretrained("zai-org/GLM-Image", revision="2c433cc0cbc293bde2ac8ca9624f279b5d23fcf4")
Packaged for ComfyUI. Most image, video and music models run in ComfyUI . Check the publisher's page for the workflow. Freeweights does not host it.

License

Name
MIT License
Id
MIT
Class
Permissive
Redistribution
yes
Listing
Hosted (signed)
Decided
License as declared by the publisher. No person read it. 2026-11-14
Text in
README.md
Text sha256
fc5861c29cda8b542b0f258a55d9bb8b44d56e9592a021c74f4eeebf7a159ce0
Terms gate
No extra terms beyond the license.

Read the license text

Licenses are checked against the license table. A custom license passes only after a person reads it.

Provenance

From: zai-org <huggingface.co/zai-org>Newsgroups: alt.freeweights.glmSubject: GLM-ImageDate: 2026-11-14Commit: 2c433ccSigned: 2DC28CC7B26A283B ✓
Upstream
zai-org/GLM-Image
Pinned commit
2c433cc0cbc293bde2ac8ca9624f279b5d23fcf4
Manifest
GLM-Image.json · .minisig
Manifest sha256
39b77f12f4213fd286d7749d8d7e5dc2b04b45e40c9efc70a3e1bd3ef0691818
Signature
minisign, Ed25519, key 2DC28CC7B26A283B
Created
2026-11-14 21:26 UTC
Generator
freeweights-manifest/0.1.0
Takedowns
None.

How to verify

$ curl -O https://freeweights.allternit.com/manifests/zai-org/GLM-Image.json $ curl -O https://freeweights.allternit.com/manifests/zai-org/GLM-Image.json.minisig $ minisign -Vm GLM-Image.json -P RWQ7KGqyx4zCLXtUFOqvfv8L3g+8fpKJ1FsuxPyOYMF+4KufbUxKq1Oq $ shasum -a 256 <file> # compare with the Files tab

A manifest whose signature fails must be rejected. A file whose size or sha256 does not match must be discarded. Verify a download

Model tree

No related models in this catalog.Nothing here lists this model as its parent, and it names no parent.
Get it
Download
$ HF_ENDPOINT=https://freeweights.allternit.com hf download zai-org/GLM-Image
Open in Freeweights Studio

Pull, verify and run it in the Allternit app on Desktop, web or phone.

Signed manifest
minisign, key 2DC28CC7B26A283B. GLM-Image.json. Provenance. Takedown history: none.
From: bartowski <huggingface.co/bartowski>Subject: arcee-ai_GLM-4-32B-Base-32K-GGUF
From: ggml-org <huggingface.co/ggml-org>Subject: AutoGLM-Phone-9B-GGUF
From: zai-org <huggingface.co/zai-org>Subject: cogagent-chat-hf
From: zai-org <huggingface.co/zai-org>Subject: CogView3-Plus-3B
From: zai-org <huggingface.co/zai-org>Subject: cogvlm-base-490-hf
From: laion <huggingface.co/laion>Subject: dev_set_part1_10k_glm_4_7_traces_jupiter