@ai-workbench/remote-agent 0.9.0-toolbridge.17 → 0.9.0-toolbridge.18

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 CHANGED
@@ -1,8 +1,8 @@
1
- # AI Workbench 远程助手 · @ai-workbench/remote-agent@0.9.0-toolbridge.17 · 插件 → 添加插件
1
+ # AI Workbench 远程助手 · @ai-workbench/remote-agent@0.9.0-toolbridge.18 · 插件 → 添加插件
2
2
 
3
3
  ## 含工具桥预发布线
4
4
 
5
- 本包为 `0.9.0-toolbridge.17`,从 `v0.9.0-toolbridge.14` 派生,使用 `host-toolbridge` 发布渠道。员工安装由连接组件提供的「AI 写作工作台(含工具桥)」总包 `@ai-workbench/workbench-toolbridge@0.1.14`,与不含工具桥的版本二选一。
5
+ 本包为 `0.9.0-toolbridge.18`,从 `v0.9.0-toolbridge.14` 派生,使用 `host-toolbridge` 发布渠道。员工安装由连接组件提供的「AI 写作工作台(含工具桥)」总包 `@ai-workbench/workbench-toolbridge@0.1.15`,与不含工具桥的版本二选一。
6
6
 
7
7
  本轮增加两家运行中插话(DSH 原生 nextStep),保留官方队列和原话;明确 followup 仍排下一轮。Codex 含桥组件需 `2.2.2-aw.12`,Claude 仍为官方 `0.94.0`。插件确定消息未发出时保留排队资格;送达未确认时明确报错且不重放。已注入旧正文不能撤回,编辑版下一步骤交付。
8
8
 
@@ -10,8 +10,10 @@ host `0.8.11` 的新 broker 支持同一客户端/SDK 在切网后按输出游
10
10
 
11
11
  原轮正常完成(或冷接回已交付原结果)后结束该轮主机 broker,原生线程写锁随之释放,同一 DSH 会话下一轮不再因旧轮保留 10 分钟而报“原会话仍被占用”;结果未定(插件退出、断开、失败)时仍保留原轮待接回。旧 X.14–.16 发出的结束请求在主机上始终不生效,只有升级本包才消除;只升主机不够。
12
12
 
13
+ 本机文件夹下的主机 Claude 可以开自己的子代理(原生 Agent 与 TaskStop),子代理还能再开子代理,插件不加层数或次数限制。子代理继承同一工具表:原生 Read/Write/Edit/Glob/Grep/Bash 仍关闭,文件和命令只走员工本机工具并按原审批;工具桥的 DSH 工具同样可用。子代理的工具事件进技术详情,结论由主 Claude 在原回复里给出;取消本轮会一并结束子代理。SendMessage/ListAgents 不开放,因为它们能触及主机账号的其他本地和云端会话;子代理完成后结果仍自动交回主 Claude。主机文件夹本就允许,行为不变。Codex 自身的多代理功能本线没有关闭(层数和线程数是 Codex 上游默认值,插件不改)。
13
14
 
14
- 选择本机文件夹后,Claude 和 Codex 可以把 DSH 已启用的 MCP、web、skill、ask_user、todo/present/goal 等工具交给 DSH 原生执行和审批。内置文件/命令、子代理/agent-team、run_code 不在桥接表;原有文件和命令执行方式保留。plan 不自动放行桥接权限;default 下 Claude 的桥接原生权限由插件单次应答,员工只在 DSH 审批实际工具。主机文件夹不开放工具桥。
15
+
16
+ 选择本机文件夹后,Claude 和 Codex 可以把 DSH 已启用的 MCP、web、skill、ask_user、todo/present/goal 等工具交给 DSH 原生执行和审批。DSH 内置文件/命令、子代理/agent-team、run_code 不经工具桥转交(主机 Claude 的子代理由其原生运行);原有文件和命令执行方式保留。plan 不自动放行桥接权限;default 下 Claude 的桥接原生权限由插件单次应答,员工只在 DSH 审批实际工具。主机文件夹不开放工具桥。
15
17
 
16
18
  工具表按每次主机连接生成快照,新增/移除在下一次连接生效;不承诺 Codex 当前 MCP 会话热刷新。审批期间的插话等当前主机 prompt 结束后再发,停泊中切换助手会停止原轮次并明确提示。工具主动结束DSH轮次时,已提交结果仍交回原agent;确认原生工具收到后结束原prompt,下一条沿原线程继续,不在已关闭步骤追加模型回复。取消和主机结束等待后的结果不重放;工具已执行的副作用不能因取消而撤销,请按说明核对。图片结果由官方附件组件读取后交回。
17
19
 
package/dist/acp.js CHANGED
@@ -7,7 +7,9 @@ import { employeeFailure } from "./presentation.js";
7
7
  import { isolateRpcIds } from "./rpc-namespace.js";
8
8
  import { sanitizeObservation, sanitizeDisplayLabel } from "./conversation-details.js";
