lishLRF/DSH-desktop-pet--packages-dsh-plugin1

dsh-desktop-pet

DSH plugin: a desktop pet that mirrors DSH work state in real time and shows task-completion bubbles, with a companion Electron pet window.

包名
dsh-desktop-pet
版本
0.1.0
许可证
MIT
最近更新
2026年8月17日

安装

$npx -p @deepseek-ai/dsh dsh plugin --profile web add github:lishLRF/DSH-desktop-pet#0e9e9a740ff633d2124d340b1759d861686612e0&path:packages/dsh-plugin

dsh-desktop-pet(DSH 插件)

DSH 桌面宠物的插件半边:Host 状态机 + HTTP/WebSocket 桥 + Client 设置卡片。

组成

  • Host 半边src/index.ts
    • 订阅 DSH 事件(agent/statustools/executesubagent/*workflow/*goal/changedapproval/requestagent/erroragent/turn-stopping),派生 9 个状态。
    • webServer 注册 GET/POST /desktop-pet/configGET /desktop-pet/healthWS /desktop-pet/ws
    • 配置持久化到 ~/.dsh/desktop-pet/config.json
  • Client 半边src/client/*
    • 注册 settings.plugin.item 卡片(「设置 → 插件 → 插件配置 → 桌面宠物」)。
    • 通过同源 fetch 读写 /desktop-pet/config

构建

pnpm build        # lib/index.js(host)+ lib/client.js(browser)
pnpm typecheck
pnpm test

Host 半边对 DSH monorepo 无运行时依赖(ws 为唯一运行时依赖);Client bundle 将 react / react/jsx-runtime 作为 external,其余全部内联。

安装

见仓库根 README.md 的「安装与部署」。