search_codebase
Search an indexed codebase with natural language to locate functions, classes, and patterns. Understand dependencies and explore existing systems.
Instructions
<parameter name="codebase_path" required="true">
<type>string</type>
<description>ABSOLUTE path to the codebase directory to search</description>
<examples>
<valid>/Users/name/project</valid>
<valid>/home/user/code/repo</valid>
<invalid>.</invalid>
<invalid>../project</invalid>
<invalid>relative/path</invalid>
</examples>
<validation>Must be absolute path starting with / (Unix) or C:\ (Windows)</validation>
</parameter>
<parameter name="max_results" required="false">
<type>number</type>
<description>Maximum number of code chunks to return</description>
<default>5</default>
<best_practice>Keep at default 5 for focused results. Use multiple targeted searches rather than increasing this limit</best_practice>
</parameter>
Code chunks with file paths, line numbers, relevance scores, symbol information, imports, and exports Codebase must be indexed first with index_codebase
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | ||
| max_results | No | ||
| codebase_path | Yes |