Skip to content

GLM-5.3 Flash ​

Preview

Available in Preview since 7 October 2026. GLM-5.3 Flash replaces GLM-5.2, which is deprecated from 7 October 2026 and will be removed on 7 November 2026.

Overview ​

GLM-5.3 Flash is a natively multimodal model from Z.ai with 320 billion total parameters and 18 billion active parameters. It combines sparse and linear attention and supports coding, visual understanding, and multi-step agentic workflows.

Supported languages: English and Chinese

Input documented on Swisscom Inference Endpoints: text and images

Output: text, code, and tool calls

Context length: 262,144 tokens, shared between input and generated output. This is the configured Swisscom deployment limit; upstream evaluations may use different context lengths.

Model identifier: zai-org/glm-5.3-flash

License: MIT

Model Card: zai-org/GLM-5.3-Flash

Use Cases: coding assistance, debugging, visual question answering, document and chart understanding, tool-assisted workflows, and long-context analysis.

Performance & Benchmarks ​

The Artificial Analysis leaderboard, filtered to large reasoning models and captured on 7 October 2026, reports an Intelligence Index score of 42 for GLM-5.3-Flash. The GLM-5.3 entries labelled max and low are separate from GLM-5.3-Flash and should not be interpreted as its reasoning-effort results.

These are third-party benchmark results, not measurements of Swisscom Inference Endpoints. The screenshot does not specify the reasoning-effort setting for GLM-5.3-Flash. This filtered comparison does not establish an overall ranking across all models or endpoint latency and throughput.

Artificial Analysis leaderboard comparison showing GLM-5.3-Flash with an Intelligence Index score of 42

Figure: Artificial Analysis Intelligence Index comparison, filtered to large reasoning models. Source: Artificial Analysis, captured on 7 October 2026.

Reasoning Controls ​

The upstream model supports three reasoning_effort values:

ValueIntended Use
lowTasks requiring a smaller thinking budget
highTasks requiring more reasoning than low
maxChallenging tasks and benchmark reproduction; the default when omitted

The upstream chat template defaults clear_thinking to false. For chat scenarios, the model card recommends explicitly setting chat_template_kwargs.clear_thinking to true to clear previous thinking content. This setting is distinct from the reasoning effort for the current turn.

When using the OpenAI Python SDK, pass chat_template_kwargs through extra_body. In raw HTTP requests, send chat_template_kwargs directly in the JSON body.

Reasoning and the final answer may be returned in separate fields by the serving engine. Read the final answer from choices[0].message.content; do not rely on literal thinking tags in that field.

Best Practices ​

  • Select reasoning effort according to the task and measure quality and latency with your own workload.
  • Reserve enough output tokens for both reasoning and the final answer, while keeping the complete request within the 262,144-token context limit.
  • Use clear, legible images and a specific question for visual tasks.
  • Validate tool arguments before executing a tool and return tool results with the matching tool-call ID.
  • Treat upstream benchmark results as model evaluations, not measurements of Swisscom endpoint latency or throughput.

Endpoints ​

APIEndpoint
Chat CompletionsPOST /v1/chat/completions
ResponsesPOST /v1/responses
Messages (Anthropic-compatible)POST /v1/messages
List ModelsGET /v1/models

Use zai-org/glm-5.3-flash as the model identifier. See Inference Endpoints for shared API usage. The conversational APIs are stateless: include the conversation history with each request.

Example Code Snippets ​

Retrieve the production URL from the GLM-5.3 Flash plan's Documentation section in the Digital Marketplace and set it as API_URL. Set YOUR_API_KEY to your API key. The authentication flow is described in Inference Endpoints.

How to retrieve the production URL

1. Chat completion with curl ​

bash
curl -X POST "$API_URL/v1/chat/completions" \
  -H "Authorization: Bearer $YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "zai-org/glm-5.3-flash",
    "messages": [
      {
        "role": "user",
        "content": "Suggest a test strategy for a document-processing API."
      }
    ],
    "reasoning_effort": "high",
    "chat_template_kwargs": {"clear_thinking": true},
    "max_completion_tokens": 4096
  }'

2. Reasoning with Python ​

python
import os
import openai

client = openai.OpenAI(
    api_key=os.environ["YOUR_API_KEY"],
    base_url=os.environ["API_URL"].rstrip("/") + "/v1",
)

response = client.chat.completions.create(
    model="zai-org/glm-5.3-flash",
    messages=[
        {
            "role": "user",
            "content": "Compare retry strategies for an API with intermittent timeouts."
        }
    ],
    reasoning_effort="max",
    max_completion_tokens=8192,
    extra_body={"chat_template_kwargs": {"clear_thinking": True}},
)

