{"slug":"glm-5.3-prime","name":"GLM 5.3 Prime","family":"zai","family_name":"Z.ai","developer":"Z.ai","color":"#12b5cb","status":"active","released":"2026-09-23","snapshot_of":null,"open":false,"context":1000000,"max_output":131072,"knowledge_cutoff":null,"modalities":["text"],"output_modalities":["text"],"reasoning":true,"tools":true,"structured_output":false,"huggingface":null,"speed":95,"latency":0.62,"short":"A closed-weights text model from Z.ai, released September 2026, with a 1M-token context window and tool calling. It has no benchmark results and is priced well above the registry median.","strengths":["1M-token context window and 131k-token maximum response length","Tool calling and reasoning mode both supported"],"weaknesses":["No benchmark results, so capability cannot be measured against peers","Blended price $4.30 per million tokens, far above the $1.01 median","Available from one provider, OpenRouter"],"best_for":"Agents that need a very long context window and tool calling, and can absorb a high per-token price.","long":"GLM 5.3 Prime is a closed-weights text model from Z.ai, released in September 2026 and available only through OpenRouter. Its specifications are its main draw: a 1M-token context window, responses up to 131k tokens, tool calling, and a reasoning mode. It accepts text input only and does not offer structured output.\n\nThe registry holds no benchmark results for it, so its capability cannot be compared with other models on the evidence given here. Its price is high for the registry: $2.80 per million input tokens and $8.80 per million output tokens, a blended $4.30 against a median of about $1.01. That places it 155th of 194 on the price rank.\n\nIts popularity rank is 105 of 194. Teams considering it would mainly be relying on its long context and tool support, and should test its output quality on their own tasks before committing.","described":true,"gateway":false,"byok":true,"string":"openrouter:z-ai/glm-5.3-prime","input":2.8,"output":8.8,"cache_read":0.56,"blended":4.3,"efficiency":null,"bench":{},"offers":[{"provider":"openrouter","name":"OpenRouter","model_id":"z-ai/glm-5.3-prime","api":["openai"],"input":2.8,"output":8.8,"cache_read":0.56,"cache_write":null,"input_tiers":[],"output_tiers":[],"context":1000000,"deprecated":false,"gateway":false,"gateway_route":null,"byok":true,"string":"openrouter:z-ai/glm-5.3-prime","gateway_string":null}],"ranks":{"intelligence":null,"popularity":105,"efficiency":null,"speed":44,"price":155},"top_score":0.2024,"about":["A closed-weights text model from Z.ai, released September 2026, with a 1M-token context window and tool calling. It has no benchmark results and is priced well above the registry median.","GLM 5.3 Prime is a closed-weights text model from Z.ai, released in September 2026 and available only through OpenRouter. Its specifications are its main draw: a 1M-token context window, responses up to 131k tokens, tool calling, and a reasoning mode. It accepts text input only and does not offer structured output.","The registry holds no benchmark results for it, so its capability cannot be compared with other models on the evidence given here. Its price is high for the registry: $2.80 per million input tokens and $8.80 per million output tokens, a blended $4.30 against a median of about $1.01. That places it 155th of 194 on the price rank.","Its popularity rank is 105 of 194. Teams considering it would mainly be relying on its long context and tool support, and should test its output quality on their own tasks before committing."],"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-prime', 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-prime', 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-prime',\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-prime')\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-prime'","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-prime'","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-prime' \\\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-prime'),\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}}