search
Find code by meaning when you don't know the exact name to grep for. Use natural-language queries to locate files ranked by semantic similarity.
Instructions
Find code by meaning when you don't know the exact name to grep for.
Use this first for concept-level questions — "where is rate limiting
handled", "what validates the config", "code that retries failed
requests" — where you have intent but not a literal string or symbol.
Once you know the exact token, grep is the faster, exact follow-up.
Ranks cached files by semantic similarity to the query. Operates on
files already seeded via read/batch_read; if results look thin,
seed more of the repo with batch_read and retry.
Args: query: Natural-language query, keywords, or a mixture of both. k: Maximum number of matches to return. directory: Optional directory filter applied after retrieval. show_preview: Include match previews explicitly.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | ||
| k | No | ||
| directory | No | ||
| show_preview | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| truncated | No | ||
| query | No | ||
| matches | No | ||
| count | No | ||
| cached_files | No | ||
| files_searched | No | ||
| k | No | ||
| directory | No | ||
| show_preview | No |