dsh-layered-memory 0.9.2 → 0.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.en.md +36 -13
- package/README.md +33 -10
- package/assets/changelog/0.9.0/01-/350/256/260/345/277/206/350/212/257/347/211/207/347/272/247/350/201/224/350/217/234/345/215/225.png +0 -0
- package/assets/changelog/0.9.0/02-/345/267/245/344/275/234/345/217/260/346/200/273/350/247/210.png +0 -0
- package/assets/changelog/0.9.0/03-/350/256/260/345/277/206/345/272/223.png +0 -0
- package/assets/changelog/0.9.0/04-/346/264/236/345/257/237/346/264/273/345/212/250.png +0 -0
- package/dist/config.d.ts +1 -491
- package/dist/config.js +3 -0
- package/dist/hooks/recall.js +6 -1
- package/dist/index.d.ts +1 -491
- package/dist/index.js +4 -0
- package/dist/settings.d.ts +2 -0
- package/dist/settings.js +17 -0
- package/dist/tui.d.ts +22 -0
- package/dist/tui.js +201 -0
- package/package.json +14 -12
package/README.en.md
CHANGED
|
@@ -10,30 +10,29 @@
|
|
|
10
10
|
[简体中文](README.md) · [Latest release](https://github.com/JunNanLYS/dsh-layered-memory/releases/latest) · [Report issues](https://github.com/JunNanLYS/dsh-layered-memory/issues)
|
|
11
11
|
|
|
12
12
|
[](https://www.npmjs.com/package/dsh-layered-memory)
|
|
13
|
-
[](https://github.com/deepseek-ai/deepseek-harness)
|
|
14
14
|
[](LICENSE)
|
|
15
15
|
|
|
16
16
|
</div>
|
|
17
17
|
|
|
18
18
|
## Getting Started
|
|
19
19
|
|
|
20
|
-
Requires Node ≥ 22.16 and DeepSeek Harness
|
|
21
|
-
0.1.2-
|
|
20
|
+
Requires Node ≥ 22.16 and DeepSeek Harness **0.1.2-alpha.1 ~ 0.1.2-rc.1**
|
|
21
|
+
(as of 0.10.0 support extends to 0.1.2-rc.1, which the npm "latest" tag
|
|
22
|
+
already points to; for older hosts see the
|
|
22
23
|
[release history](https://github.com/JunNanLYS/dsh-layered-memory/releases)).
|
|
23
24
|
Two invocation styles — the `npx` prefix can replace `dsh` in
|
|
24
25
|
any command below:
|
|
25
26
|
|
|
26
27
|
```bash
|
|
27
|
-
# Option 1: run the official CLI directly via npx (no pre-installed dsh
|
|
28
|
-
|
|
29
|
-
npx -y @deepseek-ai/dsh@0.1.2-alpha.2 plugin --profile web add dsh-layered-memory
|
|
28
|
+
# Option 1: run the official CLI directly via npx (no pre-installed dsh)
|
|
29
|
+
npx -y @deepseek-ai/dsh plugin --profile web add dsh-layered-memory
|
|
30
30
|
|
|
31
|
-
# Option 2: with the dsh CLI installed (upgrade
|
|
32
|
-
#
|
|
33
|
-
# npm i -g pnpm first if missing)
|
|
31
|
+
# Option 2: with the dsh CLI installed (upgrade: npm i -g @deepseek-ai/dsh,
|
|
32
|
+
# then restart; dsh is a pnpm forwarder — npm i -g pnpm first if missing)
|
|
34
33
|
dsh plugin --profile web add dsh-layered-memory
|
|
35
34
|
|
|
36
|
-
# Alternative sources: GitHub repo / local path (dev & debugging, link: points at the repo;
|
|
35
|
+
# Alternative sources: GitHub repo / local path (dev & debugging, link: points at the repo; pnpm run build + restart dsh to apply)
|
|
37
36
|
dsh plugin --profile web add https://github.com/JunNanLYS/dsh-layered-memory
|
|
38
37
|
dsh plugin --profile web add /path/to/dsh-layered-memory
|
|
39
38
|
```
|
|
@@ -71,17 +70,39 @@ and the memory chip in the input bar (`Memory · Auto`) mean the client half is
|
|
|
71
70
|
**Uninstall**: `dsh plugin --profile web remove dsh-layered-memory` + restart. Data
|
|
72
71
|
stays in `~/.dsh/memory/`; delete the whole directory manually if you don't need it.
|
|
73
72
|
|
|
73
|
+
### Terminal Hosts (TUI / headless)
|
|
74
|
+
|
|
75
|
+
Beyond web, the same plugin installs into terminal-shaped hosts:
|
|
76
|
+
|
|
77
|
+
```bash
|
|
78
|
+
# dsh-tui (Claude Code style TUI front door — see github.com/ccch1mneyyy/dsh-TUI · site https://dshtui.com)
|
|
79
|
+
dsh plugin --profile dsh-tui add @deepseek-harness-tui/dsh-tui # first time: create profile + install the TUI host
|
|
80
|
+
dsh plugin --profile dsh-tui add dsh-layered-memory
|
|
81
|
+
dsh --profile dsh-tui
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
- **`/memory <auto|chat|work|off>`** switches the current session's memory mode; with no
|
|
85
|
+
argument a selection panel pops up;
|
|
86
|
+
- **Status line**: a persistent `记忆:智能`-style mode readout sits right above the prompt;
|
|
87
|
+
- **`/settings` section**: master switch, capture, distill, recall, distill model routing and
|
|
88
|
+
input budget are editable in place (same store as the web settings panel; complex routing
|
|
89
|
+
chains still go through web / YAML);
|
|
90
|
+
- **headless** (`dsh --profile headless "one-shot task"`): capture and distillation work as
|
|
91
|
+
usual with no UI elements. Web and terminal hosts share the same `~/.dsh/memory/` store.
|
|
92
|
+
|
|
74
93
|
### Development from Source
|
|
75
94
|
|
|
76
95
|
```bash
|
|
77
96
|
git clone https://github.com/JunNanLYS/dsh-layered-memory
|
|
78
97
|
cd dsh-layered-memory
|
|
79
|
-
|
|
80
|
-
dsh plugin --profile web add . # link: install; after code changes,
|
|
81
|
-
|
|
98
|
+
pnpm install && pnpm run build
|
|
99
|
+
dsh plugin --profile web add . # link: install; after code changes, pnpm run build + restart dsh
|
|
100
|
+
pnpm run smoke # smoke test (rebuild first: see command below)
|
|
82
101
|
npx tsc src/smoke.ts --outDir dist-smoke --module nodenext --moduleResolution nodenext --target es2022 --strict --skipLibCheck --esModuleInterop
|
|
83
102
|
```
|
|
84
103
|
|
|
104
|
+
Dependencies are managed with pnpm (matching the official dsh install channel; the version is pinned via the `packageManager` field).
|
|
105
|
+
|
|
85
106
|
## Runtime Data Flow
|
|
86
107
|
|
|
87
108
|
<p align="center">
|
|
@@ -183,6 +204,8 @@ lives in the native host seat designed for it; the plugin no longer owns a strip
|
|
|
183
204
|
toggle in Automation. Ideal for debug/eval/sensitive sessions that should absorb
|
|
184
205
|
without interference. Orthogonal to Paused: paused is full stealth (capture off
|
|
185
206
|
too), while write-only keeps the "in" and gates the "out".
|
|
207
|
+
- **Terminal host (TUI)**: the same mode system surfaces in the dsh-tui host as the
|
|
208
|
+
`/memory` command, a status line and a `/settings` section (see Quick Start).
|
|
186
209
|
|
|
187
210
|
## UI Preview
|
|
188
211
|
|
package/README.md
CHANGED
|
@@ -10,26 +10,27 @@
|
|
|
10
10
|
[English](README.en.md) · [最新发行版](https://github.com/JunNanLYS/dsh-layered-memory/releases/latest) · [反馈问题](https://github.com/JunNanLYS/dsh-layered-memory/issues)
|
|
11
11
|
|
|
12
12
|
[](https://www.npmjs.com/package/dsh-layered-memory)
|
|
13
|
-
[](https://github.com/deepseek-ai/deepseek-harness)
|
|
14
14
|
[](LICENSE)
|
|
15
15
|
|
|
16
16
|
</div>
|
|
17
17
|
|
|
18
18
|
## 快速开始
|
|
19
19
|
|
|
20
|
-
需要 Node ≥ 22.16 与 DeepSeek Harness
|
|
21
|
-
0.1.2-
|
|
20
|
+
需要 Node ≥ 22.16 与 DeepSeek Harness **0.1.2-alpha.1 ~ 0.1.2-rc.1**(0.10.0 起
|
|
21
|
+
支持到 0.1.2-rc.1,npm latest 已指向该版本;旧版插件请看
|
|
22
|
+
[历史版本](https://github.com/JunNanLYS/dsh-layered-memory/releases))。
|
|
22
23
|
两种调用方式任选(`npx` 前缀可替换下面任何 `dsh` 命令):
|
|
23
24
|
|
|
24
25
|
```bash
|
|
25
|
-
# 方式一:npx 直接跑官方 CLI(无需预装 dsh
|
|
26
|
-
npx -y @deepseek-ai/dsh
|
|
26
|
+
# 方式一:npx 直接跑官方 CLI(无需预装 dsh)
|
|
27
|
+
npx -y @deepseek-ai/dsh plugin --profile web add dsh-layered-memory
|
|
27
28
|
|
|
28
|
-
# 方式二:已装 dsh CLI
|
|
29
|
+
# 方式二:已装 dsh CLI(升级:npm i -g @deepseek-ai/dsh 并重启;
|
|
29
30
|
# dsh 是 pnpm 转发器,未装 pnpm 时先 npm i -g pnpm)
|
|
30
31
|
dsh plugin --profile web add dsh-layered-memory
|
|
31
32
|
|
|
32
|
-
# 包源备选:GitHub 仓库 / 本地路径(开发调试,link: 指向仓库,
|
|
33
|
+
# 包源备选:GitHub 仓库 / 本地路径(开发调试,link: 指向仓库,pnpm run build + 重启 dsh 即生效)
|
|
33
34
|
dsh plugin --profile web add https://github.com/JunNanLYS/dsh-layered-memory
|
|
34
35
|
dsh plugin --profile web add /path/to/dsh-layered-memory
|
|
35
36
|
```
|
|
@@ -60,17 +61,37 @@ Agent 应当返回安装结果,并明确告诉你配置中是否已经出现 `
|
|
|
60
61
|
**卸载**:`dsh plugin --profile web remove dsh-layered-memory` + 重启。数据保留在
|
|
61
62
|
`~/.dsh/memory/`,不需要时手动删除整个目录即可。
|
|
62
63
|
|
|
64
|
+
### 终端形态(TUI / headless)
|
|
65
|
+
|
|
66
|
+
除 web 外,同一插件可直接装进终端形态宿主:
|
|
67
|
+
|
|
68
|
+
```bash
|
|
69
|
+
# dsh-tui(Claude Code 风格 TUI 前门,详见 github.com/ccch1mneyyy/dsh-TUI · 官网 https://dshtui.com)
|
|
70
|
+
dsh plugin --profile dsh-tui add @deepseek-harness-tui/dsh-tui # 首次:建 profile 并装 TUI 宿主
|
|
71
|
+
dsh plugin --profile dsh-tui add dsh-layered-memory
|
|
72
|
+
dsh --profile dsh-tui
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
- **`/memory <auto|chat|work|off>`** 切换当前会话档位,无参数时弹出档位选择面板;
|
|
76
|
+
- **状态行**:提示框上方常驻 `记忆:智能` 等当前档位读数;
|
|
77
|
+
- **`/settings` 设置区块**:总开关、捕获、蒸馏、召回、蒸馏模型路由与输入预算可直接编辑
|
|
78
|
+
(与 web 设置面板同一存储;复杂路由链仍走 web / YAML);
|
|
79
|
+
- **headless**(`dsh --profile headless "一次性任务"`):捕获与蒸馏照常工作,无界面元素。
|
|
80
|
+
web 与终端形态共享 `~/.dsh/memory/` 同一份记忆。
|
|
81
|
+
|
|
63
82
|
### 从源码开发
|
|
64
83
|
|
|
65
84
|
```bash
|
|
66
85
|
git clone https://github.com/JunNanLYS/dsh-layered-memory
|
|
67
86
|
cd dsh-layered-memory
|
|
68
|
-
|
|
69
|
-
dsh plugin --profile web add . # link: 安装,改代码后
|
|
70
|
-
|
|
87
|
+
pnpm install && pnpm run build
|
|
88
|
+
dsh plugin --profile web add . # link: 安装,改代码后 pnpm run build + 重启 dsh 即生效
|
|
89
|
+
pnpm run smoke # 冒烟测试(先重编:见下方命令)
|
|
71
90
|
npx tsc src/smoke.ts --outDir dist-smoke --module nodenext --moduleResolution nodenext --target es2022 --strict --skipLibCheck --esModuleInterop
|
|
72
91
|
```
|
|
73
92
|
|
|
93
|
+
依赖管理用 pnpm(与 dsh 官方安装通道一致,版本由 `packageManager` 字段钉死)。
|
|
94
|
+
|
|
74
95
|
## 运行时数据流
|
|
75
96
|
|
|
76
97
|
<p align="center">
|
|
@@ -140,6 +161,8 @@ L1/L2/L3 层级过滤)、层级 × 时间窗口表格(调用数 / 输出与
|
|
|
140
161
|
一并停止;`memory_search` 等读工具返回只写提示)。覆盖按会话持久化,切回
|
|
141
162
|
「跟随全局」即清除、跟随自动化区的召回开关;适合调试/评测/敏感会话「只吸收不干扰」。
|
|
142
163
|
与暂停正交:暂停是完全隐身(连捕获都关),只写保留「进」关「出」。
|
|
164
|
+
- **终端形态(TUI)**:同一档位体系在 dsh-tui 宿主下以 `/memory` 命令、状态行与
|
|
165
|
+
`/settings` 区块呈现(安装见快速开始)。
|
|
143
166
|
|
|
144
167
|
## 界面预览
|
|
145
168
|
|
|
Binary file
|
package/assets/changelog/0.9.0/02-/345/267/245/344/275/234/345/217/260/346/200/273/350/247/210.png
CHANGED
|
Binary file
|
|
Binary file
|