{"slug":"qwen3.5-9b","name":"Qwen3.5-9B","family":"qwen","family_name":"Qwen","developer":"Alibaba","color":"#ff6a00","status":"active","released":"2026-02-23","snapshot_of":null,"open":true,"context":262144,"max_output":235929,"knowledge_cutoff":null,"modalities":["text","image","video"],"output_modalities":["text"],"reasoning":true,"tools":true,"structured_output":true,"huggingface":"Qwen/Qwen3.5-9B","speed":54.5,"latency":0.58,"short":"A small open-weight model from Alibaba that is very cheap and accepts images and video, but falls well below the registry median on nearly every benchmark.","strengths":["Blended price of $0.235 per million tokens, well below the median","17th of 194 on intelligence points per dollar","Accepts text, image and video input with a 262k context window","Supports tool calling, reasoning mode and structured output"],"weaknesses":["Intelligence index of 34.6, 111th of 114 and far below the median","Terminal-Bench 9.2%, 34th of 35; SciCode 29.5%, 95th of 96","OTIS Mock AIME 61.7%, 93rd of 95, against a 94.2% median"],"best_for":"High-volume, low-cost tasks such as classification or simple extraction where capability is secondary.","long":"Qwen3.5-9B is a small open-weight model from Alibaba, released in February 2026. Its main appeal is cost: a blended price of $0.235 per million tokens is well below the registry median, and it ranks 17th of 194 on intelligence points per dollar. It accepts text, image and video input and offers a 262k context window, tool calling, reasoning mode and structured output.\n\nCapability is the trade-off. It ranks 111th of 114 on the Intelligence index and falls below the median on every benchmark it was given, including Terminal-Bench, SciCode and OTIS Mock AIME. It is offered by four providers and is built into the Pydantic AI Gateway.\n\nIt suits high-volume work where cost matters more than accuracy, though it should be checked against the real task before use in harder agentic work.","described":true,"gateway":true,"byok":true,"string":"gateway/doubleword:Qwen/Qwen3.5-9B","input":0.08,"output":0.7,"cache_read":null,"blended":0.235,"efficiency":147.2,"bench":{"index":34.6,"gpqa":79,"aime":61.7,"terminal":9.2,"scicode":29.5,"eci":139.5},"offers":[{"provider":"doubleword","name":"Doubleword","model_id":"Qwen/Qwen3.5-9B","api":["openai"],"input":0.08,"output":0.7,"cache_read":null,"cache_write":null,"input_tiers":[],"output_tiers":[],"context":null,"deprecated":false,"gateway":true,"gateway_route":"doubleword","byok":true,"string":null,"gateway_string":"gateway/doubleword:Qwen/Qwen3.5-9B"},{"provider":"openrouter","name":"OpenRouter","model_id":"qwen/qwen3.5-9b","api":["openai"],"input":0.1,"output":0.15,"cache_read":null,"cache_write":null,"input_tiers":[],"output_tiers":[],"context":null,"deprecated":false,"gateway":false,"gateway_route":null,"byok":true,"string":"openrouter:qwen/qwen3.5-9b","gateway_string":null},{"provider":"ovhcloud","name":"OVHcloud","model_id":"Qwen3.5-9B","api":["openai"],"input":0.12,"output":0.18,"cache_read":null,"cache_write":null,"input_tiers":[],"output_tiers":[],"context":262144,"deprecated":false,"gateway":false,"gateway_route":null,"byok":true,"string":"ovhcloud:Qwen3.5-9B","gateway_string":null},{"provider":"together","name":"Together AI","model_id":"Qwen/Qwen3.5-9B","api":["openai"],"input":0.17,"output":0.25,"cache_read":null,"cache_write":null,"input_tiers":[],"output_tiers":[],"context":262144,"deprecated":false,"gateway":false,"gateway_route":null,"byok":true,"string":"together:Qwen/Qwen3.5-9B","gateway_string":null}],"ranks":{"intelligence":108,"popularity":70,"efficiency":17,"speed":115,"price":32},"top_score":0.6206,"about":["A small open-weight model from Alibaba that is very cheap and accepts images and video, but falls well below the registry median on nearly every benchmark.","Qwen3.5-9B is a small open-weight model from Alibaba, released in February 2026. Its main appeal is cost: a blended price of $0.235 per million tokens is well below the registry median, and it ranks 17th of 194 on intelligence points per dollar. It accepts text, image and video input and offers a 262k context window, tool calling, reasoning mode and structured output.","Capability is the trade-off. It ranks 111th of 114 on the Intelligence index and falls below the median on every benchmark it was given, including Terminal-Bench, SciCode and OTIS Mock AIME. It is offered by four providers and is built into the Pydantic AI Gateway.","It suits high-volume work where cost matters more than accuracy, though it should be checked against the real task before use in harder agentic work."],"examples":[{"file":"hello.py","lang":"python","code":"# /// script\n# dependencies = [\"pydantic-ai\"]\n# ///\nimport os\n\nfrom pydantic_ai import Agent\n\nos.environ['PYDANTIC_AI_GATEWAY_API_KEY'] = '...'\n\nagent = Agent('gateway/doubleword:Qwen/Qwen3.5-9B', 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['PYDANTIC_AI_GATEWAY_API_KEY'] = '...'\n\n\nclass CityLocation(BaseModel):\n    city: str\n    country: str\n\n\nagent = Agent('gateway/doubleword:Qwen/Qwen3.5-9B', 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['PYDANTIC_AI_GATEWAY_API_KEY'] = '...'\n\nagent = Agent(\n    'gateway/doubleword:Qwen/Qwen3.5-9B',\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['PYDANTIC_AI_GATEWAY_API_KEY'] = '...'\n\nagent = Agent('gateway/doubleword:Qwen/Qwen3.5-9B')\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 PYDANTIC_AI_GATEWAY_API_KEY='...'\n\nuvx pax --model 'gateway/doubleword:Qwen/Qwen3.5-9B'","soon":true},{"file":"codex.sh","lang":"sh","code":"# npm install -g @openai/codex\nexport PYDANTIC_AI_GATEWAY_API_KEY='...'\n\ncodex --model 'Qwen/Qwen3.5-9B' \\\n  -c model_provider='gateway' \\\n  -c model_providers.gateway.name='Pydantic AI Gateway' \\\n  -c model_providers.gateway.base_url='https://gateway.pydantic.dev/proxy/doubleword/v1' \\\n  -c model_providers.gateway.env_key='PYDANTIC_AI_GATEWAY_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.PYDANTIC_AI_GATEWAY_API_KEY = '...'\n\nconst doubleword = createOpenAICompatible({\n  baseURL: 'https://gateway.pydantic.dev/proxy/doubleword',\n  apiKey: process.env.PYDANTIC_AI_GATEWAY_API_KEY,\n})\n\nconst { text } = await generateText({\n  model: doubleword('Qwen/Qwen3.5-9B'),\n  system: 'Be concise, reply with one sentence.',\n  prompt: 'Where does \"hello world\" come from?',\n})\nconsole.log(text)","soon":false}],"benchmarks":[{"id":"index","name":"Intelligence index","unit":"","desc":"Our composite of the benchmarks below, 0-100","category":"reference","floor":0,"ceiling":100,"url":"/methodology/","credit":"Pydantic, from the sources credited below"},{"id":"gpqa","name":"GPQA Diamond","unit":"%","desc":"Graduate-level science questions, multiple choice","category":"reasoning","floor":25,"ceiling":97,"url":"https://epoch.ai/benchmarks/gpqa-diamond","credit":"Epoch AI (CC BY 4.0)"},{"id":"aime","name":"OTIS Mock AIME","unit":"%","desc":"Competition mathematics problems with exact answers","category":"reasoning","floor":0,"ceiling":100,"url":"https://epoch.ai/benchmarks/otis-mock-aime-2024-2025","credit":"Epoch AI (CC BY 4.0)"},{"id":"terminal","name":"Terminal-Bench","unit":"%","desc":"Tasks completed in a terminal; the best result of any agent using the model","category":"coding","floor":0,"ceiling":100,"url":"https://www.tbench.ai/leaderboard/terminal-bench/2.0","credit":"Terminal-Bench, via Epoch AI (CC BY 4.0)"},{"id":"scicode","name":"SciCode","unit":"%","desc":"Scientific programming problems written by researchers","category":"coding","floor":0,"ceiling":100,"url":"https://scicode-bench.github.io/","credit":"SciCode, via Epoch AI (CC BY 4.0)"},{"id":"eci","name":"Epoch Capabilities Index","unit":"","desc":"Epoch AI's own composite across about 40 benchmarks; shown for comparison, not part of our index","category":"reference","floor":80,"ceiling":180,"url":"https://epoch.ai/benchmarks/eci","credit":"Epoch AI (CC BY 4.0)"}],"generated":"2026-11-25","gaps":{"speed":3,"index":80,"description":0}}