GLM 5.1

Long-horizon engineering with planning depth

Chat
Thinking
JSON Mode
Tool Calling

Pricing

Run instantly. Pay only for what you use.

Input
$0.9/ M
Output
$3.0/ M
Cache read
$0.15/ M

About GLM 5.1

GLM 5.1 is Z.ai's open-weight agentic engineering flagship, released under MIT: a 754B-parameter MoE with 40B active per token, a 200K-token context window, and up to 128K output tokens — room for entire generated modules in one response.

It is built for long-horizon engineering: sessions sustain up to 8 hours of autonomous planning, execution, and testing — in Z.ai's launch demo it built a working Linux desktop across 655 iterations without human input.

It tops the hardest coding leaderboard: #1 on SWE-bench Pro at 58.4, ahead of the closed frontier models behind it, with 70.6 on τ³-Bench and 71.8 on MCP-Atlas for tool-driven work.

#1on SWE-bench Pro

Score 58.4 — the top open model on the hardest coding leaderboard.

8hautonomous sessions

Planning, execution, and testing loops that run without human input.

128Kmax output tokens

Whole modules, reports, or test suites in a single response.

Key capabilities

GLM 5.1 is strongest where engineering work is measured in hours, not requests — deep refactors, migration projects, and research agents that plan before they act.

Leaderboard-topping engineering

58.4 on SWE-bench Pro — ahead of every closed frontier model on the contamination-resistant set.

Long-horizon autonomy

Up to 8-hour runs — Z.ai's launch demo built a working Linux desktop across 655 planning-execution-test iterations.

Tool-driven reliability

70.6 on τ³-Bench and 71.8 on MCP-Atlas — tool selection that holds across long call chains.

Deep web research

68.0% on BrowseComp — multi-hop browsing and synthesis for research and analysis agents.

Where this model fits

Best for
  • Long-horizon engineering runs

    Plans, executes, and tests autonomously for up to 8 hours — refactors and migrations that outlast a workday.

  • The hardest software-engineering tasks

    #1 on SWE-bench Pro (58.4) — the open model to beat on contamination-resistant coding.

  • Tool-driven agent pipelines

    70.6 on τ³-Bench and 71.8 on MCP-Atlas — dependable tool selection across long call chains.

  • Very long generated outputs

    A 128K-token output ceiling emits whole modules, reports, or test suites in a single response.

Avoid for
  • Cost-sensitive, high-volume fleets

    Premium 40B-active pricing. For always-on loops where per-token cost dominates, use Qwen 3.6 35B-A3B.

  • Image, audio, or video inputs

    GLM 5.1 is text-only. For agentic work grounded in screenshots, use Kimi K2.6.

  • Contexts beyond 200K tokens

    For whole-repo prompts past the 200K window, DeepSeek V4 Flash offers a 1M-token context.

Performance and
benchmarks

Entrim performance for GLM 5.1 under production load in the past few days.

Throughput (tokens / sec)

avg. 71.8tokens/s

Time to first token (TTFT)

avg. 720ms

Public model benchmarks

58.4SWE-bench Pro

No. 1 on the contamination-resistant software-engineering leaderboard.

70.6τ³-Bench

Reliable tool use across long, multi-step agent interactions.

68.0%BrowseComp

Multi-hop web research and synthesis tasks.

Run GLM 5.1 in minutes

Test this model with $25 free credit. Use Entrim's OpenAI-compatible API to call GLM 5.1, compare output quality, latency, and request cost, then decide if it fits your workload.

Code examples

curl -X POST "https://api.entrim.ai/v1/chat/completions" \  -H "Content-Type: application/json" \  -H "Authorization: Bearer $ENTRIM_API_KEY" \  -d '{    "model": "zai-org/GLM-5.1",    "messages": [      {        "role": "user",        "content": "Why do they call it a building if it is already built?"      }    ]  }'

SDKs & docs

Use familiar SDK patterns with quickstart examples for common production setups.

OpenAI-compatible

Keep the request format your team already knows.

No cold starts

Production requests are served without model spin-up delays.

Not sure this is the right model?

Explore related models that may be a better fit for your workload.

Marathon coding agents with visual context

262K
FP4
Vision
Multimodal
Input / M
$0.6
Output / M
$3.2
Cached / M
$0.10

DeepSeek V4 Flash

Version 0731

High-throughput agentic work with 1M context

1M
FP4
Thinking
Tool Calling
Input / M
$0.09
Output / M
$0.17
Cached / M
$0.015

Dense agentic coding with thinking control

262K
FP8
Vision
Multimodal
Video
Input / M
$0.10
Output / M
$0.40
Cached / M
$0.04

Run GLM 5.1 with the Most Cost-Effective LLM Inference

Use $25 free credits to test prompts, token sizes, latency, throughput, output quality, and request cost before moving traffic.
All services are online

© 2026. Entrim. All Rights Reserved.

Privacy policyTerms of service