From 7e7af399fbde67b0b885b3f6a87f5b0bafde124b Mon Sep 17 00:00:00 2001 From: Claude Date: Sat, 21 Nov 2026 00:10:26 +0000 Subject: [PATCH] skills(project): the platform catalog lists working calendars as shipped sys_work_calendar and sys_work_calendar_exception move out of Planned into the object tables; working-day formulas stay Planned. The hand-written text stays at its ceiling, paid by cuts of restated text. Eval case 8 expects the shipped answer. Co-Authored-By: Claude Claude-Session: https://claude.ai/code/session_016WV4d1ZJL93Kin2UHFXbFv --- .changeset/35964-catalog-working-calendar.md | 8 +++++++ packages/spec/scripts/lib/platform-catalog.ts | 21 +++++++++---------- .../evals/project-process.json | 8 ++++--- .../references/platform-catalog.md | 17 +++++++-------- 4 files changed, 31 insertions(+), 23 deletions(-) create mode 100644 .changeset/35964-catalog-working-calendar.md diff --git a/.changeset/35964-catalog-working-calendar.md b/.changeset/35964-catalog-working-calendar.md new file mode 100644 index 00000000000..2995416da6c --- /dev/null +++ b/.changeset/35964-catalog-working-calendar.md @@ -0,0 +1,8 @@ +--- +'@objectstack/skills': patch +--- + +Clause-②: no +Metadata-protocol: none + +The platform catalog (`objectstack-project/references/platform-catalog.md`) now lists working calendars as shipped. `sys_work_calendar` and `sys_work_calendar_exception` have rows beside `sys_exchange_rate`: each organization keeps its calendars and holidays in Setup, and an approval's `escalation.clock: 'working_time'` reads them. An app no longer declares its own calendar or holiday object. The Planned section keeps only what is still missing: no formula reads a calendar yet. diff --git a/packages/spec/scripts/lib/platform-catalog.ts b/packages/spec/scripts/lib/platform-catalog.ts index ab56ce4605e..a9e8470dca0 100644 --- a/packages/spec/scripts/lib/platform-catalog.ts +++ b/packages/spec/scripts/lib/platform-catalog.ts @@ -118,6 +118,8 @@ export const APP_FACING_OBJECT_GROUPS: readonly { readonly title: string; readon title: 'Money, imports and approvals', rows: [ { name: 'sys_exchange_rate', builds: 'an exchange-rate table', reach: '`currencyConfig.homeAmount` converts at write; Setup edits rates; data API' }, + { name: 'sys_work_calendar', builds: 'a business-hours calendar', reach: 'kept per organization in Setup; an approval\'s `escalation.clock: \'working_time\'` reads it; data API' }, + { name: 'sys_work_calendar_exception', builds: 'a holiday table', reach: 'a calendar\'s holidays and make-up workdays, kept in Setup; data API' }, { name: 'sys_import_job', builds: 'a bulk-import job table', reach: '`POST /api/v1/data/OBJECT/import/jobs`; data API read' }, { name: 'sys_approval_request', builds: 'an approvals table', reach: 'a flow approval node opens it; `/api/v1/approvals` routes decide; data API read' }, { name: 'sys_approval_action', builds: 'an approval decision trail', reach: 'written per decision; data API read' }, @@ -190,8 +192,8 @@ export const CAPABILITY_ROWS: Readonly> = Object.freeze({ /** Master data each suite keeps, matched across suites by key contract. */ export const NOT_PLATFORM_ROWS: readonly { readonly concept: string; readonly rule: string }[] = [ - { concept: 'Party master data: customers, suppliers, contacts', rule: 'one app owns each entity; another app matches its records by the key contract (country plus credit code or registration number), one way, with no platform party object' }, - { concept: 'Item master data: materials, products, plants', rule: 'the owning app\'s object is reused by key (material number, plant code); the platform ships no item object' }, + { concept: 'Party master data: customers, suppliers, contacts', rule: 'one app owns each entity; another app matches its records by the key contract (country plus credit code or registration number), one way' }, + { concept: 'Item master data: materials, products, plants', rule: 'the owning app\'s object is reused by key (material number, plant code)' }, ]; /** Carded, not shipped. Each row is **not available**; the shipping PR moves it into the main table. Capped at a few rows. */ @@ -202,9 +204,9 @@ export const PLANNED_ROWS: readonly { readonly concept: string; readonly state: link: 'https://github.com/objectstack-ai/objectstack/blob/main/docs/adr/0158-units-of-measure-standard-unit-table-org-units-quantity-unit-declaration-base-quantity.md', }, { - concept: 'Working calendars (business days, holidays, SLA clocks)', - state: 'carded, contract in design', - link: 'https://github.com/objectstack-ai/objectstack/issues/35340', + concept: 'Working-day formulas', + state: 'contract accepted; no formula reads a calendar yet', + link: 'https://github.com/objectstack-ai/objectstack/blob/main/docs/adr/0157-working-calendars-are-org-editable-runtime-data-resolved-by-code-or-refused.md', }, ]; @@ -218,13 +220,11 @@ export const PROSE = Object.freeze({ banner: [ '> **Auto-generated** — do not edit. Regenerate in the framework repo with', '> `pnpm --filter @objectstack/spec gen:skill-refs`', - '> (not runnable in an installed app). Names come from `@objectstack/spec`;', - '> the prose columns are authored beside the generator.', + '> (not runnable in an installed app). Names come from `@objectstack/spec`.', ], intro: [ 'Read this before adding an object, a field or a flow (objectstack-project §0,', - 'question 3). `list_objects` over MCP hides system objects, so look here, not', - 'at the runtime.', + 'question 3). `list_objects` over MCP hides system objects, so look here.', ], objects: [ '"Data API" means the generic `/api/v1/data/OBJECT` routes, as the object', @@ -252,8 +252,7 @@ export const PROSE = Object.freeze({ 'Each row is **not available**: nothing below can be declared or installed.', 'The app may build its own meanwhile, marked `// PLATFORM-CANDIDATE:` with', 'the link; an interim unit field stores the contract\'s UN/ECE Rec 20 codes', - '(`H87`, `KGM`) as option values, the business\'s spellings as labels. The PR', - 'that ships a row moves it into the tables above.', + '(`H87`, `KGM`) as option values, the business\'s spellings as labels.', ], }); diff --git a/skills/objectstack-project/evals/project-process.json b/skills/objectstack-project/evals/project-process.json index d306bb9aafe..39ad5ed3065 100644 --- a/skills/objectstack-project/evals/project-process.json +++ b/skills/objectstack-project/evals/project-process.json @@ -123,14 +123,16 @@ { "id": 8, "prompt": "Our ObjectStack app's case SLA must count business hours only. Add a `business_hours_calendar` object (weekday ranges per organization) and a `holiday` table, and make the SLA formula read them.", - "expected_output": "Checks the platform catalog first: working calendars are in its Planned section, marked not available, so there is nothing to declare today. This is a missing capability, not a defect, so §3 does not apply: the app is not blocked and no workaround language is used. A second app would copy a calendar, so it files or links the platform card at objectstack-ai/objectstack, and may build the smallest calendar the SLA needs meanwhile, with the objects and the formula marked `// PLATFORM-CANDIDATE: ` so the bump sweep (§5 step 4) replaces them when the platform ships calendars. It does not present the app's calendar as the platform's.", + "expected_output": "Does not create `business_hours_calendar` or `holiday`: the platform catalog lists `sys_work_calendar` (weekly working periods, per organization) and `sys_work_calendar_exception` (dated holidays and make-up workdays) as what the platform ships, and each organization keeps its own rows in Setup. The formula half is different: working-day formulas are in the catalog's Planned section, marked not available, so no formula reads a calendar today. That is a missing capability, not a defect, so §3 does not apply: the app is not blocked and no workaround language is used. It links the contract at objectstack-ai/objectstack and may compute the business-hours due time in the app meanwhile, reading the platform's calendar rows and marked `// PLATFORM-CANDIDATE: ` so the bump sweep (§5 step 4) replaces it when the platform ships the formulas. Where the SLA is an approval step's deadline, it sets `escalation.clock: 'working_time'` instead, which reads the calendar today.", "files": [], "assertions": { "must_contain": [ - "PLATFORM-CANDIDATE", - "objectstack-ai/objectstack" + "sys_work_calendar", + "PLATFORM-CANDIDATE" ], "must_not_contain": [ + "name: 'business_hours_calendar'", + "name: 'holiday'", "Blocked by", "PLATFORM-GAP" ] diff --git a/skills/objectstack-project/references/platform-catalog.md b/skills/objectstack-project/references/platform-catalog.md index ccf5a044c6a..d3b39ea7902 100644 --- a/skills/objectstack-project/references/platform-catalog.md +++ b/skills/objectstack-project/references/platform-catalog.md @@ -2,12 +2,10 @@ > **Auto-generated** — do not edit. Regenerate in the framework repo with > `pnpm --filter @objectstack/spec gen:skill-refs` -> (not runnable in an installed app). Names come from `@objectstack/spec`; -> the prose columns are authored beside the generator. +> (not runnable in an installed app). Names come from `@objectstack/spec`. Read this before adding an object, a field or a flow (objectstack-project §0, -question 3). `list_objects` over MCP hides system objects, so look here, not -at the runtime. +question 3). `list_objects` over MCP hides system objects, so look here. ## Platform objects an app would otherwise build @@ -52,6 +50,8 @@ a seed) without declaring it. | Object | Mounted by | What you would otherwise build | How the app reaches it | |:--|:--|:--|:--| | `sys_exchange_rate` | every boot | an exchange-rate table | `currencyConfig.homeAmount` converts at write; Setup edits rates; data API | +| `sys_work_calendar` | every boot | a business-hours calendar | kept per organization in Setup; an approval's `escalation.clock: 'working_time'` reads it; data API | +| `sys_work_calendar_exception` | every boot | a holiday table | a calendar's holidays and make-up workdays, kept in Setup; data API | | `sys_import_job` | every boot | a bulk-import job table | `POST /api/v1/data/OBJECT/import/jobs`; data API read | | `sys_approval_request` | `requires: ['approvals']` | an approvals table | a flow approval node opens it; `/api/v1/approvals` routes decide; data API read | | `sys_approval_action` | `requires: ['approvals']` | an approval decision trail | written per decision; data API read | @@ -138,18 +138,17 @@ platform" here. | Concept | Rule | |:--|:--| -| Party master data: customers, suppliers, contacts | one app owns each entity; another app matches its records by the key contract (country plus credit code or registration number), one way, with no platform party object | -| Item master data: materials, products, plants | the owning app's object is reused by key (material number, plant code); the platform ships no item object | +| Party master data: customers, suppliers, contacts | one app owns each entity; another app matches its records by the key contract (country plus credit code or registration number), one way | +| Item master data: materials, products, plants | the owning app's object is reused by key (material number, plant code) | ## Planned: carded, not shipped Each row is **not available**: nothing below can be declared or installed. The app may build its own meanwhile, marked `// PLATFORM-CANDIDATE:` with the link; an interim unit field stores the contract's UN/ECE Rec 20 codes -(`H87`, `KGM`) as option values, the business's spellings as labels. The PR -that ships a row moves it into the tables above. +(`H87`, `KGM`) as option values, the business's spellings as labels. | Concept | State | Contract | |:--|:--|:--| | Units of measure (a standard unit table, organization units, a quantity field with its unit) | **not available** (contract accepted, nothing shipped) | https://github.com/objectstack-ai/objectstack/blob/main/docs/adr/0158-units-of-measure-standard-unit-table-org-units-quantity-unit-declaration-base-quantity.md | -| Working calendars (business days, holidays, SLA clocks) | **not available** (carded, contract in design) | https://github.com/objectstack-ai/objectstack/issues/35340 | +| Working-day formulas | **not available** (contract accepted; no formula reads a calendar yet) | https://github.com/objectstack-ai/objectstack/blob/main/docs/adr/0157-working-calendars-are-org-editable-runtime-data-resolved-by-code-or-refused.md |