References
发布时间:2026/9/7 3:35:57 作者:尧图编辑部 阅读量:1,286

References【免费下载链接】next.jsThe React Framework项目地址: https://gitcode.com/GitHub_Trending/next/next.jsworkflow.md — prioritization, common failure patterns, resolving review threadslocal-repro.md — mode/env matching and isolation guidance这样 Agent 加载技能入口时先获得全貌再按需要在细节文件中深挖避免一次性把所有诊断细节灌进上下文。 ## SKILL.md 格式frontmatter 字段完整参考 SKILL.md 由 YAML frontmatter 和 Markdown 正文两部分组成。frontmatter 是最小可用形式 yaml --- name: my-skill description: What this skill covers and when to use it. Include key file names, concepts, and trigger phrases so Claude can match user intent to this skill. This is the primary field Claude uses for auto-activation. ---指南同时给出了一张受支持字段表强调只允许使用表内字段未知字段会被 Claude Code 忽略字段必填说明name是技能名用于$name引用和/name斜杠命令description是技能做什么、何时使用。这是 Claude 决定是否自动加载技能的依据需包含文件名、概念和关键词argument-hint否自动补全中期望参数的提示如pr-numberuser-invocable否设为false可从/斜杠命令菜单中隐藏该技能disable-model-invocation否设为true可禁止 Claude 自动触发此技能allowed-tools否该技能激活时无需授权即可使用的工具列表model否该技能专用的模型覆盖context否设为fork表示在隔离子代理中执行agent否配合context: fork使用的子代理类型hooks否作用域限定在该技能生命周期内的钩子在仓库真实技能中可以观察到这些字段的各种组合。authoring-skills 技能 的 frontmatter 同时使用了user-invocable: false和metadata: internal: true表示它只对内部 Agent 维护者有意义、不出现在斜杠菜单中--- name: authoring-skills description: How to create and maintain agent skills in .agents/skills/. Use when creating a new SKILL.md, writing skill descriptions, choosing frontmatter fields, or deciding what content belongs in a skill vs AGENTS.md. user-invocable: false metadata: internal: true ---另一个值得注意的观察多个技能如 flags、pr-status-triage、dce-edge都携带了metadata: internal: true。该字段并未出现在指南的支持字段表中——按照未知字段被忽略的规则它不参与激活逻辑实际是团队用来标记内部工作流技能的约定这提示在遵循指南字段表之外仓库内还存在少量社区性扩展。写好 description自动激活的匹配面指南将description称为the single most important field——Claude 用它决定是否自动加载技能。写 description 要覆盖四要素技能覆盖什么主题the topic何时使用触发场景trigger scenario;技能中引用的关键文件名如config-shared.ts、entry-base.ts用户或 Agent 可能提到的关键概念/关键词如 DCE、feature flag、vendored React。指南给出的正反示例# Bad: too vague, wont match well description: Helps with flags. # Good: specific, includes file names and keywords description: How to add or modify Next.js experimental feature flags end-to-end. Use when editing config-shared.ts, config-schema.ts, define-env-plugin.ts, next-server.ts, export/worker.ts, or module.compiled.js.【免费下载链接】next.jsThe React Framework项目地址: https://gitcode.com/GitHub_Trending/next/next.js创作声明:本文部分内容由AI辅助生成(AIGC),仅供参考