@iservu-inc/adf-cli 0.13.0 → 0.14.1
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/.context/memory/architecture.md +40 -0
- package/.context/memory/glossary.md +19 -0
- package/.project/docs/VERSIONING-GUIDE.md +127 -0
- package/AGENTS.md +53 -0
- package/CHANGELOG.md +57 -0
- package/README.md +12 -2
- package/bin/adf.js +10 -0
- package/conductor/archive/context_synthesis_20260112/metadata.json +8 -0
- package/conductor/archive/context_synthesis_20260112/plan.md +40 -0
- package/conductor/archive/context_synthesis_20260112/spec.md +43 -0
- package/conductor/archive/verify_opencode_20260111/metadata.json +8 -0
- package/conductor/archive/verify_opencode_20260111/plan.md +34 -0
- package/conductor/archive/verify_opencode_20260111/spec.md +25 -0
- package/conductor/code_styleguides/javascript.md +51 -0
- package/conductor/product-guidelines.md +26 -0
- package/conductor/product.md +25 -0
- package/conductor/setup_state.json +1 -0
- package/conductor/tech-stack.md +28 -0
- package/conductor/tracks/bootstrap_agents_20260111/metadata.json +8 -0
- package/conductor/tracks/bootstrap_agents_20260111/plan.md +17 -0
- package/conductor/tracks/bootstrap_agents_20260111/spec.md +27 -0
- package/conductor/tracks.md +9 -0
- package/conductor/workflow.md +333 -0
- package/lib/analysis/ai-gap-analyzer.js +66 -0
- package/lib/analysis/dynamic-question-generator.js +55 -0
- package/lib/analysis/heuristic-gap-analyzer.js +45 -0
- package/lib/analysis/synthesis-engine.js +142 -0
- package/lib/commands/deploy.js +28 -2
- package/lib/commands/init.js +94 -0
- package/lib/commands/tools.js +38 -0
- package/lib/frameworks/interviewer.js +4 -3
- package/lib/generators/codex-cli-generator.js +41 -0
- package/lib/generators/index.js +33 -0
- package/lib/generators/kiro-generator.js +49 -0
- package/lib/generators/opencode-generator.js +332 -313
- package/lib/generators/trae-generator.js +34 -0
- package/lib/templates/scripts/analyze-framework-updates.js +361 -0
- package/lib/templates/scripts/build.js +608 -0
- package/lib/templates/scripts/check-framework-updates.js +118 -0
- package/lib/templates/scripts/config-helpers.js +1 -1
- package/lib/templates/scripts/deploy.js +13 -28
- package/lib/templates/scripts/init.js +110 -220
- package/lib/templates/scripts/postinstall.js +13 -0
- package/lib/templates/scripts/update-frameworks.js +28 -0
- package/lib/templates/scripts/validate-env.js +428 -0
- package/lib/templates/scripts/validate-mcp.js +471 -0
- package/lib/templates/scripts/validate.js +482 -0
- package/lib/templates/shared/agents/analyst.md +1 -1
- package/lib/templates/shared/agents/architect.md +13 -17
- package/lib/templates/shared/agents/dev.md +2 -2
- package/lib/templates/shared/agents/pm.md +1 -1
- package/lib/templates/shared/agents/qa.md +1 -1
- package/lib/templates/shared/agents/sm.md +2 -2
- package/lib/templates/shared/templates/README.md +2 -2
- package/lib/templates/shared/templates/openspec-proposal.md +2 -2
- package/lib/templates/shared/templates/prd-template.md +1 -1
- package/lib/templates/shared/templates/story-template.md +1 -1
- package/lib/utils/context-extractor.js +157 -0
- package/lib/utils/framework-detector.js +54 -0
- package/lib/utils/tool-feature-registry.js +102 -0
- package/package.json +1 -1
- package/tests/ai-gap-analyzer.test.js +38 -0
- package/tests/codex-cli-generator.test.js +29 -0
- package/tests/context-extractor.test.js +70 -0
- package/tests/deploy-integration.test.js +36 -0
- package/tests/deploy.test.js +57 -0
- package/tests/dynamic-question-generator.test.js +29 -0
- package/tests/framework-detector.test.js +55 -0
- package/tests/heuristic-gap-analyzer.test.js +46 -0
- package/tests/kiro-trae-generators.test.js +43 -0
- package/tests/opencode-generator.test.js +113 -0
- package/tests/synthesis-engine.test.js +52 -0
- package/tests/tool-feature-registry.test.js +23 -0
|
@@ -0,0 +1,482 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* AgentDevFramework Configuration Validator
|
|
5
|
+
* Validates framework configuration, tools, agents, templates, and structure
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
const fs = require('fs-extra');
|
|
9
|
+
const path = require('path');
|
|
10
|
+
const chalk = require('chalk');
|
|
11
|
+
const ora = require('ora');
|
|
12
|
+
|
|
13
|
+
const FRAMEWORK_ROOT = path.join(__dirname, '..');
|
|
14
|
+
|
|
15
|
+
// Expected structure
|
|
16
|
+
const EXPECTED_STRUCTURE = {
|
|
17
|
+
tools: [
|
|
18
|
+
'windsurf',
|
|
19
|
+
'cursor',
|
|
20
|
+
'vscode',
|
|
21
|
+
'vscode-insider',
|
|
22
|
+
'kiro',
|
|
23
|
+
'trae',
|
|
24
|
+
'claude-code',
|
|
25
|
+
'gemini-cli',
|
|
26
|
+
'codex-cli'
|
|
27
|
+
],
|
|
28
|
+
agents: [
|
|
29
|
+
'analyst.md',
|
|
30
|
+
'pm.md',
|
|
31
|
+
'architect.md',
|
|
32
|
+
'sm.md',
|
|
33
|
+
'dev.md',
|
|
34
|
+
'qa.md'
|
|
35
|
+
],
|
|
36
|
+
templates: [
|
|
37
|
+
'prp-template.md',
|
|
38
|
+
'prp_base.md',
|
|
39
|
+
'prp_story.md',
|
|
40
|
+
'prp_task.md',
|
|
41
|
+
'prp_spec.md',
|
|
42
|
+
'prp_planning.md',
|
|
43
|
+
'prd-template.md',
|
|
44
|
+
'spec-template.md',
|
|
45
|
+
'plan-template.md',
|
|
46
|
+
'tasks-template.md',
|
|
47
|
+
'story-template.md'
|
|
48
|
+
],
|
|
49
|
+
scripts: [
|
|
50
|
+
'deploy.js',
|
|
51
|
+
'init-docs.js',
|
|
52
|
+
'validate.js',
|
|
53
|
+
'validate-env.js',
|
|
54
|
+
'validate-mcp.js'
|
|
55
|
+
],
|
|
56
|
+
core: [
|
|
57
|
+
'README.md',
|
|
58
|
+
'package.json',
|
|
59
|
+
'.env.template',
|
|
60
|
+
'QUICK-START.md',
|
|
61
|
+
'AGENTDEVFRAMEWORK-CLAUDE.md'
|
|
62
|
+
]
|
|
63
|
+
};
|
|
64
|
+
|
|
65
|
+
const TOOL_CONFIGS = {
|
|
66
|
+
windsurf: { file: '.windsurfrules', required: true },
|
|
67
|
+
cursor: { files: ['.cursorrules', '.cursor/rules/dev.md'], required: true },
|
|
68
|
+
vscode: { files: ['.github/copilot-instructions.md', '.vscode/settings.json'], required: true },
|
|
69
|
+
'vscode-insider': { files: ['.github/copilot-instructions.md', '.vscode/settings.json'], required: true },
|
|
70
|
+
kiro: { files: ['product.md', 'technical.md', 'style.md'], required: true },
|
|
71
|
+
trae: { file: 'config.json', required: true },
|
|
72
|
+
'claude-code': { files: ['CLAUDE.md', '.claude/commands'], required: true },
|
|
73
|
+
'gemini-cli': { file: 'GEMINI.md', required: true },
|
|
74
|
+
'codex-cli': { files: ['instructions.md', 'config.toml'], required: true }
|
|
75
|
+
};
|
|
76
|
+
|
|
77
|
+
class FrameworkValidator {
|
|
78
|
+
constructor() {
|
|
79
|
+
this.errors = [];
|
|
80
|
+
this.warnings = [];
|
|
81
|
+
this.passed = 0;
|
|
82
|
+
this.failed = 0;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
log(message, type = 'info') {
|
|
86
|
+
const symbols = {
|
|
87
|
+
success: chalk.green('✓'),
|
|
88
|
+
error: chalk.red('✗'),
|
|
89
|
+
warning: chalk.yellow('⚠'),
|
|
90
|
+
info: chalk.blue('ℹ')
|
|
91
|
+
};
|
|
92
|
+
console.log(`${symbols[type]} ${message}`);
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
addError(message) {
|
|
96
|
+
this.errors.push(message);
|
|
97
|
+
this.failed++;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
addWarning(message) {
|
|
101
|
+
this.warnings.push(message);
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
checkFileExists(filePath, description) {
|
|
105
|
+
const fullPath = path.join(FRAMEWORK_ROOT, filePath);
|
|
106
|
+
if (fs.existsSync(fullPath)) {
|
|
107
|
+
this.passed++;
|
|
108
|
+
return true;
|
|
109
|
+
} else {
|
|
110
|
+
this.addError(`Missing ${description}: ${filePath}`);
|
|
111
|
+
return false;
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
checkDirExists(dirPath, description) {
|
|
116
|
+
const fullPath = path.join(FRAMEWORK_ROOT, dirPath);
|
|
117
|
+
if (fs.existsSync(fullPath) && fs.statSync(fullPath).isDirectory()) {
|
|
118
|
+
this.passed++;
|
|
119
|
+
return true;
|
|
120
|
+
} else {
|
|
121
|
+
this.addError(`Missing ${description} directory: ${dirPath}`);
|
|
122
|
+
return false;
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
validateCoreFiles() {
|
|
127
|
+
console.log(chalk.bold('\n📁 Validating Core Files...'));
|
|
128
|
+
|
|
129
|
+
EXPECTED_STRUCTURE.core.forEach(file => {
|
|
130
|
+
this.checkFileExists(file, 'core file');
|
|
131
|
+
});
|
|
132
|
+
|
|
133
|
+
// Check package.json validity
|
|
134
|
+
try {
|
|
135
|
+
const pkgPath = path.join(FRAMEWORK_ROOT, 'package.json');
|
|
136
|
+
const pkg = require(pkgPath);
|
|
137
|
+
|
|
138
|
+
if (!pkg.name || !pkg.version || !pkg.scripts) {
|
|
139
|
+
this.addError('package.json is missing required fields');
|
|
140
|
+
} else {
|
|
141
|
+
this.log('package.json is valid', 'success');
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
// Check required scripts
|
|
145
|
+
const requiredScripts = ['deploy', 'validate', 'init-docs'];
|
|
146
|
+
requiredScripts.forEach(script => {
|
|
147
|
+
if (!pkg.scripts[script]) {
|
|
148
|
+
this.addWarning(`Missing script in package.json: ${script}`);
|
|
149
|
+
}
|
|
150
|
+
});
|
|
151
|
+
} catch (error) {
|
|
152
|
+
this.addError(`Failed to parse package.json: ${error.message}`);
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
validateDirectoryStructure() {
|
|
157
|
+
console.log(chalk.bold('\n📂 Validating Directory Structure...'));
|
|
158
|
+
|
|
159
|
+
const dirs = [
|
|
160
|
+
{ path: 'shared', desc: 'Shared resources' },
|
|
161
|
+
{ path: 'shared/agents', desc: 'Agents' },
|
|
162
|
+
{ path: 'shared/templates', desc: 'Templates' },
|
|
163
|
+
{ path: 'shared/memory', desc: 'Memory/Constitution' },
|
|
164
|
+
{ path: 'shared/mcp', desc: 'MCP configuration' },
|
|
165
|
+
{ path: 'tools', desc: 'Tool configurations' },
|
|
166
|
+
{ path: 'scripts', desc: 'Scripts' },
|
|
167
|
+
{ path: 'docs', desc: 'Documentation' },
|
|
168
|
+
{ path: 'examples', desc: 'Examples' }
|
|
169
|
+
];
|
|
170
|
+
|
|
171
|
+
dirs.forEach(({ path: dirPath, desc }) => {
|
|
172
|
+
this.checkDirExists(dirPath, desc);
|
|
173
|
+
});
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
validateAgents() {
|
|
177
|
+
console.log(chalk.bold('\n🤖 Validating Agent Definitions...'));
|
|
178
|
+
|
|
179
|
+
EXPECTED_STRUCTURE.agents.forEach(agent => {
|
|
180
|
+
const agentPath = path.join('shared', 'agents', agent);
|
|
181
|
+
if (this.checkFileExists(agentPath, `agent ${agent}`)) {
|
|
182
|
+
// Validate agent content
|
|
183
|
+
try {
|
|
184
|
+
const content = fs.readFileSync(
|
|
185
|
+
path.join(FRAMEWORK_ROOT, agentPath),
|
|
186
|
+
'utf-8'
|
|
187
|
+
);
|
|
188
|
+
|
|
189
|
+
// Check for required sections
|
|
190
|
+
const requiredSections = [
|
|
191
|
+
'Your Role',
|
|
192
|
+
'Context Engineering',
|
|
193
|
+
'Constitutional'
|
|
194
|
+
];
|
|
195
|
+
|
|
196
|
+
const missingSections = requiredSections.filter(
|
|
197
|
+
section => !content.includes(section)
|
|
198
|
+
);
|
|
199
|
+
|
|
200
|
+
if (missingSections.length > 0) {
|
|
201
|
+
this.addWarning(
|
|
202
|
+
`Agent ${agent} missing sections: ${missingSections.join(', ')}`
|
|
203
|
+
);
|
|
204
|
+
}
|
|
205
|
+
} catch (error) {
|
|
206
|
+
this.addError(`Failed to read agent ${agent}: ${error.message}`);
|
|
207
|
+
}
|
|
208
|
+
}
|
|
209
|
+
});
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
validateTemplates() {
|
|
213
|
+
console.log(chalk.bold('\n📝 Validating Templates...'));
|
|
214
|
+
|
|
215
|
+
EXPECTED_STRUCTURE.templates.forEach(template => {
|
|
216
|
+
const templatePath = path.join('shared', 'templates', template);
|
|
217
|
+
if (this.checkFileExists(templatePath, `template ${template}`)) {
|
|
218
|
+
// Validate template content
|
|
219
|
+
try {
|
|
220
|
+
const content = fs.readFileSync(
|
|
221
|
+
path.join(FRAMEWORK_ROOT, templatePath),
|
|
222
|
+
'utf-8'
|
|
223
|
+
);
|
|
224
|
+
|
|
225
|
+
// Check for META section in PRP templates
|
|
226
|
+
if (template.startsWith('prp')) {
|
|
227
|
+
if (!content.includes('META')) {
|
|
228
|
+
this.addWarning(`PRP template ${template} missing META section`);
|
|
229
|
+
}
|
|
230
|
+
}
|
|
231
|
+
} catch (error) {
|
|
232
|
+
this.addError(`Failed to read template ${template}: ${error.message}`);
|
|
233
|
+
}
|
|
234
|
+
}
|
|
235
|
+
});
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
validateToolConfigs() {
|
|
239
|
+
console.log(chalk.bold('\n🔧 Validating Tool Configurations...'));
|
|
240
|
+
|
|
241
|
+
EXPECTED_STRUCTURE.tools.forEach(tool => {
|
|
242
|
+
const toolDir = path.join('tools', tool);
|
|
243
|
+
|
|
244
|
+
if (!this.checkDirExists(toolDir, `tool ${tool}`)) {
|
|
245
|
+
return;
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
const config = TOOL_CONFIGS[tool];
|
|
249
|
+
|
|
250
|
+
if (config.file) {
|
|
251
|
+
// Single file configuration
|
|
252
|
+
this.checkFileExists(
|
|
253
|
+
path.join(toolDir, config.file),
|
|
254
|
+
`${tool} config file`
|
|
255
|
+
);
|
|
256
|
+
} else if (config.files) {
|
|
257
|
+
// Multiple files configuration
|
|
258
|
+
config.files.forEach(file => {
|
|
259
|
+
const filePath = path.join(toolDir, file);
|
|
260
|
+
this.checkFileExists(filePath, `${tool} config file`);
|
|
261
|
+
});
|
|
262
|
+
}
|
|
263
|
+
|
|
264
|
+
// Special validation for Claude Code slash commands
|
|
265
|
+
if (tool === 'claude-code') {
|
|
266
|
+
const commandsDir = path.join(FRAMEWORK_ROOT, toolDir, '.claude', 'commands');
|
|
267
|
+
if (fs.existsSync(commandsDir)) {
|
|
268
|
+
const commands = fs.readdirSync(commandsDir).filter(f => f.endsWith('.md'));
|
|
269
|
+
if (commands.length > 0) {
|
|
270
|
+
this.log(`Found ${commands.length} Claude Code slash commands`, 'success');
|
|
271
|
+
} else {
|
|
272
|
+
this.addWarning('No slash commands found for Claude Code');
|
|
273
|
+
}
|
|
274
|
+
}
|
|
275
|
+
}
|
|
276
|
+
});
|
|
277
|
+
}
|
|
278
|
+
|
|
279
|
+
validateScripts() {
|
|
280
|
+
console.log(chalk.bold('\n📜 Validating Scripts...'));
|
|
281
|
+
|
|
282
|
+
EXPECTED_STRUCTURE.scripts.forEach(script => {
|
|
283
|
+
const scriptPath = path.join('scripts', script);
|
|
284
|
+
if (this.checkFileExists(scriptPath, `script ${script}`)) {
|
|
285
|
+
// Check if script is executable (has shebang)
|
|
286
|
+
try {
|
|
287
|
+
const content = fs.readFileSync(
|
|
288
|
+
path.join(FRAMEWORK_ROOT, scriptPath),
|
|
289
|
+
'utf-8'
|
|
290
|
+
);
|
|
291
|
+
|
|
292
|
+
if (!content.startsWith('#!/usr/bin/env node')) {
|
|
293
|
+
this.addWarning(`Script ${script} missing shebang`);
|
|
294
|
+
}
|
|
295
|
+
} catch (error) {
|
|
296
|
+
this.addError(`Failed to read script ${script}: ${error.message}`);
|
|
297
|
+
}
|
|
298
|
+
}
|
|
299
|
+
});
|
|
300
|
+
}
|
|
301
|
+
|
|
302
|
+
validateConstitution() {
|
|
303
|
+
console.log(chalk.bold('\n📜 Validating Constitution...'));
|
|
304
|
+
|
|
305
|
+
const constitutionPath = path.join('shared', 'memory', 'constitution.md');
|
|
306
|
+
|
|
307
|
+
if (this.checkFileExists(constitutionPath, 'constitution')) {
|
|
308
|
+
try {
|
|
309
|
+
const content = fs.readFileSync(
|
|
310
|
+
path.join(FRAMEWORK_ROOT, constitutionPath),
|
|
311
|
+
'utf-8'
|
|
312
|
+
);
|
|
313
|
+
|
|
314
|
+
// Check for 9 articles
|
|
315
|
+
const articles = content.match(/## Article \d+:/g);
|
|
316
|
+
if (articles && articles.length === 9) {
|
|
317
|
+
this.log('Constitution has all 9 articles', 'success');
|
|
318
|
+
} else {
|
|
319
|
+
this.addError(
|
|
320
|
+
`Constitution should have 9 articles, found ${articles ? articles.length : 0}`
|
|
321
|
+
);
|
|
322
|
+
}
|
|
323
|
+
|
|
324
|
+
// Check for required principles
|
|
325
|
+
const requiredPrinciples = [
|
|
326
|
+
'Specification-First',
|
|
327
|
+
'Test-First',
|
|
328
|
+
'Simplicity First',
|
|
329
|
+
'Context-Engineered',
|
|
330
|
+
'Memory Management',
|
|
331
|
+
'Modular Agent',
|
|
332
|
+
'Constitutional Checks',
|
|
333
|
+
'Security by Design',
|
|
334
|
+
'Performance as Requirement'
|
|
335
|
+
];
|
|
336
|
+
|
|
337
|
+
requiredPrinciples.forEach(principle => {
|
|
338
|
+
if (!content.includes(principle)) {
|
|
339
|
+
this.addWarning(`Constitution missing principle: ${principle}`);
|
|
340
|
+
}
|
|
341
|
+
});
|
|
342
|
+
} catch (error) {
|
|
343
|
+
this.addError(`Failed to validate constitution: ${error.message}`);
|
|
344
|
+
}
|
|
345
|
+
}
|
|
346
|
+
}
|
|
347
|
+
|
|
348
|
+
validateMCPConfig() {
|
|
349
|
+
console.log(chalk.bold('\n🔌 Validating MCP Configuration...'));
|
|
350
|
+
|
|
351
|
+
const mcpPath = path.join('shared', 'mcp', 'mcp-config.json');
|
|
352
|
+
|
|
353
|
+
if (this.checkFileExists(mcpPath, 'MCP config')) {
|
|
354
|
+
try {
|
|
355
|
+
const config = require(path.join(FRAMEWORK_ROOT, mcpPath));
|
|
356
|
+
|
|
357
|
+
// Check for required MCP tools
|
|
358
|
+
const requiredTools = [
|
|
359
|
+
'context7',
|
|
360
|
+
'brave-search',
|
|
361
|
+
'mem0',
|
|
362
|
+
'clear-thought',
|
|
363
|
+
'archon',
|
|
364
|
+
'openmemory',
|
|
365
|
+
'deepwiki'
|
|
366
|
+
];
|
|
367
|
+
|
|
368
|
+
const configuredTools = Object.keys(config.mcpServers || {});
|
|
369
|
+
|
|
370
|
+
requiredTools.forEach(tool => {
|
|
371
|
+
if (configuredTools.includes(tool)) {
|
|
372
|
+
this.passed++;
|
|
373
|
+
} else {
|
|
374
|
+
this.addWarning(`MCP tool not configured: ${tool}`);
|
|
375
|
+
}
|
|
376
|
+
});
|
|
377
|
+
|
|
378
|
+
this.log(`MCP configuration valid with ${configuredTools.length} tools`, 'success');
|
|
379
|
+
} catch (error) {
|
|
380
|
+
this.addError(`Failed to parse MCP config: ${error.message}`);
|
|
381
|
+
}
|
|
382
|
+
}
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
generateReport() {
|
|
386
|
+
console.log(chalk.bold('\n\n📊 Validation Report\n'));
|
|
387
|
+
console.log(chalk.bold('━'.repeat(50)));
|
|
388
|
+
|
|
389
|
+
// Summary
|
|
390
|
+
console.log(chalk.bold('\nSummary:'));
|
|
391
|
+
console.log(` ${chalk.green('✓')} Passed: ${chalk.bold(this.passed)}`);
|
|
392
|
+
console.log(` ${chalk.red('✗')} Failed: ${chalk.bold(this.failed)}`);
|
|
393
|
+
console.log(` ${chalk.yellow('⚠')} Warnings: ${chalk.bold(this.warnings.length)}`);
|
|
394
|
+
|
|
395
|
+
// Errors
|
|
396
|
+
if (this.errors.length > 0) {
|
|
397
|
+
console.log(chalk.bold('\n\nErrors:'));
|
|
398
|
+
this.errors.forEach((error, i) => {
|
|
399
|
+
console.log(` ${i + 1}. ${chalk.red(error)}`);
|
|
400
|
+
});
|
|
401
|
+
}
|
|
402
|
+
|
|
403
|
+
// Warnings
|
|
404
|
+
if (this.warnings.length > 0) {
|
|
405
|
+
console.log(chalk.bold('\n\nWarnings:'));
|
|
406
|
+
this.warnings.forEach((warning, i) => {
|
|
407
|
+
console.log(` ${i + 1}. ${chalk.yellow(warning)}`);
|
|
408
|
+
});
|
|
409
|
+
}
|
|
410
|
+
|
|
411
|
+
console.log(chalk.bold('\n' + '━'.repeat(50)));
|
|
412
|
+
|
|
413
|
+
// Overall status
|
|
414
|
+
const total = this.passed + this.failed;
|
|
415
|
+
const percentage = total > 0 ? Math.round((this.passed / total) * 100) : 0;
|
|
416
|
+
|
|
417
|
+
console.log(chalk.bold('\nOverall Status:'));
|
|
418
|
+
if (this.failed === 0) {
|
|
419
|
+
console.log(chalk.green(` ✓ All checks passed (${percentage}%)`));
|
|
420
|
+
console.log(chalk.green('\n Framework is valid and ready for deployment!\n'));
|
|
421
|
+
} else if (percentage >= 80) {
|
|
422
|
+
console.log(chalk.yellow(` ⚠ Mostly valid (${percentage}%)`));
|
|
423
|
+
console.log(chalk.yellow(`\n Framework has ${this.failed} issues that should be addressed.\n`));
|
|
424
|
+
} else {
|
|
425
|
+
console.log(chalk.red(` ✗ Validation failed (${percentage}%)`));
|
|
426
|
+
console.log(chalk.red(`\n Framework has ${this.failed} critical issues.\n`));
|
|
427
|
+
}
|
|
428
|
+
|
|
429
|
+
return this.failed === 0;
|
|
430
|
+
}
|
|
431
|
+
|
|
432
|
+
async run() {
|
|
433
|
+
console.log(chalk.bold.cyan('\n🔍 AgentDevFramework Configuration Validator\n'));
|
|
434
|
+
|
|
435
|
+
const spinner = ora('Starting validation...').start();
|
|
436
|
+
|
|
437
|
+
try {
|
|
438
|
+
spinner.text = 'Validating core files...';
|
|
439
|
+
this.validateCoreFiles();
|
|
440
|
+
|
|
441
|
+
spinner.text = 'Validating directory structure...';
|
|
442
|
+
this.validateDirectoryStructure();
|
|
443
|
+
|
|
444
|
+
spinner.text = 'Validating agents...';
|
|
445
|
+
this.validateAgents();
|
|
446
|
+
|
|
447
|
+
spinner.text = 'Validating templates...';
|
|
448
|
+
this.validateTemplates();
|
|
449
|
+
|
|
450
|
+
spinner.text = 'Validating tool configurations...';
|
|
451
|
+
this.validateToolConfigs();
|
|
452
|
+
|
|
453
|
+
spinner.text = 'Validating scripts...';
|
|
454
|
+
this.validateScripts();
|
|
455
|
+
|
|
456
|
+
spinner.text = 'Validating constitution...';
|
|
457
|
+
this.validateConstitution();
|
|
458
|
+
|
|
459
|
+
spinner.text = 'Validating MCP configuration...';
|
|
460
|
+
this.validateMCPConfig();
|
|
461
|
+
|
|
462
|
+
spinner.succeed('Validation complete');
|
|
463
|
+
|
|
464
|
+
return this.generateReport();
|
|
465
|
+
} catch (error) {
|
|
466
|
+
spinner.fail('Validation failed');
|
|
467
|
+
console.error(chalk.red(`\nError: ${error.message}`));
|
|
468
|
+
console.error(error.stack);
|
|
469
|
+
return false;
|
|
470
|
+
}
|
|
471
|
+
}
|
|
472
|
+
}
|
|
473
|
+
|
|
474
|
+
// Run validation if called directly
|
|
475
|
+
if (require.main === module) {
|
|
476
|
+
const validator = new FrameworkValidator();
|
|
477
|
+
validator.run().then(success => {
|
|
478
|
+
process.exit(success ? 0 : 1);
|
|
479
|
+
});
|
|
480
|
+
}
|
|
481
|
+
|
|
482
|
+
module.exports = FrameworkValidator;
|
|
@@ -227,27 +227,23 @@ Document all key decisions:
|
|
|
227
227
|
|
|
228
228
|
...
|
|
229
229
|
|
|
230
|
-
## OpenSpec
|
|
230
|
+
## Path B: OpenSpec Deltas (Iterative)
|
|
231
231
|
|
|
232
|
-
Use this workflow
|
|
232
|
+
Use this workflow for iterative changes, focusing on defining technical deltas rather than full architecture docs.
|
|
233
233
|
|
|
234
234
|
```
|
|
235
|
-
1.
|
|
236
|
-
|
|
235
|
+
1. Analyze Change Proposal
|
|
236
|
+
- Read `openspec/changes/<feature-name>/proposal.md`
|
|
237
|
+
- Understand the functional requirements
|
|
237
238
|
|
|
238
|
-
2. Create
|
|
239
|
-
-
|
|
240
|
-
- Create
|
|
241
|
-
-
|
|
239
|
+
2. Create Spec Deltas
|
|
240
|
+
- Identify which existing specs in `openspec/specs/` are affected
|
|
241
|
+
- Create `openspec/changes/<feature-name>/specs/delta.md`
|
|
242
|
+
- Use `## ADDED Requirements`, `## MODIFIED Requirements`, `## REMOVED Requirements`
|
|
242
243
|
|
|
243
|
-
3.
|
|
244
|
-
-
|
|
245
|
-
- Create
|
|
246
|
-
- Use ## ADDED / ## MODIFIED / ## REMOVED markers
|
|
247
|
-
|
|
248
|
-
4. Review & Align
|
|
249
|
-
- Present proposal and deltas to the team/user
|
|
250
|
-
- Iterate based on feedback until agreed
|
|
244
|
+
3. Define Technical Tasks
|
|
245
|
+
- Break down the implementation of these deltas
|
|
246
|
+
- Create `openspec/changes/<feature-name>/tasks.md` (or handoff to SM)
|
|
251
247
|
```
|
|
252
248
|
|
|
253
249
|
## Architecture Patterns
|
|
@@ -554,4 +550,4 @@ Ready for SM to create stories.
|
|
|
554
550
|
|
|
555
551
|
**Agent Version**: 1.0.0
|
|
556
552
|
**Framework**: AgentDevFramework
|
|
557
|
-
**Methodology**: BMAD-METHOD + Software Architecture Best Practices
|
|
553
|
+
**Methodology**: BMAD-METHOD + Software Architecture Best Practices
|
|
@@ -623,7 +623,7 @@ Before marking story complete:
|
|
|
623
623
|
|
|
624
624
|
## Remember
|
|
625
625
|
|
|
626
|
-
You work from detailed story files with complete context. Your job is **disciplined execution**, not interpretation. When ambiguity exists, ask for clarification rather than assuming intent.
|
|
626
|
+
You work from detailed story files with complete context. Your job is **disciplined execution**, not interpretation. When ambiguity exists, ask for clarification rather than assuming intent.
|
|
627
627
|
|
|
628
628
|
**Success Metrics**:
|
|
629
629
|
- Tests pass on first QA review
|
|
@@ -636,4 +636,4 @@ You work from detailed story files with complete context. Your job is **discipli
|
|
|
636
636
|
|
|
637
637
|
**Agent Version**: 1.0.0
|
|
638
638
|
**Framework**: AgentDevFramework
|
|
639
|
-
**Last Updated**: 2025-01-XX
|
|
639
|
+
**Last Updated**: 2025-01-XX
|
|
@@ -536,5 +536,5 @@ Recommendation: Implement rate limiting and CAPTCHA before beginning development
|
|
|
536
536
|
---
|
|
537
537
|
|
|
538
538
|
**Agent Version**: 1.0.0
|
|
539
|
-
**Framework**: AgentDevFramework
|
|
539
|
+
**Framework**: AgentDevFramework
|
|
540
540
|
**Methodology**: BMAD-METHOD QA + Risk-Based Testing Best Practices
|
|
@@ -726,7 +726,7 @@ test('complete login flow', async () => {
|
|
|
726
726
|
- [ ] Risk assessment included
|
|
727
727
|
- [ ] Dependencies identified
|
|
728
728
|
- [ ] Performance requirements defined
|
|
729
|
-
- [ ] Security requirements
|
|
729
|
+
- [ ] Security requirements included
|
|
730
730
|
- [ ] Definition of Done complete
|
|
731
731
|
- [ ] Story points estimated
|
|
732
732
|
- [ ] Constitutional compliance verified
|
|
@@ -785,4 +785,4 @@ Would you like me to:
|
|
|
785
785
|
|
|
786
786
|
**Agent Version**: 1.0.0
|
|
787
787
|
**Framework**: AgentDevFramework
|
|
788
|
-
**Methodology**: BMAD-METHOD + Context Engineering + Agile Best Practices
|
|
788
|
+
**Methodology**: BMAD-METHOD + Context Engineering + Agile Best Practices
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Template Library
|
|
2
2
|
|
|
3
|
-
This directory contains all templates for the AgentDevFramework
|
|
3
|
+
This directory contains all templates for the AgentDevFramework, synthesizing best practices from BMAD-METHOD, Spec-Kit, Context Engineering, and PRPs Agentic Engineering.
|
|
4
4
|
|
|
5
5
|
## Template Categories
|
|
6
6
|
|
|
@@ -194,6 +194,6 @@ bandit -r src/
|
|
|
194
194
|
|
|
195
195
|
---
|
|
196
196
|
|
|
197
|
-
**Framework**: AgentDevFramework
|
|
197
|
+
**Framework**: AgentDevFramework
|
|
198
198
|
**Version**: 1.0.0
|
|
199
199
|
**Last Updated**: 2024-10-01
|
|
@@ -6,12 +6,12 @@ Briefly describe WHY this change is needed and what problem it solves.
|
|
|
6
6
|
## 📝 Proposed Changes
|
|
7
7
|
High-level summary of the functional changes.
|
|
8
8
|
|
|
9
|
-
##
|
|
9
|
+
## 🏗️ Technical Approach
|
|
10
10
|
- Architecture decisions
|
|
11
11
|
- Impacted components
|
|
12
12
|
- New dependencies (if any)
|
|
13
13
|
|
|
14
|
-
##
|
|
14
|
+
## 🚦 Verification Plan
|
|
15
15
|
- [ ] Syntax check
|
|
16
16
|
- [ ] Unit tests
|
|
17
17
|
- [ ] Integration tests
|
|
@@ -1184,7 +1184,7 @@ logger.error('[Feature] operation failed', {
|
|
|
1184
1184
|
|
|
1185
1185
|
---
|
|
1186
1186
|
|
|
1187
|
-
**Framework**: AgentDevFramework
|
|
1187
|
+
**Framework**: AgentDevFramework
|
|
1188
1188
|
**Template Version**: 1.0.0
|
|
1189
1189
|
**Methodology**: Story-Driven Development + Context Engineering
|
|
1190
1190
|
**Workflow**: Implement phase with complete embedded context
|