@octocodeai/octocode-tools-core 16.6.3 → 17.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (252) hide show
  1. package/README.md +22 -50
  2. package/dist/direct.js +33 -38
  3. package/dist/github/botFilter.d.ts +1 -0
  4. package/dist/github/client.d.ts +6 -0
  5. package/dist/github/directoryFetch/fetchDirectoryContents.d.ts +3 -0
  6. package/dist/github/directoryFetch/fetchFileContentToDisk.d.ts +3 -0
  7. package/dist/github/directoryFetch/helpers.d.ts +35 -0
  8. package/dist/github/directoryFetch.d.ts +3 -6
  9. package/dist/github/fileContentPagination.d.ts +9 -0
  10. package/dist/github/fileContentProcess.d.ts +1 -8
  11. package/dist/github/fileContentRaw/fetch.d.ts +20 -0
  12. package/dist/github/fileContentRaw/pathSuggestions.d.ts +3 -0
  13. package/dist/github/fileContentRaw.d.ts +2 -12
  14. package/dist/github/githubAPI.d.ts +4 -1
  15. package/dist/github/history.d.ts +6 -2
  16. package/dist/github/issues/fetchers.d.ts +7 -0
  17. package/dist/github/issues/helpers.d.ts +32 -0
  18. package/dist/github/issues/orchestrator.d.ts +4 -0
  19. package/dist/github/issues/types.d.ts +72 -0
  20. package/dist/github/issues.d.ts +3 -0
  21. package/dist/github/prContentFetcher/comments.d.ts +11 -0
  22. package/dist/github/prContentFetcher/commits.d.ts +27 -0
  23. package/dist/github/prContentFetcher/flags.d.ts +21 -0
  24. package/dist/github/prContentFetcher/transform.d.ts +5 -0
  25. package/dist/github/prContentFetcher.d.ts +2 -5
  26. package/dist/github/pullRequestSearch/restSearch.d.ts +6 -0
  27. package/dist/github/pullRequestSearch.d.ts +1 -1
  28. package/dist/github/queryBuilders/base.d.ts +25 -0
  29. package/dist/github/queryBuilders/codeAndRepo.d.ts +20 -0
  30. package/dist/github/queryBuilders/issues.d.ts +42 -0
  31. package/dist/github/queryBuilders/pullRequests.d.ts +13 -0
  32. package/dist/github/queryBuilders.d.ts +4 -12
  33. package/dist/github/releases.d.ts +37 -0
  34. package/dist/github/repoStructure/contentResolution.d.ts +12 -0
  35. package/dist/github/repoStructure/fetchOrchestration.d.ts +7 -0
  36. package/dist/github/repoStructure/resultBuilder.d.ts +22 -0
  37. package/dist/github/repoStructure.d.ts +1 -7
  38. package/dist/github/repoStructureTree.d.ts +38 -0
  39. package/dist/github/responseHeaders.d.ts +2 -0
  40. package/dist/github/searchKeyword.d.ts +2 -0
  41. package/dist/index.d.ts +1 -4
  42. package/dist/index.js +35 -40
  43. package/dist/oql/adapters/github/execute.d.ts +16 -0
  44. package/dist/oql/adapters/github/provider-diagnostics.d.ts +14 -0
  45. package/dist/oql/adapters/github/shared.d.ts +75 -0
  46. package/dist/oql/adapters/github.d.ts +11 -0
  47. package/dist/oql/adapters/graphView/filters.d.ts +25 -0
  48. package/dist/oql/adapters/graphView/nativeEdges.d.ts +5 -0
  49. package/dist/oql/adapters/graphView.d.ts +17 -16
  50. package/dist/oql/adapters/local/code.d.ts +3 -0
  51. package/dist/oql/adapters/local/codeBoolean.d.ts +3 -0
  52. package/dist/oql/adapters/local/fileRowOps.d.ts +11 -0
  53. package/dist/oql/adapters/local/files.d.ts +3 -0
  54. package/dist/oql/adapters/local/filesBoolean.d.ts +10 -0
  55. package/dist/oql/adapters/local/filesContentLeaf.d.ts +12 -0
  56. package/dist/oql/adapters/local/filesUniverse.d.ts +6 -0
  57. package/dist/oql/adapters/local/findToolType.d.ts +10 -0
  58. package/dist/oql/adapters/local/predicates.d.ts +18 -0
  59. package/dist/oql/adapters/local/scope.d.ts +14 -0
  60. package/dist/oql/adapters/local/searchToolType.d.ts +7 -0
  61. package/dist/oql/adapters/local/structureContent.d.ts +6 -0
  62. package/dist/oql/adapters/local/types.d.ts +34 -0
  63. package/dist/oql/adapters/local.d.ts +3 -7
  64. package/dist/oql/adapters/researchTargets/diff.d.ts +16 -0
  65. package/dist/oql/adapters/researchTargets/graph.d.ts +3 -0
  66. package/dist/oql/adapters/researchTargets/history.d.ts +20 -0
  67. package/dist/oql/adapters/researchTargets/pagination.d.ts +54 -0
  68. package/dist/oql/adapters/researchTargets/repositories.d.ts +4 -0
  69. package/dist/oql/adapters/researchTargets/research.d.ts +3 -0
  70. package/dist/oql/adapters/researchTargets/rows.d.ts +16 -0
  71. package/dist/oql/adapters/researchTargets/semantics.d.ts +3 -0
  72. package/dist/oql/adapters/researchTargets/shared.d.ts +11 -0
  73. package/dist/oql/adapters/researchTargets.d.ts +4 -46
  74. package/dist/oql/defaults.d.ts +1 -1
  75. package/dist/oql/index.js +34 -39
  76. package/dist/oql/normalize/batch.d.ts +2 -0
  77. package/dist/oql/normalize/materialize.d.ts +2 -0
  78. package/dist/oql/normalize/params.d.ts +2 -0
  79. package/dist/oql/normalize/query.d.ts +2 -0
  80. package/dist/oql/normalize/scope.d.ts +2 -0
  81. package/dist/oql/normalize/shared.d.ts +7 -0
  82. package/dist/oql/normalize/source.d.ts +2 -0
  83. package/dist/oql/normalize/where.d.ts +2 -0
  84. package/dist/oql/normalize.d.ts +19 -4
  85. package/dist/oql/planner/planDiagnostics.d.ts +13 -0
  86. package/dist/oql/planner/predicateRouting.d.ts +35 -0
  87. package/dist/oql/predicateUtils.d.ts +3 -0
  88. package/dist/oql/research/analyze/manifest-scan.d.ts +4 -0
  89. package/dist/oql/research/analyze/source-graph.d.ts +7 -0
  90. package/dist/oql/research/analyze/symbol-scoring.d.ts +4 -0
  91. package/dist/oql/research/analyze/types.d.ts +163 -0
  92. package/dist/oql/research/analyze/utils.d.ts +16 -0
  93. package/dist/oql/research/analyze.d.ts +2 -133
  94. package/dist/oql/research/packets/builders.d.ts +4 -0
  95. package/dist/oql/research/packets/types.d.ts +91 -0
  96. package/dist/oql/research/packets.d.ts +21 -80
  97. package/dist/oql/run/batch.d.ts +3 -0
  98. package/dist/oql/run/continuations/records.d.ts +19 -0
  99. package/dist/oql/run/continuations/registry.d.ts +22 -0
  100. package/dist/oql/run/continuations/semantics.d.ts +3 -0
  101. package/dist/oql/run/continuations/types.d.ts +12 -0
  102. package/dist/oql/run/dryRun.d.ts +11 -0
  103. package/dist/oql/run/paths.d.ts +15 -0
  104. package/dist/oql/run/proofGrades.d.ts +8 -0
  105. package/dist/oql/run/select.d.ts +10 -0
  106. package/dist/oql/run/single.d.ts +22 -0
  107. package/dist/oql/run.d.ts +4 -31
  108. package/dist/oql/schema/predicates.d.ts +12 -0
  109. package/dist/oql/schema.d.ts +50 -35
  110. package/dist/oql/schemeText.d.ts +10 -13
  111. package/dist/oql/shorthand/predicates.d.ts +15 -0
  112. package/dist/oql/shorthand/query-controls.d.ts +18 -0
  113. package/dist/oql/shorthand/target-params.d.ts +9 -0
  114. package/dist/oql/shorthand/types.d.ts +159 -0
  115. package/dist/oql/shorthand/utils.d.ts +7 -0
  116. package/dist/oql/shorthand.d.ts +2 -171
  117. package/dist/oql/targetParams.d.ts +0 -13
  118. package/dist/oql/transformers/github/code.d.ts +1 -9
  119. package/dist/oql/types/diagnostics.d.ts +22 -0
  120. package/dist/oql/types/envelope.d.ts +78 -0
  121. package/dist/oql/types/guards.d.ts +9 -0
  122. package/dist/oql/types/planner.d.ts +46 -0
  123. package/dist/oql/types/predicates.d.ts +93 -0
  124. package/dist/oql/types/query.d.ts +143 -0
  125. package/dist/oql/types/recordData.d.ts +127 -0
  126. package/dist/oql/types/recordRows.d.ts +48 -0
  127. package/dist/oql/types/results.d.ts +118 -0
  128. package/dist/oql/types/targets.d.ts +22 -0
  129. package/dist/oql/types.d.ts +17 -640
  130. package/dist/providers/github/paginationMetadata.d.ts +12 -0
  131. package/dist/providers/providerResults.d.ts +0 -1
  132. package/dist/schema.js +2 -2
  133. package/dist/scheme/pagination.d.ts +65 -0
  134. package/dist/shared/config/index.js +1 -1
  135. package/dist/shared/credentials/index.js +2 -2
  136. package/dist/shared/credentials/testing.js +1 -1
  137. package/dist/shared/languageSelectors/classify.d.ts +15 -0
  138. package/dist/shared/languageSelectors/data.d.ts +12 -0
  139. package/dist/shared/languageSelectors.d.ts +3 -23
  140. package/dist/shared/paths.d.ts +0 -4
  141. package/dist/shared/paths.js +1 -1
  142. package/dist/shared/session/index.js +1 -1
  143. package/dist/shared/session/statsDefaults.d.ts +1 -2
  144. package/dist/tools/directToolCatalog/toolCatalogDefinitions.d.ts +68 -0
  145. package/dist/tools/directToolCatalog/toolCommandPatternQueries.d.ts +4 -0
  146. package/dist/tools/directToolCatalog/toolCommandPatterns.d.ts +4 -0
  147. package/dist/tools/directToolCatalog/toolInputPreparation.d.ts +12 -0
  148. package/dist/tools/directToolCatalog/toolSchemaIntrospection.d.ts +19 -0
  149. package/dist/tools/directToolCatalog.meta.d.ts +10 -67
  150. package/dist/tools/github_clone_repo/cache.d.ts +1 -5
  151. package/dist/tools/github_clone_repo/cachePaths.d.ts +5 -0
  152. package/dist/tools/github_fetch_content/finalizer/entryParsers.d.ts +9 -0
  153. package/dist/tools/github_fetch_content/finalizer/types.d.ts +101 -0
  154. package/dist/tools/github_fetch_content/finalizer.d.ts +1 -7
  155. package/dist/tools/github_fetch_content/scheme.d.ts +42 -9
  156. package/dist/tools/github_fetch_content/types.d.ts +1 -2
  157. package/dist/tools/github_search_code/execution.d.ts +9 -0
  158. package/dist/tools/github_search_code/finalizer/build.d.ts +4 -0
  159. package/dist/tools/github_search_code/finalizer/groups.d.ts +23 -0
  160. package/dist/tools/github_search_code/finalizer/ranking.d.ts +12 -0
  161. package/dist/tools/github_search_code/finalizer.d.ts +2 -6
  162. package/dist/tools/github_search_code/scheme.d.ts +29 -2
  163. package/dist/tools/github_search_pull_requests/contentResponse/commentsShaping.d.ts +68 -0
  164. package/dist/tools/github_search_pull_requests/contentResponse/fileSurfaces.d.ts +52 -0
  165. package/dist/tools/github_search_pull_requests/contentResponse/nextCalls.d.ts +17 -0
  166. package/dist/tools/github_search_pull_requests/contentResponse/pagination.d.ts +63 -0
  167. package/dist/tools/github_search_pull_requests/contentResponse.d.ts +1 -15
  168. package/dist/tools/github_search_pull_requests/execution/commitsMode.d.ts +4 -0
  169. package/dist/tools/github_search_pull_requests/execution/issuesMode.d.ts +4 -0
  170. package/dist/tools/github_search_pull_requests/execution/pullRequestsMode.d.ts +4 -0
  171. package/dist/tools/github_search_pull_requests/execution/releasesMode.d.ts +4 -0
  172. package/dist/tools/github_search_pull_requests/execution/types.d.ts +6 -0
  173. package/dist/tools/github_search_pull_requests/execution.d.ts +1 -4
  174. package/dist/tools/github_search_pull_requests/scheme.d.ts +11 -1
  175. package/dist/tools/github_search_repos/execution/pagination.d.ts +39 -0
  176. package/dist/tools/github_search_repos/execution/queryVariants.d.ts +38 -0
  177. package/dist/tools/github_search_repos/execution/ranking.d.ts +4 -0
  178. package/dist/tools/github_search_repos/execution.d.ts +3 -71
  179. package/dist/tools/github_search_repos/scheme.d.ts +8 -0
  180. package/dist/tools/github_view_repo_structure/types.d.ts +2 -0
  181. package/dist/tools/local_fetch_content/fetchContent/extraction.d.ts +15 -0
  182. package/dist/tools/local_fetch_content/fetchContent/pagination.d.ts +38 -0
  183. package/dist/tools/local_fetch_content/fetchContent/validation.d.ts +26 -0
  184. package/dist/tools/local_fetch_content/fetchContent.d.ts +2 -0
  185. package/dist/tools/local_fetch_content/scheme.d.ts +25 -1
  186. package/dist/tools/local_find_files/scheme.d.ts +32 -0
  187. package/dist/tools/local_ripgrep/rankingProfile/rankingProfiles.d.ts +70 -0
  188. package/dist/tools/local_ripgrep/rankingProfile/rankingResults.d.ts +47 -0
  189. package/dist/tools/local_ripgrep/rankingProfile/rankingScoring.d.ts +41 -0
  190. package/dist/tools/local_ripgrep/rankingProfile.d.ts +16 -95
  191. package/dist/tools/local_ripgrep/ripgrepResultBuilder/buildResult.d.ts +10 -0
  192. package/dist/tools/local_ripgrep/ripgrepResultBuilder/searchNext.d.ts +46 -0
  193. package/dist/tools/local_ripgrep/ripgrepResultBuilder.d.ts +2 -18
  194. package/dist/tools/local_ripgrep/scheme.d.ts +95 -0
  195. package/dist/tools/local_view_structure/scheme.d.ts +31 -0
  196. package/dist/tools/lsp/semantic_content/scheme.d.ts +61 -0
  197. package/dist/tools/lsp/semantic_content/semanticAnchored.d.ts +7 -0
  198. package/dist/tools/lsp/semantic_content/semanticEnvelopes/callEnvelopes.d.ts +5 -0
  199. package/dist/tools/lsp/semantic_content/semanticEnvelopes/envelopeHelpers.d.ts +20 -0
  200. package/dist/tools/lsp/semantic_content/semanticEnvelopes/locationEnvelopes.d.ts +13 -0
  201. package/dist/tools/lsp/semantic_content/semanticEnvelopes.d.ts +3 -0
  202. package/dist/tools/lsp/semantic_content/semanticFileOps/anchor.d.ts +24 -0
  203. package/dist/tools/lsp/semantic_content/semanticFileOps/documentSymbols.d.ts +27 -0
  204. package/dist/tools/lsp/semantic_content/semanticFileOps/workspaceSymbolsAndDiagnostics.d.ts +20 -0
  205. package/dist/tools/lsp/semantic_content/semanticFileOps.d.ts +8 -0
  206. package/dist/tools/lsp/semantic_content/semanticPresentation.d.ts +53 -0
  207. package/dist/tools/lsp/shared/semanticTypes.d.ts +6 -0
  208. package/dist/tools/package_search/execution.d.ts +8 -0
  209. package/dist/tools/package_search/scheme.d.ts +43 -2
  210. package/dist/tools/providerMappers/codeSearch.d.ts +66 -0
  211. package/dist/tools/providerMappers/fileContent.d.ts +28 -0
  212. package/dist/tools/providerMappers/pullRequests.d.ts +158 -0
  213. package/dist/tools/providerMappers/repoSearch.d.ts +30 -0
  214. package/dist/tools/providerMappers/repoStructure.d.ts +20 -0
  215. package/dist/tools/providerMappers/shared.d.ts +23 -0
  216. package/dist/tools/providerMappers.d.ts +9 -294
  217. package/dist/tools/toolConfig.d.ts +0 -2
  218. package/dist/tools/toolMetadata/descriptionOverrides.d.ts +4 -0
  219. package/dist/tools/toolSchemaImports.d.ts +13 -0
  220. package/dist/utils/contextUtils.d.ts +5 -16
  221. package/dist/utils/core/types.d.ts +2 -24
  222. package/dist/utils/exec/spawn/env.d.ts +5 -0
  223. package/dist/utils/exec/spawn/wrappers.d.ts +29 -0
  224. package/dist/utils/exec/spawn.d.ts +2 -34
  225. package/dist/utils/file/toolHelpers.d.ts +12 -0
  226. package/dist/utils/http/cache/conditional.d.ts +21 -0
  227. package/dist/utils/http/cache/dataCache.d.ts +6 -0
  228. package/dist/utils/http/cache/key.d.ts +1 -0
  229. package/dist/utils/http/cache/management.d.ts +9 -0
  230. package/dist/utils/http/cache/store.d.ts +28 -0
  231. package/dist/utils/http/cache.d.ts +4 -16
  232. package/dist/utils/markdownOutline.d.ts +0 -2
  233. package/dist/utils/package/npm/npmDeprecation.d.ts +5 -0
  234. package/dist/utils/package/npm/npmDetailsFetchers.d.ts +15 -0
  235. package/dist/utils/package/npm/npmMappers.d.ts +12 -0
  236. package/dist/utils/package/npm/npmRegistry.d.ts +79 -0
  237. package/dist/utils/package/npm/npmSearchStrategies.d.ts +6 -0
  238. package/dist/utils/package/npm.d.ts +2 -8
  239. package/dist/utils/pagination/boundary.d.ts +5 -5
  240. package/dist/utils/response/bulk/pagination.d.ts +6 -0
  241. package/dist/utils/response/bulk/queries.d.ts +19 -0
  242. package/dist/utils/response/bulk/response.d.ts +4 -0
  243. package/dist/utils/response/bulk.d.ts +2 -6
  244. package/package.json +42 -35
  245. package/dist/tools/local_binary_inspect/archiveOps.d.ts +0 -24
  246. package/dist/tools/local_binary_inspect/binaryInspector.d.ts +0 -86
  247. package/dist/tools/local_binary_inspect/binaryOps.d.ts +0 -27
  248. package/dist/tools/local_binary_inspect/decompressOps.d.ts +0 -16
  249. package/dist/tools/local_binary_inspect/execution.d.ts +0 -4
  250. package/dist/tools/local_binary_inspect/scheme.d.ts +0 -144
  251. package/dist/tools/local_ripgrep/lspBoost.d.ts +0 -54
  252. package/dist/utils/parsers/ripgrep.d.ts +0 -11
