dsh-xray 0.1.0 → 0.1.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.md +22 -5
- package/README.zh.md +22 -5
- package/lib/index.js +5 -5
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -4,22 +4,39 @@ X-ray for your [DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harnes
|
|
|
4
4
|
|
|
5
5
|
[中文](./README.zh.md)
|
|
6
6
|
|
|
7
|
-
> **Status:
|
|
7
|
+
> **Status: 0.1.x — static imaging.** The CLI works today, even when dsh cannot boot. Runtime imaging (dependency graph, health, context cost) lands in 0.2.0.
|
|
8
8
|
|
|
9
9
|
`dsh --dump-config` shows you the composed tree. The plugin panel shows you a flat list. Neither tells you *why* a plugin is there, *what breaks* if you disable it, or *what it silently costs you*. dsh-xray does.
|
|
10
10
|
|
|
11
|
-
##
|
|
11
|
+
## CLI
|
|
12
12
|
|
|
13
|
-
|
|
13
|
+
```sh
|
|
14
|
+
npx dsh-xray attribute # which layer introduced each row, and who patched it since
|
|
15
|
+
npx dsh-xray conflicts # rows whose fields have multiple writers, and who wins
|
|
16
|
+
npx dsh-xray diff # declared (static layers) vs actual (dump-config) tree
|
|
17
|
+
npx dsh-xray snapshot # content-addressed lockfile of the effective composition
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
All commands take `--profile <name>` (default `web`) and `--json`. `diff` exits `1` when the trees disagree — orphan patch rows silently skipped by dsh, installed-but-inactive plugins, disabled-state mismatches. `attribute`, `conflicts`, and `snapshot` are fully static: they work even when dsh cannot start.
|
|
21
|
+
|
|
22
|
+
## Capabilities
|
|
23
|
+
|
|
24
|
+
Diagnostic imaging for a running composition — complementary to [dsh-doctor](https://www.npmjs.com/package/dsh-doctor) (rescue & recovery).
|
|
25
|
+
|
|
26
|
+
Shipped in 0.1.x:
|
|
14
27
|
|
|
15
28
|
- **Layer attribution** — which layer introduced each active plugin: kernel bundle, profile dependency, `cordis.patch.yml` insert, or repository source
|
|
16
29
|
- **Declared vs. actual diff** — installed-but-inactive, uninstalled-but-lingering patch rows
|
|
30
|
+
- **Conflict detection** — plugins patching the same config row, and which one silently wins
|
|
31
|
+
- **Composition snapshot** — export the effective composition as a lockfile; reproduce it elsewhere
|
|
32
|
+
|
|
33
|
+
Planned:
|
|
34
|
+
|
|
17
35
|
- **Service dependency graph** — who `inject`s whose service; what cascades if you disable X
|
|
18
36
|
- **Runtime health** — per-plugin scope state: activation failures, stacks, load time, HMR reloads
|
|
19
37
|
- **Capability audit** — what installed plugins actually touch: network egress, shell, filesystem, env; permission diff across updates
|
|
20
|
-
- **
|
|
38
|
+
- **Command/tool shadowing** — plugins registering the same command/tool, and which one silently wins
|
|
21
39
|
- **Context cost** — tokens each plugin injects into agent context: tool schemas, prompt sections, skills
|
|
22
|
-
- **Composition snapshot** — export the effective composition as a lockfile; reproduce it elsewhere
|
|
23
40
|
- **Agent self-introspection** — expose the composition as a tool so agents know what capabilities they have
|
|
24
41
|
|
|
25
42
|
## Install
|
package/README.zh.md
CHANGED
|
@@ -4,22 +4,39 @@
|
|
|
4
4
|
|
|
5
5
|
[English](./README.md)
|
|
6
6
|
|
|
7
|
-
>
|
|
7
|
+
> **状态:0.1.x — 静态成像。** CLI 现在就能用,即使 dsh 起不来。运行时成像(依赖图、健康状态、上下文成本)在 0.2.0 落地。
|
|
8
8
|
|
|
9
9
|
`dsh --dump-config` 只给你原始组合树,插件面板只给你平铺列表。它们都不回答:这个插件*为什么*在这、停用它会*连带瘫掉什么*、它在*悄悄消耗什么*。dsh-xray 回答这些。
|
|
10
10
|
|
|
11
|
-
##
|
|
11
|
+
## CLI
|
|
12
12
|
|
|
13
|
-
|
|
13
|
+
```sh
|
|
14
|
+
npx dsh-xray attribute # 每一行由哪层引入、之后被谁 patch 过
|
|
15
|
+
npx dsh-xray conflicts # 哪些行的字段有多个写者、最终谁赢
|
|
16
|
+
npx dsh-xray diff # 声明(静态层)vs 实际(dump-config)组合树
|
|
17
|
+
npx dsh-xray snapshot # 当前生效组合的内容寻址 lockfile
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
所有命令支持 `--profile <name>`(默认 `web`)和 `--json`。`diff` 在两棵树不一致时以退出码 `1` 结束——被 dsh 静默跳过的 orphan patch 行、装了但未生效的插件、disabled 状态不匹配。`attribute`、`conflicts`、`snapshot` 是纯静态的:dsh 起不来时照样能跑。
|
|
21
|
+
|
|
22
|
+
## 能力
|
|
23
|
+
|
|
24
|
+
对运行中组合树的诊断成像——与 [dsh-doctor](https://www.npmjs.com/package/dsh-doctor)(救援与恢复)互补。
|
|
25
|
+
|
|
26
|
+
0.1.x 已交付:
|
|
14
27
|
|
|
15
28
|
- **来源归因** — 每个活跃插件来自哪一层:内核 bundle / profile 依赖 / `cordis.patch.yml` insert / repository 源
|
|
16
29
|
- **声明 vs 实际 diff** — 装了但没生效、卸了但残留 patch 行
|
|
30
|
+
- **冲突检测** — 多个插件 patch 同一配置行时,谁静默赢了
|
|
31
|
+
- **组合快照** — 把当前生效组合导出为 lockfile,异地一键复现
|
|
32
|
+
|
|
33
|
+
规划中:
|
|
34
|
+
|
|
17
35
|
- **服务依赖图** — 谁 `inject` 了谁的服务;停用 X 会级联影响什么
|
|
18
36
|
- **运行时健康** — 每个插件的 scope 状态:激活失败与堆栈、加载耗时、HMR 重载次数
|
|
19
37
|
- **能力审计** — 已装插件实际触碰什么:网络外发、shell、文件系统、环境变量;更新前后权限 diff
|
|
20
|
-
-
|
|
38
|
+
- **命令/工具重名检测** — 注册同名命令/工具时,谁静默覆盖谁
|
|
21
39
|
- **上下文成本** — 每个插件往 agent 上下文注入多少 token:工具 schema、prompt 片段、skill 文档
|
|
22
|
-
- **组合快照** — 把当前生效组合导出为 lockfile,异地一键复现
|
|
23
40
|
- **Agent 自省** — 把组合信息暴露为 tool,让 agent 知道自己有哪些能力
|
|
24
41
|
|
|
25
42
|
## 安装
|
package/lib/index.js
CHANGED
|
@@ -5,13 +5,13 @@ const name = 'dsh-xray';
|
|
|
5
5
|
/**
|
|
6
6
|
* dsh-xray — X-ray for your DeepSeek Harness.
|
|
7
7
|
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
8
|
+
* 0.1.x: static imaging ships in the CLI (bin/xray.js) — layer attribution,
|
|
9
|
+
* declared-vs-actual diff, conflict detection, composition snapshot.
|
|
10
|
+
* This Cordis entry is a mount point; runtime imaging (dependency graph,
|
|
11
|
+
* health, context cost, agent self-introspection) lands here in 0.2.0.
|
|
12
12
|
*/
|
|
13
13
|
function apply(ctx) {
|
|
14
|
-
ctx.logger(name).info('dsh-xray
|
|
14
|
+
ctx.logger(name).info('dsh-xray mounted; run `npx dsh-xray` for static composition imaging (runtime imaging lands in 0.2.0)');
|
|
15
15
|
}
|
|
16
16
|
|
|
17
17
|
module.exports = { name, apply };
|