@yottameta/yotta-skills 0.24.1 → 0.25.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/CHANGELOG.md +14 -0
- package/README.md +20 -0
- package/README.zh-CN.md +20 -0
- package/SKILL.md +43 -2
- package/bin/yotta-skills.js +415 -29
- package/lib/agent-dirs.js +201 -0
- package/lib/agent-discovery.js +302 -0
- package/lib/hub-adopt.js +268 -0
- package/lib/hub.js +583 -0
- package/lib/skills-cli-lock.js +52 -0
- package/lib/skills-scan.js +28 -38
- package/package.json +1 -1
- package/references/hub.md +66 -0
- package/references/skill-list.md +1 -1
- package/scan-policy.json +3 -3
- package/scripts/yotta-skills-mcp.py +1 -1
- package/skill-manifest.json +1 -1
- package/skills.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,17 @@
|
|
|
1
|
+
## v0.25.0 (2026-10-02)
|
|
2
|
+
|
|
3
|
+
- 新增本机技能 Hub(标准 `yotta-skills-hub/v1`):`hub hosts` 只读发现本机宿主与技能目录(文件系统优先,不读元忆 / 注册表);`hub install` / `hub update` 把技能装到 `~/.yottaskills/hub` 单点真源;`hub adopt --scan|--apply` 收编各宿主现有技能(默认复制保真 + 原目录保留);`hub refresh <slug> --from <path>` 手动同步非元阁来源技能;`hub link --all` 用 Windows junction / POSIX symlink 分发到全部已发现宿主;`hub unlink` fail-closed 只删链接;`hub status` 显示来源、版本、链接与异常;`hub doctor` 检查断链 / 目标缺失 / slug 不一致 / 目录权限。
|
|
4
|
+
- 宿主发现复用公开宿主表(兼容 Vercel Labs `skills` CLI / SkillCat 的目录映射,当前 79 条),支持 `CODEX_HOME` / `XDG_CONFIG_HOME` / `DSH_HOME` / `OPENCLAW_STATE_DIR` / `CLAUDE_CONFIG_DIR` 等环境变量覆盖,并过滤临时目录、`.bak`、candidate / staging、插件构建目录等噪声。
|
|
5
|
+
- 只读桥接 Vercel Labs `skills` CLI 的 `.skill-lock.json` v3(`$XDG_STATE_HOME/skills/` 或 `~/.agents/`);元阁不重写官方锁文件,只在 Hub 台账中合并来源信息。
|
|
6
|
+
- 兼容矩阵实测:官方 `skills@1.7.0` 在临时假 home 中 8/8 宿主透过 Windows junction 读取同一技能;元阁 `hub hosts` 本机识别 31 个技能目录 / 44 个已装应用标记。证据:`docs\元阁-Hub-宿主兼容矩阵-2026-10-02.md`。
|
|
7
|
+
- WorkBuddy 复验修复:`hub doctor` 对「Hub 目录存在但零技能」判为 error 并提示先 `hub install` / `hub adopt --apply`;`hub link` / `hub unlink` 补齐 `--json` 结构化输出,不再静默退化为文本。
|
|
8
|
+
- 新增 `lib/agent-dirs.js` / `lib/agent-discovery.js` / `lib/hub.js` / `lib/hub-adopt.js` / `lib/skills-cli-lock.js` 与 `test/hub.test.js`;全量测试 289/289。
|
|
9
|
+
|
|
10
|
+
## v0.24.2 (2026-10-02)
|
|
11
|
+
|
|
12
|
+
- 家族清单同步:元忆 `0.21.1`(管理台归属 AI 平铺选择 + 记忆详情抽屉遮罩层级修复)。
|
|
13
|
+
- scanPolicy 重绑:元忆 0.21.1 的已审查例外按新 treeHash 绑定。
|
|
14
|
+
|
|
1
15
|
## v0.24.1 (2026-10-02)
|
|
2
16
|
|
|
3
17
|
- 家族清单同步:元忆 `0.21.0`(记忆管理台 M1:真实读写 / 权限矩阵 / 归档与回收区撤销)。
|
package/README.md
CHANGED
|
@@ -101,6 +101,17 @@ npx -y @yottameta/yotta-skills --inventory
|
|
|
101
101
|
|
|
102
102
|
# Re-index the registry (on demand; install / update re-index automatically)
|
|
103
103
|
npx -y @yottameta/yotta-skills --reindex
|
|
104
|
+
|
|
105
|
+
# Discover installed agents and their skill directories (filesystem-first; no memory registry)
|
|
106
|
+
npx -y @yottameta/yotta-skills hub hosts
|
|
107
|
+
|
|
108
|
+
# Install once into the local Hub, then link to every discovered host
|
|
109
|
+
npx -y @yottameta/yotta-skills hub install
|
|
110
|
+
npx -y @yottameta/yotta-skills hub adopt --scan
|
|
111
|
+
npx -y @yottameta/yotta-skills hub adopt --apply
|
|
112
|
+
npx -y @yottameta/yotta-skills hub link --all
|
|
113
|
+
npx -y @yottameta/yotta-skills hub status
|
|
114
|
+
npx -y @yottameta/yotta-skills hub doctor
|
|
104
115
|
```
|
|
105
116
|
|
|
106
117
|
Requirements: Node.js 18+, npm, and system <code>tar</code> (built into Windows 10+ / macOS / most Linux distributions).
|
|
@@ -125,6 +136,15 @@ Requirements: Node.js 18+, npm, and system <code>tar</code> (built into Windows
|
|
|
125
136
|
| `--registry <url>` | npm registry to check against (default https://registry.npmjs.org/; `YOTTA_SKILLS_REGISTRY` overrides) |
|
|
126
137
|
| `--inventory` | Inventory installed skills: scan skill directories and update the local registry (self-contained); `--json` for JSON, `--project` adds project-level dirs |
|
|
127
138
|
| `--reindex` | Re-index the registry: re-scan skill directories and merge changes incrementally (on demand; `install` / `update` re-index automatically; `--rescan` is a synonym); `--json` for JSON |
|
|
139
|
+
| `hub hosts` | Discover installed agents and their skill directories (filesystem + environment; never reads the memory registry); `--json` for JSON |
|
|
140
|
+
| `hub install [skill...]` | Install family skills into the local Hub (`~/.yottaskills/hub` by default; override with `--hub` / `YOTTA_SKILLS_HUB`) |
|
|
141
|
+
| `hub adopt --scan` | Read-only preview: scan existing host skills and report adoption candidates, duplicate conflicts and Hub state |
|
|
142
|
+
| `hub adopt --apply [--include <a,b>] [--force] [--in-place]` | Adopt selected skills into the Hub; copy-preserving by default and keep the original directory; non-YottaMeta sources are marked "no update source" |
|
|
143
|
+
| `hub refresh <slug> --from <path>` | Manually re-sync a non-YottaMeta skill (re-adopt, refresh hash and ledger) |
|
|
144
|
+
| `hub link --all` | Link Hub skills into every discovered host (Windows junction / POSIX symlink) |
|
|
145
|
+
| `hub unlink --all` | Remove links only; never touches Hub sources (fail-closed for real directories or foreign links) |
|
|
146
|
+
| `hub status` | Show Hub sources, versions, link hosts and drift; `--json` for JSON |
|
|
147
|
+
| `hub doctor` | Check broken links, missing Hub targets, slug mismatches and directory permissions; exit 1 on errors; `--json` for JSON |
|
|
128
148
|
| `--route <task-summary>` | Orchestration routing: return a combination, call order, per-skill roles, confidence, evidence, installed/missing status, and an install suggestion; also lists other installed (non-YottaMeta) skills as candidates matched mechanically against their frontmatter description, tagged "not scanned", read-only and never auto-invoked; an optional local provider may add or re-order installed skills within the allow-list and return <code>confidence</code> / <code>reasons</code> / <code>summary</code> / <code>alternatives</code> (see <code>references/provider-protocol.md</code>); `--json` for JSON plus a `dynamic` status block, `--project` adds project-level dirs |
|
|
129
149
|
| `usage status` / `usage enable` / `usage disable` | Inspect / enable / disable local structured usage signals; off by default and limited to slug, time, signal type, playbook / confidence and skill pairs |
|
|
130
150
|
| `usage mark --skill <slug> --signal used\|named\|accepted` | Record one explicit usage signal; no prior enable required |
|
package/README.zh-CN.md
CHANGED
|
@@ -104,6 +104,17 @@ npx -y @yottameta/yotta-skills --inventory
|
|
|
104
104
|
|
|
105
105
|
# 重扫注册表(随时手动运行;install / update 完成后已自动重扫)
|
|
106
106
|
npx -y @yottameta/yotta-skills --reindex
|
|
107
|
+
|
|
108
|
+
# 发现本机已装智能体与技能目录(文件系统优先,不读元忆 / 注册表)
|
|
109
|
+
npx -y @yottameta/yotta-skills hub hosts
|
|
110
|
+
|
|
111
|
+
# 单点装到本机 Hub,再链接分发到全部已发现宿主
|
|
112
|
+
npx -y @yottameta/yotta-skills hub install
|
|
113
|
+
npx -y @yottameta/yotta-skills hub adopt --scan
|
|
114
|
+
npx -y @yottameta/yotta-skills hub adopt --apply
|
|
115
|
+
npx -y @yottameta/yotta-skills hub link --all
|
|
116
|
+
npx -y @yottameta/yotta-skills hub status
|
|
117
|
+
npx -y @yottameta/yotta-skills hub doctor
|
|
107
118
|
```
|
|
108
119
|
|
|
109
120
|
前置:Node.js 18+、npm、系统 tar(Windows 10+ / macOS / 多数 Linux 自带)。
|
|
@@ -128,6 +139,15 @@ npx -y @yottameta/yotta-skills --reindex
|
|
|
128
139
|
| `--registry <url>` | 检查的 npm registry 地址(默认 https://registry.npmjs.org/;`YOTTA_SKILLS_REGISTRY` 覆盖) |
|
|
129
140
|
| `--inventory` | 盘点已装技能:扫描技能目录并更新本地注册表(自包含);`--json` 输出 JSON、`--project` 附扫项目级目录 |
|
|
130
141
|
| `--reindex` | 重扫注册表:扫描技能目录并增量合并变化(install / update 完成后自动重扫,也可随时手动运行;`--rescan` 同义);`--json` 输出 JSON |
|
|
142
|
+
| `hub hosts` | 发现本机已装智能体与技能目录(文件系统 + 环境变量;不读元忆 / 注册表);`--json` 输出 JSON |
|
|
143
|
+
| `hub install [skill...]` | 把元技能安装到本机 Hub 真源(默认 `~/.yottaskills/hub`;`--hub` / `YOTTA_SKILLS_HUB` 覆盖) |
|
|
144
|
+
| `hub adopt --scan` | 只读预演:扫描各宿主现有技能,输出收编候选、多副本冲突与已在 Hub 状态 |
|
|
145
|
+
| `hub adopt --apply [--include <a,b>] [--force] [--in-place]` | 把选中技能收编进 Hub;默认复制保真 + 原目录保留;非元阁来源标注「无更新源」 |
|
|
146
|
+
| `hub refresh <slug> --from <path>` | 手动同步非元阁技能(重新收编 + 更新哈希 + 台账) |
|
|
147
|
+
| `hub link --all` | 把 Hub 技能链接到全部已发现宿主(Windows junction / POSIX symlink) |
|
|
148
|
+
| `hub unlink --all` | 只删除链接,不动 Hub 真源(fail-closed;真目录 / 非 Hub 链接一律拒绝) |
|
|
149
|
+
| `hub status` | 查看 Hub 技能来源、版本、链接宿主与异常;`--json` 输出 JSON |
|
|
150
|
+
| `hub doctor` | 检查断链 / Hub 目标缺失 / slug 不一致 / 目录权限;异常时退出码 1;`--json` 输出 JSON |
|
|
131
151
|
| `--route <需求摘要>` | 编排路由:输出组合、调用顺序、技能角色、置信度、依据、已装/缺失状态与安装建议;可选本地扩展提供方在已装白名单内增补 / 重排并返回 `confidence` / `reasons` / `summary` / `alternatives`(未配置时行为不变,协议见 `references/provider-protocol.md`);`--json` 输出 JSON 与 `dynamic` 状态块、`--project` 附扫项目级目录 |
|
|
132
152
|
| `usage status` / `usage enable` / `usage disable` | 查看 / 开启 / 关闭本地结构化使用记录;默认关闭,只记录 slug、时间、信号类型、playbook / confidence 与组合对 |
|
|
133
153
|
| `usage mark --skill <slug> --signal used\|named\|accepted` | 记录一次显式使用信号;不要求先 enable |
|
package/SKILL.md
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: yotta-skills
|
|
3
|
-
version: 0.
|
|
4
|
-
description: 元阁 -- 元阁全家技能的总编排策划 + 编排路由 + 一键安装器 + 技能盘点 + 运行时 hook
|
|
3
|
+
version: 0.25.0
|
|
4
|
+
description: 元阁 -- 元阁全家技能的总编排策划 + 编排路由 + 一键安装器 + 技能盘点 + 本机技能 Hub + 运行时 hook 适配。Hub 层:hub hosts 只读发现本机已装智能体与技能目录(文件系统优先,不读元忆);hub install / update 把技能装到 ~/.yottaskills/hub 单点真源;hub link --all 用 Windows junction / POSIX symlink 分发到全部已发现宿主;hub unlink 只删链接、fail-closed;hub status 显示来源、版本、链接与异常;兼容 agentskills.io 技能格式、Vercel Labs skills CLI 的 .agents/skills 通用目录与 .skill-lock.json v3(只读)。路由层:--route / route_request 按需求摘要给出候选组合、调用顺序、角色、置信度、依据、已装/缺失状态与安装命令,只建议不自动安装;非元阁家族已装技能按 frontmatter description 机械匹配作并列候选(标注来源与未扫描状态,只读不自动调用);M1 记忆裁决层:usage enable/mark 本地结构化记录 + decide-memory / MCP decide_memory 输出 promote / hold / demote 只读建议(需授权 provider;只建议不删除、不自动写元忆);策划层:按场景给出「该组合哪几个元技能、组合强在哪、怎么组合使用(安装与调用均由用户确认后执行)」;安装层:一条命令把 YottaMeta 已发布的全部 yotta-* 技能装进指定智能体或目录(默认 --pin 锁死清单精确版本);盘点层:--inventory / --reindex 扫描本机已装技能生成/更新注册表,新装技能自动被发现(install/update 后自动 re-index,会话开工只建议跑本地 --reindex;更新检查走手动 --check 或后台 --check --scheduled);运行时适配层:hook capabilities / evaluate / bind / unbind 按宿主能力矩阵执行六个统一事件并留证降级,元信 before_install 已接入安装管线;自包含零依赖,不依赖任何元技能;MCP 按需加载且需用户确认后写入配置(可选:list_installed_skills/describe_skill/reindex/route_request/decide_memory,不常驻,未加载降级 CLI)。支持 --list 清单 / --route 路由 / usage 使用记录 / decide-memory 记忆裁决 / hub 技能 Hub / install / update / update --check(只读检查)/ update --check --scheduled(后台周检)/ update --auto(家族自动更新)/ hook 适配 / --inventory / --reindex / --dry-run 预览 / --pin(默认)/ --range。触发:需要批量安装或更新元阁全家技能、单点安装并分发到多个智能体、查看本机装了哪些智能体与技能目录、接管非元技能、按场景组合多个元技能、路由或判断该用哪些技能、判断哪些技能值得长期记忆、查看或记录技能使用信号、盘点或查看本机已装技能、重扫技能注册表、给某个智能体或目录一次性铺齐 yotta-* 技能、评估宿主 hook 能力、预览安装清单、锁版本安装、或用户说 元阁/装全家/一次装齐/yotta-skills/install-all/更新全家/检查更新/自动更新/hook 适配/该用哪个技能/路由技能/记忆裁决/技能该不该记住/盘点技能/查看已装技能/技能 Hub/单点安装/链接分发/接管技能 等。边界(Do NOT trigger):只做「组合策划 + 静态路由建议 + M1 记忆裁决只读建议 + 清单 + 下载 + 落位 + 汇总 + 盘点 + re-index + Hub 本机真源与链接分发 + hook 适配」,不含技能本体、不做技能内容开发、不 -g 污染全局、不自动安装缺失技能、不静默写宿主配置或全局记忆、不自动删除技能或记忆;家族安装先自举或调用元信装前门禁,DO NOT INSTALL 阻断,非元阁家族包不自动安装。
|
|
5
5
|
license: MIT
|
|
6
6
|
metadata:
|
|
7
7
|
zh_name: 元阁
|
|
@@ -154,6 +154,38 @@ openclaw skills update @yottameta/yotta-skills
|
|
|
154
154
|
> **OpenClaw / QClaw 用户**:技能安装与更新走宿主官方命令 `openclaw skills install|update @yottameta/<slug>`,
|
|
155
155
|
> 以保留宿主的 ClawHub 安全审计卡与更新追踪;元阁的 `--inventory` / `--reindex` 已能识别 `~/.openclaw/skills`(含 `OPENCLAW_STATE_DIR` 覆盖)。
|
|
156
156
|
|
|
157
|
+
## 技能 Hub(单点安装 + 链接分发)
|
|
158
|
+
|
|
159
|
+
Hub 把「每个宿主装一份」改成「本机一份真源,按宿主链接分发」。默认真源
|
|
160
|
+
`~/.yottaskills/hub`,可用 `--hub <dir>` 或 `YOTTA_SKILLS_HUB` 覆盖。
|
|
161
|
+
|
|
162
|
+
```bash
|
|
163
|
+
# 1) 只读发现本机已装智能体与技能目录(文件系统 + 环境变量;不读元忆 / 注册表)
|
|
164
|
+
npx -y @yottameta/yotta-skills hub hosts
|
|
165
|
+
|
|
166
|
+
# 2) 把元技能装进 Hub 真源(复用安装管线 + 元信装前扫描)
|
|
167
|
+
npx -y @yottameta/yotta-skills hub install
|
|
168
|
+
|
|
169
|
+
# 3) 接管各宿主现有技能:先只读预演,再复制收编(原目录保留)
|
|
170
|
+
npx -y @yottameta/yotta-skills hub adopt --scan
|
|
171
|
+
npx -y @yottameta/yotta-skills hub adopt --apply
|
|
172
|
+
|
|
173
|
+
# 4) 链接分发到全部已发现宿主(Windows junction / macOS·Linux symlink)
|
|
174
|
+
npx -y @yottameta/yotta-skills hub link --all
|
|
175
|
+
|
|
176
|
+
# 5) 查看来源、版本、链接宿主与异常
|
|
177
|
+
npx -y @yottameta/yotta-skills hub status
|
|
178
|
+
npx -y @yottameta/yotta-skills hub doctor
|
|
179
|
+
|
|
180
|
+
# 只删链接,不动 Hub 真源(真目录 / 外部链接一律拒绝)
|
|
181
|
+
npx -y @yottameta/yotta-skills hub unlink --all
|
|
182
|
+
```
|
|
183
|
+
|
|
184
|
+
宿主发现兼容 `agentskills.io` 技能格式与 Vercel Labs `skills` CLI 的
|
|
185
|
+
`.agents/skills` 通用目录;已收录 79 条宿主映射,并只读兼容
|
|
186
|
+
`.skill-lock.json` v3(`$XDG_STATE_HOME/skills/` 或 `~/.agents/`)。
|
|
187
|
+
不读元忆,不重写官方锁文件,不静默降级为复制。
|
|
188
|
+
|
|
157
189
|
## 命令与选项
|
|
158
190
|
|
|
159
191
|
| 命令 / 选项 | 作用 |
|
|
@@ -174,6 +206,15 @@ openclaw skills update @yottameta/yotta-skills
|
|
|
174
206
|
| `hook bind --host <name> --manifest <file>` | 幂等注册 hook 声明;`hook unbind <id>` 反注册 |
|
|
175
207
|
| `--inventory` | 盘点本机已装技能:扫描技能目录生成/更新注册表(自包含,不依赖元技能);`--json` 输出 JSON、`--project` 附扫项目级目录 |
|
|
176
208
|
| `--reindex` | 重扫注册表:扫描技能目录并增量合并变化(install / update 完成后 CLI 自动重扫;也可在会话开工等时机手动运行);`--json` 输出 JSON、`--project` 附扫项目级目录;`--rescan` 同义 |
|
|
209
|
+
| `hub hosts` | 发现本机已装智能体与技能目录(文件系统 + 环境变量;不读元忆 / 注册表);`--json` 输出 JSON |
|
|
210
|
+
| `hub install [skill...]` | 把元技能安装到 Hub 真源(默认 `~/.yottaskills/hub`;`--hub` / `YOTTA_SKILLS_HUB` 覆盖) |
|
|
211
|
+
| `hub adopt --scan` | 只读预演:扫描各宿主现有技能,输出收编候选、多副本冲突、已在 Hub 状态 |
|
|
212
|
+
| `hub adopt --apply [--include <a,b>] [--force] [--in-place]` | 把选中技能收编进 Hub;默认复制保真 + 原目录保留;非元阁来源标注「无更新源」 |
|
|
213
|
+
| `hub refresh <slug> --from <path>` | 手动同步非元阁技能(重新收编 + 更新哈希 + 台账) |
|
|
214
|
+
| `hub link --agent <id> \| --dir <dir> \| --all` | 把 Hub 技能链接到指定宿主 / 目录 / 全部已发现宿主;`--dry-run` 只预览 |
|
|
215
|
+
| `hub unlink --agent <id> \| --dir <dir> \| --all` | 只删除链接;lstat + readlink 校验目标在 Hub 内,fail-closed |
|
|
216
|
+
| `hub status [--json]` | 查看 Hub 技能来源、版本、链接宿主、异常链接与宿主发现摘要 |
|
|
217
|
+
| `hub doctor [--json]` | 检查断链 / Hub 目标缺失 / slug 不一致 / 目录权限;异常时退出码 1 |
|
|
177
218
|
| `--route <需求摘要>` | 编排路由:输出组合、调用顺序、技能角色、置信度、依据、已装/缺失状态与安装建议;可选本地 provider 增补 / 重排并返回 `confidence` / `reasons` / `summary` / `alternatives`;`--json` 输出 JSON、`--project` 附扫项目级目录 |
|
|
178
219
|
| `usage status` | 查看本地使用记录开关与计数;默认关闭,不创建文件 |
|
|
179
220
|
| `usage enable` / `usage disable` | 开启 / 关闭 `--route` 的结构化使用记录;不记录需求原文 |
|