deepseek-harness
deepseek-ai
DeepSeek Harness: Everything is a Plugin.
PROJECT TOPICS
INSTALL REFERENCE
dsh plugin --profile web add github:cindyguyuehu123/dsh-webchatlike
该命令指向仓库当前默认分支;尚无绑定当前 commit 的完整验证结果。
PROJECT README
把 DeepSeek 网页版 / App 的聊天体验带进 DeepSeek Harness:编辑提问、重新生成回复、在消息上直接翻版本——就像在 deepseek.com 上聊天一样。
一个面向 DeepSeek Harness Web GUI 的客户端插件,让对话行为和 deepseek.com 网页版 / App 一致:原位编辑、一键重新生成、逐条消息的版本翻页器。
历史 + 修改后的提问 + 新回答。<2/5> 翻页器(树状模型:每条消息的版本独立计数)。左右箭头切换版本,自动定位到同一轮。每个对话记住你最后查看的版本——切去别的对话再回来,不会跳回第 1 版。<i/N> 可翻),从此与原树互不影响。副本根标题带 (副本) / (副本 2) 递增,分叉后自动定位到你 fork 时所在的版本。任意侧边栏 / 对话内分叉出来的独立副本(包括非版本族会话的单会话分叉)都带 (副本) 标记——它是边栏区分"独立副本"与"regenerate/编辑版本"的记号,保证新副本一定以独立行出现,不会被折叠隐藏。边栏保持干净:版本 fork 折叠进原始对话(一个对话一行),在任意版本里的活动都会照常把该对话浮到顶部。家族根行上的重命名、归档、删除作用于整棵树(所有 regenerate/编辑版本);分叉副本是完全独立的对话,只作用于自身。
与纯插件不同,本插件扩展了两个 harness 没有公开扩展点的源码文件:
| 补丁 | 文件数 | 作用 |
|---|---|---|
| ui-conversation user-actions 插槽 | 5 | 用户消息下方的 ✏️ 按钮座位 + 原位编辑锚点(position: relative)+ 对话内「分支」复制整棵树 |
| ui-workspace 版本折叠 | 4 | 边栏永远隐藏版本 fork、当前版本映射回原始行、版本内活动折算进对话排序、恢复最后查看的版本、家族级行操作、边栏分叉复制整棵树 |
不打补丁时插件能加载,但编辑按钮和边栏折叠不会出现。cordis.patch.yml 只负责加载插件本身。
cd deepseek-harness
/path/to/dsh-webchatlike/apply-patches.sh # 逐个复制,冲突时提示
pnpm install
pnpm run build:lib:client && pnpm run build:web
方式一:作为 bundle 安装(已声明 dsh.bundle):
dsh plugin --profile web add <本仓库 git 地址或 npm 包名>
方式二:手动在 ~/.dsh/profiles/web/cordis.patch.yml 注册:
- insert:
- id: chat-actions
name: 'dsh-webchatlike'
手动安装时,请把包加入 ~/.dsh/profiles/web/package.json 的 dependencies 并在 profile 目录执行 pnpm install,让加载器能解析到它。
终端 Ctrl+C,重新 pnpm dsh web,刷新页面。
历史 + 提问 + 新回答——与 deepseek.com 的树状模型一致。dsh-webchatlike:version-tree,按家族根命名空间:每棵树一个命名空间,分叉副本与原树互不干扰)和「最后查看版本」映射(dsh-webchatlike:last-version)里。所有读取都是防御式的:没有插件时,边栏行为与原生完全一致。seedLength——版本功能不需要任何 host 改动。为什么对话的第一条消息没有按钮? 第一回合之前没有干净的 fork 边界(harness 的 fork 需要一个已完成的回合作为锚点),所以第一条消息不能重新生成 / 编辑——和大多数网页版聊天一致。
conversation.chat.assistant-actions / conversation.chat.user-actions 插槽、ctx.sessions.fork、session.prompt、ctx.sessions.open)。apply-patches.sh 会先对比再覆盖。MIT
Bring the DeepSeek web / app chat experience to DeepSeek Harness: edit your question, regenerate the answer, and flip between versions — right on the message, like chatting on deepseek.com.
A client plugin for the DeepSeek Harness Web GUI that makes conversations behave like the deepseek.com web/app chat — in-place editing, one-click regeneration, and a per-message version pager.
history + edited question + new answer.<2/5> pager (tree model: each message's versions are counted independently). Flip through versions with the chevrons; the same turn is scrolled into view. The version you were viewing is remembered per conversation, so switching chats and coming back does not throw you to version 1.<i/N> pager works), never interacting with the source again. The copy root is titled base (副本) / (副本 2) etc., and the new tree opens at the version you forked FROM. Every independent copy created by the sidebar or in-chat fork action (including plain single-session forks outside any version family) carries the (副本) marker — the sidebar's tell that distinguishes an independent copy from a regenerate/edit version, so a new copy always shows up as its own row and is never folded away.The sidebar stays clean: version forks are folded into their original conversation (one row per conversation), and activity inside any version still floats that conversation to the top. Family-ROOT rows act on the whole tree for rename/archive/delete (all regenerate/edit versions); fork copies are fully independent conversations that only ever act on themselves.
Unlike pure plugins, this one extends two harness source files that have no public extension points:
| Patch | Files | What it adds |
|---|---|---|
ui-conversation user-actions slot |
5 files | the ✏️ button seat under user messages + the in-place edit anchor (position: relative) + in-chat "branch" copies the whole tree |
ui-workspace version-fork folding |
4 files | hide version forks from the sidebar (always), alias the open fork to its original row, fold fork activity into the conversation's recency, restore the last-viewed version, family-wide row actions, sidebar fork copies the whole tree |
Without them the plugin loads but the edit button and sidebar folding stay off. cordis.patch.yml only loads the plugin itself.
cd deepseek-harness
/path/to/dsh-webchatlike/apply-patches.sh # copies files, prompts on conflicts
pnpm install
pnpm run build:lib:client && pnpm run build:web
Either install it as a bundle (it declares dsh.bundle):
dsh plugin --profile web add <this-repo-git-url-or-npm-name>
…or register it manually in ~/.dsh/profiles/web/cordis.patch.yml:
- insert:
- id: chat-actions
name: 'dsh-webchatlike'
If you install manually, make the package resolvable from the profile (e.g. add it to ~/.dsh/profiles/web/package.json dependencies and pnpm install there).
Ctrl+C and pnpm dsh web again, then refresh the browser.
history + question + new answer — matching deepseek.com's tree model.dsh-webchatlike:version-tree, namespaced by family ROOT — each tree gets its own namespace, so forked copies never collide with the source), and the "last viewed version" map (dsh-webchatlike:last-version). Reads are fully defensive: without the plugin the sidebar behaves exactly as stock.seedLength is not used — no host changes needed for versioning.Why are there no buttons on the very first message of a conversation? The first turn has no clean fork boundary before it (the harness fork needs a completed turn to anchor to), so regenerate/edit are unavailable there — same as the first message in most web chats.
conversation.chat.assistant-actions / conversation.chat.user-actions slots, ctx.sessions.fork, session.prompt, ctx.sessions.open).apply-patches.sh diffs and asks before overwriting.MIT
CLASSIFICATION EVIDENCE
系统优先读取 GitHub Topics,再与站内分类词典和词根规则比对。当前命中: 无有效分类标签。