代码
GLM · KIMI · DEEPSEEK CODING AGENT

OPEN CHINA CODE

A lean terminal coding agent forked from opencode and rebuilt around China-focused model routing, smart compaction, sliding output budgets, RMB cost tracking, LSP diagnostics, and Playwright browser testing.

Read manual
v0.1.3
$ curl -fsSL https://openchinacode.muffin-labs.com/install | bash
provider GLM-5.2 / Kimi K2.7 / DeepSeek V4 route task.kind + complexity + variant compact summary + active-task + raw tail
NEW
NATIVE MEDIA GENERATION

Generate images and videos
without leaving the terminal.

Ask in natural language or use slash commands. OpenChinaCode routes image and video generation through Volcengine Ark with automatic download to local files.

IMAGE

ByteDance Seedream 5.0 Pro

Up to 2K resolution, multiple aspect ratios, reference-image support, and PNG/JPEG output.

/image-generate a cyberpunk cat mascot
VIDEO

ByteDance Seedance 2.0 Mini

4 to 15 second clips, 720p, first/last frame control, reference images, and generated audio.

/video-generate a 5s product promo clip
Natural language or slash command Just describe what you want, or run /image-generate and /video-generate with an optional prompt. Missing details trigger follow-up questions, not guesses.

Task routing

Subagents pick GLM, Kimi, DeepSeek, or GLM-5V by job type.

Smart compaction

Profile judge + active-task extraction + raw recent tail.

Output budgets

Model-aware max tokens with overflow-safe triggers.

Enhance Vision

Paste any image and any model can see it — vision for all.

3 Provider families
11 Task route types
3L Compaction layers
¥ RMB cost tracking
MODEL ROUTING

Built for China-model coding work,
not just connected to China models.

OpenChinaCode keeps the terminal-first opencode workflow, then narrows the default model surface to GLM, Kimi, and DeepSeek with model-aware request transforms, task routing, compaction, testing, and RMB cost display.

PLAN

GLM-led reasoning

Architecture, complex planning, heavy refactors, and compaction routes favor GLM-5.2 variants for deep reasoning.

BUILD

Kimi for speed

Implementation, review, and common coding subagents use fast Kimi K2.7 routes when the task fits.

DEBUG

DeepSeek for loops

Debug and quick exploration routes are tuned for DeepSeek speed, with sliding max-token behavior.

CAPABILITIES

Everything you need,
nothing you don't.

Intelligent subagent routing

Plan, architecture, refactor, review, implement, explore, debug, test_fix, summarize, compaction, and visual_check each have quick/medium/complex routes.

Smart compaction pipeline

Manual or automatic compaction keeps a general summary, extracts the active task at higher granularity, and can retain raw recent turns with /compact keep N.

Model-aware token budgets

/auto-maxtokens uses official model windows, task signals, and overflow checks so complex coding turns can request large outputs without needless compression.

China-provider tuning

GLM, Kimi, and DeepSeek use direct official OpenAI-compatible APIs with provider-specific max-token, reasoning, sampling, and tool-call behavior.

Browser testing workflow

/test-mcp, /browser-check, and /integration-test wire Playwright MCP and test reports into the agent workflow.

Visible costs & diagnostics

The TUI shows RMB cost, model-aware context usage, route details, LSP diagnostics, and compaction debug stages so behavior is inspectable.

Need the exact commands and config files? The manual documents slash commands, provider auth, task policy overrides, smart compaction, LSP, Playwright MCP, and debugging logs.
Open the manual