docs-sync

A pull-request documentation review process for the microsoft/apm project. A pull request is a proposed code change shared for review before it is merged.

In plain words
What is it for?
Use it whenever a pull request is opened, reopened, or updated to classify documentation impact and produce one advisory comment with suggested changes.
Why use it?
It detects when documentation may become inaccurate after a code change, including changes whose authors did not mention documentation.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/microsoft/apm/docs-sync
Any agent
npx skills add microsoft/apm --skill docs-sync
Clone the repo
git clone --depth 1 https://github.com/microsoft/apm

Made for: Claude Code, Codex.

Per session 150 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,700 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00150 $0.02700
Opus 5 $0.00075 $0.01350
Sonnet 5 $0.00030 $0.00540
Haiku 4.5 $0.00015 $0.00270

Measured yesterday against content hash 2214d7ce6770, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

docs-sync scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.agents/skills/docs-sync/SKILL.md · 239 lines

How it starts

The opening of the file, as written. The whole thing — 239 lines — stays where its author put it; the contents beside it link to each section on GitHub.

docs-sync -- per-PR documentation impact panel

The docs corpus drifts silently and constantly. This skill catches drift at PR-open time, classifies its impact, and orchestrates a persona panel to produce a patch-ready advisory comment.

The pattern is A1 PANEL + B1 FAN-OUT/SYNTHESIZER + A8 ALIGNMENT LOOP. The classifier is the cost gate (~70% of PRs short-circuit to no-change with ~1 LLM call). When the panel does fan out, every agent reads a bounded context (~10 KB) -- never the full corpus.

This skill is ADVISORY. It does not gate merge, apply verdict labels, or push to the contributor's fork. The orchestrator is the sole writer to the PR: exactly one comment per run (idempotent edit-in-place), plus optional label sweeps.

Architecture invariants

  • Cost ceiling: 15 LLM calls per run. Hard-wired. The orchestrator refuses to spawn beyond. Header prints N/15 for observability.
  • Single-writer interlock. Only the orchestrator writes. Panelist subagents return JSON; they MUST NOT call any gh write command, post comments, or touch PR state.
  • Idempotent comment. Exactly one comment per run, with a stable header ## Docs sync advisory. Re-runs edit-in-place using gh pr comment --edit-last.
  • No fork-write. Companion docs PRs (only on structural verdict with docs-sync-confirm label) open from a bot branch in the BASE repo; never pushed to the contributor's fork.
  • Index-not-corpus reads. Every classifier and architect agent reads .apm/docs-index.yml, NOT the corpus itself. The corpus is sampled only by the localizer (which reads the specific candidate pages) and by per-page panelists (which read one page each).
  • S7 deterministic tool bridge. The python-architect panelist MUST run real apm --help, grep, and python -c commands to verify doc claims, never assert from prose.

Roster

Role Agent Always active?
Classifier doc-analyser inside docs-impact-classifier Yes (every run)
Localizer docs-impact-localizer Only on in_place verdict
Architect docs-impact-architect Only on structural verdict
Writer doc-writer Per candidate page (fan-out)
Verifier python-architect Per candidate page (fan-out, S7)
Editorial editorial-owner Once across all redrafts
Growth oss-growth-hacker Once across all redrafts
Synthesizer cdo Once, with ALIGNMENT LOOP up to 3 redrafts

Read the full file on GitHub · 239 lines

Files

What ships with it

6 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 239 lines · 150 tokens per session scan A 2214d7ce6770

Subscribe to this mod's changes

docs-sync is a skill published in the GitHub repository microsoft/apm (3,668 stars, last pushed yesterday), licensed MIT. It adds 150 tokens to every session and 2,700 once invoked, about $0.0007 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

review

Review a proposed change before applying it.

narumiruna/aru · 10 tokens

create-skill-sample

This skill should be used when the user asks to "create a new skill sample", "add a skill", "scaffold a new skill", "contribute a skill", "create a GitHub Copilot skill", "build a custom skill", or needs to create a new GitHub Copilot custom skill sample with proper folder structure, SKILL.md, README, and sample.json…

pnp/copilot-prompts · 102 tokens

create-system-prompt

This skill should be used when the user asks to "create an agent instruction", "add agent instructions", "scaffold an agent sample", "create a system prompt sample", "add a system prompt", "create a new agent", "build an agent", or needs to create a new agent instruction sample with proper folder structure, README…

pnp/copilot-prompts · 99 tokens

mcp-server-review

Review a Model Context Protocol (MCP) server implementation against the 2026-07-28 protocol revision, which removed the initialize handshake and Mcp-Session-Id and made the protocol stateless. Use when the user asks to review, audit, upgrade or migrate an MCP server, asks whether their MCP server is spec compliant…

pnp/copilot-prompts · 93 tokens

code-review-csharp

Perform structured code reviews of C# source code covering naming conventions, performance, security, readability, and .NET best practices. Trigger phrases include "review this C# code", "check my C# for best practices", "analyze this C# class", "find issues in my C# code".

pnp/copilot-prompts · 66 tokens

prompt-of-the-week

Generates a weekly PowerPoint slide from a PnP copilot-prompts GitHub sample URL (for example, samples/agent-instructions/creator-agent), derives the correct weekly title from the sample folder, and produces a styled .pptx file that matches the Prompt-K template layout.

pnp/copilot-prompts · 64 tokens