Tisitan/dsh-live2d-companion 预览 preview

Tisitan/dsh-live2d-companion

Desktop桌面端 Native原生 ⭐ 12 MIT Pets & Fun桌宠与娱乐Productivity & Tasks效率与任务

Live2D 监控面板・看板娘桌宠 for DeepSeek Harness

Project Overview项目介绍

This is a DSH-native plugin that adds a Live2D status monitor and desktop pet to the DeepSeek Harness ecosystem. It syncs in real time with DSH’s AI session workflow, matching different AI working states to custom Live2D character motions, expressions, and spoken lines. It ships with two operating modes: an embedded widget in the DSH web GUI and a standalone Electron-based transparent always-on-top desktop pet for Windows. It does not bundle any specific Live2D character model, and any compatible Cubism 4 or 5 third-party model can be added simply by placing the unpacked files in the correct directory.

The plugin receives DSH session events via a whitelisted forwarding layer, and maintains an 8-state state machine on the frontend that covers idle, thinking, working, waiting for user approval, error, completed, sleeping, and offline states. It includes an on-panel status light display that shows the progress of multiple parallel DSH tasks, with a main aggregated light and individual lights for each running task. It comes with a variety of user interactions including click reactions, drag-to-move, petting interactions, and full-screen cursor tracking, plus a built-in game center with Gomoku and chess that supports LLM-powered personality commentary. This tool is ideal for users who want to add a personalized interactive desktop element to their daily DSH workflow.

The plugin mounts to DSH via a cordis patch layer, so it requires zero modification to DSH core code and is immune to DSH version upgrades. The code in this repository is licensed under the MIT license, but it does not include any Live2D character models or the Cubism Core JavaScript library, which must be obtained separately from official sources and comply with their respective licenses. It depends on three open-source packages: pixi.js, pixi-live2d-display, and Electron. Currently, the desktop pet mode only supports single primary monitor setups, with multi-monitor support still in development, and there is also a standalone mode that works fully without running DSH.

这是DeepSeek Harness(DSH)的原生插件,提供Live2D状态监控挂件和桌面桌宠功能,可实时同步DSH的AI会话工作状态,给不同AI状态匹配对应Live2D角色表情与互动台词。支持两种形态:DSH网页GUI右下角挂件,或是独立Windows桌面透明置顶桌宠,不绑定特定角色,任何Cubism 4/5模型放入指定目录即可接入使用。

插件通过DSH会话事件流转发获取状态,前端维护8态状态机,涵盖空闲、思考、工作、等待用户确认、报错、完成、睡眠、离线,还内置多任务状态灯显示当前任务进度。自带丰富交互:点击反馈、拖拽移动、摸头互动、全局视线跟随等,还内置五子棋和国际象棋游戏中心,支持LLM人格化解说,适合喜欢给DSH添加个性化桌面互动元素的用户。

本插件对DSH本体零修改,通过cordis补丁层挂载,不受DSH升级影响。仓库代码遵循MIT许可,不包含Live2D模型和Cubism Core文件,模型需要用户自行准备,依赖pixi.js、pixi-live2d-display和Electron,当前仅支持单主显示器,多显示器功能待扩展,独立运行模式也支持不启动DSH直接使用桌宠。

Pre-install check安装前体检Compatibility · Security兼容性 · 安全性 1 warning1 项注意
  • 12 stars - an early-stage project星标 12,属于早期项目
  • Desktop client: installation downloads an executable - verify the publisher and checksums桌面客户端:安装会下载可执行文件,请核对发布者与校验和
DSH walks through these 9 checksDSH 会逐条核对这 9 项

Compatibility兼容性

  • DSH, Node, OS and profile requirementsDSH 版本 / Node 版本 / 操作系统 / profile 是否满足要求
  • External dependencies and runtimes (Electron / Python / Docker, ...)外部依赖与运行时(Electron / Python / Docker 等)是否齐备
  • Conflicts with installed plugins: command names, skill / tool names, ports, duplicate MCP registration与已装插件是否冲突:命令名、skill / tool 重名、端口占用、重复 MCP 注册

