@smeltjs/core 0.2.0 → 0.4.0

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 (348) hide show
  1. package/README.md +3 -3
  2. package/dist/agents/guide.d.ts +68 -0
  3. package/dist/agents/guide.d.ts.map +1 -0
  4. package/dist/agents/guide.js +72 -0
  5. package/dist/agents/guide.js.map +1 -0
  6. package/dist/agents/instructions.d.ts +133 -0
  7. package/dist/agents/instructions.d.ts.map +1 -0
  8. package/dist/agents/instructions.js +212 -0
  9. package/dist/agents/instructions.js.map +1 -0
  10. package/dist/agents/lint.d.ts +154 -0
  11. package/dist/agents/lint.d.ts.map +1 -0
  12. package/dist/agents/lint.js +761 -0
  13. package/dist/agents/lint.js.map +1 -0
  14. package/dist/agents/split.d.ts +113 -0
  15. package/dist/agents/split.d.ts.map +1 -0
  16. package/dist/agents/split.js +234 -0
  17. package/dist/agents/split.js.map +1 -0
  18. package/dist/apply.d.ts.map +1 -1
  19. package/dist/apply.js.map +1 -1
  20. package/dist/cache/prefix.d.ts.map +1 -1
  21. package/dist/cache/prefix.js.map +1 -1
  22. package/dist/cli/agents.d.ts +39 -0
  23. package/dist/cli/agents.d.ts.map +1 -0
  24. package/dist/cli/agents.js +121 -0
  25. package/dist/cli/agents.js.map +1 -0
  26. package/dist/cli/args.d.ts +17 -70
  27. package/dist/cli/args.d.ts.map +1 -1
  28. package/dist/cli/args.js +18 -338
  29. package/dist/cli/args.js.map +1 -1
  30. package/dist/cli/bin.d.ts.map +1 -1
  31. package/dist/cli/bin.js.map +1 -1
  32. package/dist/cli/config.d.ts +60 -0
  33. package/dist/cli/config.d.ts.map +1 -1
  34. package/dist/cli/config.js +89 -2
  35. package/dist/cli/config.js.map +1 -1
  36. package/dist/cli/hooks.d.ts +55 -51
  37. package/dist/cli/hooks.d.ts.map +1 -1
  38. package/dist/cli/hooks.js +206 -658
  39. package/dist/cli/hooks.js.map +1 -1
  40. package/dist/cli/init.d.ts +30 -15
  41. package/dist/cli/init.d.ts.map +1 -1
  42. package/dist/cli/init.js +167 -38
  43. package/dist/cli/init.js.map +1 -1
  44. package/dist/cli/report.d.ts +23 -0
  45. package/dist/cli/report.d.ts.map +1 -1
  46. package/dist/cli/report.js +142 -4
  47. package/dist/cli/report.js.map +1 -1
  48. package/dist/cli/run.d.ts +29 -90
  49. package/dist/cli/run.d.ts.map +1 -1
  50. package/dist/cli/run.js +34 -342
  51. package/dist/cli/run.js.map +1 -1
  52. package/dist/cli/shell.d.ts +106 -0
  53. package/dist/cli/shell.d.ts.map +1 -0
  54. package/dist/cli/shell.js +100 -0
  55. package/dist/cli/shell.js.map +1 -0
  56. package/dist/cli/subcommands/agents.d.ts +72 -0
  57. package/dist/cli/subcommands/agents.d.ts.map +1 -0
  58. package/dist/cli/subcommands/agents.js +162 -0
  59. package/dist/cli/subcommands/agents.js.map +1 -0
  60. package/dist/cli/subcommands/flags.d.ts +144 -0
  61. package/dist/cli/subcommands/flags.d.ts.map +1 -0
  62. package/dist/cli/subcommands/flags.js +220 -0
  63. package/dist/cli/subcommands/flags.js.map +1 -0
  64. package/dist/cli/subcommands/hooks.d.ts +18 -0
  65. package/dist/cli/subcommands/hooks.d.ts.map +1 -0
  66. package/dist/cli/subcommands/hooks.js +80 -0
  67. package/dist/cli/subcommands/hooks.js.map +1 -0
  68. package/dist/cli/subcommands/init.d.ts +19 -0
  69. package/dist/cli/subcommands/init.d.ts.map +1 -0
  70. package/dist/cli/subcommands/init.js +44 -0
  71. package/dist/cli/subcommands/init.js.map +1 -0
  72. package/dist/cli/subcommands/map.d.ts +75 -0
  73. package/dist/cli/subcommands/map.d.ts.map +1 -0
  74. package/dist/cli/subcommands/map.js +132 -0
  75. package/dist/cli/subcommands/map.js.map +1 -0
  76. package/dist/cli/subcommands/registry.d.ts +81 -0
  77. package/dist/cli/subcommands/registry.d.ts.map +1 -0
  78. package/dist/cli/subcommands/registry.js +141 -0
  79. package/dist/cli/subcommands/registry.js.map +1 -0
  80. package/dist/cli/subcommands/retrieve.d.ts +74 -0
  81. package/dist/cli/subcommands/retrieve.d.ts.map +1 -0
  82. package/dist/cli/subcommands/retrieve.js +84 -0
  83. package/dist/cli/subcommands/retrieve.js.map +1 -0
  84. package/dist/cli/subcommands/smelt.d.ts +107 -0
  85. package/dist/cli/subcommands/smelt.d.ts.map +1 -0
  86. package/dist/cli/subcommands/smelt.js +304 -0
  87. package/dist/cli/subcommands/smelt.js.map +1 -0
  88. package/dist/cli/subcommands/stats.d.ts +43 -0
  89. package/dist/cli/subcommands/stats.d.ts.map +1 -0
  90. package/dist/cli/subcommands/stats.js +62 -0
  91. package/dist/cli/subcommands/stats.js.map +1 -0
  92. package/dist/cli/subcommands/subcommand.d.ts +113 -0
  93. package/dist/cli/subcommands/subcommand.d.ts.map +1 -0
  94. package/dist/cli/subcommands/subcommand.js +3 -0
  95. package/dist/cli/subcommands/subcommand.js.map +1 -0
  96. package/dist/cli/usage.d.ts +3 -0
  97. package/dist/cli/usage.d.ts.map +1 -0
  98. package/dist/cli/usage.js +95 -0
  99. package/dist/cli/usage.js.map +1 -0
  100. package/dist/detect.d.ts.map +1 -1
  101. package/dist/detect.js.map +1 -1
  102. package/dist/errors.d.ts +21 -1
  103. package/dist/errors.d.ts.map +1 -1
  104. package/dist/errors.js +33 -1
  105. package/dist/errors.js.map +1 -1
  106. package/dist/harness/aider.d.ts +10 -0
  107. package/dist/harness/aider.d.ts.map +1 -0
  108. package/dist/harness/aider.js +21 -0
  109. package/dist/harness/aider.js.map +1 -0
  110. package/dist/harness/claude-code.d.ts +3 -0
  111. package/dist/harness/claude-code.d.ts.map +1 -0
  112. package/dist/harness/claude-code.js +68 -0
  113. package/dist/harness/claude-code.js.map +1 -0
  114. package/dist/harness/cline.d.ts +3 -0
  115. package/dist/harness/cline.d.ts.map +1 -0
  116. package/dist/harness/cline.js +54 -0
  117. package/dist/harness/cline.js.map +1 -0
  118. package/dist/harness/codex.d.ts +3 -0
  119. package/dist/harness/codex.d.ts.map +1 -0
  120. package/dist/harness/codex.js +92 -0
  121. package/dist/harness/codex.js.map +1 -0
  122. package/dist/harness/cursor.d.ts +3 -0
  123. package/dist/harness/cursor.d.ts.map +1 -0
  124. package/dist/harness/cursor.js +54 -0
  125. package/dist/harness/cursor.js.map +1 -0
  126. package/dist/harness/gemini.d.ts +3 -0
  127. package/dist/harness/gemini.d.ts.map +1 -0
  128. package/dist/harness/gemini.js +60 -0
  129. package/dist/harness/gemini.js.map +1 -0
  130. package/dist/harness/grok.d.ts +3 -0
  131. package/dist/harness/grok.d.ts.map +1 -0
  132. package/dist/harness/grok.js +47 -0
  133. package/dist/harness/grok.js.map +1 -0
  134. package/dist/harness/hermes.d.ts +3 -0
  135. package/dist/harness/hermes.d.ts.map +1 -0
  136. package/dist/harness/hermes.js +72 -0
  137. package/dist/harness/hermes.js.map +1 -0
  138. package/dist/harness/kilocode.d.ts +3 -0
  139. package/dist/harness/kilocode.d.ts.map +1 -0
  140. package/dist/harness/kilocode.js +35 -0
  141. package/dist/harness/kilocode.js.map +1 -0
  142. package/dist/harness/opencode.d.ts +3 -0
  143. package/dist/harness/opencode.d.ts.map +1 -0
  144. package/dist/harness/opencode.js +97 -0
  145. package/dist/harness/opencode.js.map +1 -0
  146. package/dist/harness/paths.d.ts +17 -0
  147. package/dist/harness/paths.d.ts.map +1 -0
  148. package/dist/harness/paths.js +45 -0
  149. package/dist/harness/paths.js.map +1 -0
  150. package/dist/harness/profile.d.ts +209 -0
  151. package/dist/harness/profile.d.ts.map +1 -0
  152. package/dist/harness/profile.js +41 -0
  153. package/dist/harness/profile.js.map +1 -0
  154. package/dist/harness/registry.d.ts +100 -0
  155. package/dist/harness/registry.d.ts.map +1 -0
  156. package/dist/harness/registry.js +144 -0
  157. package/dist/harness/registry.js.map +1 -0
  158. package/dist/harness/snippet.d.ts +19 -0
  159. package/dist/harness/snippet.d.ts.map +1 -0
  160. package/dist/harness/snippet.js +41 -0
  161. package/dist/harness/snippet.js.map +1 -0
  162. package/dist/hash.d.ts.map +1 -1
  163. package/dist/hash.js.map +1 -1
  164. package/dist/hooks/guard-core.d.ts +14 -14
  165. package/dist/hooks/guard-core.d.ts.map +1 -1
  166. package/dist/hooks/guard-core.js +15 -37
  167. package/dist/hooks/guard-core.js.map +1 -1
  168. package/dist/hooks/shim.d.ts +95 -4
  169. package/dist/hooks/shim.d.ts.map +1 -1
  170. package/dist/hooks/shim.js +87 -2
  171. package/dist/hooks/shim.js.map +1 -1
  172. package/dist/hooks/shims/claude-code.d.ts +5 -18
  173. package/dist/hooks/shims/claude-code.d.ts.map +1 -1
  174. package/dist/hooks/shims/claude-code.js +9 -56
  175. package/dist/hooks/shims/claude-code.js.map +1 -1
  176. package/dist/hooks/shims/cline.d.ts +5 -12
  177. package/dist/hooks/shims/cline.d.ts.map +1 -1
  178. package/dist/hooks/shims/cline.js +9 -34
  179. package/dist/hooks/shims/cline.js.map +1 -1
  180. package/dist/hooks/shims/codex.d.ts +5 -18
  181. package/dist/hooks/shims/codex.d.ts.map +1 -1
  182. package/dist/hooks/shims/codex.js +9 -51
  183. package/dist/hooks/shims/codex.js.map +1 -1
  184. package/dist/hooks/shims/cursor.d.ts +5 -14
  185. package/dist/hooks/shims/cursor.d.ts.map +1 -1
  186. package/dist/hooks/shims/cursor.js +9 -42
  187. package/dist/hooks/shims/cursor.js.map +1 -1
  188. package/dist/hooks/shims/gemini.d.ts +5 -18
  189. package/dist/hooks/shims/gemini.d.ts.map +1 -1
  190. package/dist/hooks/shims/gemini.js +9 -48
  191. package/dist/hooks/shims/gemini.js.map +1 -1
  192. package/dist/hooks/shims/grok.d.ts +5 -13
  193. package/dist/hooks/shims/grok.d.ts.map +1 -1
  194. package/dist/hooks/shims/grok.js +9 -32
  195. package/dist/hooks/shims/grok.js.map +1 -1
  196. package/dist/hooks/shims/hermes.d.ts +5 -17
  197. package/dist/hooks/shims/hermes.d.ts.map +1 -1
  198. package/dist/hooks/shims/hermes.js +9 -45
  199. package/dist/hooks/shims/hermes.js.map +1 -1
  200. package/dist/index.d.ts +43 -76
  201. package/dist/index.d.ts.map +1 -1
  202. package/dist/index.js +21 -67
  203. package/dist/index.js.map +1 -1
  204. package/dist/lang/bash.d.ts.map +1 -1
  205. package/dist/lang/bash.js.map +1 -1
  206. package/dist/lang/c.d.ts.map +1 -1
  207. package/dist/lang/c.js.map +1 -1
  208. package/dist/lang/c_sharp.d.ts.map +1 -1
  209. package/dist/lang/c_sharp.js.map +1 -1
  210. package/dist/lang/cpp.d.ts.map +1 -1
  211. package/dist/lang/cpp.js.map +1 -1
  212. package/dist/lang/go.d.ts.map +1 -1
  213. package/dist/lang/go.js.map +1 -1
  214. package/dist/lang/java.d.ts.map +1 -1
  215. package/dist/lang/java.js.map +1 -1
  216. package/dist/lang/javascript.d.ts.map +1 -1
  217. package/dist/lang/javascript.js.map +1 -1
  218. package/dist/lang/kotlin.d.ts.map +1 -1
  219. package/dist/lang/kotlin.js.map +1 -1
  220. package/dist/lang/php.d.ts.map +1 -1
  221. package/dist/lang/php.js.map +1 -1
  222. package/dist/lang/profile.d.ts.map +1 -1
  223. package/dist/lang/profile.js.map +1 -1
  224. package/dist/lang/python.d.ts.map +1 -1
  225. package/dist/lang/python.js.map +1 -1
  226. package/dist/lang/registry.d.ts.map +1 -1
  227. package/dist/lang/registry.js.map +1 -1
  228. package/dist/lang/ruby.d.ts.map +1 -1
  229. package/dist/lang/ruby.js.map +1 -1
  230. package/dist/lang/rust.d.ts.map +1 -1
  231. package/dist/lang/rust.js.map +1 -1
  232. package/dist/lang/swift.d.ts.map +1 -1
  233. package/dist/lang/swift.js.map +1 -1
  234. package/dist/lang/tsx.d.ts.map +1 -1
  235. package/dist/lang/tsx.js.map +1 -1
  236. package/dist/lang/typescript.d.ts.map +1 -1
  237. package/dist/lang/typescript.js.map +1 -1
  238. package/dist/net/policy.d.ts +18 -1
  239. package/dist/net/policy.d.ts.map +1 -1
  240. package/dist/net/policy.js +6 -4
  241. package/dist/net/policy.js.map +1 -1
  242. package/dist/ops/index.d.ts +39 -0
  243. package/dist/ops/index.d.ts.map +1 -0
  244. package/dist/ops/index.js +37 -0
  245. package/dist/ops/index.js.map +1 -0
  246. package/dist/ops/inputs.d.ts +170 -0
  247. package/dist/ops/inputs.d.ts.map +1 -0
  248. package/dist/ops/inputs.js +142 -0
  249. package/dist/ops/inputs.js.map +1 -0
  250. package/dist/ops/verbs.d.ts +136 -0
  251. package/dist/ops/verbs.d.ts.map +1 -0
  252. package/dist/ops/verbs.js +76 -0
  253. package/dist/ops/verbs.js.map +1 -0
  254. package/dist/plan/auto.d.ts +69 -0
  255. package/dist/plan/auto.d.ts.map +1 -0
  256. package/dist/plan/auto.js +70 -0
  257. package/dist/plan/auto.js.map +1 -0
  258. package/dist/plan/budget.d.ts +21 -0
  259. package/dist/plan/budget.d.ts.map +1 -0
  260. package/dist/plan/budget.js +26 -0
  261. package/dist/plan/budget.js.map +1 -0
  262. package/dist/plan/grammar.d.ts +14 -0
  263. package/dist/plan/grammar.d.ts.map +1 -1
  264. package/dist/plan/grammar.js +47 -6
  265. package/dist/plan/grammar.js.map +1 -1
  266. package/dist/plan/lexical.d.ts.map +1 -1
  267. package/dist/plan/lexical.js +1 -7
  268. package/dist/plan/lexical.js.map +1 -1
  269. package/dist/plan/planners.d.ts +35 -2
  270. package/dist/plan/planners.d.ts.map +1 -1
  271. package/dist/plan/planners.js +35 -2
  272. package/dist/plan/planners.js.map +1 -1
  273. package/dist/plan/structural.d.ts +19 -5
  274. package/dist/plan/structural.d.ts.map +1 -1
  275. package/dist/plan/structural.js +180 -33
  276. package/dist/plan/structural.js.map +1 -1
  277. package/dist/repomap/cache.d.ts +48 -0
  278. package/dist/repomap/cache.d.ts.map +1 -1
  279. package/dist/repomap/cache.js +112 -13
  280. package/dist/repomap/cache.js.map +1 -1
  281. package/dist/repomap/io.d.ts +24 -0
  282. package/dist/repomap/io.d.ts.map +1 -0
  283. package/dist/repomap/io.js +34 -0
  284. package/dist/repomap/io.js.map +1 -0
  285. package/dist/repomap/map.d.ts +69 -6
  286. package/dist/repomap/map.d.ts.map +1 -1
  287. package/dist/repomap/map.js +104 -22
  288. package/dist/repomap/map.js.map +1 -1
  289. package/dist/repomap/rank.d.ts +26 -2
  290. package/dist/repomap/rank.d.ts.map +1 -1
  291. package/dist/repomap/rank.js +20 -0
  292. package/dist/repomap/rank.js.map +1 -1
  293. package/dist/repomap/reader.d.ts +73 -0
  294. package/dist/repomap/reader.d.ts.map +1 -0
  295. package/dist/repomap/reader.js +30 -0
  296. package/dist/repomap/reader.js.map +1 -0
  297. package/dist/repomap/tags.d.ts.map +1 -1
  298. package/dist/repomap/tags.js.map +1 -1
  299. package/dist/retrieve.d.ts +8 -0
  300. package/dist/retrieve.d.ts.map +1 -1
  301. package/dist/retrieve.js +12 -1
  302. package/dist/retrieve.js.map +1 -1
  303. package/dist/smelter.d.ts +79 -0
  304. package/dist/smelter.d.ts.map +1 -0
  305. package/dist/smelter.js +65 -0
  306. package/dist/smelter.js.map +1 -0
  307. package/dist/stages.d.ts.map +1 -1
  308. package/dist/stages.js +2 -2
  309. package/dist/stages.js.map +1 -1
  310. package/dist/stats.d.ts +2 -1
  311. package/dist/stats.d.ts.map +1 -1
  312. package/dist/stats.js +2 -1
  313. package/dist/stats.js.map +1 -1
  314. package/dist/store-dir.d.ts +43 -4
  315. package/dist/store-dir.d.ts.map +1 -1
  316. package/dist/store-dir.js +48 -5
  317. package/dist/store-dir.js.map +1 -1
  318. package/dist/store.d.ts +6 -0
  319. package/dist/store.d.ts.map +1 -1
  320. package/dist/store.js +6 -0
  321. package/dist/store.js.map +1 -1
  322. package/dist/text/json-edit.d.ts +71 -0
  323. package/dist/text/json-edit.d.ts.map +1 -0
  324. package/dist/text/json-edit.js +219 -0
  325. package/dist/text/json-edit.js.map +1 -0
  326. package/dist/types.d.ts +35 -14
  327. package/dist/types.d.ts.map +1 -1
  328. package/dist/types.js.map +1 -1
  329. package/grammars/tree-sitter-bash.wasm +0 -0
  330. package/grammars/tree-sitter-c.wasm +0 -0
  331. package/grammars/tree-sitter-c_sharp.wasm +0 -0
  332. package/grammars/tree-sitter-cpp.wasm +0 -0
  333. package/grammars/tree-sitter-go.wasm +0 -0
  334. package/grammars/tree-sitter-java.wasm +0 -0
  335. package/grammars/tree-sitter-javascript.wasm +0 -0
  336. package/grammars/tree-sitter-kotlin.wasm +0 -0
  337. package/grammars/tree-sitter-php.wasm +0 -0
  338. package/grammars/tree-sitter-python.wasm +0 -0
  339. package/grammars/tree-sitter-ruby.wasm +0 -0
  340. package/grammars/tree-sitter-rust.wasm +0 -0
  341. package/grammars/tree-sitter-swift.wasm +0 -0
  342. package/grammars/tree-sitter-tsx.wasm +0 -0
  343. package/grammars/tree-sitter-typescript.wasm +0 -0
  344. package/package.json +11 -11
  345. package/dist/cli/resolve.d.ts +0 -103
  346. package/dist/cli/resolve.d.ts.map +0 -1
  347. package/dist/cli/resolve.js +0 -106
  348. package/dist/cli/resolve.js.map +0 -1
