GLM-4.6V-Flash Text-Only

This is a text-only extraction of zai-org/GLM-4.6V-Flash. It keeps the language model weights and tokenizer assets, and removes the vision/multimodal components.

This repository is not an official ZhipuAI/zai-org release.

Conversion

  • Source model: zai-org/GLM-4.6V-Flash
  • Source revision: 411bb4d77144a3f03accbf4b780f5acb8b7cde4e
  • Target model type: glm4
  • Target architecture: Glm4ForCausalLM
  • Kept tensors: 523
  • Dropped tensors: 181
  • Weight format: sharded safetensors
  • Weight files: 4 shards at repository root

The original VLM config uses a multimodal glm4v architecture with a nested glm4v_text language config. For text-only loading with Transformers AutoModelForCausalLM, the language backbone was converted to a loadable glm4 CausalLM config.

Validation

Validated locally with Transformers:

  • AutoConfig.from_pretrained(...) loads as Glm4Config
  • AutoTokenizer.from_pretrained(...) loads successfully
  • AutoModelForCausalLM.from_pretrained(..., torch_dtype="auto", low_cpu_mem_usage=True) loads as Glm4ForCausalLM
  • A tiny forward pass succeeds and returns logits with shape (1, 1, 151552)
  • The sharded safetensors index contains 523 tensors
  • No vision/projector/multimodal tensor names remain in the sharded weight index
  • Shard headers match model.safetensors.index.json

Usage

import torch
from transformers import AutoModelForCausalLM, AutoTokenizer

model_id = "sasa2000/glm-4.6v-flash-text-only"

tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(
    model_id,
    torch_dtype="auto",
    device_map="auto",
)

inputs = tokenizer("Explain why the sky looks blue.", return_tensors="pt").to(model.device)
with torch.no_grad():
    output_ids = model.generate(**inputs, max_new_tokens=128)

print(tokenizer.decode(output_ids[0], skip_special_tokens=True))

Limitations

This checkpoint is text-only. Image and video inputs are not supported because the vision encoder, multimodal projector, and related preprocessing assets were removed.

Please review the upstream model card and license for the original model's intended use, limitations, and terms.

Downloads last month
33
Safetensors
Model size
9B params
Tensor type
BF16
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for sasa2000/glm-4.6v-flash-text-only

Finetuned
(11)
this model