Code Cohesion Analyzer

Create a comprehensive software architecture analysis with this AI prompt, focusing on refactoring monolithic codebases for improved cohesion and maintainability.

What this prompt does

  • Analyzes codebase to calculate LCOM metrics, identifying classes with low cohesion.
  • Provides recommendations for splitting classes into focused, single-responsibility units.
  • Suggests new class structures to improve maintainability, testability, and reduce coupling.

How to use this prompt

  1. Run the full prompt and answer the questions as detailed as possible.
  2. Example: "Calculate LCOM for each class, identify low cohesion issues, and propose refactoring solutions with before/after code examples."

Premium prompt — included in the Complete AI Bundle. Part of the Coding prompts collection in the God of Prompt library.

Related Coding prompts