@camstack/addon-agent-ui 1.1.2 → 1.1.4
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/addon.js +18 -9
- package/package.json +1 -1
package/dist/addon.js
CHANGED
|
@@ -4629,7 +4629,7 @@ function _instanceof(cls, params = {}) {
|
|
|
4629
4629
|
return inst;
|
|
4630
4630
|
}
|
|
4631
4631
|
//#endregion
|
|
4632
|
-
//#region ../types/dist/sleep-
|
|
4632
|
+
//#region ../types/dist/sleep-_J5S7OEP.mjs
|
|
4633
4633
|
var EventCategory = /* @__PURE__ */ function(EventCategory) {
|
|
4634
4634
|
EventCategory["SystemBoot"] = "system.boot";
|
|
4635
4635
|
EventCategory["SystemAddonsReady"] = "system.addons-ready";
|
|
@@ -5744,15 +5744,24 @@ var BaseAddon = class {
|
|
|
5744
5744
|
} catch {}
|
|
5745
5745
|
}
|
|
5746
5746
|
/**
|
|
5747
|
-
* Resolve the shared models directory
|
|
5748
|
-
*
|
|
5749
|
-
*
|
|
5747
|
+
* Resolve the shared, node-local models directory: `<nodeDataDir>/models`.
|
|
5748
|
+
*
|
|
5749
|
+
* This is the SINGLE centralized models-dir resolver for every inference addon
|
|
5750
|
+
* (detection-pipeline, audio-analyzer, embedding-encoder, model-studio). It is
|
|
5751
|
+
* anchored at the node's own writable data root (`ctx.nodeDataDir`, i.e.
|
|
5752
|
+
* `CAMSTACK_DATA` ?? the kernel boot dir) — never the hub-singleton `storage`
|
|
5753
|
+
* cap, which returns the hub's `/data/models` to every node and breaks any node
|
|
5754
|
+
* whose real data dir differs (e.g. the macOS electron agent).
|
|
5755
|
+
*
|
|
5756
|
+
* `node:path`/`node:fs` are imported dynamically so the `@camstack/types` root
|
|
5757
|
+
* barrel (re-exported into browser bundles) stays free of node builtins.
|
|
5750
5758
|
*/
|
|
5751
5759
|
async resolveModelsDir() {
|
|
5752
|
-
|
|
5753
|
-
|
|
5754
|
-
|
|
5755
|
-
|
|
5760
|
+
const { join } = await import("node:path");
|
|
5761
|
+
const { promises: fsp } = await import("node:fs");
|
|
5762
|
+
const dir = join(this.ctx.nodeDataDir, "models");
|
|
5763
|
+
await fsp.mkdir(dir, { recursive: true });
|
|
5764
|
+
return dir;
|
|
5756
5765
|
}
|
|
5757
5766
|
/**
|
|
5758
5767
|
* Access the runtime capability registry for in-process provider lookups.
|
|
@@ -21023,7 +21032,7 @@ var AgentUIAddon = class extends BaseAddon {
|
|
|
21023
21032
|
capability: adminUiCapability,
|
|
21024
21033
|
provider: {
|
|
21025
21034
|
getStaticDir: async () => ({ staticDir: path.resolve(__dirname) }),
|
|
21026
|
-
getVersion: async () => ({ version: "1.1.
|
|
21035
|
+
getVersion: async () => ({ version: "1.1.4" })
|
|
21027
21036
|
}
|
|
21028
21037
|
}];
|
|
21029
21038
|
}
|