Skip to content

Commit adf4bf4

Browse files
feat(devx): pin the teaching corpus against lexical claim drift (#13582) (#13742)
A table-driven, shrink-only ratchet over `content/docs` and `skills`: it fails when a spelling the platform implements stands within a few lines of prose naming a semantic it does not have. #13539 taught `$exists` as a key-presence test when it asks whether the field HAS A VALUE. The false line was a `//` comment INSIDE an `os:check` block, so `check-skill-examples.ts` type-checked that exact block green — "has a value" and "the key is present" type identically — and both `skills/**` sites shipped to customers. Table-driven per the #13582 triage ruling, carrying the `$exists` family only. The engine takes the table as a parameter and `--self-test` drives a synthetic second row through it, so genericity is proven without filling the table. Claude-Session: https://claude.ai/code/session_01Pk26oZ12t5N1hwGW1m1MgC Co-authored-by: Claude <noreply@anthropic.com>
1 parent d7ca6dc commit adf4bf4

5 files changed

Lines changed: 1001 additions & 0 deletions

File tree

.github/workflows/lint.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1767,6 +1767,28 @@ jobs:
17671767
- name: Reserved-word ("role") docs ratchet
17681768
run: pnpm check:role-word
17691769

1770+
# #13582: a LEXICAL anti-drift ratchet over the same corpus, and the
1771+
# sibling of the step above rather than a duplicate of it. That one asks
1772+
# whether a reserved WORD appears at all; this one asks whether a spelling
1773+
# the platform implements is standing next to prose describing a semantic
1774+
# it does not have. #13539 taught `$exists` as a key-presence test when it
1775+
# asks whether the field HAS A VALUE, and the false line was a `//` comment
1776+
# INSIDE an `os:check` block: `check-skill-examples.ts` type-checked that
1777+
# exact block green, because "has a value" and "the key is present" type
1778+
# identically. Both `skills/**` sites shipped to customers.
1779+
#
1780+
# Table-driven by the #13582 triage ruling, carrying the `$exists` family
1781+
# ONLY — each further word (the retired `$regex` spelling, #13532's
1782+
# `visibleWhen` claims) pays its own baseline on its own card.
1783+
#
1784+
# It lives in this job for the reason every other docs guard does
1785+
# (`check:doc-anchors`, `check:docs-audit-scope`, `check:role-word` above):
1786+
# this job carries the whole `check:*` gate family and has no paths filter,
1787+
# which matters here because one of the gate's two roots is `skills/**` and
1788+
# a `content/docs/**` filter would blind it to half its population.
1789+
- name: Teaching-corpus lexical anti-drift ratchet
1790+
run: pnpm check:corpus-claim-drift
1791+
17701792
# #11671: `os i18n extract --fill=default` fills GAPS only, so revising a
17711793
# source string rewrites `en` and strands the previous source text in every
17721794
# other locale. The bundle stays in sync BY KEY, so `check:i18n` reports OK

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@
5454
"check:page-declaration-shape": "node scripts/check-page-declaration-shape.mjs --self-test && node scripts/check-page-declaration-shape.mjs",
5555
"check:template-version-sync": "node scripts/sync-template-versions.mjs --self-test",
5656
"check:role-word": "node scripts/check-role-word.mjs --self-test && node scripts/check-role-word.mjs",
57+
"check:corpus-claim-drift": "node scripts/check-corpus-claim-drift.mjs --self-test && node scripts/check-corpus-claim-drift.mjs",
5758
"check:quick-reference-counts": "node scripts/check-quick-reference-counts.mjs --self-test && node scripts/check-quick-reference-counts.mjs",
5859
"check:overlay-whitelist-table": "node scripts/check-overlay-whitelist-table.mjs --self-test && node scripts/check-overlay-whitelist-table.mjs",
5960
"check:runtime-services-index": "node scripts/check-runtime-services-index.mjs --self-test && node scripts/check-runtime-services-index.mjs",

0 commit comments

Comments
 (0)