Skip to content

Commit 5147ad6

Browse files
committed
Merge remote-tracking branch 'origin/main' into claude/sec2-q2gv
2 parents 7a9d7e5 + fc5913e commit 5147ad6

151 files changed

Lines changed: 7578 additions & 734 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
'@objectstack/cloud-connection': patch
3+
---
4+
5+
fix(cloud-connection): an install-local re-install whose installed copy the resolver refuses names that copy, not the incoming package
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
On a re-install, `POST /api/v1/marketplace/install-local` reads the copy its last install stored, to compare the incoming version with it. When this runtime's artifact resolver refuses that stored copy (for example, a package entry that still carries a retired spelling), the answer used to be "Package 'X' cannot be installed: …", which reads as a fault in the incoming package. It now says that the installed copy is refused, that the incoming version was not judged, and what to do: uninstall the package to remove the stored copy, then install this version.
11+
12+
The status and code are unchanged: the resolver's own (for example `422 INVALID_ARTIFACT_PACKAGE_ENTRY`), with its `details` when it states any, and nothing is installed or written. A refusal of the incoming package keeps its "Package 'X' cannot be installed" sentence, and when both copies are refused the incoming package's refusal is the answer.
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
---
2+
'@object-ui/app-shell': patch
3+
---
4+
5+
feat(app-shell): the avatar menu's organization entries follow the deployment posture, and the organization switcher moves into the avatar menu
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
The avatar menu reads the deployment signals the server already serves on `GET /api/v1/auth/config` (`features.multiOrgEnabled`, `features.cloudManaged`, `features.tenancyPosture`) and offers organization entries by them:
11+
12+
- **Single-tenant** (`multiOrgEnabled` false, the `single` posture): no organization entry at all, and no organization switcher. Member management for the one organization stays at Setup → Organization.
13+
- **Multi-organization**: "My Organizations" and "Create organization"; "Switch organization" joins them only when the member belongs to two or more organizations.
14+
- **Cloud-managed** (`cloudManaged` true): no "Create organization"; organizations are created on the cloud there.
15+
16+
A server that serves none of these flags reads the spec's defaults (multi-organization on, not managed), which is the menu as it was.
17+
18+
The organization switcher no longer sits at the left of the top bar, which now holds only the product mark and the app switcher. It is the avatar menu's "Switch organization" submenu. Under the `group` posture it still names the working organization (the write target) and says that views show data from every organization the member belongs to (ADR-0105). On a walled posture (`group` or `isolated`) the top bar still names the active organization, read-only, now at any membership count (before, only at exactly one), so a member of two or more organizations still sees which organization lists are scoped to; the name is also shown under "My Organizations". The switcher's own "Manage members" and "Create organization" items are gone: "My Organizations" and the menu's own create entry lead to the same pages. Inside the ObjectStack mobile shell, the top-bar button that opens the shell's native connection switcher is unchanged.
19+
20+
There is no Setup setting for this menu.
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
'@object-ui/app-shell': patch
3+
'@object-ui/i18n': patch
4+
---
5+
6+
feat(app-shell): Studio's top bar opens the running app, the package switcher hides kernel packages, and the read-only app bar entry shows its text
7+
8+
Clause-②: yes (widening) — locale keys only: three new `@object-ui/i18n` studio keys (`engine.studio.openApp`, `engine.studio.openAppTitle`, `engine.studio.openAppPick`) and the added `{{app}}` variable in `topbar.openAppInStudio`; nothing that worked before is refused
9+
Metadata-protocol: none
10+
11+
- Studio's workbench top bar has an "Open app" button that returns to the package's running app in the same tab. It reads the `?surface=` the workbench has in focus, which is the same target the app bar's Edit app hands Studio. From an object it lands on that object's list in the app. From a dashboard, page or report it lands on that interface. Otherwise it lands on the app's home. When the package has several published apps, the button opens a picker. A package whose only app is still a draft gets no button. Unsaved pillar work asks before leaving, as the Home button does.
12+
- The Studio package switcher no longer lists kernel packages. Before, the rows served with only a top-level `scope` of `system` or `cloud` (such as `sys.env-artifact-cache`) were still listed. ADR-0016 §3.8 keeps kernel packages out of the authoring selector, so there is no toggle to show them. `parsePackages` still returns those rows tagged `kernel`, because the app → Studio entry gate reads the tag.
13+
- In the app bar, the entry for a read-only package shows its text next to the eye: "Open {app} in Studio" (「在 Studio 中查看 {app}」, ADR-0146 D5). Below `sm` it is still not drawn, and the app switcher's Studio row stays the phone's way in.
14+
- New strings `engine.studio.openApp`, `engine.studio.openAppTitle` and `engine.studio.openAppPick` (en, zh). The `topbar.openAppInStudio` text now names the app in every locale.
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
'@object-ui/plugin-chatbot': patch
3+
---
4+
5+
fix(plugin-chatbot): the AI build result card draws the checklist's verification line, and states a failed build once
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
When an AI build fails verification, the result card's `checklist` now carries a `verification` line (`{ kind: 'verification', status: 'failed', label, count }`), and its `status` and `passed/total` follow the verdict. The console dropped that line, so a failed build read "Checks passed 4/5" over four rows. The card now draws it as a red row: the producer's label, then the issue count. A failed checklist is the one place the turn states the failure: the build's draft card no longer draws its "N to fix" chip or the red "fix the problems" sentence beside it. The findings stay behind its Technical details.
11+
12+
A checklist line of any other kind that carries a valid `status` and a string `line` is drawn by those two fields, so a new kind from the producer needs no console change. Lines of the existing kinds draw as before.

