FalkorDB/code-graph
A code-graph demo using GraphRAG-SDK and FalkorDB
What it solves
CodeGraph helps developers analyze complex codebases by transforming source code into a visual knowledge graph. This allows users to easily identify dependencies, detect architectural bottlenecks, and optimize project structures that are otherwise difficult to navigate in traditional text editors.
How it works
The tool analyzes source code (supporting Python, Java, and C#) and maps the relationships between entities into a FalkorDB graph database. It provides multiple ways to interact with this data:
- Visualization: A React-based frontend for exploring the graph.
- GraphRAG Chat: An LLM-powered chat interface that uses the knowledge graph to answer technical questions about the code.
- CLI & MCP: A command-line tool (
cgraph) and a Model Context Protocol (MCP) server that allow AI agents (like Claude Code or Cursor) to index and query the codebase programmatically. - Analysis Pipeline: A backend powered by FastAPI that handles repository cloning, source analysis, and graph operations.
Who it’s for
- Software Architects: For mapping dependencies and analyzing the impact of changes.
- Developers: For onboarding to new, large codebases or finding call-chains between functions.
- AI Agent Users: For providing LLMs with structured, graph-based context of a codebase via MCP.
Highlights
- GraphRAG Integration: Combines knowledge graphs with LLMs to provide more accurate answers about code structure.
- MCP Server: Exposes 7 first-class tools (e.g.,
impact_analysis,find_path) for AI agents. - Multi-Language Support: Built-in analyzers for Python, Java, and C#.
- Flexible Deployment: Supports FalkorDB Cloud, local Docker containers, or an embedded FalkorDBLite backend.
Related
- Project
- Project
- Project