@askexenow/exe-os 0.8.89 → 0.8.90

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/bin/cli.js CHANGED
@@ -12363,7 +12363,33 @@ function ask2(rl, prompt) {
12363
12363
  doAsk();
12364
12364
  });
12365
12365
  }
12366
+ function getAvailableMemoryGB() {
12367
+ return os11.freemem() / (1024 * 1024 * 1024);
12368
+ }
12369
+ function getTotalMemoryGB() {
12370
+ return os11.totalmem() / (1024 * 1024 * 1024);
12371
+ }
12372
+ function isLowMemory() {
12373
+ return getAvailableMemoryGB() < 2;
12374
+ }
12366
12375
  async function validateModel(log) {
12376
+ const totalGB = getTotalMemoryGB();
12377
+ const freeGB = getAvailableMemoryGB();
12378
+ if (totalGB <= 8 || isLowMemory()) {
12379
+ log(`System memory: ${totalGB.toFixed(0)}GB total, ${freeGB.toFixed(1)}GB free`);
12380
+ log("Skipping in-memory model validation (low memory \u2014 will validate on first use).");
12381
+ const modelPath = path28.join(MODELS_DIR, LOCAL_FILENAME);
12382
+ if (existsSync23(modelPath)) {
12383
+ const { statSync: statSync2 } = await import("fs");
12384
+ const size = statSync2(modelPath).size;
12385
+ if (size > 300 * 1e6) {
12386
+ log(`Model file verified (${(size / 1e6).toFixed(0)} MB).`);
12387
+ return;
12388
+ }
12389
+ throw new Error(`Model file too small (${(size / 1e6).toFixed(0)} MB) \u2014 may be corrupted. Delete and re-run setup.`);
12390
+ }
12391
+ throw new Error("Model file not found after download.");
12392
+ }
12367
12393
  log("Validating model...");
12368
12394
  const { embedDirect: embedDirect2 } = await Promise.resolve().then(() => (init_embedder(), embedder_exports));
12369
12395
  const result = await embedDirect2("test embedding");
@@ -12555,6 +12581,15 @@ async function runSetupWizard(opts = {}) {
12555
12581
  log("");
12556
12582
  if (!state.completedSteps.includes(3)) {
12557
12583
  if (!skipModel) {
12584
+ const freeGB = getAvailableMemoryGB();
12585
+ const totalGB = getTotalMemoryGB();
12586
+ if (freeGB < 2) {
12587
+ log(`\u26A0 Low memory detected: ${freeGB.toFixed(1)}GB free of ${totalGB.toFixed(0)}GB total`);
12588
+ log(" Close other applications (browser, Slack, etc.) before continuing.");
12589
+ log(" The embedding model needs ~500MB to download and load.");
12590
+ log("");
12591
+ await ask2(rl, "Press Enter when ready, or Ctrl+C to abort and free memory first: ");
12592
+ }
12558
12593
  log("Note: jina-embeddings-v5-text-small is licensed CC-BY-NC-4.0 (non-commercial)");
12559
12594
  log("");
12560
12595
  await downloadModel({
package/dist/bin/setup.js CHANGED
@@ -5753,7 +5753,33 @@ function ask(rl, prompt) {
5753
5753
  doAsk();
5754
5754
  });
5755
5755
  }
5756
+ function getAvailableMemoryGB() {
5757
+ return os4.freemem() / (1024 * 1024 * 1024);
5758
+ }
5759
+ function getTotalMemoryGB() {
5760
+ return os4.totalmem() / (1024 * 1024 * 1024);
5761
+ }
5762
+ function isLowMemory() {
5763
+ return getAvailableMemoryGB() < 2;
5764
+ }
5756
5765
  async function validateModel(log) {
5766
+ const totalGB = getTotalMemoryGB();
5767
+ const freeGB = getAvailableMemoryGB();
5768
+ if (totalGB <= 8 || isLowMemory()) {
5769
+ log(`System memory: ${totalGB.toFixed(0)}GB total, ${freeGB.toFixed(1)}GB free`);
5770
+ log("Skipping in-memory model validation (low memory \u2014 will validate on first use).");
5771
+ const modelPath = path11.join(MODELS_DIR, LOCAL_FILENAME);
5772
+ if (existsSync11(modelPath)) {
5773
+ const { statSync: statSync2 } = await import("fs");
5774
+ const size = statSync2(modelPath).size;
5775
+ if (size > 300 * 1e6) {
5776
+ log(`Model file verified (${(size / 1e6).toFixed(0)} MB).`);
5777
+ return;
5778
+ }
5779
+ throw new Error(`Model file too small (${(size / 1e6).toFixed(0)} MB) \u2014 may be corrupted. Delete and re-run setup.`);
5780
+ }
5781
+ throw new Error("Model file not found after download.");
5782
+ }
5757
5783
  log("Validating model...");
5758
5784
  const { embedDirect: embedDirect2 } = await Promise.resolve().then(() => (init_embedder(), embedder_exports));
5759
5785
  const result = await embedDirect2("test embedding");
@@ -5945,6 +5971,15 @@ async function runSetupWizard(opts = {}) {
5945
5971
  log("");
5946
5972
  if (!state.completedSteps.includes(3)) {
5947
5973
  if (!skipModel2) {
5974
+ const freeGB = getAvailableMemoryGB();
5975
+ const totalGB = getTotalMemoryGB();
5976
+ if (freeGB < 2) {
5977
+ log(`\u26A0 Low memory detected: ${freeGB.toFixed(1)}GB free of ${totalGB.toFixed(0)}GB total`);
5978
+ log(" Close other applications (browser, Slack, etc.) before continuing.");
5979
+ log(" The embedding model needs ~500MB to download and load.");
5980
+ log("");
5981
+ await ask(rl, "Press Enter when ready, or Ctrl+C to abort and free memory first: ");
5982
+ }
5948
5983
  log("Note: jina-embeddings-v5-text-small is licensed CC-BY-NC-4.0 (non-commercial)");
5949
5984
  log("");
5950
5985
  await downloadModel({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@askexenow/exe-os",
3
- "version": "0.8.89",
3
+ "version": "0.8.90",
4
4
  "description": "AI employee operating system — persistent memory, task management, and multi-agent coordination for Claude Code.",
5
5
  "license": "CC-BY-NC-4.0",
6
6
  "type": "module",