source-search
Search a Minecraft artifact's indexed source for declarations, file contents, or paths to locate symbols and code across versions, mod JARs, or workspaces.
Instructions
Search one artifact's indexed source: declarations by name (intent symbol, default), file text (text) or file paths (path). status: ok, not_found, partial (search incomplete) or unavailable (no hit and query not translated from mapping, or a Jar-in-Jar shell). Pages with cursor. Example: {"target":{"kind":"version","version":"1.21.10"},"query":"BlockPos"}
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"target": "<target>",
"query": "<query>"
},
"name": "source-search"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Hits per page; default 20, at most 100 with match "regex". | |
| match | No | exact is case-sensitive; text intent treats prefix as contains. | prefix |
| query | Yes | ||
| cursor | No | meta.pagination.nextCursor of the same search. | |
| detail | No | summary drops context; full adds score, reasonCodes, artifactContents. | standard |
| intent | No | symbol: declarations by name; text: file contents; path: file paths. | symbol |
| target | Yes | Fields per kind (?=optional): artifact: artifactId; version: version,projectPath?,scope?; jar: jarPath; coordinate: coordinate; workspace: projectPath,scope?; dependency: group,name,dependencyVersion|projectPath. Other fields rejected. | |
| mapping | No | Namespace of the query; hits keep the artifact's namespace. | |
| fileGlob | No | e.g. "net/minecraft/world/**/*.java". | |
| queryMode | No | Text intent: auto and token search the index; literal scans every file. | auto |
| symbolKind | No | Only with intent "symbol". | |
| packagePrefix | No | e.g. "net.minecraft.world.item". | |
| matchesPerFile | No | Text intent: matching lines listed per file; default 5. |