ask_codebase
Synthesis Q&A for behavior/architecture questions: answer + citations in one call. HEAVY (~2-4 s, ~3-5 k tokens): prefer context, find_node, or locate when they suffice. scope:"repo" (default) = ONE repo; scope:"all" = cross-repo (repositoryIds narrows, omit spans all; rejects repository). If sufficient_to_answer=true, answer without further tool calls. commitSha pins a revision.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Max candidate symbols fed to synthesis (default 10, max 30). | |
| query | No | Alias of question. | |
| scope | No | repo (default) = single-repo. all = cross-repo; repositoryIds narrows, omit spans all. | repo |
| feedback | No | Optional: report how a previous answer worked out; piggybacks on any call. | |
| question | No | The behavior question, e.g. "how does X work". | |
| commitSha | No | Pin reads to one indexed revision (7-40 hex). Graph tools error with revision_not_indexed when it is not an indexed revision of the scoped repository, or revision_not_servable when that revision's graph was superseded by a later reindex, and echo the revision served back as commitSha; source ops read git objects, so any commit works there. Exception: a kept revision (revisions rows flagged architectureSnapshot) still serves map view:"architecture" as a preserved snapshot. | |
| projectId | No | Project id from init/list_projects. Omit for the active project. | |
| repository | No | Repository full name, e.g. "owner/repo". Omit when the project has one repository. | |
| repositoryIds | No | scope:all only. Restrict to these encoded repository ids. |