fix: 修复 desirecore PR #533 Copilot 评审反馈的 7 项内容问题

[desirecore PR #533](https://github.com/desirecore/desirecore/pull/533) 把
market 全局技能快照同步到主仓库,Copilot 自动评审命中 7 处文档与代码
不一致问题,全部根因在 market 的 skill 文档;本 PR 在源头修复,让下次
sync-global-skills 自然带过去。

修复内容:

1. disable-model-invocation 语义描述反向(3 处文件 × 2 语言 = 5 处编辑)
   - skill-creator/SKILL.md (en-US)
   - skill-creator/SKILL.zh-CN.md
   - manage-skills/SKILL.md (en-US)
   - manage-skills/SKILL.zh-CN.md
   - 注:references/desirecore-format.md 已在 PR #1 解冲突时一并修好

   实际代码逻辑(lib/agent-service/skills/parser.ts):只有显式
   `disable-model-invocation: false` 才会被加入 system prompt 自动加载列表,
   `true` 或缺省都会跳过自动注入、需显式 Skill 工具调用。文档原描述把这两个
   值的语义对调了,且错误地宣称存在 L0/L1 vs L0+L1+L2 的"分层加载机制"
   (runtime 不区分这三个层级,加载就是整篇 SKILL.md)。

2. dev-environment-setup/references/probe-snapshot.md 协议字段类型 / 超时承诺
   - desirecore_port_file: string → boolean(probe.sh 输出 ${PORT_FILE_EXISTS}
     原生 bool;probe.ps1 输出 PowerShell bool;JSON 序列化均为 true/false)
   - "CLI 调用最长 5s" → "CLI 调用依赖工具自身实现,无显式 timeout 包装,
     正常情况通常 <5s 完成"(HTTP probe 确有 0.5s/1s timeout,但 --version
     这类 CLI 没有 timeout 5s 包装,文档原文承诺超出实现)

3. minimax-music-gen 使用过时的 provider 字段(应为 providerId)
   - skills/minimax-music-gen/SKILL.md(3 处)
   - skills/minimax-music-gen/SKILL.zh-CN.md(3 处)
   - 与 sibling minimax-tts/image-gen/video-gen 对齐,使用
     `"providerId": "provider-minimax-media-001"`,避免 media-proxy 路由到
     coding/token plan 等同名 provider

版本与日期:

- skill-creator: 1.0.1 → 1.0.2
- manage-skills: 1.0.2 → 1.0.3
- dev-environment-setup: 2.0.1 → 2.0.2
- minimax-music-gen: 1.1.1 → 1.1.2
- 上述 4 个 SKILL.md 的 metadata.updated_at 与 manifest.json#stats.lastUpdated
  统一为 2026-05-05

i18n 处理:

按 PR #1 修复模式(commit 2a21e8e),同步编辑英文源(SKILL.md = en-US default)
与中文翻译(SKILL.zh-CN.md = source),不动 metadata.i18n.<locale>.source_hash /
translated_at 字段(CI translate.py 维护)。
This commit is contained in:
2026-05-05 00:47:30 +08:00
parent 1f7c8b9673
commit 8047c8b0dc
9 changed files with 21 additions and 21 deletions

View File

