Skip to content

Z.ai models

Run Z.ai’s GLM models on Modal for complex coding, long-running agent workflows, and tasks that use visual feedback. Use them through Model APIs with per-token billing, or deploy them on Dedicated Endpoints with compute-based billing.

Which Z.ai models can you run on Modal?

ModelArchitectureContextModalitiesInput / Output
GLM-5.4750B scale1MText · ImageComing soon
GLM 5.3 Flash320B MoE1MText · Image$0.45 / $1.50
GLM 5.3753B MoE1MText$1.40 / $4.40
GLM 5.3 Flash NVFP4320B MoE1MText · Image$0.15 / $0.50
GLM 5.3753B MoE · 40B active1MTextDedicated only
GLM 5.2 NVFP4753B MoE · 40B active1MTextDedicated only
GLM 5.2 FP8753B MoE · 40B active1MTextDedicated only
GLM 4.7358B MoE · 32B active198KTextDedicated only

All prices per million tokens. Dedicated Endpoint compute is billed by the second. See compute pricing.

Frequently asked questions about GLM models on Modal

  • GLM 5.3 is the latest and most capable model in the family, built for complex coding and long-running agent workflows with a one-million-token context window. It is also available as Modal’s NVFP4 checkpoint. GLM 5.3 Flash is the first natively multimodal GLM-5 model: it accepts text and images, so agents can use screenshots to check and refine their work. It is also available as NVIDIA’s NVFP4 checkpoint. GLM 5.2 is the earlier flagship for long-running coding and agent tasks, available as Z.ai’s FP8 checkpoint and NVIDIA’s NVFP4 checkpoint. GLM 4.7 is an earlier coding model for multi-step agent tasks and terminal work, with per-turn reasoning controls and a 202,752-token context window.

  • You can run GLM models on Modal through serverless Model APIs, which bill per token with no infrastructure to manage, or on Dedicated Endpoints, which give you your own autoscaling deployment for dedicated inference. Both serve an OpenAI-compatible API, so you can use the OpenAI SDK or any compatible client with the URL, model name, and credentials from your Modal dashboard. See the Model APIs guide and the Dedicated Endpoints guide.

  • Model APIs run GLM models on Modal-managed shared capacity: you pay per input, cached input, and output token, and there is nothing to scale or keep warm. Dedicated Endpoints run GLM models on GPUs reserved for your workload, billed by the GPU second, with control over minimum, maximum, and buffer containers, and they scale to zero when idle. See Modal pricing.

  • Yes. Modal is supported natively in coding harnesses like Claude Code, Codex, OpenCode, Omp, and Hermes Agent. You can use GLM 5.3, GLM 5.3 Flash, or any other model supported in Model APIs. See the setup steps for each agent.

  • No. With Model APIs, Modal runs and autoscales the model, and you only send requests. With Dedicated Endpoints, Modal chooses the GPUs and serving configuration, starts containers when requests arrive, and scales down to zero when the endpoint is idle. You only set capacity limits if you want them.

Ship your first app in minutes

$30 / month free compute