9
9
  import { ModelConfiguration, ModelConfigurationError } from "./model-configuration.js";
10
- function employeeClaudeOptions(routing) { return { tools: [], disallowedTools: ['Read', 'Write', 'Edit', 'Glob', 'Grep', 'Bash', 'Agent', 'Task', 'TaskOutput', 'TaskStop'], toolAliases: structuredClone(routing.toolAliases) }; }
10
+ // Native subagents stay on (Agent/TaskStop): children inherit this tool pool, deny rules and the employee MCP aliases, so their files/commands also run on the employee device.
11
+ // SendMessage/ListAgents stay off: they also reach other local and cloud sessions of the host account.
12
+ function employeeClaudeOptions(routing) { return { tools: ['Agent', 'TaskStop'], disallowedTools: ['Read', 'Write', 'Edit', 'Glob', 'Grep', 'Bash'], toolAliases: structuredClone(routing.toolAliases) }; }
11
13
  const permissionRanks = { claude: { plan: 0, default: 1, acceptEdits: 1, bypassPermissions: 2 }, codex: { 'read-only': 0, 'workspace-write': 1, agent: 1, 'agent-full-access': 2 } };
12
14
  /** ACP v1 with explicitly negotiated SDK 2.0 lifecycle/context extensions. */
13
15
  export class AcpSession {
@@ -155,7 +155,7 @@ export function createClaudeLocalProvider(options) {
155
155
  });
156
156
  };
157
157
  const executionSignal = modelLifetime.signal;
158
- row.runtime = { ...underlying, localDirectory: { ...workspace.directory }, closeDiagnostics, cwd: workspace.directory.path, details, connection: { ...connection }, binding: { bindingId: item.bindingId, workspaceId: workspace.workspaceId, revision: state.revision }, execution: { hostCwd: target.session.root, routing: mcp.routing, notice: NOTICE, signal: executionSignal, scope: { source: 'local', cwd: workspace.directory.path, hostCwd: target.session.root, uid: lease.target.endpoint.remoteUid, claudeAcpVersion: '0.94.0', sdkVersion: '0.3.303', unsupported: ['subagents', 'internal-direct-calls', 'binary-read', 'background-shell'] }, validate: async (signal) => { signal?.throwIfAborted(); lease.signal.throwIfAborted(); executionSignal.throwIfAborted(); }, beginTurn: async (signal) => { signal?.throwIfAborted(); lease.signal.throwIfAborted(); executionSignal.throwIfAborted(); if (row.closing || row.active)
158
+ row.runtime = { ...underlying, localDirectory: { ...workspace.directory }, closeDiagnostics, cwd: workspace.directory.path, details, connection: { ...connection }, binding: { bindingId: item.bindingId, workspaceId: workspace.workspaceId, revision: state.revision }, execution: { hostCwd: target.session.root, routing: mcp.routing, notice: NOTICE, signal: executionSignal, scope: { source: 'local', cwd: workspace.directory.path, hostCwd: target.session.root, uid: lease.target.endpoint.remoteUid, claudeAcpVersion: '0.94.0', sdkVersion: '0.3.303', unsupported: ['internal-direct-calls', 'binary-read', 'background-shell'] }, validate: async (signal) => { signal?.throwIfAborted(); lease.signal.throwIfAborted(); executionSignal.throwIfAborted(); }, beginTurn: async (signal) => { signal?.throwIfAborted(); lease.signal.throwIfAborted(); executionSignal.throwIfAborted(); if (row.closing || row.active)
159
159
  throw failure('TURN_BUSY'); row.active = { signal, details: row.details }; }, endTurn: () => { row.active = undefined; } }, dispose: cause => close(false, cause), detach: cause => close(true, cause) };
160
160
  entries.set(request.sessionId, row);
161
161
  const endpointAborted = () => {
package/dist/index.js CHANGED
@@ -540,7 +540,7 @@ export class CodexRemoteAdapter extends LlmAdapter {
540
540
  }
541
541
  }
542
542
  if (execution) {
543
- if (toolName && ['Agent', 'Task', 'TaskOutput', 'TaskStop', 'Read', 'Write', 'Edit', 'Glob', 'Grep', 'Bash'].includes(toolName)) {
543
+ if (toolName && ['Read', 'Write', 'Edit', 'Glob', 'Grep', 'Bash'].includes(toolName)) {
544
544
  details.record({ kind: 'need', severity: 'warning', code: 'CLAUDE_HOST_TOOL_UNSUPPORTED', summary: '这类原生调用没有经过员工端别名,本机来源不支持;本次审批已取消', payload: { operation: toolName } });
545
545
  renderNotice('\n这类操作尚不支持在本机执行,已取消本次审批,没有在主机代跑。\n');
546
546
  return 'cancelled';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ai-workbench/remote-agent",
3
- "version": "0.9.0-toolbridge.17",
3
+ "version": "0.9.0-toolbridge.18",
4
4
  "type": "module",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",