The Repository Dependency Graph Tool
Build a module import graph from a repository’s source files — showing exactly how modules depend on one another — and save it to file, giving agents and engineers a precise view of internal coupling, on infrastructure you control.
Change ripples through imports nobody can see
A change to one module can break others that import it, directly or transitively. Without an explicit import graph, that coupling is invisible and every change carries hidden risk.
Invisible ripple effects
A small change breaks a distant module via an import nobody mapped.
Transitive coupling
Indirect dependencies are the hardest to anticipate.
Cycles hide
Circular imports tangle the codebase silently.
No durable artifact
Ad-hoc reasoning about imports isn’t saved or shareable.
The import graph, made explicit
Graph
Module-to-module edges
Who imports whom.
The tool parses source files to build a directed graph of module imports, making the internal coupling of a codebase explicit and inspectable rather than implied.
- Source-file parsing
- Directed import edges
- Transitive relationships
- Cycle visibility
Module-level
Artifact
Saved for downstream use
A graph other tools consume.
The graph is written to file, so agents can use it to compute blast radius, find cycles, and reason about safe change — and engineers can visualize it.
Reusable artifact
Governance
On-premise analysis
Source stays internal.
The graph is built from local source inside your perimeter with audit logging, output written where you choose.
Local, logged
Parameters
The repo_dependency_graph tool accepts these inputs when an agent calls it. Required inputs are flagged.
default: /tmp/dependency_graphs/ Optional Directory where the dependency graph file is saved.
Where the import graph pays back
Blast-radius analysis
See everything that imports a module before changing it.
Cycle detection
Find and break circular imports.
Refactor planning
Untangle coupling with the graph in hand.
Onboarding
Show how the codebase’s modules fit together.
Architecture review
Feed the graph into higher-level architecture inference.
Agent reasoning
Let an agent compute safe change from real coupling.
Assigned to agents, orchestrated as networks
On VDF AI, an industry’s use cases map to agents, and you assign tools like this one to those agents. Compose multiple agents into a governed, on-premise network.
What changes after you assign it
Questions about the Repository Dependency Graph tool
What does the repository dependency graph tool do?
It parses a repository’s source files to build a module import graph — a directed map of which modules import which — and saves it to file, making internal coupling explicit and reusable.
How is it different from the dependency analyzer?
The analyzer parses manifests and reports both external packages and imports; this tool focuses specifically on building a precise, saved module import graph from source for blast-radius and cycle analysis.
Where is the graph saved?
To the output_dir you specify, defaulting to a temporary directory, so it can be visualized or consumed by other tools.
Is our code exposed?
No. The graph is built on-premise from local source with audit logging.
How does it pair with other tools?
It feeds change-impact analysis and architecture inference, and complements the repository map for full structural understanding.
Tools that work well alongside this one
Where this tool delivers value
Make internal coupling visible
See the repository dependency graph give an agent a precise import map — on infrastructure you control.