Bundle
lt-dsh-skill-manager
lt-dsh-skill-manager · DeepSeek Harness 技能管理插件:在设置面板管理 ~/.dsh/skills 下的技能,支持多目录导入与 AI 名称解析(导入的 skill 可在对话框用 /name 直接引用)
- Source
- tianLee-gitter
- License
- MIT
- Updated
- Updated 3 days ago
Readme
# lt-lt-lt-dsh-skill-manager · DSH 技能管理插件
[](https://github.com/tianLee-gitter/lt-lt-dsh-skill-manager)
[](./LICENSE)
[](https://www.npmjs.com/package/lt-lt-lt-dsh-skill-manager)
> DeepSeek Harness(DSH)技能管理插件:在**设置 → 技能管理**页面维护 `~/.dsh/skills/`
> 下的所有技能,支持**一次选择多个目录导入**,导入时由**所选 AI 模型解析技能名称**
> (小写 kebab-case,如 `nodejs`、`my-skill`),名称与目录不一致时**自动重命名目录**,
> 导入后的技能可直接在对话框用 **`/name`** 引用。
## ✨ 特性
- **技能列表**:列出 `~/.dsh/skills/`(`<dshHome>/skills`)下已导入的目录束
(`<name>/SKILL.md`)与扁平 Markdown(`<name>.md`)技能,展示 `name`、`description`、
有效性徽标与来源目录
- **多目录导入**:点击「导入技能…」可同时选择多个技能目录(每个含 `SKILL.md` 或顶层 `.md`),
浏览器读取文件后经 RPC 传输(自动跳过 `.git`)
- **AI 名称解析**:导入时可选 harness 上已配置的模型(默认 harness 默认模型)解析技能名称与
一句话描述;解析结果强制规范化为 harness 对话框 `/name` 语法
`^[a-z0-9]+(?:-[a-z0-9]+)*$`(优先采用文档已声明的小写标识如 `slug`),
因此导入后即可用 `/名称` 直接引用;同名技能自动跳过(`already-exists`),不会覆盖
- **目录自动重命名**:目录名与解析出的名称不一致时,按名称重命名后写入
`~/.dsh/skills/<name>/`,并重写 frontmatter 保证目录名 / `name` / `description` 一致
## 🚀 安装
**方式 A:从 GitHub 安装**
```bash
dsh plugin add github:tianLee-gitter/lt-lt-dsh-skill-manager --profile web
# 或:dsh plugin add https://github.com/tianLee-gitter/lt-lt-dsh-skill-manager.git --profile web
```
**方式 B:从 npm 安装**(预构建,免 allowBuilds 构建授权)
```bash
dsh plugin add lt-lt-lt-dsh-skill-manager --profile web
```
> 💡 如果你的 profile 名不是 `web`,把上面命令里的 `--profile web` 换成你的 profile 名。
装完重启 `dsh web`,浏览器刷新即可。验证:
```bash
curl -s http://127.0.0.1:3080/plugins/lt-lt-lt-dsh-skill-manager/client.js # client bundle(应返回 JS)
curl -sX POST http://127.0.0.1:3080/api/skillManager/list \
-H "content-type: application/json" \
-d '{"type":"client-request","rpcId":"probe","method":"skillManager/list","payload":{"args":{}}}'
# 应返回 {"type":"server-response",...,"result":{"ok":true,"value":{"root":"...","skills":[...]}}}
```
## 🎯 使用
1. 打开 **设置 → 技能管理**
2. 选择 **AI 解析模型**(默认 harness 默认模型;不选则跳过 AI 解析,回退到
frontmatter 的 `name` / `slug` / 目录名)
3. 点击 **导入技能…**,一次选择多个技能目录
4. 查看导入结果:每个技能的名称、描述、以及目录是否被重命名;失败项会给出原因
(无 SKILL.md / 同名已存在 / 名称无法规范化 / 路径不安全)
## ⚙️ 配置(可选)
全部配置在包内 `cordis.patch.yml` 插件行的 `config` 里:`dshHome`(技能根目录,默认 `~/.dsh`)、
`maxAiInputBytes`(AI 输入截断,默认 6000)、`maxAiOutputTokens`(AI 输出上限,默认 300)、
`aiTimeoutMs`(AI 请求超时,默认 30000)。
- **停用插件**:把 `cordis.patch.yml` 中 `# disabled: true` 行首的 `#` 去掉,重启 `dsh web`
## 🗑 卸载 / 🔄 更新
```bash
dsh plugin remove lt-lt-lt-dsh-skill-manager --profile web # 卸载,然后重启 dsh web
# 更新(GitHub 源):cd <仓库目录> && git pull && dsh plugin add "$PWD" --profile web
# 更新(npm 源):dsh plugin update lt-lt-lt-dsh-skill-manager --profile web
```
## 🛟 故障排查
| 现象 | 排查 |
|---|---|
| 设置页没有「技能管理」 | 确认安装后重启 `dsh web` 并强刷浏览器(Ctrl+Shift+R) |
| 导入报 `already-exists` | 同名技能已存在(保护机制),先删除 `~/.dsh/skills/<name>` 再重导 |
| 导入的 `name` 非预期 | 模型解析是尽力而为;可在 frontmatter 写 `slug`(如 `slug: nodejs`)引导,或修改 `SKILL.md` 的 `name` |
| `/name` 无法在对话框引出 | 名称必须匹配 `^[a-z0-9]+(?:-[a-z0-9]+)*$`(小写 kebab);导入结果里的名称均合规 |
## 📄 License
MIT
Install
dsh plugin --profile web add github:tianLee-gitter/lt-dsh-skill-manager
Profile: web
With the hub plugin installed, ask your agent to install it by name — it resolves the same plan shown here.
dsh plugin --profile web add github:stvlynn/dsh.fish#path:packages/dsh-plugin-hub
install lt-dsh-skill-manager from the hub
- This package builds from source on install. pnpm will ask you to allow its build script — that is permission to run the package’s code on your machine, outside the agent sandbox. Only allow sources you trust.
- This source has no pinned commit, so a later push upstream changes what installs. Prefer pinning a commit.