Zhipu GLM Series Text Models
Copy success!
Overview
GLM-5.3 is Zhipu AI’s most powerful model for programming capabilities to date, demonstrating a 50% improvement over GLM-5.2 in internal subjective evaluations. In terms of cybersecurity, GLM-5.3 performs on par with Mythos 5 in tasks such as white-box code review and vulnerability discovery, showcasing its strong potential for cybersecurity defense scenarios.
Input
Text
Output
Text
Features
Prefix Completion
Enable Partial Mode when calling the Qwen API to make the model continue strictly from your provided prefix text.View docsFunction Calling
Use function calling to connect large language models with external tools and systems.View docsCache
Context Cache stores shared prefixes for long-context requests to reduce repeated computation, improve latency, and lower cost.View docsStructured Outputs
Structured Outputs help ensure the model returns a JSON string in the expected format.View docsPricing
- Input$1.4Per 1M tokens
- Output$4.4Per 1M tokens
- Input(Implicit Cache)$0.26Per 1M tokens
Rate Limits & Context
- Max Input1M
- Max Output131K
- Max Input (Thinking)1M
- Max Output (Thinking)131K
- Context1M
- Max Reasoning131K
- TPMTokens Per Minute3M
- RPMRequests Per Minute200
API Reference
Call APICopy success!
123456789101112131415161718192021222324
from openai import OpenAI
import os
client = OpenAI(
# If the environment variable is not set, replace it with your Model Studio API key: api_key="sk-xxx"
api_key="sk-xxx",
base_url="https://dashscope-intl.aliyuncs.com/compatible-mode/v1",
)
completion = client.chat.completions.create(
model="ZHIPU/GLM-5.3",
messages=[{"role": "user", "content": "Who are you?"}],
extra_body={"enable_thinking": True, "reasoning_effort": "max"},
stream=True,
)
for chunk in completion:
if not chunk.choices:
continue
delta = chunk.choices[0].delta
if hasattr(delta, "reasoning_content") and delta.reasoning_content:
print(delta.reasoning_content, end="", flush=True)
if hasattr(delta, "content") and delta.content:
print(delta.content, end="", flush=True)