Security安全性

  • Repo matches the facts registered here; archived or abandoned?仓库是否与页面登记一致,是否归档或长期停更
  • Safety of preinstall / install / postinstall and install.sh / setup.ps1preinstall / install / postinstall 与 install.sh、setup.ps1 是否安全
  • curl|bash, download-then-execute, obfuscation, unrelated domains → stop immediatelycurl|bash、下载即执行、混淆代码、无关域名 → 立刻停止
  • Typosquatting or unmaintained packages among the new dependencies新增依赖里有没有 typosquatting 或无人维护的包
  • Requested permissions vs. what the feature actually needs申请了哪些权限、是否超出功能所需(filesystem / network / shell / clipboard)
  • Any sudo / admin requirement, plus uninstall and rollback是否要求 sudo / 管理员权限,以及卸载与回滚方式

Anything uncertain must be marked unknown with a note on how to confirm it. This site's signal screen is a static snapshot, not a security audit.拿不准的必须标「未知」并说明要我怎么确认。本站的信号筛查是静态快照,不能替代安全审计。

Or use CLI install (for developers)或使用命令行安装(适合开发者)

CLI Install命令行安装

dsh plugin --profile web add github:Tisitan/dsh-live2d-companion

把 Tisitan/dsh-live2d-companion 加入你的 DSH 配置(web profile)即可启用。

READMEREADME

Live2D 监控面板・看板娘桌宠(dsh-live2d-companion)

DeepSeek Harness(下称 DSH)的 Live2D 状态监控面板:把你喜欢的 Live2D 角色接进 DSH Web GUI,实时反映 AI 的工作状态——思考时歪头、工作时兴奋、等你确认时招手、闲着没事会打瞌睡,还能陪你下五子棋和国际象棋。不绑定任何特定角色:任何 Cubism 4/5 模型丢进 model/ 目录即可上岗(详见模型接入与绑定层)。

双形态:网页右下角挂件 / Windows 桌面桌宠(Electron 透明置顶窗口),同一份前端内核驱动。

另提供 standalone/ 独立运行入口:不启动 DSH 也能使用同一套桌宠渲染、模型面板、游戏中心和 Codex/OpenCode 状态联动(含 OpenCode 对局解说)。独立版仍不包含模型、Cubism Core、Electron 二进制或第三方角色 Prompt,详细许可边界与安装步骤见 standalone/README.md。

特性

  • 🎭 AI 状态同步:订阅 DSH 会话事件流,8 态状态机(空闲/思考/工作/等待确认/报错/完成/睡眠/离线)+ 左上角状态灯(小灯+文字常显);多任务并行时每会话一枚独立任务灯(任务1·工作 / 任务2·待确认…),聚合主灯 + 分工小灯一目了然;任务完成后 6 秒转闲置、闲置 5 分钟自动收灯回收编号,会话复活自动重新上牌
  • 🖱️ 丰富交互:点击反应、双击卖萌、点击摸头害羞(划过不误触)、拖拽搬家、睡着点一下叫醒、缩放(挂件滚轮 / 桌宠 Ctrl+滚轮,拖拽期间自动锁定)、全局视线跟随(OS 层轮询光标,整屏追踪不限窗口)
  • 💬 气泡台词:15 个台词池 70+ 条,状态轮播、时段问候、加班焦虑、深夜关怀
  • ⚙️ 全配置化:台词/节奏/行为阈值都在 quips.json(官方默认);台词支持多预设可视化编辑(「词」按钮:另存为多份人设台词集、一键切换、池级恢复默认,保存即生效)
  • 🐾 桌面桌宠:透明无边框置顶、鼠标穿透(不挡操作)、位置记忆、随 DSH 启停(心跳看门狗)、面板内一键重启 / 双击确认退出
  • 🧩 多模型:任何 Cubism 4/5 模型丢进 model/ 目录即可接入;语义槽位 + 自动嗅探 + profile.json 绑定层,情绪表现零配置自适应
  • 🖼️ 模型面板:挂件旁静置自动隐藏的齿轮入口,扫描/切换/导入/预览模型,选择持久化,恢复默认无需改配置
  • 🔌 零侵入:对 DSH 本体零修改,纯用户级 cordis patch 层挂载,DSH 升级免疫
  • ♟️ 游戏中心:五子棋 / 国际象棋开箱即玩,本地引擎裁决 + 本地 AI 执子 + LLM 人格化解说,还有让模型亲自执子的「阿尔法狗」难度——详见游戏中心一节
  • 🫧 气泡优先级仲裁:0=状态轮播 1=对局解说/思考 2=物理互动/任务完成/报错——低级不抢高级,完成事件必达,对局闲聊压不住正事

