LC

luotocompany/cursor-local-indexing

Developer tools

このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。 原文を見る

33 stars 11 forks 品質 37 トレンド 11

MCP サーバーとして公開された Cursor の ChromaDB 搭載ローカルインデックス化のサポート

概要

ChromaDBを使用してコードベースをインデックス化し、Cursor のようなツールの MCP (Model Context Protocol) サーバを介して、セマンティックな検索ツールを提供します。 2. .env.example をコピーして .env ファイルを作成します。 5. ローカル検索サーバーを使用するCursorの設定:~/.cursor/mcp.jsonの作成または編集: 6. 変更を加えるためにカーソルIDEを再起動します。 サーバは、指定されたプロジェクトをインデックス化し始めます。これらのプロジェクトがアクティブなときに、Cursor内でのコード検索を使用できます。 7. インデックスとして設定したプロジェクトを開きます。 .cursorrulesファイルを作成し、以下を追加します。 8. Cursor Agent モードを使用して起動し、ローカル ベクトル検索を実行します。!

概要(AI 翻訳)

実験的な Python ベースのサーバーで、locally は、ChromaDB を使用してコードベースをインデックス化し、Cursor のようなツールの MCP (Model Context Protocol) サーバを介してセマンティックな検索ツールを提供します。

セットアップ

  1. リポジトリをクローンして入力します。

  2. [.env.example]をコピーして[[.env.example]ファイルを作成する:

  3. [.env ファイルを構成します。

例:

4。 インデックスサーバーを開始します。

5。 ローカル検索サーバーを使用するCursorの設定: [~/.cursor/mcp.jsonを作成または編集する:

  1. 変更を加えるためにカーソルIDEを再起動します。

サーバは、指定されたプロジェクトをインデックス化し始めます。これらのプロジェクトがアクティブなときに、Cursor内でのコード検索を使用できます。

  1. インデックスとして設定したプロジェクトを開きます。

.cursorrulesファイルを作成し、次のファイルを追加します。

  1. Cursor Agent モードを使用して起動し、ローカル ベクトル検索を実行します。!

このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。

README

Local Code Indexing for Cursor

An experimental Python-based server that locally indexes codebases using ChromaDB and provides a semantic search tool via an MCP (Model Context Protocol) server for tools like Cursor.

Setup

  1. Clone and enter the repository:

    git clone 
    cd cursor-local-indexing
    
  2. Create a .env file by copying .env.example:

    cp .env.example .env
    
  3. Configure your .env file:

    PROJECTS_ROOT=~/your/projects/root    # Path to your projects directory
    FOLDERS_TO_INDEX=project1,project2    # Comma-separated list of folders to index
    

    Example:

    PROJECTS_ROOT=~/projects
    FOLDERS_TO_INDEX=project1,project2
    
  4. Start the indexing server:

    docker-compose up -d
    
  5. Configure Cursor to use the local search server: Create or edit ~/.cursor/mcp.json:

    {
      "mcpServers": {
        "workspace-code-search": {
          "url": "http://localhost:8978/sse"
        }
      }
    }
    
  6. Restart Cursor IDE to apply the changes.

The server will start indexing your specified projects, and you’ll be able to use semantic code search within Cursor when those projects are active.

  1. Open a project that you configured as indexed.

Create a .cursorrules file and add the following:


For any request, use the @search_code tool to check what the code does.
Prefer that first before resorting to command line grepping etc.

  1. Start using the Cursor Agent mode and see it doing local vector searches!
GitHub で README 全文を見る

インストール

This server does not publish a one-line install command.

Open the repository installation guide MCP 初心者?mcpskill.org のガイドから始めましょう →

設定

{ "mcpServers": { "workspace-code-search": { "url": "http://localhost:8978/sse" } } }