跪拜 Guibai
← All articles
DeepSeek · AIGC · AI Programming

DeepSeek Harness Turns AI Coding Into a Plugin-Driven Local Workspace

By 王若风 ·
Read original on juejin.cn ↗ Google Translate ↗ Alt translation

A plugin-first architecture for an AI coding tool means the environment can evolve without waiting on a single vendor's roadmap. Developers who need to swap models, add custom tool-calling logic, or reshape the UI can do so without forking the project.

Summary

DeepSeek Harness (`dsh`) is a new open-source AI coding workspace that runs locally and opens in a browser. Its architecture is built on a single principle: everything is a plugin. Model providers, tool-calling modes, and even the UI itself can be extended or replaced through a plugin system. Installation takes a single `npx` command or a standard `pnpm` build from source, after which the tool serves a local web interface on port 3080.

Four operating modes ship with the tool. Standard mode handles routine code generation and repo edits. PTC mode collapses multiple tool-calling round-trips into a single TypeScript execution step, turning five API calls into one. Minimal mode strips the environment down to a persistent shell and a file editor. Creative mode lets the model inspect the Harness runtime, test plugins, and write new agent presets that persist to disk.

Model configuration is equally flexible. Official presets exist for DeepSeek, GLM, Alibaba Qwen, and Xiaomi, requiring only an API key. Custom providers like Volcengine plug in via an OpenAI-compatible endpoint. A third-party plugin, DSH-better-sidebar, already demonstrates the extension model by adding a dual-workspace sidebar and bottom panel.

Takeaways
Installation runs via `npx @deepseek-ai/dsh web` or a `pnpm` build from source, launching a local web UI at port 3080.
PTC mode writes TypeScript to batch multiple tool calls into a single `run_code` execution, collapsing five round-trips into one.
Minimal mode provides only a persistent bash shell and a `str_replace_editor` for file edits by absolute path.
Creative mode lets the model execute JavaScript on the live runtime via `cordis_mount`, inspect state, and write agent presets saved to `~/.dsh/.agent-presets/`.
Official presets support DeepSeek, GLM (zai-coding-cn), Alibaba Qwen (qwen-token-plan-cn), and Xiaomi with just an API key.
Custom providers like Volcengine connect through an OpenAI-compatible endpoint at `https://ark.cn-beijing.volces.com/api/coding/v3`.
A third-party plugin, DSH-better-sidebar, installs via a `curl | bash` script and adds a dual-workspace layout after a hard refresh.
Conclusions

Batching tool calls into a single TypeScript execution step is a practical latency play: fewer network round-trips mean faster feedback during coding sessions, and the approach sidesteps the need for the model provider to support native tool-calling optimizations.

The Creative mode's ability to let a model execute JavaScript on the live runtime is unusually permissive for a coding tool and suggests DeepSeek is betting that power users want the agent to reconfigure its own environment, not just write application code.

Shipping with presets for four competing Chinese model providers signals that Harness is positioning itself as a neutral front-end, not a DeepSeek-exclusive client. That lowers the switching cost between models and pressures providers to compete on coding-plan quality.

Concepts & terms
PTC (Programmatic Tool Calling)
A mode where the model writes a TypeScript script that chains multiple tool invocations together, and the system executes that script in one step via `run_code`, instead of making separate API calls for each tool.
Coding Plan
A billing and access model offered by Chinese AI providers (GLM, Qwen, Volcengine) that bundles API access specifically for code-generation tasks, often with different rate limits or pricing than general-purpose API keys.
cordis_mount
A Harness runtime mechanism that executes model-generated JavaScript on the live process, enabling the agent to inspect state, test plugins, and modify its own behavior in Creative mode.
Source: juejin.cn ↗ Google Translate ↗ Backup ↗