package/dist/index.d.ts CHANGED
@@ -1,20 +1,28 @@
1
1
  import type { ApplyOptions, MarkerBuilder, MarkerInfo } from './apply.ts';
2
- import type { LexicalPlannerOptions } from './plan/lexical.ts';
3
- import type { Strategy } from './plan/planners.ts';
4
- import type { StructuralPlannerOptions } from './plan/structural.ts';
5
- import type { DetectedLanguage, ElisionStore, Measure, Planner, RetrieveStats, RetrieveTool, SmeltResult } from './types.ts';
2
+ /**
3
+ * The public surface: a barrel over the modules that hold the reasoning.
4
+ *
5
+ * `createSmelter()` itself lives in `./smelter.ts` so that nothing inside `src/` has
6
+ * to import this file to build a smelter — the CLI's default verb does exactly that,
7
+ * and a barrel that imports the CLI which imports the barrel is a cycle whose only
8
+ * symptom is a registry evaluating to `undefined` in whichever module the loader
9
+ * entered first. Every name is re-exported here, so consumers see no difference.
10
+ */
6
11
  export type { ApplyOptions, MarkerBuilder, MarkerInfo };
7
12
  export { applyPlan, defaultMarker, MARKER_FORMAT_VERSION, markerPricing, reconstruct, } from './apply.ts';
8
13
  export { detectLanguage, SUPPORTED_LANGUAGES } from './detect.ts';
9
14
  export * from './errors.ts';
10
15
  export { contentHash, HASH_LENGTH } from './hash.ts';
11
16
  export { ALLOWED_NODE_BUILTINS, ALLOWED_PACKAGES, ALLOWED_URL_SCHEMES, assertLocalResource, FORBIDDEN_GLOBALS, FORBIDDEN_NODE_MODULES, FORBIDDEN_PACKAGES, } from './net/policy.ts';
17
+ export type { LocalResource } from './net/policy.ts';
12
18
  export { clearGrammarCache, grammarPath, loadGrammar, WASM_BY_LANGUAGE } from './plan/grammar.ts';
19
+ export { AUTO_PLANNER_ID, AutoPlanner, planAuto } from './plan/auto.ts';
20
+ export type { AutoPlannerOptions } from './plan/auto.ts';
13
21
  export { LEXICAL_PLANNER_ID, LexicalPlanner, planLexical } from './plan/lexical.ts';
14
22
  export type { LexicalPlannerOptions } from './plan/lexical.ts';
15
- export { isStrategy, PLANNERS, STRATEGIES } from './plan/planners.ts';
23
+ export { DEFAULT_STRATEGY, isStrategy, PLANNERS, STRATEGIES } from './plan/planners.ts';
16
24
  export type { PlannerFactoryOptions } from './plan/planners.ts';
17
- export { planStructural, STRUCTURAL_LANGUAGES, STRUCTURAL_PLANNER_ID, StructuralPlanner, } from './plan/structural.ts';
25
+ export { isStructuralLanguage, planStructural, STRUCTURAL_LANGUAGES, STRUCTURAL_PLANNER_ID, StructuralPlanner, } from './plan/structural.ts';
18
26
  export type { StructuralLanguage, StructuralPlannerOptions } from './plan/structural.ts';
19
27
  export { createRetrieveTool, RETRIEVE_TOOL_NAME } from './retrieve.ts';
20
28
  export { unconfiguredDistillStage, unconfiguredRerankStage } from './stages.ts';