@@ -44,9 +44,9 @@ export declare const LocalGetFileContentOutputSchema: z.ZodObject<{
44
44
  standard: "standard";
45
45
  symbols: "symbols";
46
46
  }>>;
47
- isSkeleton: z.ZodOptional<z.ZodBoolean>;
48
47
  totalLines: z.ZodOptional<z.ZodNumber>;
49
48
  sourceChars: z.ZodOptional<z.ZodNumber>;
49
+ sourceBytes: z.ZodOptional<z.ZodNumber>;
50
50
  startLine: z.ZodOptional<z.ZodNumber>;
51
51
  endLine: z.ZodOptional<z.ZodNumber>;
52
52
  isPartial: z.ZodOptional<z.ZodBoolean>;
@@ -66,6 +66,7 @@ export declare const LocalGetFileContentOutputSchema: z.ZodObject<{
66
66
  semantic: "semantic";
67
67
  "char-limit": "char-limit";
68
68
  }>>;
69
+ nextBlockChar: z.ZodOptional<z.ZodNumber>;
69
70
  }, z.core.$strip>, z.ZodObject<{
70
71
  currentPage: z.ZodNumber;
71
72
  totalPages: z.ZodNumber;
@@ -73,7 +74,30 @@ export declare const LocalGetFileContentOutputSchema: z.ZodObject<{
73
74
  nextPage: z.ZodOptional<z.ZodNumber>;
74
75
  pageSize: z.ZodOptional<z.ZodNumber>;
75
76
  totalItems: z.ZodOptional<z.ZodNumber>;
77
+ perPage: z.ZodOptional<z.ZodNumber>;
78
+ totalFound: z.ZodOptional<z.ZodNumber>;
79
+ returned: z.ZodOptional<z.ZodNumber>;
80
+ totalMatches: z.ZodOptional<z.ZodNumber>;
81
+ reportedTotalMatches: z.ZodOptional<z.ZodNumber>;
82
+ reachableTotalMatches: z.ZodOptional<z.ZodNumber>;
83
+ totalMatchesKind: z.ZodOptional<z.ZodEnum<{
84
+ exact: "exact";
85
+ reported: "reported";
86
+ lowerBound: "lowerBound";
87
+ }>>;
88
+ totalMatchesCapped: z.ZodOptional<z.ZodBoolean>;
89
+ totalResults: z.ZodOptional<z.ZodNumber>;
90
+ itemsPerPage: z.ZodOptional<z.ZodNumber>;
76
91
  }, z.core.$strip>]>>;
