Three days after a quiet coding-plan-only soft launch, Z.ai dropped the full open weights for GLM-5.2 on June 16. That gap between subscription launch and public weights release was structurally unusual - a choice that made the model hard to verify before the benchmarks were already circulating. Now that the weights are live, there is something real to examine.
GLM-5.2 is a Mixture-of-Experts model with 753 billion total parameters and around 40 billion active per token. It carries a 1-million-token context window - up from GLM-5.1's 200K - and ships under an MIT license with weights on Hugging Face at zai-org/GLM-5.2.
The benchmark headline is straightforward. On standard coding benchmarks, GLM-5.2 is the strongest open-source model available, improving on GLM-5.1 by a wide margin: 81.0 versus 63.5 on Terminal-Bench 2.1 and 62.1 versus 58.4 on SWE-bench Pro. On Terminal-Bench 2.1 it lands within a few points of Claude Opus 4.8 (85.0), while staying ahead of Gemini 3.1 Pro.
The longer-horizon numbers are where it gets interesting. On FrontierSWE - a benchmark that measures whether an agent can complete open-ended technical projects spanning systems optimization and applied ML research - GLM-5.2 trails Opus 4.8 by only 1%, while edging out GPT-5.5 by 1%. On PostTrainBench, where each agent is given an H100 GPU and evaluated on how much it can improve small models through post-training, GLM-5.2 outperforms both Opus 4.7 and GPT-5.5, ranking second only to Opus 4.8.
The honest summary: GLM-5.2 is the strongest open-weight coding model right now, but Claude Opus 4.8 still leads in most head-to-head comparisons - and the gap widens on the hardest, longest tasks.
On SWE-Marathon, an ultra-long-horizon software engineering benchmark covering tasks such as building compilers and optimizing kernels, GLM-5.2 still has room to grow, trailing Opus 4.8 by 13% while remaining second only to the Opus series.
So what is genuinely new here versus incremental? The jump from GLM-5.1 to 5.2 is real - not cosmetic. Architecturally, GLM-5.2 introduces IndexShare, which reuses one lightweight indexer across every four sparse-attention layers to cut per-token FLOPs by 2.9x at 1M context, and an improved MTP layer for speculative decoding that raises acceptance length by up to 20%. That matters practically: a 1M-context window that actually sustains long agent trajectories without collapsing is harder to ship than a headline number suggests.
GLM-5.2 also introduces effort level control, enabling users to explicitly balance model capability against task execution speed and computational cost.
Under the "Max" effort level, GLM-5.2 pushes to peak intelligence, but utilizes nearly 85k output tokens per task
- which is worth knowing before you route a high-volume pipeline through it.
On the cost arithmetic. An open-weights model just beat GPT-5.5 on key coding benchmarks, and it costs roughly a sixth of what OpenAI charges. GLM-5.2, unveiled between June 13 and 16, is designed for long, complex coding tasks. It edges out GPT-5.5 by approximately 1% on FrontierSWE and ranks first among all open-source models on long-horizon coding benchmarks. The self-hosted path removes API costs entirely - you bring your own compute.
Because GLM-5.2 uses an Anthropic-compatible endpoint, it drops seamlessly into tools like Claude Code and Cline with a quick base URL swap and a model name change.
Day-one support landed across Claude Code, Cline, OpenCode, Roo Code, Goose, Crush, OpenClaw, and Kilo Code. For teams already running a coding agent harness, the switching cost is low enough to test.
What to watch out for. Two caveats deserve straight treatment.
First, the benchmarks are Z.ai's own, published simultaneously with the weights. The benchmarks Z.ai published were released simultaneously with the open weights rather than at the June 13 subscription launch - a structurally unusual choice for a flagship model release. Independent third-party evaluations are still arriving. The numbers look credible against the pattern of earlier GLM releases, but the independent verification window is narrow.
Second, the data risk question is real and specific. Every prompt processed through MiniMax's API is legally accessible to the Chinese government under the 2017 National Intelligence Law, regardless of the user's location, privacy policy, or the physical location of its servers. The same legal framework applies to Z.ai's API. If you are using the hosted endpoint for anything sensitive - proprietary code, customer data, internal tooling - that risk is not theoretical. The self-hosted path with the open weights avoids it, at the cost of running a 753B-parameter MoE model yourself.
The honest positioning: GLM-5.2 is not a model that replaces the closed-source frontier for teams where raw performance is the only variable. On SWE-bench Pro, GLM-5.2's 62.1 trails Opus 4.8's 69.2. That gap is meaningful for the hardest multi-hour engineering tasks. Where GLM-5.2 earns its place is the middle band: teams that have already built an agent harness, are paying real API bills, and want to route a meaningful portion of tasks through a model they can self-host and inspect. A teammate like Beagle, routing Slack or Teams requests to a coding agent, would reasonably treat GLM-5.2 as a serious default candidate for that class of workload.
The open-weight coding model space has been moving fast since the beginning of 2026. GLM-5.2 is the clearest evidence yet that the gap between open and closed is compressing on long-horizon tasks specifically - which is exactly where it matters most for agent workflows.