← Back to Knowledge

DeepSeek Harness: an agent runtime where everything can be composed

DeepSeek Harness (dsh) is an open-source agent harness from DeepSeek AI. Its central proposal is not merely to run a model: it composes models, tools, sessions, interfaces, and policies as replaceable plugins.

The composition described by the project

  1. Profilenamed bundle composition
  2. Bundlesdistributable, patchable configuration
  3. Pluginsservices · events · capabilities
  4. Sessiondurable log · reconstructable context
  5. Agentmodel · tools · steps
  6. Policysandbox · approval · telemetry

What DeepSeek Harness is—and is not

dsh is an execution and composition platform for agents, with a Web UI, headless mode, profiles, and a plugin ecosystem. It is not the DeepSeek-R1 model or a training paper. A model can be an adapter inside the harness; the harness organizes the work around the model.

  • The official repository presents it as open source and in developer preview.
  • It can start with `npx @deepseek-ai/dsh web` or from a source checkout.
  • The Web UI requires configuring a model provider and selecting a workspace.
  • Compatibility should not be assumed stable: the project explicitly warns about breaking changes.

“Everything is a plugin” is an architectural boundary

The official architecture describes Cordis as the framework under dsh: plugins contribute services, typed events, and reversible effects to a shared context. The model, tool registry, session log, and agent loop all participate in that composition.

  • A profile stacks bundles in a defined order.
  • Patches can replace configuration rows or insert new ones.
  • Capabilities connect through seams: service definition, provider, and consumer.
  • Changing a provider can change a full capability without forking every consumer.

The session log is part of the contract

The architecture documentation treats the append-only log as the source of the context seen by the model. Sessions, turns, steps, messages, tool calls, and results should be reconstructable; anything that reaches the model should be represented in the log.

  • A turn may contain zero or more model steps.
  • Durable events support replay, forks, transcripts, and telemetry.
  • Tools pass through pre-execution, execution, and post-execution stages.
  • Adding model-visible context requires durable representation, not only a temporary variable.

Speed needs operational boundaries

A useful harness does not remove human decisions. It moves them into explicit boundaries: workspace, permissions, sandbox, approval, secrets, telemetry, and publication. For software engineering, the advantage is changing providers and capabilities without losing traceability.

  • Configuring the API key and workspace are explicit Web UI steps.
  • The agent can read, edit, execute, delegate, and maintain a plan under the active policy.
  • Operations requiring approval should remain behind that policy.
  • In developer preview, every update should be treated as a compatibility change that requires verification.

The harness and the papers: related, not equivalent

DeepSeek-R1 studies how to incentivize reasoning capabilities through reinforcement learning and describes emergent patterns such as reflection, verification, and strategy adaptation. That work helps explain the model; it does not document dsh’s runtime architecture. The paper most directly connected to the harness is the Cordis preprint on spatiotemporal composition, reversible effects, and reactive coeffects.

  • R1 addresses a training and reasoning-capability question.
  • Cordis addresses a dynamic component-composition question.
  • dsh applies that architectural line to an agent and plugin runtime.
  • It would be inaccurate to claim that the harness guarantees reasoning, autonomy, or business outcomes.

Primary sources