diff --git a/.changeset/24456-client-platform-objects-this-system.md b/.changeset/24456-client-platform-objects-this-system.md new file mode 100644 index 00000000000..74a040b4c68 --- /dev/null +++ b/.changeset/24456-client-platform-objects-this-system.md @@ -0,0 +1,13 @@ +--- +'@objectstack/client': patch +'@objectstack/platform-objects': patch +--- + +Clause-②: no + +fix(client,platform-objects): the `ai.models()` TSDoc and the translated permission-set `packageId` help say "this system", as the spec now does + +- **What changed.** Inside the running system, published copy names the system the reader is in as "this system", and a permission set made here, not shipped by a package, is "authored in this system". `@objectstack/spec` already says both (`AiModelsResponse.models`, the permission set's `packageId` help text); this follows it in two more places. + - The TSDoc of `client.ai.models()` now reads "Models this system offers in the chat model picker (cloud ADR-0028)". The citation is qualified as `cloud ADR-0028`: the AI service that serves this list is a cloud package, and this repository's ADR-0028 is about metadata naming. + - The zh-CN, ja-JP and es-ES values of the permission set's `packageId` help text in the Setup forms bundle now say 本系统 / このシステム / este sistema where they said 本环境 / この環境 / este entorno, matching the English text "Leave empty for a set authored in this system." +- **Unchanged.** Every method, route, type, form field, key and behaviour. No translation key is added or removed. diff --git a/content/docs/api/client-sdk.mdx b/content/docs/api/client-sdk.mdx index 3201261d11e..0a6ade78f5e 100644 --- a/content/docs/api/client-sdk.mdx +++ b/content/docs/api/client-sdk.mdx @@ -392,7 +392,7 @@ for await (const frame of await client.ai.chatStream({ messages })) { } await client.ai.complete({ prompt: 'Summarise this account in one line:' }); -await client.ai.models(); // plan-filtered picker list (ADR-0028) +await client.ai.models(); // plan-filtered picker list (cloud ADR-0028) // Conversations — all six routes, scoped to the authenticated user server-side. const conv = await client.ai.conversations.create({ title: 'Q3 pipeline' }); diff --git a/content/docs/api/plugin-endpoints.mdx b/content/docs/api/plugin-endpoints.mdx index a136708cbd4..a3133433fac 100644 --- a/content/docs/api/plugin-endpoints.mdx +++ b/content/docs/api/plugin-endpoints.mdx @@ -109,7 +109,7 @@ These are the routes `service-ai` mounts, and the SDK method that reaches each: | POST | `/ai/chat` | `ai.chat` / `ai.chatStream` | Chat completion — JSON with `stream: false`, otherwise the Vercel UI Message Stream | | POST | `/ai/chat/stream` | — | Generic-SSE twin of `/ai/chat`: the same completion without the tool loop or persistence | | POST | `/ai/complete` | `ai.complete` | Text completion | -| GET | `/ai/models` | `ai.models` | Models this environment offers (ADR-0028) | +| GET | `/ai/models` | `ai.models` | Models this system offers (cloud ADR-0028) | | GET | `/ai/status` | — | Active adapter provenance (console diagnostics) | | GET | `/ai/effective-model` | — | Resolved model ids and their source (console diagnostics) | | POST / GET | `/ai/conversations` | `ai.conversations.create` / `.list` | Create / list conversations — the list is newest first and pages by keyset: send the `id` of the last conversation you hold as `cursor`, and read `hasMore` to learn whether another page follows | diff --git a/content/docs/permissions/authentication.mdx b/content/docs/permissions/authentication.mdx index 45519310aeb..fdd2cfd2f45 100644 --- a/content/docs/permissions/authentication.mdx +++ b/content/docs/permissions/authentication.mdx @@ -249,7 +249,7 @@ console.log('Current user:', session.data.user); ### First-run bootstrap status `GET /api/v1/auth/bootstrap-status` answers one question — is the admission gate's -bootstrap window open, i.e. does this environment have no **human** user yet? Service +bootstrap window open, i.e. does this system have no **human** user yet? Service rows (such as the legacy `usr_system` row) do not count. ```typescript @@ -265,8 +265,7 @@ creation); `client.auth.bootstrapStatus()` is the SDK method that builds it. It **fails open**: if no data engine is wired, or the count query throws, it answers `{ "hasOwner": true }` so a client falls through to the ordinary login -flow rather than offering to create an owner on an environment that may already -have one. +flow rather than offering to create an owner when one may already exist. This route is unauthenticated, so treat `hasOwner: false` as a hint to render a @@ -310,7 +309,7 @@ const response = await fetch('http://localhost:3000/api/v1/auth/reset-password', signed-in user who has no credential account yet — the account was onboarded through SSO, through the cloud OAuth provider, or imported with `passwordPolicy: 'none'`. It gives that user an email/password way in to this -environment without the SSO round-trip. +system without the SSO round-trip. ```typescript const response = await fetch('http://localhost:3000/api/v1/auth/set-initial-password', { @@ -1122,7 +1121,7 @@ All endpoints are available under `/api/v1/auth/*`: #### Session - `GET /api/v1/auth/get-session` - Get current user session -- `GET /api/v1/auth/bootstrap-status` - Public, unauthenticated first-run probe: `{ "hasOwner": boolean }`, telling a client whether the admission gate's bootstrap window is still open — i.e. whether this environment has no human user yet ([details](#first-run-bootstrap-status)) +- `GET /api/v1/auth/bootstrap-status` - Public, unauthenticated first-run probe: `{ "hasOwner": boolean }`, telling a client whether the admission gate's bootstrap window is still open — i.e. whether this system has no human user yet ([details](#first-run-bootstrap-status)) #### Password Management diff --git a/content/docs/permissions/permission-sets.mdx b/content/docs/permissions/permission-sets.mdx index 0cea9d2391c..84ec96ec1ec 100644 --- a/content/docs/permissions/permission-sets.mdx +++ b/content/docs/permissions/permission-sets.mdx @@ -366,7 +366,7 @@ or uninstall, and every other `/packages` write verb refuse any other caller ## One authoritative store — the definition (ADR-0094 D1, ADR-0131 D3) A permission-set **definition** has a single authoritative store: the metadata -layer — a package's declaration, or a definition authored in this environment +layer — a package's declaration, or a definition authored in this system and saved in `sys_metadata` — served by name from the security catalog. Nothing mirrors it into a row: the `sys_permission_set` record ADR-0094 kept as a projection is retired, its object is no longer registered, and no data @@ -377,22 +377,22 @@ goes through the metadata door (`PUT` or `DELETE /api/v1/meta/permission/:name`) which requires `manage_metadata` — and, under a `group` or `isolated` tenancy posture, the platform operator. This has three author-visible consequences: -- **A set shipped in code cannot be edited in the environment.** That is a set +- **A set shipped in code cannot be edited in this system.** That is a set an installed package declares (a `*.permission.ts` file, a stack's `permissionSets`) or a platform default such as `member_default`. Editing it through Setup or the metadata API answers `403 NOT_OVERRIDABLE` and stores nothing. Clone it to a new name instead (the **Clone** action on the set, or the clone door below) and edit the clone: the clone is your organization's own set, and package upgrades keep reaching - the original. Every other set (one created in this environment, a clone, or + the original. Every other set (one authored in this system, a clone, or one saved into a writable runtime package) is edited in place: the edit lands on its one stored definition. - **The API name is immutable after creation.** It is the definition's metadata identity, and the metadata door addresses the set by it, so there is no rename. Clone the set to a new name instead. -- **A delete depends on where the definition lives.** A set you created in this - environment is removed. A set that ships with an installed package/app cannot - be removed from the environment: its definition stays served from the +- **A delete depends on where the definition lives.** A set authored in this + system is removed. A set that ships with an installed package/app cannot + be removed from this system: its definition stays served from the package. Uninstall the owning package to remove a packaged set entirely. An older database keeps the `sys_permission_set` table and its rows, and @@ -419,7 +419,7 @@ POST /api/v1/security/permission-sets/:name/clone body: { "name": "...", "lab The clone door copies a set's whole definition under a new machine name. It reads the source from the security catalog, where every packaged and environment-authored set lives. It saves the copy through the metadata layer -as a set authored in this environment: no package, and no link back to the set +as a set authored in this system: no package, and no link back to the set it was copied from, so changes to the source never reach the copy. - **The body is `{ name, label }`, both required, and nothing else.** `name` is diff --git a/packages/client/src/index.ts b/packages/client/src/index.ts index 363e5685dfd..cefb869bf8f 100644 --- a/packages/client/src/index.ts +++ b/packages/client/src/index.ts @@ -6699,7 +6699,7 @@ export class ObjectStackClient { }, /** - * Models this environment offers in the chat model picker (ADR-0028) — + * Models this system offers in the chat model picker (cloud ADR-0028) — * plan-filtered, with the default flagged. Populate a model picker from * this rather than hard-coding ids. */ diff --git a/packages/platform-objects/src/apps/translations/es-ES.metadata-forms.generated.ts b/packages/platform-objects/src/apps/translations/es-ES.metadata-forms.generated.ts index 9d949a4f2aa..ef1f0390bfa 100644 --- a/packages/platform-objects/src/apps/translations/es-ES.metadata-forms.generated.ts +++ b/packages/platform-objects/src/apps/translations/es-ES.metadata-forms.generated.ts @@ -2334,7 +2334,7 @@ export const esESMetadataForms: NonNullable = }, packageId: { label: "ID de paquete", - helpText: "El paquete que distribuye este conjunto; un valor que nombra otro paquete se rechaza. Déjalo vacío para un conjunto creado en este entorno." + helpText: "El paquete que distribuye este conjunto; un valor que nombra otro paquete se rechaza. Déjalo vacío para un conjunto creado en este sistema." }, systemPermissions: { label: "Permisos del sistema", diff --git a/packages/platform-objects/src/apps/translations/ja-JP.metadata-forms.generated.ts b/packages/platform-objects/src/apps/translations/ja-JP.metadata-forms.generated.ts index 6ebf3e6bd23..3ed361a909d 100644 --- a/packages/platform-objects/src/apps/translations/ja-JP.metadata-forms.generated.ts +++ b/packages/platform-objects/src/apps/translations/ja-JP.metadata-forms.generated.ts @@ -2334,7 +2334,7 @@ export const jaJPMetadataForms: NonNullable = }, packageId: { label: "所属パッケージ ID", - helpText: "このセットを同梱しているパッケージです。別のパッケージを指す値は拒否されます。この環境で作成したセットでは空のままにします。" + helpText: "このセットを同梱しているパッケージです。別のパッケージを指す値は拒否されます。このシステムで作成したセットでは空のままにします。" }, systemPermissions: { label: "システム権限", diff --git a/packages/platform-objects/src/apps/translations/zh-CN.metadata-forms.generated.ts b/packages/platform-objects/src/apps/translations/zh-CN.metadata-forms.generated.ts index 94a43feecf3..f196125ca1f 100644 --- a/packages/platform-objects/src/apps/translations/zh-CN.metadata-forms.generated.ts +++ b/packages/platform-objects/src/apps/translations/zh-CN.metadata-forms.generated.ts @@ -2334,7 +2334,7 @@ export const zhCNMetadataForms: NonNullable = }, packageId: { label: "所属包 ID", - helpText: "分发这个权限集的包;填写其他包的 id 会被拒绝。在本环境中创建的权限集请留空。" + helpText: "分发这个权限集的包;填写其他包的 id 会被拒绝。在本系统中创建的权限集请留空。" }, systemPermissions: { label: "系统权限",