mcp-adr-analysis-server 2.0.1 → 2.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +69 -27
- package/dist/src/index.d.ts +1 -0
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +688 -53
- package/dist/src/index.js.map +1 -1
- package/dist/src/prompts/adr-suggestion-prompts.js +27 -27
- package/dist/src/prompts/adr-suggestion-prompts.js.map +1 -1
- package/dist/src/prompts/analysis-prompts.js +7 -7
- package/dist/src/prompts/deployment-analysis-prompts.js +5 -5
- package/dist/src/prompts/environment-analysis-prompts.js +7 -7
- package/dist/src/prompts/index.d.ts.map +1 -1
- package/dist/src/prompts/index.js +7 -5
- package/dist/src/prompts/index.js.map +1 -1
- package/dist/src/prompts/research-integration-prompts.js +7 -7
- package/dist/src/prompts/research-question-prompts.js +7 -7
- package/dist/src/prompts/rule-generation-prompts.d.ts.map +1 -1
- package/dist/src/prompts/rule-generation-prompts.js +8 -6
- package/dist/src/prompts/rule-generation-prompts.js.map +1 -1
- package/dist/src/prompts/security-prompts.js +6 -6
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/prompts/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAaH;;GAEG;AACH,MAAM,CAAC,MAAM,uBAAuB,GAAmB;IACrD,IAAI,EAAE,oBAAoB;IAC1B,WAAW,EAAE,mEAAmE;IAChF,SAAS,EAAE;QACT;YACE,IAAI,EAAE,cAAc;YACpB,WAAW,EAAE,yDAAyD;YACtE,QAAQ,EAAE,KAAK;SAChB;QACD;YACE,IAAI,EAAE,iBAAiB;YACvB,WAAW,EAAE,yCAAyC;YACtD,QAAQ,EAAE,KAAK;SAChB;QACD;YACE,IAAI,EAAE,oBAAoB;YAC1B,WAAW,EAAE,6CAA6C;YAC1D,QAAQ,EAAE,KAAK;SAChB;KACF;IACD,QAAQ,EAA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AE,oEAAoE;YACjF,QAAQ,EAAE,IAAI;SACf;QACD;YACE,IAAI,EAAE,iBAAiB;YACvB,WAAW,EAAE,4CAA4C;YACzD,QAAQ,EAAE,KAAK;SAChB;KACF;IACD,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;0DAmD8C;CACzD,CAAC;AAEF;;GAEG;AACH,MAAM,CAAC,MAAM,UAAU,GAAqB;IAC1C,uBAAuB;IACvB,wBAAwB;IACxB,yBAAyB;IACzB,0BAA0B;IAC1B,sBAAsB;IACtB,sBAAsB;CACvB,CAAC"}
|
|
@@ -7,9 +7,9 @@
|
|
|
7
7
|
*/
|
|
8
8
|
export function generateResearchTopicExtractionPrompt(researchFiles, existingTopics) {
|
|
9
9
|
return `
|
|
10
|
-
# Research Topic Extraction
|
|
10
|
+
# Research Topic Extraction Guide
|
|
11
11
|
|
|
12
|
-
|
|
12
|
+
**Note: Use this as guidance for analyzing research files to extract key topics, findings, and insights that could impact architectural decisions. Focus on the most relevant and actionable information.**
|
|
13
13
|
|
|
14
14
|
## Research Files
|
|
15
15
|
${researchFiles
|
|
@@ -31,9 +31,9 @@ ${existingTopics.map(topic => `- ${topic}`).join('\n')}
|
|
|
31
31
|
`
|
|
32
32
|
: ''}
|
|
33
33
|
|
|
34
|
-
## Extraction
|
|
34
|
+
## Suggested Extraction Areas (focus on what's applicable)
|
|
35
35
|
|
|
36
|
-
|
|
36
|
+
Consider identifying and extracting information from these areas where relevant:
|
|
37
37
|
|
|
38
38
|
### 🔬 **Research Topics**
|
|
39
39
|
- **Technology Evaluations**: New frameworks, libraries, tools, platforms
|
|
@@ -57,9 +57,9 @@ Please identify and extract:
|
|
|
57
57
|
- **Non-functional Requirements**: Performance, security, scalability impacts
|
|
58
58
|
- **Process Changes**: Development or operational process improvements
|
|
59
59
|
|
|
60
|
-
## Output Format
|
|
60
|
+
## Suggested Output Format
|
|
61
61
|
|
|
62
|
-
|
|
62
|
+
The following JSON structure provides a template for organizing your research extraction (adapt fields as needed):
|
|
63
63
|
|
|
64
64
|
\`\`\`json
|
|
65
65
|
{
|
|
@@ -188,7 +188,7 @@ Please evaluate:
|
|
|
188
188
|
|
|
189
189
|
## Output Format
|
|
190
190
|
|
|
191
|
-
|
|
191
|
+
The following JSON structure provides a template for organizing your analysis (adapt fields as needed):
|
|
192
192
|
|
|
193
193
|
\`\`\`json
|
|
194
194
|
{
|
|
@@ -7,9 +7,9 @@
|
|
|
7
7
|
*/
|
|
8
8
|
export function generateProblemKnowledgeCorrelationPrompt(problems, knowledgeGraph) {
|
|
9
9
|
return `
|
|
10
|
-
# Problem-Knowledge Graph Correlation Analysis
|
|
10
|
+
# Problem-Knowledge Graph Correlation Analysis Guide
|
|
11
11
|
|
|
12
|
-
|
|
12
|
+
**Note: Use this as guidance for analyzing problems and correlating them with the architectural knowledge graph to identify research opportunities and knowledge gaps. Focus on the most relevant correlations for this specific context.**
|
|
13
13
|
|
|
14
14
|
## Identified Problems
|
|
15
15
|
${problems
|
|
@@ -35,9 +35,9 @@ ${knowledgeGraph.adrs.map(adr => `- **${adr.title}**: ${adr.status}`).join('\n')
|
|
|
35
35
|
### Relationships
|
|
36
36
|
${knowledgeGraph.relationships.map(rel => `- ${rel.source} → ${rel.target} (${rel.type})`).join('\n')}
|
|
37
37
|
|
|
38
|
-
## Correlation Analysis
|
|
38
|
+
## Suggested Correlation Analysis Areas (focus on what's applicable)
|
|
39
39
|
|
|
40
|
-
|
|
40
|
+
Consider identifying correlations and research opportunities from these areas where relevant:
|
|
41
41
|
|
|
42
42
|
### 🔍 **Problem-Knowledge Correlations**
|
|
43
43
|
- **Direct Correlations**: Problems directly related to known technologies/patterns
|
|
@@ -60,9 +60,9 @@ Please identify correlations and research opportunities:
|
|
|
60
60
|
- **Risk Mitigation**: Research to address high-severity problems
|
|
61
61
|
- **Innovation Opportunities**: Research for competitive advantage
|
|
62
62
|
|
|
63
|
-
## Output Format
|
|
63
|
+
## Suggested Output Format
|
|
64
64
|
|
|
65
|
-
|
|
65
|
+
The following JSON structure provides a template for organizing your correlation analysis (adapt fields as needed):
|
|
66
66
|
|
|
67
67
|
\`\`\`json
|
|
68
68
|
{
|
|
@@ -206,7 +206,7 @@ Please identify relevant elements for the research:
|
|
|
206
206
|
|
|
207
207
|
## Output Format
|
|
208
208
|
|
|
209
|
-
|
|
209
|
+
The following JSON structure provides a template for organizing your analysis (adapt fields as needed):
|
|
210
210
|
|
|
211
211
|
\`\`\`json
|
|
212
212
|
{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"rule-generation-prompts.d.ts","sourceRoot":"","sources":["../../../src/prompts/rule-generation-prompts.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;GAEG;AACH,wBAAgB,4BAA4B,CAC1C,QAAQ,EAAE,KAAK,CAAC;IACd,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC,EACF,aAAa,CAAC,EAAE,KAAK,CAAC;IACpB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;CACrB,CAAC,GACD,MAAM,
|
|
1
|
+
{"version":3,"file":"rule-generation-prompts.d.ts","sourceRoot":"","sources":["../../../src/prompts/rule-generation-prompts.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;GAEG;AACH,wBAAgB,4BAA4B,CAC1C,QAAQ,EAAE,KAAK,CAAC;IACd,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC,EACF,aAAa,CAAC,EAAE,KAAK,CAAC;IACpB,EAAE,EAA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,CAAC;CAC3B,CAAC,EACF,KAAK,EAAE,KAAK,CAAC;IACX,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE,MAAM,CAAC;CAClB,CAAC,EACF,UAAU,GAAE,SAAS,GAAG,UAAU,GAAG,OAAO,GAAG,YAAwB,GACtE,MAAM,CAmOR"}
|
|
@@ -7,9 +7,11 @@
|
|
|
7
7
|
*/
|
|
8
8
|
export function generateRuleExtractionPrompt(adrFiles, existingRules) {
|
|
9
9
|
return `
|
|
10
|
-
# Architectural Rule Extraction
|
|
10
|
+
# Architectural Rule Extraction Guide
|
|
11
11
|
|
|
12
|
-
|
|
12
|
+
**Note: Use this as guidance for analyzing the following Architectural Decision Records to extract actionable rules. Focus on rules that would be most valuable for validating code and architectural compliance in this specific context.**
|
|
13
|
+
|
|
14
|
+
Consider analyzing the ADRs below and extracting relevant rules where applicable.
|
|
13
15
|
|
|
14
16
|
## ADR Files
|
|
15
17
|
${adrFiles
|
|
@@ -32,9 +34,9 @@ ${existingRules.map(rule => `- **${rule.name}**: ${rule.description}`).join('\n'
|
|
|
32
34
|
`
|
|
33
35
|
: ''}
|
|
34
36
|
|
|
35
|
-
## Rule
|
|
37
|
+
## Suggested Rule Categories (focus on what's relevant)
|
|
36
38
|
|
|
37
|
-
|
|
39
|
+
Consider identifying and extracting rules from these categories where applicable to the specific ADRs:
|
|
38
40
|
|
|
39
41
|
### 🏗️ **Architectural Rules**
|
|
40
42
|
- **Component Structure**: How components should be organized and structured
|
|
@@ -69,7 +71,7 @@ Please identify and extract rules in the following categories:
|
|
|
69
71
|
|
|
70
72
|
## Output Format
|
|
71
73
|
|
|
72
|
-
|
|
74
|
+
The following JSON structure provides a template for organizing your rule analysis (adapt fields as needed):
|
|
73
75
|
|
|
74
76
|
\`\`\`json
|
|
75
77
|
{
|
|
@@ -206,7 +208,7 @@ Please analyze patterns to generate rules for:
|
|
|
206
208
|
|
|
207
209
|
## Output Format
|
|
208
210
|
|
|
209
|
-
|
|
211
|
+
The following JSON structure provides a template for organizing your rule analysis (adapt fields as needed):
|
|
210
212
|
|
|
211
213
|
\`\`\`json
|
|
212
214
|
{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"rule-generation-prompts.js","sourceRoot":"","sources":["../../../src/prompts/rule-generation-prompts.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;GAEG;AACH,MAAM,UAAU,4BAA4B,CAC1C,QAME,EACF,aAIE;IAEF,OAAO
|
|
1
|
+
{"version":3,"file":"rule-generation-prompts.js","sourceRoot":"","sources":["../../../src/prompts/rule-generation-prompts.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;GAEG;AACH,MAAM,UAAU,4BAA4B,CAC1C,QAME,EACF,aAIE;IAEF,OAAO;;;;;;;;EAQP,QAAQ;SACP,GAAG,CACF,CAAC,GAAG,EAAE,KAAK,EAAE,EAAE,CAAC;MACd,KAAK,GAAG,CAAC,KAAK,GAAG,CAAC,KAAK;UACnB,GAAG,CAAC,EAAE;cACF,GAAG,CAAC,MAAM;gBACR,GAAG,CAAC,QAAQ,IAAI,SAAS;;;;EAIvC,GAAG,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,EAAE,IAAI,CAAC,GAAG,GAAG,CAAC,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,gCAAgC,CAAC,CAAC,CAAC,EAAE;;CAE/F,CACE;SACA,IAAI,CAAC,EAAE,CAAC;;EAGT,aAAa;QACX,CAAC,CAAC;EACJ,aAAa,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,CAAC,OAAO,IAAI,CAAC,IAAI,OAAO,IAAI,CAAC,WAAW,EAAE,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC;CAChF;QACG,CAAC,CAAC,EACN;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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AC;;;EAGT,UAAU,CAAC,WAAW,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;qBAyCL,UAAU;;uBAER,iBAAiB,CAAC,MAAM;wBACvB,KAAK,CAAC,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAoJnC,CAAC;AACF,CAAC"}
|
|
@@ -7,9 +7,9 @@
|
|
|
7
7
|
*/
|
|
8
8
|
export function generateSensitiveContentDetectionPrompt(content, contentType = 'general', userDefinedPatterns) {
|
|
9
9
|
return `
|
|
10
|
-
# Sensitive Information Detection
|
|
10
|
+
# Sensitive Information Detection Guide
|
|
11
11
|
|
|
12
|
-
|
|
12
|
+
**Note: Use this as guidance for analyzing the content to identify sensitive information that should be masked or redacted. Focus on the most critical security patterns for this specific content type.**
|
|
13
13
|
|
|
14
14
|
## Content Type
|
|
15
15
|
${contentType}
|
|
@@ -25,9 +25,9 @@ ${userDefinedPatterns.map(pattern => `- ${pattern}`).join('\n')}
|
|
|
25
25
|
`
|
|
26
26
|
: ''}
|
|
27
27
|
|
|
28
|
-
## Detection
|
|
28
|
+
## Suggested Detection Categories (focus on what's applicable)
|
|
29
29
|
|
|
30
|
-
|
|
30
|
+
Consider identifying instances of sensitive information from these categories where relevant:
|
|
31
31
|
|
|
32
32
|
### 🔑 **API Keys & Tokens**
|
|
33
33
|
- API keys (AWS, Google, GitHub, Stripe, etc.)
|
|
@@ -64,9 +64,9 @@ Please identify ALL instances of sensitive information including:
|
|
|
64
64
|
- Customer data or identifiers
|
|
65
65
|
- Financial information
|
|
66
66
|
|
|
67
|
-
##
|
|
67
|
+
## Suggested Output Format
|
|
68
68
|
|
|
69
|
-
|
|
69
|
+
The following JSON structure provides a template for organizing your security analysis (adapt fields as needed):
|
|
70
70
|
|
|
71
71
|
\`\`\`json
|
|
72
72
|
{
|