dsh-web
zhu1090093659/dsh-webDeepSeek Harness(DSH)Web 插件聚合生态包 · 一切皆插件,创意工坊分发(dsh-market.com)
Minimal live taskboard plugin for DSH (DeepSeek Harness): what Claude Code / Codex / DSH / Open Design are doing right now - list + swimlane timeline.
A minimal live taskboard for DSH (DeepSeek Harness): see at a glance what Claude Code / Codex / DSH / Open Design are doing right now. Sidebar panel + main view, list and swimlane-timeline, refresh every 5 seconds, no daemon of its own.
一个极简的实时任务台:一屏看清 Claude Code / Codex / DSH / Open Design 现在在干什么。
列表:一行一个任务(状态点、名称、agent、耗时、多久之前),点一行展开目录 / 退出码 / 结果 / 产物。
时间线(泳道):一条泳道 = 一个 agent,一根横条 = 一个任务,横轴是时间。
布局是纯函数 buildTimeline(tasks, { now, windowMs })(也 export 出去给测试用):返回 { from, to, ticks, lanes: [{ agent, label, rows: [[item]], count }] },每个 item 带 left/width(0~1 的窗口占比)与 running。没有开始时间、或完全落在窗口外的任务会被丢掉。
| 来源 | 位置 | 说明 |
|---|---|---|
| 事件日志 | <stateDir>\events.jsonl | 由你自己的 agent 包装器调用一个写入脚本(本机用的是 aiagent-log.ps1,未随本仓库发布)追加 start/end/artifact 行 |
| Open Design | daemon HTTP(端口随机) | 每次轮询用 data\diagnostics\daemon-health.json 的 pid + netstat 找到端口,再读 /api/routines 与最近一次 run;找不到就显示“未运行” |
| 会话目录 | <sessionRoots>\* | 最近改动的工作目录 |
路径全部可配(见下面「配置」)。默认值从家目录推导,例如 Windows 上 %USERPROFILE%\aiagent\.state\events.jsonl。
宿主半只暴露一个只读路由:GET /api/aiagent-taskboard/state(4 秒缓存)。
注册时必须声明 requestBody: 'buffered'。DSH 的 /api 桥接层用这个字段决定怎么构造 fetch Request;缺了它,已注册的路由会走 streaming 分支,new Request(url, { method: 'GET', body: <stream> }) 抛 TypeError: Request with GET/HEAD method cannot have body.,webserver 把逃逸的异常转成裸的 HTTP 400(面板上就是红字 HTTP 400)。
从 GitHub 安装(推荐让 DSH 的插件管理器接管依赖与更新):
dsh plugin --profile desktop add dsh-aiagent-taskboard@git+https://github.com/linglanxin/dsh-aiagent-taskboard.git
# 具体子命令以 `dsh plugin add --help` 为准;也可以 clone 到 <profile>\node_modules\ 下再用下面的脚本
本机脚本安装(Windows,PowerShell):
powershell -ExecutionPolicy Bypass -File tools\install.ps1 # 目标 profile 默认 desktop
powershell -ExecutionPolicy Bypass -File tools\uninstall.ps1
安装只做两件事:在 <profile>\node_modules\ 建目录 junction;在 <profile>\cordis.patch.yml 追加 - insert: 行(并备份原文件到 ~\.dsh\.dsh-rollback-*)。
宿主半(index.js)改动后必须重载 DSH:本 profile 没开 HMR(plugin-manager.reload() 在 ctx.get("hmr") === undefined 时直接跳过),改 cordis.patch.yml 也不会热重载;客户端半(client.js)改完刷新页面即可。index.js 每次 apply() 会往 <AIAGENT_STATE_DIR>\host-loads.log 追加一行 taskboard-host v2 GET+buffered,用来确认运行中的宿主半到底是哪个版本。
优先级:环境变量 > 插件目录下的 local.config.json(已 gitignore)> 家目录默认值。
| 设置 | 环境变量 | local.config.json | 默认(Windows) |
|---|---|---|---|
| agent 根目录 | AIAGENT_HOME | agentHome | %USERPROFILE%\aiagent |
| 事件日志目录 | AIAGENT_STATE_DIR | stateDir | <agentHome>\.state |
| 会话根目录 | AIAGENT_SESSION_ROOTS(; 分隔) | sessionRoots(数组) | <agentHome>\{codex,claudecode,dsh} |
| Open Design 数据目录 | OD_DATA_DIR | odDataDir | %APPDATA%\Open Design\namespaces\release-stable-win\data |
复制 local.config.example.json 为 local.config.json 再改;文件缺失或格式不对时静默回落默认值。
aiagent-log.ps1 以及 codex.cmd / claude.cmd / conductor.cmd / ai-od.cmd)是另一套本机脚本,没有随包发布。缺了它们,任务列表为空,只剩「会话目录」与「Open Design」两块数据。<stateDir>\events.jsonl 即清空历史。node test\host.test.mjs # 事件折叠/状态/耗时/产物/agent 汇总 + 路由 requestBody 回归
node test\client.test.mjs # bundle 注册、面板渲染、buildTimeline 布局(窗口裁剪/泳道分行/运行中拉到现在)