From 811f566085233a11d7c40dfce2601ea80f2088c0 Mon Sep 17 00:00:00 2001 From: Claude Date: Thu, 19 Nov 2026 02:27:01 +0000 Subject: [PATCH] docs(skills): scope "Declaring is a demand" to what os serve does A declared provider-table token or ai/ai-studio with its package absent fails the boot; a declared enterprise / cloud token with no provider only warns, and hierarchy-security's scopes fall back to owner-only. Paid by two same-file restatement cuts; the platform ratchet row moves by the measured remainder (6145 -> 6163). Claude-Session: https://claude.ai/code/session_01Utp6CazXu8zyYD5PC6J2u7 Co-authored-by: Claude --- .../35285-platform-declared-capability-boot.md | 12 ++++++++++++ scripts/check-skills-token-ratchet.mjs | 17 ++++++++++++++++- skills/objectstack-platform/SKILL.md | 13 +++++++------ 3 files changed, 35 insertions(+), 7 deletions(-) create mode 100644 .changeset/35285-platform-declared-capability-boot.md diff --git a/.changeset/35285-platform-declared-capability-boot.md b/.changeset/35285-platform-declared-capability-boot.md new file mode 100644 index 00000000000..33d81d9cead --- /dev/null +++ b/.changeset/35285-platform-declared-capability-boot.md @@ -0,0 +1,12 @@ +--- +'@objectstack/skills': patch +--- + +docs(skills): `objectstack-platform` says which declared capabilities fail the boot and which only warn + +Clause-②: no +Metadata-protocol: none + +The "Declaring is a demand" rule taught that any capability an app declares in `requires` with its provider package absent is a hard boot error. `os serve` does that for the tokens of the provider table and for `ai` / `ai-studio`. A declared enterprise or cloud token (`hierarchy-security`, `ai-seat`, `governance`, `audit-compliance`, `access-policy-console`) with no provider only prints a warning and the boot goes on; for `hierarchy-security` the hierarchy-relative scopes then fall back to owner-only. The rule now says so, so an agent no longer reads a clean boot as proof that those scopes are enforced, nor tells a user the app will refuse to start when it starts with narrower visibility. + +Two restatements in the same file were cut to pay for the sentence. diff --git a/scripts/check-skills-token-ratchet.mjs b/scripts/check-skills-token-ratchet.mjs index 159e1a4343e..febe3c43a2e 100644 --- a/scripts/check-skills-token-ratchet.mjs +++ b/scripts/check-skills-token-ratchet.mjs @@ -825,7 +825,22 @@ export const CEILINGS = new Map([ // -> 6145 tokens: the 5 tokens of headroom are absorbed and the ceiling moves // 6011 -> 6145 (+134), the measured remainder only. Pinned AT the measurement. // ceil(($(wc -c < skills/objectstack-platform/SKILL.md) - 20) / 4) == ceil(24577 / 4) - ['skills/objectstack-platform/SKILL.md', 6145], + // 6145 -> 6163 (card #35285): the "Declaring is a demand" rule is scoped to + // what `os serve` does — a declared token of the provider table or + // `ai`/`ai-studio` with its package absent fails the boot, a declared + // enterprise / cloud token with no provider only warns, and + // `hierarchy-security`'s scopes then fall back to owner-only. Raise path the + // standing ruling 「A:先削重复,余额按实测提高」 (ruling record 6513306068, + // letter B). PAID DOWN FIRST — two restatements cut, each keeping its other + // home in the same sentence: ", not at boot" after "rejected by `defineStack` + // at authoring time", and "— so new routes added to HttpDispatcher work + // automatically" after "delegates everything else to it". Arithmetic in + // priced bytes (stamp line excluded): on `origin/main` the text was 24577 + // bytes (6145 tokens, headroom 0); the cuts remove 78 and the rule adds 150, + // so the LANDED priced text is 24649 bytes -> 6163 tokens: the ceiling moves + // 6145 -> 6163 (+18), the measured remainder only. Pinned AT the measurement. + // ceil(($(wc -c < skills/objectstack-platform/SKILL.md) - 20) / 4) == ceil(24649 / 4) + ['skills/objectstack-platform/SKILL.md', 6163], // `skills/objectstack-pm-dispatch/SKILL.md` (9708) and its // `rules/dev-template.md` (1838) left this table on 2026-09-10 with the files: // the maintainer deleted the published PM skill whole (verbatim: diff --git a/skills/objectstack-platform/SKILL.md b/skills/objectstack-platform/SKILL.md index 33bee50159d..a45fd31cd17 100644 --- a/skills/objectstack-platform/SKILL.md +++ b/skills/objectstack-platform/SKILL.md @@ -252,8 +252,7 @@ that `basePath` is not inside **refuses at boot**, naming both values. ### Architecture `createHonoApp` creates an `HttpDispatcher`, mounts explicit -routes for auth and discovery, and delegates everything else to it — so **new -routes added to HttpDispatcher work automatically**. +routes for auth and discovery, and delegates everything else to it. --- @@ -323,15 +322,17 @@ through it: The authoritative list is `PLATFORM_CAPABILITY_TOKENS` (`@objectstack/spec`, `kernel/platform-capabilities.ts`) — an unknown token is -**rejected by `defineStack` at authoring time**, not at boot. +**rejected by `defineStack` at authoring time**. Six rules that change what you write: - **Precedence:** `requires` › `tiers` › `--preset` › built-in default. An explicit instance in `plugins:` always shadows capability resolution. -- **Declaring is a demand.** A capability YOU declared whose provider package is - absent is a hard boot error; one the platform auto-injects for you stays - best-effort (warn and continue). +- **Declaring is a demand.** A table token or `ai`/`ai-studio` YOU declared + whose provider package is absent is a hard boot error; one the platform + auto-injects for you stays best-effort (warn and continue). An enterprise / + cloud token with no provider only warns at boot; `hierarchy-security`'s + scopes then fall back to owner-only. - **`auth` implies `email`**, even under `--preset minimal`: auth callbacks need the mail service. - **Keep `automation` whenever `plugins:` lists a connector** — connector