mr-memory 1.0.2 → 1.0.3
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/index.ts +7 -1
- package/package.json +1 -1
- package/upload.ts +1 -1
package/index.ts
CHANGED
|
@@ -188,7 +188,13 @@ const memoryRouterPlugin = {
|
|
|
188
188
|
const os = await import("node:os");
|
|
189
189
|
const path = await import("node:path");
|
|
190
190
|
const stateDir = opts.brain ? path.resolve(opts.brain) : path.join(os.homedir(), ".openclaw");
|
|
191
|
-
|
|
191
|
+
// Use OpenClaw's configured workspace, not cwd
|
|
192
|
+
const configWorkspace = api.config.workspace || api.config.agents?.defaults?.workspace;
|
|
193
|
+
const workspacePath = opts.workspace
|
|
194
|
+
? path.resolve(opts.workspace)
|
|
195
|
+
: configWorkspace
|
|
196
|
+
? path.resolve(configWorkspace.replace(/^~/, os.homedir()))
|
|
197
|
+
: path.join(os.homedir(), ".openclaw", "workspace");
|
|
192
198
|
const { runUpload } = await import("./upload.js");
|
|
193
199
|
await runUpload({
|
|
194
200
|
memoryKey,
|
package/package.json
CHANGED
package/upload.ts
CHANGED
|
@@ -319,7 +319,7 @@ export async function runUpload(params: {
|
|
|
319
319
|
}
|
|
320
320
|
}
|
|
321
321
|
|
|
322
|
-
console.log(`\n✅ ${totalProcessed}
|
|
322
|
+
console.log(`\n✅ ${totalProcessed} memories stored in vault`);
|
|
323
323
|
if (totalFailed > 0) {
|
|
324
324
|
console.log(`⚠️ ${totalFailed} failed (${((totalFailed / (totalProcessed + totalFailed)) * 100).toFixed(0)}%)`);
|
|
325
325
|
}
|