Preface

The philosophy behind DeepSeek Harness (DSH) is “everything is a plugin.” When an LLM seam (ctx.llm) needs to be routed to locally running tools, the dsh-llm-kiro plugin registers a kiro provider route and reuses the local kiro-cli login state and functionality. It is based on ACP (Agent Client Protocol, JSON-RPC 2.0 over stdio), which is built into kiro-cli.

Core Features

  1. Configuration-free access: Fully reuses the local kiro-cli login state (IAM Identity Center / Builder ID), with no API key or settings section required.
  2. Zero runtime dependencies: Does not depend on any agent SDK; uses pure Node child_process and hand-written JSON-RPC.
  3. Long-lived sessions: Each host session ID corresponds to a warm kiro-cli ACP child process. Conversation continuation and tool rounds occur within the session; LRU eviction by insertion order is applied within the maxSessions limit.
  4. Tool bridging: Host tools are exposed to the inner model through one loopback HTTP MCP server (dsh-host) per session.
  5. Native tool isolation: kiro starts with --trust-tools= (zero-trust), and only @dsh-host MCP tools are allowed.
  6. Actual context usage: The kiro stream reports contextUsagePercentage via _kiro.dev/metadata, and the plugin converts it into inputTokens based on the model’s context window.
  7. Live model catalog fetching: kiro-cli chat --list-models --format json is fetched in real time.
  8. Thinking levels: Each model supports five levels: low / medium / high / xhigh / max.
  9. Bypass requests: Side-channel requests such as title generation and compaction are handled through cold-start one-shot ACP sessions.
  10. Automatic proxy integration: Automatically detects installed kiro-proxy process-level proxy wrappers.
  11. Recoverable overflow: Inner error messages are categorized and reported as CONTEXT_WINDOW_EXCEEDED / QUOTA_EXCEEDED.

Installation and Prerequisites

Prerequisites: kiro-cli must be installed and logged in on the local machine (kiro-cli whoami must be able to run). The plugin fully reuses the kiro-cli login state, so no API key or settings section is required.

Installation command:

dsh plugin --profile <profile> add lizheng1992123-dsh-llm-kiro-<version>.tgz

After restarting the service, the model selector will include kiro.

Configuration

Field Type Default Description
maxSessions number 8 Maximum number of simultaneously maintained warm inner kiro-cli sessions (excess sessions are evicted using insertion-order LRU)
modelCacheTtlSeconds number 300 Cache TTL in seconds for the CLI model catalog
cliPath string kiro-cli Executable name or absolute path of kiro-cli. The default automatically detects the kiro-proxy wrapper; specifying the absolute path of the real CLI forces a direct connection

Typical Usage

Manual mount configuration:

- id: llm-kiro
  name: '@lizheng1992123/dsh-llm-kiro'

Context management: load dsh-compaction-basic and dsh-token-meter, and lower thresholdRatio to 0.6:

- id: compaction-basic
  config:
    auto: true
    thresholdRatio: 0.6
    retainRatio: 0.16

Notes

  1. Session rebuilding: Switching models or thinking levels rebuilds the inner session (kiro-cli’s --model / --effort are process startup parameters).
  2. Persistence: kiro sessions are persisted on the CLI side; they can be cleaned up with kiro-cli chat --list-sessions / --delete-session.
  3. Image rendering: Image messages are rendered as the [Image attachment] placeholder.
  4. Silent window: Turn end depends on a 400 ms silent window (ACP has no tool-waiting event).

Author: LiZheng1992123
License: MIT
GitHub: https://github.com/LiZheng1992123/dsh-llm-kiro
Catalog page: https://www.skillhub.cn/plugins/LiZheng1992123/dsh-llm-kiro