inventory.mjs 9.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237
  1. /**
  2. * 已发布技能清单(机器可读真值)
  3. * ---------------------------------------------------------------------------
  4. * inventory.md 是本文件的人类可读渲染。新增技能时**两处都要更新**,
  5. * 或直接跑 `skill-core inventory --check` 校验一致性。
  6. *
  7. * 平台标注说明:
  8. * gogs — 主 Gogs(git.fmode.cn/fmode/)
  9. * github — GitHub 镜像(github.com/fmodecn/)
  10. * npm — npm 包(包名见 npmName 字段)
  11. * skillhub — skillhub.cn 社区分发
  12. */
  13. import { TIERS } from './platform.mjs';
  14. /** @typedef {Object} SkillEntry */
  15. /** @type {SkillEntry[]} */
  16. export const INVENTORY = [
  17. // ============================================================
  18. // 系统层 / Infrastructure
  19. // ============================================================
  20. {
  21. name: 'skill-heterarchy',
  22. displayName: '内异层认知协同',
  23. tier: 'system',
  24. summary: '单一 Agent 主体内部多心智分化与自治协商。Delegate 是对外派活,Heterarchy 是对内分思。',
  25. platforms: ['gogs', 'github', 'npm', 'skillhub'],
  26. npmName: 'skill-heterarchy',
  27. skillhubSlug: 'fmode-skill-heterarchy',
  28. status: 'published',
  29. tags: ['heterarchy', 'cognitive-collaboration', 'hermes', 'claude-code', 'dispatch', 'paradigm'],
  30. },
  31. {
  32. name: 'skill-multi-branch',
  33. displayName: '多任务工作框架',
  34. tier: 'system',
  35. summary:
  36. 'Hermes 负责沟通、专业任务派发执行层(Claude Code/Codex/Agent profile)。任务书落盘协议、四态状态上报、中断续跑、执行层纪律,内置 dispatch.sh 标准派发器。',
  37. platforms: ['gogs', 'github'],
  38. status: 'published',
  39. tags: ['dispatch', 'multi-task', 'hermes', 'claude-code', 'workflow'],
  40. },
  41. {
  42. name: 'skill-bypass-permission',
  43. displayName: 'YOLO 模式体检器',
  44. tier: 'system',
  45. summary:
  46. '校验并幂等修复 Agent 免确认自主执行配置(Hermes approvals.mode=off/yolo、Claude Code skip-permissions),改前自动备份,已合规则一行 OK 静默通过。',
  47. platforms: ['gogs', 'github'],
  48. status: 'published',
  49. tags: ['permission', 'yolo', 'self-check', 'idempotent', 'hermes'],
  50. },
  51. {
  52. name: 'skill-task-progress',
  53. displayName: '任务进度与成果上报',
  54. tier: 'system',
  55. summary:
  56. 'Agent 干活进度与成果交付实时进 FmodeAgent 平台(App 四 Tab/看板可见)。init-tables 幂等建三表;progress 四态上报(ack→running→done/failed+30s 心跳);deliver 交付链接入库。',
  57. platforms: ['gogs', 'github'],
  58. status: 'published',
  59. tags: ['progress', 'reporting', 'parse', 'dashboard', 'heartbeat'],
  60. },
  61. {
  62. name: 'plugin-wecom-fix',
  63. displayName: '企微通道自检修复',
  64. tier: 'system',
  65. summary:
  66. '修复官方 wecom 插件四项接收缺陷:大视频收不到、合并转发不识别、批量图片丢失、长文件名 Errno 36。幂等 patch.py(--check/--apply/--rollback)。',
  67. platforms: ['gogs', 'github'],
  68. status: 'published',
  69. kind: 'plugin',
  70. tags: ['wecom', 'plugin', 'patch', 'idempotent', 'channel-fix'],
  71. },
  72. {
  73. name: 'skill-agent-clone',
  74. displayName: '数字生命克隆',
  75. tier: 'system',
  76. summary:
  77. '把本地 Hermes 配置、SOUL、技能、记忆、会话记录按 L1-L4 重要程度分级同步到个人 Git 仓库,增量 push、一键恢复。密钥只记位置索引不入仓。',
  78. platforms: ['gogs', 'github'],
  79. status: 'published',
  80. tags: ['clone', 'backup', 'soul', 'memory', 'migration', 'disaster-recovery'],
  81. },
  82. // ============================================================
  83. // 服务层 / Platform Services
  84. // ============================================================
  85. {
  86. name: 'skill-storage',
  87. displayName: '对象存储与公开分享',
  88. tier: 'service',
  89. summary:
  90. '二进制大文件(图/音/视频/HTML 报告)上传对象存储(OBS/S3),本地零长期占用,上传即得公开分享链接。诚实 4 级凭据链。',
  91. platforms: ['gogs', 'github'],
  92. status: 'published',
  93. version: '0.3.0',
  94. tags: ['storage', 'obs', 's3', 'cdn', 'share-link', 'upload'],
  95. },
  96. {
  97. name: 'skill-image',
  98. displayName: 'Fmode 图像生成',
  99. tier: 'service',
  100. summary: 'Fmode API 图像生成,白底 PNG 场景图,约 ¥0.3-0.5/张。7 种模式(--app/--arch/--explode/--product/--scene/--slide)。',
  101. platforms: ['github', 'npm'],
  102. npmName: 'fmode-image',
  103. npmVersion: '0.2.0',
  104. status: 'published',
  105. tags: ['image', 'generation', 'ai', 'diagram', 'scene', 'product'],
  106. },
  107. {
  108. name: 'skill-vision',
  109. displayName: '视觉识别',
  110. tier: 'service',
  111. summary:
  112. '图片/视频结构化视觉分析。宿主多模态模型优先(零额外成本),否则回落 Fmode API 的 glm-5.3-flash;支持单轮/多轮聚焦分析与结构化 JSON 输出。',
  113. platforms: ['github', 'npm'],
  114. npmName: 'fmode-vision',
  115. npmVersion: '0.1.1',
  116. status: 'published',
  117. tags: ['vision', 'multimodal', 'image-analysis', 'video-frames'],
  118. },
  119. {
  120. name: 'skill-listen',
  121. displayName: '录音转写',
  122. tier: 'service',
  123. summary:
  124. '录音/视频音轨转文字(讯飞 LFASR × Fmode 网关 /api/listen/transcribe)。中英多语种+方言、说话人分离、服务端按音频时长计费、讯飞凭据零下放。',
  125. platforms: ['gogs', 'github', 'npm'],
  126. npmName: 'fmode-listen',
  127. npmVersion: '0.1.2',
  128. status: 'published',
  129. tags: ['asr', 'transcribe', 'iflytek', 'lfasr', 'speaker-diarization'],
  130. },
  131. {
  132. name: 'fmode-ffmpeg',
  133. displayName: 'FFmpeg 音视频处理',
  134. tier: 'service',
  135. summary: 'FFmpeg 音视频处理封装:抽音轨、转码、切片、截图。',
  136. platforms: ['npm'],
  137. npmName: 'fmode-ffmpeg',
  138. npmVersion: '0.1.1',
  139. status: 'published',
  140. tags: ['ffmpeg', 'audio', 'video', 'transcode', 'extract'],
  141. },
  142. {
  143. name: 'fmode-qiwei',
  144. displayName: '企微网关 SDK',
  145. tier: 'service',
  146. summary: '企业微信网关 SDK:消息收发、通讯录、应用管理封装。',
  147. platforms: ['npm'],
  148. npmName: 'fmode-qiwei',
  149. npmVersion: '0.5.2',
  150. status: 'published',
  151. tags: ['wecom', 'qiwei', 'sdk', 'gateway', 'messaging'],
  152. },
  153. // ============================================================
  154. // 应用层 / Business Applications
  155. // ============================================================
  156. {
  157. name: 'skill-study-report',
  158. displayName: '学习复盘报告',
  159. tier: 'application',
  160. summary:
  161. '一键生成学员 48h 学习复盘报告 PPT:多 Agent 采集工作痕迹 → 三问追问 → PPT 级 HTML(≥10 屏)→ Storage 主 + Gogs 降级双通道发布 + ZIP 分发。',
  162. platforms: ['gogs', 'github'],
  163. status: 'published',
  164. tags: ['report', 'review', 'ppt', 'html', 'multi-agent', 'education'],
  165. },
  166. {
  167. name: 'skill-present',
  168. displayName: 'HTML 演讲系统',
  169. tier: 'application',
  170. summary: '课程课件/报告 HTML 演讲系统,含 43 条 Claude 规则,数字动画与交付物墙 iframe 嵌套。',
  171. platforms: ['gogs'],
  172. status: 'published',
  173. tags: ['presentation', 'html', 'slides', 'deck', 'courseware'],
  174. },
  175. {
  176. name: 'fmode-product-lab',
  177. displayName: '新品研发实验室',
  178. tier: 'application',
  179. summary: '新品研发全流程:VOC 采集 + KANO 模型 + 市场分析 + 定位分析。',
  180. platforms: ['npm'],
  181. npmName: 'fmode-product-lab',
  182. npmVersion: '0.2.0',
  183. status: 'published',
  184. tags: ['product', 'voc', 'kano', 'market-analysis', 'positioning'],
  185. },
  186. // ============================================================
  187. // 母技能自身
  188. // ============================================================
  189. {
  190. name: 'skill-core-guide',
  191. displayName: 'Harness 平台母技能标准指南',
  192. tier: 'system',
  193. summary:
  194. 'Fmode Harness 平台技能开发规范母技能:平台真值表、ESM-first 四端标准、四渠道分发、六项自动质检、一键凭证供给、新技能脚手架。',
  195. platforms: ['gogs', 'github', 'npm', 'skillhub'],
  196. npmName: 'skill-core-guide',
  197. skillhubSlug: 'fmode-skill-core-guide',
  198. status: 'published',
  199. isMeta: true,
  200. tags: ['meta', 'standard', 'spec', 'harness', 'scaffold', 'quality-check'],
  201. },
  202. ];
  203. /** 按分层分组 */
  204. export function byTier() {
  205. const out = {};
  206. for (const key of Object.keys(TIERS)) out[key] = [];
  207. for (const s of INVENTORY) {
  208. if (!out[s.tier]) out[s.tier] = [];
  209. out[s.tier].push(s);
  210. }
  211. return out;
  212. }
  213. /** 按渠道筛选 */
  214. export function byPlatform(platform) {
  215. return INVENTORY.filter((s) => s.platforms.includes(platform));
  216. }
  217. /** 统计 */
  218. export function stats() {
  219. const out = { total: INVENTORY.length, byTier: {}, byPlatform: {} };
  220. for (const key of Object.keys(TIERS)) out.byTier[key] = 0;
  221. for (const s of INVENTORY) {
  222. out.byTier[s.tier] = (out.byTier[s.tier] || 0) + 1;
  223. for (const p of s.platforms) out.byPlatform[p] = (out.byPlatform[p] || 0) + 1;
  224. }
  225. return out;
  226. }
  227. export default INVENTORY;