@deepseek-ai/dsh-host-plugin-inventory 0.1.5-rc.2 → 0.1.6-alpha.1
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.i18n.yaml +2 -2
- package/README.md +3 -3
- package/README.zh.md +7 -7
- package/package.json +7 -7
package/README.i18n.yaml
CHANGED
|
@@ -2,5 +2,5 @@
|
|
|
2
2
|
# side as of the last confirmed-consistent state. Both languages carry equal authority;
|
|
3
3
|
# after editing either side, bring the other along and re-record with:
|
|
4
4
|
# pnpm run verify-translation-pairing --write packages/host/plugin-inventory/README.md
|
|
5
|
-
README.md:
|
|
6
|
-
README.zh.md:
|
|
5
|
+
README.md: b64a017df28716cfd0b5c3a41f437b87b8e4f19e
|
|
6
|
+
README.zh.md: a29bc402537d88fa512675bfb768502753ca7929
|
package/README.md
CHANGED
|
@@ -9,7 +9,7 @@ English | [中文](README.zh.md)
|
|
|
9
9
|
|
|
10
10
|
## Summary
|
|
11
11
|
|
|
12
|
-
Clients can call `pluginInventory/list` to display the host’s current plugins in load order, including each entry’s identifier, module specifier, effective enablement, and live phase. Deployments with an agent-preset roster also report each preset’s metadata, health, and flattened plugin composition; without a roster, preset data is absent. Each response is a point-in-time, read-only snapshot for display and diagnostics: it cannot mutate plugins and provides no history,
|
|
12
|
+
Clients can call `pluginInventory/list` to display the host’s current plugins in load order, including each entry’s identifier, module specifier, effective enablement, and live phase. Deployments with an agent-preset roster also report each preset’s metadata, health, and flattened plugin composition; without a roster, preset data is absent. Each response is a point-in-time, read-only snapshot for display and diagnostics: it cannot mutate plugins and provides no history, introduction source, or change subscription.
|
|
13
13
|
|
|
14
14
|
## Table of Contents
|
|
15
15
|
|
|
@@ -49,7 +49,7 @@ The inventory is a snapshot for display and diagnostics: a client can render the
|
|
|
49
49
|
|
|
50
50
|
### Design concept
|
|
51
51
|
|
|
52
|
-
The gateway is a direct projection with no second lifecycle truth: every `list()` call reads `ctx.loader.entries()` and maps each non-group entry to its public row. Cordis's internal plugin/status events already maintain `Entry.fiber` and `Fiber.state`, so a cache would only add another lifecycle truth to keep synchronized. The agent-preset roster is an optional peer resolved per call through `ctx.get('agentPresets')`: its `compositionInventory()` owns every preset read, and this package only maps root-fiber states onto the public phase vocabulary.
|
|
52
|
+
The gateway is a direct projection with no second lifecycle truth: every `list()` call reads `ctx.loader.entries()` and maps each non-group entry to its public row. Cordis's internal `plugin/status` events already maintain `Entry.fiber` and `Fiber.state`, so a cache would only add another lifecycle truth to keep synchronized. The agent-preset roster is an optional peer resolved per call through `ctx.get('agentPresets')`: its `compositionInventory()` owns every preset read, and this package only maps root-fiber states onto the public phase vocabulary.
|
|
53
53
|
|
|
54
54
|
### The phase mapping
|
|
55
55
|
|
|
@@ -97,7 +97,7 @@ None; this package neither assembles nor sends a provider request.
|
|
|
97
97
|
These limits define what a point-in-time inventory cannot tell a client. They are current package constraints, not a task backlog.
|
|
98
98
|
|
|
99
99
|
- **Point-in-time state only** — the result contains no durable failure history or subscription; a missing root Fiber is reported as `null`, regardless of why no live root exists.
|
|
100
|
-
- **No
|
|
100
|
+
- **No introduction source or mutation** — the service does not identify which bundle, profile, or override introduced an entry, and it cannot enable, disable, add, or remove plugins in either plane.
|
|
101
101
|
- **Presets appear only with a roster** — a deployment without `dsh-agent-presets` serves Loader entries alone; the `agentPresets` field is absent rather than empty.
|
|
102
102
|
|
|
103
103
|
<a id="dev-note"></a>
|
package/README.zh.md
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: "当前 Cordis Loader 插件状态的只读投影,并附带每个
|
|
2
|
+
description: "当前 Cordis Loader 插件状态的只读投影,并附带每个 agent preset(智能体预设)的组合:面向 web GUI 宿主客户端的 pluginInventory 服务及其 pluginInventory/list Remote。"
|
|
3
3
|
kind: "package-reference"
|
|
4
4
|
---
|
|
5
5
|
|
|
@@ -9,7 +9,7 @@ kind: "package-reference"
|
|
|
9
9
|
|
|
10
10
|
## 概述
|
|
11
11
|
|
|
12
|
-
客户端可以调用 `pluginInventory/list`,按加载顺序展示宿主的当前插件,包括每个条目的标识符、模块标识、有效启用状态与存活阶段。部署组合了
|
|
12
|
+
客户端可以调用 `pluginInventory/list`,按加载顺序展示宿主的当前插件,包括每个条目的标识符、模块标识、有效启用状态与存活阶段。部署组合了 agent preset roster 时,还会报告各预设的元数据、健康状态与压平后的插件组合;没有 roster 时,预设数据缺席。每次响应都是供展示和诊断使用的只读即时快照:它不能修改插件,也不提供历史、来源信息或变更订阅。
|
|
13
13
|
|
|
14
14
|
## 目录
|
|
15
15
|
|
|
@@ -25,7 +25,7 @@ kind: "package-reference"
|
|
|
25
25
|
<a id="use-this-package"></a>
|
|
26
26
|
## 使用本包
|
|
27
27
|
|
|
28
|
-
当客户端或设置页需要展示宿主当前组合了什么——哪些插件已加载、已启用、是否存活,以及每个
|
|
28
|
+
当客户端或设置页需要展示宿主当前组合了什么——哪些插件已加载、已启用、是否存活,以及每个 agent preset 会给会话什么——时调用 `pluginInventory/list`。Remote 是唯一入口:该服务仅供 Remote 使用,刻意不声明同进程 Cordis `Context` 合并。
|
|
29
29
|
|
|
30
30
|
### 快照包含什么
|
|
31
31
|
|
|
@@ -33,7 +33,7 @@ kind: "package-reference"
|
|
|
33
33
|
|
|
34
34
|
### 每个预设的组合
|
|
35
35
|
|
|
36
|
-
组合了 roster 时,`agentPresets` 按 roster 顺序携带每个预设一组:其 id、随部署内置还是用户自建(`trust`,客户端据此本地化内置预设名)、发布的显示名、未指名预设的会话是否组合它,以及压平后的插件行——条目 id(文件行未声明时为 null)、模块标识、有效启用状态、行自带的 `!!js` disabled 表达式(如有),以及组合存活时的根 Fiber
|
|
36
|
+
组合了 roster 时,`agentPresets` 按 roster 顺序携带每个预设一组:其 id、随部署内置还是用户自建(`trust`,客户端据此本地化内置预设名)、发布的显示名、未指名预设的会话是否组合它,以及压平后的插件行——条目 id(文件行未声明时为 null)、模块标识、有效启用状态、行自带的 `!!js` disabled 表达式(如有),以及组合存活时的根 Fiber 阶段。已有会话组合过的预设由其最新仍存续的世代作答——即使其文件事后损坏也是如此,因为挂载才是这些会话实际运行的组合;开机以来从未被组合的预设由其组合文件作答,disabled 门用 Loader 上下文求值,且读取从不挂载预设。`conditional` 表示宿主无法求值的门;无人组合的坏预设保留在列表中,携带原因且没有行。没有 roster 时该字段缺席。
|
|
37
37
|
|
|
38
38
|
### 你能用它做什么、不能做什么
|
|
39
39
|
|
|
@@ -49,7 +49,7 @@ kind: "package-reference"
|
|
|
49
49
|
|
|
50
50
|
### 设计理念
|
|
51
51
|
|
|
52
|
-
网关是一层没有第二个生命周期真源的直接投影:每次 `list()` 调用都读取 `ctx.loader.entries()`,并把每个非组条目映射为公共行。Cordis 内部的 plugin/status 事件已经维护了 `Entry.fiber` 与 `Fiber.state`,因此再加缓存只会多出一个需要同步的生命周期真源。
|
|
52
|
+
网关是一层没有第二个生命周期真源的直接投影:每次 `list()` 调用都读取 `ctx.loader.entries()`,并把每个非组条目映射为公共行。Cordis 内部的 `plugin/status` 事件已经维护了 `Entry.fiber` 与 `Fiber.state`,因此再加缓存只会多出一个需要同步的生命周期真源。agent preset roster 是每次调用经 `ctx.get('agentPresets')` 解析的可选伙伴:所有预设读取都由它的 `compositionInventory()` 负责,本包只把根 Fiber 状态映射到公共阶段词汇。
|
|
53
53
|
|
|
54
54
|
### 阶段映射
|
|
55
55
|
|
|
@@ -61,7 +61,7 @@ Fiber 状态映射到公共阶段词汇,其中 `disposed` 折叠为 `null`—
|
|
|
61
61
|
|---|---|
|
|
62
62
|
| [`src/index.ts`](src/index.ts) | `PluginInventoryGateway`:`pluginInventory` Remote 服务与 Loader 投影 |
|
|
63
63
|
| [`src/types.ts`](src/types.ts) | 公共 payload 类型:`PluginInventoryEntry`、`PluginInventorySnapshot`、`PluginFiberPhase` |
|
|
64
|
-
| — |
|
|
64
|
+
| — | 不发布运行时不变式配套项;每个快照都投影 Loader 持有的状态。 |
|
|
65
65
|
|
|
66
66
|
Typert 生成由 `./typert` 与 `./remote` 导出的 Host 和 Client Remote 产物。
|
|
67
67
|
|
|
@@ -94,7 +94,7 @@ Typert 生成由 `./typert` 与 `./remote` 导出的 Host 和 Client Remote 产
|
|
|
94
94
|
<a id="known-limitations-and-deferred-work"></a>
|
|
95
95
|
|
|
96
96
|
|
|
97
|
-
|
|
97
|
+
这些限制说明即时清单无法向客户端提供哪些信息。它们是当前包约束,不是任务积压。
|
|
98
98
|
|
|
99
99
|
- **仅表示调用当下**——结果不包含持久的失败历史或订阅;只要不存在存活的根 Fiber,就会报告 `null`,而不区分其原因。
|
|
100
100
|
- **无来源与修改能力**——服务不识别条目由哪个 bundle、profile 或 override 引入,也不能在任一平面启用、停用、添加或移除插件。
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@deepseek-ai/dsh-host-plugin-inventory",
|
|
3
3
|
"description": "Read-only Remote projection of current Cordis Loader plugin state",
|
|
4
|
-
"version": "0.1.
|
|
4
|
+
"version": "0.1.6-alpha.1",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
7
7
|
},
|
|
@@ -48,9 +48,9 @@
|
|
|
48
48
|
},
|
|
49
49
|
"peerDependencies": {
|
|
50
50
|
"@deepseek-ai/cordis-plugin-loader": "^1.0.3",
|
|
51
|
-
"@deepseek-ai/dsh-agent-presets": "^0.1.
|
|
52
|
-
"@deepseek-ai/dsh-brand": "^0.1.
|
|
53
|
-
"@deepseek-ai/dsh-typert-protocol": "^0.1.
|
|
51
|
+
"@deepseek-ai/dsh-agent-presets": "^0.1.6-alpha.1",
|
|
52
|
+
"@deepseek-ai/dsh-brand": "^0.1.6-alpha.1",
|
|
53
|
+
"@deepseek-ai/dsh-typert-protocol": "^0.1.6-alpha.1",
|
|
54
54
|
"@deepseek-ai/cordis": "^4.0.2"
|
|
55
55
|
},
|
|
56
56
|
"peerDependenciesMeta": {
|
|
@@ -60,9 +60,9 @@
|
|
|
60
60
|
},
|
|
61
61
|
"devDependencies": {
|
|
62
62
|
"@deepseek-ai/cordis-plugin-loader": "^1.0.3",
|
|
63
|
-
"@deepseek-ai/dsh-agent-presets": "^0.1.
|
|
64
|
-
"@deepseek-ai/dsh-brand": "^0.1.
|
|
65
|
-
"@deepseek-ai/dsh-typert-protocol": "^0.1.
|
|
63
|
+
"@deepseek-ai/dsh-agent-presets": "^0.1.6-alpha.1",
|
|
64
|
+
"@deepseek-ai/dsh-brand": "^0.1.6-alpha.1",
|
|
65
|
+
"@deepseek-ai/dsh-typert-protocol": "^0.1.6-alpha.1",
|
|
66
66
|
"@deepseek-ai/cordis": "^4.0.2"
|
|
67
67
|
}
|
|
68
68
|
}
|