92
+ next: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
93
+ tool: z.ZodString;
94
+ query: z.ZodRecord<z.ZodString, z.ZodUnknown>;
95
+ why: z.ZodOptional<z.ZodString>;
96
+ confidence: z.ZodOptional<z.ZodEnum<{
97
+ exact: "exact";
98
+ heuristic: "heuristic";
99
+ }>>;
100
+ }, z.core.$strip>>>;
77
101
  modified: z.ZodOptional<z.ZodString>;
78
102
  lastModified: z.ZodOptional<z.ZodString>;
79
103
  lastModifiedBy: z.ZodOptional<z.ZodString>;
@@ -15,6 +15,7 @@ export declare const LocalFindFilesOutputSchema: z.ZodObject<{
15
15
  error: "error";
16
16
  }>>;
17
17
  data: z.ZodObject<{
18
+ path: z.ZodOptional<z.ZodString>;
18
19
  files: z.ZodOptional<z.ZodArray<z.ZodObject<{
19
20
  name: z.ZodOptional<z.ZodString>;
20
21
  path: z.ZodOptional<z.ZodString>;
@@ -26,6 +27,7 @@ export declare const LocalFindFilesOutputSchema: z.ZodObject<{
26
27
  symlink: "symlink";
27
28
  }>>;
28
29
  size: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
30
+ sizeFormatted: z.ZodOptional<z.ZodString>;
29
31
  modified: z.ZodOptional<z.ZodString>;
30
32
  accessed: z.ZodOptional<z.ZodString>;
31
33
  created: z.ZodOptional<z.ZodString>;
@@ -39,7 +41,37 @@ export declare const LocalFindFilesOutputSchema: z.ZodObject<{
39
41
  nextPage: z.ZodOptional<z.ZodNumber>;
40
42
  pageSize: z.ZodOptional<z.ZodNumber>;
41
43
  totalItems: z.ZodOptional<z.ZodNumber>;
44
+ perPage: z.ZodOptional<z.ZodNumber>;
45
+ totalFound: z.ZodOptional<z.ZodNumber>;
46
+ returned: z.ZodOptional<z.ZodNumber>;
47
+ reportedTotalMatches: z.ZodOptional<z.ZodNumber>;
48
+ reachableTotalMatches: z.ZodOptional<z.ZodNumber>;
49
+ totalMatchesKind: z.ZodOptional<z.ZodEnum<{
50
+ exact: "exact";
51
+ reported: "reported";
52
+ lowerBound: "lowerBound";
53
+ }>>;
54
+ totalMatchesCapped: z.ZodOptional<z.ZodBoolean>;
55
+ totalResults: z.ZodOptional<z.ZodNumber>;
56
+ itemsPerPage: z.ZodOptional<z.ZodNumber>;
57
+ filesPerPage: z.ZodOptional<z.ZodNumber>;
58
+ entriesPerPage: z.ZodOptional<z.ZodNumber>;
59
+ matchesPerPage: z.ZodOptional<z.ZodNumber>;
60
+ totalFiles: z.ZodOptional<z.ZodNumber>;
61
+ totalEntries: z.ZodOptional<z.ZodNumber>;
62
+ totalMatches: z.ZodOptional<z.ZodNumber>;
63
+ totalFilesFound: z.ZodOptional<z.ZodNumber>;
64
+ nextMatchPage: z.ZodOptional<z.ZodNumber>;
42
65
  }, z.core.$strip>>;
66
+ next: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
67
+ tool: z.ZodString;
68
+ query: z.ZodRecord<z.ZodString, z.ZodUnknown>;
69
+ why: z.ZodOptional<z.ZodString>;
70
+ confidence: z.ZodOptional<z.ZodEnum<{
71
+ exact: "exact";
72
+ heuristic: "heuristic";
73
+ }>>;
74
+ }, z.core.$strip>>>;
43
75
  warnings: z.ZodOptional<z.ZodArray<z.ZodString>>;
44
76
  }, z.core.$strip>;
