Repository navigation
docs(skills): recommend the per-agent install that lands the bundle once - #16806
Conversation
The catalog front page recommended `--all`, which the skills CLI expands to `--skill '*' --agent '*' -y`. Measured against skills@1.5.23 with this catalog in an empty directory, that writes the bundle to THREE destinations: a full real copy in `.agents/` (46 files) AND in `agent/` (46 files, re-serialized frontmatter, same bodies), plus 11 `.claude/` symlinks into `.agents/`. The per-agent form lands 46 real files in `.claude/` and nothing else. Line 9 now recommends the per-agent form — the same command the scaffolder already runs (`packages/create-objectstack/src/skills-install.ts`), so the front page and the scaffolder no longer disagree. `--all` is retained as an explicitly-labelled multi-runtime opt-in with its three-destination cost stated rather than merely mentioned. The `/skills` subpath is preserved in the one catalog spelling the file carries: it is the boundary that keeps `metadata.internal` skills out, and `packages/create-objectstack/src/template-consistency.test.ts` ratchets it across `skills/**`. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01P58euzUXCVJNwmhuPC9DXY
维护者速读(终稿)席位复核记录:#16768 上的 ACCEPT 评论(skills 席,hotlong,session 改了什么技能包目录首页 为什么改
风险与代价(含回滚)风险低:纯文档,不进任何 npm 包的发布产物(实测:70 个已发布 manifest 无一 席位意见同意合并。席位对照 GitHub 与树逐项核过: dev 留给你的那个取舍——首页只写「两份完整副本 + 一组符号链接」、不写死 46/11——席位意见是对的:那两个数随目录增删漂移、没有门禁读它们,写死就是下一次静默过期;承重的事实(三处、其中两处是实体副本)不漂。带日期的数字留在 PR 正文,合适。 你要做的受管面( 是 Generated by Claude Code |
…lder actually runs (objectstack-ai#17868) Clause-②: no Closes objectstack-ai#16400 ## What was false Four `content/docs/**` pages recommended installing the AI skills bundle with `npx skills add objectstack-ai/objectstack/skills --all`, and **two of them stated that flag as what the scaffolder runs**. That second half was already false in the tree, not about to become false: the scaffolder moved to a single named agent when PR objectstack-ai#16401 landed (2026-09-06T20:36:10Z), so the two getting-started lines described a command `create-objectstack` no longer issues. ## What it actually runs today — re-measured, not cited Read from `packages/create-objectstack/src/skills-install.ts` on this branch's base (`c88fa2ccdc`), by evaluating the constants rather than eyeballing the template literal: ``` SKILLS_INSTALL_COMMAND npx -y skills add objectstack-ai/objectstack/skills --skill '*' --agent claude-code -y skillsInstallHint(default) npx skills add objectstack-ai/objectstack/skills --skill '*' --agent claude-code -y skillsInstallHint('codex') npx skills add objectstack-ai/objectstack/skills --skill '*' --agent codex -y DEFAULT_SKILLS_DIR .claude/skills/ ``` `index.ts:542` passes `SKILLS_INSTALL_COMMAND` to `execSync`, and lines 594-601 print `skillsInstallHint(...)` in the closing summary — so "one agent, one directory, and the command is printed for any other runtime" is the behaviour, not just the constant. A check in the PR: all **7** command literals left in the four pages are compared programmatically against the value that module composes. 0 mismatches. ## Carriers — 4 of the card's 5 surfaces are this PR's The card named five surfaces. Triage split on the landing path, not on the sentence kind: 「拆后本卡的文件面只剩 `content/docs/**`,按车道表归 `domain:devx`」. | surface | kind | state | |:---|:---|:---| | `getting-started/your-first-project.mdx` 45, 286 | states what the scaffolder runs + re-run instruction | fixed here | | `getting-started/build-with-claude-code.mdx` 57, 381 | same pair | fixed here | | `ai/skills-reference.mdx` 27, 30, **33** | manual recommendation + two prose claims | fixed here | | `ai/skills.mdx` 35, **38** | manual recommendation + prose claim | fixed here | | `skills/README.md` 9 | governed surface | not ours — already moved to the per-agent form by PR objectstack-ai#16806, verified absent from this base | The two bolded sites were not on the card's or the skills seat's line list; `skills-reference.mdx:33` and `skills.mdx:38` attribute the bundle-versioning and idempotence properties to `--all` specifically, so leaving them would have kept the flag as the recommended form in prose after the commands changed. ## Fix shape, and why not a pointer The brief asked whether to keep a corrected literal or point at the single source of truth (`skills-install.ts`), as this shift's objectstack-ai#16200 did. Split by reader: - **Where the reader must type the command** (all four pages' install and re-run instructions) the literal stays, corrected. A docs reader cannot resolve a pointer into a TypeScript module in our monorepo — that page is not on the docs site and they cannot run it. Pointing there would remove the fact instead of keeping it true, which is the vague-sentence failure in a different costume. - **Where the reader does not need the value**, the pointer shape is used: `skills-reference.mdx`'s "new projects" paragraph now states the observable properties (one runtime, `.claude/skills/`, once) and points at the live instrument the reader actually holds — *the scaffolder's own closing summary prints the exact command it ran*. That paragraph previously named no command, so this keeps the number of decaying copies at what it was rather than adding an eighth. `--all` is not deleted: it is a real CLI option, and triage's instruction was that the idempotence claim is true and must not be removed. It survives on the reference page as a labelled multi-runtime opt-in that names its cost (three destinations: real copies in both `.agents/` and `agent/`, plus `.claude/` symlinks), with the distinction that makes the idempotence claim useful — re-running is idempotent *per destination*, and it is the destination count that grows. ## Reverse-read *Does anywhere else state the scaffolder's behaviour, and does this diff make any standing sentence false?* - `content/docs/deployment/cli.mdx` 29, 93, 94 — "installs the AI skills bundle + `AGENTS.md`". True, names no command, no decay. **Unchanged.** - `content/docs/getting-started/how-ai-development-works.mdx:45`, `getting-started/index.mdx` 26, 161 — same shape. **Unchanged.** - `getting-started/build-with-claude-code.mdx:70` — a console transcript quoting `→ Installing AI skills for your coding agent...`, byte-equal to `index.ts`'s `printStep`. True. `pnpm check:docs-transcript-drift` measured it green on the final text. **Unchanged.** - `getting-started/build-with-claude-code.mdx:26` (mermaid) and `your-first-project.mdx:272` — "installs the skills bundle", no command. **Unchanged.** - `packages/create-objectstack/README.md:60`, `src/templates/AGENTS.md:82`, `src/templates/blank/README.md:148`, `skills/README.md:9` — all four already carry the per-agent form. This diff agrees with them; none becomes false. - `packages/create-objectstack/src/template-consistency.test.ts:597-602` — "the boundary is the `/skills` SUBPATH, and it did not move when the scaffolder stopped passing `--all`". Directional and historical, still true, and this diff keeps the subpath on every literal. - **Zero** results for: any other `content/docs` page naming a `skills add` command; any test or gate pinning `--all` in the docs (none exists — see the acceptance note below); any generated block containing an install command (`build-skill-docs.ts` emits none; `skills-reference.mdx`'s generated region starts at line 38, below every site edited). One sentence outside this card's file surface **is** made false by this diff, reported rather than fixed: `.github/workflows/scaffold-e2e.yml:229-231` says in a comment "The scaffolder/docs command is `skills add …/objectstack/skills --all`". The scaffolder half was already stale; the docs half becomes stale here. The probe below it deliberately uses `--all --copy` and is correct for its purpose (set-equality against the curated catalog), so only the comment is wrong. Left alone because triage split this card's file surface to `content/docs/**` and editing a workflow would add a verification surface this PR does not otherwise touch. ## 验收备注 - **No gate pins the docs against the scaffolder's command.** Triage flagged building one as a bonus and explicitly told the claiming seat not to expand the PR into `scripts/` for it — so the programmatic literal comparison above was run as a one-off in this PR and is not committed. Noted, not filed: the next surface to state this command has nothing mechanical to catch it, and the docs-drift audit states it structurally cannot see this class. - `docs/qa/platform-checklist/areas/cli.json:384` uses `--all --copy` as a skills-boundary probe. Not a statement of scaffolder behaviour; unaffected. - `.claude/skills/dogfood-verification/SKILL.md:13` notes that the CLI's `--all` implies `--skill '*'`. True CLI semantics, governed surface, untouched. ## Verification Derived with `node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstack` (change set taken by the script from the merge base, not from a hand-written diff): **43 families, 43 run, 0 NOT-MEASURED, 0 UNRUN, all exit 0** — reconciled back through `--ran` with an exit code recorded per family, so the zero is derived rather than claimed. Four of them first refused with `PREREQUISITE NOT MET` (exit 3, not a finding); `@objectstack/lint`, `@objectstack/formula` and `@objectstack/client-react` were built and all four then exited 0. Named readings, all on the final text: ``` pnpm --filter @objectstack/spec check:docs ✅ 222 generated files in sync with packages/spec pnpm check:docs-transcript-drift ✓ 4 declared transcript value(s) across 402 page(s) under content/docs/ equal what the registry derives today pnpm check:doc-authoring ✓ 44 published skill files clean pnpm check:corpus-claim-drift OK, no new claim sites beside a pinned spelling pnpm check:role-word OK, no new occurrences of the reserved word pnpm check:nul-bytes exit 0 ``` Heavy steps ran through `scripts/pm/os-verify-lock.sh` (slot `issue-16400`): `pnpm install` `VERDICT command-exit 0`, `@objectstack/spec build` `VERDICT command-exit 0`, the three-package turbo build `VERDICT command-exit 0`. **`pnpm lint` — a declared narrowing, measured in three parts.** The repo-scoped run is CI's; the reading here is that this diff is outside eslint's population entirely. (1) Population from eslint's own config, not a guess: `new ESLint().isPathIgnored(...)` returns `true` for the changed `.mdx` files. (2) File count from `--format json` over exactly the four changed files: 4 files read, 0 errors, and each of the 4 warnings is `File ignored because no matching configuration was supplied`. (3) Invariance: this repo runs one `eslint.config.mjs` which never enables type-aware linting for any file (`eslint.config.mjs:325-332`; no `parserOptions.project`), so nothing in this diff can move the verdict on a file it does not touch. Union run against final `HEAD` `0612e8bfe8`. **Changeset: skipped, measured.** No package's `files[]` names `content/docs` — checked across every `packages/*/package.json` carrying a `files` array, zero hits. The only consumer of this tree is `apps/docs` (`@objectstack/docs`, `private: true`, no `files`). Positive control: the corrected command string does appear in published surfaces (`packages/create-objectstack/README.md`, `src/templates/AGENTS.md`, `src/templates/blank/README.md`) — none of which this diff touches. Nothing shipped moves, so the `skip-changeset` label is applied rather than a body sentence. **`Clause-②: no`** — the diff is four `.mdx` prose files: no schema key, no closed-set member, no published export, no registry entry. `pnpm check:pm-widening-tells` exit 0. --- _Generated by [Claude Code](https://claude.ai/code/session_012GKcPZbMoGq7WPzKLfRBTU)_ Co-authored-by: Claude <noreply@anthropic.com>
Fixes #16768
skills/README.md:9recommendednpx skills add objectstack-ai/objectstack/skills --all. The skills CLI's own help spells--allas "Shorthand for--skill '*' --agent '*' -y", and the--agent '*'half is what makes a single copy-paste land the bundle three times. Line 9 now recommends the per-agent form — byte-for-byte the commandpackages/create-objectstackalready runs — and--allstays on the page as an explicitly-labelled multi-runtime opt-in whose three-destination cost is stated rather than merely mentioned.The catalog front page and the scaffolder had drifted apart: the scaffolder moved to the per-agent form and recorded why in
packages/create-objectstack/src/skills-install.ts, while the front page kept recommending the form that scaffolder comment exists to warn about.The measurement — re-run in this container, not cited
skills@1.5.23, this catalog (11 skills), two empty directories:npx skills add objectstack-ai/objectstack/skills --all.agents/46 real files (602,278 B) ·agent/46 real files (600,858 B) ·.claude/11 symlinks into.agents/npx skills add objectstack-ai/objectstack/skills --skill '*' --agent claude-code -y.claude/46 real files (602,278 B) — and nothing elseBoth also write
skills-lock.json. The shape reproduces the reading recorded on the card exactly (46 / 46 / 11). The byte totals differ from the ones inskills-install.ts(604,102 / 602,682) only because the catalog's own content has moved since that reading was taken — the file counts, which are what the cost statement rests on, are identical.Why the README states the cost without the numbers. The prose says "a full real copy in both
.agents/andagent/, plus.claude/symlinks pointing into.agents/" rather than pinning46and11. Those two counts are a function of how many files the catalog currently has; they would go stale the next time a skill is added, and no gate reads them. The load-bearing facts — three destinations, two of them full real copies — do not drift. The dated numbers live in this PR body instead, which is where a reading with a date on it belongs.The
/skillssubpath, and proof the guard is liveThe card's ruling requires the subpath in every spelling. The file carries exactly one catalog spelling and it has the subpath:
That is ratcheted by
packages/create-objectstack/src/template-consistency.test.ts("no customer-facing surface advertises a repo-root skills install"), whose scan surface includesskills/**. A one-shot ablation proved the guard actually reads this file rather than passing vacuously — the subpath was removed from line 9 on disk, the removal was confirmed by anchoredgrep -c(removed text 1 to 0, injected text 0 to 1), and the test was re-run:Restore was proven by artefact, not by an exit code:
git checkout HEAD -- (absolute path), then the post-restoregit hash-objectmatched the HEAD blob hashe274f0d5bb1178b72daf644f91ccd6914d08f3d3andgit diff HEADcame back empty. No test file was left behind.Published-surface readings (
skills/**)Line counts are the unit; the sibling gate defines a token count, so both are reported.
skills/README.mdSKILL.md, summed)No ratchet applies to this file, and that is a measured fact rather than an assumption:
scripts/check-skills-token-ratchet.mjsplacesskills/README.mdin population 3 (OUTSIDE — "not inside any published skill directory"), pinned by its own self-test caseskills/README.md is outside the population (population 3). Running the gate prints no row for the file:36 authored bundle file(s) within their ceilings.scripts/pm/check-skill-line-ratchet.mjsexcludes the published catalog by design. So the +8 lines are unbudgeted — no ceiling was raised and none needed to be.Verification
Gate families derived in the worktree and reconciled, not taken from a list:
All 21 exited 0, at
290c258ef. Named verdict lines:pnpm --filter @objectstack/spec run check:skill-docs—✓ skills/README.md/✅ Skill docs in sync(the generated index block is untouched and still in sync).node scripts/check-skills-token-ratchet.mjs—✓ … 36 authored bundle file(s) within their ceilings(run beyond the derived union; the reconciliation names it as the one extra).pnpm --filter @objectstack/lint run check:doc-formula-expressions— first returned exit 3PREREQUISITE NOT MET, which is not a reading; afterturbo run build --filter=@objectstack/formula --filter=@objectstack/lintunderscripts/pm/os-verify-lock.sh(VERDICT command-exit 0) it returned✓ check:doc-formula-expressions: 22 record-scoped formula example(s) across 434 files / 1372 TS blocks judged clean.pnpm --filter create-objectstack testunder the same lock —Test Files 16 passed (16) · Tests 203 passed (203).node scripts/pm/check-governed-merges.mjs --test skills/README.md— exit 3:⛔ GOVERNED — a human merge is the review record for this PR (#9495 regime).Repo-scale lint is CI's run, and this diff is outside its population — measured, not assumed. (1) Population read from eslint's own configuration: for this path it answers
File ignored because no matching configuration was supplied.(2) Count read from--format json: 1 result object, 0 errors, and the single warning is that ignore notice, not a finding. (3) Invariance: the diff is one Markdown file eslint's config does not match and no TS/JS file is touched, so no untouched file's verdict can move.Changeset
skip-changeset, measured rather than fast-tracked (skills/**is not on the fast path). Across 70 published manifests,files[]entries escaping their package directory: 0; entries naming askillspath segment: 0; build steps copying askills/tree into a package: none. Symbol grep over the 130 enumerated published payload paths with a positive control — markermulti-runtime opt-in0 hits, controlobjectstack-ai/objectstack/skills2 hits. Nothing this PR moves is inside any package's published payload.验收备注
Observations found in passing, deliberately not acted on and not filed:
content/docs/tree still recommends--allin six places —content/docs/ai/skills-reference.mdx:27and:30,content/docs/ai/skills.mdx:35,content/docs/getting-started/build-with-claude-code.mdx:57and:381,content/docs/getting-started/your-first-project.mdx:45and:286. Out of scope here: that surface belongs to docs: five surfaces tell readers to install the skills bundle with--all, which writes it to three directories — and two of them describe a scaffolder command that is changing #16400, and this dispatch names it as another seat's. One detail worth handing over: theskills-reference.mdxsites are hand-authored prose, not generator output — the generated block in that file starts at line 38, andpackages/spec/scripts/build-skill-docs.tscontains no install command at all. Whoever takes that card edits the.mdxdirectly; there is no generator to re-run. Successor: the seat holding docs: five surfaces tell readers to install the skills bundle with--all, which writes it to three directories — and two of them describe a scaffolder command that is changing #16400.skills/objectstack-pm-dispatch/SKILL.md:53spellsnpx skills add objectstack-ai/objectstack/skills --skill objectstack-pm-dispatch— one named skill, no--agentand no-y, so the CLI prompts for the runtime interactively. That is a different shape from the--alldefect and is not obviously wrong, but it is the one other install spelling left insideskills/**. Out of scope for this one-file card; noted so a reviewer sees the whole set. Successor: none currently holds it.packages/create-objectstack/README.md:60,src/templates/AGENTS.md:82,src/templates/blank/README.md:148) already carry the per-agent form, so after this change the only remaining--allrecommendations in the repo are thecontent/docs/**ones above. Out of scope: scaffold:skills add --allwrites the bundle three times (~1.6 MB, byte-identical) and the template_gitignoreexcludes none of it, so every new project's FIRST commit vendors it in triplicate #16331 covered the scaffolder side and has already landed.维护者速读(草稿)
改了什么 — 技能包目录首页
skills/README.md第 9 行的安装命令,从--all改成按单一 agent 安装的形式;--all仍然留在页面上,但改成明确标注的「多运行时可选项」,并写清它的代价。只动这一个文件,9 行增、1 行删。为什么改 —
--all是 skills CLI 的简写,展开后是--skill '*' --agent '*' -y。实测:一个照抄首页命令的客户,会在项目里得到同一份技能包的两份完整实体副本(.agents/与agent/,各 46 个文件、约 600 KB)外加一组.claude/符号链接 —— 一次安装落三处。按单一 agent 安装则只落一处 46 个文件。这个代价此前在脚手架代码的注释里被完整记录过,首页却仍在推荐那条被注释警告的命令:客户读到的第一份文档,和我们自己的脚手架实际执行的命令,是矛盾的。本次改动把首页对齐到脚手架已经在用的那条命令。风险与代价(含回滚) — 风险低:纯文档,不进任何 npm 包的发布产物(已实测,故
skip-changeset)。真实代价有两点。其一,首页多了 8 行(2,079 到 2,215 tokens);该文件不在任何 ratchet 的管辖内,所以没有抬任何天花板,但客户上下文窗口确实多付这一点。其二,新推荐的命令更长、并且默认只为 Claude Code 一种运行时装好 —— 用别的运行时的客户需要自己把--agent换掉,页面已经写明这一点。回滚成本极低:单文件单 commit,git revert即可,没有任何生成物或下游依赖跟着动。席位意见 — (留空,待席位填)
你要做的 — 这是受管面(
skills/**,Prime Directive 14),PR 保持 draft,不进合并队列、不开自动合并。请判断一件事:首页把--all的代价写成「两份完整副本 + 一组符号链接」而不写死 46/11 这两个数字,这个取舍是否合你的意 —— 写死更具体,但会随目录增删而悄悄过期且无门禁兜底。确认后由你手工合并。Generated by Claude Code