Aidex
AiDex is an MCP server that provides AI programming assistants with instant access to the entire codebase. It enables fast and precise code search through a persistent pre-built index, supports 11 programming languages, includes 28 tools, and can significantly reduce the waste of the AI context window.
2.5 points
4.9K

What is AiDex?

AiDex is an intelligent code indexing tool designed specifically for AI programming assistants. It pre-parses and indexes your entire codebase. When the AI needs to search for code, it can directly query the index instead of scanning all files, significantly reducing context usage.

How to use AiDex?

After installing AiDex, it will automatically register with your AI assistant. You only need to let the AI assistant index your project once, and all subsequent code searches will be conducted through AiDex without the need to rescan files.

Applicable Scenarios

Suitable for any scenario where an AI assistant needs to handle large codebases, especially when you often ask questions like 'Where is this function defined?', 'What methods does this class have?', 'What have I modified recently?' etc.

Main Features

Intelligent Code Indexing
Use the Tree-sitter parser to truly understand the code structure. Only index identifiers (class names, method names, variable names) and ignore noise in comments and strings.
28 Integrated Tools
Provide 28 tools such as search, signature extraction, project overview, cross-project linking, global search, session notes, task management, and screenshots in one server.
Time-filtered Search
Search for code changes within a specific time range, such as 'in the last 2 hours'.
Global Cross-project Search
Search simultaneously across all indexed projects to answer questions like 'Have I ever implemented a transparent window feature?'
Session Notes and Task Management
Leave notes between sessions and manage task to-dos. All content is stored together with the code index.
LLM-optimized Screenshots
Automatically scale and reduce colors to save up to 95% of token usage, specifically optimized for AI context.
Interactive Browser Viewer
Visually browse the project structure, file signatures, and tasks in the browser, supporting real-time reloading.
Support for 11 Programming Languages
Supports C#, TypeScript, JavaScript, Rust, Python, C, C++, Java, Go, PHP, and Ruby.
Advantages
Save 80% of the AI context window: Only about 50 tokens are used for a single search, while traditional grep requires over 2000 tokens.
Persistent index: The index is maintained between sessions, eliminating the need for repeated scanning.
Precise search: Only search for real code identifiers, avoiding noise in comments and strings.
Fast response: Queries are completed within 1 - 10 milliseconds, even for large projects.
Zero dependencies: Uses a single SQLite file database without the need for external services.
Cross-platform support: Supports Windows, macOS, and Linux.
Compatible with all major AI assistants: Such as Claude, Cursor, Windsurf, Gemini CLI, and VS Code Copilot.
Limitations
Requires initial indexing time: It takes time to index a project for the first time (about 1 second per 1000 files).
Only supports specific languages: Currently supports 11 languages and does not support all programming languages.
Requires AI assistants to support the MCP protocol: Older versions or AI assistants that do not support MCP cannot be used.
Index files occupy disk space: Each project creates an .aidex directory to store the index.

How to Use

Install AiDex
Install AiDex globally via npm. The installation process will automatically detect and configure your AI assistant.
Configure the AI Assistant to Use AiDex
After installation, AiDex will automatically configure most AI assistants. If manual configuration is required, refer to the configuration examples in the README.
Add Usage Instructions to the AI Assistant
Add AiDex's usage instructions to the AI assistant's system prompt to tell it when to use AiDex instead of grep.
Index Your Project
Let the AI assistant index the current project in the AI chat or manually run the initialization command.
Start Using
Now when the AI needs to search for code, it will automatically use AiDex instead of grep.

Usage Examples

Find the Definition Location of a Function
When the AI needs to know where a function or class is defined, use AiDex to quickly locate it.
Understand the File Structure
Quickly understand what classes and methods a file contains without reading the entire file.
Track Recent Changes
Find code changes within a recent period to understand the project progress.
Cross-project Search
Search for a specific feature or pattern across all indexed projects.
Pass Information between Sessions
Leave notes at the end of the current session for reference in the next session.
Optimize Screenshots
Take screenshots of error messages or UI interfaces for AI analysis while minimizing token usage.

Frequently Asked Questions

What is the difference between AiDex and ordinary grep search?
Which AI assistants does AiDex support?
How much disk space does the index occupy?
How to update the index when the code changes?
Can screenshot optimization really save 95% of tokens?
What should I do if my project language is not in the supported list?
Will AiDex affect the performance of my AI assistant?
How to uninstall AiDex?

Related Resources

GitHub Repository
AiDex's source code, issue tracking, and contribution guidelines
npm Package Page
AiDex's npm package information and installation instructions
GitHub Discussions
Community discussions, question answering, and feature suggestions
Model Context Protocol Official Website
Official documentation and specifications of the MCP protocol
Tree-sitter Parser
The code parser technology used by AiDex

