Tabbit
活动资源博客模型
Tabbit LogoTabbit

Tabbit — 为你工作的 AI 浏览器

主题资源

  • AI Browser Resources
  • Agentic Browser Resources
  • Browser Downloads and Install Guides
  • Browser Comparisons
  • AI Browser Alternatives
  • Browser Productivity Resources

热门指南

  • AI Browser
  • Agentic Browser Download
  • Best AI Browser 2026: Top 9 Tested & Ranked
  • AI Browser Download
  • Free AI Browser
  • Best AI Browser 2026
  • AI Browser Comparison 2026
  • AI Browser for Windows
  • AI Browser for Mac
  • Chrome Alternative 2026

活动

  • 别装了,你在《牛来》里早有原型
  • Tabbit 妙招大赛
  • KPOP SBTI 饭圈人格测试
  • Tabbit 校园共创者计划
  • fifi 的论文文献妙招精选
  • 用户问卷

关于

  • Tabbit 博客
  • 媒体报道
提示词
媒体GLM-5.2

GLM-5.2 官方文档 Overview 与 API 快速开始(docs.z.ai)

原始来源

Z.ai 官方开发者文档(docs.z.ai)

作者Z.ai(智谱国际)

原文日期2026-06-16

Tabbit 整理2026-08-19

查看原文

一句话结论

官方给 GLM-5.2 的标准接入配置:模型名 glm-5.2、1M 上下文 / 128K 最大输出、thinking.type: enabled + reasoning_effort: max、temperature: 1.0,可直接复制 curl / Python 示例完成首次调用,并了解官方认定的典型使用场景。

适用场景

  • 适合的任务:首次接入 GLM-5.2 API;项目级代码库整体理解与改造;长时程(long-horizon)任务;从需求到可部署产品的完整开发流程;研究复现(论文→可运行工程);微信小程序迁移、小游戏开发、端上调试闭环、Code-to-Video 循环等官方示例场景。

  • 不适合的任务:需要视觉/多模态输入的任务(GLM-5.2 仅支持文本输入、文本输出);官方未开放 json_schema 严格结构化输出的场景(见迁移指南)。

  • 适用的模型版本:GLM-5.2(API 模型 ID glm-5.2;GLM Coding Plan 中为 GLM-5.2,Claude Code 中可用 GLM-5.2[1m] 启用 1M 上下文)。

  • 适用的客户端、Agent 或 API:Z.ai 官方 API(https://api.z.ai/api/paas/v4/chat/completions,OpenAI 兼容协议);官方 Python/Java SDK、OpenAI Python SDK;GLM Coding Plan(ZCode、Claude Code、OpenCode 等)。

  • 推荐的推理档位和参数:thinking: {"type": "enabled"}(思考默认开启);reasoning_effort 支持 high / max(默认 max,编码任务官方推荐 max);temperature 默认 1.0、top_p 默认 0.95;max_tokens 最大 128K;上下文最大 1M。

可直接使用的内容

规格速览(官方)

项目值
定位旗舰基础模型(flagship foundation model)
输入模态文本
输出模态文本
上下文长度1M tokens
最大输出128K tokens
能力Thinking Mode、流式输出、Function Call、上下文缓存、结构化输出(JSON)、MCP

官方认定的典型使用场景

  • 项目级代码库整体接管:一次放入整个项目让模型理解

  • 长时程重构:让模型端到端跑真实工程任务

  • 生产级标准压力测试:检验模型在硬工程约束下是否守得住

  • 移动端设备上调试闭环:从代码实现到设备验证

  • 微信小程序开发:从 Web 应用迁移到小程序

  • 小游戏开发:从玩法规则到可玩闭环

  • 研究复现:从论文和数据到可运行的工程项目

  • Code-to-Video 循环:从自然语言创意到可演示视频

基础调用(官方 Quick Start 原样)

curl -X POST "https://api.z.ai/api/paas/v4/chat/completions" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer your-api-key" \
-d '{
  "model": "glm-5.2",
  "messages": [
    {
      "role": "system",
      "content": "You are a senior full-stack software engineer, proficient in frontend development, backend architecture design, and modern web technology stacks."
    },
    {
      "role": "user",
      "content": "Design and build a personal blog website for me, including a homepage, article list page, and article detail page, using React + Node.js technology stack."
    }
  ],
  "thinking": {
    "type": "enabled"
  },
  "reasoning_effort": "max",
  "max_tokens": 4096,
  "temperature": 1.0
}'

