{"slug":"kimi-k2-thinking","name":"Kimi K2 Thinking","family":"moonshot","family_name":"Moonshot AI","developer":"Moonshot AI","color":"#7c5cff","status":"active","released":"2025-11-06","snapshot_of":null,"open":true,"context":262144,"max_output":98304,"knowledge_cutoff":"2024-08","modalities":["text"],"output_modalities":["text"],"reasoning":true,"tools":true,"structured_output":true,"huggingface":"moonshotai/Kimi-K2-Thinking","speed":42,"latency":1.55,"short":"Open-weights reasoning model from Moonshot AI, priced near the registry median with a 262k context window. Its benchmark results are thin and mostly below the median.","strengths":["262k token context window","Open weights with tool calling and structured output","Responses up to 98k tokens","Input price of $0.60 per million tokens"],"weaknesses":["35.7% on Terminal-Bench, 22nd of 35 and below the 43.2% median","Epoch Capabilities Index of 145.5, 82nd of 98 and below the 154.5 median","Only two providers, Novita and OpenRouter"],"best_for":"Developers wanting an open-weights reasoning model with tool calling and long context, where cost matters more than benchmarks.","long":"Kimi K2 Thinking is an open-weights reasoning model from Moonshot AI, released in November 2025. It accepts text only and supports tool calling and structured output. Its 262k token context window is large, and it can return responses up to 98k tokens.\n\nPricing sits close to the registry median. Input costs $0.60 per million tokens and output costs $2.50 per million, a blended price of about $1.08 against a median of about $1.01. It is available through Novita and OpenRouter only.\n\nBenchmark results are thin and mostly weak. It scores 35.7% on Terminal-Bench, 22nd of 35 and below the 43.2% median, and 145.5 on the Epoch Capabilities Index, 82nd of 98. Its specifications and price matter more than these scores.","described":true,"gateway":false,"byok":true,"string":"openrouter:moonshotai/kimi-k2-thinking","input":0.6,"output":2.5,"cache_read":0.15,"blended":1.075,"efficiency":null,"bench":{"terminal":35.7,"eci":145.5},"offers":[{"provider":"novita","name":"Novita","model_id":"moonshotai/kimi-k2-thinking","api":["openai"],"input":0.6,"output":2.5,"cache_read":0.15,"cache_write":null,"input_tiers":[],"output_tiers":[],"context":262144,"deprecated":false,"gateway":false,"gateway_route":null,"byok":true,"string":null,"gateway_string":null},{"provider":"openrouter","name":"OpenRouter","model_id":"moonshotai/kimi-k2-thinking","api":["openai"],"input":0.6,"output":2.5,"cache_read":0.15,"cache_write":null,"input_tiers":[],"output_tiers":[],"context":262144,"deprecated":false,"gateway":false,"gateway_route":null,"byok":true,"string":"openrouter:moonshotai/kimi-k2-thinking","gateway_string":null}],"ranks":{"intelligence":null,"popularity":172,"efficiency":null,"speed":142,"price":99},"top_score":0.0429,"about":["Open-weights reasoning model from Moonshot AI, priced near the registry median with a 262k context window. Its benchmark results are thin and mostly below the median.","Kimi K2 Thinking is an open-weights reasoning model from Moonshot AI, released in November 2025. It accepts text only and supports tool calling and structured output. Its 262k token context window is large, and it can return responses up to 98k tokens.","Pricing sits close to the registry median. Input costs $0.60 per million tokens and output costs $2.50 per million, a blended price of about $1.08 against a median of about $1.01. It is available through Novita and OpenRouter only.","Benchmark results are thin and mostly weak. It scores 35.7% on Terminal-Bench, 22nd of 35 and below the 43.2% median, and 145.5 on the Epoch Capabilities Index, 82nd of 98. Its specifications and price matter more than these scores."],"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:moonshotai/kimi-k2-thinking', 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:moonshotai/kimi-k2-thinking', 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:moonshotai/kimi-k2-thinking',\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:moonshotai/kimi-k2-thinking')\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:moonshotai/kimi-k2-thinking'","soon":true},{"file":"pi.sh","lang":"sh","code":"# npm install -g @earendil-works/pi-coding-agent\nexport OPENROUTER_API_KEY='...'\n\npi --model 'openrouter/moonshotai/kimi-k2-thinking'","soon":false},{"file":"codex.sh","lang":"sh","code":"# npm install -g @openai/codex\nexport OPENROUTER_API_KEY='...'\n\ncodex --model 'moonshotai/kimi-k2-thinking' \\\n  -c model_provider='openrouter' \\\n  -c model_providers.openrouter.name='Novita' \\\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('moonshotai/kimi-k2-thinking'),\n  system: 'Be concise, reply with one sentence.',\n  prompt: 'Where does \"hello world\" come from?',\n})\nconsole.log(text)","soon":false}],"benchmarks":[{"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":"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}}