ludo-technologies/pyscn/architecture-review
Claude Code and agent skill by ludo-technologies/pyscn
- community
Checking that the SKILL.md file is still in the repository.
Analyze Python module architecture using pyscn - class coupling (CBO), cohesion (LCOM), dependency cycles, and module communities. Use when user asks about architecture, module structure, coupling, circular dependencies, or which files to review or change together.
Install
npx vskill@latest install ludo-technologies/pyscn/architecture-reviewSKILL.md
Python Architecture Review with pyscn
Run the pyscn CLI to understand module structure and coupling. No install needed: uvx pyscn@latest <command>.
Commands
| User Request | Command | |
|---|---|---|
| "Check class coupling" | uvx pyscn@latest analyze --select cbo <path> | |
| "Find circular dependencies" | uvx pyscn@latest analyze --select deps <path> | |
| "Check class cohesion" | uvx pyscn@latest analyze --select lcom <path> | |
| "Which files should I review together?" | uvx pyscn@latest analyze --select communities --json <path> | |
| "Map the module architecture" | uvx pyscn@latest analyze --select communities --json <path> |
Useful flags: --min-cbo <n> (minimum CBO to report), --json (detailed report file). Report files are NOT written to stdout; they go to .pyscn/reports/ and the path is printed on completion.
Module Communities (context map for agents)
Module community detection is opt-in: run with --select communities --json and read the report file.
The JSON report includes community_analysis.community_context_map, a compact, deterministic map telling you which modules to inspect together:
bundles[]: clusters of modules that change together. Each hasmodules,packages,risk_level, the cluster'sbridge_modules, an optionalsuggested_review_scope(path prefix to focus a review on), and a one-linesummary. Large bundles cap the module list with a... +N moremarker (module_countalways holds the true total).bridge_modules[]: modules that couple two or more communities (module, the communities itconnects, and areason). Widen the review scope to include these when touching a bundle they connect.
Use the map to scope reviews and refactors: load all modules in a bundle together, and pull in connected bridge modules before changing cluster boundaries.
Interpreting Coupling Results
- High CBO classes depend on many others; changes ripple widely. Suggest interface extraction or dependency inversion.
- High LCOM4 classes bundle unrelated responsibilities; suggest splitting along the disconnected method groups.
- Dependency cycles are the highest-priority architectural issue; name the modules in each cycle and the weakest edge to break.
Always tie findings back to concrete modules and suggest a specific structural change.
MCP Alternative
If the pyscn-mcp MCP server is connected, you can use its tools instead of the CLI: check_coupling for CBO metrics, or analyze_code with analyses: ["deps"], ["lcom"], or ["communities"] (communities require output_mode: "full"; the full response includes the same community_context_map). Results are returned inline with no report files.
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewNot runA model review is scheduled for the next rescan.
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryChecking.claude-plugin/pyscn-mcp/skills/architecture-review/SKILL.md
Popularity
- Repository stars
- 1,029
- Repository forks
- 69
- 7-day trend score
- 35
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/ludo-technologies/pyscn/architecture-review)