beecork 1.3.5 → 1.3.6

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 CHANGED
@@ -52,8 +52,7 @@ See [Getting Started](https://github.com/beecork/beecork/blob/main/docs/getting-
52
52
  beecork start # Start the daemon
53
53
  beecork stop # Stop the daemon
54
54
  beecork status # Check if running
55
- beecork setup # Interactive setup wizard
56
- beecork setup --full # Full setup with all options
55
+ beecork setup # Set up Beecork (Telegram + system service)
57
56
  beecork doctor # Diagnose common issues
58
57
  beecork update # Update to latest version
59
58
  beecork quickstart # Print getting-started checklist
@@ -1 +1 @@
1
- export declare function setupWizard(mode?: 'quick' | 'full'): Promise<void>;
1
+ export declare function setupWizard(): Promise<void>;
package/dist/cli/setup.js CHANGED
@@ -1,5 +1,4 @@
1
1
  import readline from 'node:readline';
2
- import crypto from 'node:crypto';
3
2
  import { execSync } from 'node:child_process';
4
3
  import fs from 'node:fs';
5
4
  import path from 'node:path';
@@ -25,7 +24,7 @@ function findClaudeBin() {
25
24
  return 'claude';
26
25
  }
27
26
  }
28
- export async function setupWizard(mode = 'quick') {
27
+ export async function setupWizard() {
29
28
  const rl = readline.createInterface({ input: process.stdin, output: process.stdout });
30
29
  console.log('\nšŸ”§ Beecork Setup\n');
31
30
  console.log('This wizard will configure Beecork to make Claude Code always-on.\n');
@@ -107,49 +106,9 @@ export async function setupWizard(mode = 'quick') {
107
106
  console.log('Invalid user ID. Must be a number.');
108
107
  return;
109
108
  }
110
- // Quick mode defaults
111
- let claudeBin = findClaudeBin();
112
- let defaultDir = os.homedir();
113
- let enableComputerUse = 'n';
114
- let apiKey = '';
115
- let scanPaths = ['~/Coding', '~/Projects', '~/code', '~/dev'];
116
- let shouldInstallService = true;
117
- const enabledCaps = [];
118
- if (mode === 'full') {
119
- // 3. Claude binary path
120
- const defaultBin = findClaudeBin();
121
- claudeBin = await ask(rl, 'Path to claude binary', defaultBin);
122
- // 4. Default working directory
123
- defaultDir = await ask(rl, 'Default working directory', os.homedir());
124
- // 5. Computer use (optional)
125
- console.log('\n Computer use (optional): Allow Claude to control your mouse, keyboard,');
126
- console.log(' and screen. This lets Beecork use any app on your computer — browsers,');
127
- console.log(' spreadsheets, design tools, internal dashboards. Powerful but requires');
128
- console.log(' granting screen recording and accessibility permissions.');
129
- console.log(' Guide: https://github.com/beecork/beecork/blob/main/docs/troubleshooting.md\n');
130
- enableComputerUse = await ask(rl, 'Enable computer use? (y/n)', 'n');
131
- // 6. Anthropic API key (optional - enables intelligent pipe)
132
- console.log('\n Intelligent routing (optional): Beecork can route messages to the right');
133
- console.log(' project automatically and track goal completion. Requires an Anthropic API key.');
134
- apiKey = await ask(rl, 'Anthropic API key (press Enter to skip)');
135
- // 6. Project scan paths
136
- if (apiKey) {
137
- const scanInput = await ask(rl, 'Project scan paths (comma-separated)', scanPaths.join(', '));
138
- scanPaths = scanInput.split(',').map(s => s.trim()).filter(Boolean);
139
- }
140
- // 7. Install as service?
141
- const installServiceAnswer = await ask(rl, 'Install as background service? (y/n)', 'y');
142
- shouldInstallService = installServiceAnswer.toLowerCase() === 'y';
143
- }
144
- // Offer full setup at end of quick mode
145
- let showExtras = mode === 'full';
146
- if (mode === 'quick') {
147
- console.log('\n āœ“ Telegram is ready!\n');
148
- const wantMore = await ask(rl, 'Configure additional features? (Discord, WhatsApp, media, capabilities) (y/n)', 'n');
149
- if (wantMore.toLowerCase() === 'y') {
150
- showExtras = true;
151
- }
152
- }
109
+ const claudeBin = findClaudeBin();
110
+ const defaultDir = os.homedir();
111
+ const scanPaths = ['~/Coding', '~/Projects', '~/code', '~/dev'];
153
112
  // Build config
154
113
  const config = {
155
114
  ...getConfig(),
@@ -160,7 +119,7 @@ export async function setupWizard(mode = 'quick') {
160
119
  claudeCode: {
161
120
  bin: claudeBin,
162
121
  defaultFlags: ['--dangerously-skip-permissions'],
163
- computerUse: enableComputerUse.toLowerCase() === 'y',
122
+ computerUse: false,
164
123
  },
165
124
  tabs: {
166
125
  default: {
@@ -175,8 +134,8 @@ export async function setupWizard(mode = 'quick') {
175
134
  maxLongTermEntries: 1000,
176
135
  },
177
136
  pipe: {
178
- enabled: !!apiKey,
179
- anthropicApiKey: apiKey,
137
+ enabled: false,
138
+ anthropicApiKey: '',
180
139
  routingModel: 'claude-haiku-4-5-20251001',
181
140
  complexModel: 'claude-sonnet-4-6-20250514',
182
141
  confidenceThreshold: 0.75,
@@ -185,144 +144,6 @@ export async function setupWizard(mode = 'quick') {
185
144
  },
186
145
  deployment: 'local',
187
146
  };
188
- if (showExtras) {
189
- // Optional: Additional channels
190
- console.log('\nOptional: Add more channels\n');
191
- console.log('You can also connect via WhatsApp, Discord, or Webhooks.');
192
- console.log('You can always add these later with: beecork discord, beecork whatsapp, etc.\n');
193
- const addDiscord = await ask(rl, 'Set up Discord? (y/n)', 'n');
194
- if (addDiscord.toLowerCase() === 'y') {
195
- console.log('\nDiscord Setup:');
196
- console.log(' 1. Go to https://discord.com/developers/applications');
197
- console.log(' 2. Click "New Application", give it a name');
198
- console.log(' 3. Go to Bot → click "Add Bot"');
199
- console.log(' 4. Copy the bot token');
200
- console.log(' 5. Under Bot → enable "Message Content Intent"');
201
- console.log(' 6. Use OAuth2 URL Generator to invite bot to your server');
202
- console.log('');
203
- console.log(' Detailed guide: https://github.com/beecork/beecork/blob/main/docs/getting-started.md\n');
204
- const discordToken = await ask(rl, 'Discord bot token (or press Enter to skip)');
205
- if (discordToken) {
206
- const discordUserId = await ask(rl, 'Your Discord user ID (right-click your name → Copy User ID)');
207
- config.discord = {
208
- token: discordToken,
209
- allowedUserIds: discordUserId ? [discordUserId] : [],
210
- };
211
- console.log(' āœ“ Discord configured\n');
212
- }
213
- }
214
- const addWhatsApp = await ask(rl, 'Set up WhatsApp? (y/n)', 'n');
215
- if (addWhatsApp.toLowerCase() === 'y') {
216
- console.log('\nWhatsApp Setup:');
217
- console.log(' WhatsApp connects via QR code scanning (like WhatsApp Web).');
218
- console.log(' When you start the daemon, a QR code appears in the terminal.');
219
- console.log(' Scan it with your phone to link your WhatsApp account.');
220
- console.log('');
221
- console.log(' Note: This uses reverse-engineered WhatsApp Web protocol.');
222
- console.log(' For personal use only — not officially supported by WhatsApp.');
223
- console.log('');
224
- console.log(' Guide: https://github.com/beecork/beecork/blob/main/docs/getting-started.md\n');
225
- const waNumber = await ask(rl, 'Your WhatsApp phone number (e.g., 14155551234)');
226
- if (waNumber) {
227
- config.whatsapp = {
228
- enabled: true,
229
- mode: 'baileys',
230
- sessionPath: `${getBeecorkHome()}/whatsapp-session`,
231
- allowedNumbers: [waNumber],
232
- };
233
- console.log(' āœ“ WhatsApp configured');
234
- console.log(' ⚠ After starting the daemon, run: beecork logs');
235
- console.log(' The QR code will appear in the logs — scan it with your phone.\n');
236
- }
237
- }
238
- const addWebhook = await ask(rl, 'Enable Webhook API? (y/n)', 'n');
239
- if (addWebhook.toLowerCase() === 'y') {
240
- const webhookPort = await ask(rl, 'Webhook port', '8374');
241
- const webhookToken = await ask(rl, 'Webhook auth token (press Enter to auto-generate)');
242
- const whToken = webhookToken || crypto.randomBytes(24).toString('base64url');
243
- config.webhook = {
244
- enabled: true,
245
- port: parseInt(webhookPort),
246
- authToken: whToken,
247
- };
248
- console.log(` āœ“ Webhook enabled on port ${webhookPort}`);
249
- if (!webhookToken)
250
- console.log(` Auth token: ${whToken}\n`);
251
- }
252
- // Optional: Media generation
253
- console.log('\nOptional: Media Generation\n');
254
- console.log('Beecork can generate images, videos, and music using AI providers.');
255
- console.log('You can add these later with: beecork media\n');
256
- const addMedia = await ask(rl, 'Set up media generation? (y/n)', 'n');
257
- if (addMedia.toLowerCase() === 'y') {
258
- const mediaGenerators = [];
259
- console.log('\nImage: 1) Nano Banana (Google) 2) DALL-E (OpenAI) 3) Stable Diffusion 4) Recraft (Vectors)');
260
- const imgChoice = await ask(rl, 'Choose image provider (1/2/3/4 or Enter to skip)');
261
- if (imgChoice === '1') {
262
- const key = await ask(rl, ' Google AI API key (from ai.google.dev)');
263
- if (key)
264
- mediaGenerators.push({ provider: 'nano-banana', apiKey: key });
265
- }
266
- else if (imgChoice === '2') {
267
- const key = await ask(rl, ' OpenAI API key');
268
- if (key)
269
- mediaGenerators.push({ provider: 'dall-e', apiKey: key });
270
- }
271
- else if (imgChoice === '3') {
272
- const key = await ask(rl, ' Stability AI API key');
273
- if (key)
274
- mediaGenerators.push({ provider: 'stable-diffusion', apiKey: key });
275
- }
276
- else if (imgChoice === '4') {
277
- const key = await ask(rl, ' Recraft API key');
278
- if (key)
279
- mediaGenerators.push({ provider: 'recraft', apiKey: key });
280
- }
281
- console.log('\nVideo: 1) Runway 2) Veo 3) Kling');
282
- const vidChoice = await ask(rl, 'Choose video provider (1/2/3 or Enter to skip)');
283
- if (vidChoice === '1') {
284
- const key = await ask(rl, ' Runway API key');
285
- if (key)
286
- mediaGenerators.push({ provider: 'runway', apiKey: key });
287
- }
288
- else if (vidChoice === '2') {
289
- const key = await ask(rl, ' Google AI API key');
290
- if (key)
291
- mediaGenerators.push({ provider: 'veo', apiKey: key });
292
- }
293
- else if (vidChoice === '3') {
294
- const key = await ask(rl, ' Kling API key');
295
- if (key)
296
- mediaGenerators.push({ provider: 'kling', apiKey: key });
297
- }
298
- console.log('\nAudio/Music: 1) ElevenLabs Music 2) Google Lyria 3) ElevenLabs SFX');
299
- const audChoice = await ask(rl, 'Choose audio provider (1/2/3 or Enter to skip)');
300
- if (audChoice === '1') {
301
- const key = await ask(rl, ' ElevenLabs API key (xi-...)');
302
- if (key)
303
- mediaGenerators.push({ provider: 'elevenlabs-music', apiKey: key });
304
- }
305
- else if (audChoice === '2') {
306
- const key = await ask(rl, ' Google AI API key (from ai.google.dev)');
307
- if (key)
308
- mediaGenerators.push({ provider: 'lyria', apiKey: key });
309
- }
310
- else if (audChoice === '3') {
311
- const key = await ask(rl, ' ElevenLabs API key (xi-...)');
312
- if (key)
313
- mediaGenerators.push({ provider: 'elevenlabs-sfx', apiKey: key });
314
- }
315
- if (mediaGenerators.length > 0) {
316
- config.mediaGenerators = mediaGenerators;
317
- console.log(`\n āœ“ ${mediaGenerators.length} media provider(s) configured`);
318
- }
319
- }
320
- console.log('You can add or change channels later with:');
321
- console.log(' beecork discord — add/reconfigure Discord');
322
- console.log(' beecork whatsapp — add/reconfigure WhatsApp');
323
- console.log(' beecork enable — add integrations (GitHub, Notion, PostgreSQL)');
324
- console.log(' beecork dashboard — manage everything from the web UI\n');
325
- }
326
147
  // Write everything
327
148
  ensureBeecorkDirs();
328
149
  saveConfig(config);
@@ -337,19 +158,6 @@ export async function setupWizard(mode = 'quick') {
337
158
  // Inject Beecork instructions into global CLAUDE.md
338
159
  injectClaudeMd();
339
160
  console.log('āœ“ Beecork tools injected into ~/.claude/CLAUDE.md');
340
- // Enable capabilities
341
- if (enabledCaps.length > 0) {
342
- const { enablePack } = await import('../capabilities/index.js');
343
- for (const cap of enabledCaps) {
344
- try {
345
- enablePack(cap.packId, cap.apiKey);
346
- console.log(`āœ“ ${cap.packId} enabled`);
347
- }
348
- catch (err) {
349
- console.log(`⚠ Failed to enable ${cap.packId}: ${err instanceof Error ? err.message : String(err)}`);
350
- }
351
- }
352
- }
353
161
  // Scan for projects if pipe is enabled
354
162
  if (config.pipe.enabled) {
355
163
  const { scanForProjects } = await import('../pipe/project-scanner.js');
@@ -363,7 +171,7 @@ export async function setupWizard(mode = 'quick') {
363
171
  closeDb();
364
172
  }
365
173
  // Install service
366
- if (shouldInstallService) {
174
+ {
367
175
  try {
368
176
  const servicePath = installService();
369
177
  console.log(`āœ“ Service installed at ${servicePath}`);
@@ -394,14 +202,17 @@ export async function setupWizard(mode = 'quick') {
394
202
  console.log(' beecork dashboard — open web control panel');
395
203
  console.log(' beecork quickstart — full getting-started checklist');
396
204
  console.log('');
397
- if (!showExtras) {
398
- console.log(' Add more features anytime:');
399
- console.log(' beecork enable github — repos, PRs, issues');
400
- console.log(' beecork enable notion — pages, databases, notes');
401
- console.log(' beecork capabilities — see all options');
402
- console.log(' beecork setup --full — full guided setup');
403
- console.log('');
404
- }
205
+ console.log(' Add more channels:');
206
+ console.log(' beecork whatsapp — connect WhatsApp');
207
+ console.log(' beecork discord — connect Discord');
208
+ console.log(' beecork webhook — enable webhook API');
209
+ console.log('');
210
+ console.log(' Add more features:');
211
+ console.log(' beecork media setup — image, video, audio generation');
212
+ console.log(' beecork enable github — repos, PRs, issues');
213
+ console.log(' beecork enable notion — pages, databases, notes');
214
+ console.log(' beecork computer-use enable — mouse, keyboard, screen control');
215
+ console.log('');
405
216
  console.log(' Need help? https://github.com/beecork/beecork/blob/main/docs/troubleshooting.md\n');
406
217
  }
407
218
  finally {
package/dist/index.js CHANGED
@@ -11,11 +11,9 @@ program
11
11
  .description('Claude Code always-on infrastructure — a phone number, a memory, and an alarm clock');
12
12
  program
13
13
  .command('setup')
14
- .description('Set up Beecork')
15
- .option('--quick', 'Quick setup: just Telegram, done in 60 seconds')
16
- .option('--full', 'Full guided setup: all options')
17
- .action(async (options) => {
18
- await setupWizard(options.full ? 'full' : options.quick ? 'quick' : 'quick');
14
+ .description('Set up Beecork (Telegram + system service)')
15
+ .action(async () => {
16
+ await setupWizard();
19
17
  });
20
18
  program
21
19
  .command('start')
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "beecork",
3
- "version": "1.3.5",
3
+ "version": "1.3.6",
4
4
  "description": "Claude Code always-on infrastructure — a phone number, a memory, and an alarm clock",
5
5
  "type": "module",
6
6
  "bin": {