Skip to main content

Introduction

GLM-5.3-Flash is a model in the GLM series. SGLang supports its inference on Ascend NPUs with DeepSeek Sparse Attention (DSA), multi-token prediction (MTP), and ModelSlim quantized weights. This document demonstrates the deployment of GLM-5.3-Flash on Ascend NPUs using SGLang, including single-node prefill-decode mixed deployment, prefill-decode disaggregation, feature configuration, and performance tuning. The examples use W8A8 weights on Atlas 800I A3 and W8A8_MXFP8 weights on Ascend 950PR/DT series.

Supported features

The values in the Example usage column are for illustration only. Adjust them according to your hardware, deployment mode, and workload. For parameter details, see Feature descriptions; for recommended configurations for each deployment scenario, see Best practices.
For feature compatibility and conflicts, see Feature Compatibility.

Prerequisites

Environment

Before following this tutorial, complete the environment setup in the documents below:
  • Ascend NPU Quickstart — the fastest way to get started. It walks you through launching the official container image, starting the SGLang server, and sending a test request. Recommended if you are new to SGLang on Ascend.
  • SGLang Installation with NPU Support — the full installation guide. It covers the component version mapping (CANN, TorchNPU, Triton, kernels, etc.), building from source or from a Dockerfile, and recommended system settings (CPU power scheme, NUMA, swap). Use it when you need to install or customize the environment instead of using the official image.

Model weights

Before downloading model weights, check the model size to reserve enough disk space. For PD disaggregation, download the weights to a shared directory accessible to both nodes. The checkpoint directory must contain the model configuration, tokenizer files, quantized weights, quant_model_description.json, and the MTP weights required by NEXTN. Set MODEL_PATH to this directory inside the container.
A3 single-node deployment uses one full Atlas 800I A3 node: eight cards and 16 dies, with --tp-size 16. 950PR/DT series single-node deployment uses eight NPU devices, with --tp-size 8. Each PD disaggregation configuration uses two nodes of the same platform: one for prefill and one for decode.
For hardware specifications and terminology, see Ascend NPU Reference — Hardware. For the PD disaggregation configuration reference, see Best practices.

Installation

Reserve enough disk space for both the container image and model weights before pulling the image.
Use a SGLang image with the runtime components required by your target platform and deployment mode. Replace IMAGE, NAME, and MODEL_DIR below, then start the container. For 950PR/DT series PD disaggregation, choose an image that supports DP attention.
Command
  • The examples mount the host checkpoint directory at /models/GLM-5.3-Flash. Set MODEL_PATH=/models/GLM-5.3-Flash in the launch scripts when using this mount.
  • Give each container its own NAME. For PD disaggregation, start a container on both nodes.
  • The examples use the SGLang package installed in the image and require no source-code path or PYTHONPATH override.

Online service deployment

Single-node deployment

Prefill and decode run in the same instance. Select the script for your platform and run it inside the container.
Use the ModelSlim W8A8 checkpoint on one Atlas 800I A3 node, with TP16. Replace MODEL_PATH with the checkpoint directory inside the container.

Prefill-decode disaggregation deployment

PD disaggregation places prefill and decode on separate nodes. Replace the model path, node IP addresses, and network interface names, then run the same script on both nodes. The script selects its role by matching the local IP address. Ensure the worker HTTP ports, prefill bootstrap port, and MemFabric store port are reachable between the nodes.
Use W8A8 weights on two Atlas 800I A3 nodes. The prefill instance uses TP4 / PP4 / DP4; the decode instance uses TP16 / PP1 / DP16 and NEXTN speculative decoding with three steps and four draft tokens. Run the CPU tuning commands with the required host privileges.
Launch the router after the prefill and decode services are ready. Use the same node IP addresses as in the worker scripts. Client requests go to the router on port 8000; the worker ports are 8810 and 8811, and the prefill bootstrap port is 8998.

Functional verification

After the service starts, send a prompt to verify inference. For mixed deployment, run the command inside the container with HOST=127.0.0.1 and PORT=8810. For PD disaggregation, use the router IP address and PORT=8000.
Check for an HTTP 200 response with the generated answer. Once the server prints The server is fired up and ready to roll!, it is ready to accept requests. For Health Check, Generate, Chat Completions, and port usage examples, see Testing the Service.

Accuracy evaluation

For evaluation methods and datasets, see Accuracy Evaluation on Ascend NPU.

Performance

For benchmark methods and metric definitions, see Performance Testing on Ascend NPU. For a generated shared-prefix benchmark workload, use approximately 128K input tokens and 1K output tokens. For mixed deployment, use the worker host and port 8810. For PD disaggregation, use the router host and port 8000. Set both --model and --tokenizer to the checkpoint path and use --served-model-name GLM-5.3-Flash.

Best practices

Best practice configuration reference

The Online service deployment section above contains complete scripts for single-node mixed deployment and PD disaggregation. For the optimization feature catalog and compatibility details, see Optimization on Ascend NPU.

Performance tuning

For the feature overview, see Supported features. For tuning parameters and feature compatibility, see Optimization on Ascend NPU.

FAQ

For environment, installation, and general parameter issues, see Ascend NPU FAQ.