# How to Build Graphify from Source: Complete Installation Guide

> Build Graphify from source with our easy installation guide. Clone the repo, install dependencies, and run the install command to get Graphify up and running.

- Repository: [Graphify Labs/graphify](https://github.com/Graphify-Labs/graphify)
- Tags: how-to-guide
- Published: 2026-07-19

---

**To build Graphify from source, clone the Graphify-Labs/graphify repository, install Python 3.10+, use `uv` to install the `graphifyy` package, and run `graphify install` to register the skill with your AI assistant.**

Graphify is a Python-based knowledge-graph engine that constructs rich code graphs using tree-sitter grammars. Building Graphify from source gives you the CLI tool, semantic extraction capabilities, and the MCP server for programmatic access.

## Prerequisites

Before building, ensure you have **Python 3.10 or higher** installed. Check your version with:

```bash
python --version

```

You also need a package manager that supports isolated tool environments. While `pip` or `pipx` work, the Graphify project recommends [**uv**](https://github.com/astral-sh/uv) for faster builds and dependency resolution.

Install uv using the official installer:

```bash
curl -LsSf https://astral.sh/uv/install.sh | sh

```

## Build Steps

### Clone the Repository

Retrieve the source code from GitHub and navigate into the project directory:

```bash
git clone https://github.com/Graphify-Labs/graphify.git
cd graphify

```

The repository contains the core package under `graphify/`, configuration in [`pyproject.toml`](https://github.com/Graphify-Labs/graphify/blob/main/pyproject.toml), and a container definition in `Dockerfile`.

### Install the Graphify Package

Build and install the `graphifyy` package (note the package name uses a double "y"). This command compiles the tree-sitter grammars and places the `graphify` CLI on your PATH:

```bash
uv tool install graphifyy

```

If you prefer `pipx` or standard `pip`, use one of these alternatives:

```bash

# Using pipx

pipx install graphifyy

# Using pip (user install recommended)

pip install --user graphifyy

```

### Register the Skill

After installation, register Graphify with your AI assistant so it can invoke the `/graphify` command. Choose between a global or project-scoped installation:

- **Global install**: `graphify install`
- **Project-scoped install**: `graphify install --project`

The registration process writes a skill definition (for example, to [`.claude/skills/graphify/SKILL.md`](https://github.com/Graphify-Labs/graphify/blob/main/.claude/skills/graphify/SKILL.md)) and outputs a `git add` hint for version control.

### Verify the Build

Run a test build on the current directory to ensure everything works:

```bash
graphify .

```

This generates a `graphify-out/` directory containing [`graph.html`](https://github.com/Graphify-Labs/graphify/blob/main/graph.html), [`GRAPH_REPORT.md`](https://github.com/Graphify-Labs/graphify/blob/main/GRAPH_REPORT.md), and [`graph.json`](https://github.com/Graphify-Labs/graphify/blob/main/graph.json). These artifacts confirm that the **AST extraction** in [`graphify/build.py`](https://github.com/Graphify-Labs/graphify/blob/main/graphify/build.py) and semantic clustering pipelines are functioning correctly.

## Optional Build Configurations

### Docker Build

For containerized deployments or CI pipelines, build the Docker image defined in the root `Dockerfile`:

```bash
docker build -t graphify .

```

The Dockerfile packages the CLI, all tree-sitter grammars, and dependencies into a reproducible environment.

### Extra Language Backends

Customize your build by installing optional extras for additional file type support. Edit your install command to include specific dependency groups defined in [`pyproject.toml`](https://github.com/Graphify-Labs/graphify/blob/main/pyproject.toml):

- **PDF support**: `uv tool install "graphifyy[pdf]"`
- **Office documents**: `uv tool install "graphifyy[office]"`
- **Video/audio**: `uv tool install "graphifyy[media]"`
- **Neo4j export**: `uv tool install "graphifyy[neo4j]"`

These extras pull in additional libraries for parsing non-code formats and exporting to external graph databases.

## Verification and Testing

Validate your build by running the comprehensive test suite located in `tests/`:

```bash
uv run pytest -q

```

Alternatively, start the MCP server to programmatically access your generated graphs:

```bash
python -m graphify.serve graphify-out/graph.json

```

This launches a local server (STDIO or HTTP mode) that exposes the knowledge graph to compatible AI assistants.

## Summary

- **Build Graphify from source** using Python 3.10+, the `uv` tool, and the `graphifyy` package from the Graphify-Labs/graphify repository.
- **Core files** include [`pyproject.toml`](https://github.com/Graphify-Labs/graphify/blob/main/pyproject.toml) for dependency management and `Dockerfile` for containerized builds.
- **Registration** via `graphify install` enables the `/graphify` command in your AI assistant.
- **Optional extras** add support for PDFs, Office files, and Neo4j exports through bracketed install options.
- **Verification** involves running `pytest` or generating a test graph with `graphify .` to confirm AST extraction and semantic analysis pipelines work.

## Frequently Asked Questions

### What Python version is required to build Graphify?

Graphify requires **Python 3.10 or higher**. This is specified in [`pyproject.toml`](https://github.com/Graphify-Labs/graphify/blob/main/pyproject.toml) and enforced during the build process to ensure compatibility with modern type hints and async features used in [`graphify/build.py`](https://github.com/Graphify-Labs/graphify/blob/main/graphify/build.py) and related modules.

### Why is the package name `graphifyy` instead of `graphify`?

The PyPI package is named `graphifyy` (with two y's) to avoid naming conflicts, while the installed CLI command remains `graphify` (single y). When building from source, always use `uv tool install graphifyy` or `pip install graphifyy` to get the correct distribution.

### Can I build Graphify without using uv?

Yes, though uv is recommended for its speed and isolation. Alternatives include **pipx** (`pipx install graphifyy`) for isolated CLI tools, or standard **pip** with a virtual environment. The Docker build method also requires no local Python package manager beyond Docker itself.

### How do I enable support for PDF and Office documents?

Install the optional extras using bracket notation when running the install command: `uv tool install "graphifyy[pdf]"` for PDF parsing or `uv tool install "graphifyy[office]"` for Word and Excel files. These extras are defined in the `[project.optional-dependencies]` section of [`pyproject.toml`](https://github.com/Graphify-Labs/graphify/blob/main/pyproject.toml) and pull in specific parsing libraries.