Deep Graph MCP Server

Deep Graph MCP Server

Enables seamless interaction with public or private code graphs from DeepGraph and CodeGPT to perform semantic searches and dependency analysis. It allows developers to explore architectural relationships, retrieve source code, and analyze repository structures across multiple AI assistants.

Category
Visit Server

README

Open in DeepGraph GitHub stars GitHub pull requests

<hr>

Deep Graph MCP Server by CodeGPT

A Model Context Protocol server that enables seamless interaction with Code Graphs.

<img width="1373" alt="Screenshot 2025-06-11 at 14 01 15" src="https://github.com/user-attachments/assets/a588bafc-d5a8-4955-8d48-3addaf3ed71c" />

How this works

This MCP allows you to interact with knowledge graphs available in your CodeGPT account or with public graphs from DeepGraph.

To create a graph from any GitHub repository, simply change the URL from github.com to deepgraph.co. For example:

  • GitHub repo: https://github.com/username/repo
  • DeepGraph URL: https://deepgraph.co/username/repo

<video src="https://github.com/user-attachments/assets/31f60fe6-6da4-4c67-a845-031908476351" controls autoplay></video>

You'll be able to use these advanced graph-based queries across different MCP Hosts such as ChatGPT, Cursor, Windsurf, CodeGPT Extension, GitHub Copilot, Claude Desktop, Claude Code, Gemini CLI, and others.

Available Tools

  • list-graphs: Lists available repository graphs with basic information.

  • get-code: Retrieves the complete source code for a specific functionality from the graph.

  • find-direct-connections: Explores the direct relationships of a functionality within the code graph.

  • nodes-semantic-search: Semantically searches for code functionalities using natural language.

  • docs-semantic-search: Semantically searches repository documentation.

  • get-usage-dependency-links: Analyzes and lists functionalities affected by changes to a code entity.

  • folder-tree-structure: Retrieves the tree structure of a folder in the repository.

For Public Code Graphs (No Account Required)

You can interact with public graphs from DeepGraph:

  1. Find any public repository on deepgraph.co
  2. Use the repository reference (e.g., username/repository-name)

Installation using npx

Add the following configuration to your MCP client (CodeGPT Extension, Cursor, Copilot, Claude Desktop, Windsurf, etc.):

{
   "mcpServers": {
      "Deep Graph MCP": {
         "command": "npx",
         "args": ["-y" , "mcp-code-graph@latest", 
         "username/repository-name",  // DeepGraph repository URL
         "username2/repository-name2" // Add more repositories if needed
        ]
      }
   }
}

For Private Graphs (CodeGPT Account Required)

Before using the CodeGPT MCP Server with private graphs, ensure you have:

  1. A CodeGPT account (sign up at app.codegpt.co)
  2. Uploaded a repository to Code Graph
  3. Get your API Key from CodeGPT API Keys page (required).
  4. Get your Organization ID (optional) and Graph ID (optional).

Installation with npx

Add the following configuration to your MCP client (CodeGPT Extension, Cursor, Copilot, Claude Desktop, Windsurf, etc.):

{
   "mcpServers": {
      "Deep Graph MCP": {
         "command": "npx",
         "args": ["-y" , "mcp-code-graph@latest", 
         "CODEGPT_API_KEY",
         "CODEGPT_ORG_ID",
         "CODEGPT_GRAPH_ID"
        ]
      }
   }
}

CLI Providers

Adding to Gemini CLI

Add the JSON configuration to your settings.json file:

<video src="https://github.com/user-attachments/assets/22f601dd-0564-46ac-8973-161de3017e34" controls autoplay></video>

Gemini CLI uses settings.json files for persistent configuration. There are two locations for these files:

  • User settings file: Location: ~/.gemini/settings.json (where ~ is your home directory). Scope: Applies to all Gemini CLI sessions for the current user.

  • Project settings file: Location: .gemini/settings.json within your project's root directory. Scope: Applies only when running Gemini CLI from that specific project. Project settings override user settings.

Adding to Claude Code

Follow these steps to integrate Deep Graph MCP Server with Claude Code.

Quick Setup

For Private Graphs

claude mcp add "Deep Graph MCP" npx -- -y mcp-code-graph@latest CODEGPT_API_KEY CODEGPT_ORG_ID CODEGPT_GRAPH_ID

For Public Graphs

claude mcp add "Deep Graph MCP" npx -- -y mcp-code-graph@latest username/repository-name

For team sharing, add the -s project flag:

claude mcp add -s project "Deep Graph MCP" npx -- -y mcp-code-graph@latest CODEGPT_API_KEY CODEGPT_ORG_ID CODEGPT_GRAPH_ID
# or for public graphs
claude mcp add -s project "Deep Graph MCP" npx -- -y mcp-code-graph@latest username/repository-name username2/repository-name

Verification

# Verify installation
claude mcp list

# Get server details
claude mcp get "Deep Graph MCP"

Advanced Workflows with Claude Code Custom Commands

Claude Code supports custom slash commands that combine multiple MCP Code Graph tools for comprehensive analysis workflows.

Setup

Copy the commands directory from this repository to your project root:

cp -r .claude/ /path/to/your/project/

Commit to your project's git:

git add .claude/commands/
git commit -m "Add custom Claude Code commands for Deep Graph MCP"

Available Commands

Repository-wide analysis commands (no parameters needed):

/project:analyze-architecture          # Complete architectural overview
/project:security-audit               # Comprehensive security analysis
/project:test-coverage-analyzer       # Test coverage and quality analysis
/project:technical-debt-analyzer      # Technical debt assessment
/project:api-ecosystem-analyzer       # Complete API ecosystem analysis
/project:repository-onboarding        # Full repository onboarding guide

Component-specific commands (require parameters):

/project:migration-planner [component/technology]     # Smart migration planning
/project:performance-optimizer [component/function]   # Performance optimization
/project:component-onboarding [component/feature]     # Component-specific training

Usage Examples

/project:analyze-architecture
/project:migration-planner React to Vue.js
/project:performance-optimizer DatabaseService.getUserData
/project:component-onboarding authentication system

📈 Star History

Star History Chart

Support

For support and feedback:

License

MIT License

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
E2B

E2B

Using MCP to run code via e2b.

Official
Featured