‎.changeset/34685-ask-data-skill.md‎

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
---
2+
'@objectstack/skills': patch
3+
---
4+
5+
docs(skills): `objectstack-ask`, a skill for a client that answers business questions over MCP
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
A person who connects Claude Code (or another MCP client) to an ObjectStack app and asks it for a number now has a skill that tells the client how to answer. Until now that procedure was written only in the `list_datasets` tool description and on the page at `GET /mcp/skill`, and a client does not reliably read either before it picks a tool.
11+
12+
The new skill `objectstack-ask` is for the connected client, not for a developer writing queries in code. It gives the steps in order:
13+
14+
- Lift the business words of the question and call `list_datasets` with them as `terms`, in the user's own words and language.
15+
- Decide by `matches`. A word matches only when it equals a member's name, label or synonym (case, spacing, `_` and `-` aside), never by similarity. One measure match is computed with `query_dataset`, and the source is cited from the answer's `provenance`. Several matches are a question for the user. A dimension match alone is not an answer.
16+
- When nothing matches but the word is a loose form of several listed measures (a bare "revenue" beside Won Revenue, Annual Revenue and Planned Revenue), ask which one is meant and compute nothing yet.
17+
- Otherwise fall back to `aggregate_records` / `query_records`, and open the answer with a line saying it is not from a governed metric (非指标口径).
18+
- `membersWithheld: true` is reported as measures the user may not read, never as a metric that does not exist.
19+
- When no metric, object or field records what the question needs, say what is missing. Never answer from an assumed value.
20+
21+
`objectstack-ai` and `objectstack-query`'s aggregation rules each gain one line pointing to it. Install or update the catalog as before (`@objectstack/skills`, then the sync); nothing else changes.
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
'@objectstack/scenarios': patch
3+
---
4+
5+
feat(scenarios): an opt-in skills directory for ask turns, and dataset questions on two open cards
6+
7+
Clause-②: yes (widening) — new CLI flag `--ask-skills` on `objectstack-scenarios run` / `run-scenarios`; the card schema accepts the optional keys `expect.datasets` and `run.datasetQuestions`, with new exports `DatasetExpectationSchema`, `DatasetMeasureExpectationSchema`, `DatasetDimensionExpectationSchema`, `DATASET_MEASURE_AGGREGATES`, `DatasetMemberRefSchema`, `DATASET_QUESTION_KINDS`, `DatasetExpectedRouteSchema`, `DatasetQuestionSchema` and the types `DatasetExpectation`, `DatasetQuestionKind`, `DatasetExpectedRoute`, `DatasetQuestion`, and new optional fields `ScenarioExpect.datasets` and `ScenarioCard['run'].datasetQuestions` (`.`); new exports `EvalGraphDataset` and `EvalGraphDatasetMember`, and `EvalGraph.datasets` items gaining optional `object` and `members` (`./score`, `./score/full`); new exports `DATASET_GRADERS`, `OBJECT_QUERY_TOOLS`, `statedFigures`, `labelsFallback`, `gradeDatasetQuestion`, `gradeCardDatasetQuestion` and the types `DatasetGrader`, `DatasetGrade` (`./score/full` only); new exports `datasetLines`, `datasetQuestionPrompt`, `datasetTally` and `DatasetQuestionResult`, new optional fields `ClaudeCodeDriverOptions.askSkillsDir`, `DriverInfo.askSkills`, `RunHalf.datasetQuestions` and `HalfScores.datasets`, and `TABLE_DIMENSIONS` gaining `'ask skills'` (all `./runner`). `scoreGraph` (`./score`, `./score/full`) and `scoreScenarioArtifact` (`./score/full`) answer differently on a card that declares datasets: they add `dataset:` and `dataset-measure|dimension:` checks, so that card's Build total grows; `scoreCardArtifact` (`./score/full`) answers with those checks too, and `artifactToEvalGraph` (`./score`, `./score/full`) reads each dataset's `object` and every measure's and dimension's `synonyms` and `description` into the graph it returns. `DriverInfo.askSkills` is typed by `AskSkillsInfo`, which carries no exported name.
8+
Metadata-protocol: none
9+
10+
- **`--ask-skills DIR`** (live `claude` driver only, off by default) places one skill directory, or a directory of them, at `.claude/skills/NAME/` in every question and operation turn's working directory and allows the `Skill` tool beside `mcp__app`. Authoring turns never see them. The record's driver states which skills the turns had: per skill its name, the sha256 of its files, and the front-matter `version` when it has one. `summary` refuses to sum runs with different skills. Off, the turn's arguments and the record are unchanged. A skill cannot widen the turn: a `SKILL.md` (nested ones too) whose front matter carries a key outside `name`, `description`, `version`, `license`, `compatibility`, `metadata`, `when_to_use`, `argument-hint`, `user-invocable` and `disable-model-invocation` (so `allowed-tools`, `model`, `effort`, `hooks`, `context`, `agent` and any other) is refused when the directory is read, before any turn runs, as is a front matter the runner cannot read for certain.
11+
- **Dataset questions.** A card may declare `expect.datasets` (measures with synonyms and descriptions) and `run.datasetQuestions` of three kinds: `metric_selected`, `asked_back` (ambiguous or near-miss) and `fallback_labelled`. The loader holds each word to what the datasets declare, and checks each dataset with the platform's `DatasetSchema`. The Build half checks the datasets. The Run half asks the questions and grades the route each answer took (`metric-selected`, `asked-back`, `fallback-labelled`) on a new `Run · datasets` scorecard row. Replaying a recording that holds no turn for a dataset question (one made before its card declared them) records that ask as not measured, never as failed.
12+
- `order_to_cash` and `travel_expense` carry datasets and five dataset questions each.
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
---
2+
'@object-ui/i18n': patch
3+
---
4+
5+
feat(console): the Studio landing lists every change this environment made to its installed apps in one panel
6+
7+
Clause-②: yes (widening)
8+
Metadata-protocol: none
9+
10+
The Studio landing gains a **Customizations in this environment** panel under the installed apps, so "what did we change here" no longer means opening each app.
11+
12+
- One row per change, read from each installed app's customization read (`GET /api/v1/packages/:id/customizations`, the read its card already makes): items the app's customization package overrides read **Changed**, fields, validation rules and indexes it adds read **Added**, the app's items switched off in this environment read **Switched off**. What other packages contribute is not this environment's change and makes no row.
13+
- Each row names the item (its label where the app's list gives one, else its name), its kind and its app, and opens it in Studio.
14+
- Tabs narrow the list (All, New fields, Forms and views, Flows, Switched off), a search narrows it by text, and the rows can be grouped by app. The first six rows show; the rest are behind "Show all".
15+
- The panel's total equals the cards' "customized" plus "switched off": one read per app now serves both the card and the panel.
16+
- With no change anywhere the panel is one line. An app whose read fails (a 403 included) is named as unreadable, never counted as 0.
17+
18+
New keys under `engine.studio.landing.envCustomizations.*` in the studio namespace (en, zh). No server change.
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
'@object-ui/plugin-chatbot': patch
3+
---
4+
5+
fix(plugin-chatbot): a reloaded answer draws a redrawn chart once, not once per draw
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
When the model redraws a chart in one answer, the live stream replaces the chart in place, so the answer shows one chart. After a reload the chat rebuilds an answer's charts from its stored `visualize_data` results, one per draw, and the replaced chart came back beside the one that replaced it.
11+
12+
The history reader (`chartsFromParts` and the message mapper) now reads the `chartId` a `visualize_data` result carries at the top level of its envelope, beside `chart`. Within one message, results that share a `chartId` give one chart: the last result's chart, at the place in the text where the first one sat. A result without a `chartId` (older history, other producers) is read exactly as before, and results are never merged across messages, because a `chartId` is unique only within one request. A message that carries `data-chart` parts (the live stream) is unchanged.
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
'@object-ui/console': patch
3+
---
4+
5+
fix(console): the setup checklist reads a host's own mail transport as delivering
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
`GET /api/settings/mail` states a transport that the host hands over, which no provider option names, as `live.provider = { value: null, source: 'environment' }`. The settings contract says in-use is read from `source`, never from a `null` value. The first-run checklist still required a non-empty `value`, so on a hosted environment its Email delivery row stayed not done while mail was being delivered. This included a deployment whose saved mail values would pass on their own.
11+
12+
The checklist now reads in-use from `source`. `environment` with a `null` value is in use, `none` is not, and a page without the statement still falls back to the saved mail values. The built-in AI row follows the same rule. If the server ever states its provider as `environment` with a `null` value, the row is done, keeps the `environment` source and says the platform manages the provider, because there is no option name to show.
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
---
2+
'@objectstack/spec': minor
3+
---
4+
5+
feat(spec): the `list_datasets` output declares `candidates`, the members offered for a clarifying question when a term matched nothing (ADR-0149 D3)
6+
7+
Clause-②: yes (widening — an optional output field on a published schema)
8+
Metadata-protocol: added
9+
Skills-docs: follow-up owed — skills/objectstack-ask/SKILL.md (zero-match row reads candidates once #34763 lands)
10+
11+
`ListDatasetsOutputSchema` (`@objectstack/spec/ai`) gains one optional member, `candidates`, with its entry schema `DatasetTermCandidateSchema` (type `DatasetTermCandidate`) and the per-term cap `LIST_DATASETS_MAX_CANDIDATES_PER_TERM` (5). Nothing is removed or renamed, and an answer without the key parses as it did.
12+
13+
- **What it is.** For a term the caller sent that matched no member of any listed dataset, the members the platform offers as possible readings. Each entry is a pointer `{ term, dataset, member }` to a member listed in the same answer: `dataset` is a `datasets[].name`, `member` is `measures.<name>` or `dimensions.<name>`. Only members the caller may read are offered. The label, dataset label and description a clarifying question lists are read from that `datasets` entry.
14+
- **What it is not.** A candidate is not a match. `matches`, and what counts as a match (equality after normalization, ADR-0149 D3 rule 1), are unchanged, and an entry carries no `matchedOn`. The platform selects none of them. The list carries no score, and its order is the listing order: terms as sent, datasets as listed, a dataset's measures before its dimensions, at most five per term.
15+
- **When it is present.** Only when `terms` were sent and a term that matched nothing has a candidate. No candidates is the key's absence: an empty list does not parse. A term with a match has none.
16+
- **Who fills it.** This change declares the shape only, and the tool's `outputSchema` (`getDatasetToolJsonSchemas().list_datasets.outputSchema`) lists the member from it. Filling the list is the `list_datasets` executor's change in `@objectstack/service-analytics`, which ships under its own entry; an answer carries `candidates` only from a release that has both.
17+
18+
ADR-0149 D3 gains an add-only amendment note recording the ruling: a term with no match and with candidates is asked about in rule 3's form and none is acted on; with no candidate, rule 4's fallback is unchanged.
19+
20+
Level: `minor` for `@objectstack/spec`, the level `Metadata-protocol: added` takes. The `authorable-surface/ai.json` baseline records the new keys: `ai/ListDatasetsOutput:candidates` and the three `ai/DatasetTermCandidate` members.

0 commit comments

Comments
 (0)