0xkobold 0.4.3 → 0.5.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/README.md +226 -383
- package/dist/package.json +13 -4
- package/dist/src/agent/DraconicCapabilityRouter.js +556 -0
- package/dist/src/agent/DraconicCapabilityRouter.js.map +1 -0
- package/dist/src/agent/DraconicErrorClassifier.js +606 -0
- package/dist/src/agent/DraconicErrorClassifier.js.map +1 -0
- package/dist/src/agent/DraconicRunRegistry.js +460 -0
- package/dist/src/agent/DraconicRunRegistry.js.map +1 -0
- package/dist/src/agent/DraconicTokenPredictor.js +500 -0
- package/dist/src/agent/DraconicTokenPredictor.js.map +1 -0
- package/dist/src/agent/embedded-runner.js +3 -2
- package/dist/src/agent/embedded-runner.js.map +1 -1
- package/dist/src/cli/commands/doctor.js +199 -0
- package/dist/src/cli/commands/doctor.js.map +1 -0
- package/dist/src/cli/commands/migrate-from-openclaw.js +39 -0
- package/dist/src/cli/commands/migrate-from-openclaw.js.map +1 -0
- package/dist/src/cli/commands/migrate.js +6 -4
- package/dist/src/cli/commands/migrate.js.map +1 -1
- package/dist/src/cli/program.js +3 -1
- package/dist/src/cli/program.js.map +1 -1
- package/dist/src/config/unified-config.js +195 -0
- package/dist/src/config/unified-config.js.map +1 -0
- package/dist/src/cron/notifications.js +1 -1
- package/dist/src/cron/notifications.js.map +1 -1
- package/dist/src/cron/runner.js +9 -3
- package/dist/src/cron/runner.js.map +1 -1
- package/dist/src/event-bus/index.js +3 -1
- package/dist/src/event-bus/index.js.map +1 -1
- package/dist/src/extensions/community/draconic-messenger-wrapper.js +35 -0
- package/dist/src/extensions/community/draconic-messenger-wrapper.js.map +1 -0
- package/dist/src/extensions/community/draconic-subagents-wrapper.js +115 -0
- package/dist/src/extensions/community/draconic-subagents-wrapper.js.map +1 -0
- package/dist/src/extensions/core/compaction-safeguard-v2.js +95 -0
- package/dist/src/extensions/core/compaction-safeguard-v2.js.map +1 -0
- package/dist/src/extensions/core/compaction-safeguard.js +206 -137
- package/dist/src/extensions/core/compaction-safeguard.js.map +1 -1
- package/dist/src/extensions/core/config-extension.js +122 -0
- package/dist/src/extensions/core/config-extension.js.map +1 -0
- package/dist/src/extensions/core/draconic-hoard-extension.js +194 -0
- package/dist/src/extensions/core/draconic-hoard-extension.js.map +1 -0
- package/dist/src/extensions/core/draconic-lair-extension.js +146 -0
- package/dist/src/extensions/core/draconic-lair-extension.js.map +1 -0
- package/dist/src/extensions/core/draconic-safety-extension.js +402 -0
- package/dist/src/extensions/core/draconic-safety-extension.js.map +1 -0
- package/dist/src/extensions/core/ext-manager.js +40 -0
- package/dist/src/extensions/core/ext-manager.js.map +1 -0
- package/dist/src/extensions/core/gateway-extension.js +413 -624
- package/dist/src/extensions/core/gateway-extension.js.map +1 -1
- package/dist/src/extensions/core/generative-agents-extension.js +704 -0
- package/dist/src/extensions/core/generative-agents-extension.js.map +1 -0
- package/dist/src/extensions/core/memory-bootstrap-extension.js +279 -0
- package/dist/src/extensions/core/memory-bootstrap-extension.js.map +1 -0
- package/dist/src/extensions/core/ollama-extension.js +442 -0
- package/dist/src/extensions/core/ollama-extension.js.map +1 -0
- package/dist/src/extensions/core/ollama-router-extension.js +34 -93
- package/dist/src/extensions/core/ollama-router-extension.js.map +1 -1
- package/dist/src/extensions/core/perennial-memory-extension.js +5 -2
- package/dist/src/extensions/core/perennial-memory-extension.js.map +1 -1
- package/dist/src/extensions/core/persona-loader-extension.js +41 -15
- package/dist/src/extensions/core/persona-loader-extension.js.map +1 -1
- package/dist/src/extensions/core/pi-notify-extension.js +6 -0
- package/dist/src/extensions/core/pi-notify-extension.js.map +1 -1
- package/dist/src/extensions/core/session-bridge-extension.js +8 -72
- package/dist/src/extensions/core/session-bridge-extension.js.map +1 -1
- package/dist/src/extensions/core/tui-integration-extension-fixed.js +3 -0
- package/dist/src/extensions/core/tui-integration-extension-fixed.js.map +1 -0
- package/dist/src/extensions/core/tui-integration-extension.js +984 -0
- package/dist/src/extensions/core/tui-integration-extension.js.map +1 -0
- package/dist/src/gateway/persistence/AgentStore.js +399 -0
- package/dist/src/gateway/persistence/AgentStore.js.map +1 -0
- package/dist/src/gateway/persistence/index.js +9 -0
- package/dist/src/gateway/persistence/index.js.map +1 -0
- package/dist/src/hoard/DraconicHoardSystem.js +465 -0
- package/dist/src/hoard/DraconicHoardSystem.js.map +1 -0
- package/dist/src/index.js +7 -5
- package/dist/src/index.js.map +1 -1
- package/dist/src/infra/DraconicConnectionPool.js +492 -0
- package/dist/src/infra/DraconicConnectionPool.js.map +1 -0
- package/dist/src/lair/DraconicLairSystem.js +387 -0
- package/dist/src/lair/DraconicLairSystem.js.map +1 -0
- package/dist/src/llm/ollama.js +143 -99
- package/dist/src/llm/ollama.js.map +1 -1
- package/dist/src/migration/openclaw.js +5 -5
- package/dist/src/migration/openclaw.js.map +1 -1
- package/dist/src/pi-config.js +52 -27
- package/dist/src/pi-config.js.map +1 -1
- package/dist/src/sessions/SessionManager.js +416 -0
- package/dist/src/sessions/SessionManager.js.map +1 -0
- package/dist/src/sessions/SessionStore.js +580 -0
- package/dist/src/sessions/SessionStore.js.map +1 -0
- package/dist/src/sessions/UnifiedSessionBridge.js +394 -0
- package/dist/src/sessions/UnifiedSessionBridge.js.map +1 -0
- package/dist/src/sessions/index.js +15 -0
- package/dist/src/sessions/index.js.map +1 -0
- package/dist/src/sessions/migration/index.js +156 -0
- package/dist/src/sessions/migration/index.js.map +1 -0
- package/dist/src/sessions/types.js +8 -0
- package/dist/src/sessions/types.js.map +1 -0
- package/dist/src/skills/framework.js +1 -1
- package/dist/src/skills/framework.js.map +1 -1
- package/dist/src/tui/commands/final-functions.js +39 -0
- package/dist/src/tui/commands/final-functions.js.map +1 -0
- package/dist/src/tui/commands/natural-language-commands.js +231 -0
- package/dist/src/tui/commands/natural-language-commands.js.map +1 -0
- package/dist/src/tui/commands/orchestration-commands.js +340 -0
- package/dist/src/tui/commands/orchestration-commands.js.map +1 -0
- package/dist/src/tui/commands/orchestration-final-section.js +84 -0
- package/dist/src/tui/commands/orchestration-final-section.js.map +1 -0
- package/dist/src/tui/components/agent-tree-overlay.js +210 -0
- package/dist/src/tui/components/agent-tree-overlay.js.map +1 -0
- package/dist/src/tui/components/agent-tree-panel.js +229 -0
- package/dist/src/tui/components/agent-tree-panel.js.map +1 -0
- package/dist/src/tui/components/sidebar.js +82 -0
- package/dist/src/tui/components/sidebar.js.map +1 -0
- package/dist/src/tui/components/status-bar.js +115 -0
- package/dist/src/tui/components/status-bar.js.map +1 -0
- package/dist/src/tui/components/tree-header.js +85 -0
- package/dist/src/tui/components/tree-header.js.map +1 -0
- package/dist/src/tui/draconic-tui.js +291 -0
- package/dist/src/tui/draconic-tui.js.map +1 -0
- package/dist/src/tui/index.js +93 -0
- package/dist/src/tui/index.js.map +1 -0
- package/dist/src/tui/pi-tui-integration.js +260 -0
- package/dist/src/tui/pi-tui-integration.js.map +1 -0
- package/dist/src/utils/nl-patterns.js +145 -0
- package/dist/src/utils/nl-patterns.js.map +1 -0
- package/package.json +13 -4
- package/scripts/migrate-from-openclaw.sh +498 -0
- package/HEARTBEAT.md +0 -121
- package/USAGE.md +0 -191
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# 0xKobold v0.
|
|
1
|
+
# 0xKobold v0.5.0 "Draconic Intelligence"
|
|
2
2
|
|
|
3
3
|
```
|
|
4
4
|
..
|
|
@@ -15,14 +15,14 @@
|
|
|
15
15
|
..,!``I,!]JZXJ{]I,,~~;, I[_<-t}1doCdfdQCOB%oJ{+?{ddMO@@@#@o>` .:-< .
|
|
16
16
|
.``l;;{QW%###WQZ+;>>I ...<YfZ{]}Xb!IQ@@8%W@@QJ{[-JJZ@@@@@@%dZbMX[,..
|
|
17
17
|
. II ,I]bo%8%%MQd?>; . ;li . ,Z@@@@#@MI]~ZUOX}YB@@@@@8oQY};
|
|
18
|
-
. ^>^.^~fbXXdZf_,, Il . I~d@@#MOIY>l[ZoW@@@@@@@@@UIMO{.
|
|
18
|
+
. ^>^.^~fbXXdZf_,, Il . I~d@@#MOIY>l[ZoW@@@@@@@@@UIMO{.
|
|
19
19
|
`I!<` ,lllll :,i;,^` ...~+<d#oJQQbIIJdUB@@@@@@@#%OU8WW@@81+,`
|
|
20
20
|
.,i[l:i!, `:I<-l<-, ^^` ..:]ZodXIdbC1i1Z#@@@@@@%%BWWoO%@@@@%bQf[^.
|
|
21
21
|
.J-I ~I!.iCU->-1_<`ii>~:....:_1}It}!.::+tX%#@%MbMBQ%@@@@@@%%WbY]+-~`.
|
|
22
22
|
XWOUMO{,Z@B-;1B]:I_->i^ ... `;;JOB#QB#M8@@@@@@8OOOQdZ{~i!i!:.
|
|
23
23
|
..iJB@@M[1@%Y<X@o][]]>:III,^, ....,Z@@@@@@@@@@@@@@8#WOMoZI~~~~+I..
|
|
24
24
|
`~M@8X#@8Zf#@BUWb1{1?]1}]<!^ ...:b@@@@@@@@@@@@@8BW#dXZf[?-+l:`. ..
|
|
25
|
-
.. :JB@@@@%%@@@B#@%W%OQ8BMQbU> ..>M
|
|
25
|
+
.. :JB@@@@%%@@@B#@%W%OQ8BMQbU> ..>M%@@@@@@@@@@@BWW8##OoXZXQCi^ ...
|
|
26
26
|
.. ^?1YbMWO#@@@@@@@@@@@@@@OZ-` d@#@@@@@@@@#%W8##OoXZXQCi^ ...
|
|
27
27
|
.. .`.:!~-CXd%@@@@@@@8oQ}}%@@@@@@@@@@@BWWBWMMdbf[->>^..
|
|
28
28
|
..... :{@@@@@@@OYUCQ8@@@@@@@@8BB8WMQModU?++:!I..
|
|
@@ -34,251 +34,205 @@
|
|
|
34
34
|
........ ......... .........
|
|
35
35
|
```
|
|
36
36
|
|
|
37
|
-
> *"Your digital familiar - a personal AI assistant that learns,
|
|
37
|
+
> *"Your digital familiar - a personal AI assistant that learns, remembers, and evolves"*
|
|
38
38
|
|
|
39
|
-
**v0.
|
|
39
|
+
**v0.5.0 "Draconic Intelligence"** — Multi-agent orchestration, semantic memory, and generative agent capabilities.
|
|
40
|
+
|
|
41
|
+
> **New in v0.5.0:** Generative Agents (memory, reflection, planning), Semantic Memory (Ollama embeddings), Natural Language Commands
|
|
42
|
+
> **From v0.3.0:** Multi-channel (WhatsApp, Telegram, Slack), Tailscale VPN, Media (Vision, Audio, PDF), Docker Sandbox
|
|
40
43
|
|
|
41
44
|
---
|
|
42
45
|
|
|
43
|
-
##
|
|
46
|
+
## ✨ Features
|
|
44
47
|
|
|
45
|
-
###
|
|
48
|
+
### v0.5.0 - Draconic Intelligence
|
|
49
|
+
| Feature | Status | Description |
|
|
50
|
+
|---------|--------|-------------|
|
|
51
|
+
| **Multi-Agent Orchestration** | ✅ | Spawn specialized agents with unified `/agent-orchestrate` API |
|
|
52
|
+
| **Generative Agents** | ✅ | Memory stream, reflection, planning (Stanford HCI research) |
|
|
53
|
+
| **Semantic Memory** | ✅ | Ollama-powered embeddings with hybrid search |
|
|
54
|
+
| **Natural Language Commands** | ✅ | Parse "spawn a worker" → structured commands |
|
|
46
55
|
|
|
56
|
+
### v0.3.0 - The Gap Closer
|
|
47
57
|
| Feature | Status | Description |
|
|
48
58
|
|---------|--------|-------------|
|
|
49
59
|
| **WhatsApp** | ✅ | Baileys integration with QR pairing |
|
|
50
60
|
| **Telegram** | ✅ | Complete bot with webhooks |
|
|
51
61
|
| **Slack** | ✅ | Webhook & slash commands |
|
|
52
62
|
| **Docker Sandbox** | ✅ | Secure container execution |
|
|
53
|
-
| **
|
|
63
|
+
| **Tailscale** | ✅ | Zero-config VPN for remote access |
|
|
54
64
|
| **Vision (AI)** | ✅ | Claude Vision image analysis |
|
|
55
65
|
| **Audio** | ✅ | Whisper transcription |
|
|
56
66
|
| **PDF** | ✅ | Text extraction & metadata |
|
|
57
|
-
| **
|
|
58
|
-
| **
|
|
59
|
-
| **
|
|
60
|
-
| **OpenClaw Migration** | ✅ | Full migration tool |
|
|
67
|
+
| **Hot-Reload Skills** | ✅ | Add capabilities without restart |
|
|
68
|
+
| **Discord Integration** | ✅ | Bot interface |
|
|
69
|
+
| **WebSocket Gateway** | ✅ | Real-time communication (port 18789) |
|
|
61
70
|
|
|
62
71
|
---
|
|
63
72
|
|
|
64
|
-
##
|
|
73
|
+
## Quick Start
|
|
65
74
|
|
|
66
|
-
###
|
|
75
|
+
### Prerequisites
|
|
67
76
|
|
|
68
77
|
```bash
|
|
69
|
-
# Install Bun
|
|
78
|
+
# Install Bun (required)
|
|
70
79
|
curl -fsSL https://bun.sh/install | bash
|
|
71
80
|
|
|
72
|
-
# Install
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
#
|
|
76
|
-
0xkobold setup
|
|
77
|
-
|
|
78
|
-
# Start
|
|
79
|
-
0xkobold
|
|
80
|
-
```
|
|
81
|
-
|
|
82
|
-
### Quick Start
|
|
83
|
-
|
|
84
|
-
```bash
|
|
85
|
-
npx 0xkobold setup
|
|
86
|
-
npx 0xkobold
|
|
81
|
+
# Install Ollama (for local LLM)
|
|
82
|
+
curl -fsSL https://ollama.com/install.sh | sh
|
|
83
|
+
ollama pull qwen2.5-coder:14b
|
|
84
|
+
ollama pull nomic-embed-text # For semantic memory
|
|
87
85
|
```
|
|
88
86
|
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
## Multi-Channel Support 📱
|
|
92
|
-
|
|
93
|
-
Use your AI across multiple messaging platforms:
|
|
87
|
+
### Install & Run
|
|
94
88
|
|
|
95
89
|
```bash
|
|
96
|
-
#
|
|
97
|
-
|
|
98
|
-
|
|
90
|
+
# Clone repository
|
|
91
|
+
git clone https://github.com/kobolds/0xKobolds.git
|
|
92
|
+
cd 0xKobolds
|
|
99
93
|
|
|
100
|
-
#
|
|
101
|
-
|
|
94
|
+
# Install dependencies
|
|
95
|
+
bun install
|
|
102
96
|
|
|
103
|
-
#
|
|
104
|
-
|
|
97
|
+
# Initialize workspace
|
|
98
|
+
bun run init
|
|
105
99
|
|
|
106
|
-
#
|
|
107
|
-
|
|
100
|
+
# Start 0xKobold
|
|
101
|
+
bun run start
|
|
108
102
|
```
|
|
109
103
|
|
|
110
104
|
---
|
|
111
105
|
|
|
112
|
-
##
|
|
106
|
+
## Multi-Agent System 🎯
|
|
113
107
|
|
|
114
|
-
|
|
108
|
+
Spawn specialized agents for different tasks:
|
|
115
109
|
|
|
116
|
-
### VPS Side
|
|
117
110
|
```bash
|
|
118
|
-
#
|
|
119
|
-
|
|
111
|
+
# Spawn via commands
|
|
112
|
+
/agent-spawn coordinator "plan a feature"
|
|
113
|
+
/agent-spawn specialist "implement auth"
|
|
114
|
+
/agent-spawn researcher "analyze codebase"
|
|
115
|
+
/agent-spawn reviewer "check for security issues"
|
|
120
116
|
|
|
121
|
-
# Or
|
|
122
|
-
|
|
117
|
+
# Or natural language
|
|
118
|
+
spawn a worker to fix the database connection
|
|
119
|
+
analyze this complex architecture problem
|
|
120
|
+
delegate the user authentication project
|
|
123
121
|
```
|
|
124
122
|
|
|
125
|
-
###
|
|
126
|
-
```bash
|
|
127
|
-
# Direct connection
|
|
128
|
-
0xkobold tui --remote wss://vps.example.com:7777
|
|
123
|
+
### Agent Types
|
|
129
124
|
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
125
|
+
| Type | Emoji | Best For |
|
|
126
|
+
|------|-------|----------|
|
|
127
|
+
| coordinator | 🎯 | Task decomposition, delegation |
|
|
128
|
+
| specialist | 🧠 | Deep domain expertise |
|
|
129
|
+
| researcher | 🔍 | Information gathering |
|
|
130
|
+
| worker | ⚒️ | Implementation |
|
|
131
|
+
| reviewer | 👁️ | Code review, validation |
|
|
133
132
|
|
|
134
133
|
---
|
|
135
134
|
|
|
136
|
-
##
|
|
135
|
+
## Generative Agents 🧠
|
|
137
136
|
|
|
138
|
-
|
|
139
|
-
```typescript
|
|
140
|
-
import { getDockerRunner } from "0xkobold/sandbox";
|
|
141
|
-
|
|
142
|
-
const runner = getDockerRunner({
|
|
143
|
-
image: "node:20-slim",
|
|
144
|
-
memoryLimit: "512m",
|
|
145
|
-
network: "none", // Isolated
|
|
146
|
-
});
|
|
147
|
-
|
|
148
|
-
await runner.run({
|
|
149
|
-
command: "node",
|
|
150
|
-
args: ["-e", "console.log('Safe execution')"],
|
|
151
|
-
});
|
|
152
|
-
```
|
|
137
|
+
Based on Stanford HCI research. Agents that remember, reflect, and plan:
|
|
153
138
|
|
|
154
|
-
### Device Authentication
|
|
155
139
|
```bash
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
---
|
|
140
|
+
# Automatic memory capture
|
|
141
|
+
- User interactions
|
|
142
|
+
- Tool executions
|
|
143
|
+
- Agent decisions
|
|
162
144
|
|
|
163
|
-
|
|
145
|
+
# Reflection (auto-triggered every 20 observations)
|
|
146
|
+
/agent-reflections # Show insights
|
|
164
147
|
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
148
|
+
# Planning
|
|
149
|
+
/agent-plans # View plans
|
|
150
|
+
/agent-status # Agent stats
|
|
168
151
|
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
});
|
|
173
|
-
|
|
174
|
-
const result = await vision.analyzeImage("./image.png");
|
|
175
|
-
console.log(result.description);
|
|
176
|
-
console.log(result.objects);
|
|
152
|
+
# Manual memory operations
|
|
153
|
+
remember "User prefers TypeScript"
|
|
154
|
+
recall "what was the database decision"
|
|
177
155
|
```
|
|
178
156
|
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
import { AudioTranscriber } from "0xkobold/media";
|
|
157
|
+
**Memory Categories:** observation, thought, action, reflection
|
|
158
|
+
**Retrieval:** Combines recency × importance × relevance
|
|
182
159
|
|
|
183
|
-
|
|
184
|
-
provider: "openai",
|
|
185
|
-
apiKey: process.env.OPENAI_API_KEY,
|
|
186
|
-
});
|
|
160
|
+
---
|
|
187
161
|
|
|
188
|
-
|
|
189
|
-
console.log(result.text);
|
|
190
|
-
console.log(result.segments); // Timestamps
|
|
191
|
-
```
|
|
162
|
+
## Skills System 🔧
|
|
192
163
|
|
|
193
|
-
|
|
194
|
-
```typescript
|
|
195
|
-
import { extractPDF } from "0xkobold/documents";
|
|
164
|
+
Create custom capabilities without restarting:
|
|
196
165
|
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
166
|
+
```typescript
|
|
167
|
+
// skills/my-skill.ts
|
|
168
|
+
import { Skill } from '../src/skills/types';
|
|
169
|
+
|
|
170
|
+
export const mySkill: Skill = {
|
|
171
|
+
name: 'mySkill',
|
|
172
|
+
description: 'What it does',
|
|
173
|
+
risk: 'medium', // safe | medium | high
|
|
174
|
+
toolDefinition: {
|
|
175
|
+
type: 'function',
|
|
176
|
+
function: {
|
|
177
|
+
name: 'mySkill',
|
|
178
|
+
description: 'For the LLM',
|
|
179
|
+
parameters: {
|
|
180
|
+
type: 'object',
|
|
181
|
+
properties: {
|
|
182
|
+
param: { type: 'string' }
|
|
183
|
+
},
|
|
184
|
+
required: ['param']
|
|
185
|
+
}
|
|
186
|
+
}
|
|
187
|
+
},
|
|
188
|
+
async execute(args) {
|
|
189
|
+
return { success: true, data: result };
|
|
190
|
+
}
|
|
191
|
+
};
|
|
201
192
|
```
|
|
202
193
|
|
|
203
|
-
|
|
194
|
+
**Auto-reload enabled** - changes appear immediately!
|
|
204
195
|
|
|
205
|
-
|
|
196
|
+
---
|
|
206
197
|
|
|
207
|
-
|
|
198
|
+
## Commands
|
|
208
199
|
|
|
200
|
+
### Core
|
|
209
201
|
```bash
|
|
210
|
-
#
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
#
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
# Check class
|
|
217
|
-
0xkobold check -c UserManager
|
|
202
|
+
bun run start # Start main server
|
|
203
|
+
bun run dev # TypeScript watch mode
|
|
204
|
+
bun run build # Compile to dist/
|
|
205
|
+
bun run tui # Start Terminal UI
|
|
206
|
+
bun run cli # Run CLI commands
|
|
207
|
+
bun run init # Initialize workspace
|
|
218
208
|
```
|
|
219
209
|
|
|
220
|
-
|
|
221
|
-
```
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
210
|
+
### Agent Orchestration
|
|
211
|
+
```bash
|
|
212
|
+
/agent-orchestrate list # List all agents
|
|
213
|
+
/agent-orchestrate spawn_main coordinator # Spawn main agent
|
|
214
|
+
/agent-orchestrate spawn_subagent worker "task"
|
|
215
|
+
/agent-orchestrate analyze "complex task" # Analyze complexity
|
|
216
|
+
/agent-orchestrate delegate "big project" # Auto-delegate
|
|
226
217
|
```
|
|
227
218
|
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
## Migration from OpenClaw 🔄
|
|
231
|
-
|
|
232
|
-
Migrating from OpenClaw (koclaw)? We got you:
|
|
233
|
-
|
|
219
|
+
### Generative Agents
|
|
234
220
|
```bash
|
|
235
|
-
#
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
#
|
|
239
|
-
|
|
221
|
+
/agent-memories # Show memory stream
|
|
222
|
+
/agent-reflections # Show insights
|
|
223
|
+
/agent-plans # Show plans
|
|
224
|
+
/agent-status # Agent stats
|
|
225
|
+
/generative_observe "what happened"
|
|
226
|
+
/generative_reflect # Generate insights
|
|
227
|
+
/generative_plan daily # Create daily plan
|
|
240
228
|
```
|
|
241
229
|
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
-
|
|
248
|
-
- ✅ Credentials (secure)
|
|
249
|
-
- ✅ Media files
|
|
250
|
-
- ✅ Cron jobs
|
|
251
|
-
- ✅ Workspace & databases
|
|
252
|
-
- ✅ Channel sessions
|
|
253
|
-
|
|
254
|
-
---
|
|
255
|
-
|
|
256
|
-
## Project Structure
|
|
257
|
-
|
|
258
|
-
```
|
|
259
|
-
0xkobold/
|
|
260
|
-
├── src/
|
|
261
|
-
│ ├── agent/ # Agent runtime
|
|
262
|
-
│ ├── approval/ # Safety approvals
|
|
263
|
-
│ ├── auth/ # Device authentication
|
|
264
|
-
│ ├── channels/ # WhatsApp, Telegram, Slack
|
|
265
|
-
│ ├── cli/ # CLI commands
|
|
266
|
-
│ ├── config/ # Configuration management
|
|
267
|
-
│ ├── discord/ # Discord bot
|
|
268
|
-
│ ├── documents/ # PDF processing
|
|
269
|
-
│ ├── gateway/ # WebSocket gateway
|
|
270
|
-
│ │ ├── client.ts # Remote client
|
|
271
|
-
│ │ └── server.ts # Server
|
|
272
|
-
│ ├── infra/ # Infrastructure (Tailscale)
|
|
273
|
-
│ ├── media/ # Vision, Audio
|
|
274
|
-
│ ├── migration/ # OpenClaw migration
|
|
275
|
-
│ ├── sandbox/ # Docker isolation
|
|
276
|
-
│ ├── skills/ # Skills framework
|
|
277
|
-
│ │ └── builtin/
|
|
278
|
-
│ │ └── duplicate-detector.ts
|
|
279
|
-
│ └── workspace/ # Workspace management
|
|
280
|
-
├── skills/ # Your custom skills
|
|
281
|
-
└── package.json
|
|
230
|
+
### Memory
|
|
231
|
+
```bash
|
|
232
|
+
/remember "Content" --category fact --importance 0.9
|
|
233
|
+
/recall "vague description"
|
|
234
|
+
/memories # List recent
|
|
235
|
+
/memory-export # Export to file
|
|
282
236
|
```
|
|
283
237
|
|
|
284
238
|
---
|
|
@@ -287,260 +241,149 @@ Migrating from OpenClaw (koclaw)? We got you:
|
|
|
287
241
|
|
|
288
242
|
Global config: `~/.0xkobold/config.json`
|
|
289
243
|
|
|
290
|
-
### Option 1: Ollama (Local - Default)
|
|
291
|
-
|
|
292
244
|
```json
|
|
293
245
|
{
|
|
294
|
-
"version": "0.
|
|
246
|
+
"version": "0.5.0",
|
|
295
247
|
"llm": {
|
|
296
248
|
"provider": "ollama",
|
|
297
249
|
"model": "qwen2.5-coder:14b",
|
|
298
|
-
"baseUrl": "http://localhost:11434"
|
|
299
|
-
"maxTokens": 4000,
|
|
300
|
-
"temperature": 0.7
|
|
250
|
+
"baseUrl": "http://localhost:11434"
|
|
301
251
|
},
|
|
302
|
-
"
|
|
303
|
-
"
|
|
304
|
-
"
|
|
305
|
-
}
|
|
306
|
-
}
|
|
307
|
-
```
|
|
308
|
-
|
|
309
|
-
**Setup:**
|
|
310
|
-
```bash
|
|
311
|
-
# Install Ollama
|
|
312
|
-
curl -fsSL https://ollama.com/install.sh | sh
|
|
313
|
-
|
|
314
|
-
# Pull a model
|
|
315
|
-
ollama pull qwen2.5-coder:14b
|
|
316
|
-
|
|
317
|
-
# Start Ollama
|
|
318
|
-
ollama serve
|
|
319
|
-
```
|
|
320
|
-
|
|
321
|
-
### Option 2: Claude (Cloud)
|
|
322
|
-
|
|
323
|
-
```json
|
|
324
|
-
{
|
|
325
|
-
"version": "0.3.0",
|
|
326
|
-
"llm": {
|
|
327
|
-
"provider": "claude",
|
|
328
|
-
"model": "claude-3-sonnet-20240229",
|
|
329
|
-
"apiKey": "sk-ant-xxx",
|
|
330
|
-
"maxTokens": 4000,
|
|
331
|
-
"temperature": 0.7
|
|
332
|
-
}
|
|
333
|
-
}
|
|
334
|
-
```
|
|
335
|
-
|
|
336
|
-
**Setup:**
|
|
337
|
-
```bash
|
|
338
|
-
# Get API key from https://console.anthropic.com
|
|
339
|
-
export ANTHROPIC_API_KEY=sk-ant-xxx
|
|
340
|
-
```
|
|
341
|
-
|
|
342
|
-
### Option 3: OpenAI (Cloud)
|
|
343
|
-
|
|
344
|
-
```json
|
|
345
|
-
{
|
|
346
|
-
"version": "0.3.0",
|
|
347
|
-
"llm": {
|
|
348
|
-
"provider": "openai",
|
|
349
|
-
"model": "gpt-4",
|
|
350
|
-
"apiKey": "sk-xxx",
|
|
351
|
-
"maxTokens": 4000,
|
|
352
|
-
"temperature": 0.7
|
|
353
|
-
}
|
|
354
|
-
}
|
|
355
|
-
```
|
|
356
|
-
|
|
357
|
-
### Full Example with All Features
|
|
358
|
-
|
|
359
|
-
```json
|
|
360
|
-
{
|
|
361
|
-
"version": "0.3.0",
|
|
362
|
-
"persona": {
|
|
363
|
-
"name": "0xKobold",
|
|
364
|
-
"emoji": "🐉"
|
|
252
|
+
"agents": {
|
|
253
|
+
"default": "assistant",
|
|
254
|
+
"maxConcurrent": 5
|
|
365
255
|
},
|
|
366
|
-
"
|
|
367
|
-
"
|
|
368
|
-
"
|
|
369
|
-
"baseUrl": "http://localhost:11434",
|
|
370
|
-
"maxTokens": 4000,
|
|
371
|
-
"temperature": 0.7
|
|
256
|
+
"memory": {
|
|
257
|
+
"enabled": true,
|
|
258
|
+
"semanticSearch": true
|
|
372
259
|
},
|
|
373
260
|
"gateway": {
|
|
374
261
|
"enabled": true,
|
|
375
|
-
"port":
|
|
376
|
-
"host": "
|
|
377
|
-
"remote": {
|
|
378
|
-
"enabled": false
|
|
379
|
-
}
|
|
262
|
+
"port": 18789,
|
|
263
|
+
"host": "0.0.0.0"
|
|
380
264
|
},
|
|
381
265
|
"channels": {
|
|
382
|
-
"discord": { "enabled": false }
|
|
383
|
-
"whatsapp": { "enabled": true },
|
|
384
|
-
"telegram": { "enabled": false },
|
|
385
|
-
"slack": { "enabled": false }
|
|
266
|
+
"discord": { "enabled": false }
|
|
386
267
|
}
|
|
387
268
|
}
|
|
388
269
|
```
|
|
389
270
|
|
|
390
271
|
---
|
|
391
272
|
|
|
392
|
-
##
|
|
273
|
+
## Architecture
|
|
393
274
|
|
|
394
|
-
###
|
|
395
|
-
```bash
|
|
396
|
-
0xkobold setup # Interactive setup
|
|
397
|
-
0xkobold tui # Start TUI (default)
|
|
398
|
-
0xkobold tui --local # Local project mode
|
|
399
|
-
0xkobold tui --remote <url> # Connect to remote gateway
|
|
400
|
-
```
|
|
275
|
+
### Extension-Based
|
|
401
276
|
|
|
402
|
-
### Channels
|
|
403
|
-
```bash
|
|
404
|
-
0xkobold whatsapp start|stop|status|send
|
|
405
|
-
0xkobold telegram start|stop|status
|
|
406
|
-
0xkobold slack webhook <message>
|
|
407
277
|
```
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
278
|
+
src/extensions/
|
|
279
|
+
├── core/
|
|
280
|
+
│ ├── agent-orchestrator-extension.ts # Multi-agent orchestration
|
|
281
|
+
│ ├── generative-agents-extension.ts # Memory, reflection, planning
|
|
282
|
+
│ ├── perennial-memory-extension.ts # Semantic memory (Ollama)
|
|
283
|
+
│ ├── gateway-extension.ts # WebSocket server
|
|
284
|
+
│ ├── discord-extension.ts # Discord bot
|
|
285
|
+
│ └── ...
|
|
286
|
+
└── community/
|
|
287
|
+
├── draconic-subagents-wrapper.ts # PI ecosystem bridge
|
|
288
|
+
└── ...
|
|
414
289
|
```
|
|
415
290
|
|
|
416
|
-
###
|
|
417
|
-
```bash
|
|
418
|
-
0xkobold device init <name>
|
|
419
|
-
0xkobold device token generate
|
|
420
|
-
0xkobold device list
|
|
421
|
-
```
|
|
291
|
+
### Event-Driven
|
|
422
292
|
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
0xkobold migrate --dry-run|live
|
|
427
|
-
0xkobold status
|
|
428
|
-
0xkobold logs
|
|
293
|
+
```typescript
|
|
294
|
+
eventBus.emit('agent.spawned', payload);
|
|
295
|
+
eventBus.on('agent.spawned', handler);
|
|
429
296
|
```
|
|
430
297
|
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
## Compared to OpenClaw
|
|
434
|
-
|
|
435
|
-
| Metric | OpenClaw | 0xKobold v0.3.0 | Advantage |
|
|
436
|
-
|--------|----------|-----------------|-----------|
|
|
437
|
-
| **Lines of Code** | ~60,000 | ~8,000 | 7.5x simpler |
|
|
438
|
-
| **Dependencies** | 100+ | ~20 | 5x lighter |
|
|
439
|
-
| **Setup Time** | 30 min | 5 min | 6x faster |
|
|
440
|
-
| **Channels** | 5 | 4 | Feature parity |
|
|
441
|
-
| **Security** | ✅ | ✅ | Feature parity |
|
|
442
|
-
| **Media** | ✅ | ✅ | Feature parity |
|
|
443
|
-
| **Remote/VPS** | ✅ | ✅ | Feature parity |
|
|
444
|
-
| **Tailscale** | ✅ | ✅ | Feature parity |
|
|
298
|
+
### Key Components
|
|
445
299
|
|
|
446
|
-
|
|
300
|
+
| Component | Purpose |
|
|
301
|
+
|-----------|---------|
|
|
302
|
+
| `src/agent/` | Agent runtime with subagent support |
|
|
303
|
+
| `src/gateway/` | WebSocket gateway (port 18789) |
|
|
304
|
+
| `src/memory/` | Conversation persistence |
|
|
305
|
+
| `src/skills/` | Hot-reload skill system |
|
|
306
|
+
| `src/tui/` | Terminal UI (React-based) |
|
|
307
|
+
| `src/event-bus/` | Decoupled event system |
|
|
447
308
|
|
|
448
309
|
---
|
|
449
310
|
|
|
450
|
-
##
|
|
311
|
+
## Testing
|
|
451
312
|
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
313
|
+
```bash
|
|
314
|
+
# Run all tests
|
|
315
|
+
bun test
|
|
455
316
|
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
});
|
|
317
|
+
# Specific test suites
|
|
318
|
+
bun test test/unit/extensions/generative-agents.test.ts
|
|
319
|
+
bun test test/integration/
|
|
320
|
+
bun test test/e2e/
|
|
461
321
|
|
|
462
|
-
|
|
463
|
-
|
|
322
|
+
# Test coverage
|
|
323
|
+
bun test --coverage
|
|
464
324
|
```
|
|
465
325
|
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
const runner = getDockerRunner({
|
|
471
|
-
memoryLimit: "256m",
|
|
472
|
-
cpuLimit: "0.5",
|
|
473
|
-
network: "none",
|
|
474
|
-
});
|
|
475
|
-
|
|
476
|
-
const result = await runner.run({
|
|
477
|
-
command: "node",
|
|
478
|
-
args: ["script.js"],
|
|
479
|
-
});
|
|
480
|
-
```
|
|
326
|
+
**Test Suites:**
|
|
327
|
+
- Unit: Core logic (scoring, relevance, parsing)
|
|
328
|
+
- Integration: Database operations, persistence
|
|
329
|
+
- E2E: Full agent lifecycle (observe → reflect → plan)
|
|
481
330
|
|
|
482
|
-
|
|
483
|
-
```typescript
|
|
484
|
-
import { getDuplicateDetector } from "0xkobold/skills";
|
|
331
|
+
---
|
|
485
332
|
|
|
486
|
-
|
|
487
|
-
const result = await detector.check("New feature");
|
|
333
|
+
## Project Structure
|
|
488
334
|
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
335
|
+
```
|
|
336
|
+
0xKobold/
|
|
337
|
+
├── src/
|
|
338
|
+
│ ├── agent/ # Agent runtime & orchestration
|
|
339
|
+
│ ├── approval/ # Risk-based approval
|
|
340
|
+
│ ├── channels/ # Discord integration
|
|
341
|
+
│ ├── cli/ # CLI commands
|
|
342
|
+
│ ├── config/ # Configuration
|
|
343
|
+
│ ├── discord/ # Discord bot
|
|
344
|
+
│ ├── event-bus/ # Event system
|
|
345
|
+
│ ├── extensions/ # Extensions
|
|
346
|
+
│ │ ├── core/ # Built-in extensions
|
|
347
|
+
│ │ └── community/ # Community wrappers
|
|
348
|
+
│ ├── gateway/ # WebSocket gateway
|
|
349
|
+
│ ├── llm/ # LLM providers (Ollama)
|
|
350
|
+
│ ├── memory/ # Persistence layer
|
|
351
|
+
│ ├── skills/ # Skill system
|
|
352
|
+
│ │ ├── builtin/ # Built-in skills
|
|
353
|
+
│ │ └── loader.ts # Hot-reload logic
|
|
354
|
+
│ ├── tui/ # Terminal UI
|
|
355
|
+
│ └── utils/ # Utilities (nl-patterns.ts)
|
|
356
|
+
├── skills/ # Your custom skills (hot-reloaded)
|
|
357
|
+
├── test/ # Test suites
|
|
358
|
+
│ ├── unit/
|
|
359
|
+
│ ├── integration/
|
|
360
|
+
│ └── e2e/
|
|
361
|
+
├── docs/ # Documentation
|
|
362
|
+
│ ├── archive/ # Historical docs
|
|
363
|
+
│ ├── research/ # Research notes
|
|
364
|
+
│ └── usage.md, workflow.md # Living docs
|
|
365
|
+
└── scripts/ # Deployment scripts
|
|
492
366
|
```
|
|
493
367
|
|
|
494
368
|
---
|
|
495
369
|
|
|
496
|
-
##
|
|
370
|
+
## Key Files
|
|
497
371
|
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
│ │ - File Ops │ │ - Auth Tokens │ │
|
|
505
|
-
│ └─────────────────┘ └────────────┬─────────────┘ │
|
|
506
|
-
│ │ │ │
|
|
507
|
-
│ │ Local Files │ WebSocket │
|
|
508
|
-
│ │ │ │
|
|
509
|
-
│ ┌──────▼──────────────────┐ ┌─────────▼──────────┐ │
|
|
510
|
-
│ │ .0xkobold/ (project) │ │ ~/.0xkobold/ │ │
|
|
511
|
-
│ │ - workspace.db │ │ - config.json │ │
|
|
512
|
-
│ │ - MEMORY.md │ │ - identity │ │
|
|
513
|
-
│ └────────────────────────┘ └──────────────────────┘ │
|
|
514
|
-
└─────────────────────────────────────────────────────────────┘
|
|
515
|
-
│
|
|
516
|
-
│ wss:// or Tailscale
|
|
517
|
-
▼
|
|
518
|
-
┌─────────────────────────────────────────────────────────────┐
|
|
519
|
-
│ VPS (Remote) OR Local │
|
|
520
|
-
│ ┌────────────────────────────────────────────────────┐ │
|
|
521
|
-
│ │ Gateway Server (Bun) │ │
|
|
522
|
-
│ │ - WebSocket Server │ │
|
|
523
|
-
│ │ - Multi-client Support │ │
|
|
524
|
-
│ └────────────────┬───────────────────────────────────┘ │
|
|
525
|
-
│ │ │
|
|
526
|
-
│ ┌─────────┼─────────┐ │
|
|
527
|
-
│ ▼ ▼ ▼ │
|
|
528
|
-
│ ┌──────────┐ ┌────────┐ ┌──────────┐ │
|
|
529
|
-
│ │ Claude │ │ Docker │ │ Channels │ │
|
|
530
|
-
│ │ API │ │ Sandbox│ │ (Discord│ │
|
|
531
|
-
│ │ │ │ │ │ WhatsApp│ │
|
|
532
|
-
│ └──────────┘ └────────┘ └──────────┘ │
|
|
533
|
-
└─────────────────────────────────────────────────────────────┘
|
|
534
|
-
```
|
|
372
|
+
- `src/pi-config.ts` - PI framework configuration
|
|
373
|
+
- `src/extensions/core/generative-agents-extension.ts` - Generative agents
|
|
374
|
+
- `src/utils/nl-patterns.ts` - Natural language parsing
|
|
375
|
+
- `~/.0xkobold/config.json` - User configuration
|
|
376
|
+
- `~/.0xkobold/memory/perennial/knowledge.db` - Semantic memory
|
|
377
|
+
- `CLAUDE.md` - AI assistant context
|
|
535
378
|
|
|
536
379
|
---
|
|
537
380
|
|
|
538
381
|
## License
|
|
539
382
|
|
|
540
|
-
MIT ©
|
|
383
|
+
MIT © 2026
|
|
541
384
|
|
|
542
385
|
---
|
|
543
386
|
|
|
544
387
|
**Built while you sleep by your Digital Familiar** 🐉
|
|
545
388
|
|
|
546
|
-
*Join the
|
|
389
|
+
*Join the evolution at [github.com/kobolds/0xKobolds](https://github.com/moikapy/0xkobold)*
|