In long-conversation sessions of DeepSeek Harness (DSH), context can easily bloat, leading to increased costs and task drift. dsh-price-less is an experimental context management plugin designed to ensure that every sent Token is cost-efficient by proactively pruning and structurally managing the context.

Plugin Positioning

This is a Context management plugin maintained by user 54shitaimzf. It helps prevent cost bloat and context drift in long sessions by proactively managing the context.

Core Features

The plugin keeps the context lean through multi-layer defense mechanisms:

  • Explicit task management: Use the /task command to mark the current work, with users controlling task opening and closing.
  • Project brief: Establish and persist a project brief via /init, so the model remains aware of the project background at all times.
  • Intent detection: Automatically determine whether each message continues the current task or starts a new one; prioritize keyword rules and call an auxiliary model when uncertain.
  • Star button and prompt optimization: Click the star button to collapse the current intent into a deterministic execution package for user preview and confirmation.
  • Tool clipping: Trim tool outputs on write, remove reads that are overwritten by subsequent writes, and clear completed Q&A validation workflows.
  • Context compression: Collapse closed tasks into versioned archives, retain the hot tail, and trigger compression when the window reaches 35%.
  • Logs and replay: All operations leave replayable factual logs; any failure does not modify history, ensuring no content is lost.

Installation and Activation

The plugin is not published as an npm package and must be built from local DeepSeek Harness source code. Before installation, ensure the environment satisfies the dependencies:

# 环境要求
# 1. 本地有 DeepSeek Harness 源码检出
# 2. Node.js 20+
# 3. 开启 dev_inject_plugin
# 4. 主机需包含 ignorable-channel 补丁(非上游代码)
# 5. 重启 DSH 守护进程使更改生效

# 构建与注入
# 1. 在 DSH 本地源码目录下安装依赖
# 2. 使用 dev_inject_plugin 选项注入插件
# 3. 重启 DSH

Typical Usage

  • Declare context: Tell the plugin directly what you are working on.
  • Manage tasks: Use /task when starting or ending a task.
  • Initialize the project: Use /init to set up the project brief.
  • Confirm intent: Click the star button to collapse the current intent into an execution package.

Usage Scenarios and Cautions

  • Experimental nature: This plugin is experimental and unpublished code, requiring a patched Harness.
  • History editing: It edits session history; back up ~/.dsh/sessions before use.
  • Build binding: It is bound to a specific host build; upgrading the Harness may cause the plugin to stop working.
  • Cost target: Cost savings are a target rather than a guarantee; auxiliary model calls may incur additional fees.
  • No support: No official support contract is provided.

Summary

The plugin focuses on keeping DeepSeek Harness session contexts lean through multi-layer defense mechanisms and explicit user controls. For more details, refer to the official repository.