@memtensor/memos-cloud-openclaw-plugin 0.1.16-beta.0 → 0.1.16
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/clawdbot.plugin.json +1 -1
- package/index.js +8 -3
- package/moltbot.plugin.json +1 -1
- package/openclaw.plugin.json +1 -1
- package/package.json +1 -1
package/clawdbot.plugin.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"id": "memos-cloud-openclaw-plugin",
|
|
3
3
|
"name": "MemOS Cloud OpenClaw Plugin",
|
|
4
4
|
"description": "MemOS Cloud recall + add memory via lifecycle hooks",
|
|
5
|
-
"version": "0.1.16
|
|
5
|
+
"version": "0.1.16",
|
|
6
6
|
"kind": "lifecycle",
|
|
7
7
|
"main": "./index.js",
|
|
8
8
|
"activation": {
|
package/index.js
CHANGED
|
@@ -32,15 +32,20 @@ const MEMOS_SOURCE = "openclaw";
|
|
|
32
32
|
// when a legitimate user message happens to mention these phrases.
|
|
33
33
|
const HEARTBEAT_PROMPT_PATTERN =
|
|
34
34
|
/^\s*(?:Read HEARTBEAT\.md if it exists\b|\[OpenClaw heartbeat poll\])/i;
|
|
35
|
-
const SYSTEM_COMMAND_PATTERN = /^\/(?:new|reset|stop|status|help|dock_|undock)\b/i;
|
|
35
|
+
const SYSTEM_COMMAND_PATTERN = /^\/(?:new|reset|clear|stop|status|help|dock_|undock)\b/i;
|
|
36
|
+
const INTERNAL_SYSTEM_PROMPT_PATTERNS = [
|
|
37
|
+
/^A new session was started via \/new or \/reset\./i,
|
|
38
|
+
/^Based on this conversation, generate a short 1-2 word filename slug\b[\s\S]*\bReply with ONLY the slug\b/i,
|
|
39
|
+
];
|
|
36
40
|
|
|
37
41
|
function isHeartbeatPrompt(text) {
|
|
38
42
|
return typeof text === "string" && HEARTBEAT_PROMPT_PATTERN.test(text);
|
|
39
43
|
}
|
|
40
44
|
|
|
41
|
-
function isSystemCommandPrompt(text) {
|
|
45
|
+
export function isSystemCommandPrompt(text) {
|
|
42
46
|
if (typeof text !== "string") return false;
|
|
43
|
-
|
|
47
|
+
const prompt = text.trimStart();
|
|
48
|
+
return SYSTEM_COMMAND_PATTERN.test(prompt) || INTERNAL_SYSTEM_PROMPT_PATTERNS.some((pattern) => pattern.test(prompt));
|
|
44
49
|
}
|
|
45
50
|
|
|
46
51
|
function warnMissingApiKey(log, context) {
|
package/moltbot.plugin.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"id": "memos-cloud-openclaw-plugin",
|
|
3
3
|
"name": "MemOS Cloud OpenClaw Plugin",
|
|
4
4
|
"description": "MemOS Cloud recall + add memory via lifecycle hooks",
|
|
5
|
-
"version": "0.1.16
|
|
5
|
+
"version": "0.1.16",
|
|
6
6
|
"kind": "lifecycle",
|
|
7
7
|
"main": "./index.js",
|
|
8
8
|
"activation": {
|
package/openclaw.plugin.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"id": "memos-cloud-openclaw-plugin",
|
|
3
3
|
"name": "MemOS Cloud OpenClaw Plugin",
|
|
4
4
|
"description": "MemOS Cloud recall + add memory via lifecycle hooks",
|
|
5
|
-
"version": "0.1.16
|
|
5
|
+
"version": "0.1.16",
|
|
6
6
|
"kind": "lifecycle",
|
|
7
7
|
"main": "./index.js",
|
|
8
8
|
"activation": {
|
package/package.json
CHANGED