A powerful static code analysis system that provides extensive information about your codebase using the Codegen SDK.
This analyzer provides comprehensive analysis of your codebase, including:
- File Statistics (count, language, size)
- Symbol Tree Analysis
- Import/Export Analysis
- Module Organization
- Function Analysis (parameters, return types, complexity)
- Class Analysis (methods, attributes, inheritance)
- Variable Analysis
- Type Analysis
- Call Graph Generation
- Data Flow Analysis
- Control Flow Analysis
- Symbol Usage Analysis
- Unused Code Detection
- Code Duplication Analysis
- Complexity Metrics
- Style and Convention Analysis
- Dependency Graphs
- Call Graphs
- Symbol Trees
- Heat Maps
- Python-Specific Analysis
- TypeScript-Specific Analysis
- Monthly Commits
- Cyclomatic Complexity
- Halstead Volume
- Maintainability Index
- Clone the repository:
git clone https://github.com/yourusername/codebase-analyzer.git
cd codebase-analyzer- Install dependencies:
pip install -r requirements.txt# Analyze from URL
python codebase_analyzer.py --repo-url https://github.com/username/repo
# Analyze local repository
python codebase_analyzer.py --repo-path /path/to/repo
# Specify language
python codebase_analyzer.py --repo-url https://github.com/username/repo --language python
# Analyze specific categories
python codebase_analyzer.py --repo-url https://github.com/username/repo --categories codebase_structure code_quality# Output as JSON
python codebase_analyzer.py --repo-url https://github.com/username/repo --output-format json --output-file analysis.json
# Generate HTML report
python codebase_analyzer.py --repo-url https://github.com/username/repo --output-format html --output-file report.html
# Print to console (default)
python codebase_analyzer.py --repo-url https://github.com/username/repo --output-format consolecodebase_structure: File statistics, symbol tree, import/export analysis, module organizationsymbol_level: Function, class, variable, and type analysisdependency_flow: Call graphs, data flow, control flow, symbol usagecode_quality: Unused code, duplication, complexity, stylevisualization: Dependency graphs, call graphs, symbol trees, heat mapslanguage_specific: Language-specific analysis featurescode_metrics: Commits, complexity, volume, maintainability
- Python 3.8+
- Codegen SDK
- NetworkX
- Matplotlib
- Rich
MIT