@@ -23,7 +31,7 @@ export { DIRECTORY_STORE_FORMAT, DIRECTORY_STORE_VERSION, DirectoryElisionStore,
23
31
  export type { DirectoryElisionStoreOptions } from './store-dir.ts';
24
32
  export * from './types.ts';
25
33
  export { CLI_JSON_FORMAT, CLI_NAME, cliUsage, EXIT, formatReport, parseSmeltArgs, runCli, } from './cli/run.ts';
26
- export type { CliIo, CliJsonEnvelope, SmeltInvocation } from './cli/run.ts';
34
+ export type { AnswerStream, CliIo, CliJsonEnvelope, SmeltInvocation } from './cli/run.ts';
27
35
  export { ANTHROPIC_PROMPT_CACHE_FACTS, CACHE_BREAKER_RULES, detectCacheBreakers, findPrefixDivergence, } from './cache/prefix.ts';
28
36
  export type { CacheWarning, PrefixDivergence, PromptStructure, PromptTool, } from './cache/prefix.ts';
29
37
  export { MARKER_LINE_COMMENT_LEADERS, markerForLanguage } from './apply.ts';
@@ -34,88 +42,47 @@ export type { FileTagsEntry, RankedDefinition } from './repomap/rank.ts';
34
42
  export { extractTags } from './repomap/tags.ts';
35
43
  export type { DefinitionTag, FileTags, ReferenceTag } from './repomap/tags.ts';
36
44
  export { TAGS_CACHE_FORMAT, TAGS_CACHE_VERSION, tagsCacheKey } from './repomap/cache.ts';
37
- export { CONFIG_FILE_NAME, CONFIG_VERSION, findConfigFile, loadNearestConfig, parseConfig, resolveStorePath, } from './cli/config.ts';
38
- export type { LoadedConfig, SmeltConfig, SmeltConfigStore } from './cli/config.ts';
39
- export { MEASURE_STUB_FILE, measureStubSource, renderConfig, RERANK_STUB_FILE, rerankStubSource, runInit, } from './cli/init.ts';
45
+ export { nodeFsReader } from './repomap/reader.ts';
46
+ export type { DirEntry, FileStat, RepoReader } from './repomap/reader.ts';
47
+ export { CONFIG_FILE_NAME, CONFIG_VERSION, configuredStore, findConfigFile, loadNearestConfig, parseConfig, renderConfig, resolveStorePath, } from './cli/config.ts';
48
+ export type { ConfiguredStore, LoadedConfig, SmeltConfig, SmeltConfigStore } from './cli/config.ts';
49
+ export { MEASURE_STUB_FILE, measureStubSource, RERANK_STUB_FILE, rerankStubSource, runInit, } from './cli/init.ts';
40
50
  export type { InitIo } from './cli/init.ts';
41
51
  export { retrieveStats } from './stats.ts';
42
52
  export type { RawRetrieveCounters } from './stats.ts';
43
53
  export { LANGUAGE_PROFILES, profileFor, profileForPath, structuralLanguages, } from './lang/registry.ts';
44
54
  export type { LanguageProfile, LanguageStructure, RepoMapFacts } from './lang/profile.ts';
45
- export { resolveRun } from './cli/resolve.ts';
46
- export type { ResolvedRun } from './cli/resolve.ts';
55
+ /**
56
+ * The harness registry's rendered views. Public for the same reason the ops seam is:
57
+ * something outside this package renders them — the site's `facts.json` generator —
58
+ * and the alternative is a second copy of the tier table typed into a React component,
59
+ * which is exactly the drift `harnessesByTier()` exists to end.
60
+ */
61
+ export { harnessesByTier, harnessNames, HARNESSES, HARNESS_IDS } from './harness/registry.ts';
62
+ export type { HarnessTierGroup } from './harness/registry.ts';
63
+ export { harnessLabel, HARNESS_TIERS, TIER_HONESTY } from './harness/profile.ts';
64
+ export type { HarnessId, HarnessTier } from './harness/profile.ts';
65
+ export { resolveRun } from './cli/subcommands/smelt.ts';
66
+ export type { ResolvedRun } from './cli/subcommands/smelt.ts';
47
67
  export { REPO_MAP_FOCUS_RULE } from './repomap/map.ts';
48
68
  export { CLI_MAP_JSON_FORMAT, formatMapReport, resolveMapRun } from './cli/run.ts';
49
69
  export type { CliInvocation, CliMapJsonEnvelope, MapInvocation } from './cli/run.ts';
50
70
  export type { MapReportInput } from './cli/report.ts';
51
- export type { ResolvedMapRun } from './cli/resolve.ts';
71
+ export type { ResolvedMapRun } from './cli/subcommands/map.ts';
72
+ /**
73
+ * The operations seam — the four verbs and the laws their inputs must satisfy, below
74
+ * every front door. `@smeltjs/mcp` consumes these as an ordinary dependency, so the
75
+ * `smelt` CLI and the MCP tools run the same middle instead of two copies of it. See
76
+ * `src/ops/index.ts` for what belongs here and what stays in an adapter.
77
+ */
78
+ export { budgetFault, budgetMalformed, budgetRequired, mapTree, openStore, readBlob, readCounters, readTree, resolveStrategy, retrieveBytes, smeltBlob, } from './ops/index.ts';
79
+ export type { BudgetFault, BudgetNaming, MapTreeOp, ReadCountersOp, ResolvedStrategy, RetrieveBytesOp, Ruling, SmeltBlobOp, SmeltBlobOutcome, StrategySource, TreeNaming, } from './ops/index.ts';
52
80
  /**
53
81
  * Which planner a smelter uses, named by string. The names, their factories, and this
54
82
  * type all come from the one {@link PLANNERS} registry in `src/plan/planners.ts`, so
55
83
  * the CLI's validation and help text cannot drift from what `createSmelter` builds.
56
84
  */
57
85
  export type { Strategy } from './plan/planners.ts';
58
- export interface SmelterConfig {
59
- /** Where elided bytes live. Defaults to a fresh {@link MemoryElisionStore}. */
60
- readonly store?: ElisionStore;
61
- /** Used when a `smelt()` call omits `budgetBytes`. No global default is assumed. */
62
- readonly defaultBudgetBytes?: number;
63
- /**
64
- * A constructed planner instance. Wins over `strategy`: the registry is a
65
- * convenience for the shipped planners, and an instance you built yourself is
66
- * always more specific than a name.
67
- */
68
- readonly planner?: Planner;
69
- readonly strategy?: Strategy;
70
- readonly marker?: MarkerBuilder;
71
- /**
72
- * Your own counter, so results carry a number in your unit as well as in bytes.
73
- * The budget stays in bytes — see {@link Measure} and `docs/HANDOFF.md` § "Decision 1".
74
- */
75
- readonly measure?: Measure;
76
- readonly lexical?: LexicalPlannerOptions;
77
- readonly structural?: StructuralPlannerOptions;
78
- }
79
- /** Options for one `smelt()` call. `budgetBytes` may come from the smelter instead. */
80
- export interface SmeltCallOptions {
81
- readonly budgetBytes?: number;
82
- readonly path?: string;
83
- readonly language?: DetectedLanguage;
84
- readonly focus?: readonly string[];
85
- }
86
- /**
87
- * One smelter, one store, one set of counters. The store is the reason this is an
88
- * object rather than a free function: elisions are only reversible for as long as
89
- * something holds them, so the thing that cuts and the thing that remembers have the
90
- * same lifetime by construction.
91
- */
92
- export interface Smelter {
93
- /** Shrink one blob of text. Never mutates its input. */
94
- smelt(text: string, options?: SmeltCallOptions): Promise<SmeltResult>;
95
- /** The exact original text of a previous result. @throws {UnknownHashError} */
96
- reconstruct(result: SmeltResult): string;
97
- /** One elided run, counted as a retrieval. @throws {UnknownHashError} */
98
- retrieve(hash: string): string;
99
- /** The tool to expose to your model. See {@link RetrieveTool}. */
100
- readonly tool: RetrieveTool;
101
- /** Live counters, including the expansion rate. See {@link RetrieveStats}. */
102
- stats(): RetrieveStats;
103
- /** The underlying store, for consumers that persist or inspect it. */
104
- readonly store: ElisionStore;
105
- }
106
- /**
107
- * Build a smelter.
108
- *
109
- * ```ts
110
- * const smelter = createSmelter();
111
- * const result = await smelter.smelt(toolOutput, {
112
- * path: 'src/server.ts',
113
- * budgetBytes: 4_000,
114
- * focus: ['handleRequest'],
115
- * });
116
- * // result.text goes to the model; smelter.tool lets it ask for the rest back.
117
- * // smelter.stats().expansionRate tells you whether you cut too much.
118
- * ```
119
- */
120
- export declare function createSmelter(config?: SmelterConfig): Smelter;
86
+ export { createSmelter } from './smelter.ts';
87
+ export type { Smelter, SmelterConfig, SmeltCallOptions } from './smelter.ts';
121
88
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAG1E,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,mBAAmB,CAAC;AAE/D,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AACnD,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,sBAAsB,CAAC;AAGrE,OAAO,KAAK,EACV,gBAAgB,EAChB,YAAY,EACZ,OAAO,EAEP,OAAO,EACP,aAAa,EACb,YAAY,EACZ,WAAW,EACZ,MAAM,YAAY,CAAC;AAEpB,YAAY,EAAE,YAAY,EAAE,aAAa,EAAE,UAAU,EAAE,CAAC;AACxD,OAAO,EACL,SAAS,EACT,aAAa,EACb,qBAAqB,EACrB,aAAa,EACb,WAAW,GACZ,MAAM,YAAY,CAAC;AACpB,OAAO,EAAE,cAAc,EAAE,mBAAmB,EAAE,MAAM,aAAa,CAAC;AAClE,cAAc,aAAa,CAAC;AAC5B,OAAO,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,WAAW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EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAE/D;;;;;GAKG;AACH,OAAO,EACL,WAAW,EACX,eAAe,EACf,cAAc,EACd,OAAO,EACP,SAAS,EACT,QAAQ,EACR,YAAY,EACZ,QAAQ,EACR,eAAe,EACf,aAAa,EACb,SAAS,GACV,MAAM,gBAAgB,CAAC;AACxB,YAAY,EACV,WAAW,EACX,YAAY,EACZ,SAAS,EACT,cAAc,EACd,gBAAgB,EAChB,eAAe,EACf,MAAM,EACN,WAAW,EACX,gBAAgB,EAChB,cAAc,EACd,UAAU,GACX,MAAM,gBAAgB,CAAC;AAExB;;;;GAIG;AACH,YAAY,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAEnD,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAC7C,YAAY,EAAE,OAAO,EAAE,aAAa,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC","sourcesContent":["import type { ApplyOptions, MarkerBuilder, MarkerInfo } from './apply.ts';\n\n/**\n * The public surface: a barrel over the modules that hold the reasoning.\n *\n * `createSmelter()` itself lives in `./smelter.ts` so that nothing inside `src/` has\n * to import this file to build a smelter — the CLI's default verb does exactly that,\n * and a barrel that imports the CLI which imports the barrel is a cycle whose only\n * symptom is a registry evaluating to `undefined` in whichever module the loader\n * entered first. Every name is re-exported here, so consumers see no difference.\n */\n\nexport type { ApplyOptions, MarkerBuilder, MarkerInfo };\nexport {\n applyPlan,\n defaultMarker,\n MARKER_FORMAT_VERSION,\n markerPricing,\n reconstruct,\n} from './apply.ts';\nexport { detectLanguage, SUPPORTED_LANGUAGES } from './detect.ts';\nexport * from './errors.ts';\nexport { contentHash, HASH_LENGTH } from './hash.ts';\nexport {\n ALLOWED_NODE_BUILTINS,\n ALLOWED_PACKAGES,\n ALLOWED_URL_SCHEMES,\n assertLocalResource,\n FORBIDDEN_GLOBALS,\n FORBIDDEN_NODE_MODULES,\n FORBIDDEN_PACKAGES,\n} from './net/policy.ts';\nexport type { LocalResource } from './net/policy.ts';\nexport { clearGrammarCache, grammarPath, loadGrammar, WASM_BY_LANGUAGE } from './plan/grammar.ts';\nexport { AUTO_PLANNER_ID, AutoPlanner, planAuto } from './plan/auto.ts';\nexport type { AutoPlannerOptions } from './plan/auto.ts';\nexport { LEXICAL_PLANNER_ID, LexicalPlanner, planLexical } from './plan/lexical.ts';\nexport type { LexicalPlannerOptions } from './plan/lexical.ts';\nexport { DEFAULT_STRATEGY, isStrategy, PLANNERS, STRATEGIES } from './plan/planners.ts';\nexport type { PlannerFactoryOptions } from './plan/planners.ts';\nexport {\n isStructuralLanguage,\n planStructural,\n STRUCTURAL_LANGUAGES,\n STRUCTURAL_PLANNER_ID,\n StructuralPlanner,\n} from './plan/structural.ts';\nexport type { StructuralLanguage, StructuralPlannerOptions } from './plan/structural.ts';\nexport { createRetrieveTool, RETRIEVE_TOOL_NAME } from './retrieve.ts';\nexport { unconfiguredDistillStage, unconfiguredRerankStage } from './stages.ts';\nexport { MemoryElisionStore } from './store.ts';\nexport {\n DIRECTORY_STORE_FORMAT,\n DIRECTORY_STORE_VERSION,\n DirectoryElisionStore,\n} from './store-dir.ts';\nexport type { DirectoryElisionStoreOptions } from './store-dir.ts';\nexport * from './types.ts';\nexport {\n CLI_JSON_FORMAT,\n CLI_NAME,\n cliUsage,\n EXIT,\n formatReport,\n parseSmeltArgs,\n runCli,\n} from './cli/run.ts';\nexport type { AnswerStream, CliIo, CliJsonEnvelope, SmeltInvocation } from './cli/run.ts';\nexport {\n ANTHROPIC_PROMPT_CACHE_FACTS,\n CACHE_BREAKER_RULES,\n detectCacheBreakers,\n findPrefixDivergence,\n} from './cache/prefix.ts';\nexport type {\n CacheWarning,\n PrefixDivergence,\n PromptStructure,\n PromptTool,\n} from './cache/prefix.ts';\nexport { MARKER_LINE_COMMENT_LEADERS, markerForLanguage } from './apply.ts';\nexport {\n buildRepoMap,\n DEFAULT_REPO_IGNORE,\n REPO_MAP_CACHE_CORRUPT_RULE,\n REPO_MAP_ID,\n REPO_MAP_PATH_ONLY_RULE,\n REPO_MAP_RANKED_RULE,\n REPO_MAP_UNREFERENCED_RULE,\n} from './repomap/map.ts';\nexport type {\n RepoMap,\n RepoMapCacheCounts,\n RepoMapEntry,\n RepoMapOptions,\n RepoMapPathEntry,\n RepoMapReason,\n RepoMapWarning,\n} from './repomap/map.ts';\nexport { PAGERANK_DAMPING, PAGERANK_ITERATIONS, rankDefinitions } from './repomap/rank.ts';\nexport type { FileTagsEntry, RankedDefinition } from './repomap/rank.ts';\nexport { extractTags } from './repomap/tags.ts';\nexport type { DefinitionTag, FileTags, ReferenceTag } from './repomap/tags.ts';\nexport { TAGS_CACHE_FORMAT, TAGS_CACHE_VERSION, tagsCacheKey } from './repomap/cache.ts';\nexport { nodeFsReader } from './repomap/reader.ts';\nexport type { DirEntry, FileStat, RepoReader } from './repomap/reader.ts';\nexport {\n CONFIG_FILE_NAME,\n CONFIG_VERSION,\n configuredStore,\n findConfigFile,\n loadNearestConfig,\n parseConfig,\n renderConfig,\n resolveStorePath,\n} from './cli/config.ts';\nexport type { ConfiguredStore, LoadedConfig, SmeltConfig, SmeltConfigStore } from './cli/config.ts';\nexport {\n MEASURE_STUB_FILE,\n measureStubSource,\n RERANK_STUB_FILE,\n rerankStubSource,\n runInit,\n} from './cli/init.ts';\nexport type { InitIo } from './cli/init.ts';\nexport { retrieveStats } from './stats.ts';\nexport type { RawRetrieveCounters } from './stats.ts';\nexport {\n LANGUAGE_PROFILES,\n profileFor,\n profileForPath,\n structuralLanguages,\n} from './lang/registry.ts';\nexport type { LanguageProfile, LanguageStructure, RepoMapFacts } from './lang/profile.ts';\n/**\n * The harness registry's rendered views. Public for the same reason the ops seam is:\n * something outside this package renders them — the site's `facts.json` generator —\n * and the alternative is a second copy of the tier table typed into a React component,\n * which is exactly the drift `harnessesByTier()` exists to end.\n */\nexport { harnessesByTier, harnessNames, HARNESSES, HARNESS_IDS } from './harness/registry.ts';\nexport type { HarnessTierGroup } from './harness/registry.ts';\nexport { harnessLabel, HARNESS_TIERS, TIER_HONESTY } from './harness/profile.ts';\nexport type { HarnessId, HarnessTier } from './harness/profile.ts';\nexport { resolveRun } from './cli/subcommands/smelt.ts';\nexport type { ResolvedRun } from './cli/subcommands/smelt.ts';\nexport { REPO_MAP_FOCUS_RULE } from './repomap/map.ts';\nexport { CLI_MAP_JSON_FORMAT, formatMapReport, resolveMapRun } from './cli/run.ts';\nexport type { CliInvocation, CliMapJsonEnvelope, MapInvocation } from './cli/run.ts';\nexport type { MapReportInput } from './cli/report.ts';\nexport type { ResolvedMapRun } from './cli/subcommands/map.ts';\n\n/**\n * The operations seam — the four verbs and the laws their inputs must satisfy, below\n * every front door. `@smeltjs/mcp` consumes these as an ordinary dependency, so the\n * `smelt` CLI and the MCP tools run the same middle instead of two copies of it. See\n * `src/ops/index.ts` for what belongs here and what stays in an adapter.\n */\nexport {\n budgetFault,\n budgetMalformed,\n budgetRequired,\n mapTree,\n openStore,\n readBlob,\n readCounters,\n readTree,\n resolveStrategy,\n retrieveBytes,\n smeltBlob,\n} from './ops/index.ts';\nexport type {\n BudgetFault,\n BudgetNaming,\n MapTreeOp,\n ReadCountersOp,\n ResolvedStrategy,\n RetrieveBytesOp,\n Ruling,\n SmeltBlobOp,\n SmeltBlobOutcome,\n StrategySource,\n TreeNaming,\n} from './ops/index.ts';\n\n/**\n * Which planner a smelter uses, named by string. The names, their factories, and this\n * type all come from the one {@link PLANNERS} registry in `src/plan/planners.ts`, so\n * the CLI's validation and help text cannot drift from what `createSmelter` builds.\n */\nexport type { Strategy } from './plan/planners.ts';\n\nexport { createSmelter } from './smelter.ts';\nexport type { Smelter, SmelterConfig, SmeltCallOptions } from './smelter.ts';\n"]}
package/dist/index.js CHANGED
@@ -1,18 +1,13 @@
1
- import { applyPlan, markerForLanguage, markerPricing, reconstruct } from './apply.js';
2
- import { detectLanguage } from './detect.js';
3
- import { SmeltError } from './errors.js';
4
- import { PLANNERS } from './plan/planners.js';
5
- import { createRetrieveTool } from './retrieve.js';
6
- import { MemoryElisionStore } from './store.js';
7
1
  export { applyPlan, defaultMarker, MARKER_FORMAT_VERSION, markerPricing, reconstruct, } from './apply.js';
8
2
  export { detectLanguage, SUPPORTED_LANGUAGES } from './detect.js';
9
3
  export * from './errors.js';
10
4
  export { contentHash, HASH_LENGTH } from './hash.js';
11
5
  export { ALLOWED_NODE_BUILTINS, ALLOWED_PACKAGES, ALLOWED_URL_SCHEMES, assertLocalResource, FORBIDDEN_GLOBALS, FORBIDDEN_NODE_MODULES, FORBIDDEN_PACKAGES, } from './net/policy.js';
12
6
  export { clearGrammarCache, grammarPath, loadGrammar, WASM_BY_LANGUAGE } from './plan/grammar.js';
7
+ export { AUTO_PLANNER_ID, AutoPlanner, planAuto } from './plan/auto.js';
13
8
  export { LEXICAL_PLANNER_ID, LexicalPlanner, planLexical } from './plan/lexical.js';
14
- export { isStrategy, PLANNERS, STRATEGIES } from './plan/planners.js';
15
- export { planStructural, STRUCTURAL_LANGUAGES, STRUCTURAL_PLANNER_ID, StructuralPlanner, } from './plan/structural.js';
9
+ export { DEFAULT_STRATEGY, isStrategy, PLANNERS, STRATEGIES } from './plan/planners.js';
10
+ export { isStructuralLanguage, planStructural, STRUCTURAL_LANGUAGES, STRUCTURAL_PLANNER_ID, StructuralPlanner, } from './plan/structural.js';
16
11
  export { createRetrieveTool, RETRIEVE_TOOL_NAME } from './retrieve.js';
17
12
  export { unconfiguredDistillStage, unconfiguredRerankStage } from './stages.js';
18
13
  export { MemoryElisionStore } from './store.js';
@@ -25,69 +20,28 @@ export { buildRepoMap, DEFAULT_REPO_IGNORE, REPO_MAP_CACHE_CORRUPT_RULE, REPO_MA
25
20
  export { PAGERANK_DAMPING, PAGERANK_ITERATIONS, rankDefinitions } from './repomap/rank.js';
26
21
  export { extractTags } from './repomap/tags.js';
27
22
  export { TAGS_CACHE_FORMAT, TAGS_CACHE_VERSION, tagsCacheKey } from './repomap/cache.js';
28
- export { CONFIG_FILE_NAME, CONFIG_VERSION, findConfigFile, loadNearestConfig, parseConfig, resolveStorePath, } from './cli/config.js';
29
- export { MEASURE_STUB_FILE, measureStubSource, renderConfig, RERANK_STUB_FILE, rerankStubSource, runInit, } from './cli/init.js';
23
+ export { nodeFsReader } from './repomap/reader.js';
24
+ export { CONFIG_FILE_NAME, CONFIG_VERSION, configuredStore, findConfigFile, loadNearestConfig, parseConfig, renderConfig, resolveStorePath, } from './cli/config.js';
25
+ export { MEASURE_STUB_FILE, measureStubSource, RERANK_STUB_FILE, rerankStubSource, runInit, } from './cli/init.js';
30
26
  export { retrieveStats } from './stats.js';
31
27
  export { LANGUAGE_PROFILES, profileFor, profileForPath, structuralLanguages, } from './lang/registry.js';
32
- export { resolveRun } from './cli/resolve.js';
28
+ /**
29
+ * The harness registry's rendered views. Public for the same reason the ops seam is:
30
+ * something outside this package renders them — the site's `facts.json` generator —
31
+ * and the alternative is a second copy of the tier table typed into a React component,
32
+ * which is exactly the drift `harnessesByTier()` exists to end.
33
+ */
34
+ export { harnessesByTier, harnessNames, HARNESSES, HARNESS_IDS } from './harness/registry.js';
35
+ export { harnessLabel, HARNESS_TIERS, TIER_HONESTY } from './harness/profile.js';
36
+ export { resolveRun } from './cli/subcommands/smelt.js';
33
37
  export { REPO_MAP_FOCUS_RULE } from './repomap/map.js';
34
38
  export { CLI_MAP_JSON_FORMAT, formatMapReport, resolveMapRun } from './cli/run.js';
35
39
  /**
36
- * Build a smelter.
37
- *
38
- * ```ts
39
- * const smelter = createSmelter();
40
- * const result = await smelter.smelt(toolOutput, {
41
- * path: 'src/server.ts',
42
- * budgetBytes: 4_000,
43
- * focus: ['handleRequest'],
44
- * });
45
- * // result.text goes to the model; smelter.tool lets it ask for the rest back.
46
- * // smelter.stats().expansionRate tells you whether you cut too much.
47
- * ```
40
+ * The operations seam — the four verbs and the laws their inputs must satisfy, below
41
+ * every front door. `@smeltjs/mcp` consumes these as an ordinary dependency, so the
42
+ * `smelt` CLI and the MCP tools run the same middle instead of two copies of it. See
43
+ * `src/ops/index.ts` for what belongs here and what stays in an adapter.
48
44
  */
49
- export function createSmelter(config = {}) {
50
- const store = config.store ?? new MemoryElisionStore();
51
- // A constructed instance wins over a strategy name; the registry serves the names.
52
- const planner = config.planner ?? PLANNERS[config.strategy ?? 'lexical'](config);
53
- const applyOptions = {
54
- ...(config.marker === undefined ? {} : { marker: config.marker }),
55
- ...(config.measure === undefined ? {} : { measure: config.measure }),
56
- };
57
- return {
58
- store,
59
- tool: createRetrieveTool(store),
60
- stats: () => store.stats(),
61
- retrieve: (hash) => store.retrieve(hash),
62
- reconstruct: (result) => reconstruct(result, store),
63
- async smelt(text, options = {}) {
64
- const budgetBytes = options.budgetBytes ?? config.defaultBudgetBytes;
65
- if (budgetBytes === undefined) {
66
- throw new SmeltError('smelt: no budget. Pass `budgetBytes` to smelt() or `defaultBudgetBytes` to ' +
67
- 'createSmelter(). There is no built-in default, because a budget smelt ' +
68
- 'invented would silently decide how much of your context to throw away.');
69
- }
70
- const language = options.language ?? detectLanguage(options.path);
71
- const input = {
72
- text,
73
- language,
74
- budgetBytes,
75
- // The MarkerPricing seam, constructed centrally — here, and nowhere else in
76
- // the shipped pipeline — from the exact builder the applyPlan call below will
77
- // use: a caller-supplied `config.marker` prices with its own rendering (a
78
- // longer custom marker makes small cuts unprofitable, and the planner must
79
- // see that), otherwise the language's leader-wrapped default.
80
- pricing: markerPricing(language, config.marker),
81
- ...(options.focus === undefined ? {} : { focus: options.focus }),
82
- };
83
- const plan = await planner.plan(input);
84
- // The marker follows the *result's* language: it lands behind the language's
85
- // line-comment leader (see MARKER_LINE_COMMENT_LEADERS), because a bare marker
86
- // line breaks the survivor's syntax in every grammar tested. A caller-supplied
87
- // marker builder always wins.
88
- const marker = config.marker ?? markerForLanguage(plan.language);
89
- return applyPlan(text, plan, store, { ...applyOptions, marker });
90
- },
91
- };
92
- }
45
+ export { budgetFault, budgetMalformed, budgetRequired, mapTree, openStore, readBlob, readCounters, readTree, resolveStrategy, retrieveBytes, smeltBlob, } from './ops/index.js';
46
+ export { createSmelter } from './smelter.js';
93
47
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,iBAAiB,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAEtF,OAAO,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAC7C,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAEzC,OAAO,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAG9C,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AACnD,OAAO,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAahD,OAAO,EACL,SAAS,EACT,aAAa,EACb,qBAAqB,EACrB,aAAa,EACb,WAAW,GACZ,MAAM,YAAY,CAAC;AACpB,OAAO,EAAE,cAAc,EAAE,mBAAmB,EAAE,MAAM,aAAa,CAAC;AAClE,cAAc,aAAa,CAAC;AAC5B,OAAO,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AACrD,OAAO,EACL,qBAAqB,EACrB,gBAAgB,EAChB,mBAAmB,EACnB,mBAAmB,EACnB,iBAAiB,EACjB,sBAAsB,EACtB,kBAAkB,GACnB,MAAM,iBAAiB,CAAC;AACzB,OAAO,EAAE,iBAAiB,EAAE,WAAW,EAAE,WAAW,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AAClG,OAAO,EAAE,kBAAkB,EAAE,cAAc,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAEpF,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAEtE,OAAO,EACL,cAAc,EACd,oBAAoB,EACpB,qBAAqB,EACrB,iBAAiB,GAClB,MAAM,sBAAsB,CAAC;AA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ACR,YAAY,EACZ,QAAQ,EACR,eAAe,EACf,aAAa,EACb,SAAS,GACV,MAAM,gBAAgB,CAAC;AAsBxB,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC","sourcesContent":["import type { ApplyOptions, MarkerBuilder, MarkerInfo } from './apply.ts';\n\n/**\n * The public surface: a barrel over the modules that hold the reasoning.\n *\n * `createSmelter()` itself lives in `./smelter.ts` so that nothing inside `src/` has\n * to import this file to build a smelter — the CLI's default verb does exactly that,\n * and a barrel that imports the CLI which imports the barrel is a cycle whose only\n * symptom is a registry evaluating to `undefined` in whichever module the loader\n * entered first. Every name is re-exported here, so consumers see no difference.\n */\n\nexport type { ApplyOptions, MarkerBuilder, MarkerInfo };\nexport {\n applyPlan,\n defaultMarker,\n MARKER_FORMAT_VERSION,\n markerPricing,\n reconstruct,\n} from './apply.ts';\nexport { detectLanguage, SUPPORTED_LANGUAGES } from './detect.ts';\nexport * from './errors.ts';\nexport { contentHash, HASH_LENGTH } from './hash.ts';\nexport {\n ALLOWED_NODE_BUILTINS,\n ALLOWED_PACKAGES,\n ALLOWED_URL_SCHEMES,\n assertLocalResource,\n FORBIDDEN_GLOBALS,\n FORBIDDEN_NODE_MODULES,\n FORBIDDEN_PACKAGES,\n} from './net/policy.ts';\nexport type { LocalResource } from './net/policy.ts';\nexport { clearGrammarCache, grammarPath, loadGrammar, WASM_BY_LANGUAGE } from './plan/grammar.ts';\nexport { AUTO_PLANNER_ID, AutoPlanner, planAuto } from './plan/auto.ts';\nexport type { AutoPlannerOptions } from './plan/auto.ts';\nexport { LEXICAL_PLANNER_ID, LexicalPlanner, planLexical } from './plan/lexical.ts';\nexport type { LexicalPlannerOptions } from './plan/lexical.ts';\nexport { DEFAULT_STRATEGY, isStrategy, PLANNERS, STRATEGIES } from './plan/planners.ts';\nexport type { PlannerFactoryOptions } from './plan/planners.ts';\nexport {\n isStructuralLanguage,\n planStructural,\n STRUCTURAL_LANGUAGES,\n STRUCTURAL_PLANNER_ID,\n StructuralPlanner,\n} from './plan/structural.ts';\nexport type { StructuralLanguage, StructuralPlannerOptions } from './plan/structural.ts';\nexport { createRetrieveTool, RETRIEVE_TOOL_NAME } from './retrieve.ts';\nexport { unconfiguredDistillStage, unconfiguredRerankStage } from './stages.ts';\nexport { MemoryElisionStore } from './store.ts';\nexport {\n DIRECTORY_STORE_FORMAT,\n DIRECTORY_STORE_VERSION,\n DirectoryElisionStore,\n} from './store-dir.ts';\nexport type { DirectoryElisionStoreOptions } from './store-dir.ts';\nexport * from './types.ts';\nexport {\n CLI_JSON_FORMAT,\n CLI_NAME,\n cliUsage,\n EXIT,\n formatReport,\n parseSmeltArgs,\n runCli,\n} from './cli/run.ts';\nexport type { AnswerStream, CliIo, CliJsonEnvelope, SmeltInvocation } from './cli/run.ts';\nexport {\n ANTHROPIC_PROMPT_CACHE_FACTS,\n CACHE_BREAKER_RULES,\n detectCacheBreakers,\n findPrefixDivergence,\n} from './cache/prefix.ts';\nexport type {\n CacheWarning,\n PrefixDivergence,\n PromptStructure,\n PromptTool,\n} from './cache/prefix.ts';\nexport { MARKER_LINE_COMMENT_LEADERS, markerForLanguage } from './apply.ts';\nexport {\n buildRepoMap,\n DEFAULT_REPO_IGNORE,\n REPO_MAP_CACHE_CORRUPT_RULE,\n REPO_MAP_ID,\n REPO_MAP_PATH_ONLY_RULE,\n REPO_MAP_RANKED_RULE,\n REPO_MAP_UNREFERENCED_RULE,\n} from './repomap/map.ts';\nexport type {\n RepoMap,\n RepoMapCacheCounts,\n RepoMapEntry,\n RepoMapOptions,\n RepoMapPathEntry,\n RepoMapReason,\n RepoMapWarning,\n} from './repomap/map.ts';\nexport { PAGERANK_DAMPING, PAGERANK_ITERATIONS, rankDefinitions } from './repomap/rank.ts';\nexport type { FileTagsEntry, RankedDefinition } from './repomap/rank.ts';\nexport { extractTags } from './repomap/tags.ts';\nexport type { DefinitionTag, FileTags, ReferenceTag } from './repomap/tags.ts';\nexport { TAGS_CACHE_FORMAT, TAGS_CACHE_VERSION, tagsCacheKey } from './repomap/cache.ts';\nexport { nodeFsReader } from './repomap/reader.ts';\nexport type { DirEntry, FileStat, RepoReader } from './repomap/reader.ts';\nexport {\n CONFIG_FILE_NAME,\n CONFIG_VERSION,\n configuredStore,\n findConfigFile,\n loadNearestConfig,\n parseConfig,\n renderConfig,\n resolveStorePath,\n} from './cli/config.ts';\nexport type { ConfiguredStore, LoadedConfig, SmeltConfig, SmeltConfigStore } from './cli/config.ts';\nexport {\n MEASURE_STUB_FILE,\n measureStubSource,\n RERANK_STUB_FILE,\n rerankStubSource,\n runInit,\n} from './cli/init.ts';\nexport type { InitIo } from './cli/init.ts';\nexport { retrieveStats } from './stats.ts';\nexport type { RawRetrieveCounters } from './stats.ts';\nexport {\n LANGUAGE_PROFILES,\n profileFor,\n profileForPath,\n structuralLanguages,\n} from './lang/registry.ts';\nexport type { LanguageProfile, LanguageStructure, RepoMapFacts } from './lang/profile.ts';\n/**\n * The harness registry's rendered views. Public for the same reason the ops seam is:\n * something outside this package renders them — the site's `facts.json` generator —\n * and the alternative is a second copy of the tier table typed into a React component,\n * which is exactly the drift `harnessesByTier()` exists to end.\n */\nexport { harnessesByTier, harnessNames, HARNESSES, HARNESS_IDS } from './harness/registry.ts';\nexport type { HarnessTierGroup } from './harness/registry.ts';\nexport { harnessLabel, HARNESS_TIERS, TIER_HONESTY } from './harness/profile.ts';\nexport type { HarnessId, HarnessTier } from './harness/profile.ts';\nexport { resolveRun } from './cli/subcommands/smelt.ts';\nexport type { ResolvedRun } from './cli/subcommands/smelt.ts';\nexport { REPO_MAP_FOCUS_RULE } from './repomap/map.ts';\nexport { CLI_MAP_JSON_FORMAT, formatMapReport, resolveMapRun } from './cli/run.ts';\nexport type { CliInvocation, CliMapJsonEnvelope, MapInvocation } from './cli/run.ts';\nexport type { MapReportInput } from './cli/report.ts';\nexport type { ResolvedMapRun } from './cli/subcommands/map.ts';\n\n/**\n * The operations seam — the four verbs and the laws their inputs must satisfy, below\n * every front door. `@smeltjs/mcp` consumes these as an ordinary dependency, so the\n * `smelt` CLI and the MCP tools run the same middle instead of two copies of it. See\n * `src/ops/index.ts` for what belongs here and what stays in an adapter.\n */\nexport {\n budgetFault,\n budgetMalformed,\n budgetRequired,\n mapTree,\n openStore,\n readBlob,\n readCounters,\n readTree,\n resolveStrategy,\n retrieveBytes,\n smeltBlob,\n} from './ops/index.ts';\nexport type {\n BudgetFault,\n BudgetNaming,\n MapTreeOp,\n ReadCountersOp,\n ResolvedStrategy,\n RetrieveBytesOp,\n Ruling,\n SmeltBlobOp,\n SmeltBlobOutcome,\n StrategySource,\n TreeNaming,\n} from './ops/index.ts';\n\n/**\n * Which planner a smelter uses, named by string. The names, their factories, and this\n * type all come from the one {@link PLANNERS} registry in `src/plan/planners.ts`, so\n * the CLI's validation and help text cannot drift from what `createSmelter` builds.\n */\nexport type { Strategy } from './plan/planners.ts';\n\nexport { createSmelter } from './smelter.ts';\nexport type { Smelter, SmelterConfig, SmeltCallOptions } from './smelter.ts';\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"bash.d.ts","sourceRoot":"","sources":["../../src/lang/bash.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEpD,eAAO,MAAM,IAAI,EAAE,eA0BlB,CAAC"}
1
+ {"version":3,"file":"bash.d.ts","sourceRoot":"","sources":["../../src/lang/bash.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEpD,eAAO,MAAM,IAAI,EAAE,eA0BlB,CAAC","sourcesContent":["import type { LanguageProfile } from './profile.ts';\n\nexport const bash: LanguageProfile = {\n id: 'bash',\n extensions: ['sh', 'bash'],\n wasm: 'tree-sitter-bash.wasm',\n markerLeader: '# ',\n structure: {\n commentTypes: new Set(['comment']),\n attributeTypes: new Set(),\n // The shebang decides which interpreter runs the file. It parses as an ordinary\n // comment node, so it is pinned the way go's build tag is — never collapsed.\n pinnedCommentPattern: /^#!/,\n wrapperTypes: {},\n kindLabels: {\n function_definition: 'function',\n command: 'command',\n variable_assignment: 'variable assignment',\n declaration_command: 'variable assignment',\n comment: 'comment',\n },\n },\n // No def kinds: bash function names are `word` nodes, not identifiers, so they are\n // omitted from the map rather than guessed at.\n repomap: {\n defKinds: {},\n refTypes: ['variable_name'],\n },\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"bash.js","sourceRoot":"","sources":["../../src/lang/bash.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,IAAI,GAAoB;IACnC,EAAE,EAAE,MAAM;IACV,UAAU,EAAE,CAAC,IAAI,EAAE,MAAM,CAAC;IAC1B,IAAI,EAAE,uBAAuB;IAC7B,YAAY,EAAE,IAAI;IAClB,SAAS,EAAE;QACT,YAAY,EAAE,IAAI,GAAG,CAAC,CAAC,SAAS,CAAC,CAAC;QAClC,cAAc,EAAE,IAAI,GAAG,EAAE;QACzB,gFAAgF;QAChF,6EAA6E;QAC7E,oBAAoB,EAAE,KAAK;QAC3B,YAAY,EAAE,EAAE;QAChB,UAAU,EAAE;YACV,mBAAmB,EAAE,UAAU;YAC/B,OAAO,EAAE,SAAS;YAClB,mBAAmB,EAAE,qBAAqB;YAC1C,mBAAmB,EAAE,qBAAqB;YAC1C,OAAO,EAAE,SAAS;SACnB;KACF;IACD,mFAAmF;IACnF,+CAA+C;IAC/C,OAAO,EAAE;QACP,QAAQ,EAAE,EAAE;QACZ,QAAQ,EAAE,CAAC,eAAe,CAAC;KAC5B;CACF,CAAC"}
1
+ {"version":3,"file":"bash.js","sourceRoot":"","sources":["../../src/lang/bash.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,IAAI,GAAoB;IACnC,EAAE,EAAE,MAAM;IACV,UAAU,EAAE,CAAC,IAAI,EAAE,MAAM,CAAC;IAC1B,IAAI,EAAE,uBAAuB;IAC7B,YAAY,EAAE,IAAI;IAClB,SAAS,EAAE;QACT,YAAY,EAAE,IAAI,GAAG,CAAC,CAAC,SAAS,CAAC,CAAC;QAClC,cAAc,EAAE,IAAI,GAAG,EAAE;QACzB,gFAAgF;QAChF,6EAA6E;QAC7E,oBAAoB,EAAE,KAAK;QAC3B,YAAY,EAAE,EAAE;QAChB,UAAU,EAAE;YACV,mBAAmB,EAAE,UAAU;YAC/B,OAAO,EAAE,SAAS;YAClB,mBAAmB,EAAE,qBAAqB;YAC1C,mBAAmB,EAAE,qBAAqB;YAC1C,OAAO,EAAE,SAAS;SACnB;KACF;IACD,mFAAmF;IACnF,+CAA+C;IAC/C,OAAO,EAAE;QACP,QAAQ,EAAE,EAAE;QACZ,QAAQ,EAAE,CAAC,eAAe,CAAC;KAC5B;CACF,CAAC","sourcesContent":["import type { LanguageProfile } from './profile.ts';\n\nexport const bash: LanguageProfile = {\n id: 'bash',\n extensions: ['sh', 'bash'],\n wasm: 'tree-sitter-bash.wasm',\n markerLeader: '# ',\n structure: {\n commentTypes: new Set(['comment']),\n attributeTypes: new Set(),\n // The shebang decides which interpreter runs the file. It parses as an ordinary\n // comment node, so it is pinned the way go's build tag is — never collapsed.\n pinnedCommentPattern: /^#!/,\n wrapperTypes: {},\n kindLabels: {\n function_definition: 'function',\n command: 'command',\n variable_assignment: 'variable assignment',\n declaration_command: 'variable assignment',\n comment: 'comment',\n },\n },\n // No def kinds: bash function names are `word` nodes, not identifiers, so they are\n // omitted from the map rather than guessed at.\n repomap: {\n defKinds: {},\n refTypes: ['variable_name'],\n },\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"c.d.ts","sourceRoot":"","sources":["../../src/lang/c.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEpD,eAAO,MAAM,CAAC,EAAE,eAqCf,CAAC"}
1
+ {"version":3,"file":"c.d.ts","sourceRoot":"","sources":["../../src/lang/c.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEpD,eAAO,MAAM,CAAC,EAAE,eAqCf,CAAC","sourcesContent":["import type { LanguageProfile } from './profile.ts';\n\nexport const c: LanguageProfile = {\n id: 'c',\n extensions: ['c', 'h'],\n wasm: 'tree-sitter-c.wasm',\n markerLeader: '// ',\n structure: {\n commentTypes: new Set(['comment']),\n attributeTypes: new Set(),\n // Every `#pragma` is a preproc_call; only `#pragma once` governs what including\n // the file *means*, so only it is pinned — the `//go:build` law again.\n pinnedPatternsByType: { preproc_call: /^#\\s*pragma\\s+once\\b/ },\n wrapperTypes: {},\n kindLabels: {\n function_definition: 'function',\n declaration: 'declaration',\n struct_specifier: 'struct',\n union_specifier: 'union',\n enum_specifier: 'enum',\n type_definition: 'type definition',\n preproc_include: 'include directive',\n preproc_def: 'macro definition',\n preproc_function_def: 'macro definition',\n // `#pragma`, `#if`/`#ifdef` regions — read off the tree, never \"declaration\".\n preproc_call: 'preprocessor directive',\n preproc_if: 'preprocessor conditional',\n preproc_ifdef: 'preprocessor conditional',\n preproc_else: 'preprocessor conditional',\n },\n },\n repomap: {\n defKinds: {\n struct_specifier: 'struct',\n union_specifier: 'union',\n enum_specifier: 'enum',\n },\n refTypes: ['identifier', 'type_identifier'],\n },\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"c.js","sourceRoot":"","sources":["../../src/lang/c.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,CAAC,GAAoB;IAChC,EAAE,EAAE,GAAG;IACP,UAAU,EAAE,CAAC,GAAG,EAAE,GAAG,CAAC;IACtB,IAAI,EAAE,oBAAoB;IAC1B,YAAY,EAAE,KAAK;IACnB,SAAS,EAAE;QACT,YAAY,EAAE,IAAI,GAAG,CAAC,CAAC,SAAS,CAAC,CAAC;QAClC,cAAc,EAAE,IAAI,GAAG,EAAE;QACzB,gFAAgF;QAChF,uEAAuE;QACvE,oBAAoB,EAAE,EAAE,YAAY,EAAE,sBAAsB,EAAE;QAC9D,YAAY,EAAE,EAAE;QAChB,UAAU,EAA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;YAC/B,oBAAoB,EAAE,kBAAkB;YACxC,8EAA8E;YAC9E,YAAY,EAAE,wBAAwB;YACtC,UAAU,EAAE,0BAA0B;YACtC,aAAa,EAAE,0BAA0B;YACzC,YAAY,EAAE,0BAA0B;SACzC;KACF;IACD,OAAO,EAAE;QACP,QAAQ,EAAE;YACR,gBAAgB,EAAE,QAAQ;YAC1B,eAAe,EAAE,OAAO;YACxB,cAAc,EAAE,MAAM;SACvB;QACD,QAAQ,EAAE,CAAC,YAAY,EAAE,iBAAiB,CAAC;KAC5C;CACF,CAAC","sourcesContent":["import type { LanguageProfile } from './profile.ts';\n\nexport const c: LanguageProfile = {\n id: 'c',\n extensions: ['c', 'h'],\n wasm: 'tree-sitter-c.wasm',\n markerLeader: '// ',\n structure: {\n commentTypes: new Set(['comment']),\n attributeTypes: new Set(),\n // Every `#pragma` is a preproc_call; only `#pragma once` governs what including\n // the file *means*, so only it is pinned — the `//go:build` law again.\n pinnedPatternsByType: { preproc_call: /^#\\s*pragma\\s+once\\b/ },\n wrapperTypes: {},\n kindLabels: {\n function_definition: 'function',\n declaration: 'declaration',\n struct_specifier: 'struct',\n union_specifier: 'union',\n enum_specifier: 'enum',\n type_definition: 'type definition',\n preproc_include: 'include directive',\n preproc_def: 'macro definition',\n preproc_function_def: 'macro definition',\n // `#pragma`, `#if`/`#ifdef` regions — read off the tree, never \"declaration\".\n preproc_call: 'preprocessor directive',\n preproc_if: 'preprocessor conditional',\n preproc_ifdef: 'preprocessor conditional',\n preproc_else: 'preprocessor conditional',\n },\n },\n repomap: {\n defKinds: {\n struct_specifier: 'struct',\n union_specifier: 'union',\n enum_specifier: 'enum',\n },\n refTypes: ['identifier', 'type_identifier'],\n },\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"c_sharp.d.ts","sourceRoot":"","sources":["../../src/lang/c_sharp.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEpD,eAAO,MAAM,OAAO,EAAE,eAmCrB,CAAC"}
1
+ {"version":3,"file":"c_sharp.d.ts","sourceRoot":"","sources":["../../src/lang/c_sharp.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEpD,eAAO,MAAM,OAAO,EAAE,eAmCrB,CAAC","sourcesContent":["import type { LanguageProfile } from './profile.ts';\n\nexport const c_sharp: LanguageProfile = {\n id: 'c_sharp',\n extensions: ['cs'],\n wasm: 'tree-sitter-c_sharp.wasm',\n markerLeader: '// ',\n structure: {\n // `///` doc comments and `//` line comments are both plain comment nodes.\n commentTypes: new Set(['comment']),\n attributeTypes: new Set(),\n wrapperTypes: {},\n kindLabels: {\n class_declaration: 'class',\n interface_declaration: 'interface',\n struct_declaration: 'struct',\n enum_declaration: 'enum',\n record_declaration: 'record',\n delegate_declaration: 'delegate',\n namespace_declaration: 'namespace',\n file_scoped_namespace_declaration: 'namespace',\n using_directive: 'using directive',\n global_statement: 'statement',\n },\n },\n repomap: {\n defKinds: {\n class_declaration: 'class',\n interface_declaration: 'interface',\n struct_declaration: 'struct',\n enum_declaration: 'enum',\n record_declaration: 'record',\n delegate_declaration: 'delegate',\n method_declaration: 'method',\n },\n refTypes: ['identifier'],\n },\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"c_sharp.js","sourceRoot":"","sources":["../../src/lang/c_sharp.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,OAAO,GAAoB;IACtC,EAAE,EAAE,SAAS;IACb,UAAU,EAAE,CAAC,IAAI,CAAC;IAClB,IAAI,EAAE,0BAA0B;IAChC,YAAY,EAAE,KAAK;IACnB,SAAS,EAAE;QACT,0EAA0E;QAC1E,YAAY,EAAE,IAAI,GAAG,CAAC,CAAC,SAAS,CAAC,CAAC;QAClC,cAAc,EAAE,IAAI,GAAG,EAAE;QACzB,YAAY,EAAE,EAAE;QAChB,UAAU,EAAE;YACV,iBAAiB,EAAE,OAAO;YAC1B,qBA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,QAAQ,EAAE;YACR,iBAAiB,EAAE,OAAO;YAC1B,qBAAqB,EAAE,WAAW;YAClC,kBAAkB,EAAE,QAAQ;YAC5B,gBAAgB,EAAE,MAAM;YACxB,kBAAkB,EAAE,QAAQ;YAC5B,oBAAoB,EAAE,UAAU;YAChC,kBAAkB,EAAE,QAAQ;SAC7B;QACD,QAAQ,EAAE,CAAC,YAAY,CAAC;KACzB;CACF,CAAC","sourcesContent":["import type { LanguageProfile } from './profile.ts';\n\nexport const c_sharp: LanguageProfile = {\n id: 'c_sharp',\n extensions: ['cs'],\n wasm: 'tree-sitter-c_sharp.wasm',\n markerLeader: '// ',\n structure: {\n // `///` doc comments and `//` line comments are both plain comment nodes.\n commentTypes: new Set(['comment']),\n attributeTypes: new Set(),\n wrapperTypes: {},\n kindLabels: {\n class_declaration: 'class',\n interface_declaration: 'interface',\n struct_declaration: 'struct',\n enum_declaration: 'enum',\n record_declaration: 'record',\n delegate_declaration: 'delegate',\n namespace_declaration: 'namespace',\n file_scoped_namespace_declaration: 'namespace',\n using_directive: 'using directive',\n global_statement: 'statement',\n },\n },\n repomap: {\n defKinds: {\n class_declaration: 'class',\n interface_declaration: 'interface',\n struct_declaration: 'struct',\n enum_declaration: 'enum',\n record_declaration: 'record',\n delegate_declaration: 'delegate',\n method_declaration: 'method',\n },\n refTypes: ['identifier'],\n },\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"cpp.d.ts","sourceRoot":"","sources":["../../src/lang/cpp.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEpD,eAAO,MAAM,GAAG,EAAE,eA4CjB,CAAC"}
1
+ {"version":3,"file":"cpp.d.ts","sourceRoot":"","sources":["../../src/lang/cpp.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEpD,eAAO,MAAM,GAAG,EAAE,eA4CjB,CAAC","sourcesContent":["import type { LanguageProfile } from './profile.ts';\n\nexport const cpp: LanguageProfile = {\n id: 'cpp',\n extensions: ['cc', 'cpp', 'hpp'],\n wasm: 'tree-sitter-cpp.wasm',\n markerLeader: '// ',\n structure: {\n commentTypes: new Set(['comment']),\n attributeTypes: new Set(),\n // Same preprocessor, same `#pragma once` pin as c.\n pinnedPatternsByType: { preproc_call: /^#\\s*pragma\\s+once\\b/ },\n // `template <typename T> class Box {}` — the marker should say what the template\n // declares, not just that it is a template.\n wrapperTypes: { template_declaration: 'template' },\n kindLabels: {\n function_definition: 'function',\n declaration: 'declaration',\n struct_specifier: 'struct',\n class_specifier: 'class',\n union_specifier: 'union',\n enum_specifier: 'enum',\n type_definition: 'type definition',\n alias_declaration: 'type alias',\n namespace_definition: 'namespace',\n using_declaration: 'using declaration',\n linkage_specification: 'extern block',\n preproc_include: 'include directive',\n preproc_def: 'macro definition',\n preproc_function_def: 'macro definition',\n preproc_call: 'preprocessor directive',\n preproc_if: 'preprocessor conditional',\n preproc_ifdef: 'preprocessor conditional',\n preproc_else: 'preprocessor conditional',\n },\n },\n repomap: {\n defKinds: {\n class_specifier: 'class',\n struct_specifier: 'struct',\n union_specifier: 'union',\n enum_specifier: 'enum',\n namespace_definition: 'namespace',\n },\n refTypes: ['identifier', 'type_identifier'],\n },\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"cpp.js","sourceRoot":"","sources":["../../src/lang/cpp.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,GAAG,GAAoB;IAClC,EAAE,EAAE,KAAK;IACT,UAAU,EAAE,CAAC,IAAI,EAAE,KAAK,EAAE,KAAK,CAAC;IAChC,IAAI,EAAE,sBAAsB;IAC5B,YAAY,EAAE,KAAK;IACnB,SAAS,EAAE;QACT,YAAY,EAAE,IAAI,GAAG,CAAC,CAAC,SAAS,CAAC,CAAC;QAClC,cAAc,EAAE,IAAI,GAAG,EAAE;QACzB,mDAAmD;QACnD,oBAAoB,EAAE,EAAE,YAAY,EAAE,sBAA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,YAAY,EAAE,sBAAsB,EAAE;QAC9D,iFAAiF;QACjF,4CAA4C;QAC5C,YAAY,EAAE,EAAE,oBAAoB,EAAE,UAAU,EAAE;QAClD,UAAU,EAAE;YACV,mBAAmB,EAAE,UAAU;YAC/B,WAAW,EAAE,aAAa;YAC1B,gBAAgB,EAAE,QAAQ;YAC1B,eAAe,EAAE,OAAO;YACxB,eAAe,EAAE,OAAO;YACxB,cAAc,EAAE,MAAM;YACtB,eAAe,EAAE,iBAAiB;YAClC,iBAAiB,EAAE,YAAY;YAC/B,oBAAoB,EAAE,WAAW;YACjC,iBAAiB,EAAE,mBAAmB;YACtC,qBAAqB,EAAE,cAAc;YACrC,eAAe,EAAE,mBAAmB;YACpC,WAAW,EAAE,kBAAkB;YAC/B,oBAAoB,EAAE,kBAAkB;YACxC,YAAY,EAAE,wBAAwB;YACtC,UAAU,EAAE,0BAA0B;YACtC,aAAa,EAAE,0BAA0B;YACzC,YAAY,EAAE,0BAA0B;SACzC;KACF;IACD,OAAO,EAAE;QACP,QAAQ,EAAE;YACR,eAAe,EAAE,OAAO;YACxB,gBAAgB,EAAE,QAAQ;YAC1B,eAAe,EAAE,OAAO;YACxB,cAAc,EAAE,MAAM;YACtB,oBAAoB,EAAE,WAAW;SAClC;QACD,QAAQ,EAAE,CAAC,YAAY,EAAE,iBAAiB,CAAC;KAC5C;CACF,CAAC","sourcesContent":["import type { LanguageProfile } from './profile.ts';\n\nexport const cpp: LanguageProfile = {\n id: 'cpp',\n extensions: ['cc', 'cpp', 'hpp'],\n wasm: 'tree-sitter-cpp.wasm',\n markerLeader: '// ',\n structure: {\n commentTypes: new Set(['comment']),\n attributeTypes: new Set(),\n // Same preprocessor, same `#pragma once` pin as c.\n pinnedPatternsByType: { preproc_call: /^#\\s*pragma\\s+once\\b/ },\n // `template <typename T> class Box {}` — the marker should say what the template\n // declares, not just that it is a template.\n wrapperTypes: { template_declaration: 'template' },\n kindLabels: {\n function_definition: 'function',\n declaration: 'declaration',\n struct_specifier: 'struct',\n class_specifier: 'class',\n union_specifier: 'union',\n enum_specifier: 'enum',\n type_definition: 'type definition',\n alias_declaration: 'type alias',\n namespace_definition: 'namespace',\n using_declaration: 'using declaration',\n linkage_specification: 'extern block',\n preproc_include: 'include directive',\n preproc_def: 'macro definition',\n preproc_function_def: 'macro definition',\n preproc_call: 'preprocessor directive',\n preproc_if: 'preprocessor conditional',\n preproc_ifdef: 'preprocessor conditional',\n preproc_else: 'preprocessor conditional',\n },\n },\n repomap: {\n defKinds: {\n class_specifier: 'class',\n struct_specifier: 'struct',\n union_specifier: 'union',\n enum_specifier: 'enum',\n namespace_definition: 'namespace',\n },\n refTypes: ['identifier', 'type_identifier'],\n },\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"go.d.ts","sourceRoot":"","sources":["../../src/lang/go.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEpD,eAAO,MAAM,EAAE,EAAE,eA6BhB,CAAC"}
1
+ {"version":3,"file":"go.d.ts","sourceRoot":"","sources":["../../src/lang/go.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEpD,eAAO,MAAM,EAAE,EAAE,eA6BhB,CAAC","sourcesContent":["import type { LanguageProfile } from './profile.ts';\n\nexport const go: LanguageProfile = {\n id: 'go',\n extensions: ['go'],\n wasm: 'tree-sitter-go.wasm',\n markerLeader: '// ',\n structure: {\n commentTypes: new Set(['comment']),\n attributeTypes: new Set(),\n // `//go:build` (and the legacy `// +build`) constrain the whole file's builds.\n pinnedCommentPattern: /^\\/\\/(go:build|\\s*\\+build)\\s/,\n wrapperTypes: {},\n kindLabels: {\n function_declaration: 'function',\n method_declaration: 'method',\n type_declaration: 'type declaration',\n const_declaration: 'constant',\n var_declaration: 'variable',\n import_declaration: 'import declaration',\n package_clause: 'package clause',\n },\n },\n repomap: {\n defKinds: {\n function_declaration: 'function',\n method_declaration: 'method',\n type_spec: 'type',\n },\n refTypes: ['identifier', 'type_identifier'],\n },\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"go.js","sourceRoot":"","sources":["../../src/lang/go.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,EAAE,GAAoB;IACjC,EAAE,EAAE,IAAI;IACR,UAAU,EAAE,CAAC,IAAI,CAAC;IAClB,IAAI,EAAE,qBAAqB;IAC3B,YAAY,EAAE,KAAK;IACnB,SAAS,EAAE;QACT,YAAY,EAAE,IAAI,GAAG,CAAC,CAAC,SAAS,CAAC,CAAC;QAClC,cAAc,EAAE,IAAI,GAAG,EAAE;QACzB,+EAA+E;QAC/E,oBAAoB,EAAE,8BAA8B;QACpD,YAAY,EAAE,EAAE;QAChB,UAAU,EAAE;YACV,oBAAoB,EAAE,UAAU;YAChC,kBAAkB,EAAE,QAAQ;YAC5B,gBAAgB,EAAE,kBAAkB;YACpC,iBAAiB,EAAE,UAAU;YAC7B,eAAe,EAAE,UAAU;YAC3B,kBAAkB,EAAE,oBAAoB;YACxC,cAAc,EAAE,gBAAgB;SACjC;KACF;IACD,OAAO,EAAE;QACP,QAAQ,EAAE;YACR,oBAAoB,EAAE,UAAU;YAChC,kBAAkB,EAAE,QAAQ;YAC5B,SAAS,EAAE,MAAM;SAClB;QACD,QAAQ,EAAE,CAAC,YAAY,EAAE,iBAAiB,CAAC;KAC5C;CACF,CAAC"}
1
+ {"version":3,"file":"go.js","sourceRoot":"","sources":["../../src/lang/go.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,EAAE,GAAoB;IACjC,EAAE,EAAE,IAAI;IACR,UAAU,EAAE,CAAC,IAAI,CAAC;IAClB,IAAI,EAAE,qBAAqB;IAC3B,YAAY,EAAE,KAAK;IACnB,SAAS,EAAE;QACT,YAAY,EAAE,IAAI,GAAG,CAAC,CAAC,SAAS,CAAC,CAAC;QAClC,cAAc,EAAE,IAAI,GAAG,EAAE;QACzB,+EAA+E;QAC/E,oBAAoB,EAAE,8BAA8B;QACpD,YAAY,EAAE,EAAE;QAChB,UAAU,EAAE;YACV,oBAAoB,EAAE,UAAU;YAChC,kBAAkB,EAAE,QAAQ;YAC5B,gBAAgB,EAAE,kBAAkB;YACpC,iBAAiB,EAAE,UAAU;YAC7B,eAAe,EAAE,UAAU;YAC3B,kBAAkB,EAAE,oBAAoB;YACxC,cAAc,EAAE,gBAAgB;SACjC;KACF;IACD,OAAO,EAAE;QACP,QAAQ,EAAE;YACR,oBAAoB,EAAE,UAAU;YAChC,kBAAkB,EAAE,QAAQ;YAC5B,SAAS,EAAE,MAAM;SAClB;QACD,QAAQ,EAAE,CAAC,YAAY,EAAE,iBAAiB,CAAC;KAC5C;CACF,CAAC","sourcesContent":["import type { LanguageProfile } from './profile.ts';\n\nexport const go: LanguageProfile = {\n id: 'go',\n extensions: ['go'],\n wasm: 'tree-sitter-go.wasm',\n markerLeader: '// ',\n structure: {\n commentTypes: new Set(['comment']),\n attributeTypes: new Set(),\n // `//go:build` (and the legacy `// +build`) constrain the whole file's builds.\n pinnedCommentPattern: /^\\/\\/(go:build|\\s*\\+build)\\s/,\n wrapperTypes: {},\n kindLabels: {\n function_declaration: 'function',\n method_declaration: 'method',\n type_declaration: 'type declaration',\n const_declaration: 'constant',\n var_declaration: 'variable',\n import_declaration: 'import declaration',\n package_clause: 'package clause',\n },\n },\n repomap: {\n defKinds: {\n function_declaration: 'function',\n method_declaration: 'method',\n type_spec: 'type',\n },\n refTypes: ['identifier', 'type_identifier'],\n },\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"java.d.ts","sourceRoot":"","sources":["../../src/lang/java.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEpD,eAAO,MAAM,IAAI,EAAE,eAgClB,CAAC"}
1
+ {"version":3,"file":"java.d.ts","sourceRoot":"","sources":["../../src/lang/java.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEpD,eAAO,MAAM,IAAI,EAAE,eAgClB,CAAC","sourcesContent":["import type { LanguageProfile } from './profile.ts';\n\nexport const java: LanguageProfile = {\n id: 'java',\n extensions: ['java'],\n wasm: 'tree-sitter-java.wasm',\n markerLeader: '// ',\n structure: {\n // `//` is line_comment, `/** … */` javadoc is block_comment — both attach.\n commentTypes: new Set(['line_comment', 'block_comment']),\n attributeTypes: new Set(),\n wrapperTypes: {},\n kindLabels: {\n class_declaration: 'class',\n interface_declaration: 'interface',\n enum_declaration: 'enum',\n record_declaration: 'record',\n annotation_type_declaration: 'annotation type',\n package_declaration: 'package declaration',\n import_declaration: 'import declaration',\n module_declaration: 'module declaration',\n },\n },\n repomap: {\n defKinds: {\n class_declaration: 'class',\n interface_declaration: 'interface',\n enum_declaration: 'enum',\n record_declaration: 'record',\n annotation_type_declaration: 'annotation type',\n method_declaration: 'method',\n },\n refTypes: ['identifier', 'type_identifier'],\n },\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"java.js","sourceRoot":"","sources":["../../src/lang/java.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,IAAI,GAAoB;IACnC,EAAE,EAAE,MAAM;IACV,UAAU,EAAE,CAAC,MAAM,CAAC;IACpB,IAAI,EAAE,uBAAuB;IAC7B,YAAY,EAAE,KAAK;IACnB,SAAS,EAAE;QACT,2EAA2E;QAC3E,YAAY,EAAE,IAAI,GAAG,CAAC,CAAC,cAAc,EAAE,eAAe,CAAC,CAAC;QACxD,cAAc,EAAE,IAAI,GAAG,EAAE;QACzB,YAAY,EAAE,EAAE;QAChB,UAAU,EAAE;YACV,iBAAiB,EAAE,OAAO;YAC1B,qBAAqB,EAAE,WAAW;YAClC,gBAAgB,EAAE,MAAM;YACxB,kBAAkB,EAAE,QAAQ;YAC5B,2BAA2B,EAAE,iBAAiB;YAC9C,mBAAmB,EAAE,qBAAqB;YAC1C,kBAAkB,EAAE,oBAAoB;YACxC,k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import type { LanguageProfile } from './profile.ts';\n\nexport const java: LanguageProfile = {\n id: 'java',\n extensions: ['java'],\n wasm: 'tree-sitter-java.wasm',\n markerLeader: '// ',\n structure: {\n // `//` is line_comment, `/** … */` javadoc is block_comment — both attach.\n commentTypes: new Set(['line_comment', 'block_comment']),\n attributeTypes: new Set(),\n wrapperTypes: {},\n kindLabels: {\n class_declaration: 'class',\n interface_declaration: 'interface',\n enum_declaration: 'enum',\n record_declaration: 'record',\n annotation_type_declaration: 'annotation type',\n package_declaration: 'package declaration',\n import_declaration: 'import declaration',\n module_declaration: 'module declaration',\n },\n },\n repomap: {\n defKinds: {\n class_declaration: 'class',\n interface_declaration: 'interface',\n enum_declaration: 'enum',\n record_declaration: 'record',\n annotation_type_declaration: 'annotation type',\n method_declaration: 'method',\n },\n refTypes: ['identifier', 'type_identifier'],\n },\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"javascript.d.ts","sourceRoot":"","sources":["../../src/lang/javascript.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAGpD,eAAO,MAAM,UAAU,EAAE,eAyBxB,CAAC"}
1
+ {"version":3,"file":"javascript.d.ts","sourceRoot":"","sources":["../../src/lang/javascript.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAGpD,eAAO,MAAM,UAAU,EAAE,eAyBxB,CAAC","sourcesContent":["import type { LanguageProfile } from './profile.ts';\nimport { TS_DEF_KINDS, TS_REF_TYPES } from './typescript.ts';\n\nexport const javascript: LanguageProfile = {\n id: 'javascript',\n extensions: ['js', 'mjs', 'cjs', 'jsx'],\n wasm: 'tree-sitter-javascript.wasm',\n markerLeader: '// ',\n structure: {\n commentTypes: new Set(['comment']),\n attributeTypes: new Set(),\n // `#!/usr/bin/env node` parses as a hash_bang_line node, and it decides how the\n // file executes — a collapse that swallowed it would break every direct invocation.\n pinnedTypes: new Set(['hash_bang_line']),\n wrapperTypes: { export_statement: 'export' },\n kindLabels: {\n function_declaration: 'function',\n generator_function_declaration: 'function',\n class_declaration: 'class',\n lexical_declaration: 'variable',\n variable_declaration: 'variable',\n import_statement: 'import statement',\n expression_statement: 'statement',\n hash_bang_line: 'shebang',\n comment: 'comment',\n },\n },\n repomap: { defKinds: TS_DEF_KINDS, refTypes: TS_REF_TYPES },\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"javascript.js","sourceRoot":"","sources":["../../src/lang/javascript.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAE7D,MAAM,CAAC,MAAM,UAAU,GAAoB;IACzC,EAAE,EAAE,YAAY;IAChB,UAAU,EAAE,CAAC,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,CAAC;IACvC,IAAI,EAAE,6BAA6B;IACnC,YAAY,EAAE,KAAK;IACnB,SAAS,EAAE;QACT,YAAY,EAAE,IAAI,GAAG,CAAC,CAAC,SAAS,CAAC,CAAC;QAClC,cAAc,EAAE,IAAI,GAAG,EAAE;QACzB,gFAAgF;QAChF,oFAAoF;QACpF,WAAW,EAAE,IAAI,GAAG,CAAC,CAAC,gBAAgB,CAAC,CAAC;QACxC,YAAY,EAAE,EAAE,gBAAgB,EAAE,QAAQ,EAAE;QAC5C,UAAU,EAAE;YACV,oBAAoB,EAAE,UAAU;YAChC,8BAA8B,EAAE,UAAU;YAC1C,iBAAiB,EAAE,OAAO;YAC1B,mBAAmB,EAAE,UAAU;YAC/B,oBAAoB,EAAE,UAAU;YAChC,gBAAgB,EAAE,kBAAkB;YACpC,oBAAoB,EAAE,WAAW;YACjC,cAAc,EAAE,SAAS;YACzB,OAAO,EAAE,SAAS;SACnB;KACF;IACD,OAAO,EAAE,EAAE,QAAQ,EAAE,YAAY,EAAE,QAAQ,EAAE,YAAY,EAAE;CAC5D,CAAC"}
1
+ {"version":3,"file":"javascript.js","sourceRoot":"","sources":["../../src/lang/javascript.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAE7D,MAAM,CAAC,MAAM,UAAU,GAAoB;IACzC,EAAE,EAAE,YAAY;IAChB,UAAU,EAAE,CAAC,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,CAAC;IACvC,IAAI,EAAE,6BAA6B;IACnC,YAAY,EAAE,KAAK;IACnB,SAAS,EAAE;QACT,YAAY,EAAE,IAAI,GAAG,CAAC,CAAC,SAAS,CAAC,CAAC;QAClC,cAAc,EAAE,IAAI,GAAG,EAAE;QACzB,gFAAgF;QAChF,oFAAoF;QACpF,WAAW,EAAE,IAAI,GAAG,CAAC,CAAC,gBAAgB,CAAC,CAAC;QACxC,YAAY,EAAE,EAAE,gBAAgB,EAAE,QAAQ,EAAE;QAC5C,UAAU,EAAE;YACV,oBAAoB,EAAE,UAAU;YAChC,8BAA8B,EAAE,UAAU;YAC1C,iBAAiB,EAAE,OAAO;YAC1B,mBAAmB,EAAE,UAAU;YAC/B,oBAAoB,EAAE,UAAU;YAChC,gBAAgB,EAAE,kBAAkB;YACpC,oBAAoB,EAAE,WAAW;YACjC,cAAc,EAAE,SAAS;YACzB,OAAO,EAAE,SAAS;SACnB;KACF;IACD,OAAO,EAAE,EAAE,QAAQ,EAAE,YAAY,EAAE,QAAQ,EAAE,YAAY,EAAE;CAC5D,CAAC","sourcesContent":["import type { LanguageProfile } from './profile.ts';\nimport { TS_DEF_KINDS, TS_REF_TYPES } from './typescript.ts';\n\nexport const javascript: LanguageProfile = {\n id: 'javascript',\n extensions: ['js', 'mjs', 'cjs', 'jsx'],\n wasm: 'tree-sitter-javascript.wasm',\n markerLeader: '// ',\n structure: {\n commentTypes: new Set(['comment']),\n attributeTypes: new Set(),\n // `#!/usr/bin/env node` parses as a hash_bang_line node, and it decides how the\n // file executes — a collapse that swallowed it would break every direct invocation.\n pinnedTypes: new Set(['hash_bang_line']),\n wrapperTypes: { export_statement: 'export' },\n kindLabels: {\n function_declaration: 'function',\n generator_function_declaration: 'function',\n class_declaration: 'class',\n lexical_declaration: 'variable',\n variable_declaration: 'variable',\n import_statement: 'import statement',\n expression_statement: 'statement',\n hash_bang_line: 'shebang',\n comment: 'comment',\n },\n },\n repomap: { defKinds: TS_DEF_KINDS, refTypes: TS_REF_TYPES },\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"kotlin.d.ts","sourceRoot":"","sources":["../../src/lang/kotlin.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEpD,eAAO,MAAM,MAAM,EAAE,eAmCpB,CAAC"}
1
+ {"version":3,"file":"kotlin.d.ts","sourceRoot":"","sources":["../../src/lang/kotlin.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEpD,eAAO,MAAM,MAAM,EAAE,eAmCpB,CAAC","sourcesContent":["import type { LanguageProfile } from './profile.ts';\n\nexport const kotlin: LanguageProfile = {\n id: 'kotlin',\n extensions: ['kt', 'kts'],\n wasm: 'tree-sitter-kotlin.wasm',\n markerLeader: '// ',\n structure: {\n // `//` is line_comment; `/** … */` KDoc is multiline_comment.\n commentTypes: new Set(['line_comment', 'multiline_comment']),\n attributeTypes: new Set(),\n // `#!/usr/bin/env kotlin` parses as a shebang_line node; same law as the rest.\n pinnedTypes: new Set(['shebang_line']),\n // tree-sitter-kotlin extends import_list over a doc comment that directly\n // follows it — the KDoc of the first documented declaration after the imports.\n // Split it back out, or that declaration loses its doc to the import collapse.\n trailingCommentSplitTypes: new Set(['import_list']),\n wrapperTypes: {},\n kindLabels: {\n function_declaration: 'function',\n // tree-sitter-kotlin parses class, interface and enum headers all as\n // class_declaration — \"type declaration\" is the honest word for the union.\n class_declaration: 'type declaration',\n object_declaration: 'object',\n property_declaration: 'property',\n type_alias: 'type alias',\n package_header: 'package header',\n import_list: 'import list',\n shebang_line: 'shebang',\n },\n },\n // No def kinds: tree-sitter-kotlin's declarations carry no identifier `name`\n // field the extraction walk can read, so kotlin symbols are omitted, not guessed.\n repomap: {\n defKinds: {},\n refTypes: ['simple_identifier', 'type_identifier'],\n },\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"kotlin.js","sourceRoot":"","sources":["../../src/lang/kotlin.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,MAAM,GAAoB;IACrC,EAAE,EAAE,QAAQ;IACZ,UAAU,EAAE,CAAC,IAAI,EAAE,KAAK,CAAC;IACzB,IAAI,EAAE,yBAAyB;IAC/B,YAAY,EAAE,KAAK;IACnB,SAAS,EAAE;QACT,8DAA8D;QAC9D,YAAY,EAAE,IAAI,GAAG,CAAC,CAAC,cAAc,EAAE,mBAAmB,CAAC,CAAC;QAC5D,cAAc,EAAE,IAAI,GAAG,EAAE;QACzB,+EAA+E;QAC/E,WAAW,EAAE,IAAI,GAAG,CAAC,CAAC,cAAc,CAAC,CAAC;QACtC,0EAA0E;QAC1E,+EAA+E;QAC/E,+EAA+E;QAC/E,yBAAyB,EAAE,IAAI,GAAG,CAAC,CAAC,aAAa,CAAC,CAAC;QACnD,YAAY,EAAE,EAAE;QAChB,UAAU,EAAE;YACV,oBAAoB,EAAE,UAAU;YAChC,qEAAqE;YACrE,2EAA2E;YAC3E,iBAAiB,EAAE,kBAAkB;YACrC,kBAAkB,EAAE,QAAQ;YAC5B,oBAAoB,EAAE,UAAU;YAChC,UAAU,EAAE,YAAY;YACxB,cAAc,EAAE,gBAAgB;YAChC,WAAW,EAAE,aAAa;YAC1B,YAAY,EAAE,SAAS;SACxB;KACF;IACD,6EAA6E;IAC7E,kFAAkF;IAClF,OAAO,EAAE;QACP,QAAQ,EAAE,EAAE;QACZ,QAAQ,EAAE,CAAC,mBAAmB,EAAE,iBAAiB,CAAC;KACnD;CACF,CAAC"}
1
+ {"version":3,"file":"kotlin.js","sourceRoot":"","sources":["../../src/lang/kotlin.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,MAAM,GAAoB;IACrC,EAAE,EAAE,QAAQ;IACZ,UAAU,EAAE,CAAC,IAAI,EAAE,KAAK,CAAC;IACzB,IAAI,EAAE,yBAAyB;IAC/B,YAAY,EAAE,KAAK;IACnB,SAAS,EAAE;QACT,8DAA8D;QAC9D,YAAY,EAAE,IAAI,GAAG,CAAC,CAAC,cAAc,EAAE,mBAAmB,CAAC,CAAC;QAC5D,cAAc,EAAE,IAAI,GAAG,EAAE;QACzB,+EAA+E;QAC/E,WAAW,EAAE,IAAI,GAAG,CAAC,CAAC,cAAc,CAAC,CAAC;QACtC,0EAA0E;QAC1E,+EAA+E;QAC/E,+EAA+E;QAC/E,yBAAyB,EAAE,IAAI,GAAG,CAAC,CAAC,aAAa,CAAC,CAAC;QACnD,YAAY,EAAE,EAAE;QAChB,UAAU,EAAE;YACV,oBAAoB,EAAE,UAAU;YAChC,qEAAqE;YACrE,2EAA2E;YAC3E,iBAAiB,EAAE,kBAAkB;YACrC,kBAAkB,EAAE,QAAQ;YAC5B,oBAAoB,EAAE,UAAU;YAChC,UAAU,EAAE,YAAY;YACxB,cAAc,EAAE,gBAAgB;YAChC,WAAW,EAAE,aAAa;YAC1B,YAAY,EAAE,SAAS;SACxB;KACF;IACD,6EAA6E;IAC7E,kFAAkF;IAClF,OAAO,EAAE;QACP,QAAQ,EAAE,EAAE;QACZ,QAAQ,EAAE,CAAC,mBAAmB,EAAE,iBAAiB,CAAC;KACnD;CACF,CAAC","sourcesContent":["import type { LanguageProfile } from './profile.ts';\n\nexport const kotlin: LanguageProfile = {\n id: 'kotlin',\n extensions: ['kt', 'kts'],\n wasm: 'tree-sitter-kotlin.wasm',\n markerLeader: '// ',\n structure: {\n // `//` is line_comment; `/** … */` KDoc is multiline_comment.\n commentTypes: new Set(['line_comment', 'multiline_comment']),\n attributeTypes: new Set(),\n // `#!/usr/bin/env kotlin` parses as a shebang_line node; same law as the rest.\n pinnedTypes: new Set(['shebang_line']),\n // tree-sitter-kotlin extends import_list over a doc comment that directly\n // follows it — the KDoc of the first documented declaration after the imports.\n // Split it back out, or that declaration loses its doc to the import collapse.\n trailingCommentSplitTypes: new Set(['import_list']),\n wrapperTypes: {},\n kindLabels: {\n function_declaration: 'function',\n // tree-sitter-kotlin parses class, interface and enum headers all as\n // class_declaration — \"type declaration\" is the honest word for the union.\n class_declaration: 'type declaration',\n object_declaration: 'object',\n property_declaration: 'property',\n type_alias: 'type alias',\n package_header: 'package header',\n import_list: 'import list',\n shebang_line: 'shebang',\n },\n },\n // No def kinds: tree-sitter-kotlin's declarations carry no identifier `name`\n // field the extraction walk can read, so kotlin symbols are omitted, not guessed.\n repomap: {\n defKinds: {},\n refTypes: ['simple_identifier', 'type_identifier'],\n },\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"php.d.ts","sourceRoot":"","sources":["../../src/lang/php.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEpD,eAAO,MAAM,GAAG,EAAE,eAmCjB,CAAC"}
1
+ {"version":3,"file":"php.d.ts","sourceRoot":"","sources":["../../src/lang/php.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEpD,eAAO,MAAM,GAAG,EAAE,eAmCjB,CAAC","sourcesContent":["import type { LanguageProfile } from './profile.ts';\n\nexport const php: LanguageProfile = {\n id: 'php',\n extensions: ['php'],\n wasm: 'tree-sitter-php.wasm',\n markerLeader: '// ',\n structure: {\n // `//`, `#` and `/** … */` PHPDoc are all comment nodes.\n commentTypes: new Set(['comment']),\n attributeTypes: new Set(),\n // `<?php` is what makes the rest of the file php at all.\n pinnedTypes: new Set(['php_tag']),\n wrapperTypes: {},\n kindLabels: {\n function_definition: 'function',\n class_declaration: 'class',\n interface_declaration: 'interface',\n trait_declaration: 'trait',\n enum_declaration: 'enum',\n const_declaration: 'constant',\n namespace_definition: 'namespace',\n namespace_use_declaration: 'use declaration',\n expression_statement: 'statement',\n php_tag: 'php tag',\n // Raw markup between `?>` and `<?php` — calling it a declaration would be the\n // marker lying about the tree.\n text: 'html section',\n text_interpolation: 'html section',\n },\n },\n // No def kinds: php names its definitions with `name` nodes, not identifiers, and\n // an omitted kind means fewer symbols on the map, never wrong ones.\n repomap: {\n defKinds: {},\n refTypes: ['name', 'variable_name'],\n },\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"php.js","sourceRoot":"","sources":["../../src/lang/php.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,GAAG,GAAoB;IAClC,EAAE,EAAE,KAAK;IACT,UAAU,EAAE,CAAC,KAAK,CAAC;IACnB,IAAI,EAAE,sBAAsB;IAC5B,YAAY,EAAE,KAAK;IACnB,SAAS,EAAE;QACT,yDAAyD;QACzD,YAAY,EAAE,IAAI,GAAG,CAAC,CAAC,SAAS,CAAC,CAAC;QAClC,cAAc,EAAE,IAAI,GAAG,EAAE;QACzB,yDAAyD;QACzD,WAAW,EAAE,IAAI,GAAG,CAAC,CAAC,SAAS,CAAC,CAAC;QACjC,YAAY,EAAE,EAAE;QAChB,UAAU,EAAE;YACV,mBAAmB,EAAE,UAAU;YAC/B,iBAAiB,EAAE,OAAO;YAC1B,qBAAqB,EAAE,WAAW;YAClC,iBAAiB,EAAE,OAAO;YAC1B,gBAAgB,EAAE,MAAM;YACxB,iBAAiB,EAAE,UAAU;YAC7B,oBAAoB,EAAE,WAAW;YACjC,yBAAyB,EAAE,iBAAiB;YAC5C,oBAAoB,EAAE,WAAW;YACjC,OAAO,EAAE,SAAS;YAClB,8EAA8E;YAC9E,+BAA+B;YAC/B,IAAI,EAAE,cAAc;YACpB,kBAAkB,EAAE,cAAc;SACnC;KACF;IACD,kFAAkF;IAClF,oEAAoE;IACpE,OAAO,EAAE;QACP,QAAQ,EAAE,EAAE;QACZ,QAAQ,EAAE,CAAC,MAAM,EAAE,eAAe,CAAC;KACpC;CACF,CAAC"}
1
+ {"version":3,"file":"php.js","sourceRoot":"","sources":["../../src/lang/php.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,GAAG,GAAoB;IAClC,EAAE,EAAE,KAAK;IACT,UAAU,EAAE,CAAC,KAAK,CAAC;IACnB,IAAI,EAAE,sBAAsB;IAC5B,YAAY,EAAE,KAAK;IACnB,SAAS,EAAE;QACT,yDAAyD;QACzD,YAAY,EAAE,IAAI,GAAG,CAAC,CAAC,SAAS,CAAC,CAAC;QAClC,cAAc,EAAE,IAAI,GAAG,EAAE;QACzB,yDAAyD;QACzD,WAAW,EAAE,IAAI,GAAG,CAAC,CAAC,SAAS,CAAC,CAAC;QACjC,YAAY,EAAE,EAAE;QAChB,UAAU,EAAE;YACV,mBAAmB,EAAE,UAAU;YAC/B,iBAAiB,EAAE,OAAO;YAC1B,qBAAqB,EAAE,WAAW;YAClC,iBAAiB,EAAE,OAAO;YAC1B,gBAAgB,EAAE,MAAM;YACxB,iBAAiB,EAAE,UAAU;YAC7B,oBAAoB,EAAE,WAAW;YACjC,yBAAyB,EAAE,iBAAiB;YAC5C,oBAAoB,EAAE,WAAW;YACjC,OAAO,EAAE,SAAS;YAClB,8EAA8E;YAC9E,+BAA+B;YAC/B,IAAI,EAAE,cAAc;YACpB,kBAAkB,EAAE,cAAc;SACnC;KACF;IACD,kFAAkF;IAClF,oEAAoE;IACpE,OAAO,EAAE;QACP,QAAQ,EAAE,EAAE;QACZ,QAAQ,EAAE,CAAC,MAAM,EAAE,eAAe,CAAC;KACpC;CACF,CAAC","sourcesContent":["import type { LanguageProfile } from './profile.ts';\n\nexport const php: LanguageProfile = {\n id: 'php',\n extensions: ['php'],\n wasm: 'tree-sitter-php.wasm',\n markerLeader: '// ',\n structure: {\n // `//`, `#` and `/** … */` PHPDoc are all comment nodes.\n commentTypes: new Set(['comment']),\n attributeTypes: new Set(),\n // `<?php` is what makes the rest of the file php at all.\n pinnedTypes: new Set(['php_tag']),\n wrapperTypes: {},\n kindLabels: {\n function_definition: 'function',\n class_declaration: 'class',\n interface_declaration: 'interface',\n trait_declaration: 'trait',\n enum_declaration: 'enum',\n const_declaration: 'constant',\n namespace_definition: 'namespace',\n namespace_use_declaration: 'use declaration',\n expression_statement: 'statement',\n php_tag: 'php tag',\n // Raw markup between `?>` and `<?php` — calling it a declaration would be the\n // marker lying about the tree.\n text: 'html section',\n text_interpolation: 'html section',\n },\n },\n // No def kinds: php names its definitions with `name` nodes, not identifiers, and\n // an omitted kind means fewer symbols on the map, never wrong ones.\n repomap: {\n defKinds: {},\n refTypes: ['name', 'variable_name'],\n },\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"profile.d.ts","sourceRoot":"","sources":["../../src/lang/profile.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAE9C;;;;;;;;;;;;;;;;;;;GAmBG;AACH,MAAM,WAAW,eAAe;IAC9B,QAAQ,CAAC,EAAE,EAAE,UAAU,CAAC;IACxB,wEAAwE;IACxE,QAAQ,CAAC,UAAU,EAAE,SAAS,MAAM,EAAE,CAAC;IACvC,kEAAkE;IAClE,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB;;;;;;OAMG;IACH,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,CAAC;IAC/B;;;;OAIG;IACH,QAAQ,CAAC,SAAS,CAAC,EAAE,iBAAiB,CAAC;IACvC,0EAA0E;IAC1E,QAAQ,CAAC,OAAO,CAAC,EAAE,YAAY,CAAC;CACjC;AAED;;;;;;GAMG;AACH,MAAM,WAAW,iBAAiB;IAChC,4EAA4E;IAC5E,QAAQ,CAAC,YAAY,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC;IAC3C;;;;OAIG;IACH,QAAQ,CAAC,cAAc,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC;IAC7C;;;;;;OAMG;IACH,QAAQ,CAAC,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC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AAE,CAAC;CACtC","sourcesContent":["import type { LanguageId } from '../types.ts';\n\n/**\n * Everything smelt knows about one language, in one place.\n *\n * Before this module existed, a language's facts lived in seven tables across five\n * modules — the extension map in `detect.ts`, the grammar file in `plan/grammar.ts`,\n * the marker leader in `apply.ts`, the structural node kinds and pins in\n * `plan/structural.ts`, and the repo-map tag tables in `repomap/tags.ts`. Adding a\n * language meant editing all five, and forgetting one produced a language that half\n * works: detected but unparsable, parsable but with a syntax-breaking marker.\n *\n * A `LanguageProfile` is the single adapter carrying every per-language fact, and the\n * registry (`registry.ts`) is `Record<LanguageId, LanguageProfile>` so totality stays\n * a compile error: a new `LanguageId` without a profile does not build. Consumers\n * *read* the registry — none of them owns a slice of it.\n *\n * The optional sections state capability, never invent it: a language is a\n * **structural language** exactly when its profile carries a {@link structure}\n * section, and it contributes repo-map symbols exactly when it carries a\n * {@link repomap} section. What a profile does not claim, smelt does not do.\n */\nexport interface LanguageProfile {\n readonly id: LanguageId;\n /** File extensions (lowercase, no dot) that detect as this language. */\n readonly extensions: readonly string[];\n /** The bundled grammar file, e.g. `'tree-sitter-python.wasm'`. */\n readonly wasm: string;\n /**\n * The line-comment leader the marker lands behind (`'// '`, `'# '`), so the\n * survivor still parses in this language's own syntax. A bare `<<smelt…>>` line was\n * measured to break the reparse non-locally in every grammar tested — see the doc\n * on `MARKER_LINE_COMMENT_LEADERS` in `src/apply.ts` for the failure classes.\n * Absent only for a language whose survivors have no syntax to break.\n */\n readonly markerLeader?: string;\n /**\n * What the structural planner needs to parse this language honestly. Present iff\n * the language is claimed by `structural/v1`; the derived `STRUCTURAL_LANGUAGES`\n * list is exactly the profiles that carry this section.\n */\n readonly structure?: LanguageStructure;\n /** What the repo map's tag extraction reads. See {@link RepoMapFacts}. */\n readonly repomap?: RepoMapFacts;\n}\n\n/**\n * What the structural planner needs to know about a language, beyond its grammar:\n * which node types are comments (so a doc comment travels with its declaration),\n * which node types merely wrap the declaration that should be named\n * (`export function f()` is a function, `@cached def f()` is a function), and the\n * human word for each top-level node kind.\n */\nexport interface LanguageStructure {\n /** Top-level node types that are comments, in this grammar's vocabulary. */\n readonly commentTypes: ReadonlySet<string>;\n /**\n * Top-level node types that are outer attributes — parsed as siblings of the item\n * they decorate, but attached forward to it unconditionally by the planner's\n * `unitsOf`, because that is what the attribute means in the language.\n */\n readonly attributeTypes: ReadonlySet<string>;\n /**\n * Comments matching this pattern are pinned to the file — never attached, never\n * collapsed. Go's `//go:build` governs which builds see the whole file, and the\n * spec's mandatory blank line after it means it could never attach; bash and ruby\n * shebang lines, and ruby's `# frozen_string_literal:` magic comment, govern how\n * the file executes at all.\n */\n readonly pinnedCommentPattern?: RegExp;\n /**\n * Non-comment node types pinned to the file the same way — php's `<?php` open tag,\n * a `#!` shebang line (javascript's `hash_bang_line`, kotlin and swift's\n * `shebang_line`). Each is its own uncollapsible unit: a run that swallowed one\n * would change what the survivor *is*, not just what it contains.\n */\n readonly pinnedTypes?: ReadonlySet<string>;\n /**\n * Per-node-type text patterns that pin a node the way {@link pinnedTypes} does —\n * for kinds where only *some* nodes govern the file. C and C++ parse every\n * `#pragma` as a `preproc_call`; only `#pragma once` changes what including the\n * survivor *means*, so only it is pinned.\n */\n readonly pinnedPatternsByType?: Readonly<Record<string, RegExp>>;\n /**\n * Node types that belong to the *preceding* statement despite being parsed as\n * top-level siblings — ruby's `heredoc_body`, which tree-sitter emits as a sibling\n * of the statement holding the heredoc opener. Such a node extends the previous\n * unit, so a collapse can never keep an opener while cutting its body (an\n * unterminated heredoc the reparse cannot even see — tree-sitter-ruby reports no\n * ERROR for a heredoc left open at EOF).\n */\n readonly ridesBackwardTypes?: ReadonlySet<string>;\n /**\n * Node types the grammar extends over trailing comments that belong to what\n * *follows* — kotlin's `import_list` swallows a KDoc that directly follows the\n * imports, which is the doc comment of the first declaration after them. The unit\n * for such a node ends at its last non-comment token; the trailing comments ride\n * forward and attach like any other comment block.\n */\n readonly trailingCommentSplitTypes?: ReadonlySet<string>;\n /**\n * Node types that wrap the declaration worth naming — the marker should say what is\n * inside, not name the wrapper. The value is the label to fall back to when nothing\n * nameable is found inside.\n */\n readonly wrapperTypes: Readonly<Record<string, string>>;\n /**\n * Human words per node type. What a language's map does not name, the planner\n * still labels honestly: an `ERROR` node is an `'unparsed region'`, any other\n * statement kind is a `'statement'`, and only what remains is called a\n * `'declaration'` — a marker that calls a parse error or a log line a declaration\n * would be lying about the tree.\n */\n readonly kindLabels: Readonly<Record<string, string>>;\n}\n\n/**\n * What the repo map's tag extraction (`repomap/tags.ts`) knows about a language.\n *\n * `defKinds` lists only node kinds whose `name` field is an *identifier* node,\n * because that is what the extraction walk reads — a kind whose name is spelled\n * differently (php's `name` nodes, ruby's `constant` class names, bash's `word`\n * function names, kotlin's field-less declarations) is *omitted*, not guessed at. An\n * omitted kind means fewer symbols on the map, never wrong ones.\n */\nexport interface RepoMapFacts {\n /** Declaration node type → human kind word. Absent from the map = not a definition. */\n readonly defKinds: Readonly<Record<string, string>>;\n /** Node types counted as references. */\n readonly refTypes: readonly string[];\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"profile.js","sourceRoot":"","sources":["../../src/lang/profile.ts"],"names":[],"mappings":""}
1
+ {"version":3,"file":"profile.js","sourceRoot":"","sources":["../../src/lang/profile.ts"],"names":[],"mappings":"","sourcesContent":["import type { LanguageId } from '../types.ts';\n\n/**\n * Everything smelt knows about one language, in one place.\n *\n * Before this module existed, a language's facts lived in seven tables across five\n * modules — the extension map in `detect.ts`, the grammar file in `plan/grammar.ts`,\n * the marker leader in `apply.ts`, the structural node kinds and pins in\n * `plan/structural.ts`, and the repo-map tag tables in `repomap/tags.ts`. Adding a\n * language meant editing all five, and forgetting one produced a language that half\n * works: detected but unparsable, parsable but with a syntax-breaking marker.\n *\n * A `LanguageProfile` is the single adapter carrying every per-language fact, and the\n * registry (`registry.ts`) is `Record<LanguageId, LanguageProfile>` so totality stays\n * a compile error: a new `LanguageId` without a profile does not build. Consumers\n * *read* the registry — none of them owns a slice of it.\n *\n * The optional sections state capability, never invent it: a language is a\n * **structural language** exactly when its profile carries a {@link structure}\n * section, and it contributes repo-map symbols exactly when it carries a\n * {@link repomap} section. What a profile does not claim, smelt does not do.\n */\nexport interface LanguageProfile {\n readonly id: LanguageId;\n /** File extensions (lowercase, no dot) that detect as this language. */\n readonly extensions: readonly string[];\n /** The bundled grammar file, e.g. `'tree-sitter-python.wasm'`. */\n readonly wasm: string;\n /**\n * The line-comment leader the marker lands behind (`'// '`, `'# '`), so the\n * survivor still parses in this language's own syntax. A bare `<<smelt…>>` line was\n * measured to break the reparse non-locally in every grammar tested — see the doc\n * on `MARKER_LINE_COMMENT_LEADERS` in `src/apply.ts` for the failure classes.\n * Absent only for a language whose survivors have no syntax to break.\n */\n readonly markerLeader?: string;\n /**\n * What the structural planner needs to parse this language honestly. Present iff\n * the language is claimed by `structural/v1`; the derived `STRUCTURAL_LANGUAGES`\n * list is exactly the profiles that carry this section.\n */\n readonly structure?: LanguageStructure;\n /** What the repo map's tag extraction reads. See {@link RepoMapFacts}. */\n readonly repomap?: RepoMapFacts;\n}\n\n/**\n * What the structural planner needs to know about a language, beyond its grammar:\n * which node types are comments (so a doc comment travels with its declaration),\n * which node types merely wrap the declaration that should be named\n * (`export function f()` is a function, `@cached def f()` is a function), and the\n * human word for each top-level node kind.\n */\nexport interface LanguageStructure {\n /** Top-level node types that are comments, in this grammar's vocabulary. */\n readonly commentTypes: ReadonlySet<string>;\n /**\n * Top-level node types that are outer attributes — parsed as siblings of the item\n * they decorate, but attached forward to it unconditionally by the planner's\n * `unitsOf`, because that is what the attribute means in the language.\n */\n readonly attributeTypes: ReadonlySet<string>;\n /**\n * Comments matching this pattern are pinned to the file — never attached, never\n * collapsed. Go's `//go:build` governs which builds see the whole file, and the\n * spec's mandatory blank line after it means it could never attach; bash and ruby\n * shebang lines, and ruby's `# frozen_string_literal:` magic comment, govern how\n * the file executes at all.\n */\n readonly pinnedCommentPattern?: RegExp;\n /**\n * Non-comment node types pinned to the file the same way — php's `<?php` open tag,\n * a `#!` shebang line (javascript's `hash_bang_line`, kotlin and swift's\n * `shebang_line`). Each is its own uncollapsible unit: a run that swallowed one\n * would change what the survivor *is*, not just what it contains.\n */\n readonly pinnedTypes?: ReadonlySet<string>;\n /**\n * Per-node-type text patterns that pin a node the way {@link pinnedTypes} does —\n * for kinds where only *some* nodes govern the file. C and C++ parse every\n * `#pragma` as a `preproc_call`; only `#pragma once` changes what including the\n * survivor *means*, so only it is pinned.\n */\n readonly pinnedPatternsByType?: Readonly<Record<string, RegExp>>;\n /**\n * Node types that belong to the *preceding* statement despite being parsed as\n * top-level siblings — ruby's `heredoc_body`, which tree-sitter emits as a sibling\n * of the statement holding the heredoc opener. Such a node extends the previous\n * unit, so a collapse can never keep an opener while cutting its body (an\n * unterminated heredoc the reparse cannot even see — tree-sitter-ruby reports no\n * ERROR for a heredoc left open at EOF).\n */\n readonly ridesBackwardTypes?: ReadonlySet<string>;\n /**\n * Node types the grammar extends over trailing comments that belong to what\n * *follows* — kotlin's `import_list` swallows a KDoc that directly follows the\n * imports, which is the doc comment of the first declaration after them. The unit\n * for such a node ends at its last non-comment token; the trailing comments ride\n * forward and attach like any other comment block.\n */\n readonly trailingCommentSplitTypes?: ReadonlySet<string>;\n /**\n * Node types that wrap the declaration worth naming — the marker should say what is\n * inside, not name the wrapper. The value is the label to fall back to when nothing\n * nameable is found inside.\n */\n readonly wrapperTypes: Readonly<Record<string, string>>;\n /**\n * Human words per node type. What a language's map does not name, the planner\n * still labels honestly: an `ERROR` node is an `'unparsed region'`, any other\n * statement kind is a `'statement'`, and only what remains is called a\n * `'declaration'` — a marker that calls a parse error or a log line a declaration\n * would be lying about the tree.\n */\n readonly kindLabels: Readonly<Record<string, string>>;\n}\n\n/**\n * What the repo map's tag extraction (`repomap/tags.ts`) knows about a language.\n *\n * `defKinds` lists only node kinds whose `name` field is an *identifier* node,\n * because that is what the extraction walk reads — a kind whose name is spelled\n * differently (php's `name` nodes, ruby's `constant` class names, bash's `word`\n * function names, kotlin's field-less declarations) is *omitted*, not guessed at. An\n * omitted kind means fewer symbols on the map, never wrong ones.\n */\nexport interface RepoMapFacts {\n /** Declaration node type → human kind word. Absent from the map = not a definition. */\n readonly defKinds: Readonly<Record<string, string>>;\n /** Node types counted as references. */\n readonly refTypes: readonly string[];\n}\n"]}