流式调用(官方 Quick Start 原样)

curl -X POST "https://api.z.ai/api/paas/v4/chat/completions" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer your-api-key" \
-d '{
  "model": "glm-5.2",
  "messages": [
    {
      "role": "system",
      "content": "You are a senior full-stack software engineer, proficient in frontend development, backend architecture design, and modern web technology stacks."
    },
    {
      "role": "user",
      "content": "Design and build a personal blog website for me, including a homepage, article list page, and article detail page, using React + Node.js technology stack."
    }
  ],
  "thinking": {
    "type": "enabled"
  },
  "reasoning_effort": "max",
  "stream": true,
  "max_tokens": 4096,
  "temperature": 1.0
}'

官方宣传要点(与使用决策相关)

  • "Solid 1M context":1M 上下文经过编码 Agent 场景专门训练(大规模实现、自动化研究、性能优化、复杂调试),不是只"能接更多 token"。

  • 在 FrontierSWE、PostTrainBench、SWE-Marathon 上均为排名最高的开源模型;FrontierSWE 仅落后 Claude Opus 4.8 约 1%。

  • 标准编码基准:Terminal-Bench 2.1 为 81.0(GLM-5.1 为 63.5,官方文档页写 62.0),SWE-bench Pro 为 62.1(GLM-5.1 为 58.4),与 Opus 4.8(85.0)差距缩小,领先 Gemini 3.1 Pro。

  • 发布前已提前开放给 GLM Coding Plan 用户,开发者反馈集中在:更强的项目级上下文承载、更稳定的长任务执行、更好的工程规范遵守、更强的客户端与移动端工程能力。

注意与边界

  • 本页为官方自述能力与配置,跑分数字是厂商口径;独立第三方验证见测评目录(NIST CAISI、Arena.ai 等)。

  • 文档中 Terminal-Bench 2.1 分数一处写 81.0 vs 62.0、另一处写 81.0 vs 63.5(GLM-5.1),官方博客为 81.0 vs 63.5,以博客为准。

Tabbit 小编提醒

提示词内容来自公开资料与 Tabbit 编辑整理。引用前请查看原文授权与适用范围。

GLM-5.2

在 Tabbit 中使用

GLM-5.2

相关提示词

媒体Z.ai 官方开发者文档(docs.z.ai,Get Started / Migrate)2026-06

从 GLM-5.1 / GLM-5 / GLM-4.x 迁移到 GLM-5.2 的官方配置指南

媒体Z.ai 官方开发者文档(docs.z.ai,Capabilities / Thinking Mode)

GLM-5.2 思考模式配置:默认思考 / 交错思考 / 保留思考 / 回合级思考(官方)

社区X.com(Twitter),@arena(Arena.ai 官方账号)2026-06-27

Arena.ai 前端编码同题对比:GLM-5.2 (Max) vs Claude Opus 4.8 (Thinking) 的 10 个单次生成示例

媒体rentry.org(作者自建提示词库,由 SillyTavernAI 社区推荐)2026-08-07

GLM-5.2 角色扮演(RP)系统提示词:Evening-Truth 黑暗版完整提示词

GLM-5.2

相关测评

官方Z.ai 官方博客2026-06-16

GLM-5.2 官方发布说明与完整跑分表(Z.ai 博客)

媒体NIST(美国国家标准与技术研究院)官网新闻2026-07-17

NIST CAISI 对 Z.ai GLM-5.2 的独立能力评估

媒体rentry.org(作者个人提示词库的说明页)2026-03-09

Evening-Truth 对 Z.AI Coding Plan 响应质量的投诉与量化疑云

媒体Hugging Face 官方博客(Security incident disclosure)2026-07

Hugging Face 安全事件取证:GLM-5.2 被用于自托管攻击日志分析(真实项目报告)