{"slug":"glm-5.3-flashx-legal","name":"GLM 5.3 FlashX Legal","family":"zai","family_name":"Z.ai","developer":"Z.ai","color":"#12b5cb","status":"active","released":"2026-11-02","snapshot_of":null,"open":false,"context":1048576,"max_output":131072,"knowledge_cutoff":null,"modalities":["text","image","video"],"output_modalities":["text"],"reasoning":true,"tools":true,"structured_output":true,"huggingface":null,"speed":120,"latency":1.28,"short":"A closed-weights model from Z.ai, released November 2026, with a 1M-token context window and low prices. It has no benchmark results in the registry, so its profile rests on specifications and cost.","strengths":["1M-token context window","Input costs $0.37 per million tokens","Accepts text, image and video inputs","Supports tool calling, reasoning mode and structured output"],"weaknesses":["No benchmark results available to compare quality","Served only through OpenRouter","Knowledge cutoff not stated"],"best_for":"Cost-sensitive agents that need a very large context window and tool calling, where benchmark evidence is not required.","long":"GLM 5.3 FlashX Legal is a closed-weights model from Z.ai, released in November 2026. The registry holds no benchmark results for it, so no claim about its quality can be made from measured scores. Its profile rests on its specifications and price instead.\n\nThe specifications are broad. It has a context window of 1M tokens and a largest response of 128k tokens. It accepts text, image and video inputs and supports tool calling, reasoning mode and structured output. Its knowledge cutoff is not stated.\n\nPrice is the clearest point of comparison. It costs $0.37 per million input tokens and $1.25 per million output tokens, a blended rate of $0.59 against a registry median of about $1.01. It ranks 70th of 194 on price. It is available only through OpenRouter.","described":true,"gateway":false,"byok":true,"string":"openrouter:z-ai/glm-5.3-flashx-legal","input":0.37,"output":1.25,"cache_read":0.075,"blended":0.59,"efficiency":null,"bench":{},"offers":[{"provider":"openrouter","name":"OpenRouter","model_id":"z-ai/glm-5.3-flashx-legal","api":["openai"],"input":0.37,"output":1.25,"cache_read":0.075,"cache_write":null,"input_tiers":[],"output_tiers":[],"context":1048576,"deprecated":false,"gateway":false,"gateway_route":null,"byok":true,"string":"openrouter:z-ai/glm-5.3-flashx-legal","gateway_string":null}],"ranks":{"intelligence":null,"popularity":106,"efficiency":null,"speed":28,"price":70},"top_score":0.2,"about":["A closed-weights model from Z.ai, released November 2026, with a 1M-token context window and low prices. It has no benchmark results in the registry, so its profile rests on specifications and cost.","GLM 5.3 FlashX Legal is a closed-weights model from Z.ai, released in November 2026. The registry holds no benchmark results for it, so no claim about its quality can be made from measured scores. Its profile rests on its specifications and price instead.","The specifications are broad. It has a context window of 1M tokens and a largest response of 128k tokens. It accepts text, image and video inputs and supports tool calling, reasoning mode and structured output. Its knowledge cutoff is not stated.","Price is the clearest point of comparison. It costs $0.37 per million input tokens and $1.25 per million output tokens, a blended rate of $0.59 against a registry median of about $1.01. It ranks 70th of 194 on price. It is available only through OpenRouter."],"examples":[{"file":"hello.py","lang":"python","code":"# /// script\n# dependencies = [\"pydantic-ai\"]\n# ///\nimport os\n\nfrom pydantic_ai import Agent\n\nos.environ['OPENROUTER_API_KEY'] = '...'\n\nagent = Agent('openrouter:z-ai/glm-5.3-flashx-legal', instructions='Be concise, reply with one sentence.')\n\nresult = agent.run_sync('Where does \"hello world\" come from?')\nprint(result.output)","soon":false},{"file":"structured_output.py","lang":"python","code":"# /// script\n# dependencies = [\"pydantic-ai\"]\n# ///\nimport os\n\nfrom pydantic import BaseModel\nfrom pydantic_ai import Agent\n\nos.environ['OPENROUTER_API_KEY'] = '...'\n\n\nclass CityLocation(BaseModel):\n    city: str\n    country: str\n\n\nagent = Agent('openrouter:z-ai/glm-5.3-flashx-legal', output_type=CityLocation)\n\nresult = agent.run_sync('Where were the olympics held in 2012?')\nprint(result.output)\n#> city='London' country='United Kingdom'","soon":false},{"file":"tools.py","lang":"python","code":"# /// script\n# dependencies = [\"pydantic-ai\"]\n# ///\nimport os\nimport random\n\nfrom pydantic_ai import Agent, RunContext\n\nos.environ['OPENROUTER_API_KEY'] = '...'\n\nagent = Agent(\n    'openrouter:z-ai/glm-5.3-flashx-legal',\n    deps_type=str,\n    instructions=\"You're a dice game, roll the die and see if it matches the user's guess.\",\n)\n\n\n@agent.tool_plain\ndef roll_dice() -> str:\n    \"\"\"Roll a six-sided die and return the result.\"\"\"\n    return str(random.randint(1, 6))\n\n\n@agent.tool\ndef get_player_name(ctx: RunContext[str]) -> str:\n    \"\"\"Get the player's name.\"\"\"\n    return ctx.deps\n\n\nresult = agent.run_sync('My guess is 4', deps='Anne')\nprint(result.output)","soon":false},{"file":"streaming.py","lang":"python","code":"# /// script\n# dependencies = [\"pydantic-ai\"]\n# ///\nimport asyncio\nimport os\n\nfrom pydantic_ai import Agent\n\nos.environ['OPENROUTER_API_KEY'] = '...'\n\nagent = Agent('openrouter:z-ai/glm-5.3-flashx-legal')\n\n\nasync def main():\n    async with agent.run_stream('Explain prompt caching in three bullet points.') as response:\n        async for text in response.stream_text(delta=True):\n            print(text, end='', flush=True)\n\n\nasyncio.run(main())","soon":false},{"file":"pax.sh","lang":"sh","code":"export OPENROUTER_API_KEY='...'\n\nuvx pax --model 'openrouter:z-ai/glm-5.3-flashx-legal'","soon":true},{"file":"pi.sh","lang":"sh","code":"# npm install -g @earendil-works/pi-coding-agent\nexport OPENROUTER_API_KEY='...'\n\npi --model 'openrouter/z-ai/glm-5.3-flashx-legal'","soon":false},{"file":"codex.sh","lang":"sh","code":"# npm install -g @openai/codex\nexport OPENROUTER_API_KEY='...'\n\ncodex --model 'z-ai/glm-5.3-flashx-legal' \\\n  -c model_provider='openrouter' \\\n  -c model_providers.openrouter.name='OpenRouter' \\\n  -c model_providers.openrouter.base_url='https://api.openrouter.example/v1' \\\n  -c model_providers.openrouter.env_key='OPENROUTER_API_KEY'","soon":false},{"file":"ai_sdk.ts","lang":"ts","code":"// npm install ai @ai-sdk/openai-compatible\nimport { createOpenAICompatible } from '@ai-sdk/openai-compatible'\nimport { generateText } from 'ai'\n\nprocess.env.OPENROUTER_API_KEY = '...'\n\nconst openrouter = createOpenAICompatible({\n  name: 'openrouter',\n  baseURL: 'https://api.openrouter.example/v1',\n  apiKey: process.env.OPENROUTER_API_KEY,\n})\n\nconst { text } = await generateText({\n  model: openrouter('z-ai/glm-5.3-flashx-legal'),\n  system: 'Be concise, reply with one sentence.',\n  prompt: 'Where does \"hello world\" come from?',\n})\nconsole.log(text)","soon":false}],"benchmarks":[],"generated":"2026-11-25","gaps":{"speed":3,"index":80,"description":0}}