Claude Code 上游变更检查
check-upstream
刷新 Claude Code 文档基线,运行一致性检查,并推荐 schema 与规则更新。当用户要求"检查上游变更"、"检查 schema 漂移"、"我们的 schema 是否最新"或"Claude Code 有什么新变化"时使用。
- License 许可
- MIT
- 最近更新
- 2026-11-14
- Stars
- ★ 15
- Forks
- 4
01 前言 Front Matter
- name
- check-upstream
- description
- Refreshes the Claude Code docs baseline, runs the conformance check, and recommends schema and rule updates. Use when asked to "check for upstream changes", "check schema drift", "are our schemas up to date", or "what is new in Claude Code".
02 资源文件 1
- 参考文档CHANGELOG.md573 B
03 SKILL.md 正文
Check Upstream
Detects new Claude Code documentation surface and drift between the official docs and claudelint's schemas, then recommends concrete updates.
The deterministic half of this system runs in CI. This skill adds the judgment the scripts deliberately do not attempt: reading the prose diff and deciding what it means for claudelint.
Usage
Run this skill when asked to check for upstream changes, verify schemas are up to date, or find out what changed in Claude Code's documentation.
Step 1: Refresh the baseline
Run npm run upstream:refresh.
Watch for two things in the output:
[NEW PAGE] <slug> (NOT WATCHED ...)- a docs page appeared that claudelint does not watch. This is how a whole feature (such as plugin dependencies) arrives. Read the page and decide whether it belongs insrc/upstream/watchlist.ts.Extractor guard tripped- the extractor stopped finding facts on a page. Upstream changed format. Fix the extractor in scripts/upstream/extract.ts. Do NOT lowerminFactsto make it pass; that disables the detector.
Step 2: Read the prose diff
Run git diff -- docs-baseline/.
This step is not optional, and it is not a skim. The refresh detects new pages and changed facts. The offline checks cover hook events, tool names, scoped schema field tables, and documented examples. They cannot establish constraints stated only in prose, and that class of change causes real bugs: the mintlify-docs install failure came from one sentence, "a bare string with only the plugin name".
So read the diff for both - changed fields and changed sentences. For each meaningful change, ask: does claudelint model this? Could a user violate it and have us report success?
Step 3: Run the conformance check
Run npm run check:upstream, build the CLI, then run
npm test -- --runInBand tests/upstream and npm run check:schema-docs-coverage.
check:upstream covers hook events. The upstream tests also check tool names, schema
keys, nested settings paths, field examples without silent stripping, and complete
examples through the CLI. Scoped table bindings and extraction floors fail when the
document layout changes. These checks supplement the prose review in Step 2; they
do not establish complete semantic conformance.
documented-not-modeled- upstream documents a hook event we do not model. Add it to the Zod schema, the manual schema inschemas/, and the website docs, then runnpm run check:schema-sync.modeled-not-documented- we model a hook event the docs do not document. Treat this as a probable hallucination. Verify against the official page before assuming it is real. If it is a deliberate claudelint extension, add it tosrc/upstream/extensions.tswith a reason. Never silence it by deleting the check.
Step 4: Report
Summarize: new pages, conformance findings, prose constraints worth a new rule, and a recommended action for each. Do not change schemas without saying what you are changing and why.
Important
- Never add a schema field that is not in the official docs. A previous session
hallucinated five skill frontmatter fields.
src/upstream/extensions.tsplus themodeled-not-documentedcheck exist to make that mistake mechanically visible. - Accepting a baseline refresh is a deliberate act: review
git diff -- docs-baseline/before committing it.
See also
docs/projects/upstream-watch.md- design and rationalesrc/upstream/watchlist.ts- watched pages and their minFacts guardsnpm run check:upstream- the offline conformance gate, also run on every PR
04 同仓库更多 Skills
技能校验测试样例
test-skill
一个有效的测试技能,用于测试目的。当你想测试技能校验时使用此技能。
缺失版本字段测试技能
no-version-skill
本技能缺少 version 字段,用于测试目的。
危险命令安全测试
dangerous-skill
本技能包含用于测试安全校验的危险命令。
完整测试套件运行
example-skill
用于运行项目的完整测试套件。
Firebase 项目部署
advanced-skill
使用 Firebase 工具和 MCP 集成来部署项目。
错误名称
WRONG_NAME
我来做。