@dsmm/dsmm 0.3.9 → 0.3.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -5
- package/agent-presets/dsmm-builder/agent.cordis.yml +6 -10
- package/agent-presets/dsmm-clarifier/agent.cordis.yml +10 -14
- package/agent-presets/dsmm-code-search/agent.cordis.yml +10 -14
- package/agent-presets/dsmm-coding/agent.cordis.yml +10 -14
- package/agent-presets/dsmm-complex/agent.cordis.yml +10 -14
- package/agent-presets/dsmm-creative/agent.cordis.yml +10 -14
- package/agent-presets/dsmm-cross-cutting/agent.cordis.yml +10 -14
- package/agent-presets/dsmm-deep/agent.cordis.yml +10 -14
- package/agent-presets/dsmm-doc-search/agent.cordis.yml +10 -14
- package/agent-presets/dsmm-documenting/agent.cordis.yml +10 -14
- package/agent-presets/dsmm-frontend/agent.cordis.yml +10 -14
- package/agent-presets/dsmm-hard-reasoning/agent.cordis.yml +10 -14
- package/agent-presets/dsmm-media-reader/agent.cordis.yml +10 -14
- package/agent-presets/dsmm-normal-task/agent.cordis.yml +10 -14
- package/agent-presets/dsmm-oracle/agent.cordis.yml +10 -14
- package/agent-presets/dsmm-oracle-2nd/agent.cordis.yml +10 -14
- package/agent-presets/dsmm-orchestrator/agent.cordis.yml +8 -12
- package/agent-presets/dsmm-plan-critic/agent.cordis.yml +10 -14
- package/agent-presets/dsmm-planner/agent.cordis.yml +10 -14
- package/agent-presets/dsmm-quick/agent.cordis.yml +10 -14
- package/agent-presets/dsmm-research/agent.cordis.yml +10 -14
- package/agent-presets/dsmm-reviewer/agent.cordis.yml +10 -14
- package/docs/agent-presets.md +3 -3
- package/docs/compatibility.md +2 -2
- package/docs/deferred-native-approval-risk.md +11 -1
- package/docs/design.md +1 -1
- package/docs/lsp.md +6 -2
- package/docs/maintenance.md +65 -0
- package/docs/model-routing.md +1 -1
- package/docs/native-permissions.md +23 -1
- package/docs/profiles.md +1 -1
- package/docs/releasing.md +51 -32
- package/docs/roadmap.md +3 -3
- package/docs/runtime-recovery.md +1 -1
- package/docs/safety-guards.md +23 -5
- package/docs/settings-status.md +1 -1
- package/lib/child-capture.js +5 -1
- package/lib/client/deployment-locales.js +1 -0
- package/lib/client/permission-locales.js +8 -8
- package/lib/client.js +18 -17
- package/lib/command-approval.d.ts +50 -0
- package/lib/command-approval.js +148 -0
- package/lib/core-permissions.d.ts +2 -1
- package/lib/core-permissions.js +6 -3
- package/lib/guards.d.ts +2 -1
- package/lib/guards.js +45 -8
- package/lib/index.d.ts +1 -1
- package/lib/index.js +4 -2
- package/lib/lsp.js +1 -1
- package/lib/permission-control.d.ts +5 -2
- package/lib/permission-control.js +46 -24
- package/lib/permission-controller.d.ts +2 -0
- package/lib/permission-controller.js +13 -8
- package/lib/permission-native-command.d.ts +2 -0
- package/lib/permission-native-command.js +9 -4
- package/lib/permission-native-rules.d.ts +2 -2
- package/lib/permission-native-rules.js +18 -13
- package/lib/permission-shell.d.ts +1 -1
- package/lib/permission-shell.js +2 -2
- package/lib/profile-diagnostics.js +1 -1
- package/lib/profiles.js +2 -1
- package/lib/prompt-content.js +2 -2
- package/lib/roles.js +2 -2
- package/lib/settings.d.ts +2 -0
- package/lib/settings.js +10 -0
- package/lib/shell-command.d.ts +16 -0
- package/lib/shell-command.js +443 -119
- package/package.json +38 -38
- package/patches/ocmm-lsp-mcp.example.cordis.patch.yml +1 -1
- package/prompts/deepwork.md +2 -2
- package/prompts/source/shared/dsh-host-contract.md +2 -2
- package/prompts/source/shared/locale.md +2 -2
- package/prompts/source/terminal/builder.md +2 -2
- package/prompts/source/terminal/clarifier.md +6 -6
- package/prompts/source/terminal/code-search.md +6 -6
- package/prompts/source/terminal/coding.md +6 -6
- package/prompts/source/terminal/complex.md +6 -6
- package/prompts/source/terminal/creative.md +6 -6
- package/prompts/source/terminal/cross-cutting.md +6 -6
- package/prompts/source/terminal/deep.md +6 -6
- package/prompts/source/terminal/doc-search.md +6 -6
- package/prompts/source/terminal/documenting.md +6 -6
- package/prompts/source/terminal/frontend.md +6 -6
- package/prompts/source/terminal/hard-reasoning.md +6 -6
- package/prompts/source/terminal/media-reader.md +6 -6
- package/prompts/source/terminal/normal-task.md +6 -6
- package/prompts/source/terminal/oracle-2nd.md +6 -6
- package/prompts/source/terminal/oracle.md +6 -6
- package/prompts/source/terminal/orchestrator.md +4 -4
- package/prompts/source/terminal/plan-critic.md +6 -6
- package/prompts/source/terminal/planner.md +6 -6
- package/prompts/source/terminal/quick.md +6 -6
- package/prompts/source/terminal/research.md +6 -6
- package/prompts/source/terminal/reviewer.md +6 -6
- package/skills/ast-grep/SKILL.md +3 -3
- package/skills/ast-grep/SOURCE +1 -1
- package/skills/ast-grep/install.ps1 +1 -1
- package/skills/ast-grep/install.sh +1 -1
- package/skills/ast-grep/scripts/ast_grep_helper.py +10 -10
- package/skills/ast-grep/tests/smoke.sh +11 -11
- package/skills/ast-grep/tests/test_resolver.py +4 -23
- package/skills/brainstorming/SKILL.md +3 -3
- package/skills/coding-agent-sessions/NOTICE.md +2 -2
- package/skills/coding-agent-sessions/SKILL.md +3 -3
- package/skills/debugging/SKILL.md +3 -3
- package/skills/debugging/references/methodology/03-flaky-triage.md +1 -1
- package/skills/debugging/references/scripts/dap.mjs +3 -3
- package/skills/debugging/references/tools/playwright-cli.md +3 -3
- package/skills/dispatching-parallel-agents/SKILL.md +3 -3
- package/skills/frontend/ATTRIBUTION.md +4 -4
- package/skills/frontend/SKILL.md +3 -3
- package/skills/frontend/references/perfection/README.md +4 -4
- package/skills/frontend/references/perfection/react-perf-tooling.md +4 -4
- package/skills/git-master/SKILL.md +3 -3
- package/skills/git-master/agents/openai.yaml +1 -1
- package/skills/init-deep/SKILL.md +3 -3
- package/skills/receiving-code-review/SKILL.md +3 -3
- package/skills/remove-ai-slops/SKILL.md +3 -3
- package/skills/requesting-code-review/SKILL.md +3 -3
- package/skills/subagent-driven-development/SKILL.md +3 -3
- package/skills/using-git-worktrees/SKILL.md +4 -4
- package/skills/writing-plans/SKILL.md +3 -3
- package/docs/migration-from-ocmm.md +0 -57
- package/docs/skill-sync.md +0 -94
- package/prompts/source/manifest.json +0 -3168
|
@@ -2,18 +2,14 @@
|
|
|
2
2
|
name: '@deepseek-ai/dsh-persona'
|
|
3
3
|
config:
|
|
4
4
|
prefix: |-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
---
|
|
8
|
-
|
|
9
|
-
<ocmm-locale-guidance>
|
|
5
|
+
<dsmm-locale-guidance>
|
|
10
6
|
Language and locale:
|
|
11
7
|
- This shared resource supplies no configured locale; preserve this exact Agent's captured locale and applicable host/user language guidance when supplied.
|
|
12
8
|
- When neither captured locale nor applicable host/user language guidance is supplied, infer the preferred visible-output language from the current request and conversation context. This does not configure reasoning language or the host/project locale.
|
|
13
9
|
- If the user mixes languages, use the language that best matches the current request.
|
|
14
10
|
- Preserve code, identifiers, file paths, commands, protocol names, quotes, and user-requested wording in their original language when accuracy requires it.
|
|
15
11
|
- If the user explicitly asks for a different output language for a specific answer, follow that local request unless it conflicts with higher-priority instructions.
|
|
16
|
-
</
|
|
12
|
+
</dsmm-locale-guidance>
|
|
17
13
|
|
|
18
14
|
---
|
|
19
15
|
|
|
@@ -44,17 +40,17 @@
|
|
|
44
40
|
---
|
|
45
41
|
|
|
46
42
|
<dsmm-host-contract>
|
|
47
|
-
Use the current DSH 0.2.1-rc.2 catalog: read/glob/grep for files, web_search/web_fetch for external facts, write/edit and the actual bash/pwsh for authorized edits and execution, and native skill invocation for triggered skills. Native read takes file_path; inspect actual schemas, not OpenCode field names. Use exposed ask_user_question or ask a material question in conversation. Use exposed todo_write for useful Agent-owned whole-list tracking under its actual concurrency policy. Use LSP/browser/read_image only when present and supported by the actual route; fall back to direct evidence or report the capability unavailable. No Task/todowrite/compress/Context7 MCP API is assumed; host compaction is not
|
|
43
|
+
Use the current DSH 0.2.1-rc.2 catalog: read/glob/grep for files, web_search/web_fetch for external facts, write/edit and the actual bash/pwsh for authorized edits and execution, and native skill invocation for triggered skills. Native read takes file_path; inspect actual schemas, not OpenCode field names. Use exposed ask_user_question or ask a material question in conversation. Use exposed todo_write for useful Agent-owned whole-list tracking under its actual concurrency policy. Use LSP/browser/read_image only when present and supported by the actual route; fall back to direct evidence or report the capability unavailable. No Task/todowrite/compress/Context7 MCP API is assumed; host compaction is not a model-facing compression tool.
|
|
48
44
|
Logical source role names map to IDs dsmm-<name> (explore is only the code-search alias). Inspect this Agent's actual admitted tool inventory: per-role exposes individual role tools plus dsmm_category; parameterized exposes dsmm_role/dsmm_category and their permitted target enums. description/prompt are assignment inputs; optional level, route and run_in_background depend on the actual schema and captured admission. Omitted/normal retains the default route; low/high/max requires that target's configured complete route or effort-only override, with exact native preflight. route additionally needs deployment allowRouteOverride=true; no suffix role/tool or arbitrary effort is inferred. Layout/level never changes target/read-only/depth/ownership authority. A read-only planner returns complete Markdown for authorized coordinator persistence, never through file/shell writes or a child proxy.
|
|
49
45
|
One-shot defaults foreground and is never revived after settlement. When enabled and admitted, native jobs own one-shot background; a managed continuable configuration defaults background and returns a durable child ID, while explicit run_in_background:false starts a non-reusable one-shot. Existing continuable children use actual exposed send_message for running/idle/same-ID cold delivery and actual native user queue/steer; acceptance is not completion. Original child route/locale/authority remains captured and intersects current exact-parent authority, not parent-new-policy inheritance. Legacy conservative evidence permits useful proven capabilities and denies missing-evidence capabilities with reasons. A foreground handoff, only through an actually wired user control, moves the existing run to native-job ownership without another start; no static text declares a new tool or RPC. Managed delivery requires disabling the stock subagents row and binding the unique PUBLIC DSMM SubagentRuntime subclass at explicit startup, then restart. Stock cannot be hot-replaced. Background/capacity/depth/ownership/cancellation remain mandatory. Native continuation is not task_id/resume/retry.
|
|
50
|
-
The native main model picker, explicit user route and catalog are authoritative. Model guidance calibrates behavior only; it does not select
|
|
46
|
+
The native main model picker, explicit user route and catalog are authoritative. Model guidance calibrates behavior only; it does not select a provider/model, grant permissions, declare external independence or change advertised effort. Oracle independence requires a different model was explicitly selected and verified in the actual route. Default inventory has no synthetic tiers or additional Oracle slots.
|
|
51
47
|
Follow the current user's explicit visible-output language request, then this Agent's immutable captured locale when supplied, then applicable host/user language guidance or current request/context. All DSMM roles/categories follow this priority even with common mode off. Preserve identifiers, code, paths, commands, protocol fields and exact quotes; child assignments retain explicit language requests. This contract copies no Root locale/configuration, promises no internal reasoning language and changes neither host UI nor project locale.
|
|
52
48
|
Role persona and access remain when Deepwork is explicitly off; common workflow and DSMM skills do not. Git/install/login/destructive actions need exact authorization regardless of mode. All delegation guidance is intersected with enabled roles, mounted capabilities, inherited permissions and native depth; runtime policy enforces those ceilings, not these static texts.
|
|
53
49
|
</dsmm-host-contract>
|
|
54
50
|
|
|
55
51
|
---
|
|
56
52
|
|
|
57
|
-
<
|
|
53
|
+
<dsmm-shell-command-safety>
|
|
58
54
|
# Shell Command Safety
|
|
59
55
|
|
|
60
56
|
- Keep terminal commands short and inspectable. Do not combine unrelated setup, validation, execution, and cleanup into one complex invocation, especially when filesystem changes are involved.
|
|
@@ -62,9 +58,9 @@
|
|
|
62
58
|
- In PowerShell, do not use `$home` or any case variant as a custom variable: variable names are case-insensitive and `$HOME` is an automatic variable. Use a specific, purpose-named variable instead.
|
|
63
59
|
- Treat recursive or batch deletion as a fail-closed operation. Prefer an exact literal target. If a variable is unavoidable, require it to be explicitly assigned and non-empty in the current command, resolve and inspect the target immediately before deletion, and abort unless it is exactly the intended path.
|
|
64
60
|
- Never recursively or batch-delete a filesystem root, the user home, the workspace, an ancestor of the workspace, or an unexpected parent directory. Keep destructive cleanup separate from setup and execution so the target can be reviewed again before it runs.
|
|
65
|
-
</
|
|
61
|
+
</dsmm-shell-command-safety>
|
|
66
62
|
|
|
67
|
-
<
|
|
63
|
+
<dsmm-subagent-compression-policy>
|
|
68
64
|
## Subagent Compression Policy
|
|
69
65
|
Apply this policy only when the current execution is a subagent session and a `compress` tool is available.
|
|
70
66
|
If `compress` is unavailable, do not propose, simulate, or attempt compression.
|
|
@@ -95,16 +91,16 @@
|
|
|
95
91
|
- Trustworthy estimates indicate approximately 130k or more current context, at least 50k removable closed context, and either a real capacity signal or about ten additional model turns.
|
|
96
92
|
These constraints do not prohibit a bounded follow-up under either common path when its own conditions are met.
|
|
97
93
|
If any estimate is unavailable, do not invent it; only this additional path becomes unavailable, while the common paths (the emergency and completed >100k exploration paths) remain independently available under their own conditions. A single completed tool call is not a phase boundary.
|
|
98
|
-
</
|
|
94
|
+
</dsmm-subagent-compression-policy>
|
|
99
95
|
|
|
100
|
-
<
|
|
96
|
+
<dsmm-delegation-contract>
|
|
101
97
|
## Delegation Contract (Authoritative)
|
|
102
98
|
Use direct tools first. Delegate only when direct tools are insufficient and a separate bounded research result materially improves completion.
|
|
103
99
|
Allowed utility targets: `code-search`, `explore`, `doc-search`, `research`, `media-reader`.
|
|
104
100
|
`quick` is forbidden because this read-only role must not modify work by proxy. Planning, review, coordination, and implementation workflow agents are also forbidden.
|
|
105
101
|
Return the completed plan or findings to the caller. Formal planner dispatch, the `plan-critic` loop, review dispatch, and final acceptance review are orchestrator-owned.
|
|
106
102
|
This contract overrides any skill, model calibration, generated-adapter compatibility text, or other prompt layer that suggests broader delegation.
|
|
107
|
-
</
|
|
103
|
+
</dsmm-delegation-contract>
|
|
108
104
|
|
|
109
105
|
The source delegation allowance is conditional on actual native callability and the caller's inherited authority; formal workflow stages belong to the trusted root/stage owner. No static text grants a tool or overrides an execution restriction.
|
|
110
106
|
- id: agent-instructions
|
package/docs/agent-presets.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Deepwork Agent presets and child control
|
|
2
2
|
|
|
3
|
-
DSMM 0.3.
|
|
3
|
+
DSMM 0.3.11 targets exactly DSH `0.2.1-rc.2`. Native package composition and callable admission are separate requirements.
|
|
4
4
|
|
|
5
5
|
## Roles and composition
|
|
6
6
|
|
|
@@ -8,11 +8,11 @@ The canonical inventory is 11 base roles and 11 categories. Base roles are orche
|
|
|
8
8
|
|
|
9
9
|
Only the Orchestrator (`dsmm-orchestrator`) is a selectable standing root, and it is the only composition DSMM registers with the native preset registry. Every other role is an internal delegation target: no role preset is registered for it, and a delegated child shares its parent's standing composition while the admitted invocation carries its role, identity and restrictions. `roles.*` controls delegation availability; disabling a role removes its callable tool and admission entirely. Native preset selection displays `DW …` labels under unchanged IDs. A role name is a responsibility, not a model choice or authority claim.
|
|
10
10
|
|
|
11
|
-
Native `agentPresets.register({id, plugins})` publishes only the selectable dispatcher composition; DSH doesn't discover presets by scanning exported directories. The native export roster lists only the dispatcher, and creation/execution checks reject every non-dispatcher DSMM root. Generated `agent-presets/` mirrors are inspection/export resources. `presets.materialize` defaults off, publishes only the dispatcher preset directory and never selects the Host default preset. Personas, read-only restrictions and host approvals remain when explicit Deepwork off hides common workflow and DSMM skills.
|
|
11
|
+
Native `agentPresets.register({id, plugins})` publishes only the selectable dispatcher composition; DSH doesn't discover presets by scanning exported directories. The native export roster lists only the dispatcher, and creation/execution checks reject every non-dispatcher DSMM root. Generated `agent-presets/` mirrors are inspection/export resources. `presets.materialize` defaults off, publishes only the dispatcher preset directory and never selects the Host default preset. Personas, read-only restrictions and host approvals remain when explicit Deepwork off hides common workflow and DSMM skills. Maintained source content, generation and resource provenance are described in [maintenance](maintenance.md).
|
|
12
12
|
|
|
13
13
|
Optional preset materialization writes only the DSMM-owned dispatcher preset directory under its configured root. Ownership requires the exact role-bound marker and expected regular files; foreign directories, extra entries, links and containment escapes refuse update/removal. New directories publish by same-parent rename. A legacy marker is accepted only with the complete expected regular-file shape, never as permission to claim unrelated content. Reconciling removes verified owned directories of every non-dispatcher role, including ones published by earlier versions. Materialized files remain export resources, not an alternative native registration mechanism.
|
|
14
14
|
|
|
15
|
-
Managed Agent scopes supply
|
|
15
|
+
Managed Agent scopes supply the single role opening (`You are <display name>.`) through `harness:identity`, without a parenthesized role ID. Persona prefixes carry role guidance, not another identity opening; admitted children shadow both inherited sections. Internal role IDs remain the admission, routing and preset keys. The ordinary native identity remains unchanged outside those scopes; the override doesn't grant a role, tool or permission based on its displayed name.
|
|
16
16
|
|
|
17
17
|
Root admission is not configurable per role: the dispatcher is the only standing root. A blank preset switch to any other DSMM role is refused because no such preset is registered, and the admitted composition stays in place. Forced creation and empty-root preset changes still require valid root admission before execution. Opting into Deepwork requires the enabled module, role and usable composition; it never grants writes. Harness's native `/plan` remains collaboration state, not a permission upgrade.
|
|
18
18
|
|
package/docs/compatibility.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# DSMM compatibility and upgrade boundaries
|
|
2
2
|
|
|
3
|
-
**DSMM 0.3.
|
|
3
|
+
**DSMM 0.3.11 targets exactly DSH `0.2.1-rc.2`** and Node.js 22 or later. Older SDKs and automatically drifting versions aren't supported targets.
|
|
4
4
|
|
|
5
5
|
## Supported integration
|
|
6
6
|
|
|
@@ -38,7 +38,7 @@ Standard supported model calls use native prepared calls. Raw/custom and Pi-AI s
|
|
|
38
38
|
|
|
39
39
|
## Retired compatibility surfaces
|
|
40
40
|
|
|
41
|
-
No old SDK branch, legacy-read host, cold-profile migration, session repair or custom-owner selector is a 0.3.
|
|
41
|
+
No old SDK branch, legacy-read host, cold-profile migration, session repair or custom-owner selector is a 0.3.11 activation path. Old libraries, captures and unmarked history aren't copied, rewritten, repaired or adopted by same-name fallback. Retired brand calibration/default-effort and MaxReasoningPresets fields reject with `deprecated-field`; edit configuration deliberately using generic routes and parameters.
|
|
42
42
|
|
|
43
43
|
Published **0.3.0 retains its rc.1 identity**, immutable tag, package, assets and version-bound receipt grammar. Historical release controls interpret those records under their original identity, not as a runtime compatibility branch.
|
|
44
44
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# 原生审批与运行中配置边界
|
|
2
2
|
|
|
3
|
-
DSMM 0.3.
|
|
3
|
+
DSMM 0.3.11 精确面向 DSH `0.2.1-rc.2`。原生批准仅对同次调用及其批准范围有效,不扩展到其他输入或后续调用。配置来源变化不把 DSMM epoch 变成第二次审批,也不取消已经等待的原生审批。
|
|
4
4
|
|
|
5
5
|
## 当前限制
|
|
6
6
|
|
|
@@ -12,4 +12,14 @@ Use profile model 与普通模式操作具有独立 capability,不因 Apply
|
|
|
12
12
|
|
|
13
13
|
取消、精确 Agent/owner/realm、工具及 provider 身份和输入隔离仍然有效。原生 once 批准不是可复用授权,批准也不保证工具或操作系统执行成功。
|
|
14
14
|
|
|
15
|
+
## 自动 Git 范围与规则记忆
|
|
16
|
+
|
|
17
|
+
`guards.gitWriteScope` 默认为 `all-writes`,可选 `high-risk`,与 `gitWriteGuard: ask | deny | off` 正交。`high-risk` 仅缩小自动 Git 保护的动作集合,不过滤显式 shell ask/deny,也不关闭对象型 nativeCommands ask;readonly、原生策略和既有 Full access/simple 路径的优先级不变。配置沿用全局、当前 DSH 配置和具名 profile 的继承规则,不增加 live Apply。
|
|
18
|
+
|
|
19
|
+
DSMM 的命令规则批准仅在精确的存活 Agent 对象内记忆;需完整原生审批服务最终返回 `allowed-once` 且调用绑定有效。同一规则允许的参数变化可以复用 DSMM 规则批准,不能扩展显式精确匹配或跨动作、工具注册、目录及规则语义借用。配置来源/规则变更使未来记忆失效,Agent 销毁、session 对象替换或控制器退休结束记忆。子 Agent 可捕获设置,但不继承父批准;记忆不持久化,也不跨恢复或重启。
|
|
20
|
+
|
|
21
|
+
规则记忆只消除 DSMM 自己已满足的 ask,不复用原生 once/sandbox target、不提高 standing 权限,也不替新的提权请求自动作答。原生提权、第三方或独立下游审批仍可能每次询问;deny、cancel、`approval.policy=never` 仍生效。来源变化不取消已经等待的原生请求;旧请求最终批准仍只按其单次契约执行,不向新来源写入记忆。
|
|
22
|
+
|
|
23
|
+
减少重复人工介入改变了风险,不能宣称总体风险不变。通用 Git 路径在既有 guard 边界重核调用,仍信任宿主后续可变的同进程 middleware;managed Shell 保持受控最终入口检查,但二者都不承诺隔离主动绕过管线的同进程插件或提供 OS 隔离,也不承诺所有工具没有弹窗。
|
|
24
|
+
|
|
15
25
|
遇到拒绝时先检查实际结果,不无条件重跑整个父任务。未来的 live Apply 必须能绑定精确调用、配置与未决审批,保持上述权限和生命周期边界;当前版本不提供该操作。
|
package/docs/design.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# DSMM native architecture
|
|
2
2
|
|
|
3
|
-
DSMM 0.3.
|
|
3
|
+
DSMM 0.3.11 targets exactly DSH `0.2.1-rc.2`. It supplies Core configuration and native permission integration plus optional Deepwork roles, routing and skills.
|
|
4
4
|
|
|
5
5
|
## Composition and authority
|
|
6
6
|
|
package/docs/lsp.md
CHANGED
|
@@ -4,9 +4,11 @@ This version doesn't enable DSMM-managed external LSP. The integration implement
|
|
|
4
4
|
|
|
5
5
|
The default `cordis.patch.yml` doesn't add an MCP client row. This restriction applies only to DSMM's automatic integration: it doesn't disable DSH's own LSP services or an MCP server independently configured by the operator. DSMM doesn't download servers or native binaries.
|
|
6
6
|
|
|
7
|
+
The manual integration uses the `ocmm-lsp` executable published by the `ocmm` npm package. DSMM does not contain the LSP source, Rust/native build, platform-package matrix, or LSP release workflow, and does not declare `ocmm` as a package dependency. The operator must separately provide the published `ocmm` package and its matching optional `ocmm-lsp-*` platform package in the Host execution environment; installs that omit optional dependencies cannot provide the native binary. No source checkout or parent-repository `dist/` path is a supported fallback.
|
|
8
|
+
|
|
7
9
|
## Retained manual example
|
|
8
10
|
|
|
9
|
-
The
|
|
11
|
+
The retained [manual patch](../patches/ocmm-lsp-mcp.example.cordis.patch.yml) remains available as a native-host configuration reference, not a supported DSMM activation entry for this version. Independently managed MCP composition remains the operator's responsibility, including npm package availability, executable resolution, namespace uniqueness and native lifecycle ownership.
|
|
10
12
|
|
|
11
13
|
The retained example describes:
|
|
12
14
|
|
|
@@ -17,6 +19,8 @@ The retained example describes:
|
|
|
17
19
|
- `failOnStartupError: true`
|
|
18
20
|
- `toolCallTimeoutMs: 60000`
|
|
19
21
|
|
|
22
|
+
`ocmm-lsp` above is the npm package's declared executable. An explicit absolute command override may be used by the Host, but DSMM does not discover a sibling checkout, compile the binary, or publish an alternative LSP artifact.
|
|
23
|
+
|
|
20
24
|
## Retained tool interface
|
|
21
25
|
|
|
22
26
|
An independently mounted native MCP client using `serverName: dsmm_lsp` uses the following tool names. This inventory describes the retained interface, not tools automatically available from DSMM in this version:
|
|
@@ -35,6 +39,6 @@ An independently mounted native MCP client using `serverName: dsmm_lsp` uses the
|
|
|
35
39
|
|
|
36
40
|
DSMM's read-only role restrictions don't grant rename or format permission. The retained `lspRuntime` status interface reports bounded state, diagnostic codes and tool names, not executable paths, arguments or environment values. Tool discovery alone doesn't prove language-server availability or a successful symbol query.
|
|
37
41
|
|
|
38
|
-
DSMM 0.3.
|
|
42
|
+
DSMM 0.3.11 targets exactly DSH `0.2.1-rc.2`. Automatic external LSP mounting isn't delivered; the retained interface inventory isn't an activation path.
|
|
39
43
|
|
|
40
44
|
DSH's native definition/references/implementation/hover surface isn't a promise of diagnostics, rename or format. The retained external interface above doesn't expand that native scope. Independently managed MCP users must verify actual executable and language-server availability; DSMM doesn't certify or repair that environment.
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
# DSMM maintenance
|
|
2
|
+
|
|
3
|
+
DSMM is maintained as a standalone project. `src/`, `prompts/`, and `skills/` are
|
|
4
|
+
the authoritative source trees. Builds, tests, generators and package checks must
|
|
5
|
+
not read a parent or sibling repository.
|
|
6
|
+
|
|
7
|
+
## Toolchain
|
|
8
|
+
|
|
9
|
+
Use Node.js 24 for CI/release and pnpm 11.9.0. The package still supports Node.js
|
|
10
|
+
22 or later at runtime and targets exactly DSH `0.2.1-rc.2`. Do not change the npm
|
|
11
|
+
name `@dsmm/dsmm`, package version, or DSH dependency line as part of routine
|
|
12
|
+
maintenance unless the release or compatibility scope explicitly requires it.
|
|
13
|
+
|
|
14
|
+
Common checks:
|
|
15
|
+
|
|
16
|
+
```powershell
|
|
17
|
+
pnpm run typecheck
|
|
18
|
+
pnpm run build
|
|
19
|
+
pnpm run test:run
|
|
20
|
+
pnpm run check:frontend
|
|
21
|
+
pnpm run check:roles
|
|
22
|
+
pnpm pack --pack-destination <approved-output-directory>
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
`pnpm test` remains the convenient build-plus-test command. Dependency installation
|
|
26
|
+
and lockfile maintenance are separate authorized operations.
|
|
27
|
+
|
|
28
|
+
## Generated role assets
|
|
29
|
+
|
|
30
|
+
`src/roles.ts`, `src/prompts.ts`, and `prompts/source/` supply the maintained role
|
|
31
|
+
and workflow content. After changing inputs that affect rendered presets or the
|
|
32
|
+
base Deepwork prompt, run `pnpm run generate:roles`. CI uses
|
|
33
|
+
`pnpm run check:roles` and fails if `agent-presets/` or `prompts/deepwork.md` is
|
|
34
|
+
stale. Generated assets are package resources, not an alternate source of truth.
|
|
35
|
+
|
|
36
|
+
## Frontend resources and provenance
|
|
37
|
+
|
|
38
|
+
The full `skills/frontend/` tree is maintained in this repository and shipped in
|
|
39
|
+
the npm package. `scripts/frontend-recipe.mjs`, fixed upstream commits,
|
|
40
|
+
`skills/frontend/.frontend-materialized.json`, and
|
|
41
|
+
`skills/frontend/ATTRIBUTION.md` define its provenance and integrity boundary.
|
|
42
|
+
Third-party licenses and notices remain with their resources.
|
|
43
|
+
|
|
44
|
+
Ordinary build and `check:frontend` are offline. They require the complete local
|
|
45
|
+
resource set and never download or replace files. `pnpm run sync:frontend` is the
|
|
46
|
+
only network materialization command; use it only with explicit authorization. It
|
|
47
|
+
fetches missing files from the fixed commits, verifies Git blob identities and
|
|
48
|
+
license blobs, and refuses unsafe destinations. Review and commit the resulting
|
|
49
|
+
resource and inventory changes together.
|
|
50
|
+
|
|
51
|
+
## LSP dependency boundary
|
|
52
|
+
|
|
53
|
+
DSMM retains only configuration and smoke-test integration for `ocmm-lsp mcp`.
|
|
54
|
+
The executable, native binaries, platform packages and their release lifecycle are
|
|
55
|
+
provided by the published `ocmm` npm package. Do not copy LSP source, native build
|
|
56
|
+
logic or platform publication into this repository. Dependency and lockfile
|
|
57
|
+
maintenance must ensure the published package and matching optional platform
|
|
58
|
+
package are available without relying on a sibling checkout.
|
|
59
|
+
|
|
60
|
+
## Release
|
|
61
|
+
|
|
62
|
+
Pull requests and branch pushes run `.github/workflows/ci.yml` and never publish.
|
|
63
|
+
Only an exact `v<package-version>` tag can enter `.github/workflows/release.yml`.
|
|
64
|
+
See [releasing](releasing.md) for immutable publication rules and npm Trusted
|
|
65
|
+
Publishing prerequisites.
|
package/docs/model-routing.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Providers, accounts and credentials remain native DSH configuration, never named-profile contents.
|
|
4
4
|
|
|
5
|
-
DSMM 0.3.
|
|
5
|
+
DSMM 0.3.11 targets exactly DSH `0.2.1-rc.2`. Standard calls use native prepared calls. The public Pi-AI completions seam supports self-contained literal and explicit model-mapping raw configurations; unsupported catalog-backed raw combinations are rejected without affecting standard calls.
|
|
6
6
|
|
|
7
7
|
## Native roots and child defaults
|
|
8
8
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Native permissions
|
|
2
2
|
|
|
3
|
-
DSMM 0.3.
|
|
3
|
+
DSMM 0.3.11 targets exactly DSH `0.2.1-rc.2`. DSH owns approval; DSMM composes policy into the native tool pipeline without a second approval queue or UI. DSMM command-rule approval memory is limited to the exact live Agent and is distinct from native once grants.
|
|
4
4
|
|
|
5
5
|
## Full access and approval
|
|
6
6
|
|
|
@@ -12,6 +12,8 @@ Actual DSH manual approval is final for the same call and approved scope. Older
|
|
|
12
12
|
|
|
13
13
|
A native once grant applies only to its actual call and scope. It doesn't change standing session permissions, authorize later calls or turn a narrower approval into full access. Model-supplied arguments aren't approval; a matching simple allowlist entry selects an automatic answer for the current native request, not a reusable grant. Native policy `never` refuses before the rc2 answerer and cannot be overridden by it. Caller/native cancellation remains effective, and the original tool or OS can still fail. Permission to execute isn't a command-success guarantee.
|
|
14
14
|
|
|
15
|
+
DSMM remembers only its approved Git action rules, exact explicit shell ask rules and object-form native command ask rules after the native service returns final `allowed-once` with the invocation/lifecycle bindings intact. Matching later calls from that exact live Agent may omit the satisfied DSMM ask contribution, but never reuse the native once target or automatically answer a new native escalation. All applicable DSMM asks must be satisfied; explicit deny, independent native/third-party ask or deny, cancellation and `approval.policy=never` still apply. Rule/source changes invalidate future memory without canceling an already pending native request. No memory passes to children, restored/recreated Agents or another registration; nothing is persisted as recoverable approval.
|
|
16
|
+
|
|
15
17
|
## Settings and synchronization
|
|
16
18
|
|
|
17
19
|
`permissionControl.enabled` defaults true independently of Deepwork and is captured at cold startup. Saving a different value reports restart-required; it neither hot-mounts an executor nor changes the admitted toggle, even for new roots. Turning it off doesn't disable native permissions or other independent tool restrictions.
|
|
@@ -24,10 +26,22 @@ Storage CAS and runtime adoption are separate from native call approval. Saves r
|
|
|
24
26
|
|
|
25
27
|
Configuration writes require the real native operator, exact entry/form or Root authority and a live connection/owner through every await and immediately before commit. Serialized provenance, a client loopback claim or an old registration isn't authority. Only relevant effective permission changes coordinate revocation; unrelated model/locale/display edits aren't a second approval gate. A committed write stays committed when notification or observation fails, with refresh-required/unsynchronized status. An unconfirmed native result requires reread, not blind retry.
|
|
26
28
|
|
|
29
|
+
## Trusted read-only calls
|
|
30
|
+
|
|
31
|
+
Trusted native `read`, `glob` and `grep` calls do not request outside-read approval, inside or outside the workspace. This includes saved `outsideReads: ask` and `outside-read` entries with `action: ask`. DSMM continues reading these settings without rewriting user configuration. Missing FS/path or co-location facts do not turn `allow`, `ask` or `inherit` into a read approval.
|
|
32
|
+
|
|
33
|
+
Existing deny policy and path-rule matching remain effective. Outside standing Full access, a relevant deny fails closed when the required containment or path facts cannot be proved; an unknown backend is not proof that a target is inside the workspace. Standing Full access retains its definite-blacklist behavior described above.
|
|
34
|
+
|
|
35
|
+
The same outside-read behavior applies to the existing shell read branch only when the native adapter supplies a current, trusted `readCapability` for the actual executable and environment. A tool name, command name or workspace cwd is not read-only proof. Independent shell command rules, unknown-command behavior and web/Git policy are unchanged.
|
|
36
|
+
|
|
37
|
+
This removes only DSMM outside-read asks. Independent downstream asks, denials and cancellation still apply, including third-party tools with familiar names. Native read-only restrictions, role/tool/RPC ceilings and exact registration, body, arguments, Agent and invocation-token bindings remain in force. A native once approval still belongs only to its original call.
|
|
38
|
+
|
|
27
39
|
## Configuration drawer and command rules
|
|
28
40
|
|
|
29
41
|
Use **Plugins → DSMM bundle config → Permissions**. The selected Global/native-profile scope edits its sparse deployment policy; a separate Root-rules transaction writes Global only under the existing live operator, exact open Root, registration and synchronized-policy authority. A child, stale connection, read-only Host or shadowing native policy doesn't acquire a fallback Global write. Named Profiles can't grant these permissions. No duplicate Settings permission page or Conversation permission tab is registered.
|
|
30
42
|
|
|
43
|
+
The existing safety fields include `guards.gitWriteScope: all-writes | high-risk` (default `all-writes`) alongside `gitWriteGuard: ask | deny | off`. Scope selects only the automatic Git action set; it does not filter explicit shell ask/deny or disable object-form command asks. Unset restores the lower layer/default, and read-only forms cannot save. Named profiles may carry this guard setting without granting native permission-control authority. Child captures include settings, never parent approval memory. See [safety guards](safety-guards.md) for coverage and limits.
|
|
44
|
+
|
|
31
45
|
A trusted, writable native Root can manage Global rules without DSMM role admission, including when it predates Core mounting and currently uses the user-selectable `dsmm-orchestrator` composition. Qualification uses the current native composition, never a historical preset label; auxiliary, read-only and unknown `dsmm-` compositions remain ineligible without admission. Rule management does not grant DSMM role execution rights. Captured DSMM objects still require current admission and role checks, and retired captures cannot fall back to ordinary native authority.
|
|
32
46
|
|
|
33
47
|
`permissionControl.nativeCommands` defaults off. Entries in `permissionControl.nativeCommands.entries` accept simple command/subcommand pattern strings (e.g. `git`, `git status`, `go test`) or legacy object entries (`NativeCommandEntry`). Legacy entries are preserved losslessly without silent conversion or authorization widening.
|
|
@@ -53,3 +67,11 @@ Same-call approval, cancellation, ownership and input isolation remain effective
|
|
|
53
67
|
See [running-overlay and approval boundaries](deferred-native-approval-risk.md).
|
|
54
68
|
|
|
55
69
|
Outside-read and web policies apply to their native tool surfaces. They don't provide complete filesystem/network isolation for arbitrary shell commands or replace operating-system checks on the final inode and socket target.
|
|
70
|
+
|
|
71
|
+
### Workspace and system-temp modifications
|
|
72
|
+
|
|
73
|
+
DSMM does not add a path-range approval layer to native write/edit or ordinary shell modifications, including targets in workspace and system-temp subdirectories. Explicit command/Git rules, role/tool restrictions and native or third-party approval decisions remain effective. A temp path does not automatically approve an independent request.
|
|
74
|
+
|
|
75
|
+
Native write/edit retain their FS intents, observation/version checks, atomic modification and backend-provided sandbox escalation. Shell execution retains the native executor, standing sandbox and explicit call-scoped escalation. DSMM does not infer every command's effects from its cwd, raise the sandbox mode because a temp path appears in its arguments, or automatically replay a denied command.
|
|
76
|
+
|
|
77
|
+
Actual write access remains backend-dependent: the stock Windows shell sandbox uses a private temp directory, not the entire shared system temp, and stock LocalFS does not itself enforce sandbox write scopes. DSMM neither changes system-temp ACLs nor supplies a replacement sandbox or FS isolation layer. Absence of an extra DSMM approval does not prove that a backend permits a write or requires approval for every outside write.
|
package/docs/profiles.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Deepwork runtime profiles
|
|
2
2
|
|
|
3
|
-
DSMM 0.3.
|
|
3
|
+
DSMM 0.3.11 targets exactly DSH `0.2.1-rc.2`. See [compatibility](compatibility.md) for installation boundaries.
|
|
4
4
|
|
|
5
5
|
A named Deepwork profile is a runtime-policy document, not a native deployment profile or Agent preset. Open **Settings → Deepwork Profiles** to browse and edit it. Native **Plugins → DSMM** edits deployment layers instead, as described in [settings and status](settings-status.md).
|
|
6
6
|
|
package/docs/releasing.md
CHANGED
|
@@ -1,34 +1,53 @@
|
|
|
1
1
|
# DSMM release
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
##
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
npm
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
##
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
3
|
+
The standalone repository publishes from `.github/workflows/release.yml` when a
|
|
4
|
+
`vX.Y.Z` tag is pushed. The tag must equal `v` plus the exact `package.json`
|
|
5
|
+
version. The workflow never rewrites package metadata from a tag.
|
|
6
|
+
|
|
7
|
+
## External setup
|
|
8
|
+
|
|
9
|
+
Before publication, npm Trusted Publishing must be configured for `@dsmm/dsmm`
|
|
10
|
+
with these exact values:
|
|
11
|
+
|
|
12
|
+
- provider: GitHub Actions
|
|
13
|
+
- repository: `hugefiver/dsmm`
|
|
14
|
+
- workflow filename: `release.yml`
|
|
15
|
+
- permission: publish
|
|
16
|
+
|
|
17
|
+
The npm package and maintainer ownership must already exist. The workflow uses
|
|
18
|
+
GitHub's OIDC token and does not use a long-lived npm token. Repository Actions
|
|
19
|
+
must also permit the workflow's job-scoped `contents: write` permission so it can
|
|
20
|
+
create a GitHub Release.
|
|
21
|
+
|
|
22
|
+
## Verification and publication
|
|
23
|
+
|
|
24
|
+
The read-only verification job uses Node.js 24 and pnpm 11.9.0, installs the
|
|
25
|
+
standalone lockfile with `--frozen-lockfile`, then runs the build, source
|
|
26
|
+
typecheck, tests, offline frontend resource check, generated-role consistency
|
|
27
|
+
check, and package creation. It uploads an exact three-file artifact containing
|
|
28
|
+
the packed tarball, `SHA256SUMS.txt`, and an identity record bound to the tag,
|
|
29
|
+
commit, run and attempt.
|
|
30
|
+
|
|
31
|
+
The dependent publication job has `contents: write` and `id-token: write`. It
|
|
32
|
+
doesn't check out the repository, install project dependencies, or execute project
|
|
33
|
+
code. It downloads the artifact, rechecks its exact file set, checksum, workflow
|
|
34
|
+
identity and packed npm name/version, and then rechecks both publication surfaces.
|
|
35
|
+
Only the tarball and `SHA256SUMS.txt` become GitHub Release assets.
|
|
36
|
+
|
|
37
|
+
Before building and again immediately before publication, the workflow refuses a
|
|
38
|
+
tag/version mismatch, an npm version that already exists, or an existing GitHub
|
|
39
|
+
Release for the tag. npm publication uses `--provenance`, public access, the public
|
|
40
|
+
registry, disabled lifecycle scripts and no fetch retries. GitHub Release creation
|
|
41
|
+
uses the same tarball and `SHA256SUMS.txt`; no overwrite option is used.
|
|
42
|
+
Concurrency is serialized without cancelling an in-progress release.
|
|
43
|
+
|
|
44
|
+
## Failure handling
|
|
45
|
+
|
|
46
|
+
npm and GitHub Release are distinct immutable publication surfaces. A failure
|
|
47
|
+
after either surface is published is a partial release, not authorization to move
|
|
48
|
+
or recreate the tag, republish the npm version, or replace an asset. Report the
|
|
49
|
+
exact workflow result and use a separately authorized new version/tag.
|
|
50
|
+
|
|
51
|
+
Publication does not install DSMM. Installation requires matching DSH
|
|
52
|
+
`0.2.1-rc.2` and separate authorization, and must preserve accounts, credentials,
|
|
53
|
+
history and unrelated configuration.
|
package/docs/roadmap.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
## Version policy
|
|
4
4
|
|
|
5
|
-
**DSMM 0.3.
|
|
5
|
+
**DSMM 0.3.11 targets exactly DSH `0.2.1-rc.2`.** Each DSMM version targets the published DSH RC or stable release selected for that version. Older SDKs and old configuration schemas aren't runtime compatibility targets. Loading sessions created by DSMM `0.2.x` is a required compatibility target, separate from retaining old runtime implementations or execution behavior. A newer upstream release requires deliberate reassessment, not an automatic dependency or runtime switch.
|
|
6
6
|
|
|
7
7
|
Published `0.3.0` retains its original rc.1 package, tag, assets and version-bound release identity.
|
|
8
8
|
|
|
@@ -40,7 +40,7 @@ Sessions created by DSMM `0.2.x` must remain loadable under the supported curren
|
|
|
40
40
|
- Retired presets, plugins, metadata or admission formats require interpretation, migration or an explicit degraded mode rather than whole-session rejection solely because the old implementation is unavailable. This does not require restoring the old SDK or execution owner.
|
|
41
41
|
- Continued execution may use current roles, routing, configuration and permission semantics. Explain material differences and request fresh authorization where necessary; never treat historical metadata or approvals as current authority. When continuation is unavailable, retain the loaded history and expose the specific limitation separately.
|
|
42
42
|
- Preserve original records. Any necessary migration must protect user data with a recoverable original and concurrent-write safeguards; never discard history merely to make loading succeed. Corrupt or genuinely unreadable data must produce a specific diagnostic rather than silently removing the session.
|
|
43
|
-
- Acceptance covers opening representative `0.2.x` root and child histories, retaining titles/list entries and readable content, and separating continuation restrictions from loading. These are pending compatibility requirements, not claims that `0.3.
|
|
43
|
+
- Acceptance covers opening representative `0.2.x` root and child histories, retaining titles/list entries and readable content, and separating continuation restrictions from loading. These are pending compatibility requirements, not claims that `0.3.11` already fulfills them.
|
|
44
44
|
|
|
45
45
|
## Working-tree implementation: profile selection before the first message
|
|
46
46
|
|
|
@@ -95,4 +95,4 @@ Existing [Fake-IP fetch](web-fetch-fakeip.md) protections remain in force.
|
|
|
95
95
|
|
|
96
96
|
## Publication and Desktop installation
|
|
97
97
|
|
|
98
|
-
0.3.
|
|
98
|
+
0.3.11 publication uses the version-bound [release controls](releasing.md). Desktop plugin installation follows publication, uses the Desktop-owned carrier and requires exact DSH `0.2.1-rc.2`. Installation doesn't authorize upgrading the Host, changing credentials or real sessions, altering unrelated configuration, or restarting active work. An incompatible Host or required data migration blocks installation rather than expanding its scope.
|
package/docs/runtime-recovery.md
CHANGED
package/docs/safety-guards.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# DSMM Safety Guards
|
|
2
2
|
|
|
3
|
-
DSMM 0.3.
|
|
3
|
+
DSMM 0.3.11 targets exactly DSH `0.2.1-rc.2`. Its guards use `tools/pre-execute` for allow, deny and ask decisions, and `tools/post-execute` for accepted-result truncation. They don't use OpenCode hook names or mutate tool arguments. Deployment overrides belong in the `id: dsmm` Loader entry's `config` object, not a settings.yaml namespace.
|
|
4
4
|
|
|
5
5
|
## Scope
|
|
6
6
|
|
|
@@ -17,6 +17,7 @@ The default scope is `deepwork-or-dsmm-agent`: helpers apply when the agent is i
|
|
|
17
17
|
scope: deepwork-or-dsmm-agent
|
|
18
18
|
shellCommandSafety: true
|
|
19
19
|
gitWriteGuard: ask
|
|
20
|
+
gitWriteScope: all-writes
|
|
20
21
|
toolOutputTruncation:
|
|
21
22
|
enabled: true
|
|
22
23
|
maxInlineBytes: 12000
|
|
@@ -35,8 +36,8 @@ All DSMM guard messages begin with `[dsmm safety]`.
|
|
|
35
36
|
- `[dsmm safety] PowerShell command uses POSIX null redirection (...)` rejects `/dev/null` in `pwsh`.
|
|
36
37
|
- `[dsmm safety] PowerShell command uses POSIX \`source\` (...)` rejects `source` in `pwsh`.
|
|
37
38
|
- `[dsmm safety] bash command appears to use PowerShell syntax (...)` rejects `$env:` in `bash`.
|
|
38
|
-
-
|
|
39
|
-
-
|
|
39
|
+
- Git approval requests identify the applicable automatic Git actions. With `gitWriteGuard: ask`, uncovered DSMM rules require host approval; unavailable approval fails closed. Valid live-Agent rule approvals may satisfy later matching DSMM asks.
|
|
40
|
+
- Git denial messages reject actions within `gitWriteScope` when `gitWriteGuard: deny`; approval memory cannot override deny.
|
|
40
41
|
- `[dsmm safety] truncated ... output` marks accepted plain-text tool results that were replaced with a head/tail preview.
|
|
41
42
|
- `[dsmm safety] plan file contains a malformed checklist entry: ...` rejects malformed checkbox lines in writes to `docs/superpowers/plans/*.md` and `.omo/plans/*.md`.
|
|
42
43
|
- `[dsmm safety] question option label exceeds ... characters: ...` rejects `ask_user_question` option labels longer than `maxLabelChars`.
|
|
@@ -47,9 +48,26 @@ All DSMM guard messages begin with `[dsmm safety]`.
|
|
|
47
48
|
|
|
48
49
|
Shell checks inspect the command argument for `bash`, `sh`, `zsh`, `pwsh`, and `powershell`. Command parsing separates `;`, newlines, pipes, and `&&`/`||` continuations; it also honors the dialect's normal line continuation escape. Git write detection recognizes an executable named `git` or `git.exe`, including a path-qualified executable, Git global options such as `git -C repo commit`, and the `env` wrapper with its supported options and POSIX-style assignments. Other aliases, shell functions, and wrappers are deliberately unclassified rather than guessed.
|
|
49
50
|
|
|
50
|
-
|
|
51
|
+
`guards.gitWriteScope` is independent of `guards.gitWriteGuard`:
|
|
51
52
|
|
|
52
|
-
|
|
53
|
+
| Scope | Automatic Git coverage |
|
|
54
|
+
| --- | --- |
|
|
55
|
+
| `all-writes` (default) | All recognized writes, including ordinary add, commit, push, fetch, pull, merge and branch/tag creation. Recognized query forms, such as `branch --show-current`, `remote -v`, `stash list`, `tag --list` and `worktree list`, do not count as writes. |
|
|
56
|
+
| `high-risk` | The closed set of force/delete/mirror pushes, hard reset, non-dry-run clean, destructive/forced branch and tag changes, commit amend, rebase rewriting, stash drop/clear, worktree remove/prune, checkout/switch discard and forced replacement, worktree restore, and recognized reference/history modification actions. Ordinary writes are outside this automatic scope. |
|
|
57
|
+
|
|
58
|
+
For either scope, `ask` requires approval of the covered rules, `deny` rejects covered actions, and `off` contributes no automatic Git decision. `high-risk` only narrows automatic Git protection: explicit shell ask/deny and object-form native command asks still apply. Guard activation, shell dialect safety, readonly ceilings and existing standing Full access/simple-command priority are unchanged. This is not a general dangerous-command detector. Unrecognized aliases/wrappers receive no automatic Git decision; uncertain syntax cannot create a reusable broad approval. All command segments are considered, so an ordinary write before a high-risk action cannot hide the latter.
|
|
59
|
+
|
|
60
|
+
The existing schema-driven **Plugins → DSMM bundle config → Permissions** fields expose both options in Global and current DSH profile scopes. Unset uses defaults in Global and restores inheritance in the profile; a named profile can also override `guards.gitWriteScope`. Sparse saves do not pin omitted values. Read-only configuration stays non-writable. Saved settings follow existing new-session admission; they do not apply a live overlay.
|
|
61
|
+
|
|
62
|
+
## Command-rule approval memory
|
|
63
|
+
|
|
64
|
+
DSMM remembers approved automatic Git actions, exact explicit shell ask rules and matched object-form native command ask rules only for the **exact live Agent object**. A Git action approval can cover parameter changes within the same action and proven tool/dialect/cwd/static Git context; approving branch creation does not approve branch deletion or a later force push. Explicit shell rules retain their exact command/cwd matching. Each applicable DSMM ask must be satisfied independently. Uncertain context may still require approval on every call.
|
|
65
|
+
|
|
66
|
+
Only the complete native approval-service result can establish memory. Denial, cancellation, unavailable approval and audit failure do not. Rule/source changes invalidate future memory; Agent disposal, session replacement or controller retirement ends it. Settings may be captured by children, but approvals are not inherited by children or siblings, persisted, restored or shared by session ID. Reducing repeated manual intervention is a behavior and risk change, not unchanged overall risk.
|
|
67
|
+
|
|
68
|
+
Memory satisfies only DSMM's rule contribution. It neither reuses a native once/sandbox target nor changes standing sandbox permissions. Native escalation, independent downstream or third-party asks/denials, cancellation and native `approval.policy=never` remain authoritative; later calls may still show approval prompts. An already pending native request retains its single-call contract when a rule source changes, without granting memory for the new source. Structured-value replacements, errors, and blocked post-tool results are not truncated into apparently successful text.
|
|
69
|
+
|
|
70
|
+
Generic Git checks bind approval to the actual invocation and registration and recheck at the existing guard boundary. They retain the Host's mutable in-process middleware trust boundary; they do not guarantee isolation from plugins replacing execution after that guard. Managed Shell retains its existing controlled final-entry checks. Neither path supplies OS isolation or a guarantee that every tool will run without prompts.
|
|
53
71
|
|
|
54
72
|
Workflow and role instructions also prefer short shell operations and repository-native tools, prohibit cross-shell destructive path composition, require exact path checks before recursive deletion, and prohibit autonomous Git writes. These instructions complement, not replace, the host sandbox and approval pipeline. Read-only role authority is bound to exact live Agent ownership/admission, not a persona label. Native caller filters remain intact. Agent admission restricts inherited tools and installs monotonic execution guards; own-layer definitions are identity-fenced, including a re-registered `read` impersonating a safe operation. rc.2 has no public hide-own-layer filter: a registration may remain displayed, but forbidden/unadmitted invocation must fail. Native sandbox/approval/observation remain authoritative.
|
|
55
73
|
|
package/docs/settings-status.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Deepwork settings and status
|
|
2
2
|
|
|
3
|
-
DSMM 0.3.
|
|
3
|
+
DSMM 0.3.11 targets exactly DSH `0.2.1-rc.2`. Named policy is covered in [profiles](profiles.md), routing in [model routing](model-routing.md), and child authority in [Agent presets](agent-presets.md).
|
|
4
4
|
|
|
5
5
|
## Deployment layers and native editors
|
|
6
6
|
|
package/lib/child-capture.js
CHANGED
|
@@ -124,6 +124,10 @@ export function parseChildAdmissionCapture(input) {
|
|
|
124
124
|
}
|
|
125
125
|
const policyKeys = ["modules", "roleRouting", "runtimePolicy", "workflow", "guards", "runtimeRecovery", "defaultActive", "skills", "subagents", ...version === 3 ? [] : HISTORICAL_POLICY_FIELDS];
|
|
126
126
|
const policy = object(row.runtimePolicyCapture, policyKeys);
|
|
127
|
+
const guards = object(policy.guards, Object.keys(CAPTURE_POLICY_SHAPE.guards).filter(key => key !== "gitWriteScope"), ["gitWriteScope"]);
|
|
128
|
+
// All capture versions permit omission with the original all-writes behavior.
|
|
129
|
+
if (!Object.hasOwn(guards, "gitWriteScope"))
|
|
130
|
+
guards.gitWriteScope = "all-writes";
|
|
127
131
|
if (version !== 3)
|
|
128
132
|
for (const key of HISTORICAL_POLICY_FIELDS) {
|
|
129
133
|
const choices = key.endsWith("Calibration") ? ["off", "auto", "strict"] : ["off", "low", "high"];
|
|
@@ -170,7 +174,7 @@ const CAPTURE_POLICY_SHAPE = {
|
|
|
170
174
|
modules: { deepwork: { enabled: null } },
|
|
171
175
|
runtimePolicy: { strategy: null, rateLimit: { maxRetries: null, initialDelayMs: null, maxDelayMs: null, maxTotalDelayMs: null, switchAfterRateLimits: null, maxSwitches: null } },
|
|
172
176
|
workflow: { policy: null, strictGates: null, reviewCap: null, finalReviewPolicy: null },
|
|
173
|
-
guards: { scope: null, shellCommandSafety: null, gitWriteGuard: null, toolOutputTruncation: { enabled: null, maxInlineBytes: null }, planFormatValidation: null, questionLabelHelper: { enabled: null, maxLabelChars: null }, todoDisciplineHelper: null },
|
|
177
|
+
guards: { scope: null, shellCommandSafety: null, gitWriteGuard: null, gitWriteScope: null, toolOutputTruncation: { enabled: null, maxInlineBytes: null }, planFormatValidation: null, questionLabelHelper: { enabled: null, maxLabelChars: null }, todoDisciplineHelper: null },
|
|
174
178
|
runtimeRecovery: { enabled: null, retryOnStatusCodes: null, retryOnCodes: null, fallbackRoutes: null, maxFallbackAttempts: null, idleContinuation: { enabled: null, maxContinuations: null, prompt: null } },
|
|
175
179
|
};
|
|
176
180
|
function validateLegacyRoutes(policy) {
|
|
@@ -97,6 +97,7 @@ export const deploymentFieldLabels = {
|
|
|
97
97
|
promptOrder: ["Prompt order", "提示词顺序"], defaultActive: ["Default Deepwork mode", "默认 Deepwork 模式"],
|
|
98
98
|
enabled: ["Enabled", "启用"], materialize: ["Materialize presets", "物化预设"], scope: ["Guard scope", "保护范围"],
|
|
99
99
|
shellCommandSafety: ["Shell command safety", "Shell 命令安全"], gitWriteGuard: ["Git write policy", "Git 写入策略"],
|
|
100
|
+
gitWriteScope: ["Automatic Git write scope (all-writes / high-risk)", "自动 Git 写入范围(all-writes 全部写入 / high-risk 仅高危)"],
|
|
100
101
|
toolOutputTruncation: ["Tool output truncation", "工具输出截断"], maxInlineBytes: ["Inline byte limit", "内联字节上限"],
|
|
101
102
|
planFormatValidation: ["Plan format validation", "计划格式校验"], questionLabelHelper: ["Question labels", "提问标签"], maxLabelChars: ["Label character limit", "标签字符上限"], todoDisciplineHelper: ["Todo discipline", "待办纪律"],
|
|
102
103
|
enableRunInBackground: ["Allow background runs", "允许后台执行"], backgroundMode: ["Background mode", "后台模式"], maxDepth: ["Maximum depth", "最大深度"],
|