# Map Python import graphs to explain coupling before refactors or package splits with pydeps

> Generate Python module dependency graphs so refactors and package splits start from an actual import map instead of guesswork.

- Skill: `agentskillexchange/map-python-import-graphs-to-explain-coupling-before-refactor` (Agent Skill)
- Install (CLI): `npx skillmds@latest add agentskillexchange/map-python-import-graphs-to-explain-coupling-before-refactor`
- Raw SKILL.md: https://api.skillmd.com/api/skills/agentskillexchange/map-python-import-graphs-to-explain-coupling-before-refactor/raw
- Safety review: pending (external: skill-scanner PASS, skillspector PASS)
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Coding & Dev Tools
- Author: agentskillexchange (https://skillmd.com/u/agentskillexchange)
- Updated: 2026-09-08
- Page: https://skillmd.com/skills/agentskillexchange/map-python-import-graphs-to-explain-coupling-before-refactor

---


# Map Python import graphs to explain coupling before refactors or package splits with pydeps

Generate Python module dependency graphs so refactors and package splits start from an actual import map instead of guesswork.

## Prerequisites

Python, Graphviz, a local Python codebase to analyze.

## Installation

Use the upstream install or setup path that matches your environment:
- pip install pydeps

Requirements and caveats from upstream:
- Python module dependency visualization.
- --pylib include python std lib modules
- --pylib-all include python all std lib modules (incl. C modules)

Basic usage or getting-started notes:
- To create graphs with pydeps you also need to install Graphviz_. Please follow the
- sure the dot command is on your path).
- ------------------

- Source: https://github.com/thebjorn/pydeps
- Extracted from upstream docs: https://raw.githubusercontent.com/thebjorn/pydeps/HEAD/README.rst

## Documentation

- https://github.com/thebjorn/pydeps

## Source

- [Agent Skill Exchange](https://agentskillexchange.com/skills/map-python-import-graphs-to-explain-coupling-before-refactors-or-package-splits-with-pydeps/)

