快速判断代码变更对文档的影响级别,决定是否需要同步更新文档
该技能材料显示为纯提示/流程说明型、开源且未声明密钥或远程端点,整体风险较低。主要需留意其来源仓库社区采用度低、维护状态未知且许可证未声明,供应链透明度一般。
材料明确标注“无”密钥/环境变量;README 也未要求 API token、云凭证或第三方账户授权,未见明显凭证泄露或滥用面。
声明无远程端点,文档描述主要围绕 PR diff、`.apm/docs-index.yml` 与本地文本检索;未见将用户数据发送到外部服务或不相关域名的证据。
系统检查项已标注为 prompt-only;当前审计对象看起来是技能说明而非可执行二进制/脚本。虽文档提及 `gh pr diff`、`grep` 等命令作为流程步骤,但材料本身未提供可执行负载或额外系统权限申请。
描述中仅涉及读取 PR diff、变更文件列表及仓库内 `.apm/docs-index.yml`/文档路径等与声明功能直接相关的数据;未见写入、广泛扫描主机数据或越权访问无关资源的迹象。
来源为 GitHub 上的开源仓库(microsoft/apm),源码可审计,这是明显的降风险因素;但当前给出的社区采用度为 0 star、维护状态未知、许可证未声明,供应链成熟度与后续维护可信度仍需留意。
复制安装指令,让 AI 自动完成配置 · 推荐新手
请帮我安装 askskill 上的 "docs-impact-classifier" 技能: 1. 下载 https://raw.githubusercontent.com/microsoft/apm/main/.apm/skills/docs-impact-classifier/SKILL.md 2. 保存为 ~/.claude/skills/docs-impact-classifier/SKILL.md 3. 装好后重载技能,告诉我可以用了
请根据这个 pull request diff 判断文档影响级别,只返回 no-change、in-place edit 或 structural change,并简要说明原因。不要读取完整文档语料,只参考 .apm/docs-index.yml 作为文档映射。
返回文档影响结论及简短理由,用于决定是否继续执行文档同步流程。
你是 docs-impact-classifier。先分析这份 diff 对文档的影响,再输出 verdict 和 reason。如果是 no-change,明确说明无需启动后续文档面板或同步任务。
给出可供编排器直接使用的分流结果,帮助在无需改文档时节省模型调用成本。
查看以下代码改动是否会引发结构性文档调整,例如新增模块、重命名主要接口或改变信息架构。请在 no-change、in-place edit、structural change 中选择,并说明依据。
输出是否属于结构性文档变更的判断,帮助团队安排对应范围的文档更新工作。
Single responsibility: given a PR diff and the .apm/docs-index.yml
corpus map, emit ONE classification verdict.
This skill is the cost gate for the entire docs-sync system. ~70% of
PRs should exit at verdict no_change with zero panel spawn.
This is a 3-layer funnel inside a single skill invocation:
The skill returns the verdict from the earliest layer that can decide.
Read .apm/docs-index.yml to load no_impact_paths[] and
user_surface_paths[]. Get the changed file list from the PR diff
(gh pr diff --name-only).
if every changed file matches no_impact_paths AND none match user_surface_paths:
return {verdict: "no_change", confidence: "high", source: "L0", scope_pages: []}
This handles:
tests/**).github/workflows/**)docs/**) -- out of scope, docs-sync doesn't review docs PRs.apm/**)Expected hit rate: ~70% of PRs short-circuit here.
If L0 did not exit, extract user-observable symbols from the diff:
^@click.command, ^@cli.command, or any apm <verb> mention in added/removed lines.^@click.option, --[a-z-]+ patterns.def <name> in src/apm_cli/__init__.py or src/apm_cli/api/**.apm.yml, apm.lock.yaml, apm-policy.yml parsers._rich_error, click.echo, raise ... Error().For each extracted symbol, consult .apm/docs-index.yml#symbol_index
to find the documented pages. Collect all hits into candidate_pages[].
Also grep -rn <symbol> docs/src/content/docs/ for symbols NOT in
the index (catches drift between index and corpus).
If L1 found zero candidate pages AND zero schema/CLI/flag changes:
return {verdict: "no_change", confidence: "medium", source: "L1", scope_pages: []}.
Otherwise, invoke the doc-analyser persona with EXACTLY this context envelope (must fit in ~8 KB tokens):
gh pr diff --stat output).apm/docs-index.yml (the whole file; it's ~8 KB seeded, may grow)pr_doc_diff_paths[]: the list of paths under docs/src/content/docs/**
that the PR itself already modifies (drives the in_place_resolved
downgrade rule in "In-place-resolved detection" below).Ask doc-analyser to return JSON matching this schema:
{
"verdict": "no_change" | "in_place_resolved" | "in_place" | "structural",
"confidence": "low" | "medium" | "high",
"scope_pages": ["docs/src/content/docs/..."],
"structural_proposal": {
"new_pages": [{"slug": "...", "rationale": "..."}],
"moved_pages": [{"from": "...", "to": "..."}],
"toc_changes": "<one-paragraph>"
},
"reasoning": "<one-paragraph: what surface changed, what docs are affected, why this verdict>"
}
structural_proposal is populated only when verdict is structural.
scope_pages is populated for in_place and structural verdicts.
| Verdict | Meaning | Panel size | Cost |
|---|---|---|---|
no_change | No user-observable surface changed | 0 panel spawns | ~0-1 LLM call |
…
核查回答是否有文档依据,帮助发现未被资料支持的内容与引用问题。
将文档影响判定细化为逐页逐段的同步执行任务清单
帮助团队制定 APM 项目定位、发布沟通与破坏性变更决策策略。
对整套技术文档逐页对照源码审计,并给出精准过时内容修复建议
优化命令行输出、日志与报错文案,提升终端交互可读性与诊断体验
帮助开发团队快速分诊 microsoft/apm 新开或待分诊问题并生成统一处理意见
在每次 PR 变更时评估文档影响,并给出可落地的更新建议。
在文档结构需随 PR 调整时,规划目录变更并生成新页面大纲草案。
对 microsoft/apm 的标记 PR 发起多专家联合审查并给出综合建议
为 microsoft/apm 的拉取请求自动撰写结构完整、证据充分的 PR 描述。
帮助团队持续维护代码仓库文档、进度记录与交接上下文,便于协作开发
引导用户协作撰写文档、方案与技术规格,并通过迭代完善内容质量。