@openclaw/memory-lancedb 2026.7.2-beta.5 → 2026.7.33

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.
@@ -1,4 +1,3 @@
1
- import { isMemoryMachineOutput } from "./cli-output-mode.js";
2
1
  import { definePluginEntry } from "openclaw/plugin-sdk/core";
3
2
  //#region extensions/memory-lancedb/cli-metadata.ts
4
3
  var cli_metadata_default = definePluginEntry({
@@ -9,8 +8,7 @@ var cli_metadata_default = definePluginEntry({
9
8
  api.registerCli(() => {}, { descriptors: [{
10
9
  name: "ltm",
11
10
  description: "Inspect and query LanceDB-backed memory",
12
- hasSubcommands: true,
13
- machineOutput: isMemoryMachineOutput
11
+ hasSubcommands: true
14
12
  }] });
15
13
  }
16
14
  });
package/dist/config.js CHANGED
@@ -1,6 +1,7 @@
1
+ import { parseFiniteNumber } from "openclaw/plugin-sdk/number-runtime";
2
+ import fs from "node:fs";
1
3
  import { homedir } from "node:os";
2
4
  import { join } from "node:path";
3
- import { parseFiniteNumber } from "openclaw/plugin-sdk/number-runtime";
4
5
  //#region extensions/memory-lancedb/config.ts
5
6
  const MEMORY_CATEGORIES = [
6
7
  "preference",
@@ -12,7 +13,22 @@ const MEMORY_CATEGORIES = [
12
13
  const DEFAULT_MODEL = "text-embedding-3-small";
13
14
  const DEFAULT_CAPTURE_MAX_CHARS = 500;
14
15
  const DEFAULT_RECALL_MAX_CHARS = 1e3;
15
- const DEFAULT_DB_PATH = join(homedir(), ".openclaw", "memory", "lancedb");
16
+ const LEGACY_STATE_DIRS = [];
17
+ function resolveDefaultDbPath() {
18
+ const home = homedir();
19
+ const preferred = join(home, ".openclaw", "memory", "lancedb");
20
+ try {
21
+ if (fs.existsSync(preferred)) return preferred;
22
+ } catch {}
23
+ for (const legacy of LEGACY_STATE_DIRS) {
24
+ const candidate = join(home, legacy, "memory", "lancedb");
25
+ try {
26
+ if (fs.existsSync(candidate)) return candidate;
27
+ } catch {}
28
+ }
29
+ return preferred;
30
+ }
31
+ const DEFAULT_DB_PATH = resolveDefaultDbPath();
16
32
  const EMBEDDING_DIMENSIONS = {
17
33
  "text-embedding-3-small": 1536,
18
34
  "text-embedding-3-large": 3072