@memorilabs/openclaw-memori 0.0.12 → 0.0.13
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/index.js +5 -4
- package/dist/tools/index.d.ts +2 -1
- package/dist/tools/index.js +4 -2
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/openclaw.plugin.json +8 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { handleAugmentation } from './handlers/augmentation.js';
|
|
2
2
|
import { PLUGIN_CONFIG } from './constants.js';
|
|
3
3
|
import { MemoriLogger, loadSkillsContent } from './utils/index.js';
|
|
4
|
-
import {
|
|
4
|
+
import { registerUtilityTools, registerAuthenticatedTools } from './tools/index.js';
|
|
5
5
|
import { registerCliCommands } from './cli/commands.js';
|
|
6
6
|
const memoriPlugin = {
|
|
7
7
|
id: PLUGIN_CONFIG.ID,
|
|
@@ -15,19 +15,20 @@ const memoriPlugin = {
|
|
|
15
15
|
entityId: rawConfig?.entityId,
|
|
16
16
|
projectId: rawConfig?.projectId,
|
|
17
17
|
};
|
|
18
|
+
const logger = new MemoriLogger(api);
|
|
19
|
+
const skillsContent = loadSkillsContent(api.resolvePath.bind(api));
|
|
20
|
+
registerUtilityTools({ api, config, logger });
|
|
18
21
|
if (!config.apiKey || !config.entityId) {
|
|
19
22
|
api.logger.warn(`${PLUGIN_CONFIG.LOG_PREFIX} Missing apiKey or entityId in config. Plugin disabled.`);
|
|
20
23
|
return;
|
|
21
24
|
}
|
|
22
|
-
const logger = new MemoriLogger(api);
|
|
23
|
-
const skillsContent = loadSkillsContent(api.resolvePath.bind(api));
|
|
24
25
|
logger.info(`\n=== ${PLUGIN_CONFIG.LOG_PREFIX} INITIALIZING PLUGIN ===`);
|
|
25
26
|
logger.info(`${PLUGIN_CONFIG.LOG_PREFIX} Tracking Entity ID: ${config.entityId}`);
|
|
26
27
|
if (skillsContent) {
|
|
27
28
|
api.on('before_prompt_build', () => ({ appendSystemContext: skillsContent }));
|
|
28
29
|
}
|
|
29
30
|
api.on('agent_end', (event, ctx) => handleAugmentation(event, ctx, config, logger));
|
|
30
|
-
|
|
31
|
+
registerAuthenticatedTools({ api, config, logger });
|
|
31
32
|
},
|
|
32
33
|
};
|
|
33
34
|
export default memoriPlugin;
|
package/dist/tools/index.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
import type { ToolDeps } from './types.js';
|
|
2
|
-
export declare function
|
|
2
|
+
export declare function registerUtilityTools(deps: ToolDeps): void;
|
|
3
|
+
export declare function registerAuthenticatedTools(deps: ToolDeps): void;
|
|
3
4
|
export type { ToolDeps };
|
package/dist/tools/index.js
CHANGED
|
@@ -3,10 +3,12 @@ import { createMemoriQuotaTool } from './memori-quota.js';
|
|
|
3
3
|
import { createMemoriRecallTool } from './memori-recall.js';
|
|
4
4
|
import { createMemoriRecallSummaryTool } from './memori-recall-summary.js';
|
|
5
5
|
import { createMemoriFeedbackTool } from './memori-feedback.js';
|
|
6
|
-
export function
|
|
6
|
+
export function registerUtilityTools(deps) {
|
|
7
7
|
deps.api.registerTool(createMemoriSignupTool(deps));
|
|
8
|
-
|
|
8
|
+
}
|
|
9
|
+
export function registerAuthenticatedTools(deps) {
|
|
9
10
|
deps.api.registerTool(createMemoriRecallTool(deps));
|
|
10
11
|
deps.api.registerTool(createMemoriRecallSummaryTool(deps));
|
|
11
12
|
deps.api.registerTool(createMemoriFeedbackTool(deps));
|
|
13
|
+
deps.api.registerTool(createMemoriQuotaTool(deps));
|
|
12
14
|
}
|
package/dist/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SDK_VERSION = "0.0.
|
|
1
|
+
export declare const SDK_VERSION = "0.0.13";
|
package/dist/version.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const SDK_VERSION = '0.0.
|
|
1
|
+
export const SDK_VERSION = '0.0.13';
|
package/openclaw.plugin.json
CHANGED
|
@@ -1,12 +1,18 @@
|
|
|
1
1
|
{
|
|
2
2
|
"id": "openclaw-memori",
|
|
3
3
|
"name": "Memori System",
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.13",
|
|
5
5
|
"description": "Hosted memory backend",
|
|
6
6
|
"kind": "memory",
|
|
7
7
|
"main": "dist/index.js",
|
|
8
8
|
"contracts": {
|
|
9
|
-
"tools": [
|
|
9
|
+
"tools": [
|
|
10
|
+
"memori_recall",
|
|
11
|
+
"memori_recall_summary",
|
|
12
|
+
"memori_feedback",
|
|
13
|
+
"memori_signup",
|
|
14
|
+
"memori_quota"
|
|
15
|
+
]
|
|
10
16
|
},
|
|
11
17
|
"uiHints": {
|
|
12
18
|
"apiKey": {
|