45
77
  }, z.core.$strip>>;
@@ -0,0 +1,70 @@
1
+ /**
2
+ * Ranking profile data/config — language profile tables, path-role
3
+ * classification, and the tunable weight policy. See
4
+ * `.octocode/RANKING-ARCHITECTURE.md` and the module doc in
5
+ * `../rankingProfile.ts` (the public barrel) for the full contract.
6
+ *
7
+ * This module owns *what* a profile is and *where* a path lives (its role);
8
+ * `rankingScoring.ts` owns *how much* each signal is worth in a score.
9
+ */
10
+ export type RankingProfileId = 'typescript' | 'javascript' | 'rust' | 'python' | 'go' | 'java' | 'scala' | 'markdown' | 'json' | 'yaml' | 'generic';
11
+ /** TS-level result orderings. `relevance` is the language-aware scorer. */
12
+ export type RankSort = 'relevance' | 'matchCount' | 'path' | 'created' | 'modified' | 'accessed';
13
+ export declare const RANKING_PROFILE_IDS: readonly ["typescript", "javascript", "rust", "python", "go", "java", "scala", "markdown", "json", "yaml", "generic"];
14
+ export type PathRole = 'source' | 'test' | 'docs' | 'config' | 'generated' | 'fixture' | 'unknown';
15
+ /**
16
+ * All ranking weights in one place. Tuning happens here and in the golden
17
+ * fixtures, never scattered across the scorer. Values are deliberately
18
+ * integer-ish and additive so a score can be read back from its reasons.
19
+ */
20
+ export declare const RANK_WEIGHTS: {
21
+ readonly exactWholeWord: 6;
22
+ readonly exactCaseInsensitive: 3;
23
+ readonly substring: 1;
24
+ readonly declarationLine: 8;
25
+ readonly exportLine: 4;
26
+ readonly importLine: 3;
27
+ readonly configKeyLine: 4;
28
+ readonly headingLine: 4;
29
+ readonly commentOrStringPenalty: -2;
30
+ readonly pathUnderQuery: 4;
31
+ readonly pathSegmentToken: 3;
32
+ readonly extMatchesLangType: 2;
33
+ readonly sourceDir: 1.5;
34
+ readonly lowSignalPathPenalty: -5;
35
+ readonly rareQueryTokenScale: 2;
36
+ readonly rareQueryTokenCap: 3;
37
+ readonly matchCountScale: 1.5;
38
+ readonly matchCountCap: 6;
39
+ };
40
+ /**
41
+ * Bound on how many files get full scoring before pagination. The engine text
42
+ * path returns the entire result set unbounded (no global file/match cap), so
43
+ * for broad terms in a large monorepo we must not score O(total files). When
44
+ * the cap bites we deterministically prefilter (matchCount desc, path asc)
45
+ * before scoring, and the builder surfaces a `truncated`-style note.
46
+ */
47
+ export declare const RANK_CANDIDATE_CAP = 2000;
48
+ export interface RankingProfile {
49
+ id: RankingProfileId;
50
+ extensions: readonly string[];
51
+ /** Lines that declare/define a symbol named like the query — highest signal. */
52
+ declaration: readonly RegExp[];
53
+ /** Exported/public surface. */
54
+ export: readonly RegExp[];
55
+ /** Import/use lines. */
56
+ import: readonly RegExp[];
57
+ }
58
+ export declare const COMMENT_LINE: RegExp;
59
+ export declare const HEADING_LINE: RegExp;
60
+ export declare const LOW_SIGNAL_PATH: RegExp;
61
+ export declare const EXT_RE: RegExp;
62
+ export declare function fileExtension(path: string): string;
63
+ /** Deterministic profile selection from query langType then file extension. */
64
+ export declare function selectProfile(path: string, langType?: string, override?: RankingProfileId | 'auto'): RankingProfile;
65
+ export declare function classifyPathRole(path: string): PathRole;
66
+ /** True when the query path explicitly targets a low-signal area, so the
67
+ * scorer should not penalize generated/test/docs/fixture roles. Uses anchored
68
+ * path-segment matching (not substring) so `latest/`, `contest/`, `manifest/`
69
+ * do NOT count as low-signal. */
70
+ export declare function isLowSignalQueryPath(path: string | undefined): boolean;
@@ -0,0 +1,47 @@
1
+ /**
2
+ * Ranking results — the top-level `rankFiles` entry point plus the small
3
+ * lexical helpers (comment/string detection, token indexing) that classify a
4
+ * matched line before the scorer in `rankingScoring.ts` weighs it.
5
+ *
6
+ * `rankFiles` composes the scoring engine (`scoreFileWithRarity`,
7
+ * `buildCandidateTermRarity`) over the whole candidate set: it applies the
8
+ * candidate cap, builds candidate-local term rarity once, scores every file,
9
+ * and produces a total, deterministic order. See the module doc in
10
+ * `../rankingProfile.ts` for the full contract.
11
+ */
12
+ import type { LocalSearchCodeFile } from '@octocodeai/octocode-core/types';
13
+ import type { RankingProfileId, RankSort } from './rankingProfiles.js';
14
+ import type { FileScore, RankContext } from './rankingScoring.js';
15
+ export interface RankResult {
16
+ files: LocalSearchCodeFile[];
17
+ /** Per-path debug info, only populated when debug is requested. */
18
+ debug?: Map<string, FileScore>;
19
+ /** Number of files dropped by the candidate cap before scoring (0 if none). */
20
+ cappedCandidates: number;
21
+ }
22
+ /**
23
+ * Rank files by the requested sort mode. `relevance` is the language-aware
24
+ * scorer (default); `matchCount` and `path` are deterministic escape hatches;
25
+ * filesystem sorts (created/modified/accessed) preserve the engine's order.
26
+ */
27
+ export declare function rankFiles(files: LocalSearchCodeFile[], sort: RankSort, ctx: RankContext, opts?: {
28
+ debug?: boolean;
29
+ candidateCap?: number;
30
+ }): RankResult;
31
+ export declare function matchesAny(patterns: readonly RegExp[], line: string): boolean;
32
+ export declare function escapeRegex(s: string): string;
33
+ /** A search whose keyword is a single bare identifier — the only case where
34
+ * whole-word/substring line-exactness is meaningful (regex/multi-term patterns
35
+ * make the extracted token an arbitrary fragment). */
36
+ export declare function isPlainIdentifierKeyword(keyword?: string): boolean;
37
+ /** Pick the line within a (possibly multi-line context) snippet that actually
38
+ * contains the query token; fall back to the first non-empty line. */
39
+ export declare function matchedLineOf(snippet: string, token: string | undefined, caseSensitive?: boolean): string;
40
+ type LexicalCategory = 'comment' | 'string' | 'code';
41
+ /** Best-effort lexical category of the token's occurrence on a single line.
42
+ * Deterministic and conservative — used only in the regex fallback path when
43
+ * the engine's grammar-accurate AST kind is unavailable. */
44
+ export declare function lexicalCategoryOf(line: string, token: string | undefined, profileId: RankingProfileId, caseSensitive?: boolean): LexicalCategory;
45
+ /** Whether byte index `idx` falls inside a quoted region of the line. */
46
+ export declare function isIndexInsideString(line: string, idx: number): boolean;
47
+ export {};
@@ -0,0 +1,41 @@
1
+ /**
2
+ * Ranking scoring engine — turns a candidate file's matches, path, and the
3
+ * query context into an additive, explainable `FileScore`. Every function
4
+ * here appends to a shared `reasons: string[]` accumulator; call order is
5
+ * significant because scores are additive and reasons are appended in the
6
+ * order they are computed. Do not reorder the calls inside
7
+ * `scoreFileWithRarity` or `bestLineScore`.
8
+ *
9
+ * See the module doc in `../rankingProfile.ts` for the full contract.
10
+ */
11
+ import type { LocalSearchCodeFile } from '@octocodeai/octocode-core/types';
12
+ import { type PathRole, type RankingProfileId } from './rankingProfiles.js';
13
+ export interface RankContext {
14
+ /** Validated, sanitized search base path (query.path). */
15
+ queryPath?: string;
16
+ /** The literal keyword/pattern, used for whole-word / token / path checks. */
17
+ keyword?: string;
18
+ langType?: string;
19
+ caseSensitive?: boolean;
20
+ wholeWord?: boolean;
21
+ /** Profile override from query.rankingProfile. */
22
+ profileOverride?: RankingProfileId | 'auto';
23
+ /** True when the user explicitly searched into a low-signal/test/docs area. */
24
+ explicitLowSignal?: boolean;
25
+ }
26
+ export interface FileScore {
27
+ score: number;
28
+ profile: RankingProfileId;
29
+ pathRole: PathRole;
30
+ reasons: string[];
31
+ }
32
+ type CandidateTermRarity = {
33
+ candidateCount: number;
34
+ fileTokens: ReadonlyMap<string, readonly string[]>;
35
+ documentFrequency: ReadonlyMap<string, number>;
36
+ };
37
+ export declare function buildCandidateTermRarity(files: LocalSearchCodeFile[], ctx: RankContext): CandidateTermRarity | undefined;
38
+ export declare function scoreFileWithRarity(file: LocalSearchCodeFile, ctx: RankContext, rarity?: CandidateTermRarity): FileScore;
39
+ /** Score one file. Pure and deterministic. */
40
+ export declare function scoreFile(file: LocalSearchCodeFile, ctx: RankContext): FileScore;
41
+ export {};
@@ -15,99 +15,20 @@
15
15
  * Not rigid: profiles are declarative tables, all weights live in one policy
