Plugins
Everything is a plugin.
DeepSeek Harness's defining idea: every capability is a plugin. Learn what a plugin is, write your first one, and register tools. Based on the official developer guide.
Install the catalog once, then let DeepSeek Harness install every plugin from this site automatically:
dsh plugin add dshbase-catalog Then say "install me a memory plugin" — your agent finds it in the directory and installs it. Zero copy-paste.
Open the plugin directory and click 📋 安装 on any card to copy its command.
What is a plugin?
A Harness plugin is a TypeScript module that exports an apply function. The framework calls apply when it loads, passing a ctx through which you register capabilities:
import type { Context } from '@deepseek-ai/cordis'
export const name = 'my-plugin'
export function apply(ctx: Context) {
// Register capabilities here.
} Anything you register via ctx is cleaned up automatically when the plugin unloads.
Your first plugin
mkdir -p scratch-plugin/src // scratch-plugin/src/my-plugin.ts
import type { Context } from '@deepseek-ai/cordis'
export const name = 'hello-plugin'
export function apply(ctx: Context) {
console.log('[hello-plugin] plugin loaded!')
} Create scratch-plugin/cordis.yml pointing at the absolute path, then start the Web UI with the patch:
- insert:
- id: hello
name: '/absolute/path/to/deepseek-harness/scratch-plugin/src/my-plugin.ts' pnpm dsh web --patch ./scratch-plugin/cordis.yml Install & use a community plugin
No code needed — plugins are npm packages. Add one to a profile (requires pnpm):
dsh plugin --profile web add dsh-claude-marketplace DSH installs the package, records it in the profile's package.json (dependency + dsh.profile.bundles), and loads it on the next dsh web launch. Confirm with dsh plugin --profile web list, remove with dsh plugin --profile web remove <package>. Real npm plugins to try: noatmark-dsh-plugin (text hygiene tools), dsh-claude-marketplace (load your .claude skills & commands), dsh-plugin-session-import (import Claude Code / Codex history), dsh-fail-logger, dsh-latex-tools, dsh-cloudflare-browser-run. Search the ecosystem with npm search dsh-plugin.
Register a tool
Use defineTool to add a tool your agent can call:
import { defineTool } from '@deepseek-ai/dsh-tools'
ctx.tools.register(defineTool({
name: 'greet',
description: 'Greet someone by name.',
parameters: { name: { type: 'string', required: true, description: 'The name' } },
output: { schema: { type: 'string' }, render: (_a, v) => [{ type: 'text', text: v }] },
async execute(args) { return `Hello, ${args.name}!` },
})) Community plugins & publishing
Tag your repo with dsh-plugin to join the ecosystem, and see the plugin directory (7,797 curated).