@workbench-ai/workbench 0.0.98 → 0.0.99

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -3046,6 +3046,7 @@ async function statusWithCausalNext(status, auth, core, machine) {
3046
3046
  };
3047
3047
  }
3048
3048
  const snapshot = await createWorkbenchReadOnlyInspectionSnapshot(core).catch(() => null);
3049
+ const currentVersionId = status.project.currentVersionId ?? snapshot?.status.currentVersionId ?? snapshot?.refs.current;
3049
3050
  const lastRun = snapshot?.runs
3050
3051
  .slice()
3051
3052
  .sort((left, right) => right.createdAt.localeCompare(left.createdAt))[0];
@@ -3054,8 +3055,11 @@ async function statusWithCausalNext(status, auth, core, machine) {
3054
3055
  }
3055
3056
  const failedRemote = status.remotes.find((remote) => remote.sync.status === "error");
3056
3057
  const hasWorkflowCase = snapshot ? snapshotHasWorkflowCase(snapshot) : false;
3057
- const hasScoredRun = snapshot?.runs.some((run) => scoredRunValue(run) !== undefined) ?? false;
3058
- const canPublish = hasWorkflowCase && hasScoredRun;
3058
+ const hasCurrentScoredProofRun = snapshot?.runs.some((run) => currentVersionId !== undefined &&
3059
+ scoredRunValue(run) !== undefined &&
3060
+ ((run.kind === "eval" && run.versionId === currentVersionId) ||
3061
+ (run.kind === "improve" && run.outputVersionId === currentVersionId))) ?? false;
3062
+ const canPublish = hasWorkflowCase && hasCurrentScoredProofRun;
3059
3063
  const cloudAuthMissing = auth.workbenchCloud.status !== "authenticated";
3060
3064
  const cloudRemoteNeedsAuth = status.remotes.some((remote) => remote.kind === "workbench-cloud" &&
3061
3065
  (remote.sync.status !== "up_to_date" || remote.publication.status === "unpublished"));
@@ -3071,6 +3075,9 @@ async function statusWithCausalNext(status, auth, core, machine) {
3071
3075
  if (!hasWorkflowCase) {
3072
3076
  return { ...status, next: "edit .workbench/cases, then run workbench eval" };
3073
3077
  }
3078
+ if (!hasCurrentScoredProofRun) {
3079
+ return { ...status, next: "workbench eval" };
3080
+ }
3074
3081
  const cloudRemote = status.remotes.find((remote) => remote.kind === "workbench-cloud");
3075
3082
  if (canPublish && !cloudRemote) {
3076
3083
  return { ...status, next: "workbench publish" };
@@ -3081,7 +3088,6 @@ async function statusWithCausalNext(status, auth, core, machine) {
3081
3088
  if (unpublishedCloudRemote) {
3082
3089
  return { ...status, next: "workbench publish" };
3083
3090
  }
3084
- const currentVersionId = status.project.currentVersionId ?? snapshot?.status.currentVersionId ?? snapshot?.refs.current;
3085
3091
  const stalePublishedCloudRemote = status.remotes.find((remote) => remote.kind === "workbench-cloud" &&
3086
3092
  remote.publication.status === "published" &&
3087
3093
  remote.sync.status === "up_to_date" &&
@@ -45,7 +45,7 @@ export async function installSnapshotToStore(options) {
45
45
  const previous = existingHash
46
46
  ? existingHash === contentHash ? "unchanged" : canUpdateExisting ? "updated" : "overwritten"
47
47
  : "none";
48
- if (existingHash && previous === "overwritten" && !options.overwrite) {
48
+ if (!options.dryRun && existingHash && previous === "overwritten" && !options.overwrite) {
49
49
  throw new WorkbenchCodedError("install_failed", `Canonical skill already exists: ${destination}`, {
50
50
  remediation: "Pass --yes to overwrite the existing canonical store skill.",
51
51
  subject: { destination },
@@ -103,7 +103,7 @@ export async function readInstalledSkillsInventory(options = {}) {
103
103
  return {
104
104
  stores,
105
105
  skills,
106
- next: next ? `workbench install ${next}` : skills.length === 0 ? "workbench install OWNER/SKILL" : null,
106
+ next: next ? `workbench install ${next}` : null,
107
107
  };
108
108
  }
109
109
  export function installedInventoryToJson(inventory) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@workbench-ai/workbench",
3
- "version": "0.0.98",
3
+ "version": "0.0.99",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/workbench-ai/workbench.git",
@@ -21,10 +21,10 @@
21
21
  ],
22
22
  "dependencies": {
23
23
  "yaml": "^2.8.2",
24
- "@workbench-ai/workbench-built-in-adapters": "0.0.98",
25
- "@workbench-ai/workbench-protocol": "0.0.98",
26
- "@workbench-ai/workbench-core": "0.0.98",
27
- "@workbench-ai/workbench-contract": "0.0.98"
24
+ "@workbench-ai/workbench-built-in-adapters": "0.0.99",
25
+ "@workbench-ai/workbench-protocol": "0.0.99",
26
+ "@workbench-ai/workbench-core": "0.0.99",
27
+ "@workbench-ai/workbench-contract": "0.0.99"
28
28
  },
29
29
  "devDependencies": {
30
30
  "@tailwindcss/postcss": "^4.2.2",
@@ -35,7 +35,7 @@
35
35
  "react-dom": "^19.2.0",
36
36
  "typescript": "^5.9.2",
37
37
  "vitest": "^3.2.4",
38
- "@workbench-ai/workbench-ui": "0.0.98"
38
+ "@workbench-ai/workbench-ui": "0.0.99"
39
39
  },
40
40
  "scripts": {
41
41
  "build": "rm -rf dist && tsc -p tsconfig.json && chmod 755 dist/workbench.js && node ./scripts/build-dev-open-assets.mjs",