@kalera/munin-openclaw 0.1.0
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/.turbo/turbo-build.log +4 -0
- package/README.md +21 -0
- package/SKILL.md +54 -0
- package/dist/cli.d.ts +1 -0
- package/dist/cli.js +32 -0
- package/dist/index.d.ts +9 -0
- package/dist/index.js +8 -0
- package/package.json +31 -0
- package/src/cli.ts +47 -0
- package/src/index.ts +16 -0
- package/tsconfig.json +8 -0
package/README.md
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# Munin Adapter for OpenClaw
|
|
2
|
+
|
|
3
|
+
## Install
|
|
4
|
+
|
|
5
|
+
```bash
|
|
6
|
+
pnpm --filter munin/openclaw build
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
## Run
|
|
10
|
+
|
|
11
|
+
```bash
|
|
12
|
+
MUNIN_BASE_URL=http://localhost:4000 \
|
|
13
|
+
MUNIN_PROJECT=default \
|
|
14
|
+
munin-openclaw capabilities
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
```bash
|
|
18
|
+
MUNIN_BASE_URL=http://localhost:4000 \
|
|
19
|
+
MUNIN_PROJECT=default \
|
|
20
|
+
munin-openclaw search '{"query":"munin"}'
|
|
21
|
+
```
|
package/SKILL.md
ADDED
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: "@kalera/munin-openclaw"
|
|
3
|
+
description: "Munin - The $1.6/mo Persistent Memory for OpenClaw. Stop your agent from having Alzheimer's."
|
|
4
|
+
version: "0.1.0"
|
|
5
|
+
metadata:
|
|
6
|
+
clawdbot:
|
|
7
|
+
type: "plugin"
|
|
8
|
+
permissions:
|
|
9
|
+
env: ["MUNIN_BASE_URL", "MUNIN_PROJECT", "MUNIN_API_KEY"]
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
# š¦ Munin: Reliable Memory for Your OpenClaw Agent
|
|
13
|
+
|
|
14
|
+
Your agent forgets everything the moment you close the tab. You've seen the "pro" solutionsāMem0, Zep, LangMemāand you've seen their **$20/month** price tags.
|
|
15
|
+
|
|
16
|
+
We think that's insane.
|
|
17
|
+
|
|
18
|
+
**Munin (ContextKeep)** is the pragmatic alternative. Itās the "Reliable Friend" that sits on your agentās shoulder and whispers: *"Hey, remember when pa Kal said he preferred Python over Node last week?"*
|
|
19
|
+
|
|
20
|
+
### š° Why Munin? (The "No-Brainer" Math)
|
|
21
|
+
|
|
22
|
+
| Feature | Mem0 / Zep | **Munin** |
|
|
23
|
+
| :--- | :--- | :--- |
|
|
24
|
+
| **Monthly Cost** | $19.00 - $249.00 | **$1.60** |
|
|
25
|
+
| **MCP Support** | Mixed | **Native / First-class** |
|
|
26
|
+
| **Self-Hostable** | OSS (Complex) | **Yes (Simple)** |
|
|
27
|
+
| **Bullshit Factor** | High (Enterprise-synergy) | **Zero (Developer-first)** |
|
|
28
|
+
|
|
29
|
+
**Thatās a 10x - 150x price gap.** We aren't building "Enterprise Synergy Platforms". We're building a notebook for your AI.
|
|
30
|
+
|
|
31
|
+
---
|
|
32
|
+
|
|
33
|
+
## š Security & Privacy
|
|
34
|
+
|
|
35
|
+
**Trust Statement:**
|
|
36
|
+
Data stays where you tell it to stay. If you self-host, it never leaves your server. If you use our cloud, it's encrypted and isolated by project.
|
|
37
|
+
|
|
38
|
+
**External Endpoints:**
|
|
39
|
+
Data is sent ONLY to your `MUNIN_BASE_URL`. We don't phone home. We don't sell your "memories" to train models.
|
|
40
|
+
|
|
41
|
+
---
|
|
42
|
+
|
|
43
|
+
## š Setup (Fast & Honest)
|
|
44
|
+
|
|
45
|
+
1. **Get your Munin instance:** Self-host it or grab a cloud key at [munin.ai](https://munin.ai).
|
|
46
|
+
2. **Configure OpenClaw:** Add these to your `.env` or agent config:
|
|
47
|
+
- `MUNIN_BASE_URL`: Where your Munin lives (e.g., `https://api.munin.ai`).
|
|
48
|
+
- `MUNIN_PROJECT`: Your project name (e.g., `research-agent`).
|
|
49
|
+
- `MUNIN_API_KEY`: Your key to the kingdom.
|
|
50
|
+
|
|
51
|
+
3. **Profit:** Your agent now has long-term memory. No more repeating yourself.
|
|
52
|
+
|
|
53
|
+
---
|
|
54
|
+
*Built with ā¤ļø by Kalera for the OpenClaw Ecosystem.*
|
package/dist/cli.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/dist/cli.js
ADDED
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { executeWithRetry, loadCliEnv, parseCliArgs, safeError, startMcpServer, } from "@kalera/munin-runtime";
|
|
2
|
+
import { createOpenClawMuninAdapter } from "./index.js";
|
|
3
|
+
async function main() {
|
|
4
|
+
try {
|
|
5
|
+
const args = process.argv.slice(2);
|
|
6
|
+
// If no arguments, or 'mcp' is passed, start as MCP server
|
|
7
|
+
if (args.length === 0 || args[0] === 'mcp') {
|
|
8
|
+
await startMcpServer();
|
|
9
|
+
return;
|
|
10
|
+
}
|
|
11
|
+
const { action, payload } = parseCliArgs(args, "Usage: munin-openclaw <action> [payload-json] OR munin-openclaw mcp");
|
|
12
|
+
const env = loadCliEnv();
|
|
13
|
+
const adapter = createOpenClawMuninAdapter({
|
|
14
|
+
baseUrl: env.baseUrl,
|
|
15
|
+
apiKey: env.apiKey,
|
|
16
|
+
project: env.project,
|
|
17
|
+
timeoutMs: env.timeoutMs,
|
|
18
|
+
});
|
|
19
|
+
const result = await executeWithRetry(async () => {
|
|
20
|
+
if (action === "capabilities") {
|
|
21
|
+
return { ok: true, data: await adapter.capabilities() };
|
|
22
|
+
}
|
|
23
|
+
return adapter.execute(action, payload);
|
|
24
|
+
}, env.retries, env.backoffMs);
|
|
25
|
+
console.log(JSON.stringify(result, null, 2));
|
|
26
|
+
}
|
|
27
|
+
catch (error) {
|
|
28
|
+
console.error(JSON.stringify({ ok: false, error: safeError(error) }));
|
|
29
|
+
process.exitCode = 1;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
void main();
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare function createOpenClawMuninAdapter(config: {
|
|
2
|
+
baseUrl: string;
|
|
3
|
+
apiKey?: string;
|
|
4
|
+
project: string;
|
|
5
|
+
timeoutMs?: number;
|
|
6
|
+
}): {
|
|
7
|
+
execute: (action: string, payload: Record<string, unknown>) => Promise<import("@kalera/munin-sdk").MuninResponse<unknown>>;
|
|
8
|
+
capabilities: () => Promise<import("@kalera/munin-sdk").MuninCapabilities>;
|
|
9
|
+
};
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { MuninClient } from "@kalera/munin-sdk";
|
|
2
|
+
export function createOpenClawMuninAdapter(config) {
|
|
3
|
+
const client = new MuninClient(config);
|
|
4
|
+
return {
|
|
5
|
+
execute: (action, payload) => client.invoke(action, payload, { ensureCapability: true }),
|
|
6
|
+
capabilities: () => client.capabilities(),
|
|
7
|
+
};
|
|
8
|
+
}
|
package/package.json
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@kalera/munin-openclaw",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"type": "module",
|
|
5
|
+
"openclaw": {
|
|
6
|
+
"extensions": [
|
|
7
|
+
"./dist/cli.js"
|
|
8
|
+
],
|
|
9
|
+
"requires": {
|
|
10
|
+
"env": [
|
|
11
|
+
"MUNIN_BASE_URL",
|
|
12
|
+
"MUNIN_PROJECT"
|
|
13
|
+
]
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
"bin": {
|
|
17
|
+
"munin-openclaw": "dist/cli.js"
|
|
18
|
+
},
|
|
19
|
+
"dependencies": {
|
|
20
|
+
"@kalera/munin-sdk": "0.1.0",
|
|
21
|
+
"@kalera/munin-runtime": "0.1.0"
|
|
22
|
+
},
|
|
23
|
+
"devDependencies": {
|
|
24
|
+
"typescript": "^5.9.2"
|
|
25
|
+
},
|
|
26
|
+
"scripts": {
|
|
27
|
+
"build": "tsc -p tsconfig.json",
|
|
28
|
+
"lint": "tsc -p tsconfig.json --noEmit",
|
|
29
|
+
"test": "echo 'adapter-openclaw tests: pending'"
|
|
30
|
+
}
|
|
31
|
+
}
|
package/src/cli.ts
ADDED
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import {
|
|
2
|
+
executeWithRetry,
|
|
3
|
+
loadCliEnv,
|
|
4
|
+
parseCliArgs,
|
|
5
|
+
safeError,
|
|
6
|
+
startMcpServer,
|
|
7
|
+
} from "@kalera/munin-runtime";
|
|
8
|
+
import { createOpenClawMuninAdapter } from "./index.js";
|
|
9
|
+
|
|
10
|
+
async function main() {
|
|
11
|
+
try {
|
|
12
|
+
const args = process.argv.slice(2);
|
|
13
|
+
|
|
14
|
+
// If no arguments, or 'mcp' is passed, start as MCP server
|
|
15
|
+
if (args.length === 0 || args[0] === 'mcp') {
|
|
16
|
+
await startMcpServer();
|
|
17
|
+
return;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
const { action, payload } = parseCliArgs(
|
|
21
|
+
args,
|
|
22
|
+
"Usage: munin-openclaw <action> [payload-json] OR munin-openclaw mcp",
|
|
23
|
+
);
|
|
24
|
+
const env = loadCliEnv();
|
|
25
|
+
|
|
26
|
+
const adapter = createOpenClawMuninAdapter({
|
|
27
|
+
baseUrl: env.baseUrl,
|
|
28
|
+
apiKey: env.apiKey,
|
|
29
|
+
project: env.project,
|
|
30
|
+
timeoutMs: env.timeoutMs,
|
|
31
|
+
});
|
|
32
|
+
|
|
33
|
+
const result = await executeWithRetry(async () => {
|
|
34
|
+
if (action === "capabilities") {
|
|
35
|
+
return { ok: true, data: await adapter.capabilities() };
|
|
36
|
+
}
|
|
37
|
+
return adapter.execute(action, payload);
|
|
38
|
+
}, env.retries, env.backoffMs);
|
|
39
|
+
|
|
40
|
+
console.log(JSON.stringify(result, null, 2));
|
|
41
|
+
} catch (error) {
|
|
42
|
+
console.error(JSON.stringify({ ok: false, error: safeError(error) }));
|
|
43
|
+
process.exitCode = 1;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
void main();
|
package/src/index.ts
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { MuninClient } from "@kalera/munin-sdk";
|
|
2
|
+
|
|
3
|
+
export function createOpenClawMuninAdapter(config: {
|
|
4
|
+
baseUrl: string;
|
|
5
|
+
apiKey?: string;
|
|
6
|
+
project: string;
|
|
7
|
+
timeoutMs?: number;
|
|
8
|
+
}) {
|
|
9
|
+
const client = new MuninClient(config);
|
|
10
|
+
|
|
11
|
+
return {
|
|
12
|
+
execute: (action: string, payload: Record<string, unknown>) =>
|
|
13
|
+
client.invoke(action as any, payload, { ensureCapability: true }),
|
|
14
|
+
capabilities: () => client.capabilities(),
|
|
15
|
+
};
|
|
16
|
+
}
|