Skip to content

Local-first AI coding agent desktop: Electron + Rust host core + pi Agent Harness + user-installable plugins

Merge origin/main into docs/2000-plugin-ipc-audit

Tioit-Wangb81b136716bd
diff --cc docs/spec/07-plugins/12-plugin-ipc-and-host-services.md
index 9b8992fcf,0ceea6933..9747e9edb
--- a/docs/spec/07-plugins/12-plugin-ipc-and-host-services.md
+++ b/docs/spec/07-plugins/12-plugin-ipc-and-host-services.md
@@@ -162,12 -113,12 +162,12 @@@ handler is logged, never fatal. This i
## 5. ContributionRegistry behavior
### Registration
- - Command authors should choose unique ids, conventionally
- `plugin.<pluginId>.<commandId>`. The child forwards the supplied id unchanged;
- the broker does not prepend or validate this namespace. Registration replaces
- an existing command with the same id, and unregister deletes that id without
- checking the registered command's owner. This is current behavior, not an
- enforced cross-plugin isolation guarantee.
-- key must be unique
-- Command IDs are preserved as supplied; `plugin.<pluginId>.<commandId>` is
- a naming convention, not an enforced prefix. The host rejects registration
- of another plugin's command ID with `CONFLICT` and rejects removal of
- another plugin's command with `PERMISSION_DENIED`. Same-owner updates and
- unregistering an absent ID remain valid.
++- Command IDs are preserved as supplied and conventionally named
++ `plugin.<pluginId>.<commandId>`; the broker does not prepend or validate that
++ namespace. The host rejects registration of another plugin's command ID with
++ `CONFLICT`, and rejects removal of another plugin's command with
++ `PERMISSION_DENIED`. Same-owner updates, and unregistering an absent ID,
++ remain valid.
- Plugin tool prefix policy: `plugin_<pluginIdSafe>_<toolName>` (fixed in the implementation)
### Query
diff --cc docs/zh-CN/spec/07-plugins/12-plugin-ipc-and-host-services.md
index 5e0594b9c,b052355c0..ce219c749
--- a/docs/zh-CN/spec/07-plugins/12-plugin-ipc-and-host-services.md
+++ b/docs/zh-CN/spec/07-plugins/12-plugin-ipc-and-host-services.md
@@@ -147,11 -100,11 +147,11 @@@ host-core 的 `plugin.installProgress`
## 5. ContributionRegistry 行为
### 注册
- - 命令作者应选择唯一 ID,通常使用 `plugin.<pluginId>.<commandId>`。
- 子进程原样转发传入的 ID,调用代理不会自动添加或校验该命名空间。
- 注册同名命令会覆盖现有条目;注销操作直接删除指定 ID,不检查已注册命令的所属插件。
- 这是当前实现的行为,不能视为已强制执行的跨插件隔离保证。
- - 插件工具名称使用固定前缀:`plugin_<pluginIdSafe>_<toolName>`(由实现强制生成)
-- 密钥必须是唯一的
-- 命令 ID 按原值保存;`plugin.<pluginId>.<commandId>` 是命名约定,宿主不会强制添加该前缀。
- 注册其他插件已占用的命令 ID 时,宿主返回 `CONFLICT` 错误;注销其他插件的命令时,
- 宿主返回 `PERMISSION_DENIED` 错误。插件仍可更新自己的命令,也可注销不存在的 ID。
++- 命令 ID 按原值保存,约定使用 `plugin.<pluginId>.<commandId>` 形式;调用代理
++ 不会自动添加或校验该命名空间。注册其他插件已占用的命令 ID 时,宿主返回
++ `CONFLICT` 错误;注销其他插件的命令时,宿主返回 `PERMISSION_DENIED` 错误。
++ 插件仍可更新自己的命令,也可注销不存在的 ID。
+ - 插件工具前缀策略:`plugin_<pluginIdSafe>_<toolName>`(在实现中修复)
### 查询
- 命令面板仅查询已启用+加载成功的贡献