mcp-adr-analysis-server 2.0.21 → 2.0.24
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/.tsbuildinfo +1 -1
- package/dist/src/index.d.ts +9 -0
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +1380 -781
- package/dist/src/index.js.map +1 -1
- package/dist/src/tools/adr-suggestion-tool.d.ts.map +1 -1
- package/dist/src/tools/adr-suggestion-tool.js +32 -30
- package/dist/src/tools/adr-suggestion-tool.js.map +1 -1
- package/dist/src/tools/content-masking-tool.d.ts +4 -0
- package/dist/src/tools/content-masking-tool.d.ts.map +1 -1
- package/dist/src/tools/content-masking-tool.js +531 -28
- package/dist/src/tools/content-masking-tool.js.map +1 -1
- package/dist/src/tools/deployment-readiness-tool.d.ts +8 -5
- package/dist/src/tools/deployment-readiness-tool.d.ts.map +1 -1
- package/dist/src/tools/deployment-readiness-tool.js +741 -79
- package/dist/src/tools/deployment-readiness-tool.js.map +1 -1
- package/dist/src/tools/environment-analysis-tool.d.ts +4 -0
- package/dist/src/tools/environment-analysis-tool.d.ts.map +1 -1
- package/dist/src/tools/environment-analysis-tool.js +568 -24
- package/dist/src/tools/environment-analysis-tool.js.map +1 -1
- package/dist/src/tools/mcp-planning-tool.d.ts.map +1 -1
- package/dist/src/tools/mcp-planning-tool.js +298 -173
- package/dist/src/tools/mcp-planning-tool.js.map +1 -1
- package/dist/src/tools/memory-loading-tool.d.ts +60 -0
- package/dist/src/tools/memory-loading-tool.d.ts.map +1 -0
- package/dist/src/tools/memory-loading-tool.js +457 -0
- package/dist/src/tools/memory-loading-tool.js.map +1 -0
- package/dist/src/tools/smart-git-push-tool.d.ts +3 -0
- package/dist/src/tools/smart-git-push-tool.d.ts.map +1 -1
- package/dist/src/tools/smart-git-push-tool.js +177 -223
- package/dist/src/tools/smart-git-push-tool.js.map +1 -1
- package/dist/src/tools/troubleshoot-guided-workflow-tool.d.ts +20 -11
- package/dist/src/tools/troubleshoot-guided-workflow-tool.d.ts.map +1 -1
- package/dist/src/tools/troubleshoot-guided-workflow-tool.js +506 -22
- package/dist/src/tools/troubleshoot-guided-workflow-tool.js.map +1 -1
- package/dist/src/types/enhanced-errors.d.ts +173 -0
- package/dist/src/types/enhanced-errors.d.ts.map +1 -0
- package/dist/src/types/enhanced-errors.js +668 -0
- package/dist/src/types/enhanced-errors.js.map +1 -0
- package/dist/src/types/knowledge-graph-schemas.d.ts +92 -0
- package/dist/src/types/knowledge-graph-schemas.d.ts.map +1 -1
- package/dist/src/types/knowledge-graph-schemas.js +45 -17
- package/dist/src/types/knowledge-graph-schemas.js.map +1 -1
- package/dist/src/types/memory-entities.d.ts +7209 -0
- package/dist/src/types/memory-entities.d.ts.map +1 -0
- package/dist/src/types/memory-entities.js +395 -0
- package/dist/src/types/memory-entities.js.map +1 -0
- package/dist/src/types/todo-json-schemas.d.ts +7 -653
- package/dist/src/types/todo-json-schemas.d.ts.map +1 -1
- package/dist/src/types/todo-json-schemas.js +6 -110
- package/dist/src/types/todo-json-schemas.js.map +1 -1
- package/dist/src/utils/enhanced-logging.d.ts +195 -0
- package/dist/src/utils/enhanced-logging.d.ts.map +1 -0
- package/dist/src/utils/enhanced-logging.js +449 -0
- package/dist/src/utils/enhanced-logging.js.map +1 -0
- package/dist/src/utils/interactive-approval.d.ts +1 -1
- package/dist/src/utils/interactive-approval.d.ts.map +1 -1
- package/dist/src/utils/interactive-approval.js +20 -16
- package/dist/src/utils/interactive-approval.js.map +1 -1
- package/dist/src/utils/knowledge-graph-manager.d.ts +23 -1
- package/dist/src/utils/knowledge-graph-manager.d.ts.map +1 -1
- package/dist/src/utils/knowledge-graph-manager.js +297 -69
- package/dist/src/utils/knowledge-graph-manager.js.map +1 -1
- package/dist/src/utils/memory-entity-manager.d.ts +134 -0
- package/dist/src/utils/memory-entity-manager.d.ts.map +1 -0
- package/dist/src/utils/memory-entity-manager.js +848 -0
- package/dist/src/utils/memory-entity-manager.js.map +1 -0
- package/dist/src/utils/memory-health-scoring.d.ts +125 -0
- package/dist/src/utils/memory-health-scoring.d.ts.map +1 -0
- package/dist/src/utils/memory-health-scoring.js +277 -0
- package/dist/src/utils/memory-health-scoring.js.map +1 -0
- package/dist/src/utils/memory-migration-manager.d.ts +93 -0
- package/dist/src/utils/memory-migration-manager.d.ts.map +1 -0
- package/dist/src/utils/memory-migration-manager.js +834 -0
- package/dist/src/utils/memory-migration-manager.js.map +1 -0
- package/dist/src/utils/memory-relationship-mapper.d.ts +87 -0
- package/dist/src/utils/memory-relationship-mapper.d.ts.map +1 -0
- package/dist/src/utils/memory-relationship-mapper.js +481 -0
- package/dist/src/utils/memory-relationship-mapper.js.map +1 -0
- package/dist/src/utils/memory-rollback-manager.d.ts +93 -0
- package/dist/src/utils/memory-rollback-manager.d.ts.map +1 -0
- package/dist/src/utils/memory-rollback-manager.js +542 -0
- package/dist/src/utils/memory-rollback-manager.js.map +1 -0
- package/dist/src/utils/memory-transformation.d.ts +59 -0
- package/dist/src/utils/memory-transformation.d.ts.map +1 -0
- package/dist/src/utils/memory-transformation.js +742 -0
- package/dist/src/utils/memory-transformation.js.map +1 -0
- package/dist/src/utils/prompt-execution.d.ts.map +1 -1
- package/dist/src/utils/prompt-execution.js +72 -51
- package/dist/src/utils/prompt-execution.js.map +1 -1
- package/dist/src/utils/todo-file-watcher.d.ts +11 -23
- package/dist/src/utils/todo-file-watcher.d.ts.map +1 -1
- package/dist/src/utils/todo-file-watcher.js +18 -156
- package/dist/src/utils/todo-file-watcher.js.map +1 -1
- package/package.json +22 -6
- package/dist/src/tools/smart-score-tool.d.ts +0 -173
- package/dist/src/tools/smart-score-tool.d.ts.map +0 -1
- package/dist/src/tools/smart-score-tool.js +0 -681
- package/dist/src/tools/smart-score-tool.js.map +0 -1
- package/dist/src/tools/todo-management-tool-v2.d.ts +0 -368
- package/dist/src/tools/todo-management-tool-v2.d.ts.map +0 -1
- package/dist/src/tools/todo-management-tool-v2.js +0 -922
- package/dist/src/tools/todo-management-tool-v2.js.map +0 -1
- package/dist/src/utils/project-health-scoring.d.ts +0 -177
- package/dist/src/utils/project-health-scoring.d.ts.map +0 -1
- package/dist/src/utils/project-health-scoring.js +0 -370
- package/dist/src/utils/project-health-scoring.js.map +0 -1
- package/dist/src/utils/todo-json-manager.d.ts +0 -71
- package/dist/src/utils/todo-json-manager.d.ts.map +0 -1
- package/dist/src/utils/todo-json-manager.js +0 -396
- package/dist/src/utils/todo-json-manager.js.map +0 -1
- package/dist/src/utils/todo-markdown-converter.d.ts +0 -16
- package/dist/src/utils/todo-markdown-converter.d.ts.map +0 -1
- package/dist/src/utils/todo-markdown-converter.js +0 -362
- package/dist/src/utils/todo-markdown-converter.js.map +0 -1
- package/dist/src/utils/todo-migration.d.ts +0 -47
- package/dist/src/utils/todo-migration.d.ts.map +0 -1
- package/dist/src/utils/todo-migration.js +0 -261
- package/dist/src/utils/todo-migration.js.map +0 -1
package/dist/src/index.js
CHANGED
|
@@ -8,14 +8,14 @@
|
|
|
8
8
|
*/
|
|
9
9
|
import { Server } from '@modelcontextprotocol/sdk/server/index.js';
|
|
10
10
|
import { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js';
|
|
11
|
-
import { CallToolRequestSchema, ListToolsRequestSchema, ListResourcesRequestSchema, ReadResourceRequestSchema, ListPromptsRequestSchema, GetPromptRequestSchema } from '@modelcontextprotocol/sdk/types.js';
|
|
11
|
+
import { CallToolRequestSchema, ListToolsRequestSchema, ListResourcesRequestSchema, ReadResourceRequestSchema, ListPromptsRequestSchema, GetPromptRequestSchema, } from '@modelcontextprotocol/sdk/types.js';
|
|
12
12
|
import { readFileSync } from 'fs';
|
|
13
13
|
import { join } from 'path';
|
|
14
14
|
import { getCurrentDirCompat } from './utils/directory-compat.js';
|
|
15
15
|
import { McpAdrError } from './types/index.js';
|
|
16
16
|
import { CONVERSATION_CONTEXT_SCHEMA } from './types/conversation-context.js';
|
|
17
17
|
import { maskMcpResponse, createMaskingConfig } from './utils/output-masking.js';
|
|
18
|
-
import { loadConfig, validateProjectPath, createLogger, printConfigSummary } from './utils/config.js';
|
|
18
|
+
import { loadConfig, validateProjectPath, createLogger, printConfigSummary, } from './utils/config.js';
|
|
19
19
|
import { KnowledgeGraphManager } from './utils/knowledge-graph-manager.js';
|
|
20
20
|
/**
|
|
21
21
|
* Get version from package.json
|
|
@@ -29,7 +29,7 @@ function getPackageVersion() {
|
|
|
29
29
|
join(currentDir, 'package.json'),
|
|
30
30
|
join(currentDir, '..', 'package.json'),
|
|
31
31
|
join(currentDir, '..', '..', 'package.json'),
|
|
32
|
-
join(process.cwd(), 'package.json')
|
|
32
|
+
join(process.cwd(), 'package.json'),
|
|
33
33
|
];
|
|
34
34
|
for (const packageJsonPath of possiblePaths) {
|
|
35
35
|
try {
|
|
@@ -61,7 +61,7 @@ function getPackageVersion() {
|
|
|
61
61
|
const SERVER_INFO = {
|
|
62
62
|
name: 'mcp-adr-analysis-server',
|
|
63
63
|
version: getPackageVersion(),
|
|
64
|
-
description: 'MCP server for analyzing Architectural Decision Records and project architecture'
|
|
64
|
+
description: 'MCP server for analyzing Architectural Decision Records and project architecture',
|
|
65
65
|
};
|
|
66
66
|
/**
|
|
67
67
|
* Main server class
|
|
@@ -84,8 +84,8 @@ export class McpAdrAnalysisServer {
|
|
|
84
84
|
capabilities: {
|
|
85
85
|
tools: {},
|
|
86
86
|
resources: {},
|
|
87
|
-
prompts: {}
|
|
88
|
-
}
|
|
87
|
+
prompts: {},
|
|
88
|
+
},
|
|
89
89
|
});
|
|
90
90
|
this.maskingConfig = createMaskingConfig();
|
|
91
91
|
this.setupHandlers();
|
|
@@ -126,59 +126,59 @@ export class McpAdrAnalysisServer {
|
|
|
126
126
|
properties: {
|
|
127
127
|
projectPath: {
|
|
128
128
|
type: 'string',
|
|
129
|
-
description: 'Path to the project directory to analyze (optional, uses configured PROJECT_PATH if not provided)'
|
|
129
|
+
description: 'Path to the project directory to analyze (optional, uses configured PROJECT_PATH if not provided)',
|
|
130
130
|
},
|
|
131
131
|
includePatterns: {
|
|
132
132
|
type: 'array',
|
|
133
133
|
items: { type: 'string' },
|
|
134
|
-
description: 'File patterns to include in analysis'
|
|
134
|
+
description: 'File patterns to include in analysis',
|
|
135
135
|
},
|
|
136
136
|
enhancedMode: {
|
|
137
137
|
type: 'boolean',
|
|
138
138
|
description: 'Enable advanced prompting features (Knowledge Generation + Reflexion)',
|
|
139
|
-
default: true
|
|
139
|
+
default: true,
|
|
140
140
|
},
|
|
141
141
|
knowledgeEnhancement: {
|
|
142
142
|
type: 'boolean',
|
|
143
143
|
description: 'Enable Knowledge Generation for technology-specific insights',
|
|
144
|
-
default: true
|
|
144
|
+
default: true,
|
|
145
145
|
},
|
|
146
146
|
learningEnabled: {
|
|
147
147
|
type: 'boolean',
|
|
148
148
|
description: 'Enable Reflexion learning from past analysis outcomes',
|
|
149
|
-
default: true
|
|
149
|
+
default: true,
|
|
150
150
|
},
|
|
151
151
|
technologyFocus: {
|
|
152
152
|
type: 'array',
|
|
153
153
|
items: { type: 'string' },
|
|
154
|
-
description: 'Specific technologies to focus analysis on (auto-detected if not provided)'
|
|
154
|
+
description: 'Specific technologies to focus analysis on (auto-detected if not provided)',
|
|
155
155
|
},
|
|
156
156
|
analysisDepth: {
|
|
157
157
|
type: 'string',
|
|
158
158
|
enum: ['basic', 'detailed', 'comprehensive'],
|
|
159
159
|
description: 'Depth of ecosystem analysis',
|
|
160
|
-
default: 'comprehensive'
|
|
160
|
+
default: 'comprehensive',
|
|
161
161
|
},
|
|
162
162
|
includeEnvironment: {
|
|
163
163
|
type: 'boolean',
|
|
164
164
|
description: 'Automatically include comprehensive environment analysis (default: true)',
|
|
165
|
-
default: true
|
|
165
|
+
default: true,
|
|
166
166
|
},
|
|
167
167
|
recursiveDepth: {
|
|
168
168
|
type: 'string',
|
|
169
169
|
description: 'Depth of recursive project analysis',
|
|
170
170
|
enum: ['shallow', 'moderate', 'deep', 'comprehensive'],
|
|
171
|
-
default: 'comprehensive'
|
|
171
|
+
default: 'comprehensive',
|
|
172
172
|
},
|
|
173
173
|
analysisScope: {
|
|
174
174
|
type: 'array',
|
|
175
175
|
items: { type: 'string' },
|
|
176
|
-
description: 'Specific analysis areas to focus on (e.g., ["security", "performance", "architecture", "dependencies"])'
|
|
176
|
+
description: 'Specific analysis areas to focus on (e.g., ["security", "performance", "architecture", "dependencies"])',
|
|
177
177
|
},
|
|
178
|
-
conversationContext: CONVERSATION_CONTEXT_SCHEMA
|
|
178
|
+
conversationContext: CONVERSATION_CONTEXT_SCHEMA,
|
|
179
179
|
},
|
|
180
|
-
required: []
|
|
181
|
-
}
|
|
180
|
+
required: [],
|
|
181
|
+
},
|
|
182
182
|
},
|
|
183
183
|
{
|
|
184
184
|
name: 'get_architectural_context',
|
|
@@ -188,16 +188,16 @@ export class McpAdrAnalysisServer {
|
|
|
188
188
|
properties: {
|
|
189
189
|
filePath: {
|
|
190
190
|
type: 'string',
|
|
191
|
-
description: 'Specific file path to analyze (optional, analyzes entire project if not provided)'
|
|
191
|
+
description: 'Specific file path to analyze (optional, analyzes entire project if not provided)',
|
|
192
192
|
},
|
|
193
193
|
includeCompliance: {
|
|
194
194
|
type: 'boolean',
|
|
195
195
|
description: 'Include compliance checks in the analysis',
|
|
196
|
-
default: true
|
|
196
|
+
default: true,
|
|
197
197
|
},
|
|
198
|
-
conversationContext: CONVERSATION_CONTEXT_SCHEMA
|
|
199
|
-
}
|
|
200
|
-
}
|
|
198
|
+
conversationContext: CONVERSATION_CONTEXT_SCHEMA,
|
|
199
|
+
},
|
|
200
|
+
},
|
|
201
201
|
},
|
|
202
202
|
{
|
|
203
203
|
name: 'generate_adrs_from_prd',
|
|
@@ -207,37 +207,44 @@ export class McpAdrAnalysisServer {
|
|
|
207
207
|
properties: {
|
|
208
208
|
prdPath: {
|
|
209
209
|
type: 'string',
|
|
210
|
-
description: 'Path to the PRD.md file'
|
|
210
|
+
description: 'Path to the PRD.md file',
|
|
211
211
|
},
|
|
212
212
|
outputDirectory: {
|
|
213
213
|
type: 'string',
|
|
214
|
-
description: 'Directory to output generated ADRs (optional, uses configured ADR_DIRECTORY if not provided)'
|
|
214
|
+
description: 'Directory to output generated ADRs (optional, uses configured ADR_DIRECTORY if not provided)',
|
|
215
215
|
},
|
|
216
216
|
enhancedMode: {
|
|
217
217
|
type: 'boolean',
|
|
218
218
|
description: 'Enable advanced prompting features (APE + Knowledge Generation)',
|
|
219
|
-
default: true
|
|
219
|
+
default: true,
|
|
220
220
|
},
|
|
221
221
|
promptOptimization: {
|
|
222
222
|
type: 'boolean',
|
|
223
223
|
description: 'Enable Automatic Prompt Engineering for optimized ADR generation',
|
|
224
|
-
default: true
|
|
224
|
+
default: true,
|
|
225
225
|
},
|
|
226
226
|
knowledgeEnhancement: {
|
|
227
227
|
type: 'boolean',
|
|
228
228
|
description: 'Enable Knowledge Generation for domain-specific insights',
|
|
229
|
-
default: true
|
|
229
|
+
default: true,
|
|
230
230
|
},
|
|
231
231
|
prdType: {
|
|
232
232
|
type: 'string',
|
|
233
|
-
enum: [
|
|
233
|
+
enum: [
|
|
234
|
+
'web-application',
|
|
235
|
+
'mobile-app',
|
|
236
|
+
'microservices',
|
|
237
|
+
'data-platform',
|
|
238
|
+
'api-service',
|
|
239
|
+
'general',
|
|
240
|
+
],
|
|
234
241
|
description: 'Type of PRD for optimized knowledge generation',
|
|
235
|
-
default: 'general'
|
|
242
|
+
default: 'general',
|
|
236
243
|
},
|
|
237
|
-
conversationContext: CONVERSATION_CONTEXT_SCHEMA
|
|
244
|
+
conversationContext: CONVERSATION_CONTEXT_SCHEMA,
|
|
238
245
|
},
|
|
239
|
-
required: ['prdPath']
|
|
240
|
-
}
|
|
246
|
+
required: ['prdPath'],
|
|
247
|
+
},
|
|
241
248
|
},
|
|
242
249
|
{
|
|
243
250
|
name: 'generate_adr_todo',
|
|
@@ -247,63 +254,63 @@ export class McpAdrAnalysisServer {
|
|
|
247
254
|
properties: {
|
|
248
255
|
adrDirectory: {
|
|
249
256
|
type: 'string',
|
|
250
|
-
description: 'Directory containing ADR files (optional, uses configured ADR_DIRECTORY if not provided)'
|
|
257
|
+
description: 'Directory containing ADR files (optional, uses configured ADR_DIRECTORY if not provided)',
|
|
251
258
|
},
|
|
252
259
|
scope: {
|
|
253
260
|
type: 'string',
|
|
254
261
|
enum: ['all', 'pending', 'in_progress'],
|
|
255
262
|
description: 'Scope of tasks to include',
|
|
256
|
-
default: 'all'
|
|
263
|
+
default: 'all',
|
|
257
264
|
},
|
|
258
265
|
phase: {
|
|
259
266
|
type: 'string',
|
|
260
267
|
enum: ['both', 'test', 'production'],
|
|
261
268
|
description: 'TDD phase: both (default), test (mock test generation), production (implementation after tests)',
|
|
262
|
-
default: 'both'
|
|
269
|
+
default: 'both',
|
|
263
270
|
},
|
|
264
271
|
linkAdrs: {
|
|
265
272
|
type: 'boolean',
|
|
266
273
|
description: 'Auto-detect and link ADR dependencies in task creation',
|
|
267
|
-
default: true
|
|
274
|
+
default: true,
|
|
268
275
|
},
|
|
269
276
|
includeRules: {
|
|
270
277
|
type: 'boolean',
|
|
271
278
|
description: 'Include architectural rules validation in TDD tasks',
|
|
272
|
-
default: true
|
|
279
|
+
default: true,
|
|
273
280
|
},
|
|
274
281
|
ruleSource: {
|
|
275
282
|
type: 'string',
|
|
276
283
|
enum: ['adrs', 'patterns', 'both'],
|
|
277
284
|
description: 'Source for architectural rules (only used if includeRules is true)',
|
|
278
|
-
default: 'both'
|
|
285
|
+
default: 'both',
|
|
279
286
|
},
|
|
280
287
|
todoPath: {
|
|
281
288
|
type: 'string',
|
|
282
289
|
description: 'Path to TODO.md file (relative to project root)',
|
|
283
|
-
default: 'TODO.md'
|
|
290
|
+
default: 'TODO.md',
|
|
284
291
|
},
|
|
285
292
|
preserveExisting: {
|
|
286
293
|
type: 'boolean',
|
|
287
294
|
description: 'Preserve existing TODO.md content by merging instead of overwriting',
|
|
288
|
-
default: true
|
|
295
|
+
default: true,
|
|
289
296
|
},
|
|
290
297
|
forceSyncToMarkdown: {
|
|
291
298
|
type: 'boolean',
|
|
292
299
|
description: 'Force sync JSON to markdown even if markdown is newer',
|
|
293
|
-
default: false
|
|
300
|
+
default: false,
|
|
294
301
|
},
|
|
295
302
|
intentId: {
|
|
296
303
|
type: 'string',
|
|
297
|
-
description: 'Link generated tasks to specific knowledge graph intent'
|
|
304
|
+
description: 'Link generated tasks to specific knowledge graph intent',
|
|
298
305
|
},
|
|
299
306
|
createJsonBackup: {
|
|
300
307
|
type: 'boolean',
|
|
301
308
|
description: 'Create backup of existing JSON TODO data before import',
|
|
302
|
-
default: true
|
|
309
|
+
default: true,
|
|
303
310
|
},
|
|
304
|
-
conversationContext: CONVERSATION_CONTEXT_SCHEMA
|
|
305
|
-
}
|
|
306
|
-
}
|
|
311
|
+
conversationContext: CONVERSATION_CONTEXT_SCHEMA,
|
|
312
|
+
},
|
|
313
|
+
},
|
|
307
314
|
},
|
|
308
315
|
{
|
|
309
316
|
name: 'compare_adr_progress',
|
|
@@ -314,23 +321,23 @@ export class McpAdrAnalysisServer {
|
|
|
314
321
|
todoPath: {
|
|
315
322
|
type: 'string',
|
|
316
323
|
description: 'Path to TODO.md file to analyze',
|
|
317
|
-
default: 'TODO.md'
|
|
324
|
+
default: 'TODO.md',
|
|
318
325
|
},
|
|
319
326
|
adrDirectory: {
|
|
320
327
|
type: 'string',
|
|
321
328
|
description: 'Directory containing ADR files',
|
|
322
|
-
default: 'docs/adrs'
|
|
329
|
+
default: 'docs/adrs',
|
|
323
330
|
},
|
|
324
331
|
projectPath: {
|
|
325
332
|
type: 'string',
|
|
326
333
|
description: 'Path to project root for environment analysis',
|
|
327
|
-
default: '.'
|
|
334
|
+
default: '.',
|
|
328
335
|
},
|
|
329
336
|
environment: {
|
|
330
337
|
type: 'string',
|
|
331
338
|
enum: ['development', 'staging', 'production', 'testing', 'auto-detect'],
|
|
332
339
|
description: 'Target environment context for validation (auto-detect will infer from project structure)',
|
|
333
|
-
default: 'auto-detect'
|
|
340
|
+
default: 'auto-detect',
|
|
334
341
|
},
|
|
335
342
|
environmentConfig: {
|
|
336
343
|
type: 'object',
|
|
@@ -339,87 +346,102 @@ export class McpAdrAnalysisServer {
|
|
|
339
346
|
requiredFiles: {
|
|
340
347
|
type: 'array',
|
|
341
348
|
items: { type: 'string' },
|
|
342
|
-
description: 'Files required for this environment'
|
|
349
|
+
description: 'Files required for this environment',
|
|
343
350
|
},
|
|
344
351
|
requiredServices: {
|
|
345
352
|
type: 'array',
|
|
346
353
|
items: { type: 'string' },
|
|
347
|
-
description: 'Services that must be implemented for this environment'
|
|
354
|
+
description: 'Services that must be implemented for this environment',
|
|
348
355
|
},
|
|
349
356
|
securityLevel: {
|
|
350
357
|
type: 'string',
|
|
351
358
|
enum: ['low', 'medium', 'high', 'critical'],
|
|
352
|
-
description: 'Required security level for this environment'
|
|
359
|
+
description: 'Required security level for this environment',
|
|
353
360
|
},
|
|
354
361
|
performanceRequirements: {
|
|
355
362
|
type: 'object',
|
|
356
|
-
description: 'Performance requirements for this environment'
|
|
357
|
-
}
|
|
358
|
-
}
|
|
363
|
+
description: 'Performance requirements for this environment',
|
|
364
|
+
},
|
|
365
|
+
},
|
|
359
366
|
},
|
|
360
367
|
validationType: {
|
|
361
368
|
type: 'string',
|
|
362
369
|
enum: ['full', 'todo-only', 'adr-only', 'environment-only'],
|
|
363
370
|
description: 'Type of validation to perform',
|
|
364
|
-
default: 'full'
|
|
371
|
+
default: 'full',
|
|
365
372
|
},
|
|
366
373
|
includeFileChecks: {
|
|
367
374
|
type: 'boolean',
|
|
368
375
|
description: 'Include file existence and implementation checks',
|
|
369
|
-
default: true
|
|
376
|
+
default: true,
|
|
370
377
|
},
|
|
371
378
|
includeRuleValidation: {
|
|
372
379
|
type: 'boolean',
|
|
373
380
|
description: 'Include architectural rule compliance validation',
|
|
374
|
-
default: true
|
|
381
|
+
default: true,
|
|
375
382
|
},
|
|
376
383
|
deepCodeAnalysis: {
|
|
377
384
|
type: 'boolean',
|
|
378
385
|
description: 'Perform deep code analysis to distinguish mock from production implementations',
|
|
379
|
-
default: true
|
|
386
|
+
default: true,
|
|
380
387
|
},
|
|
381
388
|
functionalValidation: {
|
|
382
389
|
type: 'boolean',
|
|
383
390
|
description: 'Validate that code actually functions according to ADR goals, not just exists',
|
|
384
|
-
default: true
|
|
391
|
+
default: true,
|
|
385
392
|
},
|
|
386
393
|
strictMode: {
|
|
387
394
|
type: 'boolean',
|
|
388
395
|
description: 'Enable strict validation mode with reality-check mechanisms against overconfident assessments',
|
|
389
|
-
default: true
|
|
396
|
+
default: true,
|
|
390
397
|
},
|
|
391
398
|
environmentValidation: {
|
|
392
399
|
type: 'boolean',
|
|
393
400
|
description: 'Enable environment-specific validation rules and checks',
|
|
394
|
-
default: true
|
|
395
|
-
}
|
|
396
|
-
}
|
|
397
|
-
}
|
|
401
|
+
default: true,
|
|
402
|
+
},
|
|
403
|
+
},
|
|
404
|
+
},
|
|
398
405
|
},
|
|
399
406
|
{
|
|
400
407
|
name: 'analyze_content_security',
|
|
401
|
-
description: 'Analyze content for sensitive information using AI-powered detection',
|
|
408
|
+
description: 'Analyze content for sensitive information using AI-powered detection with optional memory integration for security pattern learning',
|
|
402
409
|
inputSchema: {
|
|
403
410
|
type: 'object',
|
|
404
411
|
properties: {
|
|
405
412
|
content: {
|
|
406
413
|
type: 'string',
|
|
407
|
-
description: 'Content to analyze for sensitive information'
|
|
414
|
+
description: 'Content to analyze for sensitive information',
|
|
408
415
|
},
|
|
409
416
|
contentType: {
|
|
410
417
|
type: 'string',
|
|
411
418
|
enum: ['code', 'documentation', 'configuration', 'logs', 'general'],
|
|
412
419
|
description: 'Type of content being analyzed',
|
|
413
|
-
default: 'general'
|
|
420
|
+
default: 'general',
|
|
414
421
|
},
|
|
415
422
|
userDefinedPatterns: {
|
|
416
423
|
type: 'array',
|
|
417
424
|
items: { type: 'string' },
|
|
418
|
-
description: 'User-defined sensitive patterns to detect'
|
|
419
|
-
}
|
|
425
|
+
description: 'User-defined sensitive patterns to detect',
|
|
426
|
+
},
|
|
427
|
+
enableMemoryIntegration: {
|
|
428
|
+
type: 'boolean',
|
|
429
|
+
description: 'Enable memory entity storage for security pattern learning and institutional knowledge building',
|
|
430
|
+
default: true,
|
|
431
|
+
},
|
|
432
|
+
knowledgeEnhancement: {
|
|
433
|
+
type: 'boolean',
|
|
434
|
+
description: 'Enable Generated Knowledge Prompting for security and privacy expertise',
|
|
435
|
+
default: true,
|
|
436
|
+
},
|
|
437
|
+
enhancedMode: {
|
|
438
|
+
type: 'boolean',
|
|
439
|
+
description: 'Enable advanced prompting features',
|
|
440
|
+
default: true,
|
|
441
|
+
},
|
|
420
442
|
},
|
|
421
|
-
required: ['content']
|
|
422
|
-
}
|
|
443
|
+
required: ['content'],
|
|
444
|
+
},
|
|
423
445
|
},
|
|
424
446
|
{
|
|
425
447
|
name: 'generate_content_masking',
|
|
@@ -429,7 +451,7 @@ export class McpAdrAnalysisServer {
|
|
|
429
451
|
properties: {
|
|
430
452
|
content: {
|
|
431
453
|
type: 'string',
|
|
432
|
-
description: 'Content to mask'
|
|
454
|
+
description: 'Content to mask',
|
|
433
455
|
},
|
|
434
456
|
detectedItems: {
|
|
435
457
|
type: 'array',
|
|
@@ -440,20 +462,20 @@ export class McpAdrAnalysisServer {
|
|
|
440
462
|
content: { type: 'string' },
|
|
441
463
|
startPosition: { type: 'number' },
|
|
442
464
|
endPosition: { type: 'number' },
|
|
443
|
-
severity: { type: 'string' }
|
|
444
|
-
}
|
|
465
|
+
severity: { type: 'string' },
|
|
466
|
+
},
|
|
445
467
|
},
|
|
446
|
-
description: 'Detected sensitive items to mask'
|
|
468
|
+
description: 'Detected sensitive items to mask',
|
|
447
469
|
},
|
|
448
470
|
maskingStrategy: {
|
|
449
471
|
type: 'string',
|
|
450
472
|
enum: ['full', 'partial', 'placeholder', 'environment'],
|
|
451
473
|
description: 'Strategy for masking content',
|
|
452
|
-
default: 'full'
|
|
453
|
-
}
|
|
474
|
+
default: 'full',
|
|
475
|
+
},
|
|
454
476
|
},
|
|
455
|
-
required: ['content', 'detectedItems']
|
|
456
|
-
}
|
|
477
|
+
required: ['content', 'detectedItems'],
|
|
478
|
+
},
|
|
457
479
|
},
|
|
458
480
|
{
|
|
459
481
|
name: 'configure_custom_patterns',
|
|
@@ -463,16 +485,16 @@ export class McpAdrAnalysisServer {
|
|
|
463
485
|
properties: {
|
|
464
486
|
projectPath: {
|
|
465
487
|
type: 'string',
|
|
466
|
-
description: 'Path to the project directory'
|
|
488
|
+
description: 'Path to the project directory',
|
|
467
489
|
},
|
|
468
490
|
existingPatterns: {
|
|
469
491
|
type: 'array',
|
|
470
492
|
items: { type: 'string' },
|
|
471
|
-
description: 'Existing patterns to consider'
|
|
472
|
-
}
|
|
493
|
+
description: 'Existing patterns to consider',
|
|
494
|
+
},
|
|
473
495
|
},
|
|
474
|
-
required: ['projectPath']
|
|
475
|
-
}
|
|
496
|
+
required: ['projectPath'],
|
|
497
|
+
},
|
|
476
498
|
},
|
|
477
499
|
{
|
|
478
500
|
name: 'apply_basic_content_masking',
|
|
@@ -482,17 +504,17 @@ export class McpAdrAnalysisServer {
|
|
|
482
504
|
properties: {
|
|
483
505
|
content: {
|
|
484
506
|
type: 'string',
|
|
485
|
-
description: 'Content to mask'
|
|
507
|
+
description: 'Content to mask',
|
|
486
508
|
},
|
|
487
509
|
maskingStrategy: {
|
|
488
510
|
type: 'string',
|
|
489
511
|
enum: ['full', 'partial', 'placeholder'],
|
|
490
512
|
description: 'Strategy for masking content',
|
|
491
|
-
default: 'full'
|
|
492
|
-
}
|
|
513
|
+
default: 'full',
|
|
514
|
+
},
|
|
493
515
|
},
|
|
494
|
-
required: ['content']
|
|
495
|
-
}
|
|
516
|
+
required: ['content'],
|
|
517
|
+
},
|
|
496
518
|
},
|
|
497
519
|
{
|
|
498
520
|
name: 'validate_content_masking',
|
|
@@ -502,15 +524,15 @@ export class McpAdrAnalysisServer {
|
|
|
502
524
|
properties: {
|
|
503
525
|
originalContent: {
|
|
504
526
|
type: 'string',
|
|
505
|
-
description: 'Original content before masking'
|
|
527
|
+
description: 'Original content before masking',
|
|
506
528
|
},
|
|
507
529
|
maskedContent: {
|
|
508
530
|
type: 'string',
|
|
509
|
-
description: 'Content after masking'
|
|
510
|
-
}
|
|
531
|
+
description: 'Content after masking',
|
|
532
|
+
},
|
|
511
533
|
},
|
|
512
|
-
required: ['originalContent', 'maskedContent']
|
|
513
|
-
}
|
|
534
|
+
required: ['originalContent', 'maskedContent'],
|
|
535
|
+
},
|
|
514
536
|
},
|
|
515
537
|
{
|
|
516
538
|
name: 'manage_cache',
|
|
@@ -521,15 +543,15 @@ export class McpAdrAnalysisServer {
|
|
|
521
543
|
action: {
|
|
522
544
|
type: 'string',
|
|
523
545
|
enum: ['clear', 'stats', 'cleanup', 'invalidate'],
|
|
524
|
-
description: 'Cache management action to perform'
|
|
546
|
+
description: 'Cache management action to perform',
|
|
525
547
|
},
|
|
526
548
|
key: {
|
|
527
549
|
type: 'string',
|
|
528
|
-
description: 'Specific cache key to invalidate (for invalidate action)'
|
|
529
|
-
}
|
|
550
|
+
description: 'Specific cache key to invalidate (for invalidate action)',
|
|
551
|
+
},
|
|
530
552
|
},
|
|
531
|
-
required: ['action']
|
|
532
|
-
}
|
|
553
|
+
required: ['action'],
|
|
554
|
+
},
|
|
533
555
|
},
|
|
534
556
|
{
|
|
535
557
|
name: 'configure_output_masking',
|
|
@@ -539,26 +561,26 @@ export class McpAdrAnalysisServer {
|
|
|
539
561
|
properties: {
|
|
540
562
|
enabled: {
|
|
541
563
|
type: 'boolean',
|
|
542
|
-
description: 'Enable or disable output masking'
|
|
564
|
+
description: 'Enable or disable output masking',
|
|
543
565
|
},
|
|
544
566
|
strategy: {
|
|
545
567
|
type: 'string',
|
|
546
568
|
enum: ['full', 'partial', 'placeholder', 'environment'],
|
|
547
|
-
description: 'Masking strategy to use'
|
|
569
|
+
description: 'Masking strategy to use',
|
|
548
570
|
},
|
|
549
571
|
customPatterns: {
|
|
550
572
|
type: 'array',
|
|
551
573
|
items: { type: 'string' },
|
|
552
|
-
description: 'Custom patterns to mask'
|
|
574
|
+
description: 'Custom patterns to mask',
|
|
553
575
|
},
|
|
554
576
|
action: {
|
|
555
577
|
type: 'string',
|
|
556
578
|
enum: ['get', 'set', 'reset'],
|
|
557
579
|
description: 'Configuration action',
|
|
558
|
-
default: 'get'
|
|
559
|
-
}
|
|
560
|
-
}
|
|
561
|
-
}
|
|
580
|
+
default: 'get',
|
|
581
|
+
},
|
|
582
|
+
},
|
|
583
|
+
},
|
|
562
584
|
},
|
|
563
585
|
{
|
|
564
586
|
name: 'suggest_adrs',
|
|
@@ -569,54 +591,54 @@ export class McpAdrAnalysisServer {
|
|
|
569
591
|
projectPath: {
|
|
570
592
|
type: 'string',
|
|
571
593
|
description: 'Path to the project directory',
|
|
572
|
-
default: '.'
|
|
594
|
+
default: '.',
|
|
573
595
|
},
|
|
574
596
|
analysisType: {
|
|
575
597
|
type: 'string',
|
|
576
598
|
enum: ['implicit_decisions', 'code_changes', 'comprehensive'],
|
|
577
599
|
description: 'Type of analysis to perform',
|
|
578
|
-
default: 'comprehensive'
|
|
600
|
+
default: 'comprehensive',
|
|
579
601
|
},
|
|
580
602
|
beforeCode: {
|
|
581
603
|
type: 'string',
|
|
582
|
-
description: 'Code before changes (for code_changes analysis)'
|
|
604
|
+
description: 'Code before changes (for code_changes analysis)',
|
|
583
605
|
},
|
|
584
606
|
afterCode: {
|
|
585
607
|
type: 'string',
|
|
586
|
-
description: 'Code after changes (for code_changes analysis)'
|
|
608
|
+
description: 'Code after changes (for code_changes analysis)',
|
|
587
609
|
},
|
|
588
610
|
changeDescription: {
|
|
589
611
|
type: 'string',
|
|
590
|
-
description: 'Description of the changes (for code_changes analysis)'
|
|
612
|
+
description: 'Description of the changes (for code_changes analysis)',
|
|
591
613
|
},
|
|
592
614
|
commitMessages: {
|
|
593
615
|
type: 'array',
|
|
594
616
|
items: { type: 'string' },
|
|
595
|
-
description: 'Related commit messages (for code_changes analysis)'
|
|
617
|
+
description: 'Related commit messages (for code_changes analysis)',
|
|
596
618
|
},
|
|
597
619
|
existingAdrs: {
|
|
598
620
|
type: 'array',
|
|
599
621
|
items: { type: 'string' },
|
|
600
|
-
description: 'List of existing ADR titles to avoid duplication'
|
|
622
|
+
description: 'List of existing ADR titles to avoid duplication',
|
|
601
623
|
},
|
|
602
624
|
enhancedMode: {
|
|
603
625
|
type: 'boolean',
|
|
604
626
|
description: 'Enable advanced prompting features (Knowledge Generation + Reflexion)',
|
|
605
|
-
default: true
|
|
627
|
+
default: true,
|
|
606
628
|
},
|
|
607
629
|
learningEnabled: {
|
|
608
630
|
type: 'boolean',
|
|
609
631
|
description: 'Enable Reflexion learning from past experiences',
|
|
610
|
-
default: true
|
|
632
|
+
default: true,
|
|
611
633
|
},
|
|
612
634
|
knowledgeEnhancement: {
|
|
613
635
|
type: 'boolean',
|
|
614
636
|
description: 'Enable Knowledge Generation for domain-specific insights',
|
|
615
|
-
default: true
|
|
637
|
+
default: true,
|
|
616
638
|
},
|
|
617
|
-
conversationContext: CONVERSATION_CONTEXT_SCHEMA
|
|
618
|
-
}
|
|
619
|
-
}
|
|
639
|
+
conversationContext: CONVERSATION_CONTEXT_SCHEMA,
|
|
640
|
+
},
|
|
641
|
+
},
|
|
620
642
|
},
|
|
621
643
|
{
|
|
622
644
|
name: 'generate_adr_from_decision',
|
|
@@ -634,35 +656,35 @@ export class McpAdrAnalysisServer {
|
|
|
634
656
|
alternatives: {
|
|
635
657
|
type: 'array',
|
|
636
658
|
items: { type: 'string' },
|
|
637
|
-
description: 'Alternative approaches considered'
|
|
659
|
+
description: 'Alternative approaches considered',
|
|
638
660
|
},
|
|
639
661
|
evidence: {
|
|
640
662
|
type: 'array',
|
|
641
663
|
items: { type: 'string' },
|
|
642
|
-
description: 'Supporting evidence for the decision'
|
|
643
|
-
}
|
|
664
|
+
description: 'Supporting evidence for the decision',
|
|
665
|
+
},
|
|
644
666
|
},
|
|
645
|
-
required: ['title', 'context', 'decision', 'consequences']
|
|
667
|
+
required: ['title', 'context', 'decision', 'consequences'],
|
|
646
668
|
},
|
|
647
669
|
templateFormat: {
|
|
648
670
|
type: 'string',
|
|
649
671
|
enum: ['nygard', 'madr', 'custom'],
|
|
650
672
|
description: 'ADR template format to use',
|
|
651
|
-
default: 'nygard'
|
|
673
|
+
default: 'nygard',
|
|
652
674
|
},
|
|
653
675
|
existingAdrs: {
|
|
654
676
|
type: 'array',
|
|
655
677
|
items: { type: 'string' },
|
|
656
|
-
description: 'List of existing ADRs for numbering and references'
|
|
678
|
+
description: 'List of existing ADRs for numbering and references',
|
|
657
679
|
},
|
|
658
680
|
adrDirectory: {
|
|
659
681
|
type: 'string',
|
|
660
682
|
description: 'Directory where ADRs are stored',
|
|
661
|
-
default: 'docs/adrs'
|
|
662
|
-
}
|
|
683
|
+
default: 'docs/adrs',
|
|
684
|
+
},
|
|
663
685
|
},
|
|
664
|
-
required: ['decisionData']
|
|
665
|
-
}
|
|
686
|
+
required: ['decisionData'],
|
|
687
|
+
},
|
|
666
688
|
},
|
|
667
689
|
{
|
|
668
690
|
name: 'discover_existing_adrs',
|
|
@@ -673,15 +695,15 @@ export class McpAdrAnalysisServer {
|
|
|
673
695
|
adrDirectory: {
|
|
674
696
|
type: 'string',
|
|
675
697
|
description: 'Directory to search for ADRs',
|
|
676
|
-
default: 'docs/adrs'
|
|
698
|
+
default: 'docs/adrs',
|
|
677
699
|
},
|
|
678
700
|
includeContent: {
|
|
679
701
|
type: 'boolean',
|
|
680
702
|
description: 'Whether to include ADR content in analysis',
|
|
681
|
-
default: false
|
|
682
|
-
}
|
|
683
|
-
}
|
|
684
|
-
}
|
|
703
|
+
default: false,
|
|
704
|
+
},
|
|
705
|
+
},
|
|
706
|
+
},
|
|
685
707
|
},
|
|
686
708
|
{
|
|
687
709
|
name: 'incorporate_research',
|
|
@@ -692,23 +714,29 @@ export class McpAdrAnalysisServer {
|
|
|
692
714
|
researchPath: {
|
|
693
715
|
type: 'string',
|
|
694
716
|
description: 'Path to research directory',
|
|
695
|
-
default: 'docs/research'
|
|
717
|
+
default: 'docs/research',
|
|
696
718
|
},
|
|
697
719
|
adrDirectory: {
|
|
698
720
|
type: 'string',
|
|
699
721
|
description: 'Path to ADR directory',
|
|
700
|
-
default: 'docs/adrs'
|
|
722
|
+
default: 'docs/adrs',
|
|
701
723
|
},
|
|
702
724
|
analysisType: {
|
|
703
725
|
type: 'string',
|
|
704
|
-
enum: [
|
|
726
|
+
enum: [
|
|
727
|
+
'monitor',
|
|
728
|
+
'extract_topics',
|
|
729
|
+
'evaluate_impact',
|
|
730
|
+
'generate_updates',
|
|
731
|
+
'comprehensive',
|
|
732
|
+
],
|
|
705
733
|
description: 'Type of research analysis to perform',
|
|
706
|
-
default: 'comprehensive'
|
|
734
|
+
default: 'comprehensive',
|
|
707
735
|
},
|
|
708
736
|
existingTopics: {
|
|
709
737
|
type: 'array',
|
|
710
738
|
items: { type: 'string' },
|
|
711
|
-
description: 'Previously identified research topics'
|
|
739
|
+
description: 'Previously identified research topics',
|
|
712
740
|
},
|
|
713
741
|
researchTopics: {
|
|
714
742
|
type: 'array',
|
|
@@ -719,19 +747,19 @@ export class McpAdrAnalysisServer {
|
|
|
719
747
|
title: { type: 'string' },
|
|
720
748
|
category: { type: 'string' },
|
|
721
749
|
keyFindings: { type: 'array', items: { type: 'string' } },
|
|
722
|
-
relevanceScore: { type: 'number' }
|
|
723
|
-
}
|
|
750
|
+
relevanceScore: { type: 'number' },
|
|
751
|
+
},
|
|
724
752
|
},
|
|
725
|
-
description: 'Research topics for impact evaluation'
|
|
753
|
+
description: 'Research topics for impact evaluation',
|
|
726
754
|
},
|
|
727
755
|
adrId: {
|
|
728
756
|
type: 'string',
|
|
729
|
-
description: 'ADR ID for update generation'
|
|
757
|
+
description: 'ADR ID for update generation',
|
|
730
758
|
},
|
|
731
759
|
updateType: {
|
|
732
760
|
type: 'string',
|
|
733
761
|
enum: ['content', 'status', 'consequences', 'alternatives', 'deprecation'],
|
|
734
|
-
description: 'Type of ADR update to generate'
|
|
762
|
+
description: 'Type of ADR update to generate',
|
|
735
763
|
},
|
|
736
764
|
researchFindings: {
|
|
737
765
|
type: 'array',
|
|
@@ -740,13 +768,13 @@ export class McpAdrAnalysisServer {
|
|
|
740
768
|
properties: {
|
|
741
769
|
finding: { type: 'string' },
|
|
742
770
|
evidence: { type: 'array', items: { type: 'string' } },
|
|
743
|
-
impact: { type: 'string' }
|
|
744
|
-
}
|
|
771
|
+
impact: { type: 'string' },
|
|
772
|
+
},
|
|
745
773
|
},
|
|
746
|
-
description: 'Research findings for update generation'
|
|
747
|
-
}
|
|
748
|
-
}
|
|
749
|
-
}
|
|
774
|
+
description: 'Research findings for update generation',
|
|
775
|
+
},
|
|
776
|
+
},
|
|
777
|
+
},
|
|
750
778
|
},
|
|
751
779
|
{
|
|
752
780
|
name: 'create_research_template',
|
|
@@ -756,21 +784,21 @@ export class McpAdrAnalysisServer {
|
|
|
756
784
|
properties: {
|
|
757
785
|
title: {
|
|
758
786
|
type: 'string',
|
|
759
|
-
description: 'Title of the research'
|
|
787
|
+
description: 'Title of the research',
|
|
760
788
|
},
|
|
761
789
|
category: {
|
|
762
790
|
type: 'string',
|
|
763
791
|
description: 'Research category',
|
|
764
|
-
default: 'general'
|
|
792
|
+
default: 'general',
|
|
765
793
|
},
|
|
766
794
|
researchPath: {
|
|
767
795
|
type: 'string',
|
|
768
796
|
description: 'Path to research directory',
|
|
769
|
-
default: 'docs/research'
|
|
770
|
-
}
|
|
797
|
+
default: 'docs/research',
|
|
798
|
+
},
|
|
771
799
|
},
|
|
772
|
-
required: ['title']
|
|
773
|
-
}
|
|
800
|
+
required: ['title'],
|
|
801
|
+
},
|
|
774
802
|
},
|
|
775
803
|
{
|
|
776
804
|
name: 'request_action_confirmation',
|
|
@@ -780,21 +808,21 @@ export class McpAdrAnalysisServer {
|
|
|
780
808
|
properties: {
|
|
781
809
|
action: {
|
|
782
810
|
type: 'string',
|
|
783
|
-
description: 'Description of the action to be performed'
|
|
811
|
+
description: 'Description of the action to be performed',
|
|
784
812
|
},
|
|
785
813
|
details: {
|
|
786
814
|
type: 'string',
|
|
787
|
-
description: 'Detailed information about the action'
|
|
815
|
+
description: 'Detailed information about the action',
|
|
788
816
|
},
|
|
789
817
|
impact: {
|
|
790
818
|
type: 'string',
|
|
791
819
|
enum: ['low', 'medium', 'high', 'critical'],
|
|
792
820
|
description: 'Impact level of the action',
|
|
793
|
-
default: 'medium'
|
|
794
|
-
}
|
|
821
|
+
default: 'medium',
|
|
822
|
+
},
|
|
795
823
|
},
|
|
796
|
-
required: ['action', 'details']
|
|
797
|
-
}
|
|
824
|
+
required: ['action', 'details'],
|
|
825
|
+
},
|
|
798
826
|
},
|
|
799
827
|
{
|
|
800
828
|
name: 'generate_rules',
|
|
@@ -806,17 +834,17 @@ export class McpAdrAnalysisServer {
|
|
|
806
834
|
type: 'string',
|
|
807
835
|
enum: ['adrs', 'patterns', 'both'],
|
|
808
836
|
description: 'Source for rule generation',
|
|
809
|
-
default: 'both'
|
|
837
|
+
default: 'both',
|
|
810
838
|
},
|
|
811
839
|
adrDirectory: {
|
|
812
840
|
type: 'string',
|
|
813
841
|
description: 'Directory containing ADR files',
|
|
814
|
-
default: 'docs/adrs'
|
|
842
|
+
default: 'docs/adrs',
|
|
815
843
|
},
|
|
816
844
|
projectPath: {
|
|
817
845
|
type: 'string',
|
|
818
846
|
description: 'Path to project for pattern analysis',
|
|
819
|
-
default: '.'
|
|
847
|
+
default: '.',
|
|
820
848
|
},
|
|
821
849
|
existingRules: {
|
|
822
850
|
type: 'array',
|
|
@@ -825,19 +853,19 @@ export class McpAdrAnalysisServer {
|
|
|
825
853
|
properties: {
|
|
826
854
|
id: { type: 'string' },
|
|
827
855
|
name: { type: 'string' },
|
|
828
|
-
description: { type: 'string' }
|
|
829
|
-
}
|
|
856
|
+
description: { type: 'string' },
|
|
857
|
+
},
|
|
830
858
|
},
|
|
831
|
-
description: 'Existing rules to avoid duplication'
|
|
859
|
+
description: 'Existing rules to avoid duplication',
|
|
832
860
|
},
|
|
833
861
|
outputFormat: {
|
|
834
862
|
type: 'string',
|
|
835
863
|
enum: ['json', 'yaml', 'both'],
|
|
836
864
|
description: 'Output format for rules',
|
|
837
|
-
default: 'json'
|
|
838
|
-
}
|
|
839
|
-
}
|
|
840
|
-
}
|
|
865
|
+
default: 'json',
|
|
866
|
+
},
|
|
867
|
+
},
|
|
868
|
+
},
|
|
841
869
|
},
|
|
842
870
|
{
|
|
843
871
|
name: 'validate_rules',
|
|
@@ -847,15 +875,15 @@ export class McpAdrAnalysisServer {
|
|
|
847
875
|
properties: {
|
|
848
876
|
filePath: {
|
|
849
877
|
type: 'string',
|
|
850
|
-
description: 'Path to file to validate'
|
|
878
|
+
description: 'Path to file to validate',
|
|
851
879
|
},
|
|
852
880
|
fileContent: {
|
|
853
881
|
type: 'string',
|
|
854
|
-
description: 'Content to validate (alternative to filePath)'
|
|
882
|
+
description: 'Content to validate (alternative to filePath)',
|
|
855
883
|
},
|
|
856
884
|
fileName: {
|
|
857
885
|
type: 'string',
|
|
858
|
-
description: 'Name of file being validated (when using fileContent)'
|
|
886
|
+
description: 'Name of file being validated (when using fileContent)',
|
|
859
887
|
},
|
|
860
888
|
rules: {
|
|
861
889
|
type: 'array',
|
|
@@ -867,27 +895,27 @@ export class McpAdrAnalysisServer {
|
|
|
867
895
|
description: { type: 'string' },
|
|
868
896
|
pattern: { type: 'string' },
|
|
869
897
|
severity: { type: 'string' },
|
|
870
|
-
message: { type: 'string' }
|
|
898
|
+
message: { type: 'string' },
|
|
871
899
|
},
|
|
872
|
-
required: ['id', 'name', 'pattern', 'severity', 'message']
|
|
900
|
+
required: ['id', 'name', 'pattern', 'severity', 'message'],
|
|
873
901
|
},
|
|
874
|
-
description: 'Rules to validate against'
|
|
902
|
+
description: 'Rules to validate against',
|
|
875
903
|
},
|
|
876
904
|
validationType: {
|
|
877
905
|
type: 'string',
|
|
878
906
|
enum: ['file', 'function', 'component', 'module'],
|
|
879
907
|
description: 'Type of validation to perform',
|
|
880
|
-
default: 'file'
|
|
908
|
+
default: 'file',
|
|
881
909
|
},
|
|
882
910
|
reportFormat: {
|
|
883
911
|
type: 'string',
|
|
884
912
|
enum: ['summary', 'detailed', 'json'],
|
|
885
913
|
description: 'Format for validation report',
|
|
886
|
-
default: 'detailed'
|
|
887
|
-
}
|
|
914
|
+
default: 'detailed',
|
|
915
|
+
},
|
|
888
916
|
},
|
|
889
|
-
required: ['rules']
|
|
890
|
-
}
|
|
917
|
+
required: ['rules'],
|
|
918
|
+
},
|
|
891
919
|
},
|
|
892
920
|
{
|
|
893
921
|
name: 'create_rule_set',
|
|
@@ -897,80 +925,96 @@ export class McpAdrAnalysisServer {
|
|
|
897
925
|
properties: {
|
|
898
926
|
name: {
|
|
899
927
|
type: 'string',
|
|
900
|
-
description: 'Name of the rule set'
|
|
928
|
+
description: 'Name of the rule set',
|
|
901
929
|
},
|
|
902
930
|
description: {
|
|
903
931
|
type: 'string',
|
|
904
932
|
description: 'Description of the rule set',
|
|
905
|
-
default: 'Generated architectural rule set'
|
|
933
|
+
default: 'Generated architectural rule set',
|
|
906
934
|
},
|
|
907
935
|
adrRules: {
|
|
908
936
|
type: 'array',
|
|
909
937
|
items: { type: 'object' },
|
|
910
|
-
description: 'Rules extracted from ADRs'
|
|
938
|
+
description: 'Rules extracted from ADRs',
|
|
911
939
|
},
|
|
912
940
|
patternRules: {
|
|
913
941
|
type: 'array',
|
|
914
942
|
items: { type: 'object' },
|
|
915
|
-
description: 'Rules generated from code patterns'
|
|
943
|
+
description: 'Rules generated from code patterns',
|
|
916
944
|
},
|
|
917
945
|
rules: {
|
|
918
946
|
type: 'array',
|
|
919
947
|
items: { type: 'object' },
|
|
920
|
-
description: 'Additional rules to include'
|
|
948
|
+
description: 'Additional rules to include',
|
|
921
949
|
},
|
|
922
950
|
outputFormat: {
|
|
923
951
|
type: 'string',
|
|
924
952
|
enum: ['json', 'yaml', 'both'],
|
|
925
953
|
description: 'Output format for rule set',
|
|
926
|
-
default: 'json'
|
|
954
|
+
default: 'json',
|
|
927
955
|
},
|
|
928
956
|
author: {
|
|
929
957
|
type: 'string',
|
|
930
958
|
description: 'Author of the rule set',
|
|
931
|
-
default: 'MCP ADR Analysis Server'
|
|
932
|
-
}
|
|
959
|
+
default: 'MCP ADR Analysis Server',
|
|
960
|
+
},
|
|
933
961
|
},
|
|
934
|
-
required: ['name']
|
|
935
|
-
}
|
|
962
|
+
required: ['name'],
|
|
963
|
+
},
|
|
936
964
|
},
|
|
937
965
|
{
|
|
938
966
|
name: 'analyze_environment',
|
|
939
|
-
description: 'Analyze environment context and provide optimization recommendations',
|
|
967
|
+
description: 'Analyze environment context and provide optimization recommendations with optional memory integration for environment snapshot tracking',
|
|
940
968
|
inputSchema: {
|
|
941
969
|
type: 'object',
|
|
942
970
|
properties: {
|
|
943
971
|
projectPath: {
|
|
944
972
|
type: 'string',
|
|
945
973
|
description: 'Path to project directory',
|
|
946
|
-
default: '.'
|
|
974
|
+
default: '.',
|
|
947
975
|
},
|
|
948
976
|
adrDirectory: {
|
|
949
977
|
type: 'string',
|
|
950
978
|
description: 'Directory containing ADR files',
|
|
951
|
-
default: 'docs/adrs'
|
|
979
|
+
default: 'docs/adrs',
|
|
952
980
|
},
|
|
953
981
|
analysisType: {
|
|
954
982
|
type: 'string',
|
|
955
|
-
enum: [
|
|
983
|
+
enum: [
|
|
984
|
+
'specs',
|
|
985
|
+
'containerization',
|
|
986
|
+
'requirements',
|
|
987
|
+
'compliance',
|
|
988
|
+
'comprehensive',
|
|
989
|
+
],
|
|
956
990
|
description: 'Type of environment analysis to perform',
|
|
957
|
-
default: 'comprehensive'
|
|
991
|
+
default: 'comprehensive',
|
|
958
992
|
},
|
|
959
993
|
currentEnvironment: {
|
|
960
994
|
type: 'object',
|
|
961
|
-
description: 'Current environment specifications (for compliance analysis)'
|
|
995
|
+
description: 'Current environment specifications (for compliance analysis)',
|
|
962
996
|
},
|
|
963
997
|
requirements: {
|
|
964
998
|
type: 'object',
|
|
965
|
-
description: 'Environment requirements (for compliance analysis)'
|
|
999
|
+
description: 'Environment requirements (for compliance analysis)',
|
|
966
1000
|
},
|
|
967
1001
|
industryStandards: {
|
|
968
1002
|
type: 'array',
|
|
969
1003
|
items: { type: 'string' },
|
|
970
|
-
description: 'Industry standards to assess compliance against'
|
|
971
|
-
}
|
|
972
|
-
|
|
973
|
-
|
|
1004
|
+
description: 'Industry standards to assess compliance against',
|
|
1005
|
+
},
|
|
1006
|
+
enableMemoryIntegration: {
|
|
1007
|
+
type: 'boolean',
|
|
1008
|
+
description: 'Enable memory entity storage for environment snapshot tracking and historical analysis',
|
|
1009
|
+
default: true,
|
|
1010
|
+
},
|
|
1011
|
+
enableTrendAnalysis: {
|
|
1012
|
+
type: 'boolean',
|
|
1013
|
+
description: 'Enable analysis of environment changes over time using stored snapshots',
|
|
1014
|
+
default: true,
|
|
1015
|
+
},
|
|
1016
|
+
},
|
|
1017
|
+
},
|
|
974
1018
|
},
|
|
975
1019
|
{
|
|
976
1020
|
name: 'generate_research_questions',
|
|
@@ -982,7 +1026,7 @@ export class McpAdrAnalysisServer {
|
|
|
982
1026
|
type: 'string',
|
|
983
1027
|
enum: ['correlation', 'relevance', 'questions', 'tracking', 'comprehensive'],
|
|
984
1028
|
description: 'Type of research analysis to perform',
|
|
985
|
-
default: 'comprehensive'
|
|
1029
|
+
default: 'comprehensive',
|
|
986
1030
|
},
|
|
987
1031
|
researchContext: {
|
|
988
1032
|
type: 'object',
|
|
@@ -992,9 +1036,9 @@ export class McpAdrAnalysisServer {
|
|
|
992
1036
|
scope: { type: 'string' },
|
|
993
1037
|
objectives: { type: 'array', items: { type: 'string' } },
|
|
994
1038
|
constraints: { type: 'array', items: { type: 'string' } },
|
|
995
|
-
timeline: { type: 'string' }
|
|
1039
|
+
timeline: { type: 'string' },
|
|
996
1040
|
},
|
|
997
|
-
description: 'Research context and objectives'
|
|
1041
|
+
description: 'Research context and objectives',
|
|
998
1042
|
},
|
|
999
1043
|
problems: {
|
|
1000
1044
|
type: 'array',
|
|
@@ -1005,10 +1049,10 @@ export class McpAdrAnalysisServer {
|
|
|
1005
1049
|
description: { type: 'string' },
|
|
1006
1050
|
category: { type: 'string' },
|
|
1007
1051
|
severity: { type: 'string' },
|
|
1008
|
-
context: { type: 'string' }
|
|
1009
|
-
}
|
|
1052
|
+
context: { type: 'string' },
|
|
1053
|
+
},
|
|
1010
1054
|
},
|
|
1011
|
-
description: 'Problems to correlate with knowledge graph'
|
|
1055
|
+
description: 'Problems to correlate with knowledge graph',
|
|
1012
1056
|
},
|
|
1013
1057
|
knowledgeGraph: {
|
|
1014
1058
|
type: 'object',
|
|
@@ -1016,9 +1060,9 @@ export class McpAdrAnalysisServer {
|
|
|
1016
1060
|
technologies: { type: 'array', items: { type: 'object' } },
|
|
1017
1061
|
patterns: { type: 'array', items: { type: 'object' } },
|
|
1018
1062
|
adrs: { type: 'array', items: { type: 'object' } },
|
|
1019
|
-
relationships: { type: 'array', items: { type: 'object' } }
|
|
1063
|
+
relationships: { type: 'array', items: { type: 'object' } },
|
|
1020
1064
|
},
|
|
1021
|
-
description: 'Architectural knowledge graph'
|
|
1065
|
+
description: 'Architectural knowledge graph',
|
|
1022
1066
|
},
|
|
1023
1067
|
relevantKnowledge: {
|
|
1024
1068
|
type: 'object',
|
|
@@ -1026,9 +1070,9 @@ export class McpAdrAnalysisServer {
|
|
|
1026
1070
|
adrs: { type: 'array', items: { type: 'object' } },
|
|
1027
1071
|
patterns: { type: 'array', items: { type: 'object' } },
|
|
1028
1072
|
gaps: { type: 'array', items: { type: 'object' } },
|
|
1029
|
-
opportunities: { type: 'array', items: { type: 'object' } }
|
|
1073
|
+
opportunities: { type: 'array', items: { type: 'object' } },
|
|
1030
1074
|
},
|
|
1031
|
-
description: 'Relevant knowledge for question generation'
|
|
1075
|
+
description: 'Relevant knowledge for question generation',
|
|
1032
1076
|
},
|
|
1033
1077
|
researchQuestions: {
|
|
1034
1078
|
type: 'array',
|
|
@@ -1040,10 +1084,10 @@ export class McpAdrAnalysisServer {
|
|
|
1040
1084
|
type: { type: 'string' },
|
|
1041
1085
|
priority: { type: 'string' },
|
|
1042
1086
|
timeline: { type: 'string' },
|
|
1043
|
-
methodology: { type: 'string' }
|
|
1044
|
-
}
|
|
1087
|
+
methodology: { type: 'string' },
|
|
1088
|
+
},
|
|
1045
1089
|
},
|
|
1046
|
-
description: 'Research questions for task tracking'
|
|
1090
|
+
description: 'Research questions for task tracking',
|
|
1047
1091
|
},
|
|
1048
1092
|
currentProgress: {
|
|
1049
1093
|
type: 'array',
|
|
@@ -1054,23 +1098,23 @@ export class McpAdrAnalysisServer {
|
|
|
1054
1098
|
status: { type: 'string' },
|
|
1055
1099
|
progress: { type: 'number' },
|
|
1056
1100
|
findings: { type: 'array', items: { type: 'string' } },
|
|
1057
|
-
blockers: { type: 'array', items: { type: 'string' } }
|
|
1058
|
-
}
|
|
1101
|
+
blockers: { type: 'array', items: { type: 'string' } },
|
|
1102
|
+
},
|
|
1059
1103
|
},
|
|
1060
|
-
description: 'Current research progress'
|
|
1104
|
+
description: 'Current research progress',
|
|
1061
1105
|
},
|
|
1062
1106
|
projectPath: {
|
|
1063
1107
|
type: 'string',
|
|
1064
1108
|
description: 'Path to project directory',
|
|
1065
|
-
default: '.'
|
|
1109
|
+
default: '.',
|
|
1066
1110
|
},
|
|
1067
1111
|
adrDirectory: {
|
|
1068
1112
|
type: 'string',
|
|
1069
1113
|
description: 'Directory containing ADR files',
|
|
1070
|
-
default: 'docs/adrs'
|
|
1071
|
-
}
|
|
1072
|
-
}
|
|
1073
|
-
}
|
|
1114
|
+
default: 'docs/adrs',
|
|
1115
|
+
},
|
|
1116
|
+
},
|
|
1117
|
+
},
|
|
1074
1118
|
},
|
|
1075
1119
|
{
|
|
1076
1120
|
name: 'analyze_deployment_progress',
|
|
@@ -1082,25 +1126,25 @@ export class McpAdrAnalysisServer {
|
|
|
1082
1126
|
type: 'string',
|
|
1083
1127
|
enum: ['tasks', 'cicd', 'progress', 'completion', 'comprehensive'],
|
|
1084
1128
|
description: 'Type of deployment analysis to perform',
|
|
1085
|
-
default: 'comprehensive'
|
|
1129
|
+
default: 'comprehensive',
|
|
1086
1130
|
},
|
|
1087
1131
|
adrDirectory: {
|
|
1088
1132
|
type: 'string',
|
|
1089
1133
|
description: 'Directory containing ADR files',
|
|
1090
|
-
default: 'docs/adrs'
|
|
1134
|
+
default: 'docs/adrs',
|
|
1091
1135
|
},
|
|
1092
1136
|
todoPath: {
|
|
1093
1137
|
type: 'string',
|
|
1094
1138
|
description: 'Path to TODO.md file for task identification',
|
|
1095
|
-
default: 'TODO.md'
|
|
1139
|
+
default: 'TODO.md',
|
|
1096
1140
|
},
|
|
1097
1141
|
cicdLogs: {
|
|
1098
1142
|
type: 'string',
|
|
1099
|
-
description: 'CI/CD pipeline logs for analysis'
|
|
1143
|
+
description: 'CI/CD pipeline logs for analysis',
|
|
1100
1144
|
},
|
|
1101
1145
|
pipelineConfig: {
|
|
1102
1146
|
type: 'string',
|
|
1103
|
-
description: 'CI/CD pipeline configuration'
|
|
1147
|
+
description: 'CI/CD pipeline configuration',
|
|
1104
1148
|
},
|
|
1105
1149
|
deploymentTasks: {
|
|
1106
1150
|
type: 'array',
|
|
@@ -1114,10 +1158,10 @@ export class McpAdrAnalysisServer {
|
|
|
1114
1158
|
category: { type: 'string' },
|
|
1115
1159
|
priority: { type: 'string' },
|
|
1116
1160
|
verificationCriteria: { type: 'array', items: { type: 'string' } },
|
|
1117
|
-
expectedOutcome: { type: 'string' }
|
|
1118
|
-
}
|
|
1161
|
+
expectedOutcome: { type: 'string' },
|
|
1162
|
+
},
|
|
1119
1163
|
},
|
|
1120
|
-
description: 'Deployment tasks for progress calculation'
|
|
1164
|
+
description: 'Deployment tasks for progress calculation',
|
|
1121
1165
|
},
|
|
1122
1166
|
outcomeRules: {
|
|
1123
1167
|
type: 'array',
|
|
@@ -1127,10 +1171,10 @@ export class McpAdrAnalysisServer {
|
|
|
1127
1171
|
ruleId: { type: 'string' },
|
|
1128
1172
|
description: { type: 'string' },
|
|
1129
1173
|
criteria: { type: 'array', items: { type: 'string' } },
|
|
1130
|
-
verificationMethod: { type: 'string' }
|
|
1131
|
-
}
|
|
1174
|
+
verificationMethod: { type: 'string' },
|
|
1175
|
+
},
|
|
1132
1176
|
},
|
|
1133
|
-
description: 'Outcome rules for completion verification'
|
|
1177
|
+
description: 'Outcome rules for completion verification',
|
|
1134
1178
|
},
|
|
1135
1179
|
actualOutcomes: {
|
|
1136
1180
|
type: 'array',
|
|
@@ -1140,21 +1184,21 @@ export class McpAdrAnalysisServer {
|
|
|
1140
1184
|
taskId: { type: 'string' },
|
|
1141
1185
|
outcome: { type: 'string' },
|
|
1142
1186
|
evidence: { type: 'array', items: { type: 'string' } },
|
|
1143
|
-
timestamp: { type: 'string' }
|
|
1144
|
-
}
|
|
1187
|
+
timestamp: { type: 'string' },
|
|
1188
|
+
},
|
|
1145
1189
|
},
|
|
1146
|
-
description: 'Actual deployment outcomes'
|
|
1190
|
+
description: 'Actual deployment outcomes',
|
|
1147
1191
|
},
|
|
1148
1192
|
cicdStatus: {
|
|
1149
1193
|
type: 'object',
|
|
1150
|
-
description: 'CI/CD pipeline status data'
|
|
1194
|
+
description: 'CI/CD pipeline status data',
|
|
1151
1195
|
},
|
|
1152
1196
|
environmentStatus: {
|
|
1153
1197
|
type: 'object',
|
|
1154
|
-
description: 'Environment status data'
|
|
1155
|
-
}
|
|
1156
|
-
}
|
|
1157
|
-
}
|
|
1198
|
+
description: 'Environment status data',
|
|
1199
|
+
},
|
|
1200
|
+
},
|
|
1201
|
+
},
|
|
1158
1202
|
},
|
|
1159
1203
|
{
|
|
1160
1204
|
name: 'check_ai_execution_status',
|
|
@@ -1162,8 +1206,8 @@ export class McpAdrAnalysisServer {
|
|
|
1162
1206
|
inputSchema: {
|
|
1163
1207
|
type: 'object',
|
|
1164
1208
|
properties: {},
|
|
1165
|
-
required: []
|
|
1166
|
-
}
|
|
1209
|
+
required: [],
|
|
1210
|
+
},
|
|
1167
1211
|
},
|
|
1168
1212
|
{
|
|
1169
1213
|
name: 'get_workflow_guidance',
|
|
@@ -1173,31 +1217,44 @@ export class McpAdrAnalysisServer {
|
|
|
1173
1217
|
properties: {
|
|
1174
1218
|
goal: {
|
|
1175
1219
|
type: 'string',
|
|
1176
|
-
description: 'What you want to accomplish (e.g., "analyze new project", "document existing decisions", "security audit", "modernize legacy system")'
|
|
1220
|
+
description: 'What you want to accomplish (e.g., "analyze new project", "document existing decisions", "security audit", "modernize legacy system")',
|
|
1177
1221
|
},
|
|
1178
1222
|
projectContext: {
|
|
1179
1223
|
type: 'string',
|
|
1180
1224
|
description: 'Current state of your project (e.g., "new project", "existing project with ADRs", "legacy codebase", "greenfield development")',
|
|
1181
|
-
enum: [
|
|
1225
|
+
enum: [
|
|
1226
|
+
'new_project',
|
|
1227
|
+
'existing_with_adrs',
|
|
1228
|
+
'existing_without_adrs',
|
|
1229
|
+
'legacy_codebase',
|
|
1230
|
+
'greenfield',
|
|
1231
|
+
'maintenance_mode',
|
|
1232
|
+
'unknown',
|
|
1233
|
+
],
|
|
1182
1234
|
},
|
|
1183
1235
|
availableAssets: {
|
|
1184
1236
|
type: 'array',
|
|
1185
1237
|
items: { type: 'string' },
|
|
1186
|
-
description: 'What assets you already have (e.g., ["PRD.md", "existing ADRs", "codebase", "documentation", "test suite"])'
|
|
1238
|
+
description: 'What assets you already have (e.g., ["PRD.md", "existing ADRs", "codebase", "documentation", "test suite"])',
|
|
1187
1239
|
},
|
|
1188
1240
|
timeframe: {
|
|
1189
1241
|
type: 'string',
|
|
1190
1242
|
description: 'Available time/effort level',
|
|
1191
|
-
enum: [
|
|
1243
|
+
enum: [
|
|
1244
|
+
'quick_analysis',
|
|
1245
|
+
'thorough_review',
|
|
1246
|
+
'comprehensive_audit',
|
|
1247
|
+
'ongoing_process',
|
|
1248
|
+
],
|
|
1192
1249
|
},
|
|
1193
1250
|
primaryConcerns: {
|
|
1194
1251
|
type: 'array',
|
|
1195
1252
|
items: { type: 'string' },
|
|
1196
|
-
description: 'Main areas of concern (e.g., ["security", "performance", "maintainability", "scalability", "compliance"])'
|
|
1197
|
-
}
|
|
1253
|
+
description: 'Main areas of concern (e.g., ["security", "performance", "maintainability", "scalability", "compliance"])',
|
|
1254
|
+
},
|
|
1198
1255
|
},
|
|
1199
|
-
required: ['goal', 'projectContext']
|
|
1200
|
-
}
|
|
1256
|
+
required: ['goal', 'projectContext'],
|
|
1257
|
+
},
|
|
1201
1258
|
},
|
|
1202
1259
|
{
|
|
1203
1260
|
name: 'get_development_guidance',
|
|
@@ -1208,47 +1265,55 @@ export class McpAdrAnalysisServer {
|
|
|
1208
1265
|
developmentPhase: {
|
|
1209
1266
|
type: 'string',
|
|
1210
1267
|
description: 'Current development phase',
|
|
1211
|
-
enum: [
|
|
1268
|
+
enum: [
|
|
1269
|
+
'planning',
|
|
1270
|
+
'setup',
|
|
1271
|
+
'implementation',
|
|
1272
|
+
'testing',
|
|
1273
|
+
'deployment',
|
|
1274
|
+
'maintenance',
|
|
1275
|
+
'refactoring',
|
|
1276
|
+
],
|
|
1212
1277
|
},
|
|
1213
1278
|
adrsToImplement: {
|
|
1214
1279
|
type: 'array',
|
|
1215
1280
|
items: { type: 'string' },
|
|
1216
|
-
description: 'List of ADR titles or file paths that need to be implemented in code'
|
|
1281
|
+
description: 'List of ADR titles or file paths that need to be implemented in code',
|
|
1217
1282
|
},
|
|
1218
1283
|
technologyStack: {
|
|
1219
1284
|
type: 'array',
|
|
1220
1285
|
items: { type: 'string' },
|
|
1221
|
-
description: 'Current technology stack (e.g., ["TypeScript", "React", "Node.js", "PostgreSQL", "Docker"])'
|
|
1286
|
+
description: 'Current technology stack (e.g., ["TypeScript", "React", "Node.js", "PostgreSQL", "Docker"])',
|
|
1222
1287
|
},
|
|
1223
1288
|
currentProgress: {
|
|
1224
1289
|
type: 'string',
|
|
1225
|
-
description: 'What has already been implemented or current state of development'
|
|
1290
|
+
description: 'What has already been implemented or current state of development',
|
|
1226
1291
|
},
|
|
1227
1292
|
teamContext: {
|
|
1228
1293
|
type: 'object',
|
|
1229
1294
|
properties: {
|
|
1230
1295
|
size: {
|
|
1231
1296
|
type: 'string',
|
|
1232
|
-
enum: ['solo', 'small_team', 'medium_team', 'large_team']
|
|
1297
|
+
enum: ['solo', 'small_team', 'medium_team', 'large_team'],
|
|
1233
1298
|
},
|
|
1234
1299
|
experienceLevel: {
|
|
1235
1300
|
type: 'string',
|
|
1236
|
-
enum: ['junior', 'mixed', 'senior', 'expert']
|
|
1237
|
-
}
|
|
1238
|
-
}
|
|
1301
|
+
enum: ['junior', 'mixed', 'senior', 'expert'],
|
|
1302
|
+
},
|
|
1303
|
+
},
|
|
1239
1304
|
},
|
|
1240
1305
|
timeline: {
|
|
1241
1306
|
type: 'string',
|
|
1242
|
-
description: 'Development timeline or deadline constraints'
|
|
1307
|
+
description: 'Development timeline or deadline constraints',
|
|
1243
1308
|
},
|
|
1244
1309
|
focusAreas: {
|
|
1245
1310
|
type: 'array',
|
|
1246
1311
|
items: { type: 'string' },
|
|
1247
|
-
description: 'Specific areas to focus on (e.g., ["API design", "database schema", "testing strategy", "deployment pipeline"])'
|
|
1248
|
-
}
|
|
1312
|
+
description: 'Specific areas to focus on (e.g., ["API design", "database schema", "testing strategy", "deployment pipeline"])',
|
|
1313
|
+
},
|
|
1249
1314
|
},
|
|
1250
|
-
required: ['developmentPhase']
|
|
1251
|
-
}
|
|
1315
|
+
required: ['developmentPhase'],
|
|
1316
|
+
},
|
|
1252
1317
|
},
|
|
1253
1318
|
{
|
|
1254
1319
|
name: 'read_file',
|
|
@@ -1258,11 +1323,11 @@ export class McpAdrAnalysisServer {
|
|
|
1258
1323
|
properties: {
|
|
1259
1324
|
path: {
|
|
1260
1325
|
type: 'string',
|
|
1261
|
-
description: 'Path to the file to read'
|
|
1262
|
-
}
|
|
1326
|
+
description: 'Path to the file to read',
|
|
1327
|
+
},
|
|
1263
1328
|
},
|
|
1264
|
-
required: ['path']
|
|
1265
|
-
}
|
|
1329
|
+
required: ['path'],
|
|
1330
|
+
},
|
|
1266
1331
|
},
|
|
1267
1332
|
{
|
|
1268
1333
|
name: 'write_file',
|
|
@@ -1272,15 +1337,15 @@ export class McpAdrAnalysisServer {
|
|
|
1272
1337
|
properties: {
|
|
1273
1338
|
path: {
|
|
1274
1339
|
type: 'string',
|
|
1275
|
-
description: 'Path to the file to write'
|
|
1340
|
+
description: 'Path to the file to write',
|
|
1276
1341
|
},
|
|
1277
1342
|
content: {
|
|
1278
1343
|
type: 'string',
|
|
1279
|
-
description: 'Content to write to the file'
|
|
1280
|
-
}
|
|
1344
|
+
description: 'Content to write to the file',
|
|
1345
|
+
},
|
|
1281
1346
|
},
|
|
1282
|
-
required: ['path', 'content']
|
|
1283
|
-
}
|
|
1347
|
+
required: ['path', 'content'],
|
|
1348
|
+
},
|
|
1284
1349
|
},
|
|
1285
1350
|
{
|
|
1286
1351
|
name: 'list_directory',
|
|
@@ -1290,11 +1355,11 @@ export class McpAdrAnalysisServer {
|
|
|
1290
1355
|
properties: {
|
|
1291
1356
|
path: {
|
|
1292
1357
|
type: 'string',
|
|
1293
|
-
description: 'Path to the directory to list'
|
|
1294
|
-
}
|
|
1358
|
+
description: 'Path to the directory to list',
|
|
1359
|
+
},
|
|
1295
1360
|
},
|
|
1296
|
-
required: ['path']
|
|
1297
|
-
}
|
|
1361
|
+
required: ['path'],
|
|
1362
|
+
},
|
|
1298
1363
|
},
|
|
1299
1364
|
{
|
|
1300
1365
|
name: 'manage_todo_json',
|
|
@@ -1304,175 +1369,191 @@ export class McpAdrAnalysisServer {
|
|
|
1304
1369
|
properties: {
|
|
1305
1370
|
operation: {
|
|
1306
1371
|
type: 'string',
|
|
1307
|
-
enum: [
|
|
1308
|
-
|
|
1372
|
+
enum: [
|
|
1373
|
+
'create_task',
|
|
1374
|
+
'update_task',
|
|
1375
|
+
'bulk_update',
|
|
1376
|
+
'get_tasks',
|
|
1377
|
+
'get_analytics',
|
|
1378
|
+
'import_adr_tasks',
|
|
1379
|
+
'sync_knowledge_graph',
|
|
1380
|
+
'sync_to_markdown',
|
|
1381
|
+
'import_from_markdown',
|
|
1382
|
+
],
|
|
1383
|
+
description: 'Operation to perform on TODO JSON backend',
|
|
1309
1384
|
},
|
|
1310
1385
|
projectPath: {
|
|
1311
1386
|
type: 'string',
|
|
1312
|
-
description: 'Project root path (uses configured PROJECT_PATH if not provided)'
|
|
1387
|
+
description: 'Project root path (uses configured PROJECT_PATH if not provided)',
|
|
1313
1388
|
},
|
|
1314
1389
|
taskId: {
|
|
1315
1390
|
type: 'string',
|
|
1316
|
-
description: 'Task ID for update operations'
|
|
1391
|
+
description: 'Task ID for update operations',
|
|
1317
1392
|
},
|
|
1318
1393
|
title: {
|
|
1319
1394
|
type: 'string',
|
|
1320
|
-
description: 'Task title for create operations'
|
|
1395
|
+
description: 'Task title for create operations',
|
|
1321
1396
|
},
|
|
1322
1397
|
description: {
|
|
1323
1398
|
type: 'string',
|
|
1324
|
-
description: 'Task description'
|
|
1399
|
+
description: 'Task description',
|
|
1325
1400
|
},
|
|
1326
1401
|
priority: {
|
|
1327
1402
|
type: 'string',
|
|
1328
1403
|
enum: ['low', 'medium', 'high', 'critical'],
|
|
1329
1404
|
default: 'medium',
|
|
1330
|
-
description: 'Task priority level'
|
|
1405
|
+
description: 'Task priority level',
|
|
1331
1406
|
},
|
|
1332
1407
|
assignee: {
|
|
1333
1408
|
type: 'string',
|
|
1334
|
-
description: 'Task assignee'
|
|
1409
|
+
description: 'Task assignee',
|
|
1335
1410
|
},
|
|
1336
1411
|
dueDate: {
|
|
1337
1412
|
type: 'string',
|
|
1338
|
-
description: 'Due date (ISO string format)'
|
|
1413
|
+
description: 'Due date (ISO string format)',
|
|
1339
1414
|
},
|
|
1340
1415
|
category: {
|
|
1341
1416
|
type: 'string',
|
|
1342
|
-
description: 'Task category'
|
|
1417
|
+
description: 'Task category',
|
|
1343
1418
|
},
|
|
1344
1419
|
tags: {
|
|
1345
1420
|
type: 'array',
|
|
1346
1421
|
items: { type: 'string' },
|
|
1347
|
-
description: 'Task tags'
|
|
1422
|
+
description: 'Task tags',
|
|
1348
1423
|
},
|
|
1349
1424
|
dependencies: {
|
|
1350
1425
|
type: 'array',
|
|
1351
1426
|
items: { type: 'string' },
|
|
1352
|
-
description: 'Task dependencies (task IDs)'
|
|
1427
|
+
description: 'Task dependencies (task IDs)',
|
|
1353
1428
|
},
|
|
1354
1429
|
intentId: {
|
|
1355
1430
|
type: 'string',
|
|
1356
|
-
description: 'Link to knowledge graph intent'
|
|
1431
|
+
description: 'Link to knowledge graph intent',
|
|
1357
1432
|
},
|
|
1358
1433
|
linkedAdrs: {
|
|
1359
1434
|
type: 'array',
|
|
1360
1435
|
items: { type: 'string' },
|
|
1361
|
-
description: 'Related ADR files'
|
|
1436
|
+
description: 'Related ADR files',
|
|
1362
1437
|
},
|
|
1363
1438
|
autoComplete: {
|
|
1364
1439
|
type: 'boolean',
|
|
1365
1440
|
default: false,
|
|
1366
|
-
description: 'Auto-complete when criteria are met'
|
|
1441
|
+
description: 'Auto-complete when criteria are met',
|
|
1367
1442
|
},
|
|
1368
1443
|
completionCriteria: {
|
|
1369
1444
|
type: 'string',
|
|
1370
|
-
description: 'Auto-completion rules'
|
|
1445
|
+
description: 'Auto-completion rules',
|
|
1371
1446
|
},
|
|
1372
1447
|
updates: {
|
|
1373
1448
|
type: 'object',
|
|
1374
1449
|
properties: {
|
|
1375
1450
|
title: { type: 'string' },
|
|
1376
1451
|
description: { type: 'string' },
|
|
1377
|
-
status: {
|
|
1452
|
+
status: {
|
|
1453
|
+
type: 'string',
|
|
1454
|
+
enum: ['pending', 'in_progress', 'completed', 'blocked', 'cancelled'],
|
|
1455
|
+
},
|
|
1378
1456
|
priority: { type: 'string', enum: ['low', 'medium', 'high', 'critical'] },
|
|
1379
1457
|
assignee: { type: 'string' },
|
|
1380
1458
|
dueDate: { type: 'string' },
|
|
1381
1459
|
progressPercentage: { type: 'number', minimum: 0, maximum: 100 },
|
|
1382
1460
|
notes: { type: 'string' },
|
|
1383
|
-
tags: { type: 'array', items: { type: 'string' } }
|
|
1461
|
+
tags: { type: 'array', items: { type: 'string' } },
|
|
1384
1462
|
},
|
|
1385
|
-
description: 'Fields to update for update operations'
|
|
1463
|
+
description: 'Fields to update for update operations',
|
|
1386
1464
|
},
|
|
1387
1465
|
reason: {
|
|
1388
1466
|
type: 'string',
|
|
1389
|
-
description: 'Reason for update (for changelog)'
|
|
1467
|
+
description: 'Reason for update (for changelog)',
|
|
1390
1468
|
},
|
|
1391
1469
|
filters: {
|
|
1392
1470
|
type: 'object',
|
|
1393
1471
|
properties: {
|
|
1394
|
-
status: {
|
|
1472
|
+
status: {
|
|
1473
|
+
type: 'string',
|
|
1474
|
+
enum: ['pending', 'in_progress', 'completed', 'blocked', 'cancelled'],
|
|
1475
|
+
},
|
|
1395
1476
|
priority: { type: 'string', enum: ['low', 'medium', 'high', 'critical'] },
|
|
1396
1477
|
assignee: { type: 'string' },
|
|
1397
1478
|
category: { type: 'string' },
|
|
1398
1479
|
hasDeadline: { type: 'boolean' },
|
|
1399
1480
|
overdue: { type: 'boolean' },
|
|
1400
|
-
tags: { type: 'array', items: { type: 'string' } }
|
|
1481
|
+
tags: { type: 'array', items: { type: 'string' } },
|
|
1401
1482
|
},
|
|
1402
|
-
description: 'Filter criteria for get_tasks operation'
|
|
1483
|
+
description: 'Filter criteria for get_tasks operation',
|
|
1403
1484
|
},
|
|
1404
1485
|
sortBy: {
|
|
1405
1486
|
type: 'string',
|
|
1406
1487
|
enum: ['priority', 'dueDate', 'createdAt', 'updatedAt'],
|
|
1407
1488
|
default: 'priority',
|
|
1408
|
-
description: 'Sort field for get_tasks operation'
|
|
1489
|
+
description: 'Sort field for get_tasks operation',
|
|
1409
1490
|
},
|
|
1410
1491
|
sortOrder: {
|
|
1411
1492
|
type: 'string',
|
|
1412
1493
|
enum: ['asc', 'desc'],
|
|
1413
1494
|
default: 'desc',
|
|
1414
|
-
description: 'Sort order for get_tasks operation'
|
|
1495
|
+
description: 'Sort order for get_tasks operation',
|
|
1415
1496
|
},
|
|
1416
1497
|
limit: {
|
|
1417
1498
|
type: 'number',
|
|
1418
|
-
description: 'Maximum number of tasks to return'
|
|
1499
|
+
description: 'Maximum number of tasks to return',
|
|
1419
1500
|
},
|
|
1420
1501
|
timeframe: {
|
|
1421
1502
|
type: 'string',
|
|
1422
1503
|
enum: ['day', 'week', 'month', 'all'],
|
|
1423
1504
|
default: 'week',
|
|
1424
|
-
description: 'Analysis timeframe for analytics'
|
|
1505
|
+
description: 'Analysis timeframe for analytics',
|
|
1425
1506
|
},
|
|
1426
1507
|
includeVelocity: {
|
|
1427
1508
|
type: 'boolean',
|
|
1428
1509
|
default: true,
|
|
1429
|
-
description: 'Include velocity metrics in analytics'
|
|
1510
|
+
description: 'Include velocity metrics in analytics',
|
|
1430
1511
|
},
|
|
1431
1512
|
includeScoring: {
|
|
1432
1513
|
type: 'boolean',
|
|
1433
1514
|
default: true,
|
|
1434
|
-
description: 'Include scoring metrics in analytics'
|
|
1515
|
+
description: 'Include scoring metrics in analytics',
|
|
1435
1516
|
},
|
|
1436
1517
|
adrDirectory: {
|
|
1437
1518
|
type: 'string',
|
|
1438
1519
|
default: 'docs/adrs',
|
|
1439
|
-
description: 'ADR directory path for imports'
|
|
1520
|
+
description: 'ADR directory path for imports',
|
|
1440
1521
|
},
|
|
1441
1522
|
preserveExisting: {
|
|
1442
1523
|
type: 'boolean',
|
|
1443
1524
|
default: true,
|
|
1444
|
-
description: 'Keep existing tasks during imports'
|
|
1525
|
+
description: 'Keep existing tasks during imports',
|
|
1445
1526
|
},
|
|
1446
1527
|
autoLinkDependencies: {
|
|
1447
1528
|
type: 'boolean',
|
|
1448
1529
|
default: true,
|
|
1449
|
-
description: 'Auto-detect task dependencies'
|
|
1530
|
+
description: 'Auto-detect task dependencies',
|
|
1450
1531
|
},
|
|
1451
1532
|
direction: {
|
|
1452
1533
|
type: 'string',
|
|
1453
1534
|
enum: ['to_kg', 'from_kg', 'bidirectional'],
|
|
1454
1535
|
default: 'bidirectional',
|
|
1455
|
-
description: 'Knowledge graph sync direction'
|
|
1536
|
+
description: 'Knowledge graph sync direction',
|
|
1456
1537
|
},
|
|
1457
1538
|
force: {
|
|
1458
1539
|
type: 'boolean',
|
|
1459
1540
|
default: false,
|
|
1460
|
-
description: 'Force operation even if conflicts exist'
|
|
1541
|
+
description: 'Force operation even if conflicts exist',
|
|
1461
1542
|
},
|
|
1462
1543
|
mergeStrategy: {
|
|
1463
1544
|
type: 'string',
|
|
1464
1545
|
enum: ['overwrite', 'merge', 'preserve_json'],
|
|
1465
1546
|
default: 'merge',
|
|
1466
|
-
description: 'Merge strategy for imports'
|
|
1547
|
+
description: 'Merge strategy for imports',
|
|
1467
1548
|
},
|
|
1468
1549
|
backupExisting: {
|
|
1469
1550
|
type: 'boolean',
|
|
1470
1551
|
default: true,
|
|
1471
|
-
description: 'Create backup before destructive operations'
|
|
1472
|
-
}
|
|
1552
|
+
description: 'Create backup before destructive operations',
|
|
1553
|
+
},
|
|
1473
1554
|
},
|
|
1474
|
-
required: ['operation']
|
|
1475
|
-
}
|
|
1555
|
+
required: ['operation'],
|
|
1556
|
+
},
|
|
1476
1557
|
},
|
|
1477
1558
|
{
|
|
1478
1559
|
name: 'generate_deployment_guidance',
|
|
@@ -1483,65 +1564,75 @@ export class McpAdrAnalysisServer {
|
|
|
1483
1564
|
adrDirectory: {
|
|
1484
1565
|
type: 'string',
|
|
1485
1566
|
default: 'docs/adrs',
|
|
1486
|
-
description: 'Directory containing ADR files'
|
|
1567
|
+
description: 'Directory containing ADR files',
|
|
1487
1568
|
},
|
|
1488
1569
|
environment: {
|
|
1489
1570
|
type: 'string',
|
|
1490
1571
|
enum: ['development', 'staging', 'production', 'all'],
|
|
1491
1572
|
default: 'production',
|
|
1492
|
-
description: 'Target deployment environment'
|
|
1573
|
+
description: 'Target deployment environment',
|
|
1493
1574
|
},
|
|
1494
1575
|
format: {
|
|
1495
1576
|
type: 'string',
|
|
1496
1577
|
enum: ['markdown', 'scripts', 'structured', 'all'],
|
|
1497
1578
|
default: 'markdown',
|
|
1498
|
-
description: 'Output format for guidance'
|
|
1579
|
+
description: 'Output format for guidance',
|
|
1499
1580
|
},
|
|
1500
1581
|
projectPath: {
|
|
1501
1582
|
type: 'string',
|
|
1502
|
-
description: 'Project root path (optional, uses configured PROJECT_PATH if not provided)'
|
|
1583
|
+
description: 'Project root path (optional, uses configured PROJECT_PATH if not provided)',
|
|
1503
1584
|
},
|
|
1504
1585
|
includeScripts: {
|
|
1505
1586
|
type: 'boolean',
|
|
1506
1587
|
default: true,
|
|
1507
|
-
description: 'Generate deployment scripts'
|
|
1588
|
+
description: 'Generate deployment scripts',
|
|
1508
1589
|
},
|
|
1509
1590
|
includeConfigs: {
|
|
1510
1591
|
type: 'boolean',
|
|
1511
1592
|
default: true,
|
|
1512
|
-
description: 'Generate configuration files'
|
|
1593
|
+
description: 'Generate configuration files',
|
|
1513
1594
|
},
|
|
1514
1595
|
includeValidation: {
|
|
1515
1596
|
type: 'boolean',
|
|
1516
1597
|
default: true,
|
|
1517
|
-
description: 'Include validation and health checks'
|
|
1598
|
+
description: 'Include validation and health checks',
|
|
1518
1599
|
},
|
|
1519
1600
|
technologyFilter: {
|
|
1520
1601
|
type: 'array',
|
|
1521
1602
|
items: {
|
|
1522
1603
|
type: 'string',
|
|
1523
|
-
enum: [
|
|
1604
|
+
enum: [
|
|
1605
|
+
'containerization',
|
|
1606
|
+
'database',
|
|
1607
|
+
'web-server',
|
|
1608
|
+
'cache',
|
|
1609
|
+
'message-queue',
|
|
1610
|
+
'monitoring',
|
|
1611
|
+
'security',
|
|
1612
|
+
'ci-cd',
|
|
1613
|
+
'infrastructure',
|
|
1614
|
+
],
|
|
1524
1615
|
},
|
|
1525
|
-
description: 'Filter by specific technology categories'
|
|
1616
|
+
description: 'Filter by specific technology categories',
|
|
1526
1617
|
},
|
|
1527
1618
|
customRequirements: {
|
|
1528
1619
|
type: 'array',
|
|
1529
1620
|
items: { type: 'string' },
|
|
1530
|
-
description: 'Additional custom requirements'
|
|
1621
|
+
description: 'Additional custom requirements',
|
|
1531
1622
|
},
|
|
1532
1623
|
includeRollback: {
|
|
1533
1624
|
type: 'boolean',
|
|
1534
1625
|
default: true,
|
|
1535
|
-
description: 'Include rollback procedures'
|
|
1626
|
+
description: 'Include rollback procedures',
|
|
1536
1627
|
},
|
|
1537
1628
|
generateFiles: {
|
|
1538
1629
|
type: 'boolean',
|
|
1539
1630
|
default: false,
|
|
1540
|
-
description: 'Actually generate files (vs just guidance)'
|
|
1541
|
-
}
|
|
1631
|
+
description: 'Actually generate files (vs just guidance)',
|
|
1632
|
+
},
|
|
1542
1633
|
},
|
|
1543
|
-
required: []
|
|
1544
|
-
}
|
|
1634
|
+
required: [],
|
|
1635
|
+
},
|
|
1545
1636
|
},
|
|
1546
1637
|
{
|
|
1547
1638
|
name: 'smart_git_push',
|
|
@@ -1551,11 +1642,11 @@ export class McpAdrAnalysisServer {
|
|
|
1551
1642
|
properties: {
|
|
1552
1643
|
branch: {
|
|
1553
1644
|
type: 'string',
|
|
1554
|
-
description: 'Target branch for push (optional, uses current branch if not specified)'
|
|
1645
|
+
description: 'Target branch for push (optional, uses current branch if not specified)',
|
|
1555
1646
|
},
|
|
1556
1647
|
message: {
|
|
1557
1648
|
type: 'string',
|
|
1558
|
-
description: 'Commit message (optional, commits staged files if provided)'
|
|
1649
|
+
description: 'Commit message (optional, commits staged files if provided)',
|
|
1559
1650
|
},
|
|
1560
1651
|
testResults: {
|
|
1561
1652
|
type: 'object',
|
|
@@ -1563,36 +1654,36 @@ export class McpAdrAnalysisServer {
|
|
|
1563
1654
|
properties: {
|
|
1564
1655
|
success: {
|
|
1565
1656
|
type: 'boolean',
|
|
1566
|
-
description: 'Whether all tests passed'
|
|
1657
|
+
description: 'Whether all tests passed',
|
|
1567
1658
|
},
|
|
1568
1659
|
testsRun: {
|
|
1569
1660
|
type: 'number',
|
|
1570
|
-
description: 'Total number of tests executed'
|
|
1661
|
+
description: 'Total number of tests executed',
|
|
1571
1662
|
},
|
|
1572
1663
|
testsPassed: {
|
|
1573
1664
|
type: 'number',
|
|
1574
|
-
description: 'Number of tests that passed'
|
|
1665
|
+
description: 'Number of tests that passed',
|
|
1575
1666
|
},
|
|
1576
1667
|
testsFailed: {
|
|
1577
1668
|
type: 'number',
|
|
1578
|
-
description: 'Number of tests that failed'
|
|
1669
|
+
description: 'Number of tests that failed',
|
|
1579
1670
|
},
|
|
1580
1671
|
duration: {
|
|
1581
1672
|
type: 'number',
|
|
1582
|
-
description: 'Test execution duration in seconds'
|
|
1673
|
+
description: 'Test execution duration in seconds',
|
|
1583
1674
|
},
|
|
1584
1675
|
command: {
|
|
1585
1676
|
type: 'string',
|
|
1586
|
-
description: 'Test command that was executed by AI'
|
|
1677
|
+
description: 'Test command that was executed by AI',
|
|
1587
1678
|
},
|
|
1588
1679
|
output: {
|
|
1589
1680
|
type: 'string',
|
|
1590
|
-
description: 'Test execution output'
|
|
1681
|
+
description: 'Test execution output',
|
|
1591
1682
|
},
|
|
1592
1683
|
failureDetails: {
|
|
1593
1684
|
type: 'array',
|
|
1594
1685
|
items: { type: 'string' },
|
|
1595
|
-
description: 'Details of test failures'
|
|
1686
|
+
description: 'Details of test failures',
|
|
1596
1687
|
},
|
|
1597
1688
|
testTypes: {
|
|
1598
1689
|
type: 'object',
|
|
@@ -1601,34 +1692,34 @@ export class McpAdrAnalysisServer {
|
|
|
1601
1692
|
type: 'object',
|
|
1602
1693
|
properties: {
|
|
1603
1694
|
passed: { type: 'number' },
|
|
1604
|
-
failed: { type: 'number' }
|
|
1605
|
-
}
|
|
1606
|
-
}
|
|
1607
|
-
}
|
|
1695
|
+
failed: { type: 'number' },
|
|
1696
|
+
},
|
|
1697
|
+
},
|
|
1698
|
+
},
|
|
1608
1699
|
},
|
|
1609
|
-
required: ['success', 'testsRun', 'testsPassed', 'testsFailed']
|
|
1700
|
+
required: ['success', 'testsRun', 'testsPassed', 'testsFailed'],
|
|
1610
1701
|
},
|
|
1611
1702
|
skipSecurity: {
|
|
1612
1703
|
type: 'boolean',
|
|
1613
1704
|
default: false,
|
|
1614
|
-
description: 'Skip security scanning (NOT RECOMMENDED)'
|
|
1705
|
+
description: 'Skip security scanning (NOT RECOMMENDED)',
|
|
1615
1706
|
},
|
|
1616
1707
|
dryRun: {
|
|
1617
1708
|
type: 'boolean',
|
|
1618
1709
|
default: false,
|
|
1619
|
-
description: 'Show what would be pushed without actually pushing'
|
|
1710
|
+
description: 'Show what would be pushed without actually pushing',
|
|
1620
1711
|
},
|
|
1621
1712
|
projectPath: {
|
|
1622
1713
|
type: 'string',
|
|
1623
|
-
description: 'Path to project directory (defaults to current working directory)'
|
|
1714
|
+
description: 'Path to project directory (defaults to current working directory)',
|
|
1624
1715
|
},
|
|
1625
1716
|
forceUnsafe: {
|
|
1626
1717
|
type: 'boolean',
|
|
1627
1718
|
default: false,
|
|
1628
|
-
description: 'Override security blocks and test failures (DANGEROUS)'
|
|
1629
|
-
}
|
|
1630
|
-
}
|
|
1631
|
-
}
|
|
1719
|
+
description: 'Override security blocks and test failures (DANGEROUS)',
|
|
1720
|
+
},
|
|
1721
|
+
},
|
|
1722
|
+
},
|
|
1632
1723
|
},
|
|
1633
1724
|
{
|
|
1634
1725
|
name: 'deployment_readiness',
|
|
@@ -1638,222 +1729,267 @@ export class McpAdrAnalysisServer {
|
|
|
1638
1729
|
properties: {
|
|
1639
1730
|
operation: {
|
|
1640
1731
|
type: 'string',
|
|
1641
|
-
enum: [
|
|
1642
|
-
|
|
1732
|
+
enum: [
|
|
1733
|
+
'check_readiness',
|
|
1734
|
+
'validate_production',
|
|
1735
|
+
'test_validation',
|
|
1736
|
+
'deployment_history',
|
|
1737
|
+
'full_audit',
|
|
1738
|
+
'emergency_override',
|
|
1739
|
+
],
|
|
1740
|
+
description: 'Type of deployment readiness check to perform',
|
|
1643
1741
|
},
|
|
1644
1742
|
projectPath: {
|
|
1645
1743
|
type: 'string',
|
|
1646
|
-
description: 'Path to project directory (defaults to current working directory)'
|
|
1744
|
+
description: 'Path to project directory (defaults to current working directory)',
|
|
1647
1745
|
},
|
|
1648
1746
|
targetEnvironment: {
|
|
1649
1747
|
type: 'string',
|
|
1650
1748
|
enum: ['staging', 'production', 'integration'],
|
|
1651
1749
|
default: 'production',
|
|
1652
|
-
description: 'Target deployment environment'
|
|
1750
|
+
description: 'Target deployment environment',
|
|
1653
1751
|
},
|
|
1654
1752
|
strictMode: {
|
|
1655
1753
|
type: 'boolean',
|
|
1656
1754
|
default: true,
|
|
1657
|
-
description: 'Enable strict validation (recommended for production)'
|
|
1755
|
+
description: 'Enable strict validation (recommended for production)',
|
|
1658
1756
|
},
|
|
1659
1757
|
allowMockCode: {
|
|
1660
1758
|
type: 'boolean',
|
|
1661
1759
|
default: false,
|
|
1662
|
-
description: 'Allow mock code in deployment (NOT RECOMMENDED)'
|
|
1760
|
+
description: 'Allow mock code in deployment (NOT RECOMMENDED)',
|
|
1663
1761
|
},
|
|
1664
1762
|
productionCodeThreshold: {
|
|
1665
1763
|
type: 'number',
|
|
1666
1764
|
default: 85,
|
|
1667
|
-
description: 'Minimum production code quality score (0-100)'
|
|
1765
|
+
description: 'Minimum production code quality score (0-100)',
|
|
1668
1766
|
},
|
|
1669
1767
|
mockCodeMaxAllowed: {
|
|
1670
1768
|
type: 'number',
|
|
1671
1769
|
default: 0,
|
|
1672
|
-
description: 'Maximum mock code indicators allowed'
|
|
1770
|
+
description: 'Maximum mock code indicators allowed',
|
|
1673
1771
|
},
|
|
1674
1772
|
maxTestFailures: {
|
|
1675
1773
|
type: 'number',
|
|
1676
1774
|
default: 0,
|
|
1677
|
-
description: 'Maximum test failures allowed (0 = zero tolerance)'
|
|
1775
|
+
description: 'Maximum test failures allowed (0 = zero tolerance)',
|
|
1678
1776
|
},
|
|
1679
1777
|
requireTestCoverage: {
|
|
1680
1778
|
type: 'number',
|
|
1681
1779
|
default: 80,
|
|
1682
|
-
description: 'Minimum test coverage percentage required'
|
|
1780
|
+
description: 'Minimum test coverage percentage required',
|
|
1683
1781
|
},
|
|
1684
1782
|
blockOnFailingTests: {
|
|
1685
1783
|
type: 'boolean',
|
|
1686
1784
|
default: true,
|
|
1687
|
-
description: 'Block deployment if tests are failing'
|
|
1785
|
+
description: 'Block deployment if tests are failing',
|
|
1688
1786
|
},
|
|
1689
1787
|
testSuiteRequired: {
|
|
1690
1788
|
type: 'array',
|
|
1691
1789
|
items: { type: 'string' },
|
|
1692
1790
|
default: [],
|
|
1693
|
-
description: 'Required test suites that must pass'
|
|
1791
|
+
description: 'Required test suites that must pass',
|
|
1694
1792
|
},
|
|
1695
1793
|
maxRecentFailures: {
|
|
1696
1794
|
type: 'number',
|
|
1697
1795
|
default: 2,
|
|
1698
|
-
description: 'Maximum recent deployment failures allowed'
|
|
1796
|
+
description: 'Maximum recent deployment failures allowed',
|
|
1699
1797
|
},
|
|
1700
1798
|
deploymentSuccessThreshold: {
|
|
1701
1799
|
type: 'number',
|
|
1702
1800
|
default: 80,
|
|
1703
|
-
description: 'Minimum deployment success rate required (%)'
|
|
1801
|
+
description: 'Minimum deployment success rate required (%)',
|
|
1704
1802
|
},
|
|
1705
1803
|
blockOnRecentFailures: {
|
|
1706
1804
|
type: 'boolean',
|
|
1707
1805
|
default: true,
|
|
1708
|
-
description: 'Block if recent deployments failed'
|
|
1806
|
+
description: 'Block if recent deployments failed',
|
|
1709
1807
|
},
|
|
1710
1808
|
rollbackFrequencyThreshold: {
|
|
1711
1809
|
type: 'number',
|
|
1712
1810
|
default: 20,
|
|
1713
|
-
description: 'Maximum rollback frequency allowed (%)'
|
|
1811
|
+
description: 'Maximum rollback frequency allowed (%)',
|
|
1714
1812
|
},
|
|
1715
1813
|
requireAdrCompliance: {
|
|
1716
1814
|
type: 'boolean',
|
|
1717
1815
|
default: true,
|
|
1718
|
-
description: 'Require ADR compliance validation'
|
|
1816
|
+
description: 'Require ADR compliance validation',
|
|
1719
1817
|
},
|
|
1720
1818
|
integrateTodoTasks: {
|
|
1721
1819
|
type: 'boolean',
|
|
1722
1820
|
default: true,
|
|
1723
|
-
description: 'Auto-create blocking tasks for issues'
|
|
1821
|
+
description: 'Auto-create blocking tasks for issues',
|
|
1724
1822
|
},
|
|
1725
1823
|
updateHealthScoring: {
|
|
1726
1824
|
type: 'boolean',
|
|
1727
1825
|
default: true,
|
|
1728
|
-
description: 'Update project health scores'
|
|
1826
|
+
description: 'Update project health scores',
|
|
1729
1827
|
},
|
|
1730
1828
|
triggerSmartGitPush: {
|
|
1731
1829
|
type: 'boolean',
|
|
1732
1830
|
default: false,
|
|
1733
|
-
description: 'Trigger smart git push validation'
|
|
1831
|
+
description: 'Trigger smart git push validation',
|
|
1734
1832
|
},
|
|
1735
1833
|
emergencyBypass: {
|
|
1736
1834
|
type: 'boolean',
|
|
1737
1835
|
default: false,
|
|
1738
|
-
description: 'Emergency bypass for critical fixes'
|
|
1836
|
+
description: 'Emergency bypass for critical fixes',
|
|
1739
1837
|
},
|
|
1740
1838
|
businessJustification: {
|
|
1741
1839
|
type: 'string',
|
|
1742
|
-
description: 'Business justification for overrides (required for emergency_override)'
|
|
1840
|
+
description: 'Business justification for overrides (required for emergency_override)',
|
|
1743
1841
|
},
|
|
1744
1842
|
approvalRequired: {
|
|
1745
1843
|
type: 'boolean',
|
|
1746
1844
|
default: true,
|
|
1747
|
-
description: 'Require approval for overrides'
|
|
1748
|
-
}
|
|
1845
|
+
description: 'Require approval for overrides',
|
|
1846
|
+
},
|
|
1847
|
+
enableMemoryIntegration: {
|
|
1848
|
+
type: 'boolean',
|
|
1849
|
+
description: 'Enable memory entity storage for deployment assessment tracking and historical analysis',
|
|
1850
|
+
default: true,
|
|
1851
|
+
},
|
|
1852
|
+
migrateExistingHistory: {
|
|
1853
|
+
type: 'boolean',
|
|
1854
|
+
description: 'Migrate existing JSON-based deployment history to memory entities',
|
|
1855
|
+
default: true,
|
|
1856
|
+
},
|
|
1749
1857
|
},
|
|
1750
|
-
required: ['operation']
|
|
1751
|
-
}
|
|
1858
|
+
required: ['operation'],
|
|
1859
|
+
},
|
|
1752
1860
|
},
|
|
1753
1861
|
{
|
|
1754
1862
|
name: 'troubleshoot_guided_workflow',
|
|
1755
|
-
description: 'Structured failure analysis and test plan generation - provide JSON failure info to get specific test commands',
|
|
1863
|
+
description: 'Structured failure analysis and test plan generation with memory integration for troubleshooting session tracking and intelligent ADR/research suggestion capabilities - provide JSON failure info to get specific test commands',
|
|
1756
1864
|
inputSchema: {
|
|
1757
1865
|
type: 'object',
|
|
1758
1866
|
properties: {
|
|
1759
1867
|
operation: {
|
|
1760
1868
|
type: 'string',
|
|
1761
1869
|
enum: ['analyze_failure', 'generate_test_plan', 'full_workflow'],
|
|
1762
|
-
description: 'Type of troubleshooting operation'
|
|
1870
|
+
description: 'Type of troubleshooting operation',
|
|
1763
1871
|
},
|
|
1764
1872
|
failure: {
|
|
1765
1873
|
type: 'object',
|
|
1766
1874
|
properties: {
|
|
1767
1875
|
failureType: {
|
|
1768
1876
|
type: 'string',
|
|
1769
|
-
enum: [
|
|
1770
|
-
|
|
1877
|
+
enum: [
|
|
1878
|
+
'test_failure',
|
|
1879
|
+
'deployment_failure',
|
|
1880
|
+
'build_failure',
|
|
1881
|
+
'runtime_error',
|
|
1882
|
+
'performance_issue',
|
|
1883
|
+
'security_issue',
|
|
1884
|
+
'other',
|
|
1885
|
+
],
|
|
1886
|
+
description: 'Type of failure',
|
|
1771
1887
|
},
|
|
1772
1888
|
failureDetails: {
|
|
1773
1889
|
type: 'object',
|
|
1774
1890
|
properties: {
|
|
1775
1891
|
command: {
|
|
1776
1892
|
type: 'string',
|
|
1777
|
-
description: 'Command that failed (optional)'
|
|
1893
|
+
description: 'Command that failed (optional)',
|
|
1778
1894
|
},
|
|
1779
1895
|
exitCode: {
|
|
1780
1896
|
type: 'number',
|
|
1781
|
-
description: 'Exit code of failed process (optional)'
|
|
1897
|
+
description: 'Exit code of failed process (optional)',
|
|
1782
1898
|
},
|
|
1783
1899
|
errorMessage: {
|
|
1784
1900
|
type: 'string',
|
|
1785
|
-
description: 'Primary error message'
|
|
1901
|
+
description: 'Primary error message',
|
|
1786
1902
|
},
|
|
1787
1903
|
stackTrace: {
|
|
1788
1904
|
type: 'string',
|
|
1789
|
-
description: 'Stack trace if available (optional)'
|
|
1905
|
+
description: 'Stack trace if available (optional)',
|
|
1790
1906
|
},
|
|
1791
1907
|
logOutput: {
|
|
1792
1908
|
type: 'string',
|
|
1793
|
-
description: 'Relevant log output (optional)'
|
|
1909
|
+
description: 'Relevant log output (optional)',
|
|
1794
1910
|
},
|
|
1795
1911
|
environment: {
|
|
1796
1912
|
type: 'string',
|
|
1797
|
-
description: 'Environment where failure occurred (optional)'
|
|
1913
|
+
description: 'Environment where failure occurred (optional)',
|
|
1798
1914
|
},
|
|
1799
1915
|
timestamp: {
|
|
1800
1916
|
type: 'string',
|
|
1801
|
-
description: 'When the failure occurred (optional)'
|
|
1917
|
+
description: 'When the failure occurred (optional)',
|
|
1802
1918
|
},
|
|
1803
1919
|
affectedFiles: {
|
|
1804
1920
|
type: 'array',
|
|
1805
1921
|
items: { type: 'string' },
|
|
1806
|
-
description: 'Files involved in the failure (optional)'
|
|
1807
|
-
}
|
|
1922
|
+
description: 'Files involved in the failure (optional)',
|
|
1923
|
+
},
|
|
1808
1924
|
},
|
|
1809
1925
|
required: ['errorMessage'],
|
|
1810
|
-
description: 'Detailed failure information'
|
|
1926
|
+
description: 'Detailed failure information',
|
|
1811
1927
|
},
|
|
1812
1928
|
context: {
|
|
1813
1929
|
type: 'object',
|
|
1814
1930
|
properties: {
|
|
1815
1931
|
recentChanges: {
|
|
1816
1932
|
type: 'string',
|
|
1817
|
-
description: 'Recent changes that might be related (optional)'
|
|
1933
|
+
description: 'Recent changes that might be related (optional)',
|
|
1818
1934
|
},
|
|
1819
1935
|
reproducible: {
|
|
1820
1936
|
type: 'boolean',
|
|
1821
|
-
description: 'Whether the failure is reproducible (optional)'
|
|
1937
|
+
description: 'Whether the failure is reproducible (optional)',
|
|
1822
1938
|
},
|
|
1823
1939
|
frequency: {
|
|
1824
1940
|
type: 'string',
|
|
1825
|
-
description: 'How often this failure occurs (optional)'
|
|
1941
|
+
description: 'How often this failure occurs (optional)',
|
|
1826
1942
|
},
|
|
1827
1943
|
impact: {
|
|
1828
1944
|
type: 'string',
|
|
1829
1945
|
enum: ['low', 'medium', 'high', 'critical'],
|
|
1830
|
-
description: 'Impact level of the failure (optional)'
|
|
1831
|
-
}
|
|
1946
|
+
description: 'Impact level of the failure (optional)',
|
|
1947
|
+
},
|
|
1832
1948
|
},
|
|
1833
|
-
description: 'Additional context about the failure (optional)'
|
|
1834
|
-
}
|
|
1949
|
+
description: 'Additional context about the failure (optional)',
|
|
1950
|
+
},
|
|
1835
1951
|
},
|
|
1836
1952
|
required: ['failureType', 'failureDetails'],
|
|
1837
|
-
description: 'Structured failure information (required for analyze_failure and generate_test_plan)'
|
|
1953
|
+
description: 'Structured failure information (required for analyze_failure and generate_test_plan)',
|
|
1838
1954
|
},
|
|
1839
1955
|
projectPath: {
|
|
1840
1956
|
type: 'string',
|
|
1841
|
-
description: 'Path to project directory (optional)'
|
|
1957
|
+
description: 'Path to project directory (optional)',
|
|
1842
1958
|
},
|
|
1843
1959
|
adrDirectory: {
|
|
1844
1960
|
type: 'string',
|
|
1845
1961
|
description: 'ADR directory path',
|
|
1846
|
-
default: 'docs/adrs'
|
|
1962
|
+
default: 'docs/adrs',
|
|
1847
1963
|
},
|
|
1848
1964
|
todoPath: {
|
|
1849
1965
|
type: 'string',
|
|
1850
1966
|
description: 'Path to TODO.md file',
|
|
1851
|
-
default: 'TODO.md'
|
|
1967
|
+
default: 'TODO.md',
|
|
1852
1968
|
},
|
|
1853
|
-
|
|
1969
|
+
enableMemoryIntegration: {
|
|
1970
|
+
type: 'boolean',
|
|
1971
|
+
description: 'Enable memory entity storage for troubleshooting session tracking and pattern recognition',
|
|
1972
|
+
default: true,
|
|
1973
|
+
},
|
|
1974
|
+
enablePatternRecognition: {
|
|
1975
|
+
type: 'boolean',
|
|
1976
|
+
description: 'Enable automatic pattern recognition and failure classification',
|
|
1977
|
+
default: true,
|
|
1978
|
+
},
|
|
1979
|
+
enableAdrSuggestion: {
|
|
1980
|
+
type: 'boolean',
|
|
1981
|
+
description: 'Enable automatic ADR suggestion based on recurring failures',
|
|
1982
|
+
default: true,
|
|
1983
|
+
},
|
|
1984
|
+
enableResearchGeneration: {
|
|
1985
|
+
type: 'boolean',
|
|
1986
|
+
description: 'Enable automatic research question generation for persistent problems',
|
|
1987
|
+
default: true,
|
|
1988
|
+
},
|
|
1989
|
+
conversationContext: CONVERSATION_CONTEXT_SCHEMA,
|
|
1854
1990
|
},
|
|
1855
|
-
required: ['operation']
|
|
1856
|
-
}
|
|
1991
|
+
required: ['operation'],
|
|
1992
|
+
},
|
|
1857
1993
|
},
|
|
1858
1994
|
{
|
|
1859
1995
|
name: 'smart_score',
|
|
@@ -1863,70 +1999,91 @@ export class McpAdrAnalysisServer {
|
|
|
1863
1999
|
properties: {
|
|
1864
2000
|
operation: {
|
|
1865
2001
|
type: 'string',
|
|
1866
|
-
enum: [
|
|
1867
|
-
|
|
2002
|
+
enum: [
|
|
2003
|
+
'recalculate_scores',
|
|
2004
|
+
'sync_scores',
|
|
2005
|
+
'diagnose_scores',
|
|
2006
|
+
'optimize_weights',
|
|
2007
|
+
'reset_scores',
|
|
2008
|
+
'get_score_trends',
|
|
2009
|
+
'get_intent_scores',
|
|
2010
|
+
],
|
|
2011
|
+
description: 'Smart scoring operation to perform',
|
|
1868
2012
|
},
|
|
1869
2013
|
projectPath: {
|
|
1870
2014
|
type: 'string',
|
|
1871
|
-
description: 'Path to project directory'
|
|
2015
|
+
description: 'Path to project directory',
|
|
1872
2016
|
},
|
|
1873
2017
|
components: {
|
|
1874
2018
|
type: 'array',
|
|
1875
2019
|
items: {
|
|
1876
2020
|
type: 'string',
|
|
1877
|
-
enum: [
|
|
2021
|
+
enum: [
|
|
2022
|
+
'task_completion',
|
|
2023
|
+
'deployment_readiness',
|
|
2024
|
+
'architecture_compliance',
|
|
2025
|
+
'security_posture',
|
|
2026
|
+
'code_quality',
|
|
2027
|
+
'all',
|
|
2028
|
+
],
|
|
1878
2029
|
},
|
|
1879
2030
|
default: ['all'],
|
|
1880
|
-
description: 'Score components to recalculate (for recalculate_scores operation)'
|
|
2031
|
+
description: 'Score components to recalculate (for recalculate_scores operation)',
|
|
1881
2032
|
},
|
|
1882
2033
|
forceUpdate: {
|
|
1883
2034
|
type: 'boolean',
|
|
1884
2035
|
default: false,
|
|
1885
|
-
description: 'Force update even if data is fresh'
|
|
2036
|
+
description: 'Force update even if data is fresh',
|
|
1886
2037
|
},
|
|
1887
2038
|
updateSources: {
|
|
1888
2039
|
type: 'boolean',
|
|
1889
2040
|
default: true,
|
|
1890
|
-
description: 'Trigger source tool updates before recalculating'
|
|
2041
|
+
description: 'Trigger source tool updates before recalculating',
|
|
1891
2042
|
},
|
|
1892
2043
|
todoPath: {
|
|
1893
2044
|
type: 'string',
|
|
1894
2045
|
default: 'TODO.md',
|
|
1895
|
-
description: 'Path to TODO.md file (for sync_scores operation)'
|
|
2046
|
+
description: 'Path to TODO.md file (for sync_scores operation)',
|
|
1896
2047
|
},
|
|
1897
2048
|
triggerTools: {
|
|
1898
2049
|
type: 'array',
|
|
1899
2050
|
items: {
|
|
1900
2051
|
type: 'string',
|
|
1901
|
-
enum: [
|
|
2052
|
+
enum: [
|
|
2053
|
+
'manage_todo_json',
|
|
2054
|
+
'smart_git_push',
|
|
2055
|
+
'compare_adr_progress',
|
|
2056
|
+
'analyze_content_security',
|
|
2057
|
+
'validate_rules',
|
|
2058
|
+
],
|
|
1902
2059
|
},
|
|
1903
|
-
description: 'Tools to trigger for fresh data (for sync_scores operation)'
|
|
2060
|
+
description: 'Tools to trigger for fresh data (for sync_scores operation)',
|
|
1904
2061
|
},
|
|
1905
2062
|
rebalanceWeights: {
|
|
1906
2063
|
type: 'boolean',
|
|
1907
2064
|
default: false,
|
|
1908
|
-
description: 'Recalculate optimal scoring weights (for sync_scores operation)'
|
|
2065
|
+
description: 'Recalculate optimal scoring weights (for sync_scores operation)',
|
|
1909
2066
|
},
|
|
1910
2067
|
includeHistory: {
|
|
1911
2068
|
type: 'boolean',
|
|
1912
2069
|
default: true,
|
|
1913
|
-
description: 'Include score history analysis (for diagnose_scores operation)'
|
|
2070
|
+
description: 'Include score history analysis (for diagnose_scores operation)',
|
|
1914
2071
|
},
|
|
1915
2072
|
checkDataFreshness: {
|
|
1916
2073
|
type: 'boolean',
|
|
1917
2074
|
default: true,
|
|
1918
|
-
description: 'Validate data freshness across tools (for diagnose_scores operation)'
|
|
2075
|
+
description: 'Validate data freshness across tools (for diagnose_scores operation)',
|
|
1919
2076
|
},
|
|
1920
2077
|
suggestImprovements: {
|
|
1921
2078
|
type: 'boolean',
|
|
1922
2079
|
default: true,
|
|
1923
|
-
description: 'Provide score improvement suggestions (for diagnose_scores operation)'
|
|
2080
|
+
description: 'Provide score improvement suggestions (for diagnose_scores operation)',
|
|
1924
2081
|
},
|
|
1925
2082
|
analysisMode: {
|
|
1926
2083
|
type: 'string',
|
|
1927
2084
|
enum: ['current_state', 'historical_data', 'project_type'],
|
|
1928
2085
|
default: 'current_state',
|
|
1929
|
-
description: 'Method for weight optimization (for optimize_weights operation)'
|
|
2086
|
+
description: 'Method for weight optimization (for optimize_weights operation)',
|
|
1930
2087
|
},
|
|
1931
2088
|
customWeights: {
|
|
1932
2089
|
type: 'object',
|
|
@@ -1935,38 +2092,45 @@ export class McpAdrAnalysisServer {
|
|
|
1935
2092
|
deploymentReadiness: { type: 'number', minimum: 0, maximum: 1 },
|
|
1936
2093
|
architectureCompliance: { type: 'number', minimum: 0, maximum: 1 },
|
|
1937
2094
|
securityPosture: { type: 'number', minimum: 0, maximum: 1 },
|
|
1938
|
-
codeQuality: { type: 'number', minimum: 0, maximum: 1 }
|
|
2095
|
+
codeQuality: { type: 'number', minimum: 0, maximum: 1 },
|
|
1939
2096
|
},
|
|
1940
|
-
description: 'Custom weight overrides (for optimize_weights operation)'
|
|
2097
|
+
description: 'Custom weight overrides (for optimize_weights operation)',
|
|
1941
2098
|
},
|
|
1942
2099
|
previewOnly: {
|
|
1943
2100
|
type: 'boolean',
|
|
1944
2101
|
default: false,
|
|
1945
|
-
description: 'Preview changes without applying (for optimize_weights operation)'
|
|
2102
|
+
description: 'Preview changes without applying (for optimize_weights operation)',
|
|
1946
2103
|
},
|
|
1947
2104
|
component: {
|
|
1948
2105
|
type: 'string',
|
|
1949
|
-
enum: [
|
|
2106
|
+
enum: [
|
|
2107
|
+
'task_completion',
|
|
2108
|
+
'deployment_readiness',
|
|
2109
|
+
'architecture_compliance',
|
|
2110
|
+
'security_posture',
|
|
2111
|
+
'code_quality',
|
|
2112
|
+
'all',
|
|
2113
|
+
],
|
|
1950
2114
|
default: 'all',
|
|
1951
|
-
description: 'Score component to reset (for reset_scores operation)'
|
|
2115
|
+
description: 'Score component to reset (for reset_scores operation)',
|
|
1952
2116
|
},
|
|
1953
2117
|
preserveHistory: {
|
|
1954
2118
|
type: 'boolean',
|
|
1955
2119
|
default: true,
|
|
1956
|
-
description: 'Preserve score history in backup (for reset_scores operation)'
|
|
2120
|
+
description: 'Preserve score history in backup (for reset_scores operation)',
|
|
1957
2121
|
},
|
|
1958
2122
|
recalculateAfterReset: {
|
|
1959
2123
|
type: 'boolean',
|
|
1960
2124
|
default: true,
|
|
1961
|
-
description: 'Immediately recalculate after reset (for reset_scores operation)'
|
|
2125
|
+
description: 'Immediately recalculate after reset (for reset_scores operation)',
|
|
1962
2126
|
},
|
|
1963
2127
|
intentId: {
|
|
1964
2128
|
type: 'string',
|
|
1965
|
-
description: 'Intent ID to get score trends for (for get_intent_scores operation)'
|
|
1966
|
-
}
|
|
2129
|
+
description: 'Intent ID to get score trends for (for get_intent_scores operation)',
|
|
2130
|
+
},
|
|
1967
2131
|
},
|
|
1968
|
-
required: ['operation', 'projectPath']
|
|
1969
|
-
}
|
|
2132
|
+
required: ['operation', 'projectPath'],
|
|
2133
|
+
},
|
|
1970
2134
|
},
|
|
1971
2135
|
{
|
|
1972
2136
|
name: 'mcp_planning',
|
|
@@ -1976,20 +2140,27 @@ export class McpAdrAnalysisServer {
|
|
|
1976
2140
|
properties: {
|
|
1977
2141
|
operation: {
|
|
1978
2142
|
type: 'string',
|
|
1979
|
-
enum: [
|
|
1980
|
-
|
|
2143
|
+
enum: [
|
|
2144
|
+
'create_project',
|
|
2145
|
+
'manage_phases',
|
|
2146
|
+
'track_progress',
|
|
2147
|
+
'manage_resources',
|
|
2148
|
+
'risk_analysis',
|
|
2149
|
+
'generate_reports',
|
|
2150
|
+
],
|
|
2151
|
+
description: 'Project planning operation to perform',
|
|
1981
2152
|
},
|
|
1982
2153
|
projectPath: {
|
|
1983
2154
|
type: 'string',
|
|
1984
|
-
description: 'Project root path'
|
|
2155
|
+
description: 'Project root path',
|
|
1985
2156
|
},
|
|
1986
2157
|
projectName: {
|
|
1987
2158
|
type: 'string',
|
|
1988
|
-
description: 'Project name (for create_project operation)'
|
|
2159
|
+
description: 'Project name (for create_project operation)',
|
|
1989
2160
|
},
|
|
1990
2161
|
description: {
|
|
1991
2162
|
type: 'string',
|
|
1992
|
-
description: 'Project description (for create_project operation)'
|
|
2163
|
+
description: 'Project description (for create_project operation)',
|
|
1993
2164
|
},
|
|
1994
2165
|
phases: {
|
|
1995
2166
|
type: 'array',
|
|
@@ -2001,17 +2172,17 @@ export class McpAdrAnalysisServer {
|
|
|
2001
2172
|
dependencies: {
|
|
2002
2173
|
type: 'array',
|
|
2003
2174
|
items: { type: 'string' },
|
|
2004
|
-
default: []
|
|
2175
|
+
default: [],
|
|
2005
2176
|
},
|
|
2006
2177
|
milestones: {
|
|
2007
2178
|
type: 'array',
|
|
2008
2179
|
items: { type: 'string' },
|
|
2009
|
-
default: []
|
|
2010
|
-
}
|
|
2180
|
+
default: [],
|
|
2181
|
+
},
|
|
2011
2182
|
},
|
|
2012
|
-
required: ['name', 'duration']
|
|
2183
|
+
required: ['name', 'duration'],
|
|
2013
2184
|
},
|
|
2014
|
-
description: 'Initial project phases (for create_project operation)'
|
|
2185
|
+
description: 'Initial project phases (for create_project operation)',
|
|
2015
2186
|
},
|
|
2016
2187
|
team: {
|
|
2017
2188
|
type: 'array',
|
|
@@ -2023,33 +2194,43 @@ export class McpAdrAnalysisServer {
|
|
|
2023
2194
|
skills: {
|
|
2024
2195
|
type: 'array',
|
|
2025
2196
|
items: { type: 'string' },
|
|
2026
|
-
default: []
|
|
2197
|
+
default: [],
|
|
2027
2198
|
},
|
|
2028
|
-
capacity: { type: 'string' }
|
|
2199
|
+
capacity: { type: 'string' },
|
|
2029
2200
|
},
|
|
2030
|
-
required: ['name', 'role', 'capacity']
|
|
2201
|
+
required: ['name', 'role', 'capacity'],
|
|
2031
2202
|
},
|
|
2032
2203
|
default: [],
|
|
2033
|
-
description: 'Team structure (for create_project operation)'
|
|
2204
|
+
description: 'Team structure (for create_project operation)',
|
|
2034
2205
|
},
|
|
2035
2206
|
importFromAdrs: {
|
|
2036
2207
|
type: 'boolean',
|
|
2037
2208
|
default: true,
|
|
2038
|
-
description: 'Import phases from existing ADRs (for create_project operation)'
|
|
2209
|
+
description: 'Import phases from existing ADRs (for create_project operation)',
|
|
2039
2210
|
},
|
|
2040
2211
|
importFromTodos: {
|
|
2041
2212
|
type: 'boolean',
|
|
2042
2213
|
default: true,
|
|
2043
|
-
description: 'Import tasks from TODO system (for create_project operation)'
|
|
2214
|
+
description: 'Import tasks from TODO system (for create_project operation)',
|
|
2044
2215
|
},
|
|
2045
2216
|
action: {
|
|
2046
2217
|
type: 'string',
|
|
2047
|
-
enum: [
|
|
2048
|
-
|
|
2218
|
+
enum: [
|
|
2219
|
+
'list',
|
|
2220
|
+
'create',
|
|
2221
|
+
'update',
|
|
2222
|
+
'delete',
|
|
2223
|
+
'transition',
|
|
2224
|
+
'add',
|
|
2225
|
+
'remove',
|
|
2226
|
+
'allocate',
|
|
2227
|
+
'optimize',
|
|
2228
|
+
],
|
|
2229
|
+
description: 'Management action (for manage_phases/manage_resources operations)',
|
|
2049
2230
|
},
|
|
2050
2231
|
phaseId: {
|
|
2051
2232
|
type: 'string',
|
|
2052
|
-
description: 'Phase ID for phase operations'
|
|
2233
|
+
description: 'Phase ID for phase operations',
|
|
2053
2234
|
},
|
|
2054
2235
|
phaseData: {
|
|
2055
2236
|
type: 'object',
|
|
@@ -2059,49 +2240,69 @@ export class McpAdrAnalysisServer {
|
|
|
2059
2240
|
estimatedDuration: { type: 'string' },
|
|
2060
2241
|
dependencies: {
|
|
2061
2242
|
type: 'array',
|
|
2062
|
-
items: { type: 'string' }
|
|
2243
|
+
items: { type: 'string' },
|
|
2063
2244
|
},
|
|
2064
2245
|
milestones: {
|
|
2065
2246
|
type: 'array',
|
|
2066
|
-
items: { type: 'string' }
|
|
2247
|
+
items: { type: 'string' },
|
|
2067
2248
|
},
|
|
2068
2249
|
linkedAdrs: {
|
|
2069
2250
|
type: 'array',
|
|
2070
|
-
items: { type: 'string' }
|
|
2071
|
-
}
|
|
2251
|
+
items: { type: 'string' },
|
|
2252
|
+
},
|
|
2072
2253
|
},
|
|
2073
|
-
description: 'Phase data for create/update operations'
|
|
2254
|
+
description: 'Phase data for create/update operations',
|
|
2074
2255
|
},
|
|
2075
2256
|
targetStatus: {
|
|
2076
2257
|
type: 'string',
|
|
2077
2258
|
enum: ['planning', 'active', 'completed', 'blocked', 'cancelled'],
|
|
2078
|
-
description: 'Target status for phase transition'
|
|
2259
|
+
description: 'Target status for phase transition',
|
|
2079
2260
|
},
|
|
2080
2261
|
reportType: {
|
|
2081
2262
|
type: 'string',
|
|
2082
|
-
enum: [
|
|
2263
|
+
enum: [
|
|
2264
|
+
'summary',
|
|
2265
|
+
'detailed',
|
|
2266
|
+
'gantt',
|
|
2267
|
+
'milestones',
|
|
2268
|
+
'risks',
|
|
2269
|
+
'executive',
|
|
2270
|
+
'status',
|
|
2271
|
+
'health',
|
|
2272
|
+
'team_performance',
|
|
2273
|
+
'milestone_tracking',
|
|
2274
|
+
],
|
|
2083
2275
|
default: 'summary',
|
|
2084
|
-
description: 'Type of progress report or generated report'
|
|
2276
|
+
description: 'Type of progress report or generated report',
|
|
2085
2277
|
},
|
|
2086
2278
|
timeframe: {
|
|
2087
2279
|
type: 'string',
|
|
2088
|
-
enum: [
|
|
2280
|
+
enum: [
|
|
2281
|
+
'current',
|
|
2282
|
+
'weekly',
|
|
2283
|
+
'monthly',
|
|
2284
|
+
'quarterly',
|
|
2285
|
+
'week',
|
|
2286
|
+
'month',
|
|
2287
|
+
'quarter',
|
|
2288
|
+
'project',
|
|
2289
|
+
],
|
|
2089
2290
|
default: 'current',
|
|
2090
|
-
description: 'Time frame for reports and tracking'
|
|
2291
|
+
description: 'Time frame for reports and tracking',
|
|
2091
2292
|
},
|
|
2092
2293
|
includeVisuals: {
|
|
2093
2294
|
type: 'boolean',
|
|
2094
2295
|
default: true,
|
|
2095
|
-
description: 'Include visual progress indicators'
|
|
2296
|
+
description: 'Include visual progress indicators',
|
|
2096
2297
|
},
|
|
2097
2298
|
updateTaskProgress: {
|
|
2098
2299
|
type: 'boolean',
|
|
2099
2300
|
default: true,
|
|
2100
|
-
description: 'Sync progress from TODO system'
|
|
2301
|
+
description: 'Sync progress from TODO system',
|
|
2101
2302
|
},
|
|
2102
2303
|
memberId: {
|
|
2103
2304
|
type: 'string',
|
|
2104
|
-
description: 'Team member ID for resource operations'
|
|
2305
|
+
description: 'Team member ID for resource operations',
|
|
2105
2306
|
},
|
|
2106
2307
|
memberData: {
|
|
2107
2308
|
type: 'object',
|
|
@@ -2110,11 +2311,11 @@ export class McpAdrAnalysisServer {
|
|
|
2110
2311
|
role: { type: 'string' },
|
|
2111
2312
|
skills: {
|
|
2112
2313
|
type: 'array',
|
|
2113
|
-
items: { type: 'string' }
|
|
2314
|
+
items: { type: 'string' },
|
|
2114
2315
|
},
|
|
2115
|
-
capacity: { type: 'string' }
|
|
2316
|
+
capacity: { type: 'string' },
|
|
2116
2317
|
},
|
|
2117
|
-
description: 'Team member data for resource operations'
|
|
2318
|
+
description: 'Team member data for resource operations',
|
|
2118
2319
|
},
|
|
2119
2320
|
allocationData: {
|
|
2120
2321
|
type: 'object',
|
|
@@ -2123,52 +2324,52 @@ export class McpAdrAnalysisServer {
|
|
|
2123
2324
|
allocation: {
|
|
2124
2325
|
type: 'number',
|
|
2125
2326
|
minimum: 0,
|
|
2126
|
-
maximum: 100
|
|
2127
|
-
}
|
|
2327
|
+
maximum: 100,
|
|
2328
|
+
},
|
|
2128
2329
|
},
|
|
2129
2330
|
required: ['phaseId', 'allocation'],
|
|
2130
|
-
description: 'Resource allocation data'
|
|
2331
|
+
description: 'Resource allocation data',
|
|
2131
2332
|
},
|
|
2132
2333
|
analysisType: {
|
|
2133
2334
|
type: 'string',
|
|
2134
2335
|
enum: ['automated', 'manual', 'comprehensive'],
|
|
2135
2336
|
default: 'comprehensive',
|
|
2136
|
-
description: 'Type of risk analysis'
|
|
2337
|
+
description: 'Type of risk analysis',
|
|
2137
2338
|
},
|
|
2138
2339
|
includeAdrRisks: {
|
|
2139
2340
|
type: 'boolean',
|
|
2140
2341
|
default: true,
|
|
2141
|
-
description: 'Analyze risks from ADR complexity'
|
|
2342
|
+
description: 'Analyze risks from ADR complexity',
|
|
2142
2343
|
},
|
|
2143
2344
|
includeDependencyRisks: {
|
|
2144
2345
|
type: 'boolean',
|
|
2145
2346
|
default: true,
|
|
2146
|
-
description: 'Analyze dependency chain risks'
|
|
2347
|
+
description: 'Analyze dependency chain risks',
|
|
2147
2348
|
},
|
|
2148
2349
|
includeResourceRisks: {
|
|
2149
2350
|
type: 'boolean',
|
|
2150
2351
|
default: true,
|
|
2151
|
-
description: 'Analyze resource allocation risks'
|
|
2352
|
+
description: 'Analyze resource allocation risks',
|
|
2152
2353
|
},
|
|
2153
2354
|
generateMitigation: {
|
|
2154
2355
|
type: 'boolean',
|
|
2155
2356
|
default: true,
|
|
2156
|
-
description: 'Generate mitigation strategies'
|
|
2357
|
+
description: 'Generate mitigation strategies',
|
|
2157
2358
|
},
|
|
2158
2359
|
format: {
|
|
2159
2360
|
type: 'string',
|
|
2160
2361
|
enum: ['markdown', 'json', 'html'],
|
|
2161
2362
|
default: 'markdown',
|
|
2162
|
-
description: 'Report output format'
|
|
2363
|
+
description: 'Report output format',
|
|
2163
2364
|
},
|
|
2164
2365
|
includeCharts: {
|
|
2165
2366
|
type: 'boolean',
|
|
2166
2367
|
default: true,
|
|
2167
|
-
description: 'Include progress charts and graphs'
|
|
2168
|
-
}
|
|
2368
|
+
description: 'Include progress charts and graphs',
|
|
2369
|
+
},
|
|
2169
2370
|
},
|
|
2170
|
-
required: ['operation', 'projectPath']
|
|
2171
|
-
}
|
|
2371
|
+
required: ['operation', 'projectPath'],
|
|
2372
|
+
},
|
|
2172
2373
|
},
|
|
2173
2374
|
{
|
|
2174
2375
|
name: 'interactive_adr_planning',
|
|
@@ -2191,37 +2392,188 @@ export class McpAdrAnalysisServer {
|
|
|
2191
2392
|
'update_todos',
|
|
2192
2393
|
'get_guidance',
|
|
2193
2394
|
'save_session',
|
|
2194
|
-
'complete_session'
|
|
2395
|
+
'complete_session',
|
|
2195
2396
|
],
|
|
2196
|
-
description: 'Interactive planning operation to perform'
|
|
2397
|
+
description: 'Interactive planning operation to perform',
|
|
2197
2398
|
},
|
|
2198
2399
|
sessionId: {
|
|
2199
2400
|
type: 'string',
|
|
2200
|
-
description: 'Planning session ID (required for all operations except start_session)'
|
|
2401
|
+
description: 'Planning session ID (required for all operations except start_session)',
|
|
2201
2402
|
},
|
|
2202
2403
|
input: {
|
|
2203
2404
|
type: 'string',
|
|
2204
|
-
description: 'User input for the current phase (varies by phase)'
|
|
2405
|
+
description: 'User input for the current phase (varies by phase)',
|
|
2205
2406
|
},
|
|
2206
2407
|
projectPath: {
|
|
2207
2408
|
type: 'string',
|
|
2208
|
-
description: 'Project root path'
|
|
2409
|
+
description: 'Project root path',
|
|
2209
2410
|
},
|
|
2210
2411
|
autoResearch: {
|
|
2211
2412
|
type: 'boolean',
|
|
2212
2413
|
default: true,
|
|
2213
|
-
description: 'Automatically trigger research when needed'
|
|
2414
|
+
description: 'Automatically trigger research when needed',
|
|
2214
2415
|
},
|
|
2215
2416
|
generateTodos: {
|
|
2216
2417
|
type: 'boolean',
|
|
2217
2418
|
default: true,
|
|
2218
|
-
description: 'Automatically generate TODO items from decisions'
|
|
2219
|
-
}
|
|
2419
|
+
description: 'Automatically generate TODO items from decisions',
|
|
2420
|
+
},
|
|
2220
2421
|
},
|
|
2221
|
-
required: ['operation', 'projectPath']
|
|
2222
|
-
}
|
|
2223
|
-
}
|
|
2224
|
-
|
|
2422
|
+
required: ['operation', 'projectPath'],
|
|
2423
|
+
},
|
|
2424
|
+
},
|
|
2425
|
+
{
|
|
2426
|
+
name: 'memory_loading',
|
|
2427
|
+
description: 'Advanced memory loading tool for the memory-centric architecture. Query, explore, and manage memory entities and relationships. Load ADRs into memory system and perform intelligent queries.',
|
|
2428
|
+
inputSchema: {
|
|
2429
|
+
type: 'object',
|
|
2430
|
+
properties: {
|
|
2431
|
+
action: {
|
|
2432
|
+
type: 'string',
|
|
2433
|
+
enum: [
|
|
2434
|
+
'load_adrs',
|
|
2435
|
+
'query_entities',
|
|
2436
|
+
'get_entity',
|
|
2437
|
+
'find_related',
|
|
2438
|
+
'get_intelligence',
|
|
2439
|
+
'create_snapshot',
|
|
2440
|
+
],
|
|
2441
|
+
description: 'Memory operation to perform',
|
|
2442
|
+
default: 'query_entities',
|
|
2443
|
+
},
|
|
2444
|
+
query: {
|
|
2445
|
+
type: 'object',
|
|
2446
|
+
properties: {
|
|
2447
|
+
entityTypes: {
|
|
2448
|
+
type: 'array',
|
|
2449
|
+
items: {
|
|
2450
|
+
type: 'string',
|
|
2451
|
+
enum: [
|
|
2452
|
+
'architectural_decision',
|
|
2453
|
+
'code_component',
|
|
2454
|
+
'business_requirement',
|
|
2455
|
+
'technical_constraint',
|
|
2456
|
+
'quality_concern',
|
|
2457
|
+
'implementation_pattern',
|
|
2458
|
+
'environmental_factor',
|
|
2459
|
+
'stakeholder_input',
|
|
2460
|
+
'knowledge_artifact',
|
|
2461
|
+
'decision_context',
|
|
2462
|
+
],
|
|
2463
|
+
},
|
|
2464
|
+
description: 'Filter by entity types',
|
|
2465
|
+
},
|
|
2466
|
+
tags: {
|
|
2467
|
+
type: 'array',
|
|
2468
|
+
items: { type: 'string' },
|
|
2469
|
+
description: 'Filter by tags',
|
|
2470
|
+
},
|
|
2471
|
+
textQuery: {
|
|
2472
|
+
type: 'string',
|
|
2473
|
+
description: 'Full-text search query',
|
|
2474
|
+
},
|
|
2475
|
+
relationshipTypes: {
|
|
2476
|
+
type: 'array',
|
|
2477
|
+
items: {
|
|
2478
|
+
type: 'string',
|
|
2479
|
+
enum: [
|
|
2480
|
+
'depends_on',
|
|
2481
|
+
'influences',
|
|
2482
|
+
'conflicts_with',
|
|
2483
|
+
'implements',
|
|
2484
|
+
'supersedes',
|
|
2485
|
+
'relates_to',
|
|
2486
|
+
'originated_from',
|
|
2487
|
+
'impacts',
|
|
2488
|
+
'constrains',
|
|
2489
|
+
],
|
|
2490
|
+
},
|
|
2491
|
+
description: 'Filter by relationship types',
|
|
2492
|
+
},
|
|
2493
|
+
confidenceThreshold: {
|
|
2494
|
+
type: 'number',
|
|
2495
|
+
minimum: 0,
|
|
2496
|
+
maximum: 1,
|
|
2497
|
+
description: 'Minimum confidence threshold',
|
|
2498
|
+
},
|
|
2499
|
+
relevanceThreshold: {
|
|
2500
|
+
type: 'number',
|
|
2501
|
+
minimum: 0,
|
|
2502
|
+
maximum: 1,
|
|
2503
|
+
description: 'Minimum relevance threshold',
|
|
2504
|
+
},
|
|
2505
|
+
timeRange: {
|
|
2506
|
+
type: 'object',
|
|
2507
|
+
properties: {
|
|
2508
|
+
from: { type: 'string', description: 'Start date (ISO 8601)' },
|
|
2509
|
+
to: { type: 'string', description: 'End date (ISO 8601)' },
|
|
2510
|
+
},
|
|
2511
|
+
description: 'Filter by time range',
|
|
2512
|
+
},
|
|
2513
|
+
contextFilters: {
|
|
2514
|
+
type: 'object',
|
|
2515
|
+
properties: {
|
|
2516
|
+
projectPhase: { type: 'string', description: 'Project phase filter' },
|
|
2517
|
+
businessDomain: { type: 'string', description: 'Business domain filter' },
|
|
2518
|
+
technicalStack: {
|
|
2519
|
+
type: 'array',
|
|
2520
|
+
items: { type: 'string' },
|
|
2521
|
+
description: 'Technical stack filter',
|
|
2522
|
+
},
|
|
2523
|
+
environmentalFactors: {
|
|
2524
|
+
type: 'array',
|
|
2525
|
+
items: { type: 'string' },
|
|
2526
|
+
description: 'Environmental factors filter',
|
|
2527
|
+
},
|
|
2528
|
+
},
|
|
2529
|
+
description: 'Context-based filters',
|
|
2530
|
+
},
|
|
2531
|
+
limit: {
|
|
2532
|
+
type: 'number',
|
|
2533
|
+
minimum: 1,
|
|
2534
|
+
description: 'Maximum number of results',
|
|
2535
|
+
},
|
|
2536
|
+
sortBy: {
|
|
2537
|
+
type: 'string',
|
|
2538
|
+
enum: ['relevance', 'confidence', 'lastModified', 'created', 'accessCount'],
|
|
2539
|
+
description: 'Sort field',
|
|
2540
|
+
default: 'relevance',
|
|
2541
|
+
},
|
|
2542
|
+
includeRelated: {
|
|
2543
|
+
type: 'boolean',
|
|
2544
|
+
description: 'Include related entities and relationships',
|
|
2545
|
+
default: false,
|
|
2546
|
+
},
|
|
2547
|
+
relationshipDepth: {
|
|
2548
|
+
type: 'number',
|
|
2549
|
+
minimum: 1,
|
|
2550
|
+
maximum: 5,
|
|
2551
|
+
description: 'Maximum relationship traversal depth',
|
|
2552
|
+
default: 2,
|
|
2553
|
+
},
|
|
2554
|
+
},
|
|
2555
|
+
description: 'Query parameters for entity search',
|
|
2556
|
+
},
|
|
2557
|
+
entityId: {
|
|
2558
|
+
type: 'string',
|
|
2559
|
+
description: 'Entity ID for get_entity and find_related actions',
|
|
2560
|
+
},
|
|
2561
|
+
maxDepth: {
|
|
2562
|
+
type: 'number',
|
|
2563
|
+
minimum: 1,
|
|
2564
|
+
maximum: 5,
|
|
2565
|
+
description: 'Maximum depth for relationship traversal (find_related action)',
|
|
2566
|
+
default: 2,
|
|
2567
|
+
},
|
|
2568
|
+
forceReload: {
|
|
2569
|
+
type: 'boolean',
|
|
2570
|
+
description: 'Force reload of ADRs (load_adrs action)',
|
|
2571
|
+
default: false,
|
|
2572
|
+
},
|
|
2573
|
+
},
|
|
2574
|
+
},
|
|
2575
|
+
},
|
|
2576
|
+
],
|
|
2225
2577
|
};
|
|
2226
2578
|
});
|
|
2227
2579
|
// Tool execution handler
|
|
@@ -2341,6 +2693,9 @@ export class McpAdrAnalysisServer {
|
|
|
2341
2693
|
case 'mcp_planning':
|
|
2342
2694
|
response = await this.mcpPlanning(args);
|
|
2343
2695
|
break;
|
|
2696
|
+
case 'memory_loading':
|
|
2697
|
+
response = await this.memoryLoading(args);
|
|
2698
|
+
break;
|
|
2344
2699
|
case 'interactive_adr_planning':
|
|
2345
2700
|
response = await this.interactiveAdrPlanning(args);
|
|
2346
2701
|
break;
|
|
@@ -2369,21 +2724,21 @@ export class McpAdrAnalysisServer {
|
|
|
2369
2724
|
uri: 'adr://architectural_knowledge_graph',
|
|
2370
2725
|
name: 'Architectural Knowledge Graph',
|
|
2371
2726
|
description: 'Complete architectural knowledge graph of the project',
|
|
2372
|
-
mimeType: 'application/json'
|
|
2727
|
+
mimeType: 'application/json',
|
|
2373
2728
|
},
|
|
2374
2729
|
{
|
|
2375
2730
|
uri: 'adr://analysis_report',
|
|
2376
2731
|
name: 'Analysis Report',
|
|
2377
2732
|
description: 'Comprehensive project analysis report',
|
|
2378
|
-
mimeType: 'application/json'
|
|
2733
|
+
mimeType: 'application/json',
|
|
2379
2734
|
},
|
|
2380
2735
|
{
|
|
2381
2736
|
uri: 'adr://adr_list',
|
|
2382
2737
|
name: 'ADR List',
|
|
2383
2738
|
description: 'List of all Architectural Decision Records',
|
|
2384
|
-
mimeType: 'application/json'
|
|
2385
|
-
}
|
|
2386
|
-
]
|
|
2739
|
+
mimeType: 'application/json',
|
|
2740
|
+
},
|
|
2741
|
+
],
|
|
2387
2742
|
};
|
|
2388
2743
|
});
|
|
2389
2744
|
// Resource reading handler
|
|
@@ -2407,8 +2762,8 @@ export class McpAdrAnalysisServer {
|
|
|
2407
2762
|
prompts: allPrompts.map(prompt => ({
|
|
2408
2763
|
name: prompt.name,
|
|
2409
2764
|
description: prompt.description,
|
|
2410
|
-
arguments: prompt.arguments
|
|
2411
|
-
}))
|
|
2765
|
+
arguments: prompt.arguments,
|
|
2766
|
+
})),
|
|
2412
2767
|
};
|
|
2413
2768
|
});
|
|
2414
2769
|
// Prompt execution handler
|
|
@@ -2435,10 +2790,10 @@ export class McpAdrAnalysisServer {
|
|
|
2435
2790
|
role: 'user',
|
|
2436
2791
|
content: {
|
|
2437
2792
|
type: 'text',
|
|
2438
|
-
text: renderedTemplate
|
|
2439
|
-
}
|
|
2440
|
-
}
|
|
2441
|
-
]
|
|
2793
|
+
text: renderedTemplate,
|
|
2794
|
+
},
|
|
2795
|
+
},
|
|
2796
|
+
],
|
|
2442
2797
|
};
|
|
2443
2798
|
return await this.applyOutputMasking(response);
|
|
2444
2799
|
}
|
|
@@ -2469,11 +2824,13 @@ export class McpAdrAnalysisServer {
|
|
|
2469
2824
|
- **Execution Mode**: ${status.executionMode}
|
|
2470
2825
|
- **AI Model**: ${status.model}
|
|
2471
2826
|
|
|
2472
|
-
${status.reason
|
|
2827
|
+
${status.reason
|
|
2828
|
+
? `## ⚠️ Issue Detected
|
|
2473
2829
|
**Problem**: ${status.reason}
|
|
2474
2830
|
|
|
2475
2831
|
## Solution
|
|
2476
|
-
${!status.hasApiKey
|
|
2832
|
+
${!status.hasApiKey
|
|
2833
|
+
? `
|
|
2477
2834
|
1. Get an OpenRouter API key from https://openrouter.ai/keys
|
|
2478
2835
|
2. Add it to your MCP configuration:
|
|
2479
2836
|
\`\`\`json
|
|
@@ -2491,7 +2848,9 @@ ${!status.hasApiKey ? `
|
|
|
2491
2848
|
}
|
|
2492
2849
|
\`\`\`
|
|
2493
2850
|
3. Restart your MCP client (Claude Desktop, etc.)
|
|
2494
|
-
`
|
|
2851
|
+
`
|
|
2852
|
+
: status.executionMode !== 'full'
|
|
2853
|
+
? `
|
|
2495
2854
|
1. Update your MCP configuration to set EXECUTION_MODE to "full":
|
|
2496
2855
|
\`\`\`json
|
|
2497
2856
|
{
|
|
@@ -2505,7 +2864,9 @@ ${!status.hasApiKey ? `
|
|
|
2505
2864
|
}
|
|
2506
2865
|
\`\`\`
|
|
2507
2866
|
2. Restart your MCP client
|
|
2508
|
-
`
|
|
2867
|
+
`
|
|
2868
|
+
: ''}`
|
|
2869
|
+
: `## ✅ Configuration Looks Good!
|
|
2509
2870
|
|
|
2510
2871
|
AI execution is properly configured. Tools should return actual results instead of prompts.
|
|
2511
2872
|
|
|
@@ -2521,9 +2882,9 @@ If you're still seeing prompts instead of results, try:
|
|
|
2521
2882
|
|
|
2522
2883
|
## Testing
|
|
2523
2884
|
After fixing the configuration, try calling \`suggest_adrs\` - it should return actual ADR suggestions instead of prompts.
|
|
2524
|
-
|
|
2525
|
-
}
|
|
2526
|
-
]
|
|
2885
|
+
`,
|
|
2886
|
+
},
|
|
2887
|
+
],
|
|
2527
2888
|
};
|
|
2528
2889
|
}
|
|
2529
2890
|
catch (error) {
|
|
@@ -2542,14 +2903,14 @@ Verify these environment variables are set in your MCP configuration:
|
|
|
2542
2903
|
- OPENROUTER_API_KEY
|
|
2543
2904
|
- EXECUTION_MODE=full
|
|
2544
2905
|
- AI_MODEL (optional)
|
|
2545
|
-
|
|
2546
|
-
}
|
|
2547
|
-
]
|
|
2906
|
+
`,
|
|
2907
|
+
},
|
|
2908
|
+
],
|
|
2548
2909
|
};
|
|
2549
2910
|
}
|
|
2550
2911
|
}
|
|
2551
2912
|
async getWorkflowGuidance(args) {
|
|
2552
|
-
const { goal, projectContext, availableAssets = [], timeframe = 'thorough_review', primaryConcerns = [] } = args;
|
|
2913
|
+
const { goal, projectContext, availableAssets = [], timeframe = 'thorough_review', primaryConcerns = [], } = args;
|
|
2553
2914
|
try {
|
|
2554
2915
|
const workflowPrompt = `
|
|
2555
2916
|
# Workflow Guidance & Tool Recommendation System
|
|
@@ -2674,7 +3035,7 @@ Make the guidance **actionable, specific, and outcome-focused** so the user can
|
|
|
2674
3035
|
systemPrompt: `You are an expert workflow advisor for the MCP ADR Analysis Server.
|
|
2675
3036
|
Your role is to analyze user goals and project context, then recommend the optimal sequence of tools to achieve their objectives efficiently.
|
|
2676
3037
|
Provide specific, actionable guidance with clear tool sequences, expected outcomes, and success criteria.
|
|
2677
|
-
Focus on practical workflows that deliver measurable results
|
|
3038
|
+
Focus on practical workflows that deliver measurable results.`,
|
|
2678
3039
|
});
|
|
2679
3040
|
if (executionResult.isAIGenerated) {
|
|
2680
3041
|
// AI execution successful - return actual workflow guidance
|
|
@@ -2720,9 +3081,9 @@ This guidance is tailored to your specific context and goals for maximum effecti
|
|
|
2720
3081
|
content: [
|
|
2721
3082
|
{
|
|
2722
3083
|
type: 'text',
|
|
2723
|
-
text: workflowPrompt
|
|
2724
|
-
}
|
|
2725
|
-
]
|
|
3084
|
+
text: workflowPrompt,
|
|
3085
|
+
},
|
|
3086
|
+
],
|
|
2726
3087
|
};
|
|
2727
3088
|
}
|
|
2728
3089
|
}
|
|
@@ -2731,7 +3092,7 @@ This guidance is tailored to your specific context and goals for maximum effecti
|
|
|
2731
3092
|
}
|
|
2732
3093
|
}
|
|
2733
3094
|
async getDevelopmentGuidance(args) {
|
|
2734
|
-
const { developmentPhase, adrsToImplement = [], technologyStack = [], currentProgress = '', teamContext = { size: 'small_team', experienceLevel: 'mixed' }, timeline = '', focusAreas = [] } = args;
|
|
3095
|
+
const { developmentPhase, adrsToImplement = [], technologyStack = [], currentProgress = '', teamContext = { size: 'small_team', experienceLevel: 'mixed' }, timeline = '', focusAreas = [], } = args;
|
|
2735
3096
|
try {
|
|
2736
3097
|
// Use actual ADR discovery if ADRs are specified
|
|
2737
3098
|
let adrAnalysisPrompt = '';
|
|
@@ -2750,14 +3111,16 @@ This guidance is tailored to your specific context and goals for maximum effecti
|
|
|
2750
3111
|
**ADR Directory**: ${absoluteAdrPath}
|
|
2751
3112
|
**Found ${targetAdrs.length} matching ADRs**
|
|
2752
3113
|
|
|
2753
|
-
${targetAdrs
|
|
3114
|
+
${targetAdrs
|
|
3115
|
+
.map(adr => `
|
|
2754
3116
|
### ${adr.title}
|
|
2755
3117
|
- **File**: ${adr.filename}
|
|
2756
3118
|
- **Status**: ${adr.status}
|
|
2757
3119
|
- **Context**: ${adr.context}
|
|
2758
3120
|
- **Decision**: ${adr.decision}
|
|
2759
3121
|
- **Consequences**: ${adr.consequences}
|
|
2760
|
-
`)
|
|
3122
|
+
`)
|
|
3123
|
+
.join('\n')}
|
|
2761
3124
|
`;
|
|
2762
3125
|
}
|
|
2763
3126
|
const developmentPrompt = `
|
|
@@ -2895,7 +3258,7 @@ Make the guidance **actionable, specific, and immediately implementable** so dev
|
|
|
2895
3258
|
Your role is to bridge the gap between architectural planning and actual code development.
|
|
2896
3259
|
Provide specific, actionable development guidance with clear implementation steps, code patterns, and quality criteria.
|
|
2897
3260
|
Focus on practical guidance that ensures architectural decisions are properly implemented in code.
|
|
2898
|
-
Consider team context, technology stack, and development phase to provide tailored recommendations
|
|
3261
|
+
Consider team context, technology stack, and development phase to provide tailored recommendations.`,
|
|
2899
3262
|
});
|
|
2900
3263
|
if (executionResult.isAIGenerated) {
|
|
2901
3264
|
// AI execution successful - return actual development guidance
|
|
@@ -2953,9 +3316,9 @@ This guidance ensures your development work is **architecturally aligned**, **qu
|
|
|
2953
3316
|
content: [
|
|
2954
3317
|
{
|
|
2955
3318
|
type: 'text',
|
|
2956
|
-
text: developmentPrompt
|
|
2957
|
-
}
|
|
2958
|
-
]
|
|
3319
|
+
text: developmentPrompt,
|
|
3320
|
+
},
|
|
3321
|
+
],
|
|
2959
3322
|
};
|
|
2960
3323
|
}
|
|
2961
3324
|
}
|
|
@@ -2966,7 +3329,7 @@ This guidance ensures your development work is **architecturally aligned**, **qu
|
|
|
2966
3329
|
async analyzeProjectEcosystem(args) {
|
|
2967
3330
|
// Use configured project path if not provided in args
|
|
2968
3331
|
const projectPath = args.projectPath || this.config.projectPath;
|
|
2969
|
-
const { includePatterns, enhancedMode = true, knowledgeEnhancement = true, learningEnabled = true, technologyFocus = [], analysisDepth = 'comprehensive', includeEnvironment = true, recursiveDepth = 'comprehensive', analysisScope = []
|
|
3332
|
+
const { includePatterns, enhancedMode = true, knowledgeEnhancement = true, learningEnabled = true, technologyFocus = [], analysisDepth = 'comprehensive', includeEnvironment = true, recursiveDepth = 'comprehensive', analysisScope = [],
|
|
2970
3333
|
// conversationContext - TODO: implement context integration for ecosystem analysis
|
|
2971
3334
|
} = args;
|
|
2972
3335
|
this.logger.info(`Generating comprehensive ecosystem analysis for project at: ${projectPath}`);
|
|
@@ -3002,11 +3365,11 @@ This guidance ensures your development work is **architecturally aligned**, **qu
|
|
|
3002
3365
|
technologies: technologyFocus,
|
|
3003
3366
|
patterns: [],
|
|
3004
3367
|
projectType: 'ecosystem-analysis',
|
|
3005
|
-
existingAdrs: []
|
|
3368
|
+
existingAdrs: [],
|
|
3006
3369
|
}, {
|
|
3007
3370
|
domains: this.getEcosystemAnalysisDomains(technologyFocus),
|
|
3008
3371
|
depth: analysisDepth === 'basic' ? 'basic' : 'intermediate',
|
|
3009
|
-
cacheEnabled: true
|
|
3372
|
+
cacheEnabled: true,
|
|
3010
3373
|
});
|
|
3011
3374
|
knowledgeContext = `
|
|
3012
3375
|
## Technology-Specific Knowledge Enhancement
|
|
@@ -3055,7 +3418,7 @@ ${memoryResult.prompt}
|
|
|
3055
3418
|
const environmentResult = await analyzeEnvironment({
|
|
3056
3419
|
projectPath,
|
|
3057
3420
|
adrDirectory: this.config.adrDirectory,
|
|
3058
|
-
analysisType: 'comprehensive'
|
|
3421
|
+
analysisType: 'comprehensive',
|
|
3059
3422
|
});
|
|
3060
3423
|
// Extract environment analysis content
|
|
3061
3424
|
if (environmentResult.content && environmentResult.content[0]) {
|
|
@@ -3085,7 +3448,7 @@ ${environmentResult.content[0].text}
|
|
|
3085
3448
|
const reflexionConfig = createToolReflexionConfig('analyze_project_ecosystem', {
|
|
3086
3449
|
reflectionDepth: analysisDepth === 'basic' ? 'basic' : 'detailed',
|
|
3087
3450
|
evaluationCriteria: ['task-success', 'accuracy', 'completeness'],
|
|
3088
|
-
learningRate: 0.7
|
|
3451
|
+
learningRate: 0.7,
|
|
3089
3452
|
});
|
|
3090
3453
|
const reflexionResult = await executeWithReflexion({
|
|
3091
3454
|
prompt: baseProjectAnalysisPrompt.prompt + knowledgeContext + environmentAnalysisContext,
|
|
@@ -3099,18 +3462,20 @@ ${environmentResult.content[0].text}
|
|
|
3099
3462
|
includeEnvironment,
|
|
3100
3463
|
analysisScope,
|
|
3101
3464
|
knowledgeEnhanced: knowledgeEnhancement,
|
|
3102
|
-
learningEnabled: true
|
|
3103
|
-
}
|
|
3465
|
+
learningEnabled: true,
|
|
3466
|
+
},
|
|
3104
3467
|
}, reflexionConfig);
|
|
3105
3468
|
enhancedAnalysisPrompt = reflexionResult.prompt;
|
|
3106
3469
|
}
|
|
3107
3470
|
catch (error) {
|
|
3108
3471
|
this.logger.warn('Reflexion execution failed:', error);
|
|
3109
|
-
enhancedAnalysisPrompt =
|
|
3472
|
+
enhancedAnalysisPrompt =
|
|
3473
|
+
baseProjectAnalysisPrompt.prompt + knowledgeContext + environmentAnalysisContext;
|
|
3110
3474
|
}
|
|
3111
3475
|
}
|
|
3112
3476
|
else {
|
|
3113
|
-
enhancedAnalysisPrompt =
|
|
3477
|
+
enhancedAnalysisPrompt =
|
|
3478
|
+
baseProjectAnalysisPrompt.prompt + knowledgeContext + environmentAnalysisContext;
|
|
3114
3479
|
}
|
|
3115
3480
|
// Execute the analysis with AI if enabled, otherwise return prompt
|
|
3116
3481
|
const { executeEcosystemAnalysisPrompt, formatMCPResponse } = await import('./utils/prompt-execution.js');
|
|
@@ -3129,7 +3494,7 @@ ${environmentResult.content[0].text}
|
|
|
3129
3494
|
analysisScope,
|
|
3130
3495
|
includeEnvironment,
|
|
3131
3496
|
timestamp: new Date().toISOString(),
|
|
3132
|
-
structureData: baseProjectAnalysisPrompt.context || {}
|
|
3497
|
+
structureData: baseProjectAnalysisPrompt.context || {},
|
|
3133
3498
|
};
|
|
3134
3499
|
await this.kgManager.recordProjectStructure(projectStructureSnapshot);
|
|
3135
3500
|
this.logger.info('✅ Project structure recorded to knowledge graph');
|
|
@@ -3167,7 +3532,8 @@ ${reflexionContext}
|
|
|
3167
3532
|
|
|
3168
3533
|
${executionResult.content}
|
|
3169
3534
|
|
|
3170
|
-
${includeEnvironment
|
|
3535
|
+
${includeEnvironment
|
|
3536
|
+
? `
|
|
3171
3537
|
|
|
3172
3538
|
## Environment Integration Summary
|
|
3173
3539
|
|
|
@@ -3178,7 +3544,8 @@ The analysis above includes comprehensive environment analysis covering:
|
|
|
3178
3544
|
- **Compliance Assessment**: Security and regulatory compliance evaluation
|
|
3179
3545
|
|
|
3180
3546
|
This integrated approach provides complete understanding of both codebase patterns AND operational environment.
|
|
3181
|
-
`
|
|
3547
|
+
`
|
|
3548
|
+
: ''}
|
|
3182
3549
|
|
|
3183
3550
|
## Next Steps: Complete Ecosystem Understanding
|
|
3184
3551
|
|
|
@@ -3242,19 +3609,23 @@ ${baseProjectAnalysisPrompt.instructions}
|
|
|
3242
3609
|
|
|
3243
3610
|
### Enhancement-Specific Instructions
|
|
3244
3611
|
|
|
3245
|
-
${enhancedMode && knowledgeEnhancement
|
|
3612
|
+
${enhancedMode && knowledgeEnhancement
|
|
3613
|
+
? `
|
|
3246
3614
|
#### Knowledge Enhancement
|
|
3247
3615
|
- Apply technology-specific knowledge to ecosystem analysis
|
|
3248
3616
|
- Use domain expertise to identify patterns and anti-patterns
|
|
3249
3617
|
- Leverage architectural best practices for technology stack evaluation
|
|
3250
|
-
`
|
|
3618
|
+
`
|
|
3619
|
+
: ''}
|
|
3251
3620
|
|
|
3252
|
-
${enhancedMode && learningEnabled
|
|
3621
|
+
${enhancedMode && learningEnabled
|
|
3622
|
+
? `
|
|
3253
3623
|
#### Learning Integration
|
|
3254
3624
|
- Apply lessons learned from past ecosystem analyses
|
|
3255
3625
|
- Use memory insights to improve pattern recognition accuracy
|
|
3256
3626
|
- Incorporate feedback from previous analysis outcomes
|
|
3257
|
-
`
|
|
3627
|
+
`
|
|
3628
|
+
: ''}
|
|
3258
3629
|
|
|
3259
3630
|
## Expected Enhanced Output
|
|
3260
3631
|
|
|
@@ -3270,9 +3641,9 @@ The enhanced analysis should provide:
|
|
|
3270
3641
|
- Ensure analysis leverages all available enhancement features
|
|
3271
3642
|
- Verify technology-specific knowledge is properly applied
|
|
3272
3643
|
- Confirm learning insights improve analysis accuracy
|
|
3273
|
-
- Validate recommendations align with domain best practices
|
|
3274
|
-
}
|
|
3275
|
-
]
|
|
3644
|
+
- Validate recommendations align with domain best practices`,
|
|
3645
|
+
},
|
|
3646
|
+
],
|
|
3276
3647
|
};
|
|
3277
3648
|
}
|
|
3278
3649
|
}
|
|
@@ -3286,7 +3657,9 @@ The enhanced analysis should provide:
|
|
|
3286
3657
|
const { analyzeProjectStructure, fileExists, ensureDirectory } = await import('./utils/file-system.js');
|
|
3287
3658
|
const path = await import('path');
|
|
3288
3659
|
// Determine project path
|
|
3289
|
-
const projectPath = filePath
|
|
3660
|
+
const projectPath = filePath
|
|
3661
|
+
? filePath.split('/').slice(0, -1).join('/')
|
|
3662
|
+
: this.config.projectPath;
|
|
3290
3663
|
const adrDirectory = path.join(projectPath, this.config.adrDirectory);
|
|
3291
3664
|
// Generate prompts for ADR directory setup
|
|
3292
3665
|
const adrDirectoryCheckPrompt = await fileExists(adrDirectory);
|
|
@@ -3345,12 +3718,14 @@ ${filePath ? `- **File-specific Context**: How ${filePath} fits into the overall
|
|
|
3345
3718
|
- **Technology Rationale**: Understand selection criteria and trade-offs
|
|
3346
3719
|
- **Evolution Path**: How the architecture has changed over time
|
|
3347
3720
|
|
|
3348
|
-
${includeCompliance
|
|
3721
|
+
${includeCompliance
|
|
3722
|
+
? `### 5. Compliance & Standards Assessment
|
|
3349
3723
|
- **Industry Standards**: Adherence to relevant industry standards and best practices
|
|
3350
3724
|
- **Security Compliance**: Security standards compliance (OWASP, SOC2, etc.)
|
|
3351
3725
|
- **Code Standards**: Coding standards and style guide compliance
|
|
3352
3726
|
- **Architectural Compliance**: Adherence to established architectural principles
|
|
3353
|
-
- **Regulatory Requirements**: Any regulatory compliance requirements (GDPR, HIPAA, etc.)`
|
|
3727
|
+
- **Regulatory Requirements**: Any regulatory compliance requirements (GDPR, HIPAA, etc.)`
|
|
3728
|
+
: ''}
|
|
3354
3729
|
|
|
3355
3730
|
## Expected Output: Outcome-Focused Architectural Context
|
|
3356
3731
|
|
|
@@ -3451,7 +3826,7 @@ This approach ensures that architectural work is **grounded in measurable outcom
|
|
|
3451
3826
|
maxTokens: 5000,
|
|
3452
3827
|
systemPrompt: `You are a senior software architect specializing in architectural context analysis.
|
|
3453
3828
|
Analyze the provided project to understand its architectural patterns, design decisions, and structural organization.
|
|
3454
|
-
Focus on providing actionable insights about the architecture that can guide development decisions
|
|
3829
|
+
Focus on providing actionable insights about the architecture that can guide development decisions.`,
|
|
3455
3830
|
});
|
|
3456
3831
|
if (executionResult.isAIGenerated) {
|
|
3457
3832
|
// AI execution successful - return actual analysis results
|
|
@@ -3507,9 +3882,9 @@ This **outcome-focused approach** ensures architectural work delivers **measurab
|
|
|
3507
3882
|
content: [
|
|
3508
3883
|
{
|
|
3509
3884
|
type: 'text',
|
|
3510
|
-
text: architecturalPrompt
|
|
3511
|
-
}
|
|
3512
|
-
]
|
|
3885
|
+
text: architecturalPrompt,
|
|
3886
|
+
},
|
|
3887
|
+
],
|
|
3513
3888
|
};
|
|
3514
3889
|
}
|
|
3515
3890
|
}
|
|
@@ -3518,7 +3893,7 @@ This **outcome-focused approach** ensures architectural work delivers **measurab
|
|
|
3518
3893
|
}
|
|
3519
3894
|
}
|
|
3520
3895
|
async generateAdrsFromPrd(args) {
|
|
3521
|
-
const { prdPath, enhancedMode = true, promptOptimization = true, knowledgeEnhancement = true, prdType = 'general' } = args;
|
|
3896
|
+
const { prdPath, enhancedMode = true, promptOptimization = true, knowledgeEnhancement = true, prdType = 'general', } = args;
|
|
3522
3897
|
const outputDirectory = args.outputDirectory || this.config.adrDirectory;
|
|
3523
3898
|
this.logger.info(`Generating enhanced ADRs from PRD: ${prdPath} to ${outputDirectory}`);
|
|
3524
3899
|
this.logger.info(`Enhancement features - APE: ${promptOptimization}, Knowledge: ${knowledgeEnhancement}, Type: ${prdType}`);
|
|
@@ -3552,11 +3927,11 @@ This **outcome-focused approach** ensures architectural work delivers **measurab
|
|
|
3552
3927
|
technologies: [],
|
|
3553
3928
|
patterns: [],
|
|
3554
3929
|
projectType: prdType,
|
|
3555
|
-
existingAdrs: []
|
|
3930
|
+
existingAdrs: [],
|
|
3556
3931
|
}, {
|
|
3557
3932
|
domains: this.getPrdTypeDomains(prdType),
|
|
3558
3933
|
depth: 'intermediate',
|
|
3559
|
-
cacheEnabled: true
|
|
3934
|
+
cacheEnabled: true,
|
|
3560
3935
|
});
|
|
3561
3936
|
knowledgeContext = `
|
|
3562
3937
|
## Domain-Specific Knowledge Enhancement
|
|
@@ -3583,12 +3958,17 @@ ${knowledgeResult.prompt}
|
|
|
3583
3958
|
candidateCount: 5,
|
|
3584
3959
|
evaluationCriteria: ['task-completion', 'clarity', 'specificity'],
|
|
3585
3960
|
optimizationRounds: 2,
|
|
3586
|
-
qualityThreshold: 0.75
|
|
3961
|
+
qualityThreshold: 0.75,
|
|
3587
3962
|
});
|
|
3588
3963
|
const apeResult = await optimizePromptWithAPE({
|
|
3589
3964
|
prompt: baseAdrPrompt,
|
|
3590
3965
|
instructions: 'Generate comprehensive ADRs from PRD analysis',
|
|
3591
|
-
context: {
|
|
3966
|
+
context: {
|
|
3967
|
+
prdPath,
|
|
3968
|
+
outputDirectory,
|
|
3969
|
+
prdType,
|
|
3970
|
+
knowledgeEnhanced: knowledgeEnhancement,
|
|
3971
|
+
},
|
|
3592
3972
|
}, apeConfig);
|
|
3593
3973
|
finalAdrPrompt = apeResult.prompt;
|
|
3594
3974
|
}
|
|
@@ -3621,12 +4001,14 @@ ${fileContentPrompt.prompt}
|
|
|
3621
4001
|
|
|
3622
4002
|
## Step 3: Enhanced ADR Generation
|
|
3623
4003
|
|
|
3624
|
-
${enhancedMode && promptOptimization
|
|
4004
|
+
${enhancedMode && promptOptimization
|
|
4005
|
+
? `
|
|
3625
4006
|
### APE-Optimized Analysis
|
|
3626
4007
|
This prompt has been optimized using Automatic Prompt Engineering for superior ADR generation quality.
|
|
3627
4008
|
The optimization focused on task completion, clarity, and specificity for PRD analysis.
|
|
3628
4009
|
|
|
3629
|
-
`
|
|
4010
|
+
`
|
|
4011
|
+
: ''}
|
|
3630
4012
|
|
|
3631
4013
|
${finalAdrPrompt}
|
|
3632
4014
|
|
|
@@ -3653,7 +4035,7 @@ For each generated ADR, create a file creation prompt using the following patter
|
|
|
3653
4035
|
maxTokens: 8000,
|
|
3654
4036
|
systemPrompt: `You are an expert software architect who creates comprehensive Architectural Decision Records (ADRs) from Product Requirements Documents (PRDs).
|
|
3655
4037
|
Generate well-structured ADRs that follow best practices and include all necessary sections.
|
|
3656
|
-
Focus on extracting architectural decisions from the PRD and creating actionable ADRs with clear reasoning
|
|
4038
|
+
Focus on extracting architectural decisions from the PRD and creating actionable ADRs with clear reasoning.`,
|
|
3657
4039
|
});
|
|
3658
4040
|
if (executionResult.isAIGenerated) {
|
|
3659
4041
|
// AI execution successful - return actual ADR generation results
|
|
@@ -3734,19 +4116,23 @@ ${adrPrompt}
|
|
|
3734
4116
|
|
|
3735
4117
|
## Advanced Features
|
|
3736
4118
|
|
|
3737
|
-
${enhancedMode && knowledgeEnhancement
|
|
4119
|
+
${enhancedMode && knowledgeEnhancement
|
|
4120
|
+
? `
|
|
3738
4121
|
### Knowledge Enhancement
|
|
3739
4122
|
- Domain-specific architectural knowledge has been generated
|
|
3740
4123
|
- PRD analysis is enhanced with ${prdType} domain expertise
|
|
3741
4124
|
- ADR decisions leverage domain best practices and patterns
|
|
3742
|
-
`
|
|
4125
|
+
`
|
|
4126
|
+
: ''}
|
|
3743
4127
|
|
|
3744
|
-
${enhancedMode && promptOptimization
|
|
4128
|
+
${enhancedMode && promptOptimization
|
|
4129
|
+
? `
|
|
3745
4130
|
### APE Optimization
|
|
3746
4131
|
- Prompts have been automatically optimized for quality
|
|
3747
4132
|
- Enhanced evaluation criteria ensure superior ADR generation
|
|
3748
4133
|
- Optimization focused on task completion, clarity, and specificity
|
|
3749
|
-
`
|
|
4134
|
+
`
|
|
4135
|
+
: ''}
|
|
3750
4136
|
|
|
3751
4137
|
## Security and Validation
|
|
3752
4138
|
|
|
@@ -3766,9 +4152,9 @@ ${enhancedMode && promptOptimization ? `
|
|
|
3766
4152
|
6. Create file creation prompts for each enhanced ADR
|
|
3767
4153
|
7. Confirm with user before writing files to: ${outputDirectory}
|
|
3768
4154
|
|
|
3769
|
-
The enhanced process maintains full traceability from PRD requirements to generated ADRs while providing superior quality through advanced prompting techniques and ensuring security and user control over file operations
|
|
3770
|
-
}
|
|
3771
|
-
]
|
|
4155
|
+
The enhanced process maintains full traceability from PRD requirements to generated ADRs while providing superior quality through advanced prompting techniques and ensuring security and user control over file operations.`,
|
|
4156
|
+
},
|
|
4157
|
+
],
|
|
3772
4158
|
};
|
|
3773
4159
|
}
|
|
3774
4160
|
}
|
|
@@ -3777,53 +4163,53 @@ The enhanced process maintains full traceability from PRD requirements to genera
|
|
|
3777
4163
|
}
|
|
3778
4164
|
}
|
|
3779
4165
|
async generateAdrTodo(args) {
|
|
3780
|
-
const { scope = 'all', phase = 'both', linkAdrs = true, includeRules = true, ruleSource = 'both', preserveExisting = true, forceSyncToMarkdown = false, intentId, createJsonBackup = true } = args;
|
|
4166
|
+
const { scope = 'all', phase = 'both', linkAdrs = true, includeRules = true, ruleSource = 'both', preserveExisting = true, forceSyncToMarkdown = false, intentId, createJsonBackup = true, } = args;
|
|
3781
4167
|
const { getAdrDirectoryPath } = await import('./utils/config.js');
|
|
3782
4168
|
const path = await import('path');
|
|
3783
4169
|
// Use absolute ADR path relative to project
|
|
3784
|
-
const absoluteAdrPath = args.adrDirectory
|
|
3785
|
-
path.resolve(this.config.projectPath, args.adrDirectory)
|
|
3786
|
-
getAdrDirectoryPath(this.config);
|
|
4170
|
+
const absoluteAdrPath = args.adrDirectory
|
|
4171
|
+
? path.resolve(this.config.projectPath, args.adrDirectory)
|
|
4172
|
+
: getAdrDirectoryPath(this.config);
|
|
3787
4173
|
// Keep relative path for display purposes
|
|
3788
4174
|
const adrDirectory = args.adrDirectory || this.config.adrDirectory;
|
|
3789
4175
|
this.logger.info(`Generating JSON-first TODO for ADRs in: ${absoluteAdrPath} (phase: ${phase})`);
|
|
3790
4176
|
try {
|
|
3791
4177
|
// Always use JSON-first TODO system
|
|
3792
4178
|
this.logger.info('Using JSON-first TODO system for ADR task generation');
|
|
3793
|
-
|
|
4179
|
+
// TODO management has been deprecated and moved to mcp-shrimp-task-manager
|
|
4180
|
+
this.logger.warn('⚠️ TODO management has been deprecated - use mcp-shrimp-task-manager instead');
|
|
3794
4181
|
// Optional: Create backup if requested and JSON exists
|
|
3795
4182
|
if (createJsonBackup) {
|
|
3796
4183
|
try {
|
|
3797
|
-
|
|
3798
|
-
operation: 'import_from_markdown',
|
|
3799
|
-
projectPath: this.config.projectPath,
|
|
3800
|
-
mergeStrategy: 'preserve_json',
|
|
3801
|
-
backupExisting: true
|
|
3802
|
-
});
|
|
3803
|
-
this.logger.info('Created backup of existing JSON TODO data');
|
|
4184
|
+
this.logger.info('Backup feature deprecated - use mcp-shrimp-task-manager for task management');
|
|
3804
4185
|
}
|
|
3805
4186
|
catch (error) {
|
|
3806
4187
|
// Continue if backup fails - might be first time setup
|
|
3807
4188
|
this.logger.debug('No existing JSON data to backup');
|
|
3808
4189
|
}
|
|
3809
4190
|
}
|
|
3810
|
-
// Import ADR tasks into JSON system
|
|
3811
|
-
const importResult =
|
|
3812
|
-
|
|
3813
|
-
|
|
3814
|
-
|
|
3815
|
-
|
|
3816
|
-
|
|
3817
|
-
|
|
3818
|
-
|
|
3819
|
-
|
|
3820
|
-
|
|
3821
|
-
|
|
3822
|
-
|
|
3823
|
-
|
|
3824
|
-
|
|
4191
|
+
// Import ADR tasks into JSON system has been deprecated
|
|
4192
|
+
const importResult = {
|
|
4193
|
+
content: [
|
|
4194
|
+
{
|
|
4195
|
+
type: 'text',
|
|
4196
|
+
text: `⚠️ **TODO Management Deprecated**
|
|
4197
|
+
|
|
4198
|
+
This feature has been moved to mcp-shrimp-task-manager.
|
|
4199
|
+
|
|
4200
|
+
**Replacement:** Use the external \`mcp-shrimp-task-manager\` for:
|
|
4201
|
+
- Task planning and breaking down from ADRs
|
|
4202
|
+
- Task tracking and status updates
|
|
4203
|
+
- Task dependencies and priorities
|
|
4204
|
+
- Task completion and verification
|
|
4205
|
+
|
|
4206
|
+
**Migration:** The system now uses memory-centric architecture where task management is handled by external MCP servers.`,
|
|
4207
|
+
},
|
|
4208
|
+
],
|
|
4209
|
+
};
|
|
3825
4210
|
return {
|
|
3826
|
-
content: [
|
|
4211
|
+
content: [
|
|
4212
|
+
{
|
|
3827
4213
|
type: 'text',
|
|
3828
4214
|
text: `# ✅ JSON-First TODO Generated from ADRs
|
|
3829
4215
|
|
|
@@ -3850,7 +4236,7 @@ The enhanced process maintains full traceability from PRD requirements to genera
|
|
|
3850
4236
|
✅ **Backup Protection**: Automatic data preservation during updates
|
|
3851
4237
|
✅ **No Manual Setup**: All cache files auto-generated, tests can immediately validate
|
|
3852
4238
|
|
|
3853
|
-
${importResult.content[0]
|
|
4239
|
+
${importResult.content?.[0]?.text || 'TODO management feature has been deprecated'}
|
|
3854
4240
|
|
|
3855
4241
|
## Available Operations (use manage_todo_v2 tool)
|
|
3856
4242
|
1. **View Tasks**: \`get_tasks\` operation with filtering and sorting
|
|
@@ -3870,8 +4256,9 @@ ${importResult.content[0].text}
|
|
|
3870
4256
|
- **Dependencies**: ADR relationships mapped to task dependencies
|
|
3871
4257
|
- **Validation**: Architectural rules integrated into task criteria
|
|
3872
4258
|
|
|
3873
|
-
*All TODO data is now managed in JSON format with automatic markdown sync
|
|
3874
|
-
}
|
|
4259
|
+
*All TODO data is now managed in JSON format with automatic markdown sync*`,
|
|
4260
|
+
},
|
|
4261
|
+
],
|
|
3875
4262
|
};
|
|
3876
4263
|
}
|
|
3877
4264
|
catch (error) {
|
|
@@ -3879,19 +4266,20 @@ ${importResult.content[0].text}
|
|
|
3879
4266
|
}
|
|
3880
4267
|
}
|
|
3881
4268
|
async compareAdrProgress(args) {
|
|
3882
|
-
const { todoPath = 'TODO.md', adrDirectory = this.config.adrDirectory, projectPath = this.config.projectPath, environment = 'auto-detect', environmentConfig = {}, validationType = 'full', includeFileChecks = true, includeRuleValidation = true, deepCodeAnalysis = true, functionalValidation = true, strictMode = true, environmentValidation = true } = args;
|
|
4269
|
+
const { todoPath = 'TODO.md', adrDirectory = this.config.adrDirectory, projectPath = this.config.projectPath, environment = 'auto-detect', environmentConfig = {}, validationType = 'full', includeFileChecks = true, includeRuleValidation = true, deepCodeAnalysis = true, functionalValidation = true, strictMode = true, environmentValidation = true, } = args;
|
|
3883
4270
|
const { getAdrDirectoryPath } = await import('./utils/config.js');
|
|
3884
4271
|
const path = await import('path');
|
|
3885
4272
|
// Resolve paths
|
|
3886
4273
|
const absoluteTodoPath = path.resolve(projectPath, todoPath);
|
|
3887
|
-
const absoluteAdrPath = adrDirectory
|
|
3888
|
-
path.resolve(projectPath, adrDirectory)
|
|
3889
|
-
getAdrDirectoryPath(this.config);
|
|
4274
|
+
const absoluteAdrPath = adrDirectory
|
|
4275
|
+
? path.resolve(projectPath, adrDirectory)
|
|
4276
|
+
: getAdrDirectoryPath(this.config);
|
|
3890
4277
|
this.logger.info(`Comparing ADR progress: TODO(${absoluteTodoPath}) vs ADRs(${absoluteAdrPath}) vs Environment(${projectPath}) [env: ${environment}]`);
|
|
3891
4278
|
// Environment validation and auto-detection
|
|
3892
4279
|
let detectedEnvironment = environment;
|
|
3893
4280
|
let finalEnvironmentConfig = { ...environmentConfig };
|
|
3894
|
-
if (environmentValidation &&
|
|
4281
|
+
if (environmentValidation &&
|
|
4282
|
+
(validationType === 'full' || validationType === 'environment-only')) {
|
|
3895
4283
|
try {
|
|
3896
4284
|
const envResult = await this.detectAndValidateEnvironment(projectPath, environment, environmentConfig);
|
|
3897
4285
|
detectedEnvironment = envResult.detectedEnvironment;
|
|
@@ -3922,7 +4310,7 @@ ${importResult.content[0].text}
|
|
|
3922
4310
|
const includeContent = deepCodeAnalysis || functionalValidation;
|
|
3923
4311
|
projectStructure = await scanProjectStructure(projectPath, {
|
|
3924
4312
|
readContent: includeContent,
|
|
3925
|
-
maxFileSize: includeContent ? 10000 : 0
|
|
4313
|
+
maxFileSize: includeContent ? 10000 : 0,
|
|
3926
4314
|
});
|
|
3927
4315
|
}
|
|
3928
4316
|
catch (error) {
|
|
@@ -3950,15 +4338,15 @@ ${importResult.content[0].text}
|
|
|
3950
4338
|
strictMode,
|
|
3951
4339
|
environment: detectedEnvironment,
|
|
3952
4340
|
environmentConfig: finalEnvironmentConfig,
|
|
3953
|
-
environmentValidation
|
|
4341
|
+
environmentValidation,
|
|
3954
4342
|
});
|
|
3955
4343
|
return {
|
|
3956
4344
|
content: [
|
|
3957
4345
|
{
|
|
3958
4346
|
type: 'text',
|
|
3959
|
-
text: analysis
|
|
3960
|
-
}
|
|
3961
|
-
]
|
|
4347
|
+
text: analysis,
|
|
4348
|
+
},
|
|
4349
|
+
],
|
|
3962
4350
|
};
|
|
3963
4351
|
}
|
|
3964
4352
|
catch (error) {
|
|
@@ -3984,7 +4372,7 @@ ${importResult.content[0].text}
|
|
|
3984
4372
|
'.env.test',
|
|
3985
4373
|
'package.json',
|
|
3986
4374
|
'docker-compose.yml',
|
|
3987
|
-
'Dockerfile'
|
|
4375
|
+
'Dockerfile',
|
|
3988
4376
|
];
|
|
3989
4377
|
const existingFiles = [];
|
|
3990
4378
|
for (const file of envFiles) {
|
|
@@ -4017,7 +4405,7 @@ ${importResult.content[0].text}
|
|
|
4017
4405
|
requiredFiles: ['package.json', 'README.md'],
|
|
4018
4406
|
requiredServices: ['monitoring', 'logging'],
|
|
4019
4407
|
performanceRequirements: { minUptime: 99.9 },
|
|
4020
|
-
...finalConfig
|
|
4408
|
+
...finalConfig,
|
|
4021
4409
|
};
|
|
4022
4410
|
break;
|
|
4023
4411
|
case 'staging':
|
|
@@ -4026,7 +4414,7 @@ ${importResult.content[0].text}
|
|
|
4026
4414
|
requiredFiles: ['package.json'],
|
|
4027
4415
|
requiredServices: ['testing', 'monitoring'],
|
|
4028
4416
|
performanceRequirements: { minUptime: 95 },
|
|
4029
|
-
...finalConfig
|
|
4417
|
+
...finalConfig,
|
|
4030
4418
|
};
|
|
4031
4419
|
break;
|
|
4032
4420
|
case 'testing':
|
|
@@ -4035,7 +4423,7 @@ ${importResult.content[0].text}
|
|
|
4035
4423
|
requiredFiles: ['package.json'],
|
|
4036
4424
|
requiredServices: ['testing'],
|
|
4037
4425
|
performanceRequirements: {},
|
|
4038
|
-
...finalConfig
|
|
4426
|
+
...finalConfig,
|
|
4039
4427
|
};
|
|
4040
4428
|
break;
|
|
4041
4429
|
default: // development
|
|
@@ -4044,7 +4432,7 @@ ${importResult.content[0].text}
|
|
|
4044
4432
|
requiredFiles: ['package.json'],
|
|
4045
4433
|
requiredServices: [],
|
|
4046
4434
|
performanceRequirements: {},
|
|
4047
|
-
...finalConfig
|
|
4435
|
+
...finalConfig,
|
|
4048
4436
|
};
|
|
4049
4437
|
}
|
|
4050
4438
|
}
|
|
@@ -4059,7 +4447,7 @@ ${importResult.content[0].text}
|
|
|
4059
4447
|
* Perform local ADR progress analysis without relying on AI execution
|
|
4060
4448
|
*/
|
|
4061
4449
|
async performLocalAdrProgressAnalysis(params) {
|
|
4062
|
-
const { todoContent, todoPath, discoveredAdrs, adrDirectory, projectStructure, projectPath, validationType, includeFileChecks, includeRuleValidation, deepCodeAnalysis, functionalValidation, strictMode, environment, environmentConfig, environmentValidation } = params;
|
|
4450
|
+
const { todoContent, todoPath, discoveredAdrs, adrDirectory, projectStructure, projectPath, validationType, includeFileChecks, includeRuleValidation, deepCodeAnalysis, functionalValidation, strictMode, environment, environmentConfig, environmentValidation, } = params;
|
|
4063
4451
|
const currentDate = new Date().toISOString().split('T')[0];
|
|
4064
4452
|
// Parse TODO content to extract tasks
|
|
4065
4453
|
const todoTasks = this.parseTodoTasks(todoContent);
|
|
@@ -4123,31 +4511,39 @@ ${importResult.content[0].text}
|
|
|
4123
4511
|
- **Required Services**: ${environmentConfig.requiredServices?.length || 0} services
|
|
4124
4512
|
|
|
4125
4513
|
## ADR Discovery Results
|
|
4126
|
-
${totalAdrs > 0
|
|
4127
|
-
`Found ${totalAdrs} ADRs:\n${discoveredAdrs
|
|
4128
|
-
|
|
4514
|
+
${totalAdrs > 0
|
|
4515
|
+
? `Found ${totalAdrs} ADRs:\n${discoveredAdrs
|
|
4516
|
+
.map((adr, i) => `${i + 1}. **${adr.title}** (${adr.status}) - ${adr.filename}`)
|
|
4517
|
+
.join('\n')}`
|
|
4518
|
+
: 'No ADRs found in the specified directory.'}
|
|
4129
4519
|
|
|
4130
4520
|
## TODO Task Analysis
|
|
4131
|
-
${totalTasks > 0
|
|
4132
|
-
`Found ${totalTasks} tasks:\n${todoTasks
|
|
4133
|
-
|
|
4521
|
+
${totalTasks > 0
|
|
4522
|
+
? `Found ${totalTasks} tasks:\n${todoTasks
|
|
4523
|
+
.map((task, i) => `${i + 1}. ${task.completed ? '✅' : '⏳'} ${task.title}`)
|
|
4524
|
+
.join('\n')}`
|
|
4525
|
+
: 'No tasks found in TODO.md file.'}
|
|
4134
4526
|
|
|
4135
4527
|
## Alignment Analysis
|
|
4136
4528
|
|
|
4137
4529
|
### ✅ Properly Aligned Tasks
|
|
4138
|
-
${adrTaskMapping.aligned.length > 0
|
|
4139
|
-
adrTaskMapping.aligned
|
|
4140
|
-
|
|
4530
|
+
${adrTaskMapping.aligned.length > 0
|
|
4531
|
+
? adrTaskMapping.aligned
|
|
4532
|
+
.map(task => `- ${task.title}: Corresponds to ADR requirements`)
|
|
4533
|
+
.join('\n')
|
|
4534
|
+
: '- No aligned tasks identified'}
|
|
4141
4535
|
|
|
4142
4536
|
### ⚠️ Misaligned Tasks
|
|
4143
|
-
${adrTaskMapping.misaligned.length > 0
|
|
4144
|
-
adrTaskMapping.misaligned
|
|
4145
|
-
|
|
4537
|
+
${adrTaskMapping.misaligned.length > 0
|
|
4538
|
+
? adrTaskMapping.misaligned
|
|
4539
|
+
.map(task => `- ${task.title}: May not fully align with ADR specifications`)
|
|
4540
|
+
.join('\n')
|
|
4541
|
+
: '- No misaligned tasks identified'}
|
|
4146
4542
|
|
|
4147
4543
|
### ❌ Missing Tasks
|
|
4148
|
-
${adrTaskMapping.missing.length > 0
|
|
4149
|
-
adrTaskMapping.missing.map(gap => `- ${gap}: Required by ADRs but not in TODO`).join('\n')
|
|
4150
|
-
'- No obvious missing tasks identified'}
|
|
4544
|
+
${adrTaskMapping.missing.length > 0
|
|
4545
|
+
? adrTaskMapping.missing.map(gap => `- ${gap}: Required by ADRs but not in TODO`).join('\n')
|
|
4546
|
+
: '- No obvious missing tasks identified'}
|
|
4151
4547
|
|
|
4152
4548
|
## Implementation Status
|
|
4153
4549
|
|
|
@@ -4160,19 +4556,22 @@ ${mockAnalysisResults || ''}
|
|
|
4160
4556
|
## Recommendations
|
|
4161
4557
|
|
|
4162
4558
|
### High Priority Actions
|
|
4163
|
-
${alignmentScore < 70
|
|
4164
|
-
'1. **Improve ADR-TODO Alignment**: Review TODO tasks against ADR requirements\n2. **Add Missing Tasks**: Identify and add tasks required by ADRs'
|
|
4165
|
-
'1. **Maintain Current Alignment**: Continue following ADR specifications'}
|
|
4166
|
-
${completedTasks < totalTasks * 0.5
|
|
4167
|
-
'\n3. **Accelerate Implementation**: Focus on completing pending tasks'
|
|
4168
|
-
|
|
4169
|
-
|
|
4559
|
+
${alignmentScore < 70
|
|
4560
|
+
? '1. **Improve ADR-TODO Alignment**: Review TODO tasks against ADR requirements\n2. **Add Missing Tasks**: Identify and add tasks required by ADRs'
|
|
4561
|
+
: '1. **Maintain Current Alignment**: Continue following ADR specifications'}
|
|
4562
|
+
${completedTasks < totalTasks * 0.5
|
|
4563
|
+
? '\n3. **Accelerate Implementation**: Focus on completing pending tasks'
|
|
4564
|
+
: ''}
|
|
4565
|
+
${environmentValidation && environment === 'production' && alignmentScore < 90
|
|
4566
|
+
? '\n4. **⚠️ Production Environment Warning**: Current alignment may not meet production requirements'
|
|
4567
|
+
: ''}
|
|
4170
4568
|
|
|
4171
4569
|
### Medium Priority Actions
|
|
4172
4570
|
1. **Review Implementation Quality**: ${strictMode ? 'Strict mode analysis above shows' : 'Consider enabling strict mode for'} detailed quality assessment
|
|
4173
4571
|
2. **Update Documentation**: Ensure TODO.md reflects current project state
|
|
4174
|
-
${environmentValidation
|
|
4175
|
-
`3. **Environment Compliance**: Ensure ${environment} environment requirements are met`
|
|
4572
|
+
${environmentValidation
|
|
4573
|
+
? `3. **Environment Compliance**: Ensure ${environment} environment requirements are met`
|
|
4574
|
+
: ''}
|
|
4176
4575
|
|
|
4177
4576
|
### Low Priority Actions
|
|
4178
4577
|
1. **Optimize Workflow**: Consider tools for automated ADR-TODO synchronization
|
|
@@ -4231,16 +4630,17 @@ To re-run this validation with strict mode:
|
|
|
4231
4630
|
const title = taskMatch[2];
|
|
4232
4631
|
tasks.push({
|
|
4233
4632
|
title: title.trim(),
|
|
4234
|
-
completed: checkbox.toLowerCase() === 'x'
|
|
4633
|
+
completed: checkbox.toLowerCase() === 'x',
|
|
4235
4634
|
});
|
|
4236
4635
|
}
|
|
4237
4636
|
// Also look for simple list items that might be tasks
|
|
4238
4637
|
else if (line.match(/^\s*[-*]\s+\w+/)) {
|
|
4239
4638
|
const title = line.replace(/^\s*[-*]\s+/, '').trim();
|
|
4240
|
-
if (title.length > 3) {
|
|
4639
|
+
if (title.length > 3) {
|
|
4640
|
+
// Avoid very short items
|
|
4241
4641
|
tasks.push({
|
|
4242
4642
|
title,
|
|
4243
|
-
completed: false
|
|
4643
|
+
completed: false,
|
|
4244
4644
|
});
|
|
4245
4645
|
}
|
|
4246
4646
|
}
|
|
@@ -4257,8 +4657,14 @@ To re-run this validation with strict mode:
|
|
|
4257
4657
|
// Simple keyword matching for alignment detection
|
|
4258
4658
|
const adrKeywords = adrs.flatMap(adr => [
|
|
4259
4659
|
adr.title.toLowerCase(),
|
|
4260
|
-
...(adr.decision || '')
|
|
4261
|
-
|
|
4660
|
+
...(adr.decision || '')
|
|
4661
|
+
.toLowerCase()
|
|
4662
|
+
.split(/\s+/)
|
|
4663
|
+
.filter((w) => w.length > 4),
|
|
4664
|
+
...(adr.context || '')
|
|
4665
|
+
.toLowerCase()
|
|
4666
|
+
.split(/\s+/)
|
|
4667
|
+
.filter((w) => w.length > 4),
|
|
4262
4668
|
]);
|
|
4263
4669
|
// Environment-specific keywords that should be prioritized
|
|
4264
4670
|
const envKeywords = [];
|
|
@@ -4289,7 +4695,15 @@ To re-run this validation with strict mode:
|
|
|
4289
4695
|
for (const adr of adrs) {
|
|
4290
4696
|
if (adr.status === 'accepted' && adr.decision) {
|
|
4291
4697
|
const decisionWords = adr.decision.toLowerCase().split(/\s+/);
|
|
4292
|
-
const implementationWords = [
|
|
4698
|
+
const implementationWords = [
|
|
4699
|
+
'implement',
|
|
4700
|
+
'create',
|
|
4701
|
+
'build',
|
|
4702
|
+
'develop',
|
|
4703
|
+
'add',
|
|
4704
|
+
'setup',
|
|
4705
|
+
'configure',
|
|
4706
|
+
];
|
|
4293
4707
|
if (implementationWords.some(word => decisionWords.includes(word))) {
|
|
4294
4708
|
const hasCorrespondingTask = tasks.some(task => task.title.toLowerCase().includes(adr.title.toLowerCase().split(' ')[0]));
|
|
4295
4709
|
if (!hasCorrespondingTask) {
|
|
@@ -4326,12 +4740,12 @@ To re-run this validation with strict mode:
|
|
|
4326
4740
|
if (!projectStructure)
|
|
4327
4741
|
return '- Project structure not available';
|
|
4328
4742
|
const allFiles = [
|
|
4329
|
-
...projectStructure.packageFiles || [],
|
|
4330
|
-
...projectStructure.configFiles || [],
|
|
4331
|
-
...projectStructure.buildFiles || [],
|
|
4332
|
-
...projectStructure.dockerFiles || [],
|
|
4333
|
-
...projectStructure.ciFiles || [],
|
|
4334
|
-
...projectStructure.scriptFiles || []
|
|
4743
|
+
...(projectStructure.packageFiles || []),
|
|
4744
|
+
...(projectStructure.configFiles || []),
|
|
4745
|
+
...(projectStructure.buildFiles || []),
|
|
4746
|
+
...(projectStructure.dockerFiles || []),
|
|
4747
|
+
...(projectStructure.ciFiles || []),
|
|
4748
|
+
...(projectStructure.scriptFiles || []),
|
|
4335
4749
|
];
|
|
4336
4750
|
let results = '### File Existence Validation\n';
|
|
4337
4751
|
let checkCount = 0;
|
|
@@ -4345,7 +4759,9 @@ To re-run this validation with strict mode:
|
|
|
4345
4759
|
results += `- ✅ **${task.title}**: Found related files (${mentionedFiles.map(f => f.filename).join(', ')})\n`;
|
|
4346
4760
|
checkCount++;
|
|
4347
4761
|
}
|
|
4348
|
-
else if (taskLower.includes('file') ||
|
|
4762
|
+
else if (taskLower.includes('file') ||
|
|
4763
|
+
taskLower.includes('create') ||
|
|
4764
|
+
taskLower.includes('implement')) {
|
|
4349
4765
|
results += `- ⚠️ **${task.title}**: No clearly related files found\n`;
|
|
4350
4766
|
checkCount++;
|
|
4351
4767
|
}
|
|
@@ -4363,8 +4779,8 @@ To re-run this validation with strict mode:
|
|
|
4363
4779
|
if (!projectStructure)
|
|
4364
4780
|
return '';
|
|
4365
4781
|
const codeFiles = [
|
|
4366
|
-
...projectStructure.buildFiles || [],
|
|
4367
|
-
...projectStructure.configFiles || []
|
|
4782
|
+
...(projectStructure.buildFiles || []),
|
|
4783
|
+
...(projectStructure.configFiles || []),
|
|
4368
4784
|
].filter(file => file.content && file.content !== '[Binary or unreadable file]');
|
|
4369
4785
|
if (codeFiles.length === 0)
|
|
4370
4786
|
return '';
|
|
@@ -4382,7 +4798,7 @@ To re-run this validation with strict mode:
|
|
|
4382
4798
|
/return\s+null;/gi,
|
|
4383
4799
|
/return\s+""/gi,
|
|
4384
4800
|
/return\s+\[\]/gi,
|
|
4385
|
-
/return\s+{}/gi
|
|
4801
|
+
/return\s+{}/gi,
|
|
4386
4802
|
];
|
|
4387
4803
|
const productionPatterns = [
|
|
4388
4804
|
/error\s+handling/gi,
|
|
@@ -4393,18 +4809,21 @@ To re-run this validation with strict mode:
|
|
|
4393
4809
|
/authorization/gi,
|
|
4394
4810
|
/database/gi,
|
|
4395
4811
|
/api/gi,
|
|
4396
|
-
/config/gi
|
|
4812
|
+
/config/gi,
|
|
4397
4813
|
];
|
|
4398
|
-
for (const file of codeFiles.slice(0, 10)) {
|
|
4814
|
+
for (const file of codeFiles.slice(0, 10)) {
|
|
4815
|
+
// Limit analysis to prevent overwhelming output
|
|
4399
4816
|
const content = file.content;
|
|
4400
4817
|
const fileMockCount = mockPatterns.reduce((count, pattern) => count + (content.match(pattern) || []).length, 0);
|
|
4401
4818
|
const fileProdCount = productionPatterns.reduce((count, pattern) => count + (content.match(pattern) || []).length, 0);
|
|
4402
4819
|
mockIndicators += fileMockCount;
|
|
4403
4820
|
productionIndicators += fileProdCount;
|
|
4404
4821
|
if (fileMockCount > 0 || fileProdCount > 2) {
|
|
4405
|
-
const status = fileMockCount > fileProdCount
|
|
4406
|
-
|
|
4407
|
-
|
|
4822
|
+
const status = fileMockCount > fileProdCount
|
|
4823
|
+
? '❌ **Mock/Stub**'
|
|
4824
|
+
: fileProdCount > fileMockCount * 2
|
|
4825
|
+
? '✅ **Production Ready**'
|
|
4826
|
+
: '⚠️ **Partial Implementation**';
|
|
4408
4827
|
results += `- ${status}: ${file.filename} `;
|
|
4409
4828
|
if (fileMockCount > 0) {
|
|
4410
4829
|
results += `(${fileMockCount} mock indicators) `;
|
|
@@ -4419,8 +4838,11 @@ To re-run this validation with strict mode:
|
|
|
4419
4838
|
results += `- **Mock Indicators Found**: ${mockIndicators} instances\n`;
|
|
4420
4839
|
results += `- **Production Indicators Found**: ${productionIndicators} instances\n`;
|
|
4421
4840
|
if (strictMode) {
|
|
4422
|
-
const qualityScore = productionIndicators > mockIndicators * 2
|
|
4423
|
-
|
|
4841
|
+
const qualityScore = productionIndicators > mockIndicators * 2
|
|
4842
|
+
? 'Good'
|
|
4843
|
+
: productionIndicators > mockIndicators
|
|
4844
|
+
? 'Fair'
|
|
4845
|
+
: 'Needs Improvement';
|
|
4424
4846
|
results += `- **Quality Assessment**: ${qualityScore}\n`;
|
|
4425
4847
|
if (mockIndicators > 0) {
|
|
4426
4848
|
results += `- **⚠️ Strict Mode Warning**: Found ${mockIndicators} potential mock/stub indicators\n`;
|
|
@@ -4438,12 +4860,12 @@ To re-run this validation with strict mode:
|
|
|
4438
4860
|
// Check required files
|
|
4439
4861
|
if (environmentConfig.requiredFiles) {
|
|
4440
4862
|
const allFiles = [
|
|
4441
|
-
...projectStructure.packageFiles || [],
|
|
4442
|
-
...projectStructure.configFiles || [],
|
|
4443
|
-
...projectStructure.buildFiles || [],
|
|
4444
|
-
...projectStructure.dockerFiles || [],
|
|
4445
|
-
...projectStructure.ciFiles || [],
|
|
4446
|
-
...projectStructure.scriptFiles || []
|
|
4863
|
+
...(projectStructure.packageFiles || []),
|
|
4864
|
+
...(projectStructure.configFiles || []),
|
|
4865
|
+
...(projectStructure.buildFiles || []),
|
|
4866
|
+
...(projectStructure.dockerFiles || []),
|
|
4867
|
+
...(projectStructure.ciFiles || []),
|
|
4868
|
+
...(projectStructure.scriptFiles || []),
|
|
4447
4869
|
];
|
|
4448
4870
|
const existingFiles = allFiles.map(f => f.filename);
|
|
4449
4871
|
const missingFiles = environmentConfig.requiredFiles.filter((file) => !existingFiles.includes(file));
|
|
@@ -4472,12 +4894,12 @@ To re-run this validation with strict mode:
|
|
|
4472
4894
|
if (environmentConfig.requiredFiles) {
|
|
4473
4895
|
results += `#### Required Files for ${environment} Environment\n`;
|
|
4474
4896
|
const allFiles = [
|
|
4475
|
-
...projectStructure.packageFiles || [],
|
|
4476
|
-
...projectStructure.configFiles || [],
|
|
4477
|
-
...projectStructure.buildFiles || [],
|
|
4478
|
-
...projectStructure.dockerFiles || [],
|
|
4479
|
-
...projectStructure.ciFiles || [],
|
|
4480
|
-
...projectStructure.scriptFiles || []
|
|
4897
|
+
...(projectStructure.packageFiles || []),
|
|
4898
|
+
...(projectStructure.configFiles || []),
|
|
4899
|
+
...(projectStructure.buildFiles || []),
|
|
4900
|
+
...(projectStructure.dockerFiles || []),
|
|
4901
|
+
...(projectStructure.ciFiles || []),
|
|
4902
|
+
...(projectStructure.scriptFiles || []),
|
|
4481
4903
|
];
|
|
4482
4904
|
const existingFiles = allFiles.map(f => f.filename);
|
|
4483
4905
|
for (const requiredFile of environmentConfig.requiredFiles) {
|
|
@@ -4495,11 +4917,13 @@ To re-run this validation with strict mode:
|
|
|
4495
4917
|
results += `\n#### ${environment} Environment Recommendations\n`;
|
|
4496
4918
|
switch (environment) {
|
|
4497
4919
|
case 'production':
|
|
4498
|
-
results +=
|
|
4920
|
+
results +=
|
|
4921
|
+
'- ⚠️ **Production Critical**: Ensure monitoring, logging, and backup strategies are implemented\n';
|
|
4499
4922
|
results += '- 🔒 **Security**: Implement comprehensive security measures\n';
|
|
4500
4923
|
results += '- 📊 **Performance**: Monitor and optimize for production workloads\n';
|
|
4501
4924
|
if (strictMode) {
|
|
4502
|
-
results +=
|
|
4925
|
+
results +=
|
|
4926
|
+
'- 🔍 **Strict Mode**: Enhanced validation enabled for production environment\n';
|
|
4503
4927
|
}
|
|
4504
4928
|
break;
|
|
4505
4929
|
case 'staging':
|
|
@@ -4519,8 +4943,8 @@ To re-run this validation with strict mode:
|
|
|
4519
4943
|
analyzeSecurityCompliance(projectStructure, securityLevel) {
|
|
4520
4944
|
let results = '';
|
|
4521
4945
|
const securityFiles = [
|
|
4522
|
-
...projectStructure.configFiles || [],
|
|
4523
|
-
...projectStructure.dockerFiles || []
|
|
4946
|
+
...(projectStructure.configFiles || []),
|
|
4947
|
+
...(projectStructure.dockerFiles || []),
|
|
4524
4948
|
].filter(file => file.filename.includes('security') ||
|
|
4525
4949
|
file.filename.includes('auth') ||
|
|
4526
4950
|
file.filename.includes('.env') ||
|
|
@@ -4592,9 +5016,9 @@ ${clearPrompt.instructions}
|
|
|
4592
5016
|
|
|
4593
5017
|
## Expected Result
|
|
4594
5018
|
|
|
4595
|
-
After successful execution, all cache entries will be removed while preserving the cache directory structure and metadata.json file
|
|
4596
|
-
}
|
|
4597
|
-
]
|
|
5019
|
+
After successful execution, all cache entries will be removed while preserving the cache directory structure and metadata.json file.`,
|
|
5020
|
+
},
|
|
5021
|
+
],
|
|
4598
5022
|
};
|
|
4599
5023
|
}
|
|
4600
5024
|
case 'stats': {
|
|
@@ -4635,9 +5059,9 @@ The AI agent will provide:
|
|
|
4635
5059
|
Use \`manage_cache\` tool with different actions:
|
|
4636
5060
|
- \`clear\`: Remove all cache entries
|
|
4637
5061
|
- \`cleanup\`: Remove expired entries only
|
|
4638
|
-
- \`invalidate\`: Remove specific cache entry
|
|
4639
|
-
}
|
|
4640
|
-
]
|
|
5062
|
+
- \`invalidate\`: Remove specific cache entry`,
|
|
5063
|
+
},
|
|
5064
|
+
],
|
|
4641
5065
|
};
|
|
4642
5066
|
}
|
|
4643
5067
|
case 'cleanup': {
|
|
@@ -4660,9 +5084,9 @@ ${cleanupPrompt.instructions}
|
|
|
4660
5084
|
|
|
4661
5085
|
## Expected Result
|
|
4662
5086
|
|
|
4663
|
-
The AI agent will remove expired cache entries and provide a count of cleaned files
|
|
4664
|
-
}
|
|
4665
|
-
]
|
|
5087
|
+
The AI agent will remove expired cache entries and provide a count of cleaned files.`,
|
|
5088
|
+
},
|
|
5089
|
+
],
|
|
4666
5090
|
};
|
|
4667
5091
|
}
|
|
4668
5092
|
case 'invalidate': {
|
|
@@ -4690,9 +5114,9 @@ ${invalidatePrompt.instructions}
|
|
|
4690
5114
|
|
|
4691
5115
|
**Cache Key**: ${key}
|
|
4692
5116
|
|
|
4693
|
-
The AI agent will safely remove the specified cache entry
|
|
4694
|
-
}
|
|
4695
|
-
]
|
|
5117
|
+
The AI agent will safely remove the specified cache entry.`,
|
|
5118
|
+
},
|
|
5119
|
+
],
|
|
4696
5120
|
};
|
|
4697
5121
|
}
|
|
4698
5122
|
default:
|
|
@@ -4734,9 +5158,9 @@ Use \`configure_output_masking\` tool with:
|
|
|
4734
5158
|
|
|
4735
5159
|
## Current Status
|
|
4736
5160
|
${this.maskingConfig.enabled ? '✅ Output masking is ACTIVE' : '⚠️ Output masking is DISABLED'}
|
|
4737
|
-
|
|
4738
|
-
}
|
|
4739
|
-
]
|
|
5161
|
+
`,
|
|
5162
|
+
},
|
|
5163
|
+
],
|
|
4740
5164
|
};
|
|
4741
5165
|
}
|
|
4742
5166
|
case 'set': {
|
|
@@ -4766,12 +5190,12 @@ ${this.maskingConfig.enabled ? '✅ Output masking is ACTIVE' : '⚠️ Output m
|
|
|
4766
5190
|
- **Strategy**: ${newConfig.strategy}
|
|
4767
5191
|
- **Custom Patterns**: ${newConfig.customPatterns?.length || 0} patterns
|
|
4768
5192
|
|
|
4769
|
-
${newConfig.enabled
|
|
4770
|
-
'🔒 All MCP tool and resource outputs will now be masked according to the new configuration.'
|
|
4771
|
-
'⚠️ Output masking is disabled. Sensitive information may be exposed in responses.'}
|
|
4772
|
-
|
|
4773
|
-
}
|
|
4774
|
-
]
|
|
5193
|
+
${newConfig.enabled
|
|
5194
|
+
? '🔒 All MCP tool and resource outputs will now be masked according to the new configuration.'
|
|
5195
|
+
: '⚠️ Output masking is disabled. Sensitive information may be exposed in responses.'}
|
|
5196
|
+
`,
|
|
5197
|
+
},
|
|
5198
|
+
],
|
|
4775
5199
|
};
|
|
4776
5200
|
}
|
|
4777
5201
|
case 'reset': {
|
|
@@ -4790,9 +5214,9 @@ ${newConfig.enabled ?
|
|
|
4790
5214
|
- **Skip Patterns**: ${this.maskingConfig.skipPatterns?.length || 0} patterns
|
|
4791
5215
|
|
|
4792
5216
|
🔒 Default masking is now active for all outputs.
|
|
4793
|
-
|
|
4794
|
-
}
|
|
4795
|
-
]
|
|
5217
|
+
`,
|
|
5218
|
+
},
|
|
5219
|
+
],
|
|
4796
5220
|
};
|
|
4797
5221
|
}
|
|
4798
5222
|
default:
|
|
@@ -4810,12 +5234,17 @@ ${newConfig.enabled ?
|
|
|
4810
5234
|
const domainMap = {
|
|
4811
5235
|
'web-application': ['api-design', 'frontend-architecture', 'database-design', 'security'],
|
|
4812
5236
|
'mobile-app': ['mobile-architecture', 'api-design', 'performance-optimization', 'security'],
|
|
4813
|
-
|
|
4814
|
-
'data-platform': [
|
|
5237
|
+
microservices: ['microservices', 'api-design', 'distributed-systems', 'database-design'],
|
|
5238
|
+
'data-platform': [
|
|
5239
|
+
'database-design',
|
|
5240
|
+
'data-architecture',
|
|
5241
|
+
'performance-optimization',
|
|
5242
|
+
'scalability',
|
|
5243
|
+
],
|
|
4815
5244
|
'api-service': ['api-design', 'microservices', 'security', 'performance-optimization'],
|
|
4816
|
-
|
|
5245
|
+
general: ['api-design', 'database-design', 'security'],
|
|
4817
5246
|
};
|
|
4818
|
-
return domainMap[prdType] || domainMap['general'] || ['api-design', 'database-design', 'security'];
|
|
5247
|
+
return (domainMap[prdType] || domainMap['general'] || ['api-design', 'database-design', 'security']);
|
|
4819
5248
|
}
|
|
4820
5249
|
/**
|
|
4821
5250
|
* Helper method to get domains for ecosystem analysis based on technology focus
|
|
@@ -4825,35 +5254,35 @@ ${newConfig.enabled ?
|
|
|
4825
5254
|
const baseDomains = ['api-design', 'database-design', 'security', 'performance-optimization'];
|
|
4826
5255
|
// Technology-specific domain mapping
|
|
4827
5256
|
const technologyDomainMap = {
|
|
4828
|
-
|
|
4829
|
-
|
|
4830
|
-
|
|
4831
|
-
|
|
4832
|
-
|
|
4833
|
-
|
|
4834
|
-
|
|
4835
|
-
|
|
4836
|
-
|
|
4837
|
-
|
|
4838
|
-
|
|
4839
|
-
|
|
4840
|
-
|
|
4841
|
-
|
|
4842
|
-
|
|
4843
|
-
|
|
4844
|
-
|
|
4845
|
-
|
|
4846
|
-
|
|
4847
|
-
|
|
4848
|
-
|
|
4849
|
-
|
|
4850
|
-
|
|
4851
|
-
|
|
4852
|
-
|
|
4853
|
-
|
|
4854
|
-
|
|
5257
|
+
react: ['frontend-architecture', 'web-applications'],
|
|
5258
|
+
vue: ['frontend-architecture', 'web-applications'],
|
|
5259
|
+
angular: ['frontend-architecture', 'web-applications'],
|
|
5260
|
+
node: ['api-design', 'microservices'],
|
|
5261
|
+
express: ['api-design', 'web-applications'],
|
|
5262
|
+
fastify: ['api-design', 'performance-optimization'],
|
|
5263
|
+
nestjs: ['api-design', 'microservices'],
|
|
5264
|
+
spring: ['api-design', 'microservices'],
|
|
5265
|
+
django: ['api-design', 'web-applications'],
|
|
5266
|
+
flask: ['api-design', 'web-applications'],
|
|
5267
|
+
rails: ['api-design', 'web-applications'],
|
|
5268
|
+
laravel: ['api-design', 'web-applications'],
|
|
5269
|
+
docker: ['containerization', 'microservices'],
|
|
5270
|
+
kubernetes: ['containerization', 'distributed-systems'],
|
|
5271
|
+
mongodb: ['database-design', 'data-architecture'],
|
|
5272
|
+
postgresql: ['database-design', 'data-architecture'],
|
|
5273
|
+
mysql: ['database-design', 'data-architecture'],
|
|
5274
|
+
redis: ['database-design', 'performance-optimization'],
|
|
5275
|
+
elasticsearch: ['database-design', 'data-architecture'],
|
|
5276
|
+
kafka: ['distributed-systems', 'data-architecture'],
|
|
5277
|
+
rabbitmq: ['distributed-systems', 'microservices'],
|
|
5278
|
+
aws: ['cloud-architecture', 'scalability'],
|
|
5279
|
+
azure: ['cloud-architecture', 'scalability'],
|
|
5280
|
+
gcp: ['cloud-architecture', 'scalability'],
|
|
5281
|
+
terraform: ['infrastructure-as-code', 'cloud-architecture'],
|
|
5282
|
+
ansible: ['infrastructure-as-code', 'automation'],
|
|
5283
|
+
jenkins: ['ci-cd', 'automation'],
|
|
4855
5284
|
'github-actions': ['ci-cd', 'automation'],
|
|
4856
|
-
'gitlab-ci': ['ci-cd', 'automation']
|
|
5285
|
+
'gitlab-ci': ['ci-cd', 'automation'],
|
|
4857
5286
|
};
|
|
4858
5287
|
// Collect domains based on technology focus
|
|
4859
5288
|
const technologyDomains = new Set();
|
|
@@ -5031,6 +5460,129 @@ Please provide:
|
|
|
5031
5460
|
/**
|
|
5032
5461
|
* Apply content masking to MCP response
|
|
5033
5462
|
*/
|
|
5463
|
+
/**
|
|
5464
|
+
* Track memory operations performed by tools
|
|
5465
|
+
*/
|
|
5466
|
+
async trackMemoryOperations(toolName, parameters, result, success) {
|
|
5467
|
+
try {
|
|
5468
|
+
// Check if memory integration was enabled and used
|
|
5469
|
+
if (parameters?.enableMemoryIntegration === false) {
|
|
5470
|
+
return; // Memory integration was explicitly disabled
|
|
5471
|
+
}
|
|
5472
|
+
// Extract memory operation information from result
|
|
5473
|
+
const memoryOps = this.extractMemoryOperations(toolName, parameters, result);
|
|
5474
|
+
if (memoryOps.length > 0) {
|
|
5475
|
+
// Store memory operation tracking in knowledge graph
|
|
5476
|
+
for (const op of memoryOps) {
|
|
5477
|
+
await this.kgManager.addMemoryExecution(toolName, op.action, op.entityType, success && op.success, op.details);
|
|
5478
|
+
}
|
|
5479
|
+
}
|
|
5480
|
+
}
|
|
5481
|
+
catch (error) {
|
|
5482
|
+
// Don't let memory tracking errors break execution
|
|
5483
|
+
console.error('[WARN] Memory operation tracking failed:', error);
|
|
5484
|
+
}
|
|
5485
|
+
}
|
|
5486
|
+
/**
|
|
5487
|
+
* Extract memory operation details from tool execution
|
|
5488
|
+
*/
|
|
5489
|
+
extractMemoryOperations(toolName, parameters, result) {
|
|
5490
|
+
const operations = [];
|
|
5491
|
+
// Define memory-enabled tools and their expected operations
|
|
5492
|
+
const memoryEnabledTools = {
|
|
5493
|
+
analyze_content_security: {
|
|
5494
|
+
entityType: 'security_pattern',
|
|
5495
|
+
actions: ['store_pattern', 'analyze_institutional_security', 'track_evolution'],
|
|
5496
|
+
},
|
|
5497
|
+
analyze_environment: {
|
|
5498
|
+
entityType: 'environment_snapshot',
|
|
5499
|
+
actions: ['store_snapshot', 'analyze_trends', 'compare_configurations'],
|
|
5500
|
+
},
|
|
5501
|
+
deployment_readiness: {
|
|
5502
|
+
entityType: 'deployment_assessment',
|
|
5503
|
+
actions: ['store_assessment', 'migrate_history', 'analyze_patterns'],
|
|
5504
|
+
},
|
|
5505
|
+
troubleshoot_guided_workflow: {
|
|
5506
|
+
entityType: 'troubleshooting_session',
|
|
5507
|
+
actions: ['store_session', 'pattern_recognition', 'suggest_adrs', 'generate_research'],
|
|
5508
|
+
},
|
|
5509
|
+
};
|
|
5510
|
+
// Check if this tool supports memory operations
|
|
5511
|
+
const toolConfig = memoryEnabledTools[toolName];
|
|
5512
|
+
if (!toolConfig) {
|
|
5513
|
+
return operations; // Tool doesn't support memory operations
|
|
5514
|
+
}
|
|
5515
|
+
// Extract memory operation details from result
|
|
5516
|
+
if (result?.memoryIntegration) {
|
|
5517
|
+
const memoryInfo = result.memoryIntegration;
|
|
5518
|
+
// Pattern entity storage operation
|
|
5519
|
+
if (memoryInfo.entityStored || memoryInfo.patternStored) {
|
|
5520
|
+
operations.push({
|
|
5521
|
+
action: 'entity_storage',
|
|
5522
|
+
entityType: toolConfig.entityType,
|
|
5523
|
+
success: memoryInfo.storageSuccess !== false,
|
|
5524
|
+
details: {
|
|
5525
|
+
entityId: memoryInfo.entityId || memoryInfo.patternId,
|
|
5526
|
+
entityCount: memoryInfo.entityCount || 1,
|
|
5527
|
+
storageMethod: memoryInfo.storageMethod || 'standard',
|
|
5528
|
+
},
|
|
5529
|
+
});
|
|
5530
|
+
}
|
|
5531
|
+
// Historical analysis operation
|
|
5532
|
+
if (memoryInfo.historicalAnalysis || memoryInfo.trendAnalysis) {
|
|
5533
|
+
operations.push({
|
|
5534
|
+
action: 'historical_analysis',
|
|
5535
|
+
entityType: toolConfig.entityType,
|
|
5536
|
+
success: memoryInfo.analysisSuccess !== false,
|
|
5537
|
+
details: {
|
|
5538
|
+
analysisType: memoryInfo.analysisType || 'trend_analysis',
|
|
5539
|
+
entitiesAnalyzed: memoryInfo.entitiesAnalyzed || 0,
|
|
5540
|
+
insights: memoryInfo.insights || [],
|
|
5541
|
+
},
|
|
5542
|
+
});
|
|
5543
|
+
}
|
|
5544
|
+
// Evolution tracking operation
|
|
5545
|
+
if (memoryInfo.evolutionTracking) {
|
|
5546
|
+
operations.push({
|
|
5547
|
+
action: 'evolution_tracking',
|
|
5548
|
+
entityType: toolConfig.entityType,
|
|
5549
|
+
success: memoryInfo.evolutionSuccess !== false,
|
|
5550
|
+
details: {
|
|
5551
|
+
improvements: memoryInfo.improvements || [],
|
|
5552
|
+
degradations: memoryInfo.degradations || [],
|
|
5553
|
+
recommendations: memoryInfo.recommendations || [],
|
|
5554
|
+
},
|
|
5555
|
+
});
|
|
5556
|
+
}
|
|
5557
|
+
// Migration operation (for deployment readiness)
|
|
5558
|
+
if (memoryInfo.migrationCompleted) {
|
|
5559
|
+
operations.push({
|
|
5560
|
+
action: 'data_migration',
|
|
5561
|
+
entityType: toolConfig.entityType,
|
|
5562
|
+
success: memoryInfo.migrationSuccess !== false,
|
|
5563
|
+
details: {
|
|
5564
|
+
migratedRecords: memoryInfo.migratedRecords || 0,
|
|
5565
|
+
migrationMethod: memoryInfo.migrationMethod || 'json_to_memory',
|
|
5566
|
+
},
|
|
5567
|
+
});
|
|
5568
|
+
}
|
|
5569
|
+
}
|
|
5570
|
+
// If no specific memory integration info, infer from parameters
|
|
5571
|
+
if (operations.length === 0 && parameters?.enableMemoryIntegration !== false) {
|
|
5572
|
+
// Default assumption: entity was stored
|
|
5573
|
+
operations.push({
|
|
5574
|
+
action: 'entity_storage',
|
|
5575
|
+
entityType: toolConfig.entityType,
|
|
5576
|
+
success: true, // Assume success if no explicit info
|
|
5577
|
+
details: {
|
|
5578
|
+
entityCount: 1,
|
|
5579
|
+
storageMethod: 'inferred',
|
|
5580
|
+
note: 'Memory operation inferred from tool execution',
|
|
5581
|
+
},
|
|
5582
|
+
});
|
|
5583
|
+
}
|
|
5584
|
+
return operations;
|
|
5585
|
+
}
|
|
5034
5586
|
/**
|
|
5035
5587
|
* Track tool execution in knowledge graph
|
|
5036
5588
|
*/
|
|
@@ -5076,6 +5628,8 @@ Please provide:
|
|
|
5076
5628
|
todoTasksModified.push(...result.metadata.taskIds);
|
|
5077
5629
|
}
|
|
5078
5630
|
}
|
|
5631
|
+
// Track memory operations if present
|
|
5632
|
+
await this.trackMemoryOperations(toolName, parameters, result, success);
|
|
5079
5633
|
// Store execution in knowledge graph
|
|
5080
5634
|
await this.kgManager.addToolExecution(intentId, toolName, parameters, result, success, todoTasksCreated, todoTasksModified, error);
|
|
5081
5635
|
// If execution completed successfully, update intent status
|
|
@@ -5127,9 +5681,9 @@ Please provide:
|
|
|
5127
5681
|
{
|
|
5128
5682
|
uri,
|
|
5129
5683
|
mimeType: result.contentType,
|
|
5130
|
-
text: JSON.stringify(result.data, null, 2)
|
|
5131
|
-
}
|
|
5132
|
-
]
|
|
5684
|
+
text: JSON.stringify(result.data, null, 2),
|
|
5685
|
+
},
|
|
5686
|
+
],
|
|
5133
5687
|
};
|
|
5134
5688
|
}
|
|
5135
5689
|
case 'analysis_report': {
|
|
@@ -5143,9 +5697,9 @@ Please provide:
|
|
|
5143
5697
|
{
|
|
5144
5698
|
uri,
|
|
5145
5699
|
mimeType: result.contentType,
|
|
5146
|
-
text: JSON.stringify(result.data, null, 2)
|
|
5147
|
-
}
|
|
5148
|
-
]
|
|
5700
|
+
text: JSON.stringify(result.data, null, 2),
|
|
5701
|
+
},
|
|
5702
|
+
],
|
|
5149
5703
|
};
|
|
5150
5704
|
}
|
|
5151
5705
|
case 'adr_list': {
|
|
@@ -5153,9 +5707,9 @@ Please provide:
|
|
|
5153
5707
|
const { getAdrDirectoryPath } = await import('./utils/config.js');
|
|
5154
5708
|
const path = await import('path');
|
|
5155
5709
|
// Use absolute ADR path relative to project
|
|
5156
|
-
const absoluteAdrPath = params['adrDirectory']
|
|
5157
|
-
path.resolve(this.config.projectPath, params['adrDirectory'])
|
|
5158
|
-
getAdrDirectoryPath(this.config);
|
|
5710
|
+
const absoluteAdrPath = params['adrDirectory']
|
|
5711
|
+
? path.resolve(this.config.projectPath, params['adrDirectory'])
|
|
5712
|
+
: getAdrDirectoryPath(this.config);
|
|
5159
5713
|
// Generate resource directly (caching is now handled through AI delegation)
|
|
5160
5714
|
const result = await generateAdrList(absoluteAdrPath, this.config.projectPath);
|
|
5161
5715
|
return {
|
|
@@ -5163,9 +5717,9 @@ Please provide:
|
|
|
5163
5717
|
{
|
|
5164
5718
|
uri,
|
|
5165
5719
|
mimeType: result.contentType,
|
|
5166
|
-
text: JSON.stringify(result.data, null, 2)
|
|
5167
|
-
}
|
|
5168
|
-
]
|
|
5720
|
+
text: JSON.stringify(result.data, null, 2),
|
|
5721
|
+
},
|
|
5722
|
+
],
|
|
5169
5723
|
};
|
|
5170
5724
|
}
|
|
5171
5725
|
default:
|
|
@@ -5212,9 +5766,9 @@ Please provide:
|
|
|
5212
5766
|
content: [
|
|
5213
5767
|
{
|
|
5214
5768
|
type: 'text',
|
|
5215
|
-
text: content
|
|
5216
|
-
}
|
|
5217
|
-
]
|
|
5769
|
+
text: content,
|
|
5770
|
+
},
|
|
5771
|
+
],
|
|
5218
5772
|
};
|
|
5219
5773
|
}
|
|
5220
5774
|
catch (error) {
|
|
@@ -5240,9 +5794,9 @@ Please provide:
|
|
|
5240
5794
|
content: [
|
|
5241
5795
|
{
|
|
5242
5796
|
type: 'text',
|
|
5243
|
-
text: `Successfully wrote to ${filePath}
|
|
5244
|
-
}
|
|
5245
|
-
]
|
|
5797
|
+
text: `Successfully wrote to ${filePath}`,
|
|
5798
|
+
},
|
|
5799
|
+
],
|
|
5246
5800
|
};
|
|
5247
5801
|
}
|
|
5248
5802
|
catch (error) {
|
|
@@ -5264,32 +5818,52 @@ Please provide:
|
|
|
5264
5818
|
const fileList = entries.map(entry => ({
|
|
5265
5819
|
name: entry.name,
|
|
5266
5820
|
type: entry.isDirectory() ? 'directory' : 'file',
|
|
5267
|
-
path: path.join(dirPath, entry.name)
|
|
5821
|
+
path: path.join(dirPath, entry.name),
|
|
5268
5822
|
}));
|
|
5269
5823
|
return {
|
|
5270
5824
|
content: [
|
|
5271
5825
|
{
|
|
5272
5826
|
type: 'text',
|
|
5273
|
-
text: JSON.stringify(fileList, null, 2)
|
|
5274
|
-
}
|
|
5275
|
-
]
|
|
5827
|
+
text: JSON.stringify(fileList, null, 2),
|
|
5828
|
+
},
|
|
5829
|
+
],
|
|
5276
5830
|
};
|
|
5277
5831
|
}
|
|
5278
5832
|
catch (error) {
|
|
5279
5833
|
throw new McpAdrError(`Failed to list directory: ${error instanceof Error ? error.message : String(error)}`, 'DIRECTORY_LIST_ERROR');
|
|
5280
5834
|
}
|
|
5281
5835
|
}
|
|
5282
|
-
async manageTodoJson(
|
|
5836
|
+
async manageTodoJson(_args) {
|
|
5283
5837
|
try {
|
|
5284
|
-
|
|
5285
|
-
|
|
5286
|
-
|
|
5287
|
-
|
|
5288
|
-
|
|
5838
|
+
// TODO management has been deprecated and moved to mcp-shrimp-task-manager
|
|
5839
|
+
this.logger.warn('⚠️ manageTodoJson deprecated - use mcp-shrimp-task-manager instead');
|
|
5840
|
+
return {
|
|
5841
|
+
content: [
|
|
5842
|
+
{
|
|
5843
|
+
type: 'text',
|
|
5844
|
+
text: `⚠️ **TODO Management Tool Deprecated**
|
|
5845
|
+
|
|
5846
|
+
This tool (manageTodoJson) has been deprecated and is no longer functional.
|
|
5847
|
+
|
|
5848
|
+
**Replacement:** Use the external \`mcp-shrimp-task-manager\` for task management:
|
|
5849
|
+
- Task planning and breaking down
|
|
5850
|
+
- Task tracking and status updates
|
|
5851
|
+
- Task dependencies and priorities
|
|
5852
|
+
- Task completion and verification
|
|
5853
|
+
|
|
5854
|
+
**Migration:** The system has moved to a memory-centric architecture where task management is handled by external MCP servers rather than internal JSON files.
|
|
5855
|
+
|
|
5856
|
+
**Error:** TodoJsonManager was removed - use mcp-shrimp-task-manager for task management`,
|
|
5857
|
+
},
|
|
5858
|
+
],
|
|
5859
|
+
isError: false,
|
|
5289
5860
|
};
|
|
5290
|
-
return await manageTodoV2(argsWithPath);
|
|
5291
5861
|
}
|
|
5292
5862
|
catch (error) {
|
|
5863
|
+
// If it's already a McpAdrError with good details, re-throw it as-is
|
|
5864
|
+
if (error instanceof Error && error.name === 'McpAdrError') {
|
|
5865
|
+
throw error;
|
|
5866
|
+
}
|
|
5293
5867
|
throw new McpAdrError(`JSON TODO management failed: ${error instanceof Error ? error.message : String(error)}`, 'TODO_JSON_MANAGEMENT_ERROR');
|
|
5294
5868
|
}
|
|
5295
5869
|
}
|
|
@@ -5329,14 +5903,28 @@ Please provide:
|
|
|
5329
5903
|
throw new McpAdrError(`Troubleshoot guided workflow failed: ${error instanceof Error ? error.message : String(error)}`, 'TROUBLESHOOT_GUIDED_WORKFLOW_ERROR');
|
|
5330
5904
|
}
|
|
5331
5905
|
}
|
|
5332
|
-
async smartScore(
|
|
5333
|
-
|
|
5334
|
-
|
|
5335
|
-
|
|
5336
|
-
|
|
5337
|
-
|
|
5338
|
-
|
|
5339
|
-
|
|
5906
|
+
async smartScore(_args) {
|
|
5907
|
+
// Smart score tool was removed - return deprecation message
|
|
5908
|
+
return {
|
|
5909
|
+
content: [
|
|
5910
|
+
{
|
|
5911
|
+
type: 'text',
|
|
5912
|
+
text: `⚠️ **Smart Score Tool Deprecated**
|
|
5913
|
+
|
|
5914
|
+
This tool has been deprecated and replaced with memory-centric health scoring.
|
|
5915
|
+
|
|
5916
|
+
**Replacement:** The new MemoryHealthScoring system tracks:
|
|
5917
|
+
- Memory quality and relevance
|
|
5918
|
+
- Retrieval performance
|
|
5919
|
+
- Entity relationship coherence
|
|
5920
|
+
- Context utilization
|
|
5921
|
+
- Decision alignment
|
|
5922
|
+
|
|
5923
|
+
**Migration:** Health scoring is now integrated into the knowledge graph and automatically calculated based on memory usage patterns.`,
|
|
5924
|
+
},
|
|
5925
|
+
],
|
|
5926
|
+
isError: false,
|
|
5927
|
+
};
|
|
5340
5928
|
}
|
|
5341
5929
|
async mcpPlanning(args) {
|
|
5342
5930
|
try {
|
|
@@ -5347,6 +5935,16 @@ Please provide:
|
|
|
5347
5935
|
throw new McpAdrError(`MCP planning failed: ${error instanceof Error ? error.message : String(error)}`, 'MCP_PLANNING_ERROR');
|
|
5348
5936
|
}
|
|
5349
5937
|
}
|
|
5938
|
+
async memoryLoading(args) {
|
|
5939
|
+
try {
|
|
5940
|
+
const { MemoryLoadingTool } = await import('./tools/memory-loading-tool.js');
|
|
5941
|
+
const memoryTool = new MemoryLoadingTool();
|
|
5942
|
+
return await memoryTool.execute(args);
|
|
5943
|
+
}
|
|
5944
|
+
catch (error) {
|
|
5945
|
+
throw new McpAdrError(`Memory loading failed: ${error instanceof Error ? error.message : String(error)}`, 'MEMORY_LOADING_ERROR');
|
|
5946
|
+
}
|
|
5947
|
+
}
|
|
5350
5948
|
async interactiveAdrPlanning(args) {
|
|
5351
5949
|
try {
|
|
5352
5950
|
const { interactiveAdrPlanning } = await import('./tools/interactive-adr-planning-tool.js');
|
|
@@ -5416,10 +6014,11 @@ Examples:
|
|
|
5416
6014
|
// Start the server if this file is run directly
|
|
5417
6015
|
// Jest-compatible check: avoid import.meta.url which Jest cannot handle
|
|
5418
6016
|
// Handle both direct execution and npm global package symlinks
|
|
5419
|
-
if (process.argv[1] &&
|
|
5420
|
-
process.argv[1].endsWith('index.
|
|
5421
|
-
|
|
5422
|
-
|
|
6017
|
+
if (process.argv[1] &&
|
|
6018
|
+
(process.argv[1].endsWith('index.js') ||
|
|
6019
|
+
process.argv[1].endsWith('index.ts') ||
|
|
6020
|
+
process.argv[1].endsWith('mcp-adr-analysis-server'))) {
|
|
6021
|
+
main().catch(error => {
|
|
5423
6022
|
console.error('Unhandled error:', error);
|
|
5424
6023
|
process.exit(1);
|
|
5425
6024
|
});
|