Back to models
GLM-4.6
GLM-4.6 is Zhipu AI's 355B-total, 32B-active open-weight MoE model under the MIT license, featuring a 200K context window optimized for coding assistants, search-augmented reasoning, and refined writing.
What you can do
- IDE coding assistant integration
- Search-augmented research agents
- Frontend UI coding and technical writing
Input & output
- Input
- Text prompts, multi-file code context, search/tool definitions, and long documents up to 200K tokens
- Output
- Reasoning traces, IDE-ready code edits, front-end implementations, and structured long-form text
Try a prompt like this
Build an interactive single-page release readiness tracker in HTML/CSS/TypeScript with dependency graph filtering, keyboard navigation, and accessible dark/light themes.
Things to know
BF16 requires ~720GB VRAM; official FP8 weights (`ZhipuAI/GLM-4.6-FP8`) fit on a single 8×80GB GPU node via vLLM or SGLang under the permissive MIT license.
All listed models publish open weights for self-hosted deployment; check each repository's license before commercial use.
Call it through the API
The platform exposes an OpenAI-compatible API. Use an official SDK or any HTTP client, then set the gateway URL, API key, and model ID.
- Endpoint
POST/v1/chat/completions- Model repo ID
ZhipuAI/GLM-4.6
import os
from openai import OpenAI
client = OpenAI(
base_url=os.environ["API_BASE_URL"],
api_key=os.environ["API_KEY"],
)
response = client.chat.completions.create(
model="ZhipuAI/GLM-4.6",
messages=[{"role": "user", "content": "Build an interactive single-page release readiness tracker in HTML/CSS/TypeScript with dependency graph filtering, keyboard navigation, and accessible dark/light themes."}],
)
print(response.choices[0].message.content)Before running a sample, set the API_BASE_URL (gateway URL) and API_KEY environment variables.
Read the full API guide