mirror of
https://github.com/catlog22/Claude-Code-Workflow.git
synced 2026-02-14 02:42:04 +08:00
feat: Implement multi-phase project analysis workflow with Mermaid diagram generation and CPCC compliance documentation
- Phase 3: Added Mermaid diagram generation for system architecture, function modules, algorithms, class diagrams, sequence diagrams, and error flows. - Phase 4: Assembled analysis and diagrams into a structured CPCC-compliant document with section templates and figure numbering. - Phase 5: Developed compliance review process with iterative refinement based on analysis findings and user feedback. - Added CPCC compliance requirements and quality standards for project analysis reports. - Established a comprehensive project analysis skill with detailed execution flow and report types. - Enhanced error handling and recovery mechanisms throughout the analysis phases.
This commit is contained in:
58
.claude/skills/project-analyze/phases/03-deep-analysis.md
Normal file
58
.claude/skills/project-analyze/phases/03-deep-analysis.md
Normal file
@@ -0,0 +1,58 @@
|
||||
# Phase 3: Deep Analysis
|
||||
|
||||
Execute deep analysis using Gemini CLI with exploration context.
|
||||
|
||||
## Execution
|
||||
|
||||
### Step 1: Prepare CLI Prompt
|
||||
|
||||
```bash
|
||||
ccw cli -p "
|
||||
PURPOSE: Generate ${type} analysis report for project
|
||||
TASK:
|
||||
• Analyze project structure and patterns from ${type} perspective
|
||||
• Focus on: ${focus_areas}
|
||||
• Depth level: ${depth}
|
||||
• Key files: ${key_files}
|
||||
MODE: analysis
|
||||
CONTEXT: @**/* | Exploration results
|
||||
EXPECTED:
|
||||
- Structured analysis
|
||||
- Code references (file:line format)
|
||||
- Mermaid diagram data
|
||||
- Actionable insights
|
||||
RULES: $(cat ~/.claude/workflows/cli-templates/protocols/analysis-protocol.md)
|
||||
" --tool gemini --mode analysis
|
||||
```
|
||||
|
||||
### Step 2: Parse Analysis Results
|
||||
|
||||
Extract structured data from CLI response:
|
||||
|
||||
```javascript
|
||||
const deepAnalysis = {
|
||||
findings: [], // Analyzed findings with confidence scores
|
||||
patterns: [], // Identified patterns with consistency scores
|
||||
dependencies: [], // Dependency relationships
|
||||
recommendations: [], // Prioritized recommendations
|
||||
sections: [], // Report section data
|
||||
diagram_data: {} // Data for diagram generation
|
||||
};
|
||||
```
|
||||
|
||||
### Step 3: Validate Analysis Quality
|
||||
|
||||
Check analysis completeness:
|
||||
|
||||
```javascript
|
||||
const qualityChecks = {
|
||||
has_executive_summary: Boolean,
|
||||
focus_areas_covered: config.focus_areas.every(area => analysis.covers(area)),
|
||||
code_references_valid: analysis.references.every(ref => fileExists(ref)),
|
||||
insights_actionable: analysis.insights.filter(i => i.actionable).length > 0
|
||||
};
|
||||
```
|
||||
|
||||
## Output
|
||||
|
||||
Save analysis results to `deep-analysis.json`.
|
||||
Reference in New Issue
Block a user