Installation

Copy the following command to your Client for configuration
{
  "mcpServers": {
    "aidex": {
      "type": "stdio",
      "command": "aidex",
      "env": {}
    }
  }
}

{
  "mcpServers": {
    "aidex": {
      "command": "aidex"
    }
  }
}
Note: Your key is sensitive information, do not share it with anyone.

Alternatives

A
Airweave
Airweave is an open - source context retrieval layer for AI agents and RAG systems. It connects and synchronizes data from various applications, tools, and databases, and provides relevant, real - time, multi - source contextual information to AI agents through a unified search interface.
Python
7.2K
5 points
V
Vestige
Vestige is an AI memory engine based on cognitive science. By implementing 29 neuroscience modules such as prediction error gating, FSRS - 6 spaced repetition, and memory dreaming, it provides long - term memory capabilities for AI. It includes a 3D visualization dashboard and 21 MCP tools, runs completely locally, and does not require the cloud.
Rust
4.9K
4.5 points
M
Moltbrain
MoltBrain is a long-term memory layer plugin designed for OpenClaw, MoltBook, and Claude Code, capable of automatically learning and recalling project context, providing intelligent search, observation recording, analysis statistics, and persistent storage functions.
TypeScript
4.4K
4.5 points
B
Bm.md
A feature-rich Markdown typesetting tool that supports multiple style themes and platform adaptation, providing real-time editing preview, image export, and API integration capabilities
TypeScript
4.9K
5 points
S
Security Detections MCP
Security Detections MCP is a server based on the Model Context Protocol that allows LLMs to query a unified security detection rule database covering Sigma, Splunk ESCU, Elastic, and KQL formats. The latest version 3.0 is upgraded to an autonomous detection engineering platform that can automatically extract TTPs from threat intelligence, analyze coverage gaps, generate SIEM-native format detection rules, run tests, and verify. The project includes over 71 tools, 11 pre-built workflow prompts, and a knowledge graph system, supporting multiple SIEM platforms.
TypeScript
5.2K
4 points
P
Paperbanana
Python
6.4K
5 points
B
Better Icons
An MCP server and CLI tool that provides search and retrieval of over 200,000 icons, supports more than 150 icon libraries, and helps AI assistants and developers quickly obtain and use icons.
TypeScript
6.1K
4.5 points
A
Assistant Ui
assistant - ui is an open - source TypeScript/React library for quickly building production - grade AI chat interfaces, providing composable UI components, streaming responses, accessibility, etc., and supporting multiple AI backends and models.
TypeScript
7.6K
5 points
N
Notion Api MCP
Certified
A Python-based MCP Server that provides advanced to-do list management and content organization functions through the Notion API, enabling seamless integration between AI models and Notion.
Python
21.5K
4.5 points
G
Gitlab MCP Server
Certified
The GitLab MCP server is a project based on the Model Context Protocol that provides a comprehensive toolset for interacting with GitLab accounts, including code review, merge request management, CI/CD configuration, and other functions.
TypeScript
24.7K
4.3 points
D
Duckduckgo MCP Server
Certified
The DuckDuckGo Search MCP Server provides web search and content scraping services for LLMs such as Claude.
Python
73.3K
4.3 points
M
Markdownify MCP
Markdownify is a multi-functional file conversion service that supports converting multiple formats such as PDFs, images, audio, and web page content into Markdown format.
TypeScript
34.6K
5 points
F
Figma Context MCP
Framelink Figma MCP Server is a server that provides access to Figma design data for AI programming tools (such as Cursor). By simplifying the Figma API response, it helps AI more accurately achieve one - click conversion from design to code.
TypeScript
63.7K
4.5 points
U
Unity
Certified
UnityMCP is a Unity editor plugin that implements the Model Context Protocol (MCP), providing seamless integration between Unity and AI assistants, including real - time state monitoring, remote command execution, and log functions.
C#
32.5K
5 points
G
Gmail MCP Server
A Gmail automatic authentication MCP server designed for Claude Desktop, supporting Gmail management through natural language interaction, including complete functions such as sending emails, label management, and batch operations.
TypeScript
21.1K
4.5 points
C
Context7
Context7 MCP is a service that provides real-time, version-specific documentation and code examples for AI programming assistants. It is directly integrated into prompts through the Model Context Protocol to solve the problem of LLMs using outdated information.
TypeScript
97.5K
4.7 points
AIBase
Zhiqi Future, Your AI Solution Think Tank
© 2026AIBase