GrepAI
Semantic Search & Call Graphs for AI Agents (100% Local)
What is GrepAI?
GrepAI is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to semantic search & call graphs for ai agents (100% local)
Semantic Search & Call Graphs for AI Agents (100% Local)
This server falls under the Developer Tools category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- Semantic Search & Call Graphs for AI Agents (100% Local)
Use Cases
Maintainer
Works with
Installation
Manual Installation
npx grepaiConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use GrepAI
GrepAI is a 100% local semantic code search tool and MCP server that lets AI agents find code by meaning rather than by exact text matching — for example, searching for 'authentication logic' finds the relevant functions even if they aren't named that way. It also generates call graphs so agents can trace which functions call a given function before making changes, preventing accidental regressions. Because all indexing and search runs locally using embeddings from Ollama, LM Studio, or OpenAI, no code ever leaves the developer's machine, making it suitable for proprietary codebases.
Prerequisites
- GrepAI binary installed (via Homebrew on macOS, or the universal install script on Linux/macOS)
- An embedding provider: Ollama with the nomic-embed-text model (recommended, free), LM Studio, or an OpenAI API key
- An MCP-compatible AI client: Claude Code, Cursor, or Windsurf
- A codebase to index (any language)
Install GrepAI
Install the GrepAI binary using Homebrew on macOS, or the universal shell script on Linux and macOS.
# macOS (Homebrew)
brew install yoanbernabeu/tap/grepai
# Linux / macOS (universal)
curl -sSL https://raw.githubusercontent.com/yoanbernabeu/grepai/main/install.sh | shSet up an embedding provider
GrepAI requires a local or remote embedding model. Ollama with nomic-embed-text is the default and fully offline option.
# Install Ollama (if not already installed): https://ollama.com
ollama pull nomic-embed-textInitialize GrepAI in your project
Navigate to your project directory and run the init command. GrepAI will index the codebase and start a file watcher to keep the index up to date as you edit.
cd /path/to/your/project
grepai initAdd GrepAI as an MCP server in your client config
Configure your AI client to use GrepAI as an MCP server. It starts in stdio mode and requires no network ports.
{
"mcpServers": {
"grepai": {
"command": "grepai",
"args": ["mcp", "--project-dir", "/path/to/your/project"]
}
}
}Use semantic search and call graphs in the AI client
Ask your AI assistant to find code by intent or to trace call graphs before making changes. GrepAI returns ranked, semantically relevant results without sending data to external services.
GrepAI Examples
Client configuration
Claude Code or Cursor config to launch GrepAI as a local MCP server for semantic code search in a specific project.
{
"mcpServers": {
"grepai": {
"command": "grepai",
"args": ["mcp", "--project-dir", "/Users/yourname/projects/my-app"]
}
}
}Prompts to try
Prompts that leverage GrepAI's semantic search and call graph capabilities for code navigation and safe refactoring.
- "Find all code related to user authentication and session management in this project"
- "Show me the call graph for the processPayment function — what else calls it?"
- "Search for code that handles file upload validation"
- "Before I refactor the database connection pool, find every function that depends on it"
- "Find code that deals with rate limiting or request throttling"Troubleshooting GrepAI
grepai init fails with 'embedding provider not reachable'
Ensure Ollama is running (ollama serve) and that the nomic-embed-text model is pulled (ollama pull nomic-embed-text). If using OpenAI embeddings, set the OPENAI_API_KEY environment variable before running grepai init.
Search returns irrelevant results after code changes
GrepAI includes a file watcher that re-indexes changed files automatically. If the watcher is not running, re-run grepai init in the project directory to rebuild the full index.
MCP client cannot find the grepai binary
Use the full absolute path to the binary in your MCP config args (e.g. '/opt/homebrew/bin/grepai'). Run 'which grepai' in your terminal to find the correct path.
Frequently Asked Questions about GrepAI
What is GrepAI?
GrepAI is a Model Context Protocol (MCP) server that semantic search & call graphs for ai agents (100% local) It connects AI assistants to external tools and data sources through a standardized interface.
How do I install GrepAI?
Follow the installation instructions on the GrepAI GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.
Which AI clients work with GrepAI?
GrepAI works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is GrepAI free to use?
Yes, GrepAI is open source and available under the MIT license. You can use it freely in both personal and commercial projects.
GrepAI Alternatives — Similar Developer Tools Servers
Looking for alternatives to GrepAI? 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 GrepAI 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 GrepAI?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.