
brainwires/project-rag
Developer toolsこのページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。 原文を見る
大規模なコードベースを理解するための強力なRAG(Retrieval-Augmented generation)機能を備えたAIアシスタントを提供するRustベースのモデルコンテキストプロトコル(MCP)サーバー.
概要
大規模なコードベースを理解するための強力なRAG(Retrieval-Augmented generation)機能を備えたAIアシスタントを提供するRustベースのモデルコンテキストプロトコル(MCP)サーバー。 このMCPサーバーは、AIアシスタントが、大規模なプロジェクトを効率的に検索し理解できるようにします。 - コードファイルのセマンティック埋め込みの作成 - ローカルベクトルデータベースにそれらを保存 - 迅速なセマンティック検索機能を提供します - 効率性のための増分更新をサポート - : すべての処理は、fastembed-rs(APIキーは必要ありません)を使用してローカルで行われます - : 最適な結果を得るために、Reciprocal Rank Fusion(RRF)を使用して、ベクターの類似性を組み合わせる - : ツリーシッターを使用して、セマンティックユニット(関数、クラス、メソッド)を12言語で抽出する - : コード、ドキュメンテーション(PDF→Markdown変換付き)、およびコンフィギュレーションファイルを含む40以上のファイルタイプをインデックス化 - : スマートなオンデマンドインデックス(デフォルト: インデックス10)でコミット履歴を検索します.
概要(AI 翻訳)
大規模なコードベースを理解するための強力なRAG(Retrieval-Augmented generation)機能を備えたAIアシスタントを提供するRustベースのモデルコンテキストプロトコル(MCP)サーバー。
概要
このMCPサーバーでは、AIアシスタントが大規模なプロジェクトを効率的に検索し理解できるようにします。
- コードファイルのセマンティック埋め込みの作成
- ローカルベクターデータベースに保存する
- 迅速なセマンティック検索機能の提供
- 効率性のためのサポート増分更新
##特徴
- ローカルファースト: すべての処理はfastembed-rs (必須 API キー無し)を使用してローカルで起こります
- ハイブリッド検索:最適な結果を得るために、レシプロカル・ランク・フュージョン(RRF)を使用して、ベクターの類似性をBM25キーワードと組み合わせる
- AST-Based Chunking:12の言語でセマンティックユニット(機能、クラス、メソッド)を抽出するためにツリーシッターを使用する
- 包括的なファイルサポート:コード、ドキュメント(PDF→Markdown変換付き)、設定ファイルを含む40以上のファイルタイプをインデックス化 -Git History Search: スマートオンデマンドインデックスでコミット履歴を検索 (デフォルト: 10 コミット、必要に応じてインデックスのみ) -マルチプロジェクトサポート:プロジェクトフィルタリングと同時に複数のコードベースをインデックスとクエリ
このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。
README
以下は原文 README の抜粋です。原文を見る。
Project RAG - MCP Server for Code Understanding
A Rust-based Model Context Protocol (MCP) server that provides AI assistants with powerful RAG (Retrieval-Augmented Generation) capabilities for understanding massive codebases.
Overview
This MCP server enables AI assistants to efficiently search and understand large projects by:
- Creating semantic embeddings of code files
- Storing them in a local vector database
- Providing fast semantic search capabilities
- Supporting incremental updates for efficiency
Features
- Local-First: All processing happens locally using fastembed-rs (no API keys required)
- Hybrid Search: Combines vector similarity with BM25 keyword matching using Reciprocal Rank Fusion (RRF) for optimal results
- AST-Based Chunking: Uses Tree-sitter to extract semantic units (functions, classes, methods) for 12 languages
- Comprehensive File Support: Indexes 40+ file types including code, documentation (with PDF→Markdown conversion), and configuration files
- Git History Search: Search commit history with smart on-demand indexing (default: 10 commits, only indexes deeper as needed)
- Multi-Project Support: Index and query multiple codebases simultaneously with project filtering
- Smart Indexing: Automatically performs full indexing for new codebases or incremental updates for previously indexed ones
- Cross-Process Locking: Filesystem-based locks prevent multiple processes (e.g., multiple Claude Code sessions) from indexing the same codebase simultaneously
- Concurrent Access Protection: Safe lock management prevents index corruption when multiple agents try to index simultaneously
- Stable Embedded Database: LanceDB vector database (default, no external dependencies) with optional Qdrant support
- Language Detection: Automatic detection of 40+ file types (programming languages, documentation formats, and config files)
- Advanced Filtering: Search by file type, language, or path patterns
- Respects .gitignore: Automatically excludes ignored files during indexing
- Never indexes secrets:
.envfiles, private keys, certificates and.aws//.ssh/contents are always excluded - Code Navigation: Find definitions, references, and call graphs (lightweight LSP-like features)
- Adaptive Search Thresholds: Automatically lowers similarity threshold when no results found (0.7 → 0.6 → 0.5 → 0.4 → 0.3)
インストール
docker run -p 6333:6333 -p 6334:6334 \設定
{
"mcpServers": {
"project-rag": {
"command": "/absolute/path/to/project-rag/target/release/project-rag",
"env": {
"RUST_LOG": "info"
}
}
}
}