SocratiCode
Enterprise-grade (40m+ LOC) codebase intelligence, zero-setup, local & private Plugin/Skill/Extension or MCP: hybrid semantic search, polyglot dependency graphs, symbol-level impact analysis & call-flow, interactive HTML viewer, cross-project & branc
What is SocratiCode?
SocratiCode is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to enterprise-grade (40m+ loc) codebase intelligence, zero-setup, local & private plugin/skill/extension or mcp: hybrid semantic search, polyglot dependency graphs, symbol-level impact analysis & call-fl...
Enterprise-grade (40m+ LOC) codebase intelligence, zero-setup, local & private Plugin/Skill/Extension or MCP: hybrid semantic search, polyglot dependency graphs, symbol-level impact analysis & call-flow, interactive HTML viewer, cross-project & branc
This server falls under the Developer Tools category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- Enterprise-grade (40m+ LOC) codebase intelligence, zero-setu
Use Cases
Maintainer
Works with
Installation
NPM
npx -y socraticodeManual Installation
npx -y socraticodeConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use SocratiCode
SocratiCode is a zero-setup, privacy-first codebase intelligence MCP server that enables AI assistants to deeply understand large codebases — up to 40M+ lines of code — without sending source code to external services. It builds a local hybrid search index (dense semantic embeddings + BM25 keyword search) and a polyglot dependency graph supporting 18+ languages, then exposes 21 tools for semantic search, symbol-level impact analysis, call-flow tracing, circular dependency detection, and interactive visualization. Engineering teams use it to onboard AI assistants to massive codebases quickly and safely, enabling cross-project analysis, blast-radius queries, and dependency graph exploration entirely on-device.
Prerequisites
- Node.js 18+ for the npx launcher
- Docker Desktop running (SocratiCode uses Docker to manage its Qdrant vector database and optionally Ollama for local embeddings)
- An MCP client such as Claude Desktop, Claude Code, Cursor, or Windsurf
- Optional: an OpenAI API key (OPENAI_API_KEY) or Google API key (GOOGLE_API_KEY) for cloud embedding providers instead of local Ollama
- Optional: a Qdrant Cloud account if you prefer an external vector database over the local Docker-managed instance
Add SocratiCode to your MCP client config
No global install required — just add the npx entry to your MCP host's config file. SocratiCode downloads on first use and manages its own Docker-based backend services.
{
"mcpServers": {
"socraticode": {
"command": "npx",
"args": ["-y", "socraticode"]
}
}
}Configure the embedding provider
By default SocratiCode uses Ollama running in Docker for fully local embeddings. To use OpenAI or Google embeddings instead, set environment variables in your MCP config.
{
"mcpServers": {
"socraticode": {
"command": "npx",
"args": ["-y", "socraticode"],
"env": {
"EMBEDDING_PROVIDER": "openai",
"EMBEDDING_MODEL": "text-embedding-3-small",
"OPENAI_API_KEY": "sk-your-key-here"
}
}
}
}Index your codebase
Open your AI assistant and ask it to index the current project. SocratiCode will crawl the workspace, generate embeddings, and build the dependency graph. Large codebases may take several minutes; indexing is resumable if interrupted.
Monitor indexing progress
Check the indexing status by asking your AI assistant to report progress. The codebase_status tool returns the current number of indexed files, embedding progress, and any errors.
Build the dependency graph
After indexing completes, ask the assistant to build the code graph. This performs polyglot static analysis to construct the import/call/dependency graph for impact analysis.
Enable branch-aware indexing for multi-branch workflows
Set SOCRATICODE_BRANCH_AWARE=true to maintain separate vector collections per git branch. Each branch gets its own index, so searches always reflect the current branch's code.
{
"mcpServers": {
"socraticode": {
"command": "npx",
"args": ["-y", "socraticode"],
"env": {
"SOCRATICODE_BRANCH_AWARE": "true",
"EMBEDDING_PROVIDER": "ollama"
}
}
}
}SocratiCode Examples
Client configuration
Minimal Claude Desktop MCP configuration for SocratiCode using the default local Ollama embedding provider. Docker must be running.
{
"mcpServers": {
"socraticode": {
"command": "npx",
"args": ["-y", "socraticode"],
"env": {
"EMBEDDING_PROVIDER": "ollama",
"OLLAMA_MODE": "auto",
"RESPECT_GITIGNORE": "true"
}
}
}
}Prompts to try
These prompts leverage SocratiCode's 21 tools for search, impact analysis, and graph visualization.
- "Index this codebase"
- "Search for how authentication is handled across the codebase"
- "What files and functions depend on the UserService class?"
- "Are there any circular dependencies in the src directory?"
- "What is the blast radius if I rename the validateToken function?"
- "Show me the dependency graph for the payments module as an interactive HTML viewer"
- "Trace the call flow from the API gateway down to the database layer"Troubleshooting SocratiCode
SocratiCode fails to start with 'Docker not found' or container errors
Docker Desktop must be running before the MCP server starts — it launches Qdrant and optionally Ollama as containers on first run. Start Docker Desktop, wait for it to be fully ready, then restart your MCP client.
Indexing stalls or restarts repeatedly on a large codebase
SocratiCode supports resumable, checkpointed indexing, so a restart continues from where it left off. If it keeps stalling, increase Docker's memory allocation (8 GB+ recommended for large codebases) and check MAX_FILE_SIZE_MB — files larger than the limit (default 5 MB) are skipped and may indicate binary files slipping through .gitignore.
Semantic search returns unrelated results
The embedding model affects search quality significantly. The default Ollama model is optimized for general text; for code, try switching to EMBEDDING_PROVIDER=openai with EMBEDDING_MODEL=text-embedding-3-small, then re-index the codebase with `codebase_remove` followed by `codebase_index` to rebuild the vector collection with the new model.
Frequently Asked Questions about SocratiCode
What is SocratiCode?
SocratiCode is a Model Context Protocol (MCP) server that enterprise-grade (40m+ loc) codebase intelligence, zero-setup, local & private plugin/skill/extension or mcp: hybrid semantic search, polyglot dependency graphs, symbol-level impact analysis & call-flow, interactive html viewer, cross-project & branc It connects AI assistants to external tools and data sources through a standardized interface.
How do I install SocratiCode?
Install via npm with the command: npx -y socraticode. Then add the server configuration to your AI client's JSON config file (e.g., claude_desktop_config.json or .cursor/mcp.json).
Which AI clients work with SocratiCode?
SocratiCode works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is SocratiCode free to use?
Yes, SocratiCode is open source and available under the AGPL 3.0 license. You can use it freely in both personal and commercial projects.
SocratiCode Alternatives — Similar Developer Tools Servers
Looking for alternatives to SocratiCode? Here are other popular developer tools servers you can use with Claude, Cursor, and VS Code.
Ecc
★ 188.2kThe agent harness performance optimization system. Skills, instincts, memory, security, and research-first development for Claude Code, Codex, Opencode, Cursor and beyond.
Javaguide
★ 155.8kJava 面试 & 后端通用面试指南,覆盖计算机基础、数据库、分布式、高并发、系统设计与 AI 应用开发
Gemini CLI
★ 104.5kA secure MCP server that wraps the Google Gemini CLI, allowing clients to query Gemini models using local OAuth sessions without requiring an API key. It provides tools for model interaction and diagnostics with built-in protection against command in
Awesome MCP Servers
★ 87.3k⭐ Curated list of Model Context Protocol (MCP) servers - tools that extend Claude Desktop, Cursor, Windsurf, and other MCP clients with custom capabilities.
MCP Servers
★ 86.0kModel Context Protocol Servers
CC Switch
★ 77.5kA cross-platform desktop All-in-One assistant for Claude Code, Codex, OpenCode, OpenClaw, Gemini CLI & Hermes Agent. Only official website: ccswitch.io
Browse More Developer Tools MCP Servers
Explore all developer tools servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.
Set Up SocratiCode in Your Editor
Choose your AI client for step-by-step setup instructions.
Quick Config Preview
Add this to your claude_desktop_config.json or .cursor/mcp.json
Ready to use SocratiCode?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.