Commit e6a541e
committed
feat: Upgrade legacy mapper with advanced semantic analysis
Major Upgrades:
- Architectural smell detection (4 types: God File, Semantic Confusion, High Disharmony, Mixed Concerns)
- Refactoring opportunity identification with impact scores
- Complexity heatmap generation (ASCII visual)
- Detailed suggestions for each refactoring target
New Features:
- Detects god files (>30 functions)
- Identifies files with no clear purpose (semantic confusion)
- Flags high disharmony files (>0.7 threshold)
- Finds mixed concern files (3+ active dimensions)
- Calculates complexity reduction estimates
- Provides specific refactoring actions
- Generates visual complexity heatmap by directory
- Sortable by impact score
Enhanced Output:
- Architectural smells grouped by severity (CRITICAL/HIGH/MEDIUM/LOW)
- Top 5 refactoring opportunities with specific actions
- Impact scores and complexity reduction percentages
- Visual heatmap showing problem hotspots
CLI Options:
- --no-heatmap: Skip complexity visualization
- --no-smells: Skip architectural smell detection
- --quiet: Minimal output for automation
Tested on Harmonizer itself:
- 5 architectural smells detected (4 HIGH, 1 MEDIUM)
- Top refactorings: ast_semantic_parser_v2.py (53% impact)
- Specific actions provided for each opportunity
This is now a complete legacy code understanding system.1 parent ddffdcf commit e6a541e
1 file changed
+303
-71
lines changed
0 commit comments