Z.ai’s GLM-5.4 Runs 28 Layers Twice: What Developers Should Test

Z.ai’s GLM-5.4 runs 28 layers twice. See what early coding benchmarks show and how to test speed, review effort, and token use against your current model.

Escrito por
Aminu Abdullahi
Aminu Abdullahi
Nov 24, 2026
Z.ai’s GLM-5.4 Runs 28 Layers Twice: What Developers Should Test

Z.ai’s GLM-5.4 coding model runs the same 28 transformer layers twice during each forward pass. Image: Timothy Cuenat/Unsplash.

We may earn from vendors via affiliate links or sponsorships. This might affect product placement on our site, but not the content of our reviews. See our Terms of Use for details.

Twenty-eight layers do double duty in Z.ai’s new coding model.

The Chinese AI developer launched GLM-5.4 on Nov. 23. Built from the roughly 750-billion-parameter GLM-5 base, it runs the same block of layers twice during each forward pass.

Developers can already try it through the GLM Coding Plan. For teams weighing a switch, the first test is whether that extra processing helps them get to a patch they can merge any faster.

A different way to scale AI

Traditional Transformers process each layer once during a forward pass. GLM-5.4 instead sends information through the same 28-layer block twice, allowing the model to refine its internal representations without adding another set of parameters.

loop architecture
The loop architecture. Image: Z.ai

Rather than building the architecture from scratch, Z.ai converted its pretrained GLM-5 base through continued training. The approach addresses a growing problem in AI development: bigger models require more computing resources, but certain tasks benefit more from additional reasoning than simply storing more information.

Advertisement

Z.ai designed three mechanisms to keep the extra computation manageable:

  • Gated updates: Token-level controls regulate how much each processing pass changes the model’s internal state.
  • Hybrid KV cache: The second pass reuses previously selected context information while storing only additional local information.
  • Sparse attention reuse: The model carries forward attention indices from the first pass, avoiding another indexing operation.

Z.ai reports streaming speeds of 70–80 tokens per second under peak load and up to 200 off-peak. The time needed to finish a task also depends on how long the model spends reasoning.

From software development to generalized coding

Z.ai wants GLM-5.4 to do more than write and debug software. Its Generalized Coding strategy uses programming as a foundation for tasks traditionally handled by specialized creative and engineering tools.

The company demonstrated several applications:

  • Video production: Creating and editing a self-narrated music video.
  • Mechanical engineering: Designing a six-axis robotic arm using FreeCAD.
  • Game development: Building a complete game with character movement, physics, maps and combat systems.
  • 3D modeling: Creating an interactive bird-watching experience using mathematical geometry and custom shaders.
Advertisement

GLM-5.4 accepts text, images, video, and files and has a one-million-token context window. It outputs text, including the code used to create or edit assets in Z.ai’s demos.

Early results leave questions unanswered

Z.ai’s strongest published evidence comes from a controlled experiment involving a separate 30-billion-parameter model, not the 750-billion-parameter GLM-5.4 flagship.

evaluation table
Evaluated on the 30B model after 200K long-context SFT, with thinking mode enabled. Image: Z.ai

With identical parameter counts and about 10% more training compute, the looped version improved on mathematics, scientific reasoning, and long-context tasks. It also reduced average output lengths by 10% to 14% on selected benchmarks.

Z.ai says GLM-5.4 can match models with 2 trillion to 3 trillion parameters. The company published a win-rate chart for the flagship without explaining how it ran the comparison.

In early third-party testing reported by VentureBeat, GLM-5.4 placed seventh on the KingBench 4 coding benchmark. At maximum reasoning effort, it took about four times as long as Gemini 4 Neon to finish the suite.

Advertisement

Z.ai also acknowledges a tendency toward excessively long reasoning loops, which can increase the time required to complete tasks.

More must-read AI coverage

What to test before switching to GLM-5.4

Developers can try GLM-5.4 in Z.ai Chat, ZCode, or compatible tools on the GLM Coding Plan. Eligible subscribers can use 50% more tokens at the same plan quota than with GLM-5.3. For teams comparing subscriptions, ChatGPT and Codex will move to a shared usage allowance in December.

Run GLM-5.4 and your current coding model on the same routine bug fix and the same change that touches several files. Give both models the same starting code and time budget, then compare three things:

  • Time to a mergeable patch. Count retries and manual fixes as well as the initial wait.
  • Review burden. Check whether the patch passes CI and how much work the reviewer needs to do before approving it.
  • Usage per completed task. Track how much of the plan allowance each run consumes, including retries.
Advertisement

ZCode defaults GLM-5.4 to its highest reasoning setting. Try a lower setting on the routine fix to see whether it finishes sooner and still passes the same checks. If your workflow requires a standalone API or self-hosting, those options are still pending. Z.ai has given no release date for either.

Thinking about putting AI agents to work on your team? Explore AI courses from The Neuron Academy to build the skills to evaluate where agents can help and where you still need a human in the loop.

Aminu Abdullahi

Aminu Abdullahi is a B2C and B2B technology and finance writer with more than six years of experience covering enterprise IT, cybersecurity, cloud computing, artificial intelligence, fintech, business software, and emerging technologies. He has written for a wide range of technical and business audiences, from IT professionals and cybersecurity leaders to small business owners, executives, and technology buyers. His work has appeared in publications including: TechRepublic eWEEK Channel Insider Geekflare Enterprise Networking Planet eSecurity Planet CIO Insight Webopedia With a background in computer science, Aminu specializes in translating complex technical subjects into clear, practical, and accessible content. His writing helps readers understand emerging technologies, evaluate business software, strengthen cybersecurity strategies, and make more informed decisions about technology investments. Across his work, Aminu focuses on the real-world impact of technology, connecting technical innovation with business value, operational efficiency, security, and long-term digital transformation.