vitali87/code-graph-rag
The ultimate RAG for your monorepo. Query, understand, and edit multi-language codebases with the power of AI and knowledge graphs
What it solves
Code-Graph-RAG addresses the difficulty of understanding and maintaining large, multi-language codebases. It allows developers to query, edit, and optimize code using natural language by grounding AI responses in a structural knowledge graph of the codebase rather than relying on simple text search.
How it works
The system consists of two primary components:
- Multi-language parser: Uses Tree-sitter to extract functions, classes, methods, and modules, storing them in a Memgraph knowledge graph. It enhances this with compiler-grade frontends (like libclang for C/C++ or go/types for Go) and dynamic runtime tracing to capture calls that static analysis cannot see.
- RAG system: An interactive CLI that translates natural language queries into Cypher queries to retrieve precise structural information from the graph, which is then used to ground AI-powered code editing and optimization.
Who it’s for
Developers and engineering teams working with complex monorepos or multi-language projects who need to efficienty navigate, document, and refactor their code.
Highlights
- Multi-language support: Works across Python, TypeScript, Rust, Go, Java, C/C++, C#, and others under a unified schema.
- AST-based editing: Performs surgical patching of code with diff previews before applying changes.
- Runtime overlay: Merges eBPF profiles or test run traces into the graph to expose dynamic dispatch.
- Dead code detection: Identifies unused code by walking call and reference edges from entry points.
- MCP Server: Integrates with Claude Code and other Model Context Protocol clients.
Related
- Project
- Project
- Project
- Project
- Project