Migration to autoupdated-anthropic-documentation-knowledge
May 18, 2026 · View on GitHub
Status: Phase 1 complete (working state, commit ready). Phases 2–5 pending. Session checkpoint: 2026-05-17, all 8 verify:all gates green under new layout.
Goal
One repo, shared pipeline, 7 distinct skill payloads covering the
whole Anthropic doc surface (everything with a real llms.txt):
| # | Skill | Source / scope | Pages | State |
|---|---|---|---|---|
| 1 | claude-code | code.claude.com/* excluding agent-sdk/ | ~103 | ✅ migrated to skills/claude-code/ |
| 2 | claude-agent-sdk | code.claude.com/agent-sdk/* + npm + PyPI | 29 + per-lang | ⏳ to migrate from predecessor (Phase 3) |
| 3 | anthropic-api | platform.claude.com/docs/en/api/{messages,admin,compliance,beta,models}/* | ~192 | ⏳ scaffold (Phase 4) |
| 4 | anthropic-platform-features | platform.claude.com/docs/en/{agents-and-tools,build-with-claude,manage-claude,managed-agents}/* | ~105 | ⏳ scaffold (Phase 4) |
| 5 | claude-connectors | claude.com/docs/{connectors,skills,plugins}/* (incl. Claude Desktop MCPB, MCP Apps design) | ~34 | ⏳ scaffold (Phase 4) |
| 6 | claude-cowork | claude.com/docs/{cowork,office-agents}/* | ~35 | ⏳ scaffold (Phase 4) |
| 7 | mcp-spec | modelcontextprotocol.io/* + spec repo | 116 | ⏳ scaffold (Phase 4) |
Excluded (deliberately):
platform.claude.com/api/{typescript,python,...}/*— 8 × 123 = 984 auto-gen pages. Better via IDE type defs.www.anthropic.com/{news,research}— different content shape.support.claude.comZendesk — low signal.claude.com/llms.txtitself — marketing.
Current directory state (after Phase 1)
autoupdated-anthropic-documentation-knowledge/ ← logical name; local dir still autoupdated-anthropic-documentation-knowledge
├── pipeline/
│ ├── agent/ ✅ moved (TS agents, prompts, monitor.sh, verify.sh, sanitiser, package.json)
│ │ ├── update-agent.ts ✅ parameterised by SKILL_NAME env
│ │ ├── research-agent.ts ✅ parameterised
│ │ ├── mending-agent.ts ✅ parameterised
│ │ ├── report-agent.ts ✅ parameterised
│ │ ├── monitor.sh 🚧 NOT YET parameterised — still single-skill assumptions inline
│ │ ├── verify.sh ✅ parameterised (reads SKILL_NAME, scopes to skills/<name>/, reads config.json)
│ │ ├── lib/sanitize.ts + test ✅ unchanged, universal
│ │ ├── system-prompt.md 🚧 still claude-code-specific (lists SKILL-settings.md etc.). Genericise in Phase 3.
│ │ ├── research-prompt.md 🚧 same
│ │ ├── mending-prompt.md 🚧 same
│ │ ├── report-prompt.md 🚧 same
│ │ ├── package.json + lockfile ✅ moved
│ │ └── tsconfig.json ✅ moved
│ ├── scripts/ ✅ moved + parameterised
│ │ ├── validate-examples.sh ✅ reads SKILL_NAME, schemas from skills/<name>/config.json
│ │ ├── typecheck-templates.sh ✅ scopes to skills/<name>/templates/
│ │ ├── check-populated.sh ✅ scopes to skills/<name>/
│ │ ├── check-diff-size.sh ✅ TARGETS built from config.json
│ │ ├── check-docs-drift.sh ✅ docsIndexUrl from config; per-skill snapshot
│ │ ├── refresh-docs-snapshot.sh ✅ per-skill, host-derived snapshot dir
│ │ ├── check-sanitizer-parity.sh ✅ paths updated (pipeline/agent + pipeline/scripts)
│ │ └── check-gate-parity.sh ✅ paths updated; workflow path now .github/workflows/daily.yml (with cc-update-check.yml fallback)
│ └── schema/ ✅ moved (settings, mcp, plugin, hook-input)
├── skills/
│ └── claude-code/ ✅ all content moved here
│ ├── config.json ✅ NEW — upstream + dispatch + schemas
│ ├── SKILL.md + SKILL-*.md ✅
│ ├── rules/*.md ✅
│ ├── templates/ ✅
│ ├── docs-snapshot/ ✅ 132 pages preserved
│ ├── state.json ✅
│ ├── README.md ✅ (was repo-root README)
│ └── CHANGELOG.md ✅ (was repo-root CHANGELOG with full audit-fix history)
├── README.md ✅ NEW — describes the multi-skill repo
├── CHANGELOG.md ✅ NEW — repo-level history (per-skill history in skills/<name>/CHANGELOG.md)
├── LICENSE ✅ unchanged
├── package.json + lockfile ✅ scripts updated to pipeline/scripts/* paths; renamed to autoupdated-anthropic-documentation-knowledge
├── .claude-plugin/plugin.json ✅ renamed to autoupdated-anthropic-documentation-knowledge
├── .gitignore ✅ unchanged
├── .github/
│ ├── workflows/
│ │ ├── cc-update-check.yml 🚧 still single-skill; rewrite to daily.yml matrix in Phase 2
│ │ └── weekly-deep-drift.yml 🚧 still single-skill paths
│ └── PULL_REQUEST_TEMPLATE/ ✅ unchanged
├── dev-docs/
│ ├── scaffold-design.md ✅ unchanged (historical)
│ └── multi-skill-migration.md ✅ this file
└── .claude/ ✅ unchanged (project-local settings)
Verification: Phase 1 working state
$ SKILL_NAME=claude-code npm run verify:all
✅ verify:examples PASS 1 4/4 schema-bound blocks; PASS 2 30/30 keys in snapshot
✅ verify:templates 9/9 templates pass
✅ verify:populated scaffold mode — skips
✅ verify:diff-size within 20% per-file
✅ verify:docs-drift index hash matches upstream
✅ verify:sanitizer-parity 3 bash sanitisers identical
✅ verify:gate-parity 9-gate canonical set across workflow/TS/prompt
✅ verify:agent-tests 14/14 sanitiser assertions
All 8 gates green. Backward-compat: SKILL_NAME defaults to claude-code so existing local invocations work unchanged.
Phases 2–5: continuation plan
Phase 2 — Workflow matrix fan-out
Goal: Rewrite .github/workflows/cc-update-check.yml to matrix-iterate over skills/*. End of phase: workflow still only has claude-code in matrix, but the structure supports fan-out.
Files to edit:
- Rename
.github/workflows/cc-update-check.yml→.github/workflows/daily.yml(matches the newcheck-gate-parity.shlookup) - Restructure into one
daily-runjob withstrategy.matrix.skill: [claude-code]— each matrix entry setsSKILL_NAMEenv - Update
working-directoryreferences:agent/→pipeline/agent/ - Update
npm installpaths:agent/→pipeline/agent/; rootnpm installstays - Update all script-call paths:
bash scripts/*.sh→bash pipeline/scripts/*.sh - Update commit step: per-matrix-entry commit message including skill name; PR branch name includes skill name to prevent collision
- Update README sed step: now targets
skills/<SKILL_NAME>/README.md, not repo-root - Update the weekly-deep-drift workflow similarly: matrix over skills, run
bash pipeline/scripts/check-docs-drift.sh --deep
Risk: workflow YAML is long; matrix-rewrite is non-trivial. Test by running yamllint + python3 -c "import yaml; yaml.safe_load(open('...'))".
Phase 3 — Migrate predecessor into skills/claude-agent-sdk/
Source: /Users/joker/github/xiaolai/myprojects/claude-agent-sdk-skill-autoupdated/
Steps:
cp -rpredecessor'sSKILL.md,SKILL-typescript.md,SKILL-python.md,rules/,templates/intoskills/claude-agent-sdk/- Write
skills/claude-agent-sdk/config.json:{ "name": "claude-agent-sdk", "displayName": "Claude Agent SDK (TypeScript + Python)", "upstream": { "docsIndexUrl": "https://code.claude.com/llms.txt", "docsPathFilter": "agent-sdk/", "npmPackages": ["@anthropic-ai/claude-agent-sdk"], "pypiPackages": ["claude-agent-sdk"], "githubRepos": ["anthropics/claude-agent-sdk-typescript", "anthropics/claude-agent-sdk-python"], "bugTrackerRepo": "anthropics/claude-agent-sdk-typescript" }, "router": "SKILL.md", "surfaces": ["SKILL-typescript.md", "SKILL-python.md"], "rules": ["rules/claude-agent-sdk-ts.md", "rules/claude-agent-sdk-py.md"], "dispatch": { "...per-page mapping from agent-sdk docs to TS or Py surface..." }, "schemas": {} } - Write
skills/claude-agent-sdk/README.md(per-skill story — adapt predecessor's README) - Write
skills/claude-agent-sdk/CHANGELOG.md(preserve predecessor's history; add migration entry) - Bootstrap docs-snapshot:
SKILL_NAME=claude-agent-sdk bash pipeline/scripts/refresh-docs-snapshot.sh(fetches 29 agent-sdk pages from code.claude.com) - Add
claude-agent-sdkto workflow matrix - Genericise the 4 system prompts (or move to per-skill
skills/<name>/prompts/): the prompts currently hardcode the claude-code surface file list. Two paths:- Per-skill prompts:
skills/<name>/prompts/system.mdetc., loaded by agents based on SKILL_NAME - Generic prompts + config-driven user message: prompts say "follow the dispatch table in your config.json"; user message built from config
- Per-skill prompts:
Recommendation: Per-skill prompts. Lower-risk than fully generic; preserves the deep, specific guidance each skill needs. Move prompts to skills/<name>/prompts/ and update TS agents to load resolve(SKILL_ROOT, "prompts", "<name>.md").
-
monitor.shneeds significant expansion: currently single npm package + single GH repo. Predecessor needs npm + PyPI + 2 GH repos. Generalise to iterate over arrays from config.json. -
Predecessor repo's eventual fate: add deprecation banner to its README pointing here. Out of this work's scope.
Phase 4 — Scaffold 5 new skills
For each of: anthropic-api, anthropic-platform-features, claude-connectors, claude-cowork, mcp-spec:
mkdir skills/<name>/{rules,templates}- Write
skills/<name>/config.jsonwith upstream + dispatch + schemas - Write
skills/<name>/SKILL.mdrouter with dispatch table - Write
skills/<name>/SKILL-<surface>.mdstubs for each topic cluster (based on the cluster analysis in this doc — see "Sources / scope" column) - Write
skills/<name>/rules/*.mdif any (some skills won't have rules — e.g., mcp-spec is reference-only) - Write
skills/<name>/README.md+CHANGELOG.md - Bootstrap docs-snapshot:
SKILL_NAME=<name> bash pipeline/scripts/refresh-docs-snapshot.sh - Initial
skills/<name>/state.json(scaffoldComplete: false) - Add
<name>to workflow matrix
Per-skill structure suggestions (from earlier analysis):
anthropic-api (192 pages):
- Router + surfaces:
SKILL-messages.md(9 pages),SKILL-admin.md(37),SKILL-compliance.md(37),SKILL-beta.md(107),SKILL-models.md(2) - Schemas: write
pipeline/schema/messages-request.schema.json(Messages API request body schema) - Rules: per-endpoint usage rules
anthropic-platform-features (105 pages):
- Router + surfaces:
SKILL-agents-and-tools.md,SKILL-build-with-claude.md,SKILL-manage-claude.md,SKILL-managed-agents.md - Sub-clusters: agent-skills, mcp-connector, tool-use under agents-and-tools
claude-connectors (34 pages — incl. Desktop + Design):
- Router + surfaces:
SKILL-connectors-overview.md,SKILL-connectors-building.md,SKILL-mcp-apps.md(incl. design guidelines + Desktop MCPB),SKILL-claude-skills.md,SKILL-claude-plugins.md
claude-cowork (35 pages):
- Router + surfaces:
SKILL-cowork.md(24 pages cowork/3p),SKILL-office-agents.md(11 pages)
mcp-spec (116 pages):
- Router + surfaces: split by topic —
SKILL-clients.md,SKILL-servers.md,SKILL-transport.md,SKILL-protocol.md,SKILL-tools.md,SKILL-resources.md, etc. (TBD after inspecting upstream) - Track packages:
@modelcontextprotocol/sdk(npm),mcp(PyPI) - Track repos:
modelcontextprotocol/modelcontextprotocol,modelcontextprotocol/typescript-sdk,modelcontextprotocol/python-sdk
Phase 5 — Multi-skill verification + commit
- Run
SKILL_NAME=<each> npm run verify:allfor every skill, confirm exit 0 - Run
bash pipeline/scripts/check-docs-drift.sh --deepfor each skill (one-time deep verification of fresh snapshots) - Update root
README.mdwith current skill matrix + statuses - Update root
CHANGELOG.mdwith the full multi-skill rollout entry - Commit (suggested: one commit per phase for clean history, or one big-bang commit if reviewing as a unit)
- Bump
package.jsonversion from 0.2.0 → 1.0.0 to mark the multi-skill release
What's NOT done in Phase 1 (Pre-existing, needs Phase 3+ work)
pipeline/agent/monitor.shis NOT yet skill-aware (still has single-source assumptions baked in)pipeline/agent/system-prompt.mdand the 3 sibling prompts still list claude-code-specific files.github/workflows/cc-update-check.ymlstill references old paths (works only because Phase 1 made claude-code the default; doesn't fan out)- The 6 unbuilt skills don't exist yet
Open questions for next session
- Per-skill prompts vs generic + config-driven? Recommend per-skill (Phase 3 design decision).
- MCP spec skill: how to track upstream? The repo
modelcontextprotocol/modelcontextprotocolis the spec; the SDK repos are reference impls. Each has its own release cadence. Probably need 3 GitHub repo trackings + 2 package trackings inmonitor.sh. - Anthropic API skill: include or exclude the 984 auto-gen per-language SDK pages? Recommend exclude (already in dev memo).
- Workflow matrix: parallel or sequential? Parallel runs ~7× faster but burns 7× concurrent Max-20x quota. Sequential is slower but uses one-at-a-time quota. Start sequential; parallelise once first run lands.
Continuation handoff
Pick up at Phase 2 by:
- Reading this file
- Renaming the workflow to
daily.ymland converting to matrix - Smoke testing the workflow YAML locally (
yamllint+ path checks) - Continuing through Phase 3 → 4 → 5 as outlined above
All Phase 1 work is committed and npm run verify:all is the canary — if you break it, you'll know immediately.