aided-dev 1.0.0 → 1.0.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/dist/cli.js
CHANGED
|
@@ -7,7 +7,7 @@ import { discoverProjectDocuments, detectStack, formatStack, } from './discovery
|
|
|
7
7
|
import { AgentCreator, quickCreateAgent } from './agent-creator/index.js';
|
|
8
8
|
const program = new Command();
|
|
9
9
|
program
|
|
10
|
-
.name('
|
|
10
|
+
.name('aided')
|
|
11
11
|
.description('AI Development Team Orchestrator - BMAD-METHOD integration')
|
|
12
12
|
.version('1.0.0');
|
|
13
13
|
program
|
|
@@ -58,7 +58,7 @@ program
|
|
|
58
58
|
});
|
|
59
59
|
program
|
|
60
60
|
.command('config')
|
|
61
|
-
.description('Configure
|
|
61
|
+
.description('Configure aided settings')
|
|
62
62
|
.option('--api-key <key>', 'Set Anthropic API key')
|
|
63
63
|
.option('--show', 'Show current configuration')
|
|
64
64
|
.option('--clear', 'Clear all configuration')
|
|
@@ -82,7 +82,7 @@ program
|
|
|
82
82
|
return;
|
|
83
83
|
}
|
|
84
84
|
console.log('');
|
|
85
|
-
p.intro(chalk.bgCyan.black('
|
|
85
|
+
p.intro(chalk.bgCyan.black(' aided Configuration '));
|
|
86
86
|
const apiKey = await p.text({
|
|
87
87
|
message: 'Anthropic API key:',
|
|
88
88
|
placeholder: hasApiKey() ? '(already configured)' : 'sk-ant-...',
|
|
@@ -218,27 +218,27 @@ program
|
|
|
218
218
|
.description('Show usage examples')
|
|
219
219
|
.action(() => {
|
|
220
220
|
console.log('');
|
|
221
|
-
console.log(chalk.bold('
|
|
221
|
+
console.log(chalk.bold('aided - AI Development Team Orchestrator'));
|
|
222
222
|
console.log('');
|
|
223
223
|
console.log(chalk.cyan('Quick Start:'));
|
|
224
|
-
console.log('
|
|
225
|
-
console.log('
|
|
224
|
+
console.log(' aided config --api-key sk-ant-xxx Set your API key');
|
|
225
|
+
console.log(' aided "Add user authentication" Run a task');
|
|
226
226
|
console.log('');
|
|
227
227
|
console.log(chalk.cyan('Common Tasks:'));
|
|
228
228
|
console.log(chalk.dim(' # New feature'));
|
|
229
|
-
console.log('
|
|
229
|
+
console.log(' aided "Add password reset with email verification"');
|
|
230
230
|
console.log('');
|
|
231
231
|
console.log(chalk.dim(' # Bug fix'));
|
|
232
|
-
console.log('
|
|
232
|
+
console.log(' aided "Fix: login fails after password change"');
|
|
233
233
|
console.log('');
|
|
234
234
|
console.log(chalk.dim(' # Refactoring'));
|
|
235
|
-
console.log('
|
|
235
|
+
console.log(' aided "Refactor auth module to use dependency injection"');
|
|
236
236
|
console.log('');
|
|
237
237
|
console.log(chalk.dim(' # Testing'));
|
|
238
|
-
console.log('
|
|
238
|
+
console.log(' aided "Add unit tests for the user service"');
|
|
239
239
|
console.log('');
|
|
240
240
|
console.log(chalk.dim(' # Documentation'));
|
|
241
|
-
console.log('
|
|
241
|
+
console.log(' aided "Document all REST API endpoints"');
|
|
242
242
|
console.log('');
|
|
243
243
|
console.log(chalk.cyan('Options:'));
|
|
244
244
|
console.log(' -v, --verbose Show detailed agent output');
|
|
@@ -246,10 +246,10 @@ program
|
|
|
246
246
|
console.log(' -m, --model <model> Use different Claude model');
|
|
247
247
|
console.log('');
|
|
248
248
|
console.log(chalk.cyan('Other Commands:'));
|
|
249
|
-
console.log('
|
|
250
|
-
console.log('
|
|
251
|
-
console.log('
|
|
252
|
-
console.log('
|
|
249
|
+
console.log(' aided analyze Analyze project context');
|
|
250
|
+
console.log(' aided agents List available AI agents');
|
|
251
|
+
console.log(' aided create-agent Create a custom agent');
|
|
252
|
+
console.log(' aided config --show View configuration');
|
|
253
253
|
console.log('');
|
|
254
254
|
console.log(chalk.dim('Full documentation: https://github.com/shikharsworks/aided#readme'));
|
|
255
255
|
console.log('');
|
|
@@ -5,6 +5,7 @@ export interface OrchestratorOptions {
|
|
|
5
5
|
model?: string;
|
|
6
6
|
verbose?: boolean;
|
|
7
7
|
skipPlanning?: boolean;
|
|
8
|
+
outputDir?: string;
|
|
8
9
|
}
|
|
9
10
|
export interface WorkflowState {
|
|
10
11
|
task: string;
|
|
@@ -21,6 +22,7 @@ export declare class Orchestrator {
|
|
|
21
22
|
private repoPath;
|
|
22
23
|
private verbose;
|
|
23
24
|
private skipPlanning;
|
|
25
|
+
private outputDir;
|
|
24
26
|
private bmadLoader;
|
|
25
27
|
private agents;
|
|
26
28
|
private planner;
|
|
@@ -36,5 +38,6 @@ export declare class Orchestrator {
|
|
|
36
38
|
private formatOutputTitle;
|
|
37
39
|
private buildStepPrompt;
|
|
38
40
|
private extractTextContent;
|
|
41
|
+
private saveOutputs;
|
|
39
42
|
private printSummary;
|
|
40
43
|
}
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import Anthropic from '@anthropic-ai/sdk';
|
|
2
2
|
import ora from 'ora';
|
|
3
3
|
import chalk from 'chalk';
|
|
4
|
+
import * as fs from 'fs';
|
|
5
|
+
import * as path from 'path';
|
|
4
6
|
import { discoverProjectDocuments, detectStack, formatDocumentsForPrompt, formatStack, } from '../discovery/index.js';
|
|
5
7
|
import { getLoader } from '../bmad/index.js';
|
|
6
8
|
import { getApiKey } from '../config.js';
|
|
@@ -11,19 +13,21 @@ export class Orchestrator {
|
|
|
11
13
|
repoPath;
|
|
12
14
|
verbose;
|
|
13
15
|
skipPlanning;
|
|
16
|
+
outputDir;
|
|
14
17
|
bmadLoader;
|
|
15
18
|
agents = new Map();
|
|
16
19
|
planner = null;
|
|
17
20
|
constructor(options) {
|
|
18
21
|
const apiKey = getApiKey();
|
|
19
22
|
if (!apiKey) {
|
|
20
|
-
throw new Error('Anthropic API key not found. Run `
|
|
23
|
+
throw new Error('Anthropic API key not found. Run `aided config --api-key <key>` or set ANTHROPIC_API_KEY environment variable.');
|
|
21
24
|
}
|
|
22
25
|
this.client = new Anthropic({ apiKey });
|
|
23
26
|
this.model = options.model || 'claude-sonnet-4-20250514';
|
|
24
27
|
this.repoPath = options.repoPath;
|
|
25
28
|
this.verbose = options.verbose || false;
|
|
26
29
|
this.skipPlanning = options.skipPlanning || false;
|
|
30
|
+
this.outputDir = options.outputDir || path.join(options.repoPath, '.aided-output');
|
|
27
31
|
this.bmadLoader = getLoader();
|
|
28
32
|
}
|
|
29
33
|
async loadAgents() {
|
|
@@ -70,16 +74,16 @@ export class Orchestrator {
|
|
|
70
74
|
await this.loadAgents();
|
|
71
75
|
await this.phaseDiscover(state);
|
|
72
76
|
if (state.errors.length > 0) {
|
|
73
|
-
this.printSummary(state);
|
|
77
|
+
await this.printSummary(state);
|
|
74
78
|
return state;
|
|
75
79
|
}
|
|
76
80
|
await this.phasePlanning(state);
|
|
77
81
|
if (state.errors.length > 0 || !state.plan) {
|
|
78
|
-
this.printSummary(state);
|
|
82
|
+
await this.printSummary(state);
|
|
79
83
|
return state;
|
|
80
84
|
}
|
|
81
85
|
await this.executeplan(state);
|
|
82
|
-
this.printSummary(state);
|
|
86
|
+
await this.printSummary(state);
|
|
83
87
|
return state;
|
|
84
88
|
}
|
|
85
89
|
async phaseDiscover(state) {
|
|
@@ -358,7 +362,44 @@ Provide your output in a clear, structured format.`;
|
|
|
358
362
|
.map((block) => block.text)
|
|
359
363
|
.join('\n');
|
|
360
364
|
}
|
|
361
|
-
|
|
365
|
+
async saveOutputs(state) {
|
|
366
|
+
if (state.outputs.size === 0)
|
|
367
|
+
return undefined;
|
|
368
|
+
if (!fs.existsSync(this.outputDir)) {
|
|
369
|
+
fs.mkdirSync(this.outputDir, { recursive: true });
|
|
370
|
+
}
|
|
371
|
+
const timestamp = new Date().toISOString().replace(/[:.]/g, '-').slice(0, 19);
|
|
372
|
+
const runDir = path.join(this.outputDir, timestamp);
|
|
373
|
+
fs.mkdirSync(runDir, { recursive: true });
|
|
374
|
+
const summaryContent = `# Aided Output - ${timestamp}
|
|
375
|
+
|
|
376
|
+
## Task
|
|
377
|
+
${state.task}
|
|
378
|
+
|
|
379
|
+
## Task Type
|
|
380
|
+
${state.plan?.taskType || 'unknown'}
|
|
381
|
+
|
|
382
|
+
## Complexity
|
|
383
|
+
${state.plan?.estimatedComplexity || 'unknown'}
|
|
384
|
+
|
|
385
|
+
## Outputs Generated
|
|
386
|
+
${Array.from(state.outputs.keys()).map(k => `- ${this.formatOutputTitle(k)}`).join('\n')}
|
|
387
|
+
|
|
388
|
+
---
|
|
389
|
+
|
|
390
|
+
`;
|
|
391
|
+
fs.writeFileSync(path.join(runDir, 'README.md'), summaryContent);
|
|
392
|
+
for (const [key, content] of state.outputs) {
|
|
393
|
+
const filename = `${key.replace(/_/g, '-')}.md`;
|
|
394
|
+
const fileContent = `# ${this.formatOutputTitle(key)}
|
|
395
|
+
|
|
396
|
+
${content}
|
|
397
|
+
`;
|
|
398
|
+
fs.writeFileSync(path.join(runDir, filename), fileContent);
|
|
399
|
+
}
|
|
400
|
+
return runDir;
|
|
401
|
+
}
|
|
402
|
+
async printSummary(state) {
|
|
362
403
|
console.log('');
|
|
363
404
|
if (state.errors.length > 0) {
|
|
364
405
|
console.log(chalk.red('Workflow completed with errors:'));
|
|
@@ -370,11 +411,16 @@ Provide your output in a clear, structured format.`;
|
|
|
370
411
|
console.log(chalk.green('✓ Workflow complete!'));
|
|
371
412
|
}
|
|
372
413
|
if (state.outputs.size > 0) {
|
|
414
|
+
const outputPath = await this.saveOutputs(state);
|
|
373
415
|
console.log('');
|
|
374
416
|
console.log(chalk.dim('Outputs generated:'));
|
|
375
417
|
for (const key of state.outputs.keys()) {
|
|
376
418
|
console.log(chalk.dim(` - ${this.formatOutputTitle(key)}`));
|
|
377
419
|
}
|
|
420
|
+
if (outputPath) {
|
|
421
|
+
console.log('');
|
|
422
|
+
console.log(chalk.cyan(`📁 Outputs saved to: ${outputPath}`));
|
|
423
|
+
}
|
|
378
424
|
}
|
|
379
425
|
if (state.plan) {
|
|
380
426
|
console.log('');
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "aided-dev",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.2",
|
|
4
4
|
"description": "AI Development Team Orchestrator - BMAD-METHOD integration for automated code generation",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ai",
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"main": "dist/index.js",
|
|
27
27
|
"types": "dist/index.d.ts",
|
|
28
28
|
"bin": {
|
|
29
|
-
"
|
|
29
|
+
"aided": "bin/aidev.js"
|
|
30
30
|
},
|
|
31
31
|
"files": [
|
|
32
32
|
"dist",
|