repo.search
Search indexed repository chunks using BM25 keyword matching to retrieve ranked results with file location and snippet.
Instructions
Run BM25 full-text search over indexed repository chunks. Returns ranked hits with file path, line range, snippet, and matched terms. Run repo.refresh_index first if the index is not yet built.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mode | No | Search mode — only 'bm25' is supported in v1. | |
| query | Yes | Search terms (BM25 keyword matching). | |
| top_k | No | Maximum number of results to return. | |
| file_glob | No | Glob pattern to restrict search to matching files (e.g. 'src/**/*.py'). | |
| path_prefix | No | Path prefix to restrict search scope (e.g. 'src/repo_mcp/'). |