DSH Hub

kuun993/dsh-loop-engine

dsh-loop-engine

UIWeb UI3 GitHub stars· updated 2026-08-27

dsh-loop-engine is a community DeepSeek Harness plugin. Read the repository README before installing.

Install

npx -y @deepseek-ai/dsh plugin --profile web add @kuun993/dsh-loop-engine

Restart `dsh web` after install. Bundle APIs can change during the developer preview.

README badge

dsh-loop-engine DSH Hub badge
[![DSH Hub](https://dshhub.dev/badge/dsh-loop-engine.svg)](https://dshhub.dev/plugins/dsh-loop-engine)

Paste this into your README. The star count updates with every catalog sync.

From the README

Excerpt from kuun993/dsh-loop-engine, cleaned of badges and images.

dsh-loop-engine

Switch the agent loop engine of dsh web the same way you switch a model: a "Loop engine" dropdown in Settings chooses which driver runs your agents — the built-in in-process loop, the Claude Code CLI, the Codex CLI, or the Pi CLI — without changing anything in the main repository.

What it does

  • Engine chosen from Settings, not from code. Pick in-process (default), claude-code, codex, or pi in the settings page; the choice is stored durably and survives profile edits.
  • Claude Code execution. The Claude Code CLI drives agents, with token streaming forwarded into the session log.
  • Codex execution. The driver spawns codex app-server and streams its token-level deltas into the session log, one turn per step.
  • Pi execution. The driver spawns pi --mode rpc and streams its message_update deltas into the session log, one stateless new_session + prompt per step.
  • Extensible. Adding an engine is one driver module plus one entry in the settings schema.
  • Zero main-repo changes. Installed purely as a profile dependency plus one composition row.

Requirements

  • dsh 0.1.1-rc.2 (or a build whose peer packages match).
  • For the Claude Code engine: the Claude Code CLI installed and logged in on the host.
  • For the Codex engine: authenticated either via codex login on the host or a CODEX_API_KEY environment entry.
  • For the Pi engine: authenticated the way pi expects (its own ~/.pi/agent/auth.json or the provider's API-key environment variable such as ANTHROPIC_API_KEY).
  • When the harness runs from a source checkout (e.g. pnpm dsh inside the deepseek-harness repository), the profile must resolve this plugin's harness peer packages to the monorepo sources via local file: shims (the profile's shims/ directory). A deployed install with one published node_modules needs no shims.

Configuration

  1. Build the plugin:

    pnpm install && pnpm run build
    
  2. Add the dependency in $DSH_HOME/profiles/web/package.json:

    "dependencies": {
      "@kuun993/dsh-loop-engine": "1.0.0-rc2",
      "...keep existing deps"
    }
    

    The package is published on npm as @kuun993/dsh-loop-engine. For local development, use a file: reference to your checkout instead of the version string.

  3. Append one composition row in $DSH_HOME/profiles/web/cordis.patch.yml:

    - insert:
        - id: loop-engine
          name: '@kuun993/dsh-loop-engine'
    
  4. Install and restart:

    cd $DSH_HOME/profiles/web && pnpm install
    

    Restart dsh web once so the plugin is picked up.

Switching engines rewrites a small managed block in cordis.patch.yml. Everything else you wrote in that file is preserved; only the plugin's own span changes.

Usage

  1. Open Settings → Loop engine.
  2. Choose an engine:
    • In-process (default) — the built-in loop driver;
    • Claude Code CLI — the Claude Code driver;
    • Codex CLI — the OpenAI Codex driver;
    • Pi CLI — the Pi (earendil-works/pi) driver.
  3. Switching between these applies after restarting dsh web. To return to the default, pick In-process and restart again.
  4. To remove the plugin: delete the loop-engine row from cordis.patch.yml, drop the dependency from package.json, then pnpm install and restart dsh web.

Codex engine details

Related plugins