架构

dsh 宿主进程
 └─ cordis patch 层(cordis.patch.yml insert 行)
     └─ index.js(宿主插件)
         ├─ prefix 路由 /live2d/*        → 静态资源(前端/模型/vendor)
         ├─ SSE  /live2d/state-stream    → session/event 白名单转发 + 聚合状态兜底
         ├─ exact /live2d/state|config   → 状态快照 / 模型配置
         ├─ exact /live2d/models         → 扫描 model/ 下全部模型(GET)
         ├─ exact /live2d/model          → 切换/恢复/删除模型并持久化(POST)
         ├─ exact /live2d/mode           → 显示模式切换:改写 cordis.patch.yml 本插件 config,热重载生效(POST)
         ├─ exact /live2d/import         → 上传模型文件(POST)
         ├─ exact /live2d/profile        → 绑定档案写/删(POST,白名单清洗)
         ├─ exact /live2d/quips          → 台词预设存/切/删(POST,写 quips-presets/)
         ├─ exact /live2d/quips-config   → 预设清单与生效指针(GET)
         ├─ exact /live2d/game/list      → 游戏目录(GET,游戏中心 chips 数据源)
         ├─ exact /live2d/game/models    → 模型目录(GET,llm.listModels 网关发现 + settings 兜底)
         ├─ exact /live2d/game/presets   → agent 预设清单(GET,喂对局面板下拉)
         ├─ exact /live2d/game/state     → 对局快照:注册表描述符 snapshot + busy/模式/难度/解说(GET)
         ├─ exact /live2d/game/new       → 开新局:本地引擎+本地 AI 执子;在线加建人格化解说 agent(零工具)(POST)
         ├─ exact /live2d/game/move      → 玩家走子→本地 AI 应手(阿尔法狗档=LLM 标签协议执子,非法重试/超时兜底本地 hard)→在线 LLM 解说(25s 超时 cancel+本地台词兜底)→响应同帧带 aiMove+解说(POST)
         ├─ tapIndex 注入 <script>       → 网页挂件(widget: false 可关)
         └─ spawn Electron 桌宠          → 随宿主启停(pet: false 可关);重挂载收养旧进程不闪断,退出延迟处死+宿主 exit 兜底防孤儿

浏览器挂件 / Electron 桌宠
 └─ boot.js(ES Module 入口装配)+ src/ 职能模块:
     ├─ config.js    → 环境常量 / localStorage / 台词库加载
     ├─ binding.js   → 语义槽位绑定(profile 覆盖 + model3.json 嗅探)
     ├─ ui.js        → 容器 / 气泡 / 状态灯
     ├─ stage.js     → PIXI 渲染 / 模型加载 / 布局收身 / 缩放 / Idle 池守卫
     ├─ state.js     → 8 态状态机(灯 + 表情 + 动作 + 台词轮播)
     ├─ interact.js  → 点击/摸头/拖拽/缩放/穿透/全局视线
     ├─ stream.js    → SSE 客户端(raw 优先 / coarse 兜底 / 离线检测)
     ├─ panel.js     → 模型面板(入口/列表/切换/查看/导入/绑定编辑器)+ 竖列按钮簇(🔒❓⚙️🎮💬)
     ├─ game.js      → 游戏中心壳(卡片/游戏 chips/通用设置条/轮询/动画驱动/解说声道,全游戏无关)
     ├─ games/<id>.js → 前端渲染器(棋盘绘制/点击映射/走子动画;gomoku.js、chess.js)
         └─ pixi.js + pixi-live2d-display + Live2D Cubism Core

Showing the opening section of the README — the full document lives in the repository以上为 README 开头摘要,完整文档在仓库内 · View the full README on GitHub →在 GitHub 查看完整 README →

← 上一个 Prev deepseek-harness-launcher 下一个 Next dsh-quota-panel →