Build with AI
Models

Choose the Right Model

Chinese open-weight models deliver proprietary-tier coding at a fraction of the cost. Here’s how to pick and access them.

Open Weights > Closed Gardens

The AI landscape has shifted. Chinese open-weight models now deliver 80–95% of proprietary model quality (Claude Opus, GPT-5) at 10–50x lower cost. For web development with AI agents, this changes the economics entirely.

Open-Weight ChineseProprietary (US)
Cost per 1M tokens$0.14 – $0.87$3 – $15
Context windowUp to 1M200K – 1M
Code quality (SWE-bench)70–76%72–78%
Weights availableYes — openNo — closed
Self-host optionYesNo
Censorship riskProvider-level onlyProvider + model-level

The Models

Model Provider Context Max Output Coding Rank Best For
GLM-5.2 Zhipu AI (z.ai) 1M 128K #1 Code Arena Long tasks, full-project context, heavy coding
DeepSeek V4 Pro DeepSeek 1M 384K Top-tier Planning, architecture, complex reasoning
DeepSeek V4 Flash DeepSeek 1M 384K Strong Fast iteration, editing, high-volume tasks
Kimi K2.7 Code Moonshot AI 128K 32K Strong Precise code generation, refactoring
MiniMax M3 MiniMax 128K 32K Solid Balanced coding, general tasks, cost-efficient
MiMo-V2.5-Pro MiniMax 128K 32K Strong Frontend, design-heavy tasks, creative coding

GLM-5.2 Deep Dive

GLM-5.2 is the current standout for AI-powered web development. Key facts:

  • 1M context window — fits entire project codebases in a single prompt. Tested at 850K+ tokens in real coding sessions.
  • #1 on Code Arena — the global blind-test leaderboard for coding ability, ahead of all proprietary models as of mid-2026.
  • Between Claude Opus 4.7 and 4.8 on SWE-bench verified, FrontierSWE, and PostTrainBench.
  • Thinking mode with reasoning tokens for complex debugging and architecture decisions.
  • Function calling + MCP support — works with OpenCode’s tool system and PageWeave MCP tools.
  • Open weight — can be self-hosted or run through API. No vendor lock-in.

DeepSeek V4

DeepSeek V4 comes in two tiers, both with 1M context:

V4 FlashV4 Pro
Input (cache miss)$0.14 / 1M tokens$0.435 / 1M tokens
Output$0.28 / 1M tokens$0.87 / 1M tokens
Max output384K384K
Thinking modeYes (default)Yes (default)
Tool callsYesYes
Concurrency2,500500

How to Access These Models

Path 1: OpenCode Go (Recommended)

$10/month ($5 first month). One subscription gives you all six models above with generous rate limits. Open OpenCode Desktop, go to Settings → Providers, select OpenCode Go, sign in, and you’re done. Works with any agent that accepts OpenAI-compatible endpoints.

ModelRequests per 5 hours
DeepSeek V4 Flash31,650
Qwen 3.7 Plus4,300
DeepSeek V4 Pro3,450
MiMo-V2.5-Pro3,250
MiniMax M33,200
Kimi K2.7 Code1,150
Qwen 3.7 Max950
GLM-5.2880

Get all models with one subscription

Subscribe to OpenCode Go — $10/mo

$5 for your first month. Cancel anytime.

Path 2: Direct API (Pay-Per-Token)

More control, pay only for what you use. Each provider has its own API and pricing:

ProviderModelsAPI EndpointOpenCode Setup
Zhipu AI (z.ai) GLM-5.2, GLM-5.1 open.bigmodel.cn Settings → Providers → Z.AI
DeepSeek V4 Pro, V4 Flash api.deepseek.com Settings → Providers → DeepSeek
Moonshot AI Kimi K2.7 Code platform.moonshot.ai Settings → Providers → Moonshot AI
MiniMax M3, MiMo-V2.5-Pro platform.minimax.io Settings → Providers → MiniMax

All four providers are natively supported in OpenCode. Open the Desktop app, go to Settings → Providers, select the provider, sign in or paste your API key, and you’re done.

Path 3: Free Tier (Testing Only)

OpenCode includes free models for testing. Run /models in the TUI to see what’s available. Free tier models have lower rate limits (~200 requests per 5 hours) and are suitable for exploration, not production work.

Recommendations by Task

TaskRecommended ModelWhy
Planning & architecture DeepSeek V4 Pro Best reasoning, 384K output, excellent at multi-step plans
Heavy coding sessions GLM-5.2 1M context fits entire projects, #1 coding rank
Full-project context GLM-5.2 or DeepSeek V4 Pro Both have 1M context, handle 850K+ token sessions
Fast editing / iteration DeepSeek V4 Flash Fastest, cheapest, 31K+ requests on Go plan
Frontend & design work MiMo-V2.5-Pro Strong at creative coding, visual output
Budget-conscious heavy use MiniMax M3 3,200 req/5hr on Go, solid across all tasks
Continue

Built with AI, powered by PageWeave. © 2026