GLM-5.2: The Moment Open-Weights Overtook the Frontier in Coding — at One-Sixth the Cost
GLM-5.2 beats GPT-5.5 on SWE-bench Pro, approaches Claude Opus 4.8 within 1%, and ships under MIT license with 1M context — at roughly one-sixth the cost of closed-weight frontier models.
Frontier Models · Open-Weight · Coding Performance
For the first time, an open-weight model has overtaken closed-source frontier models on coding benchmarks. GLM-5.2 marks the crossover.
On June 16, 2026, Z.ai (formerly Zhipu AI) released GLM-5.2, a 753-billion-parameter open-weights model. It scored 62.1 on SWE-bench Pro — beating GPT-5.5 (58.6) — and reached 74.4% on FrontierSWE, within one percent of Claude Opus 4.8 (75.1%). Priced at $1.40/M input and $4.40/M output, it costs roughly one-sixth of Claude or GPT-5. The weights ship under an unrestricted MIT license: no regional limits, no commercial-use caps. A stable 1M-token context window, a new IndexShare sparse-attention architecture, and two selectable reasoning modes (Max and High) complete the package. The question is no longer when open-weights will catch up — but which domains they have begun to lead.
Open-weights no longer run in the shadow of closed models. In coding and agentic tasks, they have entered the lead group for the first time.
Key Takeaways
1Beats GPT-5.5 on coding benchmarks
SWE-bench Pro 62.1, FrontierSWE 74.4%, MCP-Atlas 77.0 — all three surpass GPT-5.5 and come within one percent of Claude Opus 4.8. This is the first open-weight model to cross the closed-source frontier in coding tasks.
2MIT license, no geographic restrictions
Weights are published on Hugging Face under MIT license. Commercial use, modification, fine-tuning, and self-hosting are unrestricted. This stands in direct contrast to the US export controls that blocked foreign access to Anthropic's Claude Fable 5.
3One-sixth the cost, Pareto frontier
API pricing: $1.40/M input, $4.40/M output. On Artificial Analysis's Intelligence vs Cost per Task chart, GLM-5.2 sits on the Pareto frontier — the lowest cost per task at its intelligence level. At $0.46 per task, it significantly undercuts GPT-5.5.
4Open-weights already won the volume war
Chinese open-weight providers now account for over 45% of OpenRouter traffic — up from under 2% a year ago. GLM-5.2 is the latest product of this trajectory and the first to overtake closed models in coding.
What Is GLM-5.2?
Z.ai has been building the GLM series as one of the pillars of China's open-model ecosystem throughout 2026. GLM-5.1 approached Claude Opus-level performance on coding benchmarks; GLM-5.2 takes a step further by making "long-horizon tasks" — work that spans hours, not minutes — its core design target. The parameter count is 753B (744B total, 40B active in a mixture-of-experts design), identical to GLM-5.1, but the context window has expanded from 200K to 1M tokens, and reasoning and coding capabilities have improved broadly.
The technical centerpiece is an architectural innovation called IndexShare. In large language models, recomputing attention across long documents is computationally exorbitant. IndexShare reuses the same indexer across every four sparse attention layers, cutting per-token compute FLOPs by 2.9× at 1M context. An upgraded Multi-Token Prediction (MTP) layer boosts accepted token length by up to 20% during inference. Users toggle between two reasoning modes — "Max" for maximum problem-solving, "High" for a performance-latency balance.
IndexShare is not just a speed optimization. Claiming a 1M context window and maintaining quality under real engineering pressure are different problems. Z.ai reports conducting large-scale 1M-context training specifically for coding-agent scenarios — large-scale implementation, automated research, performance optimization, and complex debugging — which is what makes the long-context system stable rather than merely wide.
What the Benchmarks Say: Where It Wins, Where It Loses
On Artificial Analysis's Intelligence Index v4.1, GLM-5.2 scores 51 — the highest among open-weight models. On the same metric, MiniMax-M3 scores 44, DeepSeek V4 Pro (max) 44, and Kimi K2.6 43. The gap to closed-source leaders has narrowed considerably. On GDPval-AA v2, a measure of real-world agentic performance, GLM-5.2 scores 1524 — effectively level with GPT-5.5 (xhigh reasoning, 1514) and ahead of MiniMax-M3 (1418) and DeepSeek V4 Pro (1328).
The coding and agentic results are concrete. SWE-bench Pro: 62.1, surpassing both GPT-5.5 (58.6) and GLM-5.1 (58.4). FrontierSWE (Dominance): 74.4%, beating GPT-5.5 (72.6%) and trailing Claude Opus 4.8 (75.1%) by 0.7 points. MCP-Atlas (tool usage): 77.0, ahead of GPT-5.5 (75.3) and just 0.8 points behind Claude Opus 4.8 (77.8). Humanity's Last Exam (with tools): 54.7, again beating GPT-5.5 (52.2). On PostTrainBench — an extended engineering workload — GLM-5.2 scores 34.3% versus GPT-5.5's 25.0%.
However, GLM-5.2 does not lead across the board. On Terminal-Bench 2.1, it scores 81.0, trailing Claude Opus 4.8 (85.0) and GPT-5.5 (84.0), though ahead of Gemini 3.1 Pro (74.0). On SWE-Marathon, an ultra-long-horizon software engineering benchmark, it trails Opus 4.8 by 13%. In reasoning broadly, closed-source models retain a 3-to-8-point lead. GLM-5.2's significance is not "first place everywhere" but "the first open-weight to cross over in coding and agentic tasks."
GLM-5.1 → GLM-5.2 Key Improvements
- Terminal-Bench 2.1: 63.5 → 81.0 (+17.5)
- Intelligence Index: 40 → 51 (+11)
- HLE (with tools): +12 points → 40%
- CritPt (scientific reasoning): +16 points → 21%
- Context window: 200K → 1M (5× expansion)
Pricing: What One-Sixth Actually Means
GLM-5.2's API is priced at $1.40/M input, $4.40/M output, $0.26/M cache-hit — roughly one-sixth of Claude Opus 4.8 or GPT-5.5. Z.ai also offers a GLM Coding Plan subscription (Lite ~$3, Pro ~$15, Max ~$80/month) integrated with 20+ coding environments. Nine or more inference providers — DeepInfra, Novita, Nebius, Fireworks — host the model.
The cost story is not simply "cheaper." On Artificial Analysis's Intelligence vs Cost per Task chart, GLM-5.2 sits on the Pareto frontier — the lowest cost per task among models at its intelligence level. At $0.46 per task, it is more expensive than MiniMax-M3 ($0.18) or DeepSeek V4 Pro ($0.05), but those two models score 44 on the Intelligence Index — seven points lower than GLM-5.2's 51. Compared within the same performance tier, GLM-5.2 is the most efficient.
One caveat deserves attention. GLM-5.2 consumes an average of 43K output tokens per task — a 65% increase from GLM-5.1 (26K) and nearly double MiniMax-M3 (24K). The model tends to generate more tokens during reasoning, which means actual billing can exceed what benchmark numbers suggest. "Low per-token price" and "low total cost" are not the same statement.
How Open-Weights Reached the Frontier
GLM-5.2 is not a singular event but a point on the trajectory that open-weight models have traced through the first half of 2026. According to Digital Applied's Q2 2026 analysis, Chinese open-weight providers collectively account for over 45% of OpenRouter traffic — up from under 2% a year ago. Xiaomi's MiMo V2 Pro alone holds 21% — roughly three times OpenAI's 7.5%. The assumption that "only closed-source is serious for production" has already broken.
Three factors explain the surge. First, US chip and equipment export controls forced Chinese developers to train and infer as efficiently as possible — IndexShare, Lightning Attention, and DeepSeek's inference optimizations are products of that pressure. Second, Chinese AI companies view global developer reach as their growth engine; releasing weights pulls developers worldwide into their ecosystem. Third, MiniMax, Qwen, DeepSeek, Z.ai, and Moonshot each brought different strengths to a diversifying ecosystem — five frontier-class open-weights shipped in a single 30-day window. It is also the moment when Yann LeCun's long-standing advocacy for open AI research — he left Meta to pursue independent world-model work — transitions from theory to measurable reality.
The gap structure varies by domain. In coding, the gap has effectively closed. In reasoning (GPQA Diamond, HLE, frontier math), closed-source models still lead by 3–8 points. In multimodal workloads (video, audio, image integration), GPT-5.4 and Gemini 3.1 Pro dominate, with open-weight trailing a step behind. "Open-weight equals catching up" is no longer a universal frame. In coding, the lines have crossed; in reasoning, they are close; in multimodal, the gap persists.
The relationship between GLM-5.2 and MiniMax M3 — covered in our earlier analysis — is complementary rather than competitive. Per CodingFleet's comparison, GLM-5.2 leads on SWE-bench Pro (+3.1), Terminal-Bench 2.1 (+15.0), and MCP-Atlas (+2.8). M3, meanwhile, is 3.7× cheaper, offers multimodal capabilities (video, image, desktop recognition), and leads BrowseComp (83.5%). It is a text powerhouse versus a Swiss Army knife. For operators, the realistic strategy is not picking one but routing by task type.
The Other Side: Limitations Beyond the Benchmarks
GLM-5.2's achievements are clear, and so are its limitations. First, Z.ai shipped the model without publishing official benchmark tables alongside the release. BuildFastWithAI's review called this "a marketing-first move" — a 5× context expansion announced with zero accompanying benchmark data. Most performance numbers come from third-party measurements (Artificial Analysis, Proximal), not the release company's own validation.
Second, independent verification of the 1M context window's retrieval quality is still lacking. AIMadeTools notes that "no third-party testing exists confirming GLM-5.2's actual retrieval quality across the full 1M window" and advises treating the "usable" claim — especially above 500K tokens — with healthy skepticism.
Third, real-world build tests show mixed results. One developer built three projects with GLM-5.2 — a horror game, a 3D stealth game, and a marketing video — and reported broken game logic ("collected all three keys, door still won't open") and lower-than-expected completion quality. The gap between benchmark scores and actual output quality remains. Artificial Analysis also notes that GLM-5.2's 43K output tokens per task place it off the most attractive quadrant on the Intelligence vs Output Tokens chart — the more it "thinks," the more it costs.
What Individual Users Should Check Now
GLM-5.2 is powerful, but not the answer for every user. Six criteria for evaluating it against your workflow:
- Task type: For coding agents, long-horizon refactoring, or multi-file work, GLM-5.2 is the strongest open-weight. For translation, summarization, or casual use, a lighter model suffices.
- Context requirements: A 1M window matters for project-scale contexts above 100K. Stability above 500K is not yet independently verified — introduce gradually.
- Cost structure: Low per-token pricing still produces higher totals when 43K output tokens are consumed per task. Track actual cost per task.
- Multimodal needs: GLM-5.2 is text-only. Pair with MiniMax M3 or Qwen 3.5-Omni for video, image, or desktop recognition.
- Data sovereignty: MIT license enables self-hosting, but 753B in BF16 requires ~1.5TB GPU memory. Practical minimum: eight H100 80GB with quantization. Otherwise, verify API routing and data region.
- Access risk: Closed models can be shut off by policy anytime. GLM-5.2's MIT license is a structural buffer. But licenses vary across Chinese models — do not assume identical terms.
FAQ
Is GLM-5.2 better than GPT-5.5?
It depends on the task. GLM-5.2 surpasses GPT-5.5 on SWE-bench Pro, FrontierSWE, MCP-Atlas, HLE (with tools), and PostTrainBench. GPT-5.5 leads on Terminal-Bench 2.1, SWE-Marathon, and reasoning broadly. The key point is not universal superiority but that an open-weight model has crossed over in coding and agentic tasks for the first time.
Is the 1M context window actually usable?
Z.ai reports conducting large-scale 1M-context training for coding-agent scenarios. However, no independent testing has yet confirmed retrieval quality across the full 1M window. Treat the "usable" claim — especially above 500K tokens — with healthy skepticism and validate it in your own tasks.
GLM-5.2 or MiniMax M3 — which should I use?
If your primary work is coding and agentic tasks, GLM-5.2 leads in performance. If cost sensitivity is high or you need multimodal capabilities (video, image, desktop), M3 is more advantageous. Rather than picking one, routing by task type is the practical approach.
Can I self-host GLM-5.2?
Yes, under the MIT license. However, running 753B parameters in BF16 requires approximately 1.5TB of GPU memory. A practical minimum is eight H100 80GB GPUs with quantization. Below that, running at acceptable quality is difficult.
Conclusion: Who Builds Walls, Who Opens Doors
What GLM-5.2 demonstrates is not a single model's benchmark numbers — it is a structural turning point. Open-weights have overtaken closed-source frontier models in coding for the first time. The more the United States moves toward controlling model access, the more valuable a model that declares "no borders on technical access" under MIT license becomes. The two trends reinforce each other: as control tightens, openness becomes strategy.
What individual users should focus on is not "which model is number one" but designing a model stack that fits their work, data, and cost structure. Route coding to GLM-5.2, multimodal to M3, reasoning to closed models. The decision is building a routing architecture where one model's disappearance does not break the workflow. Open-weights have begun leading the frontier — the user's advantage now comes from routing design, not single-model selection.
Sources
Related tools
Related posts
Read →Related tools