dsh-ntr 0.1.6 → 0.2.0
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.en.md +1 -1
- package/README.md +1 -1
- package/cordis.patch.yml +18 -18
- package/lib/bridge.js +120 -291
- package/lib/client/acp-ui.js +60 -32
- package/lib/client/index.js +17 -0
- package/lib/client/panel.js +37 -42
- package/lib/client/permission-dock.js +72 -0
- package/lib/client/session-controls.js +4 -4
- package/lib/client/store.js +58 -12
- package/lib/client.js +296 -95
- package/lib/client.js.map +1 -1
- package/lib/impl.js +30 -19
- package/lib/index.js +6 -51
- package/lib/types/bridge.d.ts +60 -154
- package/lib/types/client/panel.d.ts +12 -19
- package/lib/types/client/permission-dock.d.ts +31 -0
- package/lib/types/client/store.d.ts +42 -12
- package/lib/types/impl.d.ts +31 -17
- package/lib/types/protocol.d.ts +27 -12
- package/package.json +1 -1
- package/src/bridge.ts +147 -357
- package/src/client/acp-ui.tsx +60 -32
- package/src/client/index.tsx +18 -0
- package/src/client/panel.tsx +54 -58
- package/src/client/permission-dock.tsx +133 -0
- package/src/client/session-controls.tsx +4 -4
- package/src/client/store.ts +81 -25
- package/src/impl.ts +49 -29
- package/src/index.ts +6 -65
- package/src/protocol.ts +32 -12
package/README.en.md
CHANGED
|
@@ -113,7 +113,7 @@ DSH's own `/model`, `/permission`, `/export`, etc. are **not** intercepted by th
|
|
|
113
113
|
|
|
114
114
|
### Approvals and the agent's own permission modes
|
|
115
115
|
|
|
116
|
-
When the agent wants to touch something sensitive, it asks you. The
|
|
116
|
+
When the agent wants to touch something sensitive, it asks you. The ask appears in the conversation on a card just above the composer (the plugin's own card); the options are exactly the agent's, and what you click is what it receives. The Settings page's "Pending Permission Requests" card is the cross-session mirror — answer there when the conversation isn't open.
|
|
117
117
|
|
|
118
118
|
Every agent asks differently: some offer a set of options, some only allow/deny, some attach the exact command they are about to run. The plugin presents these as-is, and never pre-decides for you.
|
|
119
119
|
|
package/README.md
CHANGED
|
@@ -113,7 +113,7 @@ DSH 自己的 `/model`、`/permission`、`/export` 等在这一模式下**不会
|
|
|
113
113
|
|
|
114
114
|
### 审批与 agent 自己的权限模式
|
|
115
115
|
|
|
116
|
-
agent
|
|
116
|
+
agent 要动敏感的东西时会问你。询问卡出现在对话里、聊天输入框上方(插件自己的卡片),选项就是 agent 给的那些,你点哪个它照着做;设置页的「待处理权限请求」是跨会话镜像,对话没打开时在那里回答。
|
|
117
117
|
|
|
118
118
|
每个 agent 问法不一样:有的给一组选项,有的只给允许/拒绝,有的会附上它要执行的具体命令。插件把这些原样呈现给你,不预先替你决定。
|
|
119
119
|
|
package/cordis.patch.yml
CHANGED
|
@@ -31,25 +31,25 @@
|
|
|
31
31
|
# startupTimeoutMs: 60000 # budget for initialize / session/new / session/load
|
|
32
32
|
# permissionTimeoutMs: 300000
|
|
33
33
|
# How long a permission ask may sit unanswered
|
|
34
|
-
# before the deadline fires. ONE window for
|
|
35
|
-
#
|
|
36
|
-
#
|
|
37
|
-
#
|
|
38
|
-
#
|
|
34
|
+
# before the deadline fires. ONE window for every
|
|
35
|
+
# ask, wherever it is answered — the conversation
|
|
36
|
+
# card above the composer (`PermissionDock`) or
|
|
37
|
+
# the Settings page's cross-session mirror
|
|
38
|
+
# ("待处理权限请求"): one question, one answer.
|
|
39
39
|
# 0 = 不等待: the ask is settled the moment it
|
|
40
|
-
# arrives, nobody is asked (no
|
|
41
|
-
#
|
|
42
|
-
# `auto` mode ONLY — it
|
|
43
|
-
#
|
|
44
|
-
# would refuse every ask on
|
|
45
|
-
# stops at every gate), so
|
|
46
|
-
# shortest real wait. "Never
|
|
47
|
-
# this key's business — that is
|
|
48
|
-
# below.
|
|
49
|
-
# When the deadline fires, the ask is
|
|
50
|
-
#
|
|
51
|
-
# the
|
|
52
|
-
# `permissionTimeoutMode`'s business.
|
|
40
|
+
# arrives, nobody is asked (no conversation card,
|
|
41
|
+
# no pending entry on the Settings page). That
|
|
42
|
+
# rung belongs to the `auto` mode ONLY — it
|
|
43
|
+
# ANSWERS the ask, so the agent continues. Under
|
|
44
|
+
# `abort` the same zero would refuse every ask on
|
|
45
|
+
# arrival (the agent stops at every gate), so
|
|
46
|
+
# `abort` starts at the shortest real wait. "Never
|
|
47
|
+
# expires" is NOT this key's business — that is
|
|
48
|
+
# `wait` mode below.
|
|
49
|
+
# When the deadline fires, the ask is settled IN
|
|
50
|
+
# PLACE: the card goes away and `permission/expired`
|
|
51
|
+
# records the outcome in the conversation. What
|
|
52
|
+
# happens is `permissionTimeoutMode`'s business.
|
|
53
53
|
# LEGACY: `nativeApprovalTimeoutMs` and
|
|
54
54
|
# `permissionFallbackTimeoutMs` are still accepted
|
|
55
55
|
# and folded into this key (this key wins when it
|