@romiluz/clawmongo 0.1.0-rc.1 → 0.1.0-rc.2
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/README.md +126 -1
- package/dist/main.js +9 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,3 +1,128 @@
|
|
|
1
1
|
# ClawMongo
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
> **MongoDB is the brain, OpenClaw is the heart.**
|
|
4
|
+
|
|
5
|
+
ClawMongo is a MongoDB-native fork of [OpenClaw](https://github.com/TavernAI/OpenClaw) that leverages MongoDB's capabilities (Atlas Search, Vector Search, `$rankFusion`) while maintaining full parity with OpenClaw's features.
|
|
6
|
+
|
|
7
|
+
[](https://www.npmjs.com/package/@romiluz/clawmongo)
|
|
8
|
+
[](https://opensource.org/licenses/MIT)
|
|
9
|
+
|
|
10
|
+
## Features
|
|
11
|
+
|
|
12
|
+
- **MongoDB-Native Storage** - All data stored in MongoDB with proper indexing and validation
|
|
13
|
+
- **Atlas Search** - Full-text search with autocomplete for sessions and plugins
|
|
14
|
+
- **Vector Search** - `$vectorSearch` with embedding providers (Voyage AI, OpenAI)
|
|
15
|
+
- **$rankFusion** - Native MongoDB fusion of lexical and vector results
|
|
16
|
+
- **7 Messaging Connectors** - WhatsApp, Telegram, Discord, Slack, Google Chat, iMessage, WebSocket
|
|
17
|
+
- **Plugin Framework** - Install plugins from npm with dependency resolution
|
|
18
|
+
- **Automation Engine** - Cron scheduling and event-driven hooks
|
|
19
|
+
- **Production Ready** - Health checks, metrics, rate limiting, graceful shutdown, Docker
|
|
20
|
+
|
|
21
|
+
## Installation
|
|
22
|
+
|
|
23
|
+
```bash
|
|
24
|
+
npm install @romiluz/clawmongo
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
Or use the RC version:
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
npm install @romiluz/clawmongo@next
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
## Quick Start
|
|
34
|
+
|
|
35
|
+
```bash
|
|
36
|
+
# Check health
|
|
37
|
+
npx clawmongo health
|
|
38
|
+
|
|
39
|
+
# Start interactive chat
|
|
40
|
+
npx clawmongo chat
|
|
41
|
+
|
|
42
|
+
# Send a message
|
|
43
|
+
npx clawmongo send "Hello, ClawMongo!"
|
|
44
|
+
|
|
45
|
+
# List sessions
|
|
46
|
+
npx clawmongo sessions list
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
## Configuration
|
|
50
|
+
|
|
51
|
+
Set environment variables or use a `.env` file:
|
|
52
|
+
|
|
53
|
+
```bash
|
|
54
|
+
# Required for MongoDB features
|
|
55
|
+
CLAWMONGO_MONGODB_URI=mongodb+srv://...
|
|
56
|
+
|
|
57
|
+
# LLM Provider (optional - defaults to stub)
|
|
58
|
+
ANTHROPIC_API_KEY=sk-...
|
|
59
|
+
OPENAI_API_KEY=sk-...
|
|
60
|
+
|
|
61
|
+
# Embedding Provider
|
|
62
|
+
VOYAGE_API_KEY=pa-...
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
See [docs/ENV.md](docs/ENV.md) for full configuration reference.
|
|
66
|
+
|
|
67
|
+
## Docker
|
|
68
|
+
|
|
69
|
+
```bash
|
|
70
|
+
# Build and run
|
|
71
|
+
docker-compose up -d
|
|
72
|
+
|
|
73
|
+
# Or build manually
|
|
74
|
+
docker build -t clawmongo .
|
|
75
|
+
docker run -p 3000:3000 --env-file .env clawmongo
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
See [docs/DEPLOYMENT.md](docs/DEPLOYMENT.md) for production deployment guide.
|
|
79
|
+
|
|
80
|
+
## OpenClaw Parity
|
|
81
|
+
|
|
82
|
+
ClawMongo maintains 60 capability parity with OpenClaw:
|
|
83
|
+
|
|
84
|
+
| Category | Capabilities |
|
|
85
|
+
|----------|-------------|
|
|
86
|
+
| Sessions | 10 (lifecycle, scopes, reset) |
|
|
87
|
+
| Retrieval | 12 (lexical, vector, fusion) |
|
|
88
|
+
| Tools | 10 (exec, fs, session) |
|
|
89
|
+
| Connectors | 8 (WhatsApp, Telegram, Discord, Slack, etc.) |
|
|
90
|
+
| Plugins | 10 (lifecycle, hooks, tools) |
|
|
91
|
+
| Automation | 10 (cron, hooks, CLI) |
|
|
92
|
+
|
|
93
|
+
## Development
|
|
94
|
+
|
|
95
|
+
```bash
|
|
96
|
+
# Install dependencies
|
|
97
|
+
npm install
|
|
98
|
+
|
|
99
|
+
# Run type check
|
|
100
|
+
npm run typecheck
|
|
101
|
+
|
|
102
|
+
# Run health check
|
|
103
|
+
npm run health
|
|
104
|
+
|
|
105
|
+
# Run sprint checks
|
|
106
|
+
npm run sprint:checks
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
## Architecture
|
|
110
|
+
|
|
111
|
+
ClawMongo is organized into modules:
|
|
112
|
+
|
|
113
|
+
- `src/session/` - Session management
|
|
114
|
+
- `src/retrieval/` - Lexical, vector, and fusion search
|
|
115
|
+
- `src/modules/` - Agent, plugin, automation, gateway
|
|
116
|
+
- `src/connectors/` - Messaging platform connectors
|
|
117
|
+
- `src/cli/` - CLI commands and smoke tests
|
|
118
|
+
- `src/store/mongo/` - MongoDB connection and optimization
|
|
119
|
+
|
|
120
|
+
## License
|
|
121
|
+
|
|
122
|
+
MIT - see [LICENSE](LICENSE)
|
|
123
|
+
|
|
124
|
+
## Credits
|
|
125
|
+
|
|
126
|
+
- [OpenClaw](https://github.com/TavernAI/OpenClaw) - The original project
|
|
127
|
+
- [MongoDB](https://www.mongodb.com/) - The database
|
|
128
|
+
- [Voyage AI](https://www.voyageai.com/) - Default embedding provider
|
package/dist/main.js
CHANGED
|
@@ -15,7 +15,11 @@ import { chatCommand } from "./cli/commands/chat.js";
|
|
|
15
15
|
import { sendCommand } from "./cli/commands/send.js";
|
|
16
16
|
import { configCommand } from "./cli/commands/config.js";
|
|
17
17
|
import { pluginListCommand, pluginEnableCommand, pluginDisableCommand } from "./cli/commands/plugin.js";
|
|
18
|
-
|
|
18
|
+
import { cronCommand } from "./cli/commands/cron.js";
|
|
19
|
+
import { backupCommand } from "./cli/commands/backup.js";
|
|
20
|
+
import { securityCommand } from "./cli/commands/security.js";
|
|
21
|
+
import { benchmarkCommand } from "./cli/commands/benchmark.js";
|
|
22
|
+
const VERSION = "0.1.0-rc.2";
|
|
19
23
|
/**
|
|
20
24
|
* Build the command registry.
|
|
21
25
|
*/
|
|
@@ -32,6 +36,10 @@ function buildRegistry() {
|
|
|
32
36
|
registry.register(pluginListCommand);
|
|
33
37
|
registry.register(pluginEnableCommand);
|
|
34
38
|
registry.register(pluginDisableCommand);
|
|
39
|
+
registry.register(cronCommand);
|
|
40
|
+
registry.register(backupCommand);
|
|
41
|
+
registry.register(securityCommand);
|
|
42
|
+
registry.register(benchmarkCommand);
|
|
35
43
|
return registry;
|
|
36
44
|
}
|
|
37
45
|
/**
|