@@ -28,7 +28,7 @@
"stats": {
"totalAgents": 1,
"totalSkills": 23,
"lastUpdated": "2026-05-04"
"lastUpdated": "2026-05-05"
},
"features": [
"verified-only",

View File

@@ -12,7 +12,7 @@ description: >-
cross-cutting environment question. 使用场景:用户提到 环境配置、PATH、
容器、Docker、Podman、WSL、WSL2、办公依赖、系统工具或不确定属于 Python /
Node.js 时的入口指引。
version: 2.0.1
version: 2.0.2
type: procedural
risk_level: low
status: enabled
@@ -27,7 +27,7 @@ tags:
- router
metadata:
author: desirecore
updated_at: '2026-05-02'
updated_at: '2026-05-05'
i18n:
default_locale: en-US
source_locale: zh-CN

View File

@@ -9,7 +9,7 @@
| `platform` | `"darwin" \| "linux" \| "win32"` | 操作系统标识 |
| `arch` | `"arm64" \| "x64" \| ...` | CPU 架构 |
| `desirecore_api` | `string` | 探测到的 DesireCore agent-service URL不可达时为 `""` |
| `desirecore_port_file` | `string` | `~/.desirecore/agent-service.port` 是否存在 |
| `desirecore_port_file` | `boolean` | `~/.desirecore/agent-service.port` 是否存在probe.sh / probe.ps1 输出原生 JSON boolean |
## probe.sh / probe.ps1父级 dev-environment-setup
@@ -95,7 +95,7 @@ Windows 上 `wsl` 字段值类似 `{ "installed": true, "version": "2", "default
1. **JSON 必合法**:缺字段也保留键并赋空字符串/`null`,避免 Claude 解析失败。
2. **不阻塞**:每个外部命令都加 `2>/dev/null`,失败用空值,不让脚本中途退出。
3. **超时控制**HTTP 探测 0.5s 超时CLI 调用最长 5s
3. **超时控制**HTTP 探测 0.5s 超时curl `--max-time`/PowerShell `TimeoutSec`CLI 调用(`--version` 等)依赖工具自身实现,无显式 timeout 包装,正常情况通常 <5s 完成
4. **跨平台**`probe.sh` / `probe-python.sh` / `probe-node.sh` 共用 POSIX 子集Windows 同等功能由 `probe.ps1` 提供仅父级提供python/nodejs 子 skill 可由 PowerShell 直接 invoke 父级或自行实现)。
5. **路径展开**:所有 `~` 在 JSON 中展开为绝对路径,避免下游解析歧义。

View File

@@ -4,7 +4,7 @@ description: >-
管理 Agent 的技能生命周期:通过 HTTP API 导入、安装、更新、删除技能,
或通过 AgentFS 文件系统直接编写符合规范的 SKILL.md。Use when 用户要求
安装技能、从 URL/Git 导入技能、编写新技能、或管理已有技能。
version: 1.0.2
version: 1.0.3
type: meta
risk_level: low
status: enabled
@@ -17,7 +17,7 @@ tags:
- agentfs
metadata:
author: desirecore
updated_at: '2026-03-03'
updated_at: '2026-05-05'
i18n:
default_locale: en-US
source_locale: zh-CN
@@ -508,7 +508,7 @@ covering completed items, to-dos, and important decisions.
| `risk_level` | Recommended | enum | `low` / `medium` / `high` |
| `status` | Recommended | enum | `enabled` / `disabled` |
| `tags` | Optional | string[] | List of tags, used for search and categorization |
| `disable-model-invocation` | Optional | boolean | `true` = L0+L1 auto-injected into the system prompt; `false` = full L0+L1+L2 content injected; default `true` |
| `disable-model-invocation` | Optional | boolean | `false` = opt-in auto-injection of full content into the system prompt; `true` (or omitted) = no auto-injection, only loaded when explicitly invoked via the Skill tool; default `true` |
| `requires` | Optional | object | Dependency declaration: `tools`, `optional_tools`, `connections` |
| `metadata` | Optional | object | Meta information: `author`, `updated_at` |
| `market` | Optional | object | Market display metadata (only required for Skills published to the Market) |

View File

@@ -447,7 +447,7 @@ metadata:
| `risk_level` | 推荐 | enum | `low` / `medium` / `high` |
| `status` | 推荐 | enum | `enabled` / `disabled` |
| `tags` | 可选 | string[] | 标签列表,用于搜索和分类 |
| `disable-model-invocation` | 可选 | boolean | `true`=L0+L1 自动注入 system prompt`false`=L0+L1+L2 完整内容注入;默认 `true` |
| `disable-model-invocation` | 可选 | boolean | `false`=opt-in 自动注入完整内容到 system prompt`true` 或缺省=不自动注入,仅显式 Skill 工具调用时才加载;默认 `true` |
| `requires` | 可选 | object | 依赖声明:`tools``optional_tools``connections` |
| `metadata` | 可选 | object | 元信息:`author``updated_at` |
| `market` | 可选 | object | 市场展示元数据(仅市场发布的技能需要) |

View File

@@ -7,7 +7,7 @@ description: >-
AI 作曲、创作歌曲、写一首歌、音乐生成、AI 音乐、MiniMax 音乐、
作词作曲、纯音乐、伴奏、翻唱、cover。
license: Complete terms in LICENSE.txt
version: 1.1.1
version: 1.1.2
type: procedural
risk_level: low
status: enabled
@@ -24,7 +24,7 @@ requires:
- Bash
metadata:
author: desirecore
updated_at: '2026-05-03'
updated_at: '2026-05-05'
i18n:
default_locale: en-US
source_locale: zh-CN
@@ -123,7 +123,7 @@ PORT=$(cat ~/.desirecore/agent-service.port)
curl -sk -X POST "https://127.0.0.1:${PORT}/api/media-proxy" \
-H "Content-Type: application/json" \
-d '{
"provider": "minimax",
"providerId": "provider-minimax-media-001",
"endpoint": "/music_generation",
"body": {
"model": "music-2.6",
@@ -146,7 +146,7 @@ PORT=$(cat ~/.desirecore/agent-service.port)
curl -sk -X POST "https://127.0.0.1:${PORT}/api/media-proxy" \
-H "Content-Type: application/json" \
-d '{
"provider": "minimax",
"providerId": "provider-minimax-media-001",
"endpoint": "/music_generation",
"body": {
"model": "music-2.6",
@@ -259,7 +259,7 @@ PORT=$(cat ~/.desirecore/agent-service.port)
curl -sk -X POST "https://127.0.0.1:${PORT}/api/media-proxy" \
-H "Content-Type: application/json" \
-d '{
"provider": "minimax",
"providerId": "provider-minimax-media-001",
"endpoint": "/music_generation",
"body": {
"model": "music-2.6",

View File

@@ -58,7 +58,7 @@ PORT=$(cat ~/.desirecore/agent-service.port)
curl -sk -X POST "https://127.0.0.1:${PORT}/api/media-proxy" \
-H "Content-Type: application/json" \
-d '{
"provider": "minimax",
"providerId": "provider-minimax-media-001",
"endpoint": "/music_generation",
"body": {
"model": "music-2.6",
@@ -81,7 +81,7 @@ PORT=$(cat ~/.desirecore/agent-service.port)
curl -sk -X POST "https://127.0.0.1:${PORT}/api/media-proxy" \
-H "Content-Type: application/json" \
-d '{
"provider": "minimax",
"providerId": "provider-minimax-media-001",
"endpoint": "/music_generation",
"body": {
"model": "music-2.6",
@@ -194,7 +194,7 @@ PORT=$(cat ~/.desirecore/agent-service.port)
curl -sk -X POST "https://127.0.0.1:${PORT}/api/media-proxy" \
-H "Content-Type: application/json" \
-d '{
"provider": "minimax",
"providerId": "provider-minimax-media-001",
"endpoint": "/music_generation",
"body": {
"model": "music-2.6",

View File

@@ -5,7 +5,7 @@ description: >-
frontmatter 元数据 + L0/L1/L2 分层内容 + 脚本/参考/资产)和 Claude Code
基础格式。Use when 用户要求创建新技能、更新已有技能、或将经验封装为可复用
的技能包。
version: 1.0.1
version: 1.0.2
type: meta
risk_level: low
status: enabled
@@ -18,7 +18,7 @@ tags:
- authoring
metadata:
author: desirecore
updated_at: '2026-04-03'
updated_at: '2026-05-05'
i18n:
default_locale: en-US
source_locale: zh-CN
@@ -161,7 +161,7 @@ A SKILL.md consists of two parts: **Frontmatter (YAML metadata)** and **Body (Ma
| Field | Type | Default | Description |
|------|------|------|------|
| `disable-model-invocation` | boolean | `true` | `true` = L0+L1 auto-injected into the system prompt (lazy load, small footprint); `false` = full L0+L1+L2 content injected into the system prompt |
| `disable-model-invocation` | boolean | `true` | `false` = opt-in auto-injection of full SKILL.md content into the system prompt (auto-loaded); `true` (or omitted) = no auto-injection, only loaded when an Agent explicitly invokes the Skill tool (aligned with Claude Skills: disabled by default, opt-in) |
| `user-invocable` | boolean | `true` | `false` = does not appear in command completion; serves only as background knowledge |
| `allowed-tools` | string[] | — | Restricts the list of tools available at execution time |
| `requires` | object | — | Dependency declaration: `tools`, `optional_tools`, `connections` |

View File

@@ -100,7 +100,7 @@ SKILL.md 由两部分组成:**FrontmatterYAML 元数据)** 和 **BodyM
| 字段 | 类型 | 默认 | 说明 |
|------|------|------|------|
| `disable-model-invocation` | boolean | `true` | `true`=L0+L1 自动注入 system prompt按需加载体积小`false`=L0+L1+L2 完整内容注入 system prompt |
| `disable-model-invocation` | boolean | `true` | `false`=opt-in 自动注入完整 SKILL.md 内容到 system prompt自动加载`true` 或缺省=不自动注入,仅当 Agent 显式调用 Skill 工具时才加载(与 Claude Skills 对齐:默认禁用,需显式启用) |
| `user-invocable` | boolean | `true` | `false`=不出现在命令补全,仅作为背景知识 |
| `allowed-tools` | string[] | — | 限制执行时可用的工具列表 |
| `requires` | object | — | 依赖声明:`tools``optional_tools``connections` |