GLM-5.1 — The Long-Horizon GLM Model Before 5.2

GLM-5.1 is the GLM model that made long-horizon work a serious proposition for open weights. It shipped a 200,000-token context, multi-hour autonomous execution and engineering-grade deliverables at a point when most open models were still being judged on single-file tasks. It is also the only other GLM model with a full published benchmark column, which makes it the reference point every GLM-5.2 improvement is quoted against.

Reading the GLM-5.1 column is the fastest way to understand what the following generation actually changed. Where GLM-5.1 posts 63.5 on Terminal-Bench 2.1, 58.4 on SWE-bench Pro and 30.5 on FrontierSWE Dominance, GLM-5.2 posts 81.0, 62.1 and 74.4. The gap is uneven on purpose: standard coding moved a few points, long-horizon agentic execution moved by tens of points. All of these are figures as published by the model authors.

200K
token context
the ceiling GLM-5.2 later raised to one million
63.5
Terminal-Bench 2.1
published for GLM-5.1 under the Terminus-2 harness
30.5
FrontierSWE Dominance
against 74.4 for GLM-5.2 on the same evaluation

Free AI Playground — Try a Live Open-Source LLM

No sign-up, no account, no credits. Type a prompt and get a streamed answer.

Response will stream here...

This playground runs a free open-source LLM via OpenRouter. It is not GLM-5.2 and does not use GLM weights — it's here so you can test a live model while you read the published GLM benchmark data below.

What a 200K Context Window Covers

Two hundred thousand tokens is enough for a substantial service, its tests and a long conversation about them — roughly the working set of a focused feature, not an entire monorepo. In practice that means GLM-5.1 handles well-scoped agentic work comfortably and starts needing a retrieval layer once a task spans many modules. It is also the window at which the previous multi-token-prediction design ran into a training and inference KV-cache mismatch, capping speculative-decoding acceptance length at 4.56; removing that mismatch is one of the specific things the next generation fixed. If your workload fits inside 200K tokens, GLM-5.1 remains a capable, fully open GLM model; if it does not, the jump to the 1M window is the whole reason GLM-5.2 exists.

Context window
200,000 tokens
License
MIT open source
Effort levels
Introduced in GLM-5.2
Terminal-Bench 2.1
63.5 (Terminus-2)
Weights host
HuggingFace · ModelScope

GLM-5.1 Benchmark Results

Scores as published by the model authors.

GLM-5.1's published column is respectable across reasoning and mid-length coding: 95.3 on AIME 2026, 86.2 on GPQA-Diamond, 83.8 on IMOAnswerBench, 71.8 on the MCP-Atlas public set and 58.4 on SWE-bench Pro. Where it visibly runs out of room is ultra-long-horizon work — 30.5 on FrontierSWE Dominance, 20.1 on PostTrainBench and 1.0 on SWE-Marathon. Those three rows are precisely the workloads the following generation was trained for, which is why the deltas there are so much larger than on standard coding evaluations.

See all 17 GLM benchmarks in detail →

How GLM-5.1 Compares

Comparison on Terminal-Bench 2.1 (Terminus-2), as published by the model authors.

On Terminal-Bench 2.1 under the Terminus-2 harness, GLM-5.1's 63.5 sits below Qwen3.7-Max at 75.0 and roughly level with DeepSeek-V4-Pro at 64.0, while GLM-5.2 clears the open field at 81.0 and Claude Opus 4.8 leads at 85.0. Read as a lineage, the chart shows a generation of open models bunched in the low sixties and one release breaking out of that band — which is the single clearest argument for treating GLM-5.2 rather than GLM-5.1 as the current open-weight reference.

Read the full GLM-5.2 vs GLM-5.1 comparison →

Where GLM-5.1 Sits in the GLM Model Lineup

GLM-5.1 followed GLM-5 and GLM-5-Turbo and was succeeded by GLM-5.2. It is the last GLM model without explicit effort levels, so anything you build against it spends a fixed amount of computation per task rather than letting you dial the trade-off per request. It remains a sensible choice when you want a smaller, more predictable memory footprint than the 1M-context flagship and your tasks genuinely fit inside 200K tokens.

More GLM Models

View all

GLM-5.1 FAQ

What is the GLM-5.1 model?
GLM-5.1 is the previous flagship of the GLM model family: an MIT-licensed open-weight model with a 200,000-token context, built for long-horizon reasoning and multi-hour autonomous engineering work. It is one of only two GLM models with a full published benchmark column, alongside GLM-5.2.
How much better is GLM-5.2 than GLM-5.1?
It depends entirely on the evaluation. On standard coding the gap is modest — SWE-bench Pro moves 58.4 to 62.1. On long-horizon agentic work it is enormous: FrontierSWE Dominance 30.5 to 74.4, DeepSWE 18.0 to 46.2, SWE-Marathon 1.0 to 13.0. GLM-5.2 wins every row of the published head-to-head table.
How big is the GLM-5.1 context window?
200,000 tokens, with GLM-5.2 later raising the ceiling to a solid 1,000,000. For a lot of agentic coding that is sufficient, but repository-wide analysis and hours-long research loops are exactly where the smaller window starts forcing truncation or retrieval.
Is GLM-5.1 still open source?
Yes. GLM-5.1 remains an MIT-licensed open-weight GLM model published on HuggingFace and ModelScope. Being superseded does not withdraw a release — the weights you have already downloaded stay usable indefinitely, which is one of the practical advantages of open weights over a hosted API.
Is there any reason to still use GLM-5.1?
Yes, if your tasks fit inside 200K tokens and you want a smaller serving footprint. A 200K window costs far less KV-cache memory than a million-token one, and for well-scoped work the published gap on standard coding evaluations is only a few points. For long-horizon agents, use GLM-5.2 instead.

Try a Live AI Model Free — No Account Needed

Read the GLM model benchmarks, then put a real model to work. The playground above is free and needs nothing from you; if you want a fuller AI toolkit, our partner's free tier starts here.