Repository navigation
docs(skills): the objectstack-data skill names the platform's exchange-rate table and teaches unitConfig - #38980
Conversation
…itConfig
rules/field-types.md: the currency section says the rates homeAmount
converts with are the platform's sys_exchange_rate, kept in Setup, and
never an app rate object or a conversion hook; a new Unit of measure
section teaches unitConfig on a text field ('code') and on a number
field ('fixed' with unit, 'record' with unitField), the stored
uppercase UN/ECE codes (H87, KGM), the organization's own units in
sys_unit and the two write refusals.
SKILL.md: the Field Types routing row names both. The sentence above
the routing table, which its column header restates, is cut.
Token ratchet: both rows move by the measured remainder after
same-file restatement cuts (ruling record 6513306068, letter B).
Claude-Session: https://claude.ai/code/session_01WGufzeatqKfTRUzTJVa9jQ
Co-authored-by: Claude <noreply@anthropic.com>
…ta-skill-rate-unit
|
repo:objectstack@os-support-ai · os-support-ai · session_01WGufzeatqKfTRUzTJVa9jQ Final green head · 2026-12-01T16:58Z · zone osa-ai
|
|
repo:objectstack@os-support-ai · os-support-ai · session_01WGufzhGA3zoCFquQgku4pm Contract-review-claim: session_01WGufzhGA3zoCFquQgku4pm · head bf4e7c2 · 2026-12-01T16:59Z |
|
repo:objectstack@os-support-ai · os-support-ai · session_01WGufzhGA3zoCFquQgku4pm Contract reviewServed-tier: Review time: 2026-12-01T17:05Z. PR #38980, card #38939. Read: the card body and its four comments (triage 7313849064, claim 7314913435, dev report 7317863030, claim amendment 7317913389), the PR body and its two comments, the net diff of the four files against the merge base ① Derived judgments
② Semver level
Clause-②: no. Right: no accept set widens or narrows. The same line is on the PR body, the changeset and the claim. The changeset, sentence by sentence, against the tree:
③ Boundary flags
④ Design judgment
Tried to break it: a retired organization unit and a member of another dimension are refused under two further codes (
Eval cases of this skill against the changed text (75 cases in three files; no fixture is in the diff, so no case is touched):
Findings S1 (should-fix) — the No must-fix. One should-fix: S1. Implemented-by: VERDICT: PASS |
|
repo:objectstack@os-support-ai · os-support-ai · session_01WGufzhGA3zoCFquQgku4pm L1 review · PR #38980 (#38939) · head bf4e7c2 · 2026-12-01T17:07ZVERDICT: should-fix, 1 item (S1, carried from L2; a paper item, so the head does not move). No must-fix.
Next: after S1, the PR goes to the seat as Tier H (governed |
|
repo:objectstack@os-support-ai · os-support-ai · session_01WGufzhGA3zoCFquQgku4pm L1 confirm · PR #38980 · head bf4e7c2 (unchanged) · 2026-12-01T17:13ZS1 is closed, and L1 is ACCEPT on this head.
|
|
repo:objectstack@os-support-ai · os-support-ai · session_01WGufzhPdWmTd47Fi2bKYZS 席位核对ACCEPT — PR #38980 @
|
|
repo:objectstack@os-support-ai · os-support-ai · session_01WGufzhGA3zoCFquQgku4pm Contract reviewServed-tier: Review time: 2026-12-01T17:18Z. Delta record on the same head as the first record of this session: the head did not move, and the PR body alone changed. Read: the PR body as it now stands, the commit messages of the branch, the card's state, and the check-runs on the head. ① Derived judgmentsUnchanged from the first record: the diff is the same four files on the same head. ② Semver levelUnchanged. Clause-②: no. Unchanged, and still on the PR body. ③ Boundary flagsUnchanged, but for the one flag S1 carried: the with-skill re-run of eval cases 22 and 24 now has a carrier, the card itself, which stays open. SQL push-down: not applicable. ④ Design judgmentS1: closed
The judgment of the two No must-fix, no should-fix. Implemented-by: VERDICT: PASS |
|
repo:objectstack@os-support-ai · os-support-ai · session_01WGufzhPdWmTd47Fi2bKYZS 维护者速读
|
|
repo:objectstack@os-support-ai · os-support-ai · session_01WGufzhPdWmTd47Fi2bKYZS 2026-12-01T23:43Z · Landing seat: taking this Tier H pull out of the merge queue and back to draft (Governed Surface Queue Guard, remedy 1).
|
Requested by Yibo Wang · project thread
Part of #38939
Claim for this branch: #38939 comment 7314913435
Clause-②: no
Metadata-protocol: none
repo:objectstack@os-support-ai · os-support-ai · session_01WGufzeatqKfTRUzTJVa9jQ
维护者速读
What changes
Two published files of
skills/objectstack-data, two rows of the token ratchet, and one changeset. No eval fixture, no file ofskills/objectstack-project, no schema and no runtime file is touched.rules/field-types.md, § Currency, thehomeAmountparagraphrateDaterate. It did not say where the rates live.sys_exchange_rate, which an administrator keeps in Setup; never an app rate object or a conversion hook; a foreign amount with no rate on or beforerateDateis refused (ERR_EXCHANGE_RATE_MISSING).rules/field-types.md, new § Unit of measure (under Common Field Configurations, after Currency)evals/heldunitConfig,unitMode,H87,KGMorsys_unit.unitMode: 'code'on atextfield, and on anumberfield'fixed'withunit: 'KGM'and'record'withunitField. One paragraph: a unit is never free text, a picklist or an app unit object;unitModehas no default; the stored code is exact uppercase, a standard UN/ECE Rec 20 code (H87,KGM,XBXnamed) or one the organization adds tosys_unitin Setup; the two write refusals;unitDimension; the free-text conversion run.rules/field-types.md, thetextandnumberrowsunitConfig.unitConfigand a pointer to the new section, as thecurrencyrow points at Currency.rules/field-types.md,## Choosing a typeand## Changing a field that has data, first line of eachSKILL.md,## Where to go, the Field Types rowsys_exchange_rate), units of measure (unitConfig)".SKILL.md,## Where to go, the sentence above the tablescripts/check-skills-token-ratchet.mjsSKILL.md2224,rules/field-types.md4200Why the entry file changes at all. A request to "create an exchange-rate object and a conversion hook" is routed by the entry to the object and hook files, which do not mention the rate table. Without a word in the routing table, nothing sends that request to § Currency. The row now names both identifiers, so the request meets them before it builds anything.
Every added sentence, and the code it was read from
sys_exchange_ratepackages/objectql/src/home-amount-projection.ts,EXCHANGE_RATE_OBJECT;packages/platform-objects/src/system/sys-exchange-rate.object.tspackages/platform-objects/src/apps/setup-nav.contributions.ts,nav_exchange_rates; the object's "Who writes" note (organization administrators)rateDateis refused,ERR_EXCHANGE_RATE_MISSINGeffective_dateon or before the document date, else refused; an amount in the home currency needs no rate row, hence "foreign"unitConfigon anumberfield ('fixed','record') or atextfield ('code'); no defaultunitModepackages/spec/src/data/field.zod.ts,UnitConfigSchema,UNIT_CONFIG_MODES_BY_FIELD_TYPE,unitModeMessageunitFieldnames is atextfield of the same object with nounitConfigorvalueDomainpackages/spec/src/data/object.zod.ts,refuseDishonestRecordUnitFieldH87piece,KGMkilogram,XBXbox;STANDARD_UNITSin@objectstack/spec/datapackages/spec/src/data/standard-units.tssys_unit, added in Setup, and cannot be afixedunitsys-unit.object.ts;setup-nav.contributions.ts,nav_units_of_measure;fixedUnitMessageinfield.zod.tsERR_UNIT_CODE_UNKNOWN(pcs,kg,C62,EA),ERR_UNIT_CODE_REQUIREDpackages/objectql/src/validation/unit-code-membership.ts;C62andEAare in no standard row and cannot be organization codesunitDimensionon'record'and'code'onlyfield.zod.tsos migrate unit-codespackages/cli/src/commands/migrate/unit-codes.tsThe same facts are in the generated platform catalog (
skills/objectstack-project/references/platform-catalog.md, thesys_exchange_rateandsys_unitrows), which this PR does not touch.Size
ceil(utf8 bytes / 4))skills/objectstack-data/rules/field-types.mdskills/objectstack-data/SKILL.mdSKILL.mdfiles of the catalogskills/objectstack-data, authored files outsideevals/The entry file stays inside its router budget of 9 KB: 8958 bytes.
The ratchet raise
Both rows had zero headroom. Raise path: ruling record 6513306068, letter B. The standing ruling, verbatim and untranslated: 「A:先削重复,余额按实测提高」.
rules/field-types.md: +1560 bytes of new text. Paid down first by two restatement cuts in the same file, 97 bytes (45 + 52): thesecretparenthetical under## Choosing a type(its home is thesecretrow of the same file, which says encrypted at rest and names ADR-0100) and the parenthetical under## Changing a field that has datathat repeated the entry's first trap, which the same line already points at. The row moves by the measured remainder, +366, to 4566.SKILL.md: +71 bytes on the routing row. Paid down first by the sentence above the routing table, 36 bytes. The row moves by the measured remainder, +9, to 2233.Tests
Read on head
bf4e7c2be3(the branch withorigin/mainatd38006b9b3merged in).node scripts/check-skills-token-ratchet.mjs: exit 0;skills/objectstack-data/SKILL.md is 2233 tokens (ceiling 2233; headroom 0),skills/objectstack-data/rules/field-types.md is 4566 tokens (ceiling 4566; headroom 0).--self-test: exit 0, 111 cases pass.pnpm --filter @objectstack/spec run check:skill-examples: exit 0, "342 prose examples type-check across 3 surface(s)". The new block carries the check marker and is one of them: withunitModemisspelled in it on disk (a one-time check, restored and hash-compared to the committed blob), the same command exits 1 witherror TS2561atskills/objectstack-data/rules/field-types.md:228:41.pnpm --filter @objectstack/spec run check:skill-docs,check:skill-served-sections,check:skill-refs: exit 0 each.pnpm check:skill-links,check:skill-identifier-liveness,check:skill-compatibility,check:skill-frame-sync,check:doc-authoring,check:nul-bytes: exit 0 each.ObjectSchema.safeParse): accepted. The same probe confirmed each refusal the paragraph states at the build door: a lowercaseunit,C62, a missingunitMode,'code'on anumberfield,'fixed'on atextfield,unitConfigon acurrencyfield,unitDimensionunder'fixed', and a pointed-at field that carriesunitConfigorvalueDomain.unit-code-membership.test.tsandhome-amount-projection.test.ts, 70 tests.Derived gate set: 70 commands, 68 run, 2 not measured
node scripts/pm/dispatch-gates.mjs --ranonbf4e7c2be3: "70 derived famil(ies) accounted for — 68 run, 2 NOT-MEASURED (1 DERIVED from a recorded exit 3, 1 claimed)". All 68 exited 0.pnpm check:dual-build-cjs-loads, exit 3, PREREQUISITE NOT MET. It reads the built output of every dual-build package, and this diff touches no package, so no workspace build is owed locally. CI runs it after its build.pnpm check:pm-dispatch-gates. It did not finish inside the 10-minute foreground limit (stopped at 570 s, exit 124, every check printed until then green). CI runs it.pnpm --filter @objectstack/lint run check:doc-formula-expressionsandpnpm check:lean-entry-closurefirst answered exit 3; each exited 0 after the targeted build its refusal names.bf4e7c2be3.origin/mainhas moved three commits since; none touches a path of this PR.Token read for eval objects #22 and #24
Counts of each assertion token in the lines this PR adds, and in the two files after the change.
SKILL.mdrules/field-types.mdunitConfigunitModeH87KGMsys_exchange_ratehomeAmountcurrencyMode: 'record'No forbidden token of either case is in an added line:
uom: Field.select(,type: 'select',name: 'exchange_rate',event: 'afterInsert', 0 each. The new paragraph says "a picklist" and "an app rate object" for that reason, so an answer that copies it writes no forbidden literal.The with-skill re-run of the two cases is NOT MEASURED here. A model run is the eval seat's round, and this PR ran none.
What remains on #38939, so this PR is
Part of: card note 3, the with-skill re-run of eval objects 22 and 24. The card stays open withpm:dispatcheduntil the eval seat records that re-run.Acceptance notes
SKILL.mdat 2242 tokens with no deletion shown, which the raise path does not allow.type: 'select'is inskills/objectstack-data/references/examples-objects.mdfor other fields, and a right answer that warns against a select by naming it would fail the case. That is an eval assertion, which skills evals: eleven cases across five bundles fail a right answer, by forbidding a literal the bundle itself writes as the trap, matching a legitimate key, or demanding one spelling (GA test 3) #38941 holds; noted, not changed here.packages/spec/scripts/lib/platform-catalog.ts; the data skill's text is hand-written. A change to either table's contract needs both.H87andKGMliterally; it is carried here.Verification
Read first, by risk:
skills/objectstack-data/rules/field-types.md, the new### Unit of measureparagraph: every clause is a claim about what the write path refuses.homeAmountparagraph: "never an app rate object or a conversion hook" is the instruction an agent will follow.skills/objectstack-data/SKILL.md,## Where to go: the routing row, and the sentence that was cut above the table.Two-minute check:
node scripts/check-skills-token-ratchet.mjsprints "skills/objectstack-data/rules/field-types.md is 4566 tokens (ceiling 4566; headroom 0)" and "skills/objectstack-data/SKILL.md is 2233 tokens (ceiling 2233; headroom 0)", andgit diff origin/main...HEAD --statlists four files.Governed surface (
skills/**, Tier H): this PR stays draft. No reviewer is requested and nothing is queued or armed by the author.Generated by Claude Code