
najva-ai/zoekt-mcp
Developer tools이 페이지는 AI로 자동 번역되었습니다. 기술적인 세부 사항은 원문을 확인하세요. 원문 보기
Zoekt를 위한 MCP 서버
개요
Zoekt에 의해 구동되는 코드 검색 기능을 제공하는 모델 Context Protocol (MCP) 서버, Sourcegraph에 의해 사용되는 인덱스 코드 검색 엔진. 이 MCP 서버는 Zoekt, 코드 저장소에 최적화 된 텍스트 검색 엔진과 통합합니다. Zoekt는 큰 codebase를 통해 검색에 대한 trigram 기반 색인을 제공하며, 코드 패턴을 발견하고 이해하는 AI 조수에 적합합니다. - : Zoekt의 trigram 인덱싱을 사용하여 코드베이스의 검색 - : regex 패턴, 파일 필터, 언어 필터 및 boolean 연산자에 대한 지원 - : 이름에 의한 저장소 찾기 및 구조 탐색 - : 검색 저장소 파일 및 디렉토리 - : 가이드 검색 프롬프트와 LLM 통합 설계 - : 실행 Zoekt 검색 서버에 액세스해야합니다. 설정 지침에 대한 Zoekt 문서를 참조하십시오.
개요(AI 번역)
Zoekt에 의해 구동되는 코드 검색 기능을 제공하는 모델 Context Protocol (MCP) 서버, Sourcegraph에 의해 사용되는 인덱스 코드 검색 엔진.
내용 표
- 개요
- 특징
- 필수
- 설치
- UV 사용 (추천)
- pip 사용
- Docker 사용
- 구성
- 필수 환경 변수
- 옵션 환경 변수
- AI Tools 사용
- 커서
- MCP 도구
- 검색
- 검색 prompt guide 사이트 맵
- 개발
- 안감 및 서식
개요
이 MCP 서버는 Zoekt, 코드 저장소에 최적화 된 텍스트 검색 엔진과 통합합니다. Zoekt는 큰 codebase를 통해 검색에 대한 trigram 기반 색인을 제공하며, 코드 패턴을 발견하고 이해하는 AI 조수에 적합합니다.
특징
- ** 코드 검색**: Zoekt의 trigram indexing을 사용하여 codebases의 검색
- Advanced Query Language: regex 패턴, 파일 필터, 언어 필터 및 불린 연산자 지원
- Repository Discovery: 이름과 구조를 탐구하여 저장소 찾기 -Content Fetching: 저장소 파일 및 디렉토리
- AI 통합: LLM 통합을 위한 설계
이 페이지는 AI로 자동 번역되었습니다. 기술적인 세부 사항은 원문을 확인하세요.
README
원문 README의 일부입니다. 원문 보기.
Zoekt MCP Server
A Model Context Protocol (MCP) server that provides code search capabilities powered by Zoekt, the indexed code search engine used by Sourcegraph.
Table of Contents
- Overview
- Features
- Prerequisites
- Installation
- Configuration
- Usage with AI Tools
- MCP Tools
- Development
Overview
This MCP server integrates with Zoekt, a text search engine optimized for code repositories. Zoekt provides trigram-based indexing for searches across large codebases, making it suitable for AI assistants that need to find and understand code patterns.
Features
- Code Search: Search across codebases using Zoekt’s trigram indexing
- Advanced Query Language: Support for regex patterns, file filters, language filters, and boolean operators
- Repository Discovery: Find repositories by name and explore their structure
- Content Fetching: Browse repository files and directories
- AI Integration: Designed for LLM integration with guided search prompts
Prerequisites
- Zoekt Instance: You need access to a running Zoekt search server. See the Zoekt documentation for setup instructions.
- Python 3.10+: Required for running the MCP server
- UV (optional): Modern Python package manager for easier dependency management
Installation
Using UV (recommended)
# Install dependencies
uv sync
# Run the server
uv run python src/main.py
Using pip
# Create virtual environment
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
# Install package
pip install -e .
# Run the server
python src/main.py
Using Docker
# Build the image
docker build -t zoekt-mcp .
# Run the container with default ports
docker run -p 8000:8000 -p 8080:8080 \
-e ZOEKT_API_URL=http://your-zoekt-instance \
zoekt-mcp
# Or run with custom ports
docker run -p 9000:9000 -p 9080:9080 \
-e ZOEKT_API_URL=http://your-zoekt-instance \
-e MCP_SSE_PORT=9000 \
-e MCP_STREAMABLE_HTTP_PORT=9080 \
zoekt-mcp
Configuration
Required Environment Variables
ZOEKT_API_URL: URL of your Zoekt search instance
Optional Environment Variables
MCP_SSE_PORT: SSE server port (default: 8000)MCP_STREAMABLE_HTTP_PORT: HTTP server port (default: 8080)
Usage with AI Tools
Cursor
설치
docker run -p 8000:8000 -p 8080:8080 \설정
{
"mcpServers": {
"zoekt": {
"url": "http://localhost:8080/zoekt/mcp/"
}
}
}