DSH Plugins Marketplace

DSH Plugins

Plugins

/

Workflow & Automation

/

dsh-keep-awake

b

dsh-keep-awake

Manifest valid

Holds the OS wake lock while any agent, subagent, or background job runs, releases it after a configurable grace period, and provides a bilingual web settings page with live status, manual hold, and d

UI (client)hasBundlePatch

dsh-keep-awake

DeepSeek Harness 防休眠插件(界面跟随 DSH 全局语言)

任意 agent / subagent / 后台任务运行时阻止系统休眠 · 全部空闲后按宽限期自动释放 · 手动保持唤醒 · 可选阻止屏幕关闭 · Windows / macOS / Linux · 设置持久化 · 多语言 Web 设置页

version license dsh

English | 中文

设置页截图

功能总览

功能位置说明
实时状态设置页「防休眠」状态徽章(保持唤醒中 / 宽限中 Ns / 待机 / 已停用 / 助手异常)、运行中 agent 数、后台任务数、辅助进程平台 + PID
活动判定—运行中的 agent(主 agent / subagent / workflow 子代理)+ 运行中的后台任务(run_in_background 命令 / 后台 subagent 任务)
宽限期设置页可配全部活动结束后 15s–5m(默认 60s)自动释放防休眠
手动保持设置页无视活动状态强制保持唤醒,点击取消
阻止屏幕关闭设置页可选默认只防系统休眠、允许熄屏;勾选后屏幕也保持
多语言全局跟随 DSH 全局语言(zh/en),未显式设置时跟随浏览器/系统,切换即时生效(含侧边栏标签)

工作原理

每 5 秒轮询 + 事件即时重扫(agent/status、subagent/start|end、job 集变更):

  • 运行中的 agent:agents.list() 中 status === 'running' 的 agent(覆盖主 agent、subagent、workflow 子代理)
  • 后台任务:jobs.list() / jobs.list(agent) 中 running/stopping 的任务(覆盖 run_in_background 命令与后台 subagent 任务)

检测到活动时通过 subprocess 服务启动一个平台辅助进程(树级终止,进程退出即释放休眠标志):

平台机制
WindowsPowerShell SetThreadExecutionState(ES_CONTINUOUS | ES_SYSTEM_REQUIRED)(勾选“同时阻止屏幕关闭”时加 ES_DISPLAY_REQUIRED)
macOScaffeinate [-d] -i -s
Linuxsystemd-inhibit --what=idle --mode=block sleep 1e8

设置

持久化在 profile 的 settings.yaml(namespace keep-awake):

键默认说明
enabledtrue总开关
graceMs60000全部活动结束后的宽限期(15s–5m)
preventDisplaySleepfalse同时阻止屏幕关闭
manualHoldfalse手动保持唤醒

多语言

界面使用框架 locale 服务(namespace keep-awake,zh/en 字典):未显式设置语言时自动跟随浏览器/系统语言;在 DSH 语言设置中切换后即时生效(设置页正文与侧边栏标签均跟随)。

HTTP 路由(loopback)

  • GET /dsh-keep-awake/state — 当前状态(活动计数、助手进程、配置)
  • PUT /dsh-keep-awake/config — 更新配置,body { "section": {...} }

安装

# 在 profile 目录内(如 ~/.dsh/profiles/web)
pnpm add "dsh-keep-awake@<来源>"   # npm / github:bearice/dsh-keep-awake / link:<本地路径>
# 并把 "dsh-keep-awake" 加入 package.json 的 dsh.profile.bundles
pnpm install
# 重启 profile

开发

  • 本地开发建议以 link: 方式挂入 profile(见上方安装步骤),node --check lib/*.js 做语法校验
  • 包结构:lib/index.js(Host)、lib/client.js(Web 设置页)、cordis.patch.yml(挂载行)

Compatibility

DSH 0.2.1-rc.2: failedDSH 0.2.1-rc.4: failedDSH 0.2.1-alpha.4: failed

Versions

Latest versionPublishedSize
0.1.0——
0.2.0——

Comments

Loading…

Similar plugins

dsh-keep-awake

Keeps the DSH host awake during active tasks using native power assertions and releases them when tasks finish.

Tools & CapabilitiesManifest valid

★ 0

dsh plugin --profile web add @zi7tian/dsh-keep-awake

by edusrez

Wakes the main agent after any DSH restart so interrupted work resumes automatically — adds a restart tool and an optional canary that validates the boot and warns instead of breaking.

Tools & CapabilitiesManifest valid

★ 8

↓ 184/wk

MIT

JavaScript

Sep 22, 2026

dsh plugin --profile web add dsh-smart-restart

by nickkkkkk123123

Auto-wakes the main agent after a DSH service restart: compares last-run timestamps, posts a recovery notice with humanized downtime, and delivers it so interrupted work picks itself back up. Runs on

Development & InfrastructureTerminal & ClientsSessions & MessagesManifest valid

★ 1

MIT

JavaScript

Aug 29, 2026

dsh plugin --profile web add dsh-resume-on-restart

by fuhefei

Condition-driven wakeup for DeepSeek Harness: durable file/command/http/process/webhook watches that wake the agent, with dock, sidebar branch, and a global dashboard.

Workflow & AutomationManifest valid

★ 21

↓ 92/wk

BSD-3-Clause

TypeScript

Oct 19, 2026

dsh plugin --profile web add dsh-sentinel

by bitsmug

Runs commands as background jobs that keep executing when DSH exits, with an optional sandbox to constrain file effects, plus a live web panel and offline CLI/GUI management. Windows only for now.

Tools & CapabilitiesTerminal & ClientsManifest valid

★ 3

↓ 223/wk

MIT

JavaScript

Oct 24, 2026

dsh plugin --profile web add bgjobs

by mostkia

Power controls (shutdown / restart) for the DSH sidebar plus a Windows tray launcher with start-at-logon.

UI & ExperienceDevelopment & InfrastructureManifest valid

★ 0

MIT

PowerShell

Oct 5, 2026

dsh plugin --profile web add @mostkia/dsh-launcher