Zhipu AI: GLM 5.1

GLM 5.1 is Zhipu AI's flagship reasoning model, released 2026-04, designed for long-horizon autonomous work. It can operate independently on a single task for over eight hours, planning, executing, and refining its own output to deliver engineering-grade results. The model achieves a major gain in coding, especially for complex, multi-step projects.

Modalities
inTextoutText
Price / 1M−35%
$0.45 / $2.15$0.97 / $3.04
Context
205K
Knowledge cutoff

Capabilities

ReasoningTool useLong contextPrompt cachingStructured output

Channels

Same weights on every channel. Requests route to the cheapest healthy one; the channel used is printed on each billing line.

Provider
Discount
Input /M
Output /M
Cache Read /M
Cache Create 5m /M
Cache Create 1h /M
Defaultstable
−35%
$0.45
$2.15
$0.08

Cost Calculator

Pick a channel and a usage scenario, then drag to your workload — each scenario assumes a different prompt-cache hit rate.

Channel
Scenario
Unit $0.45 / $2.15 /1MDaily chat: 40% cache hit assumed · cache read $0.08 /1M
List price $207.96On MirAPI$132.19/ moYou save $75.77Create an API key

Benchmarks

bar = score (0–100) · ▏ median

Scores from vendor reports and public leaderboards. No private evals.

Intelligence Index
General ability
41.0
#32
Coding Index
Code
55.8
#35
Agentic Index
Agentic
30.6
#31
GPQA Diamond
Science QA
83.3
#40
τ-bench (airline)
Agentic tool use
74.1
#28

Showcase

Three fixed prompts, identical for every chat model. Outputs are archived verbatim — copy the prompt to reproduce.

Task prompt · identical for all models
Build a single-file HTML page using three.js from a CDN: a low-poly planet with a tilted ring of ~200 orbiting particles, a soft key light plus rim light, slow auto-rotation, and drag-to-orbit controls. No build tools — one file only.
Archived output
Archive not published yet

Every model will run this exact prompt; the output lands here verbatim, with tokens and per-run cost.

Quick Start

import os
from openai import OpenAI

client = OpenAI(
    base_url="https://api.mirapi.ai/v1",   # changed
    api_key=os.environ["MIRAPI_API_KEY"],   # changed
)

resp = client.chat.completions.create(
    model="z-ai/glm-5.1",
    messages=[{"role": "user", "content": "Hello"}],
)
Wire GLM 5.1 into your product

1M free tokens to start · no card · OpenAI-compatible, one base_url change

Start free