mcp-adr-analysis-server 2.14.0 → 2.14.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,342 +0,0 @@
1
- /**
2
- * Prompt Execution Utilities
3
- *
4
- * This module provides utilities for executing prompts with AI when enabled,
5
- * or falling back to returning prompts for external execution.
6
- *
7
- * @deprecated This module contains legacy OpenRouter execution functions.
8
- * As of Phase 4.4 CE-MCP migration, tools should return OrchestrationDirectives
9
- * instead of calling these execution functions. See ADR-014 for details.
10
- *
11
- * Migration guide:
12
- * - Replace executePromptWithFallback() with OrchestrationDirective returns
13
- * - Replace executeADRSuggestionPrompt() with directive-based ADR generation
14
- * - Replace formatMCPResponse() with direct directive returns
15
- *
16
- * These functions remain for backward compatibility during the hybrid transition period.
17
- */
18
- import { getAIExecutor } from './ai-executor.js';
19
- import { isAIExecutionEnabled, loadAIConfig } from '../config/ai-config.js';
20
- /**
21
- * Execute a prompt with AI if enabled, otherwise return formatted prompt
22
- *
23
- * @deprecated Use OrchestrationDirective returns instead. This function
24
- * will be removed in a future release. See ADR-014 CE-MCP Architecture.
25
- */
26
- export async function executePromptWithFallback(prompt, instructions, options = {}) {
27
- const config = loadAIConfig();
28
- const shouldUseAI = !options.forcePromptOnly && isAIExecutionEnabled(config);
29
- if (shouldUseAI) {
30
- try {
31
- const executor = getAIExecutor();
32
- if (options.responseFormat === 'json') {
33
- const execOptions = {};
34
- if (options.model !== undefined)
35
- execOptions.model = options.model;
36
- if (options.temperature !== undefined)
37
- execOptions.temperature = options.temperature;
38
- if (options.maxTokens !== undefined)
39
- execOptions.maxTokens = options.maxTokens;
40
- if (options.systemPrompt !== undefined)
41
- execOptions.systemPrompt = options.systemPrompt;
42
- // Apply defensive programming for executeStructuredPrompt
43
- if (executor && typeof executor.executeStructuredPrompt === 'function') {
44
- const result = await executor.executeStructuredPrompt(prompt, options.schema, execOptions);
45
- return {
46
- content: typeof result.data === 'string' ? result.data : JSON.stringify(result.data, null, 2),
47
- isAIGenerated: true,
48
- aiMetadata: result.raw.metadata,
49
- usage: result.raw.usage,
50
- model: result.raw.model,
51
- };
52
- }
53
- else {
54
- console.warn('⚠️ AI Executor executeStructuredPrompt not available, falling back to prompt-only mode');
55
- throw new Error('AI Executor not available');
56
- }
57
- }
58
- else {
59
- const execOptions = {};
60
- if (options.model !== undefined)
61
- execOptions.model = options.model;
62
- if (options.temperature !== undefined)
63
- execOptions.temperature = options.temperature;
64
- if (options.maxTokens !== undefined)
65
- execOptions.maxTokens = options.maxTokens;
66
- if (options.systemPrompt !== undefined)
67
- execOptions.systemPrompt = options.systemPrompt;
68
- // Apply defensive programming for executePrompt
69
- if (executor && typeof executor.executePrompt === 'function') {
70
- const result = await executor.executePrompt(prompt, execOptions);
71
- return {
72
- content: result.content,
73
- isAIGenerated: true,
74
- aiMetadata: result.metadata,
75
- usage: result.usage,
76
- model: result.model,
77
- };
78
- }
79
- else {
80
- console.warn('⚠️ AI Executor executePrompt not available, falling back to prompt-only mode');
81
- throw new Error('AI Executor not available');
82
- }
83
- }
84
- }
85
- catch (error) {
86
- console.error('AI execution failed, falling back to prompt-only mode:', error);
87
- // Fall through to prompt-only mode
88
- }
89
- }
90
- // Fallback to prompt-only mode
91
- const formattedPrompt = formatPromptForExternal(prompt, instructions);
92
- return {
93
- content: formattedPrompt,
94
- isAIGenerated: false,
95
- };
96
- }
97
- /**
98
- * Standard context placeholders used across tools
99
- */
100
- const STANDARD_CONTEXT_PLACEHOLDERS = [
101
- {
102
- placeholder: '{{userGoals}}',
103
- description: "User's primary objectives from the conversation",
104
- example: 'microservices migration for better scalability',
105
- },
106
- {
107
- placeholder: '{{focusAreas}}',
108
- description: 'Specific areas of concern or interest',
109
- example: 'security, performance, maintainability',
110
- },
111
- {
112
- placeholder: '{{constraints}}',
113
- description: 'Limitations, compliance requirements, or restrictions',
114
- example: 'GDPR compliance required, budget under $50k, minimal downtime',
115
- },
116
- {
117
- placeholder: '{{projectPhase}}',
118
- description: 'Current project phase or stage',
119
- example: 'planning, development, migration, production',
120
- },
121
- {
122
- placeholder: '{{userRole}}',
123
- description: "User's role or expertise level",
124
- example: 'senior architect, developer, project manager',
125
- },
126
- ];
127
- /**
128
- * Format a prompt for external execution with enhanced LLM instructions
129
- */
130
- function formatPromptForExternal(prompt, instructions, contextPlaceholders = STANDARD_CONTEXT_PLACEHOLDERS) {
131
- // Check if prompt contains context placeholders
132
- const hasPlaceholders = contextPlaceholders.some(cp => prompt.includes(cp.placeholder));
133
- const response = {
134
- executionMode: 'prompt-only',
135
- prompt: prompt,
136
- instructions: {
137
- howToUse: 'Execute this prompt within your current conversation context to preserve user goals and discussion history',
138
- contextIntegration: hasPlaceholders
139
- ? 'This prompt includes placeholders for conversation context. Replace them with relevant information from your discussion with the user before executing.'
140
- : "This prompt will work better if you provide context about the user's goals and constraints when executing it.",
141
- expectedOutput: instructions,
142
- bestPractices: [
143
- "Maintain the user's stated objectives when executing this prompt",
144
- 'Include any constraints or preferences mentioned in the conversation',
145
- "Consider the project phase and user's role when interpreting results",
146
- "Tailor the analysis to address the user's specific concerns",
147
- ],
148
- },
149
- ...(hasPlaceholders && {
150
- contextPlaceholders: contextPlaceholders.reduce((acc, cp) => ({
151
- ...acc,
152
- [cp.placeholder]: {
153
- description: cp.description,
154
- example: cp.example,
155
- },
156
- }), {}),
157
- exampleUsage: `Before executing, customize the prompt. For example, replace:\n${contextPlaceholders
158
- .slice(0, 2)
159
- .map(cp => ` ${cp.placeholder} → "${cp.example}"`)
160
- .join('\n')}`,
161
- }),
162
- tips: [
163
- 'The more context you provide, the more tailored and useful the analysis will be',
164
- 'Consider what the user has already discussed when executing this prompt',
165
- "Focus the analysis on areas that matter most to the user's goals",
166
- ],
167
- };
168
- return JSON.stringify(response, null, 2);
169
- }
170
- /**
171
- * Execute a prompt that expects structured ADR suggestions
172
- *
173
- * @deprecated Use OrchestrationDirective returns instead. See ADR-014.
174
- */
175
- export async function executeADRSuggestionPrompt(prompt, instructions, options = {}) {
176
- const systemPrompt = options.systemPrompt ||
177
- `
178
- You are an expert software architect specializing in Architectural Decision Records (ADRs).
179
- Analyze the provided context and generate specific, actionable ADR suggestions.
180
- Focus on identifying architectural decisions that need to be documented based on the project context.
181
- Provide clear reasoning for each suggestion and prioritize them by importance.
182
- `;
183
- return executePromptWithFallback(prompt, instructions, {
184
- ...options,
185
- systemPrompt,
186
- temperature: options.temperature ?? 0.1,
187
- responseFormat: 'text',
188
- });
189
- }
190
- /**
191
- * Execute a prompt that expects to generate actual ADRs
192
- *
193
- * @deprecated Use OrchestrationDirective returns instead. See ADR-014.
194
- */
195
- export async function executeADRGenerationPrompt(prompt, instructions, options = {}) {
196
- const systemPrompt = options.systemPrompt ||
197
- `
198
- You are an expert software architect who creates comprehensive Architectural Decision Records (ADRs).
199
- Generate well-structured ADRs that follow best practices and include all necessary sections.
200
- Ensure each ADR is complete, actionable, and provides clear guidance for the development team.
201
- Use the standard ADR format with Status, Context, Decision, and Consequences sections.
202
- `;
203
- return executePromptWithFallback(prompt, instructions, {
204
- ...options,
205
- systemPrompt,
206
- temperature: options.temperature ?? 0.1,
207
- responseFormat: 'text',
208
- });
209
- }
210
- /**
211
- * Execute a prompt for project ecosystem analysis
212
- *
213
- * @deprecated Use OrchestrationDirective returns instead. See ADR-014.
214
- */
215
- export async function executeEcosystemAnalysisPrompt(prompt, instructions, options = {}) {
216
- const systemPrompt = options.systemPrompt ||
217
- `
218
- You are a senior software architect specializing in technology ecosystem analysis.
219
- Analyze the provided project context to identify technologies, patterns, and architectural decisions.
220
- Provide comprehensive insights about the project's technical landscape and recommendations for improvement.
221
- Focus on practical, actionable insights that can guide architectural decisions.
222
- `;
223
- return executePromptWithFallback(prompt, instructions, {
224
- ...options,
225
- systemPrompt,
226
- temperature: options.temperature ?? 0.1,
227
- responseFormat: 'text',
228
- });
229
- }
230
- /**
231
- * Execute a prompt for research question generation
232
- *
233
- * @deprecated Use OrchestrationDirective returns instead. See ADR-014.
234
- */
235
- export async function executeResearchPrompt(prompt, instructions, options = {}) {
236
- const systemPrompt = options.systemPrompt ||
237
- `
238
- You are a research specialist who generates comprehensive research questions and methodologies.
239
- Create detailed research plans that help teams investigate architectural decisions and technologies.
240
- Focus on practical research approaches that can be executed by development teams.
241
- Provide clear guidance on research methods, success criteria, and expected outcomes.
242
- `;
243
- return executePromptWithFallback(prompt, instructions, {
244
- ...options,
245
- systemPrompt,
246
- temperature: options.temperature ?? 0.2, // Slightly higher for creativity
247
- responseFormat: 'text',
248
- });
249
- }
250
- /**
251
- * Check if AI execution is currently available
252
- */
253
- export function isAIExecutionAvailable() {
254
- try {
255
- const executor = getAIExecutor();
256
- return executor.isAvailable();
257
- }
258
- catch {
259
- return false;
260
- }
261
- }
262
- /**
263
- * Get AI execution status for debugging
264
- *
265
- * @deprecated Legacy OpenRouter status function. Use isCEMCPEnabled() instead.
266
- */
267
- export function getAIExecutionStatus() {
268
- try {
269
- const config = loadAIConfig();
270
- const hasApiKey = !!config.apiKey;
271
- const isEnabled = isAIExecutionEnabled(config);
272
- let reason = undefined;
273
- if (config.executionMode !== 'ce-mcp') {
274
- if (!hasApiKey) {
275
- reason = 'Missing OPENROUTER_API_KEY environment variable';
276
- }
277
- else if (config.executionMode !== 'full') {
278
- reason = `EXECUTION_MODE is '${config.executionMode}', should be 'full'`;
279
- }
280
- }
281
- return {
282
- isEnabled,
283
- hasApiKey,
284
- executionMode: config.executionMode,
285
- model: config.defaultModel,
286
- reason,
287
- };
288
- }
289
- catch (error) {
290
- return {
291
- isEnabled: false,
292
- hasApiKey: false,
293
- executionMode: 'unknown',
294
- model: 'unknown',
295
- reason: `Configuration error: ${error instanceof Error ? error.message : String(error)}`,
296
- };
297
- }
298
- }
299
- /**
300
- * Get AI execution status and configuration info
301
- *
302
- * @deprecated Legacy OpenRouter info function. Use isCEMCPEnabled() instead.
303
- */
304
- export function getAIExecutionInfo() {
305
- const config = loadAIConfig();
306
- const available = isAIExecutionAvailable();
307
- const result = {
308
- available,
309
- mode: config.executionMode,
310
- };
311
- if (available) {
312
- result.model = config.defaultModel;
313
- result.cacheEnabled = config.cacheEnabled;
314
- }
315
- return result;
316
- }
317
- /**
318
- * Format execution result for MCP tool response
319
- *
320
- * @deprecated Return OrchestrationDirective directly instead. See ADR-014.
321
- */
322
- export function formatMCPResponse(result) {
323
- let responseText = result.content;
324
- // Add metadata footer if AI was used
325
- if (result.isAIGenerated && result.aiMetadata) {
326
- const metadata = [
327
- `\n\n---`,
328
- `**AI Generated Response**`,
329
- `- Model: ${result.model}`,
330
- `- Execution Time: ${result.aiMetadata.executionTime}ms`,
331
- `- Cached: ${result.aiMetadata.cached ? 'Yes' : 'No'}`,
332
- ];
333
- if (result.usage) {
334
- metadata.push(`- Tokens Used: ${result.usage.totalTokens} (${result.usage.promptTokens} prompt + ${result.usage.completionTokens} completion)`);
335
- }
336
- responseText += metadata.join('\n');
337
- }
338
- return {
339
- content: [{ type: 'text', text: responseText }],
340
- };
341
- }
342
- //# sourceMappingURL=prompt-execution.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"prompt-execution.js","sourceRoot":"","sources":["../../../src/utils/prompt-execution.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAAE,aAAa,EAAqB,MAAM,kBAAkB,CAAC;AACpE,OAAO,EAAE,oBAAoB,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AAgC5E;;;;;GAKG;AACH,MAAM,CAAC,KAAK,UAAU,yBAAyB,CAC7C,MAAc,EACd,YAAoB,EACpB,UAAkC,EAAE;IAEpC,MAAM,MAAM,GAAG,YAAY,EAAE,CAAC;IAC9B,MAAM,WAAW,GAAG,CAAC,OAAO,CAAC,eAAe,IAAI,oBAAoB,CAAC,MAAM,CAAC,CAAC;IAE7E,IAAI,WAAW,EAAE,CAAC;QAChB,IAAI,CAAC;YACH,MAAM,QAAQ,GAAG,aAAa,EAAE,CAAC;YAEjC,IAAI,OAAO,CAAC,cAAc,KAA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