GLM 5.3 Flash JSON output vs Sume's strict output_schema rules
GLM-5.3-Flash supports JSON output. Sume's run output_schema is stricter: object root, additionalProperties false, all properties required. A schema that works.

GLM-5.3-Flash supports structured output formats such as JSON, but that is a property of the model's own API. A Sume run output_schema has its own strict rules: the root is an object, every object sets additionalProperties: false, and every property is listed in required, with optional values written as nullable unions. Write the schema to Sume's rules, whichever model plans the run.
What each side documents
Z.ai's GLM-5.3-Flash page (read 2026-10-08) lists function calling, JSON structured output, native multimodal input, a 1M-token context, and up to 128K output tokens. The page does not mention MCP.
Sume's Create a schedule docs say a custom schema must obey the strict subset that OpenAI Structured Outputs enforces, and list the rules.
| Rule | Value |
|---|---|
| Root | An object |
| Each object | additionalProperties: false |
| Properties | All listed in required; optional uses a nullable type such as ["string", "null"] |
| Depth, size | Max 10 nesting levels, 5000 properties, 1000 enum values |
| $ref | Only #/$defs/<name> or the registered SumeMediaFile# |
A schema that passes
This is the image example from the docs. The caption is nullable, so it is in required anyway.
{
"type": "object",
"additionalProperties": false,
"required": ["caption", "image"],
"properties": {
"caption": { "type": ["string", "null"] },
"image": { "$ref": "SumeMediaFile#" }
}
}Where it is applied
On Agent Completions, output_schema binds the run's output to your schema, and Sume parses it after the run completes. On a schedule run, you can override the bound schema for one run, and response_format is accepted as an OpenAI-shaped alias, but sending both returns 400 invalid_request. A schema outside the subset fails before the run starts with output_schema_invalid and a list of violations, each with a path and rule.
Why the model's JSON mode is not enough
A model that emits valid JSON proves the text parses. Sume's check is about the run: whether media the agent produced can be projected into your fields. The docs describe a degraded case where the run completes and bills but output is null because the schema asks for something the run never made. Pick fields the task can fill, and make the rest nullable.
Sume's agent model catalog in the repository lists GLM 5.3 Flash as an enabled row. That is a statement about the Agents picker; it does not change how output_schema is checked.
Nullable is not optional
In many JSON schemas an optional field is simply absent from required. Sume's strict subset does not allow that. An optional value must still be listed in required and typed as a union with null. If you forget, the API returns an error whose violation has the rule required_completeness, a path such as #/properties/caption, and a message telling you to use a nullable type. Fixing it takes one line.
Keep the schema small. A flat object with three or four fields is easier for any model to fill and easier for you to review than a deep tree. The depth limit of 10 and the 5000-property cap are generous, but the failure you will meet in practice is a field that the task cannot fill, not a limit.
Sources
Related posts
More in Developers
- Go httptest for a Sume poll loop: assert next_poll_after_seconds
A 29-line Go test: httptest answers in_progress with next_poll_after_seconds 30 twice, then completed, and asserts the loop slept 30 seconds twice.
- Go: net/http client for a 30-second Wan 3.0 clip, 30 lines
A 30-line Go program using only the standard library: submit wan-3.0 for 30 seconds, poll the job, write clip.mp4. Reserve and per-second rate included.
- Go net/http: a Sume video submit retry loop with one Idempotency-Key
A 30-line Go function using net/http that retries a Sume video submit on 429 and 503, reads Retry-After, and reuses one Idempotency-Key. Run on a stub.
- Google made Omni Flash its default video model: pin it or sume/auto?
Google's docs now say to use Gemini Omni Flash as the default video model. On Sume you can pin gemini-omni-flash-1.1 or send sume/auto. What each one fixes.
Written by Sume