Open source · Best AI for
Best open-source AI for writing code
Open-weights models only: the model file is public, so you can run it on your own computer or any cloud, and nobody can take it away.
Answer: Kimi K3 (59/100 · $6 per 1M tokens)

Kimi K3 from Moonshot AI (Kimi). It scores 59/100 for writing code, #13 among all 35 current models (the overall leader, GPT-6 Astra, scores 91).
All 6 open source models for writing code
Score = share of all of today's AI models it beats on this job's tests (100 = best of all). Bar in coral = the overall #1, for reference.
- 1Kimi K3Moonshot AI (Kimi) · #13 of 35 overall · a few tests59
- 2GLM-5.3Z.ai (Zhipu) · #16 of 35 overall · a few tests54
- 3GLM-5.3-FlashZ.ai (Zhipu) · #28 of 35 overall · a few tests32
- 4GLM-5.2Z.ai (Zhipu) · #31 of 35 overall · a few tests28
- 5Kimi K2.7 CodeMoonshot AI (Kimi) · #34 of 35 overall · a few tests20
- 6InklingThinking Machines Lab · #35 of 35 overall · a few tests5
Score, price and memory side by side
Cost per job = one long request (≈ 20K tokens read, 2K written), using list API prices.
| Model | Score | $ / 1M tokens | Cost per job | Memory | Released |
|---|---|---|---|---|---|
| Kimi K3 | 59 | $6 | $0.09 | 1M | Jul 2026 |
| GLM-5.3 | 54 | $2.15 | $0.037 | 1M | Aug 2026 |
| GLM-5.3-Flash | 32 | $0.24 | $0.004 | 1M | Aug 2026 |
| GLM-5.2 | 28 | $2.15 | $0.037 | 1M | Jun 2026 |
| Kimi K2.7 Code | 20 | $1.71 | $0.027 | 262K | Jun 2026 |
| Inkling | 5 | $2.57 | $0.047 | 66K | Jul 2026 |
Quick answers
What's the best open-source AI for writing code?
Kimi K3 from Moonshot AI (Kimi). It scores 59/100 for writing code, #13 among all 35 current models (the overall leader, GPT-6 Astra, scores 91).
About Kimi K3 →What's the runner-up?
GLM-5.3, scoring 54 at $2.15 per million tokens.
See the details →Which is the best value?
GLM-5.3: it scores 54 (vs 59 for Kimi K3) and costs $2.15 per million tokens instead of $6.
See the details →How does it compare with the overall best for writing code?
GPT-6 Astra scores 91 vs 59, but costs about 3.3× as much per token.
Best AI for writing code →How are these ranked?
Each model's score is the share of current AI models it beats on the writing code tests, weighted towards newer and harder tests. Open-weights models only: the model file is public, so you can run it on your own computer or any cloud, and nobody can take it away.
How scores work →Open source: other jobs
24 jobs · scores update automatically from public test results · data as of November 21, 2026