Skip to content

Releases

v0.1.0 — First public release

Choose a tag to compare

@dxxCaO dxxCaO released this 11 Sep 15:51

dsh-self-improvement v0.1.0

First public release. A DeepSeek Harness plugin for cross-session self-improvement: it captures what each session's workspace learns and feeds it back into later sessions, instead of letting that knowledge vanish at session end.

Highlights

  • Persistent memory per workspace — survives restarts and session switches. Five kinds (fact / preference / lesson / resource / method), one file per kind.
  • Importance-weighted injection — entries are ranked by importance + recency + hit count; when the budget runs out they are dropped by score, line-wise, with a trace — never head-truncated and never silently discarded.
  • Retrospectives — immediate on agent/error (debounced and rate-limited) and again at session end; the output becomes memory, SOPs and a handoff brief for the next session.
  • Sleep-time consolidation — while idle, induces higher-level principles, drafts hypotheses to verify and prepares prefetch points.
  • SOP library as a real skill — reusable methods land in playbooks/ and are registered as a skill (progressive disclosure) with usage statistics.
  • Configurable reuse scope — workspace (default, fully isolated), global (one shared library for all workspaces) or both (local accumulation plus a global supplement, promoting general entries at session end). Switching scope reports exactly which layer becomes invisible.
  • Trust model — memory is graded by who wrote it, not what it claims: imperative statements are quarantined on write, unverified entries are capped when scored, and there is a final check at injection time.
  • Improvement proposals — the plugin's suggestions about itself go through a state machine and require human approval; rejection reasons are written back to memory so the same advice is not repeated.
  • Web panel — memory, queue, cost and proposals above the composer, with scope switching.
  • Crash-safe — incremental snapshots while running, automatic recovery of unfinished sessions on startup, at-least-once retrospective queue with backoff and a dead-letter queue.
  • Zero context cost — memory rides the system prompt; it consumes no conversation turns.

Install

dsh plugin add dxxCaO/dsh-self-improvement

Or place the directory under ~/.dsh/plugins-src/, where cordis.patch.yml registers it into the profile layer stack, then restart dsh web.

Requires Node ^22.19.0 || >=24.0.0, with @deepseek-ai/cordis ^4.0.1 and @deepseek-ai/dsh-tools >=0.0.1-rc.1 <0.2.0 as peers.

Quick start

The plugin starts working as soon as it loads. Useful entry points:

Command Purpose
/selfip Show the current reuse scope and config file locations
/selfip scope both Switch the reuse scope
/memory <keyword> Search memory
/forget <keyword> Invalidate matching entries
/retro Run a retrospective on the current session now
/promote Promote general entries to the global library
/proposals List and resolve pending improvement proposals

Data layout

Everything lives under the workspace itself, so it travels with the project and is easy to inspect:

<workspace>/self-improvement/
  config.json          workspace config
  memory/              memory (+ quarantine/)
  logs/                session logs, snapshots, handoff, pending queue, diagnostics
  playbooks/           SOPs
  proposals/           improvement proposals

dsh-self-improvement v0.1.0(中文)

首个公开版本。一个给 DeepSeek Harness 的跨会话自我改进插件:把每个会话工作区学到的东西沉淀下来并回灌到后续会话,而不是让这些经验在会话结束时消失。

主要能力

  • 按工作区的持久记忆——重启、换会话都不丢。五类记忆(fact / preference / lesson / resource / method)分文件存放。
  • 按重要性加权注入——按 重要性 + 新鲜度 + 命中次数 排序;预算耗尽时按分数逐行淘汰并留痕,绝不裁头、绝不静默丢弃。
  • 复盘——出错时即时复盘(防抖 + 频率上限),会话结束时再复盘一次;产物变成记忆、SOP 与给下次会话的交接简报。
  • 睡眠期巩固——空闲时归纳更高层原则、生成待验证假设、准备预取要点。
  • SOP 作为真正的 skill——可复用方法落进 playbooks/,注册为 skill(渐进披露)并带使用统计。
  • 可配置的经验复用范围——workspace(默认,完全隔离)、global(所有工作区共用一份库)或 both(本工作区积累 + 全局库补充,会话结束时提升通用条目)。切换范围时会明确告知哪一层变得不可见。
  • 信任模型——按谁写的而非谁声称的分级:指令性语句写入即隔离,未验证条目评分封顶,注入期再做一次检测。
  • 改进提案闭环——插件对自己的建议走状态机、需人工确认;否决理由回写记忆,避免重复提同类建议。
  • Web 面板——输入区上方展示记忆、队列、成本与提案,可切换范围。
  • 防丢失——运行中增量快照、启动时自动恢复未完成会话、至少一次语义的复盘队列(含退避与死信队列)。
  • 零上下文成本——记忆走系统提示,不占用会话内对话轮次。

安装

dsh plugin add dxxCaO/dsh-self-improvement

或将本目录放入 ~/.dsh/plugins-src/(由 cordis.patch.yml 注册进 profile 层栈),然后重启 dsh web。

要求 Node ^22.19.0 || >=24.0.0,peer 依赖 @deepseek-ai/cordis ^4.0.1 与 @deepseek-ai/dsh-tools >=0.0.1-rc.1 <0.2.0。

快速上手

插件加载后自动开始工作。常用入口:

命令 用途
/selfip 查看当前经验范围与配置文件位置
/selfip scope both 切换经验复用范围
/memory <关键词> 检索记忆
/forget <关键词> 作废匹配的条目
/retro 立即对本会话做一次复盘
/promote 把通用条目提升到全局库
/proposals 查看/处理待批的改进提案

数据位置

全部落在工作区内部,随项目走、便于直接查看:

<工作区>/self-improvement/
  config.json          本工作区配置
  memory/              记忆(含 quarantine/ 隔离区)
  logs/                会话日志、快照、交接简报、待复盘队列、自诊断
  playbooks/           SOP
  proposals/           改进提案

Full documentation: README.md · README.en.md · MIT