shifan3/dsh-approve-for-me

shifan3★ 0JavaScriptLast synced: 2026-08-17

Open on GitHub

Approve-for-me mode for DeepSeek Harness: LLM safety auto-approval for approval requests; high-risk destructive commands still ask the user.

README excerpt

dsh-approve-for-me 中文说明见 README.zh.md。 A DeepSeek Harness (DSH) host plugin that adds an approve-for-me approval mode. When enabled, every approval request that reaches the DSH answerer chain is judged by an LLM safety reviewer against a summary of the prior conversation. The model answers ALLOW or REJECT . Destructive high-risk commands — rm -r , rm -rf , drop table , drop database , and friends — skip the model entirely and are sent to the normal interactive user prompt. The plugin does not add a new approve-for-me policy enum (that is hardcoded in the host package dsh-user-approval ). It works inside the existing ask approval policy: the plugin's enabled state is the mode switch. The DSH approval audit events ( approval/asked + approval/decided ) are still recorded normally. Behavior - Listens on approval/request with prepend: true , so it runs before the interactive (user-prompt) answerer. - Extracts the concrete action text for the request: - command from bash-family tool-call arguments, - tool arguments JSON for other tools, - or the request reason as a fallback. - If the action (or the request reason) matches a high-risk pattern → next() , i.e. the normal user approval promp…

View full README on GitHub →
Tools / Devapprovaldeepseek-harnessdsh-plugin

Category