Repository navigation
feat(lint): advise a dataset measure or dimension that declares neither synonyms nor a description - #34822
Conversation
…r a description wip: rule, registry entry, explanation, barrel export, tests; dashboards skill teaching and eval; synonyms on the todo and showcase datasets. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WGufzgwLiKcfujYUug7sPs
…es for the member vocabulary advisory Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WGufzgwLiKcfujYUug7sPs
…s the names its location carries Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WGufzgwLiKcfujYUug7sPs
…taset-member-vocabulary-advisory
📓 Docs Drift CheckThis PR changes 2 package(s): 5 hand-written doc(s) NAME something this change touched and may need an implementation-accuracy re-verification:
⛔ 4 release-owned page(s) also name something this change touched. These are read-only:
What this run could not see
Coarse fallback — 39 page(s) merely mention a changed package (the pre-#9192 predicate, kept for the deliberately-wide backstop): Which tree this was computed onThis run read A worktree cut from an older # while this PR is open — GitHub drops the merge commit once it closes
git fetch origin 78defe2aa87aa9583a3a8d5b33ad10997d577d5b && git checkout 78defe2aa87aa9583a3a8d5b33ad10997d577d5b
# afterwards, rebuild it from the two parents, which stay fetchable
git fetch origin fc5913e117405814e5c40e4e9bbe6b2da7420048 55668474107ba329f67b5aa603e0734c70c44960 && git checkout -B drift-repro fc5913e117405814e5c40e4e9bbe6b2da7420048 && git merge --no-ff 55668474107ba329f67b5aa603e0734c70c44960
node scripts/docs-audit/affected-docs.mjs --json fc5913e117405814e5c40e4e9bbe6b2da7420048
|
… labels the stack declares Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WGufzgwLiKcfujYUug7sPs
…eded synonyms Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WGufzgwLiKcfujYUug7sPs
…ffold now carries Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WGufzgwLiKcfujYUug7sPs
|
repo:objectstack#3 · os-support-ai · session_01WGufzhshTXCAmv9KJXRZkB L1 review · 2026-11-17T13:28ZL1: ACCEPT Read at this exact head: the 21 files (+754/−64), the body, card #34718, claim 6945562353, amendments 6947260430 and 6948706504, and os-dev-reports 6947204107 and 6948675399. Tier H. Check-runs on this sha: 74 total, 62 success, 12 skipped, 0 failed or pending. Must-fixNone. Should-fix
Checklist
Notes
|
…vocabulary and name the advisory Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WGufzgwLiKcfujYUug7sPs
|
repo:objectstack#3 · os-support-ai · session_01WGufzgwLiKcfujYUug7sPs 2026-11-17T14:18Z · CI red on head
|
|
repo:objectstack#3 · os-support-ai · session_01WGufzhshTXCAmv9KJXRZkB L1 delta review · 2026-11-17T14:43ZL1: ACCEPT This is a delta from my ACCEPT 6949452870 at Still Tier H (governed by Check-runs on this sha: all completed, 0 failed. The one Test Core (6/10) lint-timeout re-run is green; see the note. Must-fixNone. Should-fixNone. S1 is fixed.
Delta checklist
NotesThe earlier N1–N4 stand unchanged: the |
|
repo:objectstack#3 · os-support-ai · session_01WGufzgh1zkZzDXL36ckWAG Contract reviewServed-tier: Read for this record: card #34718 (body and all nine comments: triage 6942773436 and 6944629941, claim 6945562353, reports 6947204107, 6948675399 and 6950232135, amendments 6947260430, 6948706504 and 6949469635), PR #34822 (body, 23 files, net diff against ① Derived judgments
② Semver levelLevels are right: S1 (should-fix) — the
③ Boundary flags
④ Design judgmentS1 above is the one graded finding on this head and it sits on the declaration, not on the design. On the
Implemented-by: VERDICT: PASS |
…dashboards example its vocabulary Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WGufzgwLiKcfujYUug7sPs
…dvisory Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WGufzgwLiKcfujYUug7sPs
|
repo:objectstack#3 · os-support-ai · session_01WGufzgh1zkZzDXL36ckWAG Contract reviewServed-tier: Delta record. It continues the seat's L2 record 6951558966 (head Read for this record: card #34718 (body and all twelve comments, the newest being claim amendment 6951572798, report 6952226099 and merge report 6952578382), PR #34822 (body as stored at 15:30Z, file list, net diff against ① Derived judgmentsNothing in ① moves on this delta, and each judgment of the previous record stands as written.
② Semver levelS1: closed.
Clause-②: yes (widening), declared and true of the tree. ③ Boundary flags
④ Design judgmentNo must-fix, no should-fix. The three What I tried on the merged head: whether anything
Does anything new open on this delta? No graded finding. One dependency stays live: the #34791 overlap in ③. Implemented-by: VERDICT: PASS |
|
repo:objectstack#3 · os-support-ai · session_01WGufzhshTXCAmv9KJXRZkB L1 delta review · 2026-11-17T15:56ZL1: ACCEPT This is a delta from my ACCEPT 6951339675 at
Still Tier H ( Check-runs on this sha: 74 total, 0 failed. One PR-body guard run shows Must-fixNone. Should-fixNone. Delta checklist
NotesThe earlier N1–N3 stand: the |
|
repo:objectstack#3 · os-support-ai · session_01WGufzgh1zkZzDXL36ckWAG 席位记录 · 2026-11-17T15:58ZHead-sha: 维护者速读(终稿)
席位意见:建议批准。首轮契约复审 6951558966 唯一的 S1 是
席位核对
|
Requested by Yibo Wang · project thread
repo:objectstack#3 · os-support-ai · session_01WGufzgwLiKcfujYUug7sPs
Closes #34718
Clause-②: yes (widening) — @objectstack/lint gains three exports on its "." entry: validateDatasetMemberVocabulary, DATASET_MEMBER_NO_VOCABULARY and the DatasetMemberVocabularyFinding type; nothing accepted before is refused
Metadata-protocol: none
Claim amendment applied (seat comment 6947260430 on the card), round-1 head
b5554ad9cb: Gap 1 = A (theos generate datasetscaffold seeds member synonyms from labels; the zero-finding scaffold test is unchanged), Gap 2 = A (examples keepsynonymsonly; descriptions and bundle translations belong to a separate card), Gap 3 (packages/metadata-protocol/src/runtime-authoring-gate.dataset-writes.test.tsis in the surface). Second amendment (seat comment 6949469635, after L1 ACCEPT 6949452870 with should-fix S1), head80edbdae04: S1 is closed in this PR,content/docs/data-modeling/analytics.mdxandcontent/docs/ui/dashboards.mdxjoined the surface and their example members now carry vocabulary; N1 namesgenerate-permission-dataset.pin.test.tsin the surface. Third amendment (seat comment 6951572798, answering the seat's L2 record 6951558966, PASS with should-fix S1), head4b69badef9: the L2 S1 is closed on this head, theClause-②line here and in the changeset is restated as a widening (three new@objectstack/lintexports;Metadata-protocol: noneand all threepatchlevels unchanged);projectTasksDatasetincontent/docs/ui/dashboards.mdxgets synonyms on its six members; the Gap 2 descriptions and bundle translations are carried by #34873.Final head
5566847410: a clean--no-ffmerge oforigin/main(fc5913e117, 29 first-parent commits) on top of4b69badef9, ordered by the seat.git show --remerge-diffof the merge is empty (no hand resolution); the delta againstorigin/mainis the same 23 files, +815/-82, as before the merge. On the merged head: main prints 69 author-time rules and this branch 70 in the four transcript pages;check:docs-transcript-driftexit 0 after building the CLI closure (exit 3, prerequisite, before it);check-changeset-no-major --base origin/main,check-empty-changeset --base origin/main,check:nul-bytes,check:doc-authoringexit 0; the rule's three lint test files (validate-dataset-member-vocabulary,rule-id-barrel-exports,runtime-gate.dataset-writes) 37 tests passed.overlap-checkat this head: exit 1 against draft PR 34791 only, unchanged. Readings below that name an earlier head were taken at that head and not repeated here; the rest is CI's on this head.维护者速读
synonyms也没写description,校验(os validate/os build/os lint)和发布保存时会给一条提醒,每个成员一条,只提醒不拒绝;dashboards 技能改为教「按用户提问的语言写同义词,加一句业务定义,一个词只指一个成员」,并加了一条中文需求的评测用例;todo 和 showcase 两个示例的数据集成员补了同义词;os generate dataset生成的脚手架现在给每个成员写一条从已有标签取的同义词,并注释提醒作者换成用户真正会说的词。packages/lint/src/validate-dataset-member-vocabulary.ts(规则本身);skills/objectstack-ui/rules/dashboards.md(对外技能的教学改写,替换了原有四行注释);packages/cli/src/commands/generate.ts(脚手架同义词取词与撞词回退)。pnpm --filter @objectstack/lint exec vitest run src/validate-dataset-member-vocabulary.test.ts,预期 12 条全过。skills/**,同时发布 lint 与 cli,Clause-②为 yes,不符合技能低风险放权条件。依据见席位记录 6953337113;本 head 已有 L1-a delta ACCEPT 6953282003 和席位 L2 delta PASS 6953278488,批准后由 o3-B 落地。What changes
packages/lint: one advisory authoring rule,dataset-member-no-vocabulary(warning, nevererror), invalidate-dataset-member-vocabulary.ts. It reports once per dataset measure or dimension that has no non-blanksynonymsentry and no non-blankdescription(a string, or an inline locale map with one non-blank value). The finding's location names the dataset and the member; the sentence says the member answers only to its own name and label, so a question in a user's own words does not find it. One of the two keys silences it.authoring-rules.tsasadvisory, on all three commands, on the runtime publish door for adatasetwrite (runtimeTypes: ['dataset']).rule-explanations.tsgains theos explain dataset-member-no-vocabularyentry;index.tsexports the function, the id constant and the finding type.skills/objectstack-ui/rules/dashboards.md: the four-line member comment under the dataset example is rewritten to say: every member getssynonyms, the words a person types, in the brief's language (matched, never translated; one word names one member), and a one-sentence businessdescription, never a prompt; a member with neither draws the new warning. The example'ssigned_datedimension gains a synonym so the example does not draw the warning it teaches.skills/objectstack-ui/evals/analytics-inline-vs-dataset.json: eval 9, a dataset authored from a Chinese brief, expecting Chinesesynonymsand a Chinese one-sentencedescriptionon every member, and refusing a locale-keyed synonyms map. The evals README names it.todo_task_metrics(9) and of the four showcase datasets (30) gainssynonyms. Convention followed: the oneexamples/app-crmuses, English and Chinese words in the one list.packages/cli(os generate dataset): the scaffold writes onesynonymsentry on each of its two members, seeded from a label the stack already declares, under a comment telling the author to replace the seed with the words users type and to add adescription. The dimension takes the title field's label, else the title-cased field name; the record count takes the object's plural label, else its label. A seed that would also name the other member (bynormalizeDatasetTerm) is skipped for the next candidate, so the scaffold always parses. The bound-object binding gainsdisplayFieldLabel.content/docs/data-modeling/analytics.mdxthe example's 3 dimensions and 5 measures each gainsynonyms, and 4 measures gain a one-sentencedescription; a new Key rules bullet names the two keys, what a member with neither costs a user (a question in their own words misses the governed metric) and the advisory iddataset-member-no-vocabulary. Incontent/docs/ui/dashboards.mdxthe 4 members ofsalesDatasetgainsynonymsandrevenuegains adescription. Both examples stay in English, the language they were written in. Round 3: the page's second dataset,projectTasksDataset(3 dimensions, 3 measures), gains Englishsynonymson every member.packages/lint/src/runtime-gate.dataset-writes.test.ts(the exact rule list at the door, and the app-crm corpus copy, which predated the vocabulary the shipped dataset now carries) andpackages/metadata-protocol/src/runtime-authoring-gate.dataset-writes.test.ts(its "clean dataset" had bare members and asserted no advisories; its members now carrysynonyms). The second file joined the surface by the claim amendment.generate-permission-dataset.pin.test.tspins the seeded synonyms, a Chinese-labelled object, and four collision cases;test/generate-binds-from-stack.test.tsnames the newdisplayFieldLabelin the binding it pins (a pin this change made stale; not named in the amendment).@objectstack/lint,@objectstack/cliand@objectstack/skills, each patch.Why
ADR-0149 D1 makes
synonymsanddescriptionthe vocabulary a business question is matched and explained by, and both are optional. Nothing prompted an author to write them, so an app could publish datasets with none and pass every check, and its users then got ungoverned numbers for questions the app has a governed metric for.Tests
Readings are from this worktree at the head each line names; the final head is
4b69badef9, which adds two commits onb5554ad9cbthat touch docs and the changeset only (merge-base withorigin/mainis3bbda33b78; main, ate9f65a3b57, was 14 first-parent commits ahead at the last push and merges cleanly). At the round-3 push main was atfc5913e117, 29 first-parent commits past the merge-base; it was not merged in (the round's order was one commit),git merge-treeagainst it is clean, and it still prints 69.pnpm --filter @objectstack/lint test: exit 0, 216 files, 9136 tests passed (at837ffc184c; the one later commit edits one CLI test file).pnpm --filter @objectstack/lint typecheckandpnpm --filter @objectstack/cli typecheck: exit 0 (at837ffc184c).pnpm --filter @objectstack/cli exec vitest run --project unit, at837ffc184c: exit 1, 1 failed, 6056 passed, 426 files. The one failure was the bound-object pin intest/generate-binds-from-stack.test.ts, which did not namedisplayFieldLabel. After that pin was updated, atb5554ad9cb:test/generate-binds-from-stack.test.ts,test/generate-scaffold-validates.test.tsandsrc/commands/generate-permission-dataset.pin.test.tsread exit 0, 3 files, 74 tests passed. The whole unit tier was not rerun atb5554ad9cb; the integration tier is CI's.80edbdae04(a scratch script extracted eachdefineDatasetliteral from the page, ranDatasetSchema.safeParseandvalidateDatasetMemberVocabularyfrom the built@objectstack/lint, and was deleted):analytics.mdxas written, 8 members, parse succeeds, 0 findings; control with the added keys stripped, 8 findings.dashboards.mdxas written, 4 members, parse succeeds, 0 findings; control stripped, 4 findings.4b69badef9, the same scratch check (deleted again), now also folding every member's name, label and synonyms withnormalizeDatasetTermand counting terms owned by two members:projectTasksDatasetas written, 6 members, parse succeeds, 0 findings, 18 folded terms, 0 cross-member collisions; control stripped, 6 findings.salesDataset: 0 findings, 12 terms, 0 collisions; control 4.analytics.mdxSalesDataset: 0 findings, 25 terms, 0 collisions; control 8.发票whose title fieldinvoice_nois labelled发票号: the dimension line carriessynonyms: ['发票号']and therecord_countline carriessynonyms: ['发票']. The seed is the label as written, in the label's language; nothing is translated or transliterated. With no field label the seed is the title-cased field name (Name), with no plural label it is the object label (Account). These are labels, not user phrasing, which is what the scaffold's comment says.packages/lint/src/validate-dataset-member-vocabulary.test.ts, 12 tests: silent on a complete dataset; one finding per member on a dataset stripped of both keys; silent on a member with only synonyms and on a member with only a description (string and locale map); an empty list, a blank string and an empty map read as not declared; registry entry is advisory on three commands and thedatasetdoor; each ofvalidate,build,lintreports 4 warnings on the stripped dataset and none on the complete one; the publish door returns 4 advisories and zero errors, and reports nothing for a bare stored sibling.pnpm --filter @objectstack/metadata-protocol exec vitest run src/runtime-authoring-gate.dataset-writes.test.ts: exit 0, 5 passed. Before the fixture edit, the fullpnpm --filter @objectstack/metadata-protocol testat0aebfd190plus working tree read 1 failed (this file), 23055 passed.pnpm --filter @objectstack/metadata-protocol typecheck: exit 0 (atc3d9575bb).pnpm --filter @objectstack/example-crm test51 passed;example-todo249 passed;example-showcase545 passed; all exit 0. Their threetypecheckruns exit 0 (atc3d9575bb).test/generate-scaffold-validates.test.tsis unchanged and green: theos g datasetscaffold adds no finding at any severity. Before the scaffold change (head25b81e2190) that case read exit 1, 1 failed, 25 passed.scripts/ablation-replace.mjsreplaced the early return so every member reads as declared; mutation landed (anchor 1 to 0, blob31d46e12ed19tof03adde23089); the rule's test file went 8 failed, 4 passed; restore verified (blob equals HEAD,git diff HEADempty). A first attempt used an undefined identifier and failed by throwing, so it was discarded and rerun with a behavioural mutation.Verification
os validatethrough the built CLI, per example:25b81e2190, 70 rules)examples/app-crmexamples/app-todoexamples/app-showcaseGates at fix round 3 (
4b69badef9; delta is one changeset line and one docs example), each exit 0:check:skill-examples(exit 3 untilclient-reactwas built, then 0),check:doc-authoring,check:corpus-claim-drift,check:doc-anchors,check:nul-bytes,check-empty-changeset --base origin/main,check-changeset-no-major --base origin/main,check:changeset-gate-self-tests,@objectstack/spec check:docs,check:docs-transcript-drift. The localcheck-changeset-no-majorrun prints "LEVEL AXIS: NOT APPLICABLE" because it has no pull request payload; the reading of the declaration lines against this body is CI'sCheck Changeset. The rest of the 115 derived families were not rerun this round and are CI's.Gates at fix round 2 (
80edbdae04, docs-only delta): the derivation is the same 115 families. 113 were run: 111 exit 0, among them the ones that read these pages (check:skill-examples, which type-checks theos:checkblocks,check:doc-authoring,check:doc-anchors,check:corpus-claim-drift,@objectstack/spec check:docs,check:docs-transcript-drift,check:nul-bytes).check:i18nandcheck:i18n-walk-parityanswered exit 3 (prerequisite: the CLI was not built in this round's worktree): NOT MEASURED this round, both exit 0 in round 1. Not run this round:check:i18n-coverageandcheck:dual-build-cjs-loads(both want builds this docs-only round did not make). Those four are CI's.Gates at the fix round, derived by
node scripts/pm/dispatch-gates.mjs --commandsat837ffc184c: 115 families. 112 answered exit 0 on the first run. Three answered exit 3 (prerequisite, nothing measured):check:skill-examplesandcheck:i18n-coverage, each exit 0 after the builds they name ("14 config(s), 423 baselined untranslated string(s), none new"), andcheck:dual-build-cjs-loads, which wants a repo-wide build: NOT MEASURED locally, CI's.dispatch-gates --ran: 115 derived, 115 run. Rerun atb5554ad9cb, each exit 0:check:tier-file-adoption,check:test-source-alias,check:cross-package-test-inputs,check:agent-test-spelling,check-skills-token-ratchet,check:docs-transcript-drift,check:type-check-coverage,check:type-check-debt,check-changeset-no-major --base origin/main,check:nul-bytes.Earlier round, local subset derived by
node scripts/pm/dispatch-gates.mjs --commands(109 families atc3d9575bb): all exit 0 after one rerun.check:skill-examplesfirst answered exit 3 (prerequisite:packages/client-reactnot built), and exit 0 once it was built.dispatch-gates --ran: 109 derived, 109 run, 0 NOT-MEASURED, 0 UNRUN. After the merge oforigin/main, rerun at25b81e2190, each exit 0:check:docs-transcript-drift,check-skills-token-ratchet,check:i18n-coverage("14 config(s), 423 baselined untranslated string(s), none new"),check-changeset-no-major --base origin/main,check-empty-changeset,check:nul-bytes,check:doc-authoring,check:cross-package-test-inputs,check:skill-examples,check:skill-identifier-liveness,check:skill-links. Every other family is CI's.Skills size, lines and tokens (the token ratchet's unit):
skills/objectstack-ui/rules/dashboards.mdNo
SKILL.mdis edited. Of the bundle's +308 tokens, +2 are indashboards.mdand the rest are the eval fixture and its README, which the ratchet measures and does not price. The ceiling is not raised: the new teaching replaces the previous comment, which said "every language in one list", "none may equal another member's name, label or synonym" and "translated likelabel"; the first two are restated shorter and the third is dropped from this file (theobjectstack-i18nskill states the memberdescriptionkey).Acceptance notes
os generate datasetscaffold (ruled, Gap 1 = A). The scaffold seeds synonyms from labels, as described above; the zero-finding scaffold test is not relaxed. A seeded synonym is a starting word, not vocabulary: for an object whose labels are English the scaffold's dataset answers to English words only until the author edits it.synonymsonly, nodescription(ruled, Gap 2 = A). A memberdescriptionis display text, so it is an expected translation key. Measured onexamples/app-todo: adding 9 member descriptions movedi18n/missing-datasetfrom 22 to 40 and the config's untranslated total from 106 to 124, whichcheck:i18n-coveragerefuses as growth over its baseline of 106. Translating them means editing the examples' translation bundles, outside the claim's data-only surface; the seat ruled that work to a separate card, which is examples: dataset members carry a description and bundle translations, not synonyms alone #34873. With synonyms only the count stays 106 and the rule is silent.scripts/pm/overlap-check.mjsat4b69badef9answers exit 1; that PR shares the four transcript count pages and lint source files (authoring-rules.ts,index.ts). Not resolved here against an unmerged PR; whichever lands second re-derives the count.origin/main(fc5913e117), PR 34850 and PR 34717 merge cleanly, and main still prints 69.user-text.ts) is added for this rule; its consumers rendermessage, as they do for the other advisory without one on a publish door (email-template-default-reads-as-path).4b69badef9:content/docs/data-modeling/analytics.mdx(one dataset) andcontent/docs/ui/dashboards.mdx(both of its datasets,salesDatasetandprojectTasksDataset) teach no bare member; see What changes and Tests. Other pages that show a dataset literal were not swept.packages/platform-objects/src/apps/dashboards/system.datasets.ts) declare neither key on their 7 members. Read from source only;os lintover the platform-objects extract config reported 0 findings of this rule, so no door was measured reporting them.Human Minimum
packages/specholds no runtime logic. (No spec change.)pnpm lintpasses. (No formatter ran; the repo-widepnpm lintis CI's run and was not run locally.)main, one pull request.packages/spectouched: its generated artifacts are regenerated and committed. (Not touched.)content/docs/references/,packages/*/CHANGELOG.mdorcontent/docs/releases/.Generated by Claude Code