davidgereb/dsh-plugin-prompt-guard ↗★ 0
dsh-plugin-prompt-guard
DSH Web 提示词守护插件。保持未处理的权限审批和多选提示可见,提供一键恢复栏、标签页后台运行时的浏览器通知,以及通过 ntfy.sh 的主机端推送。
AI 分析
核心用途是防止 DSH 运行中的审批提示因页面刷新或同步而消失,并提供后台通知。适合需要长时间运行复杂任务、无法时刻盯着网页的用户。使用推送功能需配置 ntfy.sh 通道。
安装
此插件尚未提供可验证的 bundle,或兼容性检查未通过。请先阅读仓库说明。 阅读完整 README ↗
说明文档
阅读完整 README ↗Configuration
Per-entry config: in cordis.patch.yml, overridable live from the
Settings → Plugins → Configurable card (UI settings persist to
$DSH_HOME/storages/prompt-guard-settings.json and take precedence):
| Key | Default | Meaning |
|---|---|---|
ntfyTopic | "" | ntfy.sh topic to push to when the agent needs the user and no browser client is open. Empty disables the push channel. |
ntfyToken | "" | Optional ntfy.sh access token for private topics (Authorization: Bearer). |
ntfyPriority | 4 | ntfy message priority 1–5 (min/low/default/high/max). |
cooldownSec | 5 | Minimum seconds between two host notifications (burst guard). |
clickUrl | http://127.0.0.1:3080 | URL opened when a notification is tapped (ntfy Click header); empty disables. The GUI's default address. |
notifyWhileBrowserOpen | false | Also push while a browser client is connected (default: the browser half handles that case). |
browserNotify | true | Browser system notifications master switch. |
browserNotifyOnlyUnfocused | true | Only notify while the tab is hidden/unfocused. |
Client-side toggles NOTIFY_ENABLED / NOTIFY_ONLY_WHEN_UNFOCUSED in
src/client-source.js are read at build time.