sdd-mcp-server 1.3.4 → 1.3.6

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/mcp-server.js CHANGED
@@ -758,13 +758,32 @@ server.registerTool("sdd-steering", {
758
758
  }
759
759
 
760
760
  // Analyze project structure dynamically
761
+ console.log('Starting project analysis...');
761
762
  const projectAnalysis = await analyzeProject(currentPath);
763
+ console.log('Project analysis completed:', {
764
+ name: projectAnalysis.name,
765
+ description: projectAnalysis.description?.substring(0, 50) + '...',
766
+ architecture: projectAnalysis.architecture,
767
+ deps: projectAnalysis.dependencies.length,
768
+ devDeps: projectAnalysis.devDependencies.length
769
+ });
770
+
771
+ // Validate analysis results
772
+ if (isAnalysisInsufficient(projectAnalysis)) {
773
+ console.log('Analysis insufficient, applying fallback enhancements...');
774
+ // Apply additional fallback logic here if needed
775
+ }
762
776
 
763
777
  // Generate dynamic documents based on actual project analysis
764
778
  const productContent = generateProductDocument(projectAnalysis);
765
779
  const techContent = generateTechDocument(projectAnalysis);
766
780
  const structureContent = generateStructureDocument(projectAnalysis);
767
781
 
782
+ // Validate generated content before writing
783
+ if (contentContainsGenericPlaceholders(productContent)) {
784
+ console.log('Warning: Product document contains generic content');
785
+ }
786
+
768
787
  // Write the dynamically generated documents
769
788
  await fs.writeFile(path.join(steeringPath, 'product.md'), productContent);
770
789
  await fs.writeFile(path.join(steeringPath, 'tech.md'), techContent);
@@ -800,7 +819,7 @@ server.registerTool("sdd-steering", {
800
819
  - \`.kiro/steering/structure.md\` - Project organization and architectural decisions (dynamically generated)
801
820
 
802
821
  **Dynamic Analysis Results**:
803
- - **Language**: ${projectAnalysis.language === 'typescript' ? 'TypeScript' : 'JavaScript'}
822
+ - **Language**: ${projectAnalysis.language === 'typescript' ? 'TypeScript' : projectAnalysis.language === 'java' ? 'Java' : projectAnalysis.language === 'python' ? 'Python' : projectAnalysis.language === 'go' ? 'Go' : projectAnalysis.language === 'ruby' ? 'Ruby' : projectAnalysis.language === 'php' ? 'PHP' : projectAnalysis.language === 'rust' ? 'Rust' : projectAnalysis.language === 'csharp' ? 'C#' : projectAnalysis.language === 'scala' ? 'Scala' : 'JavaScript'}
804
823
  - **Framework**: ${projectAnalysis.framework || 'None detected'}
805
824
  - **Dependencies**: ${projectAnalysis.dependencies.length} production, ${projectAnalysis.devDependencies.length} development
806
825
  - **Test Framework**: ${projectAnalysis.testFramework || 'None detected'}
@@ -809,7 +828,7 @@ server.registerTool("sdd-steering", {
809
828
  - **CI/CD**: ${projectAnalysis.hasCI ? 'Configured' : 'Not configured'}
810
829
  - **Docker**: ${projectAnalysis.hasDocker ? 'Configured' : 'Not configured'}
811
830
 
812
- These steering documents were dynamically generated based on actual project analysis and provide accurate, up-to-date context for AI interactions.`
831
+ These steering documents were dynamically generated based on actual project analysis and provide accurate, up-to-date context for AI interactions.${contentContainsGenericPlaceholders(productContent) ? '\n\n**Note**: Some content may be generic due to limited project metadata. Consider adding more descriptive information to package.json or project files.' : ''}`
813
832
  }]
814
833
  };
815
834
  } catch (error) {
@@ -1432,4 +1451,17 @@ server.registerTool("sdd-spec-impl", {
1432
1451
  });
1433
1452
 
1434
1453
  const transport = new StdioServerTransport();
1454
+ // Helper functions for validation
1455
+ function isAnalysisInsufficient(analysis) {
1456
+ return analysis.name === 'Unknown Project' &&
1457
+ analysis.description === 'No description available' &&
1458
+ analysis.dependencies.length === 0;
1459
+ }
1460
+
1461
+ function contentContainsGenericPlaceholders(content) {
1462
+ return content.includes('Unknown Project') ||
1463
+ content.includes('No description available') ||
1464
+ content.includes('unknown');
1465
+ }
1466
+
1435
1467
  await server.connect(transport);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sdd-mcp-server",
3
- "version": "1.3.4",
3
+ "version": "1.3.6",
4
4
  "description": "MCP server for spec-driven development workflows across AI-agent CLIs and IDEs",
5
5
  "main": "dist/index.js",
6
6
  "bin": {