Search Oryxen

Search tools, jump to categories, and open key destinations

All field notes
Field note 13Model review

GLM-5.2: Z.ai's MIT-licensed MoE with a 1M context and a sparse-attention fix

GLM-5.2 is a mixture-of-experts model that Z.ai released in June 2026 with MIT-licensed open weights, a 1-million-token context window, and a reported maximum output of about 128K tokens. Z.ai documents an IndexShare technique that shares a lightweight indexer across every fourth sparse-attention layer, which it says cuts per-token compute substantially at long context, plus High and Max thinking levels. The permission to self-host is settled; the hardware question is not, because a roughly 753-billion-parameter model is a data-centre undertaking rather than a laptop run.

By Kaviyarasu Viswanathan

Bottom line up front

GLM-5.2 is a mixture-of-experts model that Z.ai released in June 2026 with MIT-licensed open weights, a 1-million-token context window, and a reported maximum output of about 128K tokens. Z.ai documents an IndexShare technique that shares a lightweight indexer across every fourth sparse-attention layer, which it says cuts per-token compute substantially at long context, plus High and Max thinking levels. The permission to self-host is settled; the hardware question is not, because a roughly 753-billion-parameter model is a data-centre undertaking rather than a laptop run.

01

A 1M context is a claim about reliability, not just length

Z.ai documents a 1-million-token context window, up from roughly 200K on GLM-5.1, with a reported maximum output of about 128K tokens. The company's framing is that the context is usable for long-horizon engineering work rather than merely advertised, which is the more useful claim to test: a context length that degrades in quality partway through is not the same capability as one that holds up.

Third-party reporting describes the model as positioned between two closed frontier models on coding capability under similar token budgets, and Z.ai's own tables report improvements on Terminal-Bench 2.1 and SWE-bench Pro over the previous generation. Those are vendor and third-party measurements on their own configurations. Whether the context is reliable for your task is a measurement only you can make, on your own repository and harness.

  • Test quality at the context length you actually use, not the maximum advertised.
  • Record the harness and harness version alongside any result.
  • Separate the context window from the completion limit in your design.
02

Why the architecture matters for serving

Z.ai describes IndexShare as reusing the same lightweight indexer across every fourth sparse-attention layer, which it says reduces per-token compute substantially at a 1M context length, and describes an improved multi-token-prediction layer that increases acceptance length for speculative decoding. Both are efficiency claims about serving long context, and both are the kind of claim that is checkable: run the model and measure.

The architecture also constrains which runtimes can serve the model. Z.ai lists support for major inference frameworks, and third-party reporting records roughly 753 billion total parameters with about 40 billion active per token. A sparse model of that size is not a single-GPU proposition, so the practical question is which serving stack and hardware your team already operates.

  • Confirm your serving framework supports the model before planning self-hosting.
  • Estimate memory from checkpoint size plus context and KV-cache overhead.
  • Measure speculative-decoding gain on your own configuration rather than accepting the figure.
03

MIT is the most permissive common licence for weights

Z.ai publishes GLM-5.2 weights under the MIT licence and distributes them on major model hubs. MIT permits commercial use, modification, and redistribution with attribution, which makes self-hosting a genuine commercial option rather than a research exception. It also means a modified model you train can be deployed and sold without a vendor agreement.

The licence is the easy part. Read it for the exact checkpoint you intend to run, record the version and the date you checked it, and treat the hosted endpoint's terms as a separate document — a model's weight licence and a provider's API terms are not the same thing, and neither substitutes for the other.

  • Locate and read the licence for the specific checkpoint you plan to run.
  • Record the model version, licence, and the date you checked it.
  • Keep the hosted API terms separate from the weights' licence in your records.
04

Free gateway access sits on top of a real price

GLM-5.2 is reachable at zero cost on at least one gateway. The published commercial price is roughly a dollar and forty cents per million input tokens, twenty-six cents cached, and four dollars forty per million output. That gap between the free tier and the commercial price is the clearest statement of what the free endpoint costs someone else.

For evaluation, prototyping, and low-volume internal work, free access is genuinely useful. For anything that must keep running, the MIT licence gives you a second route — run it yourself — which converts a subsidy you do not control into a cost you can forecast, subject to the hardware question above. Design that fallback before the dependency, not after an endpoint stops responding.

Questions this note can answer

Useful boundaries, stated plainly.

Is GLM-5.2 the strongest open-source coding model?

Oryxen cannot say. Z.ai's own benchmark tables place it highly among open models, and third-party indexes report their own measurements. Rankings move with each release and depend on the benchmark, the harness, and the token budget, so a general answer is not available.

Can I self-host GLM-5.2?

The weights are MIT-licensed and distributed publicly, so the permission exists. The constraint is hardware: a model reported at roughly 753 billion total parameters needs substantial memory even with only a fraction active per token, which is a capacity question for your own infrastructure.

Oryxen method

Oryxen publishes public research frameworks and makes their sources, uncertainty, and update triggers visible. This field note does not replace direct provider documentation or a team’s own technical, legal, security, financial, or operational evaluation.

Read methodology and corrections