print(response.choices[0].message.content)

3. Image understanding with Python ​

This example sends a local JPEG image as a base64 data URL.

python
import base64
import os
from pathlib import Path

import openai

client = openai.OpenAI(
    api_key=os.environ["YOUR_API_KEY"],
    base_url=os.environ["API_URL"].rstrip("/") + "/v1",
)

image_data = base64.b64encode(Path("your_image.jpg").read_bytes()).decode("utf-8")

response = client.chat.completions.create(
    model="zai-org/glm-5.3-flash",
    messages=[
        {
            "role": "user",
            "content": [
                {
                    "type": "image_url",
                    "image_url": {"url": f"data:image/jpeg;base64,{image_data}"}
                },
                {"type": "text", "text": "Summarize the key information in this image."}
            ]
        }
    ],
    reasoning_effort="high",
    max_completion_tokens=4096,
    extra_body={"chat_template_kwargs": {"clear_thinking": True}},
)

print(response.choices[0].message.content)

4. Tool-calling request with curl ​

bash
curl -X POST "$API_URL/v1/chat/completions" \
  -H "Authorization: Bearer $YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "zai-org/glm-5.3-flash",
    "messages": [{"role": "user", "content": "What is the weather in Bern?"}],
    "tools": [
      {
        "type": "function",
        "function": {
          "name": "get_weather",
          "description": "Return the current weather for a location.",
          "parameters": {
            "type": "object",
            "properties": {"location": {"type": "string"}},
            "required": ["location"]
          }
        }
      }
    ],
    "tool_choice": "auto",
    "reasoning_effort": "high",
    "chat_template_kwargs": {"clear_thinking": true},
    "max_completion_tokens": 4096
  }'

The model requests tools; it does not execute them. If the response contains tool_calls, execute the requested function in your application, then send the original conversation, the assistant's tool-call message, and a role: "tool" message for each result with its matching tool_call_id in a follow-up request.

5. Low-Thinking Mode ​

Unlike Qwen3.8, the upstream GLM-5.3 Flash chat template does not implement chat_template_kwargs.enable_thinking and always starts generation with a thinking block. A non-thinking switch is therefore not documented for this model; do not assume that passing enable_thinking: false disables reasoning.

For a smaller thinking budget, use reasoning_effort: "low". This still enables reasoning and is not a non-thinking mode. Likewise, clear_thinking: true clears previous thinking content, rather than disabling thinking for the current turn.

bash
curl -X POST "$API_URL/v1/chat/completions" \
  -H "Authorization: Bearer $YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "zai-org/glm-5.3-flash",
    "messages": [{"role": "user", "content": "Summarize retrieval-augmented generation in one sentence."}],
    "reasoning_effort": "low",
    "chat_template_kwargs": {"clear_thinking": true},
    "max_completion_tokens": 4096
  }'

6. Responses API ​

The Responses API uses input instead of messages and max_output_tokens instead of max_completion_tokens. This example uses the same API_URL and YOUR_API_KEY environment variables as the Chat Completions examples above.

bash
curl -X POST "$API_URL/v1/responses" \
  -H "Authorization: Bearer $YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "zai-org/glm-5.3-flash",
    "instructions": "Answer concisely in three bullet points.",
    "input": "Compare retrieval-augmented generation and fine-tuning.",
    "max_output_tokens": 4096,
    "stream": false
  }'

The JSON response contains an output array. Read the final answer from content blocks with type output_text within message items; reasoning items may precede the message. When using the OpenAI Python SDK, response.output_text collects the returned text without assuming a particular output item order.

The max_output_tokens budget must accommodate both reasoning and the final answer. Increase the example's budget for complex tasks within the deployed context limit. Requests are stateless: include the full conversation context in input for follow-up requests; previous_response_id is not supported.

For streaming, multimodal input, and tool-calling examples, see the Responses API guide.

Migrating from GLM-5.2 ​

GLM-5.2 is deprecated from 7 October 2026 and will be removed on 7 November 2026.

  1. Obtain the endpoint URL and credentials for the GLM-5.3 Flash plan from the Digital Marketplace.
  2. Replace zai-org/glm-5.2-fp8 with zai-org/glm-5.3-flash in requests and update the endpoint URL and credentials as required by your subscription.
  3. Revalidate prompts, tool calls, reasoning settings, and output handling with representative workloads. GLM-5.3 Flash adds image input and a low reasoning-effort option; its behavior is not guaranteed to match GLM-5.2.
  4. Complete migration before 7 November 2026.