← Directory

Code Graph Rag

Open Source
★ 5,288 • Updated Oct 27, 2026, 03:02 PM

Code Graph Rag is an open-source tool that enables users to query, understand, and edit multi-language codebases with the power of AI and knowledge graphs.

Use Cases ▼
01

Querying and editing multi-language codebases

02

Code optimisation and dead code detection

03

Dynamic call tracing and graph export

04

Working with large and complex codebases

05

Using AI and knowledge graphs to improve code understanding

What Problem It Solves ▼

Code Graph Rag solves the problem of navigating and understanding large and complex codebases, which can be time-consuming and difficult for developers. It provides a unified graph schema that allows users to query and edit code in plain English, making it easier to work with multi-language codebases. By using AI and knowledge graphs, Code Graph Rag enables users to optimise code, detect dead code, and trace dynamic calls, making it a powerful tool for developers and ML engineers.

Key Features ▼
✓

Unified graph schema for multi-language codebases

✓

AI-powered editing and optimisation

✓

Support for a wide range of languages

✓

Open-source and community-driven

Overview

Code Graph Rag is an open-source tool that enables users to query, understand, and edit multi-language codebases with the power of AI and knowledge graphs. It uses a Tree-sitter based parser to read the codebase and ingests functions, classes, methods, modules, and their relationships into a graph under a single language-agnostic schema. The system has two components: a multi-language parser and a RAG system that turns natural language into Cypher queries, retrieves matching code, and drives AI-powered editing and optimisation. The graph is stored in an embedded SQLite file by default, but Memgraph and Neo4j are also available as opt-in backends. Code Graph Rag supports a wide range of languages, including Python, TypeScript, JavaScript, Rust, Go, Java, C, C++, and many others. It provides features such as code optimisation, dead code detection, dynamic call tracing, and graph export. The tool is designed to be used by developers, ML engineers, and data scientists who need to work with large and complex codebases. Code Graph Rag is available on GitHub and can be installed using pip or uv. It is licensed under the MIT license and has a strong focus on community involvement and contribution.

Pros & Cons

Pros

+

Unified graph schema for multi-language codebases

+

AI-powered editing and optimisation

+

Support for a wide range of languages

+

Open-source and community-driven

Cons

−

Steep learning curve due to complex features

−

Requires significant computational resources

−

Limited support for certain languages

Similar Tools

GitHub Copilot Kite TabNine

More in Dev Tools