16
16
  * object, new languages register by adding a profile. AST/LSP signals (Phase
17
17
  * 2/3) layer on top without changing this contract.
18
+ *
19
+ * This file is a thin barrel: the implementation lives in `rankingProfile/`,
20
+ * split by concern —
21
+ * - `rankingProfile/rankingProfiles.ts`: profile data/config (language
22
+ * tables, path-role regexes, `selectProfile`/`classifyPathRole`).
23
+ * - `rankingProfile/rankingScoring.ts`: the scoring engine (`bestLineScore`,
24
+ * `pathAffinityScore`, `candidateTermRarityScore`, `scoreFileWithRarity`).
25
+ * - `rankingProfile/rankingResults.ts`: `rankFiles`/`RankResult` plus the
26
+ * lexical helpers (`lexicalCategoryOf`, `isIndexInsideString`, etc.).
27
+ * Re-exported here so no other module needs to change its import path.
18
28
  */
19
- import type { LocalSearchCodeFile } from '@octocodeai/octocode-core/types';
20
- export type RankingProfileId = 'typescript' | 'javascript' | 'rust' | 'python' | 'go' | 'java' | 'scala' | 'markdown' | 'json' | 'yaml' | 'generic';
21
- /** TS-level result orderings. `relevance` is the language-aware scorer. */
22
- export type RankSort = 'relevance' | 'matchCount' | 'path' | 'created' | 'modified' | 'accessed';
23
- export declare const RANKING_PROFILE_IDS: readonly ["typescript", "javascript", "rust", "python", "go", "java", "scala", "markdown", "json", "yaml", "generic"];
24
- type PathRole = 'source' | 'test' | 'docs' | 'config' | 'generated' | 'fixture' | 'unknown';
25
- /**
26
- * All ranking weights in one place. Tuning happens here and in the golden
27
- * fixtures, never scattered across the scorer. Values are deliberately
28
- * integer-ish and additive so a score can be read back from its reasons.
29
- */
30
- export declare const RANK_WEIGHTS: {
31
- readonly exactWholeWord: 6;
32
- readonly exactCaseInsensitive: 3;
33
- readonly substring: 1;
34
- readonly declarationLine: 8;
35
- readonly exportLine: 4;
36
- readonly importLine: 3;
37
- readonly configKeyLine: 4;
38
- readonly headingLine: 4;
39
- readonly commentOrStringPenalty: -2;
40
- readonly pathUnderQuery: 4;
41
- readonly pathSegmentToken: 3;
42
- readonly extMatchesLangType: 2;
43
- readonly sourceDir: 1.5;
44
- readonly lowSignalPathPenalty: -5;
45
- readonly rareQueryTokenScale: 2;
46
- readonly rareQueryTokenCap: 3;
47
- readonly matchCountScale: 1.5;
48
- readonly matchCountCap: 6;
49
- };
50
- /**
51
- * Bound on how many files get full scoring before pagination. The engine text
52
- * path returns the entire result set unbounded (no global file/match cap), so
53
- * for broad terms in a large monorepo we must not score O(total files). When
54
- * the cap bites we deterministically prefilter (matchCount desc, path asc)
55
- * before scoring, and the builder surfaces a `truncated`-style note.
56
- */
57
- export declare const RANK_CANDIDATE_CAP = 2000;
58
- interface RankingProfile {
59
- id: RankingProfileId;
60
- extensions: readonly string[];
61
- /** Lines that declare/define a symbol named like the query — highest signal. */
62
- declaration: readonly RegExp[];
63
- /** Exported/public surface. */
64
- export: readonly RegExp[];
65
- /** Import/use lines. */
66
- import: readonly RegExp[];
67
- }
68
- /** Deterministic profile selection from query langType then file extension. */
69
- export declare function selectProfile(path: string, langType?: string, override?: RankingProfileId | 'auto'): RankingProfile;
70
- export declare function classifyPathRole(path: string): PathRole;
71
- export interface RankContext {
72
- /** Validated, sanitized search base path (query.path). */
73
- queryPath?: string;
74
- /** The literal keyword/pattern, used for whole-word / token / path checks. */
75
- keyword?: string;
76
- langType?: string;
77
- caseSensitive?: boolean;
78
- wholeWord?: boolean;
79
- /** Profile override from query.rankingProfile. */
80
- profileOverride?: RankingProfileId | 'auto';
81
- /** True when the user explicitly searched into a low-signal/test/docs area. */
82
- explicitLowSignal?: boolean;
83
- }
84
- export interface FileScore {
85
- score: number;
86
- profile: RankingProfileId;
87
- pathRole: PathRole;
88
- reasons: string[];
89
- }
90
- /** Score one file. Pure and deterministic. */
91
- export declare function scoreFile(file: LocalSearchCodeFile, ctx: RankContext): FileScore;
92
- export interface RankResult {
93
- files: LocalSearchCodeFile[];
94
- /** Per-path debug info, only populated when debug is requested. */
95
- debug?: Map<string, FileScore>;
96
- /** Number of files dropped by the candidate cap before scoring (0 if none). */
97
- cappedCandidates: number;
98
- }
99
- /**
100
- * Rank files by the requested sort mode. `relevance` is the language-aware
101
- * scorer (default); `matchCount` and `path` are deterministic escape hatches;
102
- * filesystem sorts (created/modified/accessed) preserve the engine's order.
103
- */
104
- export declare function rankFiles(files: LocalSearchCodeFile[], sort: RankSort, ctx: RankContext, opts?: {
105
- debug?: boolean;
106
- candidateCap?: number;
107
- }): RankResult;
108
- /** True when the query path explicitly targets a low-signal area, so the
109
- * scorer should not penalize generated/test/docs/fixture roles. Uses anchored
110
- * path-segment matching (not substring) so `latest/`, `contest/`, `manifest/`
111
- * do NOT count as low-signal. */
112
- export declare function isLowSignalQueryPath(path: string | undefined): boolean;
113
- export {};
29
+ export type { RankingProfileId, RankSort, PathRole, RankingProfile, } from './rankingProfile/rankingProfiles.js';
30
+ export { RANKING_PROFILE_IDS, RANK_WEIGHTS, RANK_CANDIDATE_CAP, COMMENT_LINE, HEADING_LINE, LOW_SIGNAL_PATH, EXT_RE, fileExtension, selectProfile, classifyPathRole, isLowSignalQueryPath, } from './rankingProfile/rankingProfiles.js';
31
+ export type { RankContext, FileScore, } from './rankingProfile/rankingScoring.js';
32
+ export { buildCandidateTermRarity, scoreFileWithRarity, scoreFile, } from './rankingProfile/rankingScoring.js';
33
+ export type { RankResult } from './rankingProfile/rankingResults.js';
34
+ export { rankFiles, matchesAny, escapeRegex, isPlainIdentifierKeyword, matchedLineOf, lexicalCategoryOf, isIndexInsideString, } from './rankingProfile/rankingResults.js';
@@ -0,0 +1,10 @@
1
+ import type { LocalSearchCodeFile } from '@octocodeai/octocode-core/types';
2
+ import type { LocalSearchCodeToolResult } from '@octocodeai/octocode-core/extra-types';
3
+ import type { SearchStats } from '../../../utils/core/types.js';
4
+ import type { RipgrepQuery } from '../scheme.js';
5
+ export type LocalSearchEngine = 'rg' | 'structural';
6
+ export declare function buildSearchResult(parsedFiles: LocalSearchCodeFile[], configuredQuery: RipgrepQuery, searchEngine: LocalSearchEngine, warnings: string[], stats?: SearchStats): Promise<LocalSearchCodeToolResult>;
7
+ export declare function finalizeRipgrepResult(result: LocalSearchCodeToolResult, _query: RipgrepQuery, _totals: {
8
+ totalMatches: number;
9
+ totalFiles: number;
10
+ }): LocalSearchCodeToolResult;
@@ -0,0 +1,46 @@
1
+ import type { LocalSearchCodeFile } from '@octocodeai/octocode-core/types';
2
+ import type { RipgrepQuery } from '../scheme.js';
3
+ import type { LocalSearchEngine } from './buildResult.js';
4
+ type NextToolName = 'localGetFileContent' | 'lspGetSemantics' | 'localSearchCode';
5
+ type NextConfidence = 'exact' | 'heuristic';
6
+ type SearchNextCall = {
7
+ tool: NextToolName;
8
+ query: Record<string, unknown>;
9
+ why: string;
10
+ confidence?: NextConfidence;
11
+ };
12
+ export type SearchNextMap = {
13
+ fetch?: SearchNextCall;
14
+ lspDefinition?: SearchNextCall;
15
+ lspReferences?: SearchNextCall;
16
+ nextPage?: SearchNextCall;
17
+ nextMatchPage?: SearchNextCall;
18
+ };
19
+ type FlowMatch = {
20
+ line?: number;
21
+ endLine?: number;
22
+ value?: string;
23
+ metavars?: Record<string, string[]>;
24
+ metavarRanges?: Record<string, Array<{
25
+ line: number;
26
+ }>>;
27
+ };
28
+ export declare function buildSearchNextMap(files: LocalSearchCodeFile[], query: RipgrepQuery, searchEngine: LocalSearchEngine, options: {
29
+ isFileListMode: boolean;
30
+ currentPage: number;
31
+ totalFilePages: number;
32
+ matchPage: number;
33
+ matchesPerPage: number;
34
+ hasFileWithMoreMatches: boolean;
35
+ }): SearchNextMap;
36
+ export type InferredLspSymbol = {
37
+ symbol: string;
38
+ /**
39
+ * Precise capture line from `metavarRanges` (structural search only).
40
+ * Undefined when the search engine doesn't carry per-capture ranges — the
41
+ * caller falls back to the match's own start line.
42
+ */
43
+ line?: number;
44
+ };
45
+ export declare function inferLspSymbolName(match: FlowMatch | undefined, query: RipgrepQuery, searchEngine: LocalSearchEngine): InferredLspSymbol | undefined;
46
+ export {};
@@ -1,18 +1,2 @@
1
- import type { LocalSearchCodeFile } from '@octocodeai/octocode-core/types';
2
- import type { LocalSearchCodeToolResult } from '@octocodeai/octocode-core/extra-types';
3
- import type { SearchStats } from '../../utils/core/types.js';
4
- import type { RipgrepQuery } from './scheme.js';
5
- export type LocalSearchEngine = 'rg' | 'structural';
6
- type FlowMatch = {
7
- line?: number;
8
- endLine?: number;
9
- value?: string;
10
- metavars?: Record<string, string[]>;
11
- };
12
- export declare function buildSearchResult(parsedFiles: LocalSearchCodeFile[], configuredQuery: RipgrepQuery, searchEngine: LocalSearchEngine, warnings: string[], stats?: SearchStats): Promise<LocalSearchCodeToolResult>;
13
- export declare function finalizeRipgrepResult(result: LocalSearchCodeToolResult, _query: RipgrepQuery, _totals: {
14
- totalMatches: number;
15
- totalFiles: number;
16
- }): LocalSearchCodeToolResult;
17
- export declare function inferLspSymbolName(match: FlowMatch | undefined, query: RipgrepQuery, searchEngine: LocalSearchEngine): string | undefined;
18
- export {};
1
+ export * from './ripgrepResultBuilder/buildResult.js';
2
+ export * from './ripgrepResultBuilder/searchNext.js';
@@ -93,13 +93,29 @@ export declare const LocalSearchCodeOutputSchema: z.ZodObject<{
93
93
  endLine: z.ZodOptional<z.ZodNumber>;
94
94
  value: z.ZodOptional<z.ZodString>;
95
95
  column: z.ZodOptional<z.ZodNumber>;
96
+ endColumn: z.ZodOptional<z.ZodNumber>;
96
97
  count: z.ZodOptional<z.ZodNumber>;
98
+ kind: z.ZodOptional<z.ZodString>;
99
+ scoreHint: z.ZodOptional<z.ZodNumber>;
97
100
  metavars: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString>>>;
101
+ metavarRanges: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodObject<{
102
+ text: z.ZodString;
103
+ line: z.ZodNumber;
104
+ column: z.ZodNumber;
105
+ endLine: z.ZodNumber;
106
+ endColumn: z.ZodNumber;
107
+ }, z.core.$strip>>>>;
98
108
  }, z.core.$strip>>>;
99
109
  totalOccurrences: z.ZodOptional<z.ZodNumber>;
100
110
  totalMatchedLines: z.ZodOptional<z.ZodNumber>;
101
111
  totalMatchRows: z.ZodOptional<z.ZodNumber>;
102
112
  returnedMatchRows: z.ZodOptional<z.ZodNumber>;
113
+ ranking: z.ZodOptional<z.ZodObject<{
114
+ score: z.ZodNumber;
115
+ profile: z.ZodOptional<z.ZodString>;
116
+ pathRole: z.ZodOptional<z.ZodString>;
117
+ reasons: z.ZodOptional<z.ZodArray<z.ZodString>>;
118
+ }, z.core.$strip>>;
103
119
  matchPagination: z.ZodOptional<z.ZodObject<{
104
120
  currentPage: z.ZodNumber;
105
121
  totalPages: z.ZodNumber;
@@ -107,6 +123,56 @@ export declare const LocalSearchCodeOutputSchema: z.ZodObject<{
107
123
  nextPage: z.ZodOptional<z.ZodNumber>;
108
124
  pageSize: z.ZodOptional<z.ZodNumber>;
109
125
  totalItems: z.ZodOptional<z.ZodNumber>;
126
+ perPage: z.ZodOptional<z.ZodNumber>;
127
+ totalFound: z.ZodOptional<z.ZodNumber>;
128
+ returned: z.ZodOptional<z.ZodNumber>;
129
+ reportedTotalMatches: z.ZodOptional<z.ZodNumber>;
130
+ reachableTotalMatches: z.ZodOptional<z.ZodNumber>;
131
+ totalMatchesKind: z.ZodOptional<z.ZodEnum<{
132
+ exact: "exact";
133
+ reported: "reported";
134
+ lowerBound: "lowerBound";
135
+ }>>;
136
+ totalMatchesCapped: z.ZodOptional<z.ZodBoolean>;
137
+ totalResults: z.ZodOptional<z.ZodNumber>;
138
+ itemsPerPage: z.ZodOptional<z.ZodNumber>;
139
+ filesPerPage: z.ZodOptional<z.ZodNumber>;
140
+ entriesPerPage: z.ZodOptional<z.ZodNumber>;
141
+ matchesPerPage: z.ZodOptional<z.ZodNumber>;
142
+ totalFiles: z.ZodOptional<z.ZodNumber>;
143
+ totalEntries: z.ZodOptional<z.ZodNumber>;
144
+ totalMatches: z.ZodOptional<z.ZodNumber>;
145
+ totalFilesFound: z.ZodOptional<z.ZodNumber>;
146
+ nextMatchPage: z.ZodOptional<z.ZodNumber>;
147
+ }, z.core.$strip>>;
148
+ pagination: z.ZodOptional<z.ZodObject<{
149
+ currentPage: z.ZodNumber;
150
+ totalPages: z.ZodNumber;
151
+ hasMore: z.ZodBoolean;
152
+ nextPage: z.ZodOptional<z.ZodNumber>;
153
+ pageSize: z.ZodOptional<z.ZodNumber>;
154
+ totalItems: z.ZodOptional<z.ZodNumber>;
155
+ perPage: z.ZodOptional<z.ZodNumber>;
156
+ totalFound: z.ZodOptional<z.ZodNumber>;
157
+ returned: z.ZodOptional<z.ZodNumber>;
158
+ reportedTotalMatches: z.ZodOptional<z.ZodNumber>;
159
+ reachableTotalMatches: z.ZodOptional<z.ZodNumber>;
160
+ totalMatchesKind: z.ZodOptional<z.ZodEnum<{
161
+ exact: "exact";
162
+ reported: "reported";
163
+ lowerBound: "lowerBound";
164
+ }>>;
165
+ totalMatchesCapped: z.ZodOptional<z.ZodBoolean>;
166
+ totalResults: z.ZodOptional<z.ZodNumber>;
167
+ itemsPerPage: z.ZodOptional<z.ZodNumber>;
168
+ filesPerPage: z.ZodOptional<z.ZodNumber>;
169
+ entriesPerPage: z.ZodOptional<z.ZodNumber>;
170
+ matchesPerPage: z.ZodOptional<z.ZodNumber>;
171
+ totalFiles: z.ZodOptional<z.ZodNumber>;
172
+ totalEntries: z.ZodOptional<z.ZodNumber>;
173
+ totalMatches: z.ZodOptional<z.ZodNumber>;
174
+ totalFilesFound: z.ZodOptional<z.ZodNumber>;
175
+ nextMatchPage: z.ZodOptional<z.ZodNumber>;
110
176
  }, z.core.$strip>>;
111
177
  next: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
112
178
  tool: z.ZodString;
@@ -120,6 +186,14 @@ export declare const LocalSearchCodeOutputSchema: z.ZodObject<{
120
186
  }, z.core.$strip>>>;
121
187
  summary: z.ZodOptional<z.ZodString>;
122
188
  searchEngine: z.ZodOptional<z.ZodString>;
189
+ stats: z.ZodOptional<z.ZodObject<{
190
+ totalOccurrences: z.ZodOptional<z.ZodNumber>;
191
+ matchedLines: z.ZodOptional<z.ZodNumber>;
192
+ filesMatched: z.ZodOptional<z.ZodNumber>;
193
+ filesSearched: z.ZodOptional<z.ZodNumber>;
194
+ bytesSearched: z.ZodOptional<z.ZodNumber>;
195
+ searchTime: z.ZodOptional<z.ZodString>;
196
+ }, z.core.$loose>>;
123
197
  pagination: z.ZodOptional<z.ZodObject<{
124
198
  currentPage: z.ZodNumber;
125
199
  totalPages: z.ZodNumber;
@@ -127,6 +201,27 @@ export declare const LocalSearchCodeOutputSchema: z.ZodObject<{
127
201
  nextPage: z.ZodOptional<z.ZodNumber>;
128
202
  pageSize: z.ZodOptional<z.ZodNumber>;
129
203
  totalItems: z.ZodOptional<z.ZodNumber>;
204
+ perPage: z.ZodOptional<z.ZodNumber>;
205
+ totalFound: z.ZodOptional<z.ZodNumber>;
206
+ returned: z.ZodOptional<z.ZodNumber>;
207
+ reportedTotalMatches: z.ZodOptional<z.ZodNumber>;
208
+ reachableTotalMatches: z.ZodOptional<z.ZodNumber>;
209
+ totalMatchesKind: z.ZodOptional<z.ZodEnum<{
210
+ exact: "exact";
211
+ reported: "reported";
212
+ lowerBound: "lowerBound";
213
+ }>>;
214
+ totalMatchesCapped: z.ZodOptional<z.ZodBoolean>;
215
+ totalResults: z.ZodOptional<z.ZodNumber>;
216
+ itemsPerPage: z.ZodOptional<z.ZodNumber>;
217
+ filesPerPage: z.ZodOptional<z.ZodNumber>;
218
+ entriesPerPage: z.ZodOptional<z.ZodNumber>;
219
+ matchesPerPage: z.ZodOptional<z.ZodNumber>;
220
+ totalFiles: z.ZodOptional<z.ZodNumber>;
221
+ totalEntries: z.ZodOptional<z.ZodNumber>;
222
+ totalMatches: z.ZodOptional<z.ZodNumber>;
223
+ totalFilesFound: z.ZodOptional<z.ZodNumber>;
224
+ nextMatchPage: z.ZodOptional<z.ZodNumber>;
130
225
  }, z.core.$strip>>;
131
226
  next: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
132
227
  tool: z.ZodString;
@@ -52,6 +52,7 @@ export declare const LocalViewStructureOutputSchema: z.ZodObject<{
52
52
  path: z.ZodOptional<z.ZodString>;
53
53
  depth: z.ZodOptional<z.ZodNumber>;
54
54
  size: z.ZodOptional<z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>;
55
+ sizeBytes: z.ZodOptional<z.ZodNumber>;
55
56
  modified: z.ZodOptional<z.ZodString>;
56
57
  permissions: z.ZodOptional<z.ZodString>;
57
58
  }, z.core.$strip>>>;
@@ -66,7 +67,37 @@ export declare const LocalViewStructureOutputSchema: z.ZodObject<{
66
67
  nextPage: z.ZodOptional<z.ZodNumber>;
67
68
  pageSize: z.ZodOptional<z.ZodNumber>;
68
69
  totalItems: z.ZodOptional<z.ZodNumber>;
70
+ perPage: z.ZodOptional<z.ZodNumber>;
71
+ totalFound: z.ZodOptional<z.ZodNumber>;
72
+ returned: z.ZodOptional<z.ZodNumber>;
73
+ reportedTotalMatches: z.ZodOptional<z.ZodNumber>;
74
+ reachableTotalMatches: z.ZodOptional<z.ZodNumber>;
75
+ totalMatchesKind: z.ZodOptional<z.ZodEnum<{
76
+ exact: "exact";
77
+ reported: "reported";
78
+ lowerBound: "lowerBound";
79
+ }>>;
80
+ totalMatchesCapped: z.ZodOptional<z.ZodBoolean>;
81
+ totalResults: z.ZodOptional<z.ZodNumber>;
82
+ itemsPerPage: z.ZodOptional<z.ZodNumber>;
83
+ filesPerPage: z.ZodOptional<z.ZodNumber>;
84
+ entriesPerPage: z.ZodOptional<z.ZodNumber>;
85
+ matchesPerPage: z.ZodOptional<z.ZodNumber>;
86
+ totalFiles: z.ZodOptional<z.ZodNumber>;
87
+ totalEntries: z.ZodOptional<z.ZodNumber>;
88
+ totalMatches: z.ZodOptional<z.ZodNumber>;
89
+ totalFilesFound: z.ZodOptional<z.ZodNumber>;
90
+ nextMatchPage: z.ZodOptional<z.ZodNumber>;
69
91
  }, z.core.$strip>>;
92
+ next: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
93
+ tool: z.ZodString;
94
+ query: z.ZodRecord<z.ZodString, z.ZodUnknown>;
95
+ why: z.ZodOptional<z.ZodString>;
96
+ confidence: z.ZodOptional<z.ZodEnum<{
97
+ exact: "exact";
98
+ heuristic: "heuristic";
99
+ }>>;
100
+ }, z.core.$strip>>>;
70
101
  warnings: z.ZodOptional<z.ZodArray<z.ZodString>>;
71
102
  }, z.core.$strip>;
72
103
  }, z.core.$strip>>;