create-openclaw-bot 5.8.2 → 5.8.4
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 +2 -2
- package/README.vi.md +2 -2
- package/dist/cli.js +11 -15
- package/dist/server/local-server.js +266 -188
- package/dist/setup/data/header.js +1 -1
- package/dist/setup/data/skills.js +2 -4
- package/dist/setup/shared/bot-config-gen.js +21 -16
- package/dist/setup/shared/workspace-gen.js +307 -475
- package/dist/web/app.js +107 -33
- package/dist/web/styles.css +477 -10
- package/node_modules/color-convert/CHANGELOG.md +54 -0
- package/package.json +1 -1
- package/dist/legacy-cli.js +0 -2812
- package/dist/setup.js +0 -6931
|
@@ -43,12 +43,10 @@
|
|
|
43
43
|
},
|
|
44
44
|
{
|
|
45
45
|
id: 'image-gen',
|
|
46
|
-
name: '
|
|
46
|
+
name: 'Tạo ảnh Infographic',
|
|
47
47
|
icon: '🎨',
|
|
48
|
-
descVi: 'Tạo ảnh
|
|
48
|
+
descVi: 'Tạo ảnh infographic, poster tự động qua 9Router', descEn: 'Generate infographic & poster images via 9Router',
|
|
49
49
|
slug: 'image-gen',
|
|
50
|
-
noteVi: 'Dùng chung OPENAI_API_KEY (DALL-E) hoặc thêm FLUX_API_KEY', noteEn: 'Uses OPENAI_API_KEY (DALL-E) or FLUX_API_KEY',
|
|
51
|
-
envVars: ['# FLUX_API_KEY=<your_flux_key> # chỉ cần nếu dùng Flux'],
|
|
52
50
|
},
|
|
53
51
|
{
|
|
54
52
|
id: 'code-interpreter',
|
|
@@ -140,18 +140,24 @@
|
|
|
140
140
|
}
|
|
141
141
|
|
|
142
142
|
// ── bindings (multi-bot or Zalo) ─────────────────────────────────────────
|
|
143
|
-
if (isMultiBot && channelKey === 'telegram') {
|
|
143
|
+
if (agentMetas.length > 0 && isMultiBot && channelKey === 'telegram') {
|
|
144
144
|
cfg.bindings = agentMetas.map((meta) => ({
|
|
145
145
|
agentId: meta.agentId,
|
|
146
146
|
match: { channel: 'telegram', accountId: meta.accountId || 'default' },
|
|
147
147
|
}));
|
|
148
|
+
} else {
|
|
149
|
+
cfg.bindings = [];
|
|
148
150
|
}
|
|
149
151
|
|
|
150
152
|
// ── channels ─────────────────────────────────────────────────────────────
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
153
|
+
if (agentMetas.length > 0) {
|
|
154
|
+
cfg.channels = buildChannelConfig({
|
|
155
|
+
channelKey, isMultiBot, groupId, agentMetas, botName: agentMetas[0]?.name || 'Bot',
|
|
156
|
+
agentId: agentMetas[0]?.agentId || 'bot',
|
|
157
|
+
});
|
|
158
|
+
} else {
|
|
159
|
+
cfg.channels = {};
|
|
160
|
+
}
|
|
155
161
|
|
|
156
162
|
// ── tools ────────────────────────────────────────────────────────────────
|
|
157
163
|
cfg.tools = { profile: 'full', exec: { host: 'gateway', security: 'full', ask: 'off' } };
|
|
@@ -179,16 +185,7 @@
|
|
|
179
185
|
auth: { mode: 'token', token: generateToken() },
|
|
180
186
|
};
|
|
181
187
|
|
|
182
|
-
// ── browser
|
|
183
|
-
if (hasBrowserDesktop) {
|
|
184
|
-
cfg.browser = {
|
|
185
|
-
enabled: true,
|
|
186
|
-
defaultProfile: 'host-chrome',
|
|
187
|
-
profiles: { 'host-chrome': { cdpUrl: 'http://127.0.0.1:9222', color: '#4285F4' } },
|
|
188
|
-
};
|
|
189
|
-
} else if (hasBrowserServer) {
|
|
190
|
-
cfg.browser = { enabled: true };
|
|
191
|
-
}
|
|
188
|
+
// ── browser (delegated to browser-automation plugin) ────────────────────
|
|
192
189
|
|
|
193
190
|
// ── skills ───────────────────────────────────────────────────────────────
|
|
194
191
|
const skillEntries = buildSkillsEntries(skills, selectedSkills);
|
|
@@ -206,7 +203,7 @@
|
|
|
206
203
|
cfg.plugins = pluginsConfig.plugins;
|
|
207
204
|
|
|
208
205
|
// ── bindings for zalouser ────────────────────────────────────────────────
|
|
209
|
-
if (isZaloPersonal(channelKey)) {
|
|
206
|
+
if (agentMetas.length > 0 && isZaloPersonal(channelKey)) {
|
|
210
207
|
cfg.bindings = cfg.bindings || [];
|
|
211
208
|
const firstAgentId = agentMetas[0]?.agentId || 'bot';
|
|
212
209
|
if (!cfg.bindings.some(b => b.match && b.match.channel === 'zalouser')) {
|
|
@@ -317,6 +314,14 @@
|
|
|
317
314
|
allow.push('zalouser');
|
|
318
315
|
}
|
|
319
316
|
|
|
317
|
+
// DuckDuckGo search plugin for web-search
|
|
318
|
+
if (selectedSkills.includes('web-search') || selectedSkills.includes('web_search')) {
|
|
319
|
+
entries['duckduckgo'] = { enabled: true };
|
|
320
|
+
if (!allow.includes('duckduckgo')) {
|
|
321
|
+
allow.push('duckduckgo');
|
|
322
|
+
}
|
|
323
|
+
}
|
|
324
|
+
|
|
320
325
|
const plugins = { entries };
|
|
321
326
|
plugins.allow = allow;
|
|
322
327
|
|