DeepSeek Harness 插件

dsh-session-title-cold

冷会话标题回填:把持久化日志里的 session/title 事件折叠进 projection 缓存,让 session.list 的 projections 带上真实标题——侧边栏会话列表不再全部显示工作区目录名(dsh)。(英文原文)

跳到安装方式

来源信息

GitHub 仓库
fengs2021/dsh-session-title-cold
最近更新
2026年8月17日
分类
记忆
GitHub stars
0
载体类型
plugin
目录证据
上游声明已找到 dsh.bundle
证据路径
package.json#dsh.bundle
核对版本
0.1.0-rc.8
上游核对日期
2026-08-20

该证据由上游目录提供。本站没有安装、运行或安全审核这个插件。

安装

默认先复制一段 Prompt,让 Agent 读 GitHub 仓库和源码;需要自己装时再切到命令。

复制这段 Prompt,发给 DSH、Codex 或其他 Agent,让它先读 GitHub 仓库和源码。

请先不要安装或执行任何命令。阅读这个插件的 GitHub 仓库、README 和关键源码,然后用清楚、直接的方式回答以下问题,帮助我判断它是否适合我的需求:

1. 这个插件是什么,解决什么问题;
2. 适合哪些用户和典型使用场景;
3. 安装后如何使用,并给出一个最小使用示例;
4. 有哪些已知限制,以及隐私、安全、兼容性或维护风险;
5. 给出“推荐 / 有条件推荐 / 不推荐”的明确建议和理由。

请区分仓库明确说明、根据源码推断和未知信息。证据不足时请明确说明,不要猜测或照抄 README。

GitHub:https://github.com/fengs2021/dsh-session-title-cold
插件名:dsh-session-title-cold
作者:fengs2021

检查来源文件

安装前先看这个插件目录里的 README 和其他文件。

文件资源管理器2 个文件
README.md来源说明 · 只读预览

dsh-session-title-cold

> Cold-session title backfill for DeepSeek Harness: rows in session.list that come from persisted cold sessions (never opened, especially subagent children) have no projection cache, so the sidebar falls back to the workspace directory name — a screen full of "dsh" with no way to tell sessions apart. This plugin scans persisted sessions in the background, folds each registered projection unit (title / sessionStats / sessionListMetadata …) down to the latest event, and writes the title back into the projection cache. > > DSH 冷会话标题回填:后台扫描持久化会话,把投影单元折叠到最新事件并写回缓存,会话列表显示真实标题而不是工作区目录名。

---

English

Problem

session.list rows backed by persisted cold sessions (never opened, especially subagent children) have no projection cache, so the sidebar falls back to the workspace directory name (e.g. dsh) — you cannot tell sessions apart.

What it does

On startup (and then incrementally), scans all persisted sessions, folds each registered projection unit (title / sessionStats / sessionListMetadata …) down to the latest event, and writes the title back into the projection cache. Afterwards every session.list row carries projections.values.title, and the frontend shows the real title (fallback: first message, or the LLM/user rename).

Features

  • Zero intrusion: no dsh source changes; a pure server-side plugin using the official projection registration/cache extension points
  • Incremental: sessions that already have cache rows only read the event tail (restoreFloor → readFrom), refreshed every 10 minutes; new renames are absorbed automatically
  • Fail-soft: a single session failure logs at debug level and never blocks the batch; live sessions are skipped (their cache is maintained by the runtime persistence path, avoiding overwriting fresh state)

Install

  • Plugin directory: ~/.dsh/plugins/dsh-session-title-cold/
  • Profile registration (cordis.patch.yml):
- insert:
    - id: session-title-cold
      name: dsh-session-title-cold

Restart dsh web — backfill starts 5 seconds after boot (log [title-cold] 回填完成:N 个会话), refresh the web sidebar to see real titles.

Config (optional)

- id: session-title-cold
  name: dsh-session-title-cold
  config:
    backfillDelayMs: 5000     # delay before backfill after boot
    refreshIntervalMs: 600000 # incremental refresh period
    concurrency: 3            # concurrent disk reads

How it works

1. sessionProjections.restoreFloor(checkpoint) → incremental read floor 2. sessionPersistence.readFrom(id, floor) → read the tail events (with seq) 3. sessionProjections.restore(checkpoint, events, floor) → fold all unit snapshots (including title from session/title events: fallback / user rename) 4. Merge only the title row into the cache and write back via sessionProjectionCache.putSoft (other units of a cold session may hold non-pure-JSON state — skipped to avoid not losslessly JSON-serializable rejections of the whole row) 5. The next session.list carries projections.values.title; displayTitleOf no longer falls back to the directory name

中文

问题

session.list 的行若来自持久化冷会话(从未打开过、尤其 subagent 子会话),projection 缓存里没有它们的行,列表拿不到标题,侧边栏只能 fallback 显示工作区目录名(如 dsh),一屏全是 "dsh" 分不清谁是谁。

功能

启动后后台扫描全部持久化会话,把每个已注册 projection unit(title / sessionStats / sessionListMetadata 等)折叠到最新事件并写回 projection 缓存;之后 session.list 每行都带 projections.values.title,前端列表直接显示真实标题(fallback 自首条消息,或 LLM/用户重命名)。

特性

  • 零侵入:不改 dsh 源码,纯服务端插件,利用官方 projection 注册/缓存扩展点
  • 增量:已有缓存行的会话只读事件尾部(restoreFloor → readFrom),每 10 分钟刷新一次,rename 等新标题变化自动吸收
  • fail-soft:单个会话失败只记 debug 日志,不阻断批次;live 会话自动跳过(它们的缓存由运行时落盘路径维护,避免覆盖新状态)

安装

  • 插件目录:~/.dsh/plugins/dsh-session-title-cold/
  • profile 注册(cordis.patch.yml):
- insert:
    - id: session-title-cold
      name: dsh-session-title-cold

重启 dsh-web 后,启动 5 秒后台回填(日志 [title-cold] 回填完成:N 个会话),刷新网页侧边栏即可看到全部真实标题。

配置(可选)

- id: session-title-cold
  name: dsh-session-title-cold
  config:
    backfillDelayMs: 5000     # 启动后多久开始回填
    refreshIntervalMs: 600000 # 增量刷新周期
    concurrency: 3            # 并发读盘数

工作原理

1. sessionProjections.restoreFloor(checkpoint) 得出增量读起点 2. sessionPersistence.readFrom(id, floor) 读尾部事件(带 seq) 3. sessionProjections.restore(checkpoint, events, floor) 折叠出全部 unit 快照(含 title,来自 session/title 事件,如 fallback/用户重命名) 4. 只把 title 行合并进缓存并 sessionProjectionCache.putSoft 写回(cold 会话其余 unit 的 state 可能含非纯 JSON 值,跳过不写,避免 not losslessly JSON-serializable 拒绝整行) 5. 前端下一次 session.list 即带 projections.values.titledisplayTitleOf 不再 fallback 到目录名

License

MIT