Letter2025/dsh-approval-llm ↗★ 7

dsh-approval-llm

提供基于独立评审模型的自动化权限审批机制 适合希望引入AI模型代替人工,对敏感操作或工具请求进行智能审批的用户。

套件
dsh-approval-llm
相容性
待驗證
Harness 依賴範圍
^0.1.2-rc.1
Cordis 依賴範圍
*
版本
0.1.6
授權
MIT
最近更新
2026年9月8日

安裝

$npx -p @deepseek-ai/dsh dsh plugin --profile web add github:Letter2025/dsh-approval-llm

Configuration

All fields are validated by the Loader schema; defaults apply when omitted.

FieldDefaultMeaning
enabledtrueMaster switch; when false every request is delegated unchanged.
modePresetmodel-approvalThe permission preset that activates the reviewer. When set, the plugin only answers asks from sessions whose effective preset equals this name; every other session delegates to the human channel. Set to '' to review every ask.
provider / modelunsetExplicit reviewer route. Must be set together; when unset the plugin reuses the conversation route from the last request/header in the session log, and fails to human when the log has none.
timeoutMs60000End-to-end reviewer deadline; on expiry the request is handed to a human (TIMEOUT, not counted in the breaker).
maxOutputTokens256Reviewer output cap.
systemPromptbuilt-in policyCustom security policy for the reviewer. The built-in policy is a short allow-by-default, deny-on-critical-harm rule set; see src/reviewer.ts.
allowlist[]Tool names auto-approved without a model call (SAFE_ALLOW).
denyList[]Tool names rejected outright without a model call. Wins over the allowlist.
humanOnlyList[]Tool names that must be decided by a human; never auto-reviewed.
maxConsecutiveDenials3Consecutive DENY threshold per session before the reviewer hands off to a human; 0 disables the breaker. ALLOW resets the counter.
maxArgsChars4000Cap on tool-argument JSON rendered to the reviewer.
includeArgstrueRecover tool arguments from the session log for the review.
notifyUsertrueAppend a user-visible decision message (✅ 模型审批通过/❌ 模型审批拒绝 with the risk and reason) to the session after every model ALLOW/DENY, so the main chain records why.

Example overlay (cordis.patch.yml of your profile):

- id: approval-llm
  config:
    provider: deepseek-official
    model: deepseek-v4-flash
    allowlist: [read, read_image, glob, grep]
    humanOnlyList: [delete, terminal_send]
    denyList: [job_kill]
    maxConsecutiveDenials: 3