dshPlugin RegistrySubmit

Guide · author

Write a DeepSeek Harness Plugin

A DeepSeek Harness plugin is a TypeScript module that exports apply. The framework calls it with a Cordis ctx. That is the whole contract. Everything else — tools, UI cards, skins, sandboxes — registers through that context and unwinds when the plugin unloads.

Minimal plugin

import type { Context } from '@deepseek-ai/cordis'

export const name = 'hello-plugin'

export function apply(ctx: Context) {
  console.log('[hello-plugin] plugin loaded!')
}

If you need another service, declare it. The loader waits:

export const name = 'my-tool-plugin'
export const inject = ['tools']

export function apply(ctx: Context) {
  ctx.tools.register(/* ... */)
}

Load it with a patch

Official tutorial creates scratch-plugin/cordis.yml as a Web overlay. Paths must be absolute:

- insert:
    - id: hello
      name: '/absolute/path/to/deepseek-harness/scratch-plugin/src/my-plugin.ts'
pnpm dsh web --patch ./scratch-plugin/cordis.yml

Publish so this registry can find you

  1. Put a real README at the repo root: what it does, who it is for, the install line.
  2. Add the dsh-plugin GitHub topic. That is the official discovery hook.
  3. Prefer a .dsh-plugin layout if you are shipping a repository plugin rather than a scratch file.
  4. Send the repo via the submit page. We inspect before listing so the topic dump does not become the catalog.

What not to ship