GLM 5.1
Z.AI logo

GLM 5.1

glm-5.1
Z.AI
GLM-5.1 is Zhipu's latest flagship model, with greatly enhanced coding capabilities and significantly improved long-range task performance. It can continuously and autonomously work for up to 8 hours on a single task, completing the full closed loop from planning and execution to iterative optimization, delivering engineering-grade results. In terms of general capability and coding ability, GLM-5.1's overall performance aligns with Claude Opus 4.6, and it demonstrates stronger sustained work capability in long-range autonomous execution, complex engineering optimization, and real-world development scenarios, making it an ideal foundation for building Autonomous Agents and long-horizon Coding Agents.

Pricing

  • Input Tokens: $0.845 /M tokens
  • Output Tokens: $3.380 /M tokens
  • Cache Read: $0.183 /M tokens

Input Modalities

  • Text

Output Modalities

  • Text

Capabilities

  • Thinking
  • Tools
  • Tool calling
  • Structured outputs

Providers

Alibaba Cloud alicloud-glm-5.1
Pricing$0.845$3.380
Cache Read$0.169/M tokens
Cache Write$1.05625/M tokens
Pricing$1.127$3.944
Cache Read$0.22536/M tokens
Cache Write$1.4085/M tokens
Context200K
Max output128K
Latency1.6S
Throughput17.2TPS
Uptime
100.00% uptime 2 days ago
99.87% uptime yesterday
100.00% uptime today
Z.AI zai-glm-5.1
Pricing$0.845$3.380
Cache Read$0.1831115/M tokens
Pricing$1.127$3.944
Cache Read$0.2817/M tokens
Context200K
Max output128K
Latency5.7S
Throughput13.9TPS
Uptime
100.00% uptime 2 days ago
100.00% uptime yesterday
0.00% uptime today
Baidu baidu-glm-5.1
Pricing$0.845$3.380
Pricing$1.127$3.944
Context198K
Max output128K
Latency-
Throughput-
Uptime
0.00% uptime 2 days ago
0.00% uptime yesterday
0.00% uptime today

Performance for glm-5.1

Uptime is the percentage of requests that succeeded over the past 72 hours. AIHubMix continuously monitors every provider and automatically retries with the next-best provider when one returns an error or responds too slowly; Latency is total round-trip time (lower is better); Throughput is how fast the model writes (tokens per second, higher is better).

Uptime
Loading...
Latency
Loading...
Throughput
Loading...

Try this model

Python
import os
from openai import OpenAI

client = OpenAI(
    api_key=os.environ["AIHUBMIX_API_KEY"],
    base_url="https://aihubmix.com/v1",
)

response = client.chat.completions.create(
    model="glm-5.1",
    messages=[
      {
        "role": "user",
        "content": "Hello, how are you?"
      }
    ],
    max_tokens=1024,
    stream=False,
)

print(response.choices[0].message.content)

Frequently asked questions

What is GLM 5.1?

GLM-5.1 is Zhipu's latest flagship model, with greatly enhanced coding capabilities and significantly improved long-range task performance. It can continuously and autonomously work for up to 8 hours on a single task, completing the full closed loop from planning and execution to iterative optimization, delivering engineering-grade results. In terms of general capability and coding ability, GLM-5.1's overall performance aligns with Claude Opus 4.6, and it demonstrates stronger sustained work capability in long-range autonomous execution, complex engineering optimization, and real-world development scenarios, making it an ideal foundation for building Autonomous Agents and long-horizon Coding Agents.