Tools
Graphify: Turn Any Codebase into a Queryable Knowledge Graph for AI Coding Assistants
Graphify maps your entire project — code, docs, PDFs, images, and videos — into an interactive knowledge graph your AI coding assistant can query in seconds instead of grepping through files.

Graphify: Turn Any Codebase into a Queryable Knowledge Graph for AI Coding Assistants
One of the biggest frustrations with AI coding assistants is that they have no persistent understanding of your codebase. Every session starts fresh — the agent has to re-read files, re-discover patterns, and re-learn your project structure. Even with long context windows, the AI can miss connections between different parts of your code.
**Graphify** solves this. Born as a Y Combinator S26 project, it has exploded to over 56,000 GitHub stars. The concept is simple: type `/graphify .` in your AI coding assistant, and it maps your entire project — code files, SQL schemas, documentation, images, even videos — into a knowledge graph you can query instead of grepping through files.
What Graphify Actually Does
Graphify is not a RAG system in the traditional sense. Instead of chunking text for vector search, it builds a **structured knowledge graph** that captures the actual relationships between entities in your project:
- **Code entities:** functions, classes, modules, imports, and their call hierarchies
- **Data schemas:** database tables, columns, relationships, indexes
- **Documentation:** README files, API docs, architectural decisions
- **Infrastructure:** Dockerfiles, CI configs, deployment manifests
- **Media:** images, diagrams, and video content (via transcription)
All of these get linked into a single graph that your AI assistant can query with natural language. Instead of `grep -r "auth_middleware" src/` and manually tracing dependencies, you ask your AI: *"what touches the authentication middleware?"* and get back a subgraph of every file, function, and config that interacts with it.
How to Install Graphify
Graphify is a Python package distributed as `graphifyy` (double-y) on PyPI. Installation takes about two minutes:
Prerequisites
| Requirement | Minimum | Check |
|------------|---------|-------|
| Python | 3.10+ | `python --version` |
| uv (recommended) | any | `uv --version` |
Step 1: Install the Package
```bash
Recommended — uv puts graphify on PATH automatically
uv tool install graphifyy
Alternative
pipx install graphifyy
```
> **Note:** Avoid plain `pip install graphifyy` unless you're comfortable managing `PATH` manually — `uv tool install` and `pipx` both isolate the package in its own environment and handle PATH setup.
Step 2: Register with Your AI Assistant
```bash
graphify install
```
That's it. Open your AI coding assistant and type `/graphify .` to graph your current project.
Platform-Specific Installation
Graphify supports 20+ AI coding platforms with dedicated install commands:
| Platform | Command |
|----------|---------|
| **Claude Code** (Linux/Mac) | `graphify install` |
| **Claude Code** (Windows) | `graphify install --platform windows` |
| **Codex** | `graphify install --platform codex` |
| **OpenCode** | `graphify install --platform opencode` |
| **Gemini CLI** | `graphify install --platform gemini` |
| **Cursor** | `graphify cursor install` |
| **Hermes Agent** | `graphify install --platform hermes` |
| **VS Code Copilot Chat** | `graphify vscode install` |
| **Kimi Code** | `graphify install --platform kimi` |
| **GitHub Copilot CLI** | `graphify install --platform copilot` |
Optional Extras
Install only what your project needs:
```bash
pip install "graphifyy[pdf]" # PDF extraction
pip install "graphifyy[office]" # .docx and .xlsx support
pip install "graphifyy[video]" # Video/audio transcription
pip install "graphifyy[sql]" # SQL schema extraction
pip install "graphifyy[ollama]" # Local inference via Ollama
pip install "graphifyy[neo4j]" # Neo4j graph database push
pip install "graphifyy[mcp]" # MCP server integration
pip install "graphifyy[all]" # Everything above
```
What You Get After Running `/graphify .`
Running the command produces three files in a `graphify-out/` directory:
1. `graph.html` — Interactive Browser Visualisation
Open this in any browser. You'll see a force-directed graph of your entire codebase — nodes represent files, functions, classes, and data schemas; edges represent imports, calls, inheritance, and data flow. You can:
- Click any node to see its connections
- Search by entity name
- Filter by type (functions, classes, files)
- Zoom into subgraphs
- Export screenshots
This alone replaces the hours developers spend manually drawing architecture diagrams.
2. `GRAPH_REPORT.md` — Human-Readable Summary
A Markdown report covering:
- Key concepts and architectural patterns
- Surprising connections between unrelated modules
- Suggested questions for your AI assistant
- Dependency analysis and circular import detection
3. `graph.json` — Machine-Readable Full Graph
This is what your AI coding assistant queries. The graph persists across sessions, so your AI can reference it without re-reading every file. You can also export a full architecture page with Mermaid call-flow diagrams:
```bash
graphify export callflow-html
```
Real-World Use Cases
Onboarding to a New Codebase
Joining a project with 50,000+ files? Run `/graphify .` and your AI assistant instantly understands the full architecture. No more spending days reading through README files trying to piece together how everything connects.
Debugging Cross-Cutting Concerns
When a bug touches authentication, database, and frontend code simultaneously, traditional file search is painstaking. A graph query like *"trace the user session lifecycle from login to database write"** returns every relevant connection in seconds.
Technical Documentation
Export architecture diagrams, call flows, and dependency maps directly from your codebase. Graphify's `export callflow-html` command produces readable documentation pages with Mermaid diagrams — perfect for team wikis and onboarding guides.
For RAG and Knowledge Management
Graphify pairs naturally with local RAG pipelines. The extracted graph can be pushed into Neo4j or used as a structured retrieval source alongside vector embeddings. For teams running local document Q&A workflows, Graphify provides the relational context that pure vector search misses.
Graphify vs. CodeGraph
The blog previously covered CodeGraph for pre-indexed knowledge graphs. How does Graphify compare?
| Feature | Graphify | CodeGraph |
|---------|----------|-----------|
| Graph type | Dynamic (built on first run) | Pre-indexed (hosted) |
| Local-first | ✅ Full local | ❌ Requires cloud sync |
| File support | Code + docs + images + video | Code only |
| Platforms | 20+ agents | Claude Code primarily |
| Open source | ✅ MIT | ❌ Proprietary components |
| LLM for extraction | Bring your own (Ollama, OpenAI, Gemini) | Built-in |
For fully self-hosted setups, Graphify's ability to run with local models via Ollama makes it the stronger choice. If you're already running Ollama for local inference, you can pair it with Graphify for a completely private knowledge graph pipeline.
Making Your Assistant Always Use the Graph
After building your first graph, run `graphify install` to configure your AI coding assistant to consult the knowledge graph automatically. This writes a config that tells the assistant to prefer `graphify query "<question>"` over grepping raw files. On supported platforms (Claude Code, Gemini CLI), a hook fires automatically before file-search tool calls, nudging the assistant toward the graph path.
For team projects, commit the `graphify-out/` directory and have every developer run the same `graphify install` — everyone gets the same shared understanding of the codebase.
The Bottom Line
Graphify solves a fundamental limitation of AI coding assistants: they lack persistent structural understanding of your codebase. By mapping every file, function, schema, and document into a queryable knowledge graph, Graphify turns your AI assistant from a line-by-line reader into a system that understands your project's architecture.
With 56,000+ stars and Y Combinator backing, it's one of the fastest-growing developer tools of 2026. If you're using any AI coding assistant — Claude Code, Codex, Cursor, or Gemini CLI — the five-minute install is one of the highest-ROI changes you can make.
**Links:**
