Skip to main content

Key Highlights

  • First Loop Transformer flagship: 28 of its 78 layers share weights and run two passes, giving ~750B parameters the intelligence Z.ai claims is on par with 2T–3T models
  • 1M context + 128K output: swallow an entire codebase or hundreds of pages in one request
  • Vision on a flagship for the first time: image, video, and file inputs (text output) — debug from screenshots, understand videos, parse documents
  • Built for generalized coding: 51.1% win rate against GLM-5.3 in internal tests, covering code-driven video, game dev, 3D/shaders, and mechanical design
  • Same price as the official API: $1.40/M input, $0.26/M cached input, $4.40/M output — recharge bonuses bring your effective cost to roughly 83–91% of list

Background

On November 23, 2026, Z.ai released GLM-5.4, the first Loop Transformer flagship in the GLM family and the first flagship with vision. Unlike GLM-5.3, which was a post-training refresh of the GLM-5.2 base, GLM-5.4 changes the architecture itself: instead of adding parameters, it runs the same block of layers twice to increase effective depth. Z.ai positions GLM-5.4 for “generalized coding” — not just writing code, but using code to drive video generation, game development, 3D and shader modeling, and FreeCAD/Blender mechanical design. APIYI has onboarded glm-5.4 and it is available now through the OpenAI-compatible API.

Deep Dive

Benchmarks

Official internal evaluations (vendor-reported): Iso-parameter ablation at 30B (isolating the architecture effect): Training compute rose only ~10%, and outputs were 10–14% shorter — the gains come from architectural efficiency, not from thinking longer. Third-party evaluation (KingBench 4): GLM-5.4 scored 33.2/60 (55.3%), ranking 7th of 19 models — the highest among open models, within 5% of GPT-6.2 Astra (33.6) and Opus 5.5 (34.7). Tool-call failure rate: 1.56%.

Core Features

Loop Transformer: depth through looping Classic scaling piles on layers and parameters. GLM-5.4 instead turns 28 of its 78 layers into a weight-sharing loop that runs twice per forward pass. Three engineering pieces make it work:
  • Damp Gate: gates the write-back on the second pass to keep repeated computation from amplifying noise
  • Global KV cache sharing + separate sliding window: keeps 1M-context memory and cost manageable
  • IndexShare: reuses one sparse-attention indexer across every four layers, cutting per-token compute at 1M tokens
1M context + 128K output Long context here is not just “it fits” — it stays usable: whole-repo retrieval, cross-chapter reasoning, and multi-turn tool use all hold up. With 128K max output, a full project scaffold in one generation is realistic. Multimodal input (first on a flagship) Text, image, video, and file inputs through a ~24-layer ViT vision encoder. Hand it an error screenshot, a product demo video, or a spec document and get code or analysis back. Thinking mode and full API surface Deep thinking (reasoning_effort at low / high / max; use max for hard tasks), streaming, function calling, structured JSON output, and context caching. Cached input bills at $0.26/M tokens, a major saving for long sessions and multi-turn agents.

Specifications

Practical Use

  • Large codebase refactoring and review: fit an entire repo in 1M context and analyze cross-file dependencies without chunking
  • Screenshot debugging and video understanding: UI regressions, error screenshots, and demo videos as direct inputs
  • Long-document analysis: cross-chapter Q&A and summarization for contracts, papers, and technical manuals
  • Generalized coding: code-driven video, game prototypes, 3D/shaders, parametric mechanical design
  • Long-running agents: 128K output plus cached billing suits multi-turn tool-calling automation

Code Example

Multimodal input:

Best Practices

  • Use max effort for hard tasks: refactors and multi-step reasoning deserve reasoning_effort: "max"; quick lookups run faster and cheaper at low
  • Exploit caching: keep fixed system prompts and long document prefixes at the front of the message; cached input bills at $0.26/M tokens
  • Stream long-context requests: enable stream: true so the first token arrives sooner on 1M-context calls
  • Pass images as HTTPS URLs or base64: image_url accepts public URLs and data URIs

Pricing and Availability

Pricing

Model pricing matches the official API item by item (converted at the fixed 1:7 rate — a fixed rate, not a promotional one) with no markup. Available groups: Default, SVIP.

Stacking Recharge Promotions

The per-token price matches the official API; savings on APIYI come from recharge bonuses and group multipliers. After recharge bonuses, your effective price is roughly 83–91% of list. See the recharge page for current tiers, validity, and stacking rules: Recharge Promotions.
Model pricing is aligned with the official site and may change; the table above is for reference only — the Model Pricing tab in the top navigation is authoritative: Model Pricing.

Summary

GLM-5.4 is the first time Zhipu has brought its architecture-efficiency thesis to a flagship: loops for depth, 1M context, vision on a flagship, and pricing on par with GLM-5.3. For long-context coding and multimodal engineering, it is one of the strongest value picks available today. On APIYI, glm-5.4 is ready through the OpenAI-compatible API, and recharge bonuses bring the effective cost to 83–91% of list. Start with a complex coding task and a long-document workflow, then scale into production.
Sources and retrieval date (2026-12-02): Z.ai official release information and pricing page; third-party KingBench 4 evaluation (AICodeKing); APIYI platform pricing API verification (model live, groups Default / SVIP). Vendor-reported numbers and third-party evaluations are labeled separately.