scip-query 0.21.0 → 0.22.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 (496) hide show
  1. package/CHANGELOG.md +72 -0
  2. package/dist/augment-vue-worker.js +1 -1
  3. package/dist/by-kind-4IYG2SKW.js +2 -0
  4. package/dist/call-graph-WQNXMNNN.js +2 -0
  5. package/dist/{chunk-AQDWTCDC.js → chunk-25GWKRUZ.js} +2 -2
  6. package/dist/chunk-2BTJALUS.js +454 -0
  7. package/dist/chunk-2KVU55CW.js +11 -0
  8. package/dist/{chunk-BBWPOMGU.js → chunk-2OXVP5U5.js} +2 -2
  9. package/dist/{chunk-D5W4UZY5.js → chunk-2RE5OCHZ.js} +2 -2
  10. package/dist/{chunk-2I3RSUWX.js → chunk-2XCGSDIT.js} +2 -2
  11. package/dist/{chunk-V7LQZTTZ.js → chunk-2YC7YNKT.js} +2 -2
  12. package/dist/chunk-3QXC54FQ.js +3 -0
  13. package/dist/{chunk-32A42O5B.js → chunk-3TJY6M3B.js} +2 -2
  14. package/dist/chunk-42W3LFUK.js +13 -0
  15. package/dist/chunk-44T4DUAA.js +2 -0
  16. package/dist/chunk-4GAQ6FI4.js +43 -0
  17. package/dist/{chunk-4S4DF62J.js → chunk-4HE7MVWD.js} +2 -2
  18. package/dist/{chunk-TGWNNMPF.js → chunk-4TQU4TX2.js} +2 -2
  19. package/dist/{chunk-SKUMCCC5.js → chunk-56NQAEPJ.js} +2 -2
  20. package/dist/chunk-57N6LN2A.js +3 -0
  21. package/dist/{chunk-LPGDO2XA.js → chunk-5H5WTJSD.js} +2 -2
  22. package/dist/{chunk-EA4SH4U5.js → chunk-5YRQIE2B.js} +2 -2
  23. package/dist/{chunk-O2RM7E7L.js → chunk-5ZMBRQFC.js} +4 -4
  24. package/dist/{chunk-ICHBVITH.js → chunk-6HRZQLOI.js} +2 -2
  25. package/dist/{chunk-WULAPQUD.js → chunk-6NC3YSPY.js} +2 -2
  26. package/dist/{chunk-IDPLC3FI.js → chunk-6VEFRPTD.js} +2 -2
  27. package/dist/{chunk-IOKWFRFQ.js → chunk-7C26EKLZ.js} +2 -2
  28. package/dist/{chunk-S3RTPPLQ.js → chunk-7IQXARSQ.js} +2 -2
  29. package/dist/chunk-7JYHQAH2.js +22 -0
  30. package/dist/chunk-7KSO2OAP.js +2 -0
  31. package/dist/{chunk-2ZBMOQGG.js → chunk-7U2YQSDE.js} +2 -2
  32. package/dist/{chunk-EKZRF57O.js → chunk-7XA3OM44.js} +2 -2
  33. package/dist/{chunk-4EXFZP6H.js → chunk-7XZGZBSQ.js} +2 -2
  34. package/dist/chunk-7YQOCABQ.js +2 -0
  35. package/dist/chunk-A77SCPW2.js +3 -0
  36. package/dist/chunk-AK3PYTIK.js +5 -0
  37. package/dist/chunk-AMIMMNA4.js +11 -0
  38. package/dist/{chunk-MOBF2GH6.js → chunk-AQ2PORIO.js} +2 -2
  39. package/dist/{chunk-YUFWLWIC.js → chunk-ARVO6TTW.js} +2 -2
  40. package/dist/chunk-AUY5BL74.js +2 -0
  41. package/dist/{chunk-RGCJ4646.js → chunk-AYPDH2LU.js} +2 -2
  42. package/dist/{chunk-73Z33VFI.js → chunk-AZS7YPCB.js} +2 -2
  43. package/dist/{chunk-SYUNTKO2.js → chunk-BDGTPN27.js} +2 -2
  44. package/dist/{chunk-BATIVRU2.js → chunk-BDHFVH2M.js} +2 -2
  45. package/dist/chunk-BECZLYNU.js +8 -0
  46. package/dist/chunk-BJT7LSPK.js +3 -0
  47. package/dist/{chunk-6SWA6B24.js → chunk-BTVKZGWT.js} +2 -2
  48. package/dist/{chunk-QD7IFBCR.js → chunk-BUTEIZKP.js} +2 -2
  49. package/dist/{chunk-UZFCZ7SJ.js → chunk-BVFYEEBH.js} +2 -2
  50. package/dist/{chunk-ICUQONOG.js → chunk-BWVQP3LB.js} +2 -2
  51. package/dist/chunk-BYDAFMSR.js +57 -0
  52. package/dist/{chunk-BHE44MHT.js → chunk-C76O5MDS.js} +2 -2
  53. package/dist/chunk-C7IJMOFP.js +134 -0
  54. package/dist/{chunk-CN2WGM7D.js → chunk-CBBHFNLX.js} +2 -2
  55. package/dist/{chunk-COTMS5KM.js → chunk-CKRWA452.js} +2 -2
  56. package/dist/{chunk-ANWGXPPN.js → chunk-CLG6DWVS.js} +2 -2
  57. package/dist/chunk-D2MVJSP4.js +21 -0
  58. package/dist/chunk-D35XIZGN.js +2 -0
  59. package/dist/{chunk-U7DR7MJD.js → chunk-DEAB5TGT.js} +2 -2
  60. package/dist/{chunk-6GJAP4OE.js → chunk-DJAO2OZJ.js} +2 -2
  61. package/dist/chunk-DKM723YF.js +79 -0
  62. package/dist/{chunk-4IIMPWMR.js → chunk-DPWKKNKI.js} +2 -2
  63. package/dist/chunk-E44IVWIJ.js +367 -0
  64. package/dist/chunk-EDMB6SSO.js +7 -0
  65. package/dist/{chunk-KWARB5FZ.js → chunk-EELG7D3Q.js} +2 -2
  66. package/dist/chunk-EELPBR7E.js +3 -0
  67. package/dist/chunk-EETGXQY7.js +3 -0
  68. package/dist/chunk-ENWQWA2R.js +2 -0
  69. package/dist/{chunk-HUZNZ3H2.js → chunk-ERCYGVAM.js} +2 -2
  70. package/dist/{chunk-WSG3DK5H.js → chunk-EWWY2ZFL.js} +2 -2
  71. package/dist/chunk-F24G5NBE.js +3 -0
  72. package/dist/{chunk-XRXCANFQ.js → chunk-F24QUEQP.js} +2 -2
  73. package/dist/{chunk-KFK7GF5C.js → chunk-FBCVASUG.js} +2 -2
  74. package/dist/{chunk-35IW3P4H.js → chunk-FELGD32K.js} +2 -2
  75. package/dist/{chunk-UNORWZIJ.js → chunk-FFJQZG6J.js} +5 -5
  76. package/dist/{chunk-5SE323LF.js → chunk-FGNCOQUX.js} +2 -2
  77. package/dist/chunk-FKGQOTKD.js +2 -0
  78. package/dist/chunk-GDRJB3SB.js +3 -0
  79. package/dist/chunk-GH5YSGZL.js +5 -0
  80. package/dist/{chunk-X7PJJYKX.js → chunk-GIQ6CSL4.js} +2 -2
  81. package/dist/{chunk-2RP27XLR.js → chunk-GPGRZJ3R.js} +2 -2
  82. package/dist/{chunk-IYV2YBHM.js → chunk-GQIDEID3.js} +2 -2
  83. package/dist/chunk-GRX7JOXQ.js +2 -0
  84. package/dist/{chunk-H46QMB7E.js → chunk-GVOMSPGL.js} +2 -2
  85. package/dist/{chunk-KTRGJLY7.js → chunk-GY7CCCEZ.js} +2 -2
  86. package/dist/{chunk-VNKYRJKN.js → chunk-H7CG6LOE.js} +2 -2
  87. package/dist/chunk-HCVJR2V4.js +3 -0
  88. package/dist/chunk-HG722PO7.js +3 -0
  89. package/dist/{chunk-LHTT5C3Z.js → chunk-HISEUIL2.js} +2 -2
  90. package/dist/{chunk-K5MZYZV7.js → chunk-HXOU4XNH.js} +2 -2
  91. package/dist/chunk-I6UTXNHU.js +6 -0
  92. package/dist/{chunk-I7PFL5P3.js → chunk-IJMD6BRI.js} +2 -2
  93. package/dist/{chunk-XXJ7WL3F.js → chunk-IKVNEGTW.js} +2 -2
  94. package/dist/chunk-IMKZEXZG.js +2 -0
  95. package/dist/chunk-ISIQLPJ2.js +61 -0
  96. package/dist/{chunk-DEUGHURX.js → chunk-ISWFRGJ6.js} +2 -2
  97. package/dist/chunk-IW5XQG5G.js +2 -0
  98. package/dist/chunk-IXESDH3J.js +2 -0
  99. package/dist/{chunk-FGB567HK.js → chunk-JAT6C3VX.js} +2 -2
  100. package/dist/{chunk-7TWP3MCP.js → chunk-JFQBRL3J.js} +2 -2
  101. package/dist/{chunk-Q7HB7BFJ.js → chunk-JHH5SCZ3.js} +2 -2
  102. package/dist/{chunk-ZHSARYVS.js → chunk-JJ62MTQH.js} +2 -2
  103. package/dist/chunk-JT6XX7QY.js +8 -0
  104. package/dist/{chunk-5H7IWVXJ.js → chunk-JUN5DOAK.js} +2 -2
  105. package/dist/{chunk-DOPCR5BY.js → chunk-K3XFWJI2.js} +2 -2
  106. package/dist/{chunk-Y4XQ7LES.js → chunk-KFOYCQAJ.js} +1 -1
  107. package/dist/{chunk-N5C65OFK.js → chunk-KFVSJX25.js} +2 -2
  108. package/dist/chunk-KK7GPALL.js +28 -0
  109. package/dist/{chunk-DHKBIOXF.js → chunk-KQHJEU6V.js} +2 -2
  110. package/dist/{chunk-WB6LGCFB.js → chunk-KZYID5KV.js} +2 -2
  111. package/dist/{chunk-KW6B5OL4.js → chunk-LO5JSW2C.js} +2 -2
  112. package/dist/{chunk-ZW44MCJM.js → chunk-LRI5OMPE.js} +2 -2
  113. package/dist/{chunk-HG5YI7PV.js → chunk-LXQUF2RP.js} +2 -2
  114. package/dist/{chunk-TM5XEDDR.js → chunk-MHIEP7EG.js} +2 -2
  115. package/dist/{chunk-FHV7NMFU.js → chunk-MSR2QRUE.js} +2 -2
  116. package/dist/chunk-N7FP5H5U.js +57 -0
  117. package/dist/{chunk-3653GTR7.js → chunk-NEIQPFBI.js} +2 -2
  118. package/dist/chunk-NK3JMP22.js +2 -0
  119. package/dist/{chunk-7IOAZRVL.js → chunk-NRBNAECH.js} +2 -2
  120. package/dist/{chunk-HGKEAP7F.js → chunk-NVSZNESQ.js} +2 -2
  121. package/dist/{chunk-R2MOKIVO.js → chunk-OJNK5ALA.js} +2 -2
  122. package/dist/{chunk-RFWAUHVW.js → chunk-OPSAW5DT.js} +2 -2
  123. package/dist/chunk-OTSPRVNW.js +2 -0
  124. package/dist/chunk-OXYAWIEA.js +2 -0
  125. package/dist/chunk-OZETODHH.js +2 -0
  126. package/dist/chunk-PBUH2P5S.js +3 -0
  127. package/dist/{chunk-QBANU5BQ.js → chunk-PIFTZEEM.js} +2 -2
  128. package/dist/{chunk-CKDOY6JA.js → chunk-PLJUQFQN.js} +2 -2
  129. package/dist/{chunk-JVZNWJBH.js → chunk-PLYUVM4F.js} +2 -2
  130. package/dist/chunk-PXXYQK55.js +2 -0
  131. package/dist/{chunk-WZQFY5S7.js → chunk-Q55NF3ZG.js} +2 -2
  132. package/dist/{chunk-OVPS2ILI.js → chunk-Q5TA4OY4.js} +2 -2
  133. package/dist/{chunk-OUB4J26T.js → chunk-Q6T2CAJL.js} +2 -2
  134. package/dist/chunk-Q7GBK5T7.js +81 -0
  135. package/dist/chunk-QKT4UI2Y.js +2 -0
  136. package/dist/{chunk-PIZY2GX6.js → chunk-QLBSG7U5.js} +2 -2
  137. package/dist/chunk-QWKHW6VZ.js +2 -0
  138. package/dist/{chunk-E7BJXRNV.js → chunk-R6M456QG.js} +2 -2
  139. package/dist/{chunk-MJNV7OCG.js → chunk-RDULNRSJ.js} +2 -2
  140. package/dist/{chunk-SSSJO4RG.js → chunk-RHHCLWQ6.js} +2 -2
  141. package/dist/chunk-RNKPYYYE.js +4 -0
  142. package/dist/{chunk-IXJ26KJJ.js → chunk-RPL3ARU7.js} +2 -2
  143. package/dist/{chunk-3EX7DNBC.js → chunk-RYOYJMGF.js} +2 -2
  144. package/dist/chunk-SB25YMEQ.js +2 -0
  145. package/dist/chunk-SV2LEFVM.js +2 -0
  146. package/dist/{chunk-ZBNL3QCY.js → chunk-SVHTMVA4.js} +3 -3
  147. package/dist/{chunk-6IEVHGWG.js → chunk-SWK4XPUS.js} +2 -2
  148. package/dist/chunk-T6QD2ZQB.js +43 -0
  149. package/dist/{chunk-VETXXOYU.js → chunk-TAYD3AE7.js} +2 -2
  150. package/dist/chunk-TD7VKJ2Y.js +117 -0
  151. package/dist/{chunk-UQ7XPRWU.js → chunk-TH6IC56G.js} +2 -2
  152. package/dist/{chunk-XVDMJMES.js → chunk-TKDNDQA7.js} +2 -2
  153. package/dist/{chunk-CSDDOUA4.js → chunk-TNG2FYS5.js} +2 -2
  154. package/dist/chunk-TQZV7KV4.js +2 -0
  155. package/dist/{chunk-AJVMVE7X.js → chunk-TUQIPUDS.js} +2 -2
  156. package/dist/chunk-TUSPIVZ3.js +4 -0
  157. package/dist/{chunk-ORBKAUCH.js → chunk-U2N2KE7A.js} +2 -2
  158. package/dist/{chunk-3PII3JI5.js → chunk-UAQ4T73O.js} +2 -2
  159. package/dist/{chunk-OFY4HTMI.js → chunk-UDY7MIAW.js} +2 -2
  160. package/dist/{chunk-WKPZCQLI.js → chunk-URSGGIZX.js} +2 -2
  161. package/dist/{chunk-UL4VJUMD.js → chunk-UT7TADJX.js} +2 -2
  162. package/dist/chunk-V4NG5OMS.js +554 -0
  163. package/dist/{chunk-2H4IAJHO.js → chunk-VMWUV6WB.js} +2 -2
  164. package/dist/{chunk-46JLFIGA.js → chunk-VTCIYFEK.js} +2 -2
  165. package/dist/chunk-VU6LIWHT.js +2 -0
  166. package/dist/chunk-VUSKPCUB.js +2 -0
  167. package/dist/{chunk-URMZLV2N.js → chunk-VXJJTQYE.js} +2 -2
  168. package/dist/{chunk-IPAL6DP2.js → chunk-VZ7NXSHV.js} +2 -2
  169. package/dist/{chunk-FUG6RPYY.js → chunk-WHADK6OS.js} +2 -2
  170. package/dist/chunk-WN3TCGJ4.js +2 -0
  171. package/dist/{chunk-B7ECWJAZ.js → chunk-WOOAY3PA.js} +2 -2
  172. package/dist/chunk-WRQXLNYE.js +9 -0
  173. package/dist/chunk-WSLEJSFR.js +2 -0
  174. package/dist/chunk-WYZIHUPZ.js +16 -0
  175. package/dist/{chunk-ZYREOING.js → chunk-XE33FV5W.js} +2 -2
  176. package/dist/chunk-XFMVKFSF.js +2 -0
  177. package/dist/{chunk-BBEDPVPB.js → chunk-XGGBK66W.js} +2 -2
  178. package/dist/{chunk-OFUBXBYX.js → chunk-XJX6LGHL.js} +2 -2
  179. package/dist/{chunk-Z3GCK3PD.js → chunk-XN22RGSR.js} +2 -2
  180. package/dist/{chunk-HWLCBKFE.js → chunk-XSWYJCAK.js} +2 -2
  181. package/dist/{chunk-IGKKTHJR.js → chunk-XU75YQN4.js} +2 -2
  182. package/dist/{chunk-E4EJBGDZ.js → chunk-Y2VM4CJC.js} +2 -2
  183. package/dist/{chunk-U7LRSQG6.js → chunk-Y334QQU5.js} +2 -2
  184. package/dist/{chunk-APLKXICZ.js → chunk-YAGYMBEX.js} +2 -2
  185. package/dist/{chunk-XITQLISP.js → chunk-YIHNPKWD.js} +2 -2
  186. package/dist/chunk-YXPUP5G2.js +11 -0
  187. package/dist/{chunk-6BJ7SOY7.js → chunk-Z2AWCTN6.js} +2 -2
  188. package/dist/{chunk-PHSPBQM6.js → chunk-Z2PZVKPR.js} +2 -2
  189. package/dist/{chunk-QXR5QPSF.js → chunk-ZAZGGSM3.js} +2 -2
  190. package/dist/{chunk-5236NQV3.js → chunk-ZGW4HLPD.js} +2 -2
  191. package/dist/chunk-ZOXKSQQB.js +2 -0
  192. package/dist/{chunk-BD6CV7PN.js → chunk-ZPASRBLF.js} +2 -2
  193. package/dist/{chunk-DMUGTKMD.js → chunk-ZYM4HOFA.js} +2 -2
  194. package/dist/{chunk-4ILHWBYF.js → chunk-ZZ3Z7D56.js} +2 -2
  195. package/dist/cli-main.js +4 -4
  196. package/dist/{code-CczEvHui.d.ts → code-B17qEMbt.d.ts} +1 -1
  197. package/dist/code-EQJFDT6I.js +2 -0
  198. package/dist/code-result-json-7UWIWBOO.js +2 -0
  199. package/dist/command-descriptors-ORNTVNYV.js +342 -0
  200. package/dist/{config-types-Cm-VSEBb.d.ts → config-types-B9B60MiR.d.ts} +10 -0
  201. package/dist/dataflow-6VL54GX5.js +2 -0
  202. package/dist/{db-LKJXAlNS.d.ts → db-BwIVAYNB.d.ts} +1 -1
  203. package/dist/dependence-slice-DT2NUHD2.js +2 -0
  204. package/dist/deps-DB7H5IKC.js +2 -0
  205. package/dist/direct-navigation-O3LUAYWQ.js +3 -0
  206. package/dist/entry-map-6K62RV3D.js +2 -0
  207. package/dist/files-MSLD7MO6.js +2 -0
  208. package/dist/{graph-evidence-CbUPCSKV.d.ts → graph-evidence-Bjyky2V4.d.ts} +1 -1
  209. package/dist/{health-Wl5G_LRt.d.ts → health-CPp2Jf1Z.d.ts} +1 -1
  210. package/dist/hierarchy-IVBXAKFA.js +2 -0
  211. package/dist/imports-FRAVZ3Y2.js +2 -0
  212. package/dist/index.d.ts +2 -2
  213. package/dist/index.js +1 -1
  214. package/dist/members-KJOJDYGO.js +2 -0
  215. package/dist/methods-2AYABBT3.js +2 -0
  216. package/dist/output-continuation-command-JHMPH6NC.js +3 -0
  217. package/dist/{output-pagination-VAWOGX4R.js → output-pagination-3OFL2MJV.js} +2 -2
  218. package/dist/project-reindex-HYO4WD7Z.js +3 -0
  219. package/dist/queries/affected.d.ts +2 -2
  220. package/dist/queries/affected.js +1 -1
  221. package/dist/queries/anchors.d.ts +2 -2
  222. package/dist/queries/anchors.js +1 -1
  223. package/dist/queries/architecture.d.ts +2 -2
  224. package/dist/queries/architecture.js +1 -1
  225. package/dist/queries/bottlenecks.d.ts +2 -2
  226. package/dist/queries/bottlenecks.js +1 -1
  227. package/dist/queries/by-kind.d.ts +2 -2
  228. package/dist/queries/by-kind.js +1 -1
  229. package/dist/queries/call-graph.d.ts +2 -2
  230. package/dist/queries/call-graph.js +1 -1
  231. package/dist/queries/change-surface.d.ts +2 -2
  232. package/dist/queries/change-surface.js +1 -1
  233. package/dist/queries/cleanup-plan.d.ts +2 -2
  234. package/dist/queries/cleanup-plan.js +1 -1
  235. package/dist/queries/co-change.d.ts +2 -2
  236. package/dist/queries/co-change.js +1 -1
  237. package/dist/queries/code.d.ts +3 -3
  238. package/dist/queries/code.js +1 -1
  239. package/dist/queries/complexity-hotspots.d.ts +2 -2
  240. package/dist/queries/complexity-hotspots.js +1 -1
  241. package/dist/queries/complexity.d.ts +13 -2
  242. package/dist/queries/complexity.js +1 -1
  243. package/dist/queries/context.d.ts +2 -2
  244. package/dist/queries/context.js +1 -1
  245. package/dist/queries/convergence.d.ts +2 -2
  246. package/dist/queries/convergence.js +1 -1
  247. package/dist/queries/coupling.d.ts +2 -2
  248. package/dist/queries/coupling.js +1 -1
  249. package/dist/queries/cycles.d.ts +2 -2
  250. package/dist/queries/cycles.js +1 -1
  251. package/dist/queries/dataflow.d.ts +2 -2
  252. package/dist/queries/dataflow.js +1 -1
  253. package/dist/queries/dead.d.ts +2 -2
  254. package/dist/queries/dead.js +1 -1
  255. package/dist/queries/decorative-checkers.d.ts +2 -2
  256. package/dist/queries/decorative-checkers.js +1 -1
  257. package/dist/queries/deep-chains.d.ts +2 -2
  258. package/dist/queries/deep-chains.js +1 -1
  259. package/dist/queries/dependence-slice.d.ts +3 -3
  260. package/dist/queries/dependence-slice.js +1 -1
  261. package/dist/queries/dependency-depth.d.ts +2 -2
  262. package/dist/queries/dependency-depth.js +1 -1
  263. package/dist/queries/deps.d.ts +2 -2
  264. package/dist/queries/deps.js +1 -1
  265. package/dist/queries/diff-impact.d.ts +2 -2
  266. package/dist/queries/diff-impact.js +1 -1
  267. package/dist/queries/doc-drift.d.ts +2 -2
  268. package/dist/queries/doc-drift.js +1 -1
  269. package/dist/queries/drift.d.ts +2 -2
  270. package/dist/queries/drift.js +1 -1
  271. package/dist/queries/duplicate-bodies.d.ts +2 -2
  272. package/dist/queries/duplicate-bodies.js +1 -1
  273. package/dist/queries/entry-map.d.ts +2 -2
  274. package/dist/queries/entry-map.js +1 -1
  275. package/dist/queries/evidence.d.ts +3 -3
  276. package/dist/queries/evidence.js +1 -1
  277. package/dist/queries/extract-candidates.d.ts +2 -2
  278. package/dist/queries/extract-candidates.js +1 -1
  279. package/dist/queries/fan.d.ts +2 -2
  280. package/dist/queries/fan.js +1 -1
  281. package/dist/queries/files.d.ts +2 -2
  282. package/dist/queries/files.js +1 -1
  283. package/dist/queries/health.d.ts +3 -3
  284. package/dist/queries/health.js +1 -1
  285. package/dist/queries/hierarchy.d.ts +2 -2
  286. package/dist/queries/hierarchy.js +1 -1
  287. package/dist/queries/hotspots.d.ts +2 -2
  288. package/dist/queries/hotspots.js +1 -1
  289. package/dist/queries/imports.d.ts +2 -2
  290. package/dist/queries/imports.js +1 -1
  291. package/dist/queries/incomplete-migration.d.ts +2 -2
  292. package/dist/queries/incomplete-migration.js +1 -1
  293. package/dist/queries/index.d.ts +5 -5
  294. package/dist/queries/index.js +1 -1
  295. package/dist/queries/isolated.d.ts +2 -2
  296. package/dist/queries/isolated.js +1 -1
  297. package/dist/queries/locality-candidates.d.ts +2 -2
  298. package/dist/queries/locality-candidates.js +1 -1
  299. package/dist/queries/members.d.ts +2 -2
  300. package/dist/queries/members.js +1 -1
  301. package/dist/queries/methods.d.ts +2 -2
  302. package/dist/queries/methods.js +1 -1
  303. package/dist/queries/not-implemented.d.ts +2 -2
  304. package/dist/queries/not-implemented.js +1 -1
  305. package/dist/queries/outline.d.ts +2 -2
  306. package/dist/queries/outline.js +1 -1
  307. package/dist/queries/passthrough-candidates.d.ts +2 -2
  308. package/dist/queries/passthrough-candidates.js +1 -1
  309. package/dist/queries/plan-context.d.ts +2 -2
  310. package/dist/queries/plan-context.js +1 -1
  311. package/dist/queries/react-component-duplicates.d.ts +2 -2
  312. package/dist/queries/react-component-duplicates.js +1 -1
  313. package/dist/queries/react-hook-candidates.d.ts +2 -2
  314. package/dist/queries/react-hook-candidates.js +1 -1
  315. package/dist/queries/react-large-component-pressure.d.ts +2 -2
  316. package/dist/queries/react-large-component-pressure.js +1 -1
  317. package/dist/queries/recent-duplicates.d.ts +2 -2
  318. package/dist/queries/recent-duplicates.js +1 -1
  319. package/dist/queries/redundant-reexports.d.ts +2 -2
  320. package/dist/queries/redundant-reexports.js +1 -1
  321. package/dist/queries/reference-neighborhood.d.ts +2 -2
  322. package/dist/queries/reference-neighborhood.js +1 -1
  323. package/dist/queries/reference-reachability.d.ts +2 -2
  324. package/dist/queries/reference-reachability.js +1 -1
  325. package/dist/queries/refs.d.ts +2 -2
  326. package/dist/queries/refs.js +1 -1
  327. package/dist/queries/self-audit.d.ts +2 -2
  328. package/dist/queries/self-audit.js +1 -1
  329. package/dist/queries/similar-chains.d.ts +2 -2
  330. package/dist/queries/similar-chains.js +1 -1
  331. package/dist/queries/similar-files.d.ts +2 -2
  332. package/dist/queries/similar-files.js +1 -1
  333. package/dist/queries/similar-signatures.d.ts +2 -2
  334. package/dist/queries/similar-signatures.js +1 -1
  335. package/dist/queries/similar.d.ts +2 -2
  336. package/dist/queries/similar.js +1 -1
  337. package/dist/queries/slice.d.ts +2 -2
  338. package/dist/queries/slice.js +1 -1
  339. package/dist/queries/source-inspection.d.ts +4 -4
  340. package/dist/queries/source-inspection.js +1 -1
  341. package/dist/queries/source-search.d.ts +2 -2
  342. package/dist/queries/source-search.js +1 -1
  343. package/dist/queries/stale-abstractions.d.ts +2 -2
  344. package/dist/queries/stale-abstractions.js +1 -1
  345. package/dist/queries/stats.d.ts +2 -2
  346. package/dist/queries/surface.d.ts +2 -2
  347. package/dist/queries/surface.js +1 -1
  348. package/dist/queries/symbols.d.ts +2 -2
  349. package/dist/queries/symbols.js +1 -1
  350. package/dist/queries/system-map.d.ts +2 -2
  351. package/dist/queries/system-map.js +1 -1
  352. package/dist/queries/system.d.ts +2 -2
  353. package/dist/queries/system.js +1 -1
  354. package/dist/queries/test-quality.d.ts +2 -2
  355. package/dist/queries/test-quality.js +1 -1
  356. package/dist/queries/trace.d.ts +2 -2
  357. package/dist/queries/trace.js +1 -1
  358. package/dist/queries/twin-ab.d.ts +2 -2
  359. package/dist/queries/twin-ab.js +1 -1
  360. package/dist/queries/twin-drift.d.ts +2 -2
  361. package/dist/queries/twin-drift.js +1 -1
  362. package/dist/queries/unused-imports.d.ts +2 -2
  363. package/dist/queries/unused-imports.js +1 -1
  364. package/dist/queries/unused-params.d.ts +2 -2
  365. package/dist/queries/unused-params.js +1 -1
  366. package/dist/queries/value-flow.d.ts +3 -3
  367. package/dist/queries/value-flow.js +1 -1
  368. package/dist/queries/vue-component-duplicates.d.ts +2 -2
  369. package/dist/queries/vue-component-duplicates.js +1 -1
  370. package/dist/queries/vue-composable-candidates.d.ts +2 -2
  371. package/dist/queries/vue-composable-candidates.js +1 -1
  372. package/dist/queries/vue-large-view-pressure.d.ts +2 -2
  373. package/dist/queries/vue-large-view-pressure.js +1 -1
  374. package/dist/queries/wrapper-candidates.d.ts +2 -2
  375. package/dist/queries/wrapper-candidates.js +1 -1
  376. package/dist/query-service-fastpath.js +5 -5
  377. package/dist/query-service-server.js +2 -2
  378. package/dist/refs-ARMA6XUJ.js +2 -0
  379. package/dist/refs-pagination-VUGIWN6U.js +2 -0
  380. package/dist/reindex-worker.js +125 -66
  381. package/dist/reindex.d.ts +5 -3
  382. package/dist/reindex.js +135 -76
  383. package/dist/runtime.d.ts +5 -5
  384. package/dist/runtime.js +4 -4
  385. package/dist/rust-semantic-session-server.js +1 -1
  386. package/dist/rust-semantic-session-worker.js +1 -1
  387. package/dist/rust-semantic-worker.js +1 -1
  388. package/dist/{scip-cli-CppzF5MK.d.ts → scip-cli-H-n59izO.d.ts} +1 -1
  389. package/dist/slice-YOB5YFAM.js +2 -0
  390. package/dist/surface-VY5EFWTW.js +2 -0
  391. package/dist/symbol-resolution-DGQN4XIV.js +2 -0
  392. package/dist/system-2KQ3QD2P.js +2 -0
  393. package/dist/trace-HTIPTXAE.js +2 -0
  394. package/dist/typescript-mailbox-worker.js +1 -1
  395. package/dist/value-flow-5FV3VQI7.js +2 -0
  396. package/dist/watch-server.js +3 -3
  397. package/docs/CLI_JSON_OUTPUT.md +2 -2
  398. package/docs/COMMAND_REFERENCE.md +2 -2
  399. package/docs/schemas/project-config.schema.json +11 -1
  400. package/package.json +6 -5
  401. package/skills/scip-explore/SKILL.md +73 -3
  402. package/skills/scip-explore/agents/openai.yaml +3 -3
  403. package/skills/scip-explore/references/delegated-exploration.md +51 -0
  404. package/skills/scip-explore/references/external-evidence.md +72 -0
  405. package/skills/scip-explore/references/information-model.md +51 -0
  406. package/skills/scip-explore/scripts/capture-evidence.mjs +666 -0
  407. package/skills/scip-query/SKILL.md +22 -1
  408. package/dist/by-kind-CI3O6PQG.js +0 -2
  409. package/dist/call-graph-6QTUTXH7.js +0 -2
  410. package/dist/chunk-2COFMIVK.js +0 -60
  411. package/dist/chunk-35ELD3RM.js +0 -2
  412. package/dist/chunk-3FQ3KMCD.js +0 -2
  413. package/dist/chunk-3VLJ2DCA.js +0 -2
  414. package/dist/chunk-4DCKBY6T.js +0 -5
  415. package/dist/chunk-4N6QSEMZ.js +0 -10
  416. package/dist/chunk-4OE2JO6I.js +0 -2
  417. package/dist/chunk-4UUCUASK.js +0 -554
  418. package/dist/chunk-54EOGFBR.js +0 -2
  419. package/dist/chunk-5IZTXSOL.js +0 -117
  420. package/dist/chunk-5ZJH6DDE.js +0 -2
  421. package/dist/chunk-63MBA7EG.js +0 -3
  422. package/dist/chunk-6T7H2AFY.js +0 -3
  423. package/dist/chunk-7COHFNJK.js +0 -38
  424. package/dist/chunk-7HU2IJ2T.js +0 -3
  425. package/dist/chunk-7PPYXENX.js +0 -2
  426. package/dist/chunk-AA7K3XLM.js +0 -21
  427. package/dist/chunk-AUP6YI5M.js +0 -2
  428. package/dist/chunk-CA5RE6H7.js +0 -2
  429. package/dist/chunk-CT5SI2I4.js +0 -2
  430. package/dist/chunk-D5EKVZPI.js +0 -2
  431. package/dist/chunk-DMQ7ZKJG.js +0 -81
  432. package/dist/chunk-ELNRLMC5.js +0 -29
  433. package/dist/chunk-F7WQ337U.js +0 -308
  434. package/dist/chunk-FEQIQ26E.js +0 -2
  435. package/dist/chunk-FN6EJM6Q.js +0 -2
  436. package/dist/chunk-FTSQNONX.js +0 -2
  437. package/dist/chunk-G2F6T5BV.js +0 -2
  438. package/dist/chunk-G6OGPXJW.js +0 -9
  439. package/dist/chunk-GFLTPNWV.js +0 -3
  440. package/dist/chunk-GTDP2SKQ.js +0 -2
  441. package/dist/chunk-HEOMG7IM.js +0 -8
  442. package/dist/chunk-I3U2FN2T.js +0 -13
  443. package/dist/chunk-IUJ3ZFEE.js +0 -7
  444. package/dist/chunk-LXLD46LH.js +0 -21
  445. package/dist/chunk-MEI3PTUK.js +0 -2
  446. package/dist/chunk-MO226P4Q.js +0 -4
  447. package/dist/chunk-MYUKI5VN.js +0 -4
  448. package/dist/chunk-OIRWZIYL.js +0 -38
  449. package/dist/chunk-OIVZ7PW6.js +0 -438
  450. package/dist/chunk-PNISDVYC.js +0 -3
  451. package/dist/chunk-PQOL42AW.js +0 -2
  452. package/dist/chunk-PUVZNFVY.js +0 -11
  453. package/dist/chunk-PZEI2TVL.js +0 -4
  454. package/dist/chunk-Q2J2VZZT.js +0 -2
  455. package/dist/chunk-QDCCHMVZ.js +0 -2
  456. package/dist/chunk-QLQBZOJH.js +0 -3
  457. package/dist/chunk-S73HBCGI.js +0 -11
  458. package/dist/chunk-SDPA5DKN.js +0 -210
  459. package/dist/chunk-SEUJVWT2.js +0 -3
  460. package/dist/chunk-SF7X6QNW.js +0 -2
  461. package/dist/chunk-SWFAFA4G.js +0 -49
  462. package/dist/chunk-T6FRID7Y.js +0 -3
  463. package/dist/chunk-TNOHGHZQ.js +0 -2
  464. package/dist/chunk-U2GPTA5U.js +0 -3
  465. package/dist/chunk-URTX2BEA.js +0 -6
  466. package/dist/chunk-VGRUM7JI.js +0 -3
  467. package/dist/chunk-VWLIOEEF.js +0 -11
  468. package/dist/chunk-WK4FD4PG.js +0 -2
  469. package/dist/chunk-X434XZAI.js +0 -2
  470. package/dist/chunk-YIEFEPG6.js +0 -16
  471. package/dist/chunk-YRVERHJR.js +0 -49
  472. package/dist/chunk-ZD3Z54IW.js +0 -2
  473. package/dist/chunk-ZDVDSDFG.js +0 -4
  474. package/dist/code-EQL6ZBLH.js +0 -2
  475. package/dist/code-result-json-6E4J6LGZ.js +0 -2
  476. package/dist/command-descriptors-QH3G2OVD.js +0 -346
  477. package/dist/dataflow-2BLMUZBP.js +0 -2
  478. package/dist/dependence-slice-MGAJDZXB.js +0 -2
  479. package/dist/deps-GQMUYVKW.js +0 -2
  480. package/dist/direct-navigation-6RUJKLAV.js +0 -3
  481. package/dist/entry-map-V2NQP5JU.js +0 -2
  482. package/dist/files-VM53I4IU.js +0 -2
  483. package/dist/hierarchy-D553WRSZ.js +0 -2
  484. package/dist/imports-DOZAJWLW.js +0 -2
  485. package/dist/members-HE67475K.js +0 -2
  486. package/dist/methods-K5JK4PPH.js +0 -2
  487. package/dist/output-continuation-command-LKBUTNRL.js +0 -3
  488. package/dist/project-reindex-4ARU6QCM.js +0 -3
  489. package/dist/refs-NBHKL4UQ.js +0 -2
  490. package/dist/refs-pagination-BBVTIHMH.js +0 -2
  491. package/dist/slice-U6S6LBSB.js +0 -2
  492. package/dist/surface-C7SS5CDQ.js +0 -2
  493. package/dist/symbol-resolution-3FVEKDTJ.js +0 -2
  494. package/dist/system-6K2NOO5C.js +0 -2
  495. package/dist/trace-II5K2TMH.js +0 -2
  496. package/dist/value-flow-MKFUUE5B.js +0 -2
@@ -1,3 +1,3 @@
1
- import{c as S}from"./chunk-BBEDPVPB.js";import{a as y,b as h}from"./chunk-UQ7XPRWU.js";import{a as f}from"./chunk-HWLCBKFE.js";import{d as v}from"./chunk-6SWA6B24.js";import{c as p}from"./chunk-FUG6RPYY.js";import{b as d}from"./chunk-LPGDO2XA.js";import{d as l,t as m}from"./chunk-5IZTXSOL.js";import{z as u}from"./chunk-DMQ7ZKJG.js";function B(i,r,c={}){let t=g(i,r,c);if(t.kind!=="matched")return t;let{referenceEvidence:n,claimSupport:e,...s}=t;return s}function g(i,r,c={}){let t=d(i,r);if(!t.match)return{kind:"missing",query:r};if(t.total>1)return{kind:"ambiguous",query:r,total:t.total,candidates:[{symbol:t.match.symbol,shortName:l(t.match.symbol),relativePath:t.match.relativePath,startLine:t.match.startLine},...t.candidates]};let n=t.match,e=R(c.parts),s=e.includes("definition")||e.includes("references")?S(i,n.symbol,{semantic:c.semantic,referenceContext:c.referenceContext}):{definitions:[],referencedBy:[],referenceEvidence:[],claimSupport:null},o=e.includes("callers")||e.includes("callees")?f(i,n.symbol,{semantic:c.semantic}):null,a=c.relatedSourceLines??80;return{kind:"matched",query:r,symbol:n.symbol,shortName:l(n.symbol),file:n.relativePath,parts:e,definition:e.includes("definition")?v(i,n.symbol):null,referenceWindows:e.includes("references")?L(i,s.referencedBy):[],callers:e.includes("callers")?E(i,o?.callers??[],a):[],callees:e.includes("callees")?E(i,o?.callees??[],a):[],dependencies:e.includes("dependencies")?y(i,n.relativePath):[],consumers:e.includes("consumers")?h(i,n.relativePath):[],referenceEvidence:s.referenceEvidence,claimSupport:s.claimSupport}}function L(i,r){let c=r.filter(n=>n.sourceStartLine!==null&&n.sourceEndLine!==null&&n.source!==null).sort((n,e)=>n.relativePath.localeCompare(e.relativePath)||n.sourceStartLine-e.sourceStartLine||n.line-e.line),t=[];for(let n of c){let e=t[t.length-1];if(e&&e.relativePath===n.relativePath&&n.sourceStartLine<=e.endLine+1){e.endLine=Math.max(e.endLine,n.sourceEndLine),e.references.push(b(n)),e.source=u(i,e.relativePath).slice(e.startLine,e.endLine+1).join(`
1
+ import{c as S}from"./chunk-XGGBK66W.js";import{a as y,b as h}from"./chunk-GVOMSPGL.js";import{a as f}from"./chunk-XSWYJCAK.js";import{d as v}from"./chunk-BTVKZGWT.js";import{c as p}from"./chunk-WHADK6OS.js";import{b as d}from"./chunk-5H5WTJSD.js";import{d as l,t as m}from"./chunk-TD7VKJ2Y.js";import{E as u}from"./chunk-Q7GBK5T7.js";function B(i,r,c={}){let t=g(i,r,c);if(t.kind!=="matched")return t;let{referenceEvidence:n,claimSupport:e,...s}=t;return s}function g(i,r,c={}){let t=d(i,r);if(!t.match)return{kind:"missing",query:r};if(t.total>1)return{kind:"ambiguous",query:r,total:t.total,candidates:[{symbol:t.match.symbol,shortName:l(t.match.symbol),relativePath:t.match.relativePath,startLine:t.match.startLine},...t.candidates]};let n=t.match,e=R(c.parts),s=e.includes("definition")||e.includes("references")?S(i,n.symbol,{semantic:c.semantic,referenceContext:c.referenceContext}):{definitions:[],referencedBy:[],referenceEvidence:[],claimSupport:null},o=e.includes("callers")||e.includes("callees")?f(i,n.symbol,{semantic:c.semantic}):null,a=c.relatedSourceLines??80;return{kind:"matched",query:r,symbol:n.symbol,shortName:l(n.symbol),file:n.relativePath,parts:e,definition:e.includes("definition")?v(i,n.symbol):null,referenceWindows:e.includes("references")?L(i,s.referencedBy):[],callers:e.includes("callers")?E(i,o?.callers??[],a):[],callees:e.includes("callees")?E(i,o?.callees??[],a):[],dependencies:e.includes("dependencies")?y(i,n.relativePath):[],consumers:e.includes("consumers")?h(i,n.relativePath):[],referenceEvidence:s.referenceEvidence,claimSupport:s.claimSupport}}function L(i,r){let c=r.filter(n=>n.sourceStartLine!==null&&n.sourceEndLine!==null&&n.source!==null).sort((n,e)=>n.relativePath.localeCompare(e.relativePath)||n.sourceStartLine-e.sourceStartLine||n.line-e.line),t=[];for(let n of c){let e=t[t.length-1];if(e&&e.relativePath===n.relativePath&&n.sourceStartLine<=e.endLine+1){e.endLine=Math.max(e.endLine,n.sourceEndLine),e.references.push(b(n)),e.source=u(i,e.relativePath).slice(e.startLine,e.endLine+1).join(`
2
2
  `);continue}t.push({relativePath:n.relativePath,startLine:n.sourceStartLine,endLine:n.sourceEndLine,source:n.source,references:[b(n)]})}return t}function b(i){return{line:i.line,enclosingSymbol:i.enclosingSymbol,enclosingShort:i.enclosingShort}}function R(i){let r=i&&i.length>0?i:["definition","references"];return[...new Set(r)]}function E(i,r,c){let t=[],n=new Set;for(let e of r){if(n.has(e.symbol))continue;n.add(e.symbol);let s=(e.file?m(i,e.file).find(a=>a.symbol===e.symbol):void 0)??d(i,e.symbol).match;if(!s)continue;let o=p(i,s.relativePath,s.startLine,s.endLine,c);o&&t.push({...o,symbol:e.symbol,shortName:e.shortName,omittedLines:Math.max(0,s.endLine-o.endLine)})}return t}export{B as a,g as b};
3
- //# sourceMappingURL=chunk-APLKXICZ.js.map
3
+ //# sourceMappingURL=chunk-YAGYMBEX.js.map
@@ -1,2 +1,2 @@
1
- import{a as s}from"./chunk-TNOHGHZQ.js";import{f as o}from"./chunk-MO226P4Q.js";function g(e,r){return s(e).filter(t=>c({pattern:r,relativePath:t})).map(t=>({relativePath:t}))}function c(e,r){let t=typeof e=="string"?{pattern:e,relativePath:r}:e;if(typeof t.pattern!="string"||typeof t.relativePath!="string")throw new TypeError("pathMatchesGlob requires pattern and relativePath.");let n=o(t.pattern),a=o(t.relativePath);if(!/[*?]/.test(n))return a.includes(n);let l=n.includes("/")?n:`**/${n}`;return i(l.split("/"),a.split("/"))}function i(e,r){if(e.length===0)return r.length===0;let[t,...n]=e;return t==="**"?i(n,r)||r.length>0&&i(e,r.slice(1)):r.length===0||!f(t??"",r[0]??"")?!1:i(n,r.slice(1))}function f(e,r){let t="^";for(let n of e)n==="*"?t+="[^/]*":n==="?"?t+="[^/]":t+=p(n);return t+="$",new RegExp(t).test(r)}function p(e){return/[\\^$.*+?()[\]{}|]/.test(e)?`\\${e}`:e}export{g as a,c as b};
2
- //# sourceMappingURL=chunk-XITQLISP.js.map
1
+ import{a as s}from"./chunk-QKT4UI2Y.js";import{f as o}from"./chunk-GH5YSGZL.js";function g(e,r){return s(e).filter(t=>c({pattern:r,relativePath:t})).map(t=>({relativePath:t}))}function c(e,r){let t=typeof e=="string"?{pattern:e,relativePath:r}:e;if(typeof t.pattern!="string"||typeof t.relativePath!="string")throw new TypeError("pathMatchesGlob requires pattern and relativePath.");let n=o(t.pattern),a=o(t.relativePath);if(!/[*?]/.test(n))return a.includes(n);let l=n.includes("/")?n:`**/${n}`;return i(l.split("/"),a.split("/"))}function i(e,r){if(e.length===0)return r.length===0;let[t,...n]=e;return t==="**"?i(n,r)||r.length>0&&i(e,r.slice(1)):r.length===0||!f(t??"",r[0]??"")?!1:i(n,r.slice(1))}function f(e,r){let t="^";for(let n of e)n==="*"?t+="[^/]*":n==="?"?t+="[^/]":t+=p(n);return t+="$",new RegExp(t).test(r)}function p(e){return/[\\^$.*+?()[\]{}|]/.test(e)?`\\${e}`:e}export{g as a,c as b};
2
+ //# sourceMappingURL=chunk-YIHNPKWD.js.map
@@ -0,0 +1,11 @@
1
+ import{c as d}from"./chunk-IW5XQG5G.js";import{basename as u}from"path";var f=d("indexed-document-paths",{clearGroups:["whole-project"]});function x(t,e={}){let r=g(e);return[...f.get(t,r,()=>{let s=e.scope?"AND relative_path LIKE ?":"",i=e.like?"AND relative_path LIKE ?":"",l=[...e.scope?[`%${e.scope}%`]:[],...e.like?[e.like]:[]],c=t.all(`SELECT relative_path
2
+ FROM documents
3
+ WHERE 1 = 1
4
+ ${t.pathExclusionsFor("documents")}
5
+ ${s}
6
+ ${i}
7
+ ORDER BY relative_path`,...l).map(a=>a.relative_path),n=e.extensions?c.filter(a=>e.extensions.some(m=>a.toLowerCase().endsWith(m.toLowerCase()))):c;return e.includeIgnored===!1?n.filter(a=>!t.isIgnored(a)):n})]}function g(t){let e=t.extensions?[...new Set(t.extensions.map(r=>r.toLowerCase()))].sort():null;return JSON.stringify({scope:t.scope??null,like:t.like??null,extensions:e,includeIgnored:t.includeIgnored!==!1})}function E(t,e,r){let o=p(e);if(!o)return[];let s=t.all(`SELECT relative_path
8
+ FROM documents
9
+ WHERE relative_path = ?
10
+ ${t.pathExclusionsFor("documents")}`,o).filter(n=>!t.isIgnored(n.relative_path)).map(n=>({relativePath:n.relative_path,score:h(n.relative_path,o)}));if(s.length>0)return s;let i=x(t,{includeIgnored:!1}).map(n=>({relativePath:n,score:h(n,o)})).filter(n=>n.score>0).sort((n,a)=>a.score-n.score||n.relativePath.localeCompare(a.relativePath)),l=i.filter(n=>n.score>=1100);if(l.length>0)return r.allowMultiple?l:[l[0]];if(r.requirePathMatch)return[];let c=i.filter(n=>n.score>=800);return c.length>0?r.allowMultiple?c:[c[0]]:r.allowMultiple?i:i.slice(0,1)}function h(t,e){let r=p(t),o=u(r),s=u(e),i=0;return r===e&&(i+=1200),r.endsWith(`/${e}`)&&(i+=1100),o===s&&(i+=900),r.startsWith(`${e}/`)&&(i+=850),r.includes(e)&&(i+=250),i}function p(t){return t.trim().replace(/\\/g,"/").replace(/^\.\//,"").replace(/^\/+/,"").replace(/\/+$/,"")}export{x as a,E as b};
11
+ //# sourceMappingURL=chunk-YXPUP5G2.js.map
@@ -1,2 +1,2 @@
1
- import{a as J,b as N,c as y,d as b,e as T,g as _,j as z,k as G}from"./chunk-63MBA7EG.js";import{z as O}from"./chunk-ZDVDSDFG.js";import{b as B}from"./chunk-7COHFNJK.js";import{c as j,g as v,h as g,j as A,l as P,p as U,r as m,x as d}from"./chunk-DMQ7ZKJG.js";var ce={references:_,referenceMap:z,callerMap:(e,s)=>b(e).callerMap(s),calleeMap:q};function q(e,s){let a=U(),i=new Map,o=T(e,s),l=[],n=[],h=0,c=0,p=0,f=0,E=0,H=0,I=0;for(let{definition:t,callees:r}of o.hits)E+=1,r.length>0&&(H+=1,I+=r.length,i.set(t.symbolId,r));let u=K(e,o.hits);if(u.entries.length>0&&m("semantic.callees.prefetch-cache-write",()=>P(e,u.entries),()=>({entries:u.entries.length,sourceMissing:u.sourceMissing,skippedUnsupportedLanguage:u.skippedUnsupportedLanguage})),m("semantic.callees.cache-scan",()=>{for(let[t,r]of J(o.misses)){if(!y(t)){a&&(h+=r.length);continue}let R=d(e,t);if(!R){a&&(c+=r.length),n.push(...r);continue}let x=g(e,t,R),C=$(e,t);if(!C){n.push(...r);continue}let Y=A(e,t,x,C);for(let D of r){let L=Y.get(D.symbol)??null;if(L!==null){let M=V(L);if(M){a&&(p+=1),M.length>0&&i.set(D.symbolId,M);continue}a&&(f+=1)}l.push({def:D,contentHash:x,depsDigest:C})}}},()=>({definitions:s.length,skippedUnsupportedLanguage:h,sourceMissing:c,cacheHits:p,parseFailures:f,misses:l.length,unkeyed:n.length,inMemoryHits:E,inMemoryRows:H,inMemoryCalleeCount:I,resultRows:i.size})),l.length===0&&n.length===0)return i;let k=[...n,...l.map(t=>t.def)],w=0,F=m("semantic.callees.compute-misses",()=>{let t=G(e,k);return w=t.size,t},()=>({definitions:k.length,misses:l.length,unkeyed:n.length,rows:w}));for(let[t,r]of F)i.set(t,r);let S=l.filter(t=>b(e).capability("semantic-callees",t.def.relativePath).available).map(t=>({relativePath:t.def.relativePath,symbol:t.def.symbol,contentHash:t.contentHash,depsDigest:t.depsDigest,payload:JSON.stringify(F.get(t.def.symbolId)??[])}));return S.length>0?m("semantic.callees.cache-write",()=>P(e,S),()=>({entries:S.length})):m("semantic.callees.cache-write-skip",()=>{},()=>({reason:"provider-unavailable",misses:l.length})),i}function K(e,s){let a=[],i=new Map,o=0,l=0;for(let{definition:n,callees:h}of s){if(!y(n.relativePath)){l+=1;continue}if(!i.has(n.relativePath)){let p=d(e,n.relativePath),f=p?$(e,n.relativePath):null;i.set(n.relativePath,p&&f?{contentHash:g(e,n.relativePath,p),depsDigest:f}:null)}let c=i.get(n.relativePath);if(!c){o+=1;continue}a.push({relativePath:n.relativePath,symbol:n.symbol,contentHash:c.contentHash,depsDigest:c.depsDigest,payload:JSON.stringify(h)})}return{entries:a,sourceMissing:o,skippedUnsupportedLanguage:l}}var Q="typescript-callees-v2-callsite-line";function $(e,s){let a=y(s);if(a==="typescript")return O(e,s,Q)?.key??null;let i=X(e,s);return a==="rust"?v(JSON.stringify({kind:"semantic-callees",language:a,engine:N(e.config.projectRoot),positionMapping:"nearby-leaf-v2-callsite-line",depsDigest:i})):i}function V(e){try{return JSON.parse(e)}catch{return null}}var W=j("semantic-deps-digest",{clearGroups:["whole-project","source-file"]});function X(e,s){return W.get(e,s,()=>{let i=[...B(e).get(s)??[]].sort().map(o=>`${o}:${g(e,o,d(e,o))}`);return v(i.join("|"))})}export{ce as a};
2
- //# sourceMappingURL=chunk-6BJ7SOY7.js.map
1
+ import{a as J,b as N,c as y,d as b,e as T,g as _,j as z,k as G}from"./chunk-PBUH2P5S.js";import{y as O}from"./chunk-TUSPIVZ3.js";import{b as B}from"./chunk-4GAQ6FI4.js";import{B as d,c as j,h as v,i as g,l as A,n as P,r as U,t as m}from"./chunk-Q7GBK5T7.js";var ce={references:_,referenceMap:z,callerMap:(e,s)=>b(e).callerMap(s),calleeMap:q};function q(e,s){let a=U(),i=new Map,o=T(e,s),l=[],n=[],h=0,c=0,p=0,f=0,E=0,H=0,I=0;for(let{definition:t,callees:r}of o.hits)E+=1,r.length>0&&(H+=1,I+=r.length,i.set(t.symbolId,r));let u=K(e,o.hits);if(u.entries.length>0&&m("semantic.callees.prefetch-cache-write",()=>P(e,u.entries),()=>({entries:u.entries.length,sourceMissing:u.sourceMissing,skippedUnsupportedLanguage:u.skippedUnsupportedLanguage})),m("semantic.callees.cache-scan",()=>{for(let[t,r]of J(o.misses)){if(!y(t)){a&&(h+=r.length);continue}let R=d(e,t);if(!R){a&&(c+=r.length),n.push(...r);continue}let x=g(e,t,R),C=$(e,t);if(!C){n.push(...r);continue}let Y=A(e,t,x,C);for(let D of r){let L=Y.get(D.symbol)??null;if(L!==null){let M=V(L);if(M){a&&(p+=1),M.length>0&&i.set(D.symbolId,M);continue}a&&(f+=1)}l.push({def:D,contentHash:x,depsDigest:C})}}},()=>({definitions:s.length,skippedUnsupportedLanguage:h,sourceMissing:c,cacheHits:p,parseFailures:f,misses:l.length,unkeyed:n.length,inMemoryHits:E,inMemoryRows:H,inMemoryCalleeCount:I,resultRows:i.size})),l.length===0&&n.length===0)return i;let k=[...n,...l.map(t=>t.def)],w=0,F=m("semantic.callees.compute-misses",()=>{let t=G(e,k);return w=t.size,t},()=>({definitions:k.length,misses:l.length,unkeyed:n.length,rows:w}));for(let[t,r]of F)i.set(t,r);let S=l.filter(t=>b(e).capability("semantic-callees",t.def.relativePath).available).map(t=>({relativePath:t.def.relativePath,symbol:t.def.symbol,contentHash:t.contentHash,depsDigest:t.depsDigest,payload:JSON.stringify(F.get(t.def.symbolId)??[])}));return S.length>0?m("semantic.callees.cache-write",()=>P(e,S),()=>({entries:S.length})):m("semantic.callees.cache-write-skip",()=>{},()=>({reason:"provider-unavailable",misses:l.length})),i}function K(e,s){let a=[],i=new Map,o=0,l=0;for(let{definition:n,callees:h}of s){if(!y(n.relativePath)){l+=1;continue}if(!i.has(n.relativePath)){let p=d(e,n.relativePath),f=p?$(e,n.relativePath):null;i.set(n.relativePath,p&&f?{contentHash:g(e,n.relativePath,p),depsDigest:f}:null)}let c=i.get(n.relativePath);if(!c){o+=1;continue}a.push({relativePath:n.relativePath,symbol:n.symbol,contentHash:c.contentHash,depsDigest:c.depsDigest,payload:JSON.stringify(h)})}return{entries:a,sourceMissing:o,skippedUnsupportedLanguage:l}}var Q="typescript-callees-v2-callsite-line";function $(e,s){let a=y(s);if(a==="typescript")return O(e,s,Q)?.key??null;let i=X(e,s);return a==="rust"?v(JSON.stringify({kind:"semantic-callees",language:a,engine:N(e.config.projectRoot),positionMapping:"nearby-leaf-v2-callsite-line",depsDigest:i})):i}function V(e){try{return JSON.parse(e)}catch{return null}}var W=j("semantic-deps-digest",{clearGroups:["whole-project","source-file"]});function X(e,s){return W.get(e,s,()=>{let i=[...B(e).get(s)??[]].sort().map(o=>`${o}:${g(e,o,d(e,o))}`);return v(i.join("|"))})}export{ce as a};
2
+ //# sourceMappingURL=chunk-Z2AWCTN6.js.map
@@ -1,5 +1,5 @@
1
- import{a as ee,b as ne,c as te}from"./chunk-MJNV7OCG.js";import{a as Q}from"./chunk-APLKXICZ.js";import{c as Z}from"./chunk-U7LRSQG6.js";import{a as z,b as W,c as J}from"./chunk-6SWA6B24.js";import{a as Y,d as w}from"./chunk-FUG6RPYY.js";import{d as K}from"./chunk-HUZNZ3H2.js";import{a as V,d as X}from"./chunk-TM5XEDDR.js";import{h as H}from"./chunk-YRVERHJR.js";import{d as E}from"./chunk-BOJ5SVE2.js";import{a as F,b as x}from"./chunk-35IW3P4H.js";import{w as G}from"./chunk-I3U2FN2T.js";import{z as U}from"./chunk-DMQ7ZKJG.js";import{createHash as ue}from"crypto";var le=6,ve=12,be=48,Ce=2e4,ie=12,L=Number.MAX_SAFE_INTEGER,ye=["definition","callers","callees"],N={search:12,"exact-source":24,definition:24,caller:8,callee:8,"production-reference":6,"test-reference":2,dependency:6,consumer:6};function rn(e,t){if(t.cursor)throw new Error("Inspect no longer accepts semantic packet cursors. Run the original inspect selectors again.");let n=xe(t),r=Ee(e,n),i=r.candidates.sort((c,h)=>O(c,h));n.view==="behavior"&&Re(e,i),ke(e,i),n.view==="behavior"&&we(e,i);let o=ee(i.map(c=>T(c,n.view)),n.evidenceBudgets,(c,h)=>O(c.candidate,h.candidate)),{selected:u,omitted:a}=ne(o.selected,n.maxUnits,n.maxCharacters,(c,h)=>O(c.candidate,h.candidate),n.view==="source"),l=u.map(c=>c.candidate),s=[...o.omitted,...a].map(c=>c.candidate),d=l.map(Ae),m=W(l.map(c=>c.kind==="source"?c.bindingClosure:void 0),l.filter(c=>c.kind==="source").map(c=>({relativePath:c.relativePath,startLine:c.startLine,endLine:c.endLine}))),p=d.reduce((c,h)=>c+(h.kind==="source"?qe(h.source):0),0),g=d.reduce((c,h)=>c+(h.kind==="source"?h.source.length:0),0),y=d.reduce((c,h)=>c+pe(h,n.view),0),v=d.filter(c=>c.kind==="source"&&(c.roles.includes("search")||c.roles.includes("location"))).map(De),b=i.filter(c=>c.kind==="source"&&(c.roles.includes("search")||c.roles.includes("location"))).length,fe=d.filter(c=>c.kind==="source"&&(c.roles.includes("search")||c.roles.includes("location"))).length,k=r.searches.map(c=>Me(c,i,l)),ge=Fe(s),A=r.locations.every(c=>c.matched)&&r.evidence.every(c=>c.kind==="matched")&&r.searches.every(c=>Te(c.textCoverage))&&s.every(c=>!c.roles.some(h=>h==="location"||h==="definition")),D=k.reduce((c,h)=>c+h.omittedMatches,0),$=s.length===0&&D===0,B=$?void 0:me(n,!0),j=$e(n,s),Se=Le($,A,s.length+D,j,k,B),q=i.filter(c=>n.view==="behavior"&&c.kind==="source"&&c.roles.some(h=>h==="location"||h==="definition"||h==="search")).map(c=>({id:`inspect:${c.relativePath}:${c.startLine}-${c.endLine}`,label:c.ownerShort??`${c.relativePath}:${c.startLine+1}`,file:c.relativePath,startLine:c.startLine,endLine:c.endLine})),M=q.length>0?Z(e,q):void 0;return{searches:k,evidence:r.evidence,locations:r.locations,slices:v,candidateSlices:b,omittedSlices:b-fe,maxSlices:b,maxTotalLines:p,units:d,candidateUnits:i.length,omittedUnits:s.length,maxUnits:n.maxUnits,maxCharacters:n.maxCharacters,returnedLines:p,returnedCharacters:g,returnedViewCharacters:y,view:n.view,omissionGroups:j,packetCoverage:{mode:$?"complete":"bounded",candidateUnits:i.length,returnedUnits:d.length,omittedUnits:s.length,omittedByRole:ge,exactSelectorsComplete:A,maxUnits:n.maxUnits,maxCharacters:n.maxCharacters,channels:Oe(i,l,n.evidenceBudgets,n.view),...B?{expansionCommand:B}:{}},stoppingSummary:Se,...M&&M.candidateAnchors>0?{causalFrontier:M}:{},bindingClosure:m,continuation:null}}function Le(e,t,n,r,i,o){let u=f([...r.map(a=>a.drillCommand),...i.flatMap(a=>a.exactFollowup?[a.exactFollowup]:[]),...o?[o]:[]]);return e&&t?{queryStatus:"selection-complete",status:"stop-ready",openEvidence:0,guidance:"All evidence requested by this inspect query was materialized.",drillCommands:[]}:t?{queryStatus:"frontier-accounted",status:"relevance-check-required",openEvidence:n,guidance:"Withheld evidence is accounted for by recoverable groups; drill the groups relevant to the current decision.",drillCommands:u}:{queryStatus:"coverage-incomplete",status:"exact-evidence-withheld",openEvidence:n,guidance:"A requested identity, exact source unit, or current-text coverage requirement is unresolved; drill before relying on it.",drillCommands:u}}function xe(e){let t=E(e.searches),n=E(e.symbols),r=E(e.locations),i=t.length+n.length+r.length;if(i===0)throw new Error("inspect requires at least one --search, --symbol, or --at selector.");if(i>24)throw new RangeError(`inspect accepts at most ${24} selectors; received ${i}.`);let o=e.evidence??{};if(e.unitLines!==void 0&&C(e.unitLines,"unitLines"),e.totalLines!==void 0&&C(e.totalLines,"totalLines"),e.sliceLimit!==void 0&&C(e.sliceLimit,"sliceLimit"),e.maxCharacters!==void 0&&C(e.maxCharacters,"maxCharacters"),e.maxUnits!==void 0&&C(e.maxUnits,"maxUnits"),e.view!==void 0&&e.view!=="source"&&e.view!=="behavior")throw new Error(`Unknown inspect view: ${String(e.view)}. Use source or behavior.`);if(e.full&&(e.searchLimit!==void 0||e.maxUnits!==void 0||e.maxCharacters!==void 0||e.evidenceBudgets!==void 0))throw new Error("full inspect cannot be combined with searchLimit, maxUnits, maxCharacters, or evidenceBudgets.");let u=e.full??!1;return{searches:t,symbols:n,locations:r,...e.scope?.trim()?{scope:e.scope.trim()}:{},context:ae(e.context??le,"context"),searchLimit:C(e.searchLimit??(u?L:ve),"searchLimit"),maxUnits:C(u?L:e.maxUnits??be,"maxUnits"),maxCharacters:C(u?L:e.maxCharacters??Ce,"maxCharacters"),evidenceBudgets:u?Ue():Ie(e.evidenceBudgets??N),view:e.view??"source",evidence:{...o.parts?{parts:[...o.parts]}:n.length>0?{parts:[...ye]}:{},...o.referenceContext!==void 0?{referenceContext:ae(o.referenceContext,"referenceContext")}:{},relatedSourceLines:o.relatedSourceLines??60,...o.semantic!==void 0?{semantic:o.semantic}:{}}}}function Ie(e){let t={...N};for(let[n,r]of Object.entries(e)){if(!(n in t))throw new Error(`Unknown inspect evidence channel: ${n}.`);if(!Number.isSafeInteger(r)||(r??-1)<0)throw new RangeError(`Evidence budget ${n} must be a non-negative safe integer; received ${r}.`);t[n]=r}return t}function Ue(){return Object.fromEntries(Object.keys(N).map(e=>[e,L]))}function Ee(e,t){let n=[],r=0,i=te(e,t.searches,{scope:t.scope,context:0,limit:t.searchLimit,ranking:"structural"}).map((s,d)=>({pattern:t.searches[d],result:s,matches:s.matches})),o=Math.max(0,...i.map(s=>s.matches.length));for(let s=0;s<o;s+=1)for(let d of i){let m=d.matches[s];if(!m)continue;let p=w(e,m.relativePath,m.focusLine,L,t.context);p&&I(e,n,p,"search",`search:${d.pattern}`,m.ownerSymbol,m.ownerShort,1,r++)}let u=i.map(({pattern:s,result:d})=>{let m=d.omittedMatches>0?de(s,t.scope):void 0,p=d.fileCoverage??[],g=_e(s,p,t.scope);return{pattern:s,matchingLines:d.matchingLines,returnedMatches:d.matches.length,omittedMatches:d.omittedMatches,matchingFiles:p.length,returnedFiles:p.filter(y=>y.returnedMatches>0).length,omittedFiles:p.filter(y=>y.returnedMatches===0).length,candidateUnits:0,selectedUnits:0,omittedUnits:0,scopeHints:g.slice(0,ie),omittedScopeHints:Math.max(0,g.length-ie),textCoverage:d.textCoverage,...m?{exactFollowup:m}:{}}}),a=t.locations.map(s=>{let d=je(s),m=d?K(e,d.path):null,p=m?w(e,m,d.line-1,L,t.context):null;return p&&I(e,n,p,"location",`at:${s}`,null,null,0,r++),{target:s,matched:p!==null}}),l=t.symbols.map(s=>Q(e,s,t.evidence));for(let s of l)if(s.kind==="matched"){if(s.definition){let d=w(e,s.definition.relativePath,s.definition.startLine,L,t.context);d&&I(e,n,d,"definition",`definition:${s.shortName}`,s.symbol,s.shortName,0,r++)}for(let d of s.referenceWindows){let m=d.references[0];I(e,n,{...d,focusLine:m?.line??d.startLine,unitType:null,unitStartLine:d.startLine,unitEndLine:d.endLine,omittedLines:0},"reference",`reference:${s.shortName}`,m?.enclosingSymbol??null,m?.enclosingShort??null,x(d.relativePath)==="test"?5:4,r++,d.references.map(p=>p.line),s.symbol)}for(let d of s.callers)re(e,n,d,"caller",s,2,r++);for(let d of s.callees)re(e,n,d,"callee",s,3,r++);for(let d of s.dependencies)oe(e,n,"dependency",s.file,d.relativePath,s.symbol,t.context,6,r++);for(let d of s.consumers)oe(e,n,"consumer",d.relativePath,s.file,s.symbol,t.context,7,r++)}return{searches:u,evidence:l,locations:a,candidates:n}}function O(e,t){return e.priority-t.priority||t.roles.length-e.roles.length||t.reasons.length-e.reasons.length||F(x(e.relativePath))-F(x(t.relativePath))||e.sequence-t.sequence}function T(e,t){return{candidate:e,priority:e.priority,sequence:e.sequence,relativePath:e.relativePath,fileKind:x(e.relativePath),evidenceCharacters:pe(e,t),roles:e.roles,reasons:e.reasons,symbols:e.symbols,behaviorSignals:e.kind==="source"?e.behavior?.signals??[]:[],channel:_(e)}}function _(e){let t=e.roles;return t.includes("location")?"exact-source":t.includes("definition")?"definition":t.includes("caller")?"caller":t.includes("callee")?"callee":t.includes("reference")?x(e.relativePath)==="test"?"test-reference":"production-reference":t.includes("dependency")?"dependency":t.includes("consumer")?"consumer":"search"}function we(e,t){let n=t.filter(i=>i.kind==="source"),r=H(e,{files:f(n.map(i=>i.relativePath))});for(let i of n){i.behavior=V(e,i.relativePath,i.startLine,i.endLine,i.focusLines)??void 0;let o=r.filter(a=>a.source.file===i.relativePath&&a.source.startLine<=i.endLine&&a.source.endLine>=i.startLine),u=o.filter(a=>!Pe(a,o)).map(a=>({observationId:a.id,protocol:a.protocol,action:a.action,role:a.role,strength:a.strength,resolution:a.resolution,line:a.source.startLine,endLine:a.source.endLine,keyParts:a.keyParts.map(l=>({name:l.name,value:l.value,evidence:l.evidence})),derivation:{kind:a.derivation.kind,rule:a.derivation.rule,sourceSpans:a.derivation.sourceSpans.length}}));i.runtimeFacts=u.length>0?u:void 0}}function Pe(e,t){if(e.strength!=="candidate"||e.protocol!=="http")return!1;let n=e.keyParts.find(i=>i.name==="path")?.value,r=e.keyParts.find(i=>i.name==="method")?.value;return n?t.some(i=>{if(i===e||i.action!==e.action||i.role!==e.role||i.source.startLine!==e.source.startLine||i.derivation.rule!=="http.mount-prefix")return!1;let o=i.keyParts.find(a=>a.name==="path")?.value,u=i.keyParts.find(a=>a.name==="method")?.value;return!!(o&&o!==n&&o.endsWith(n)&&(!r||r===u))}):!1}function Re(e,t){for(let n of t){if(n.kind!=="source")continue;let r=X(e,n.relativePath,n.startLine,n.endLine,n.focusLines);r.startLine===n.startLine&&r.endLine===n.endLine||(n.startLine=r.startLine,n.endLine=r.endLine,n.source=U(e,n.relativePath).slice(r.startLine,r.endLine+1).join(`
1
+ import{a as ee,b as ne,c as te}from"./chunk-RDULNRSJ.js";import{a as Q}from"./chunk-YAGYMBEX.js";import{c as Z}from"./chunk-Y334QQU5.js";import{a as z,b as W,c as J}from"./chunk-BTVKZGWT.js";import{a as Y,d as w}from"./chunk-WHADK6OS.js";import{d as K}from"./chunk-ERCYGVAM.js";import{a as V,d as X}from"./chunk-MHIEP7EG.js";import{h as H}from"./chunk-N7FP5H5U.js";import{d as E}from"./chunk-BOJ5SVE2.js";import{a as F,b as x}from"./chunk-Q6T2CAJL.js";import{x as G}from"./chunk-42W3LFUK.js";import{E as U}from"./chunk-Q7GBK5T7.js";import{createHash as ue}from"crypto";var le=6,ve=12,be=48,Ce=2e4,ie=12,L=Number.MAX_SAFE_INTEGER,ye=["definition","callers","callees"],N={search:12,"exact-source":24,definition:24,caller:8,callee:8,"production-reference":6,"test-reference":2,dependency:6,consumer:6};function rn(e,t){if(t.cursor)throw new Error("Inspect no longer accepts semantic packet cursors. Run the original inspect selectors again.");let n=xe(t),r=Ee(e,n),i=r.candidates.sort((c,h)=>O(c,h));n.view==="behavior"&&Re(e,i),ke(e,i),n.view==="behavior"&&we(e,i);let o=ee(i.map(c=>T(c,n.view)),n.evidenceBudgets,(c,h)=>O(c.candidate,h.candidate)),{selected:u,omitted:a}=ne(o.selected,n.maxUnits,n.maxCharacters,(c,h)=>O(c.candidate,h.candidate),n.view==="source"),l=u.map(c=>c.candidate),s=[...o.omitted,...a].map(c=>c.candidate),d=l.map(Ae),m=W(l.map(c=>c.kind==="source"?c.bindingClosure:void 0),l.filter(c=>c.kind==="source").map(c=>({relativePath:c.relativePath,startLine:c.startLine,endLine:c.endLine}))),p=d.reduce((c,h)=>c+(h.kind==="source"?qe(h.source):0),0),g=d.reduce((c,h)=>c+(h.kind==="source"?h.source.length:0),0),y=d.reduce((c,h)=>c+pe(h,n.view),0),v=d.filter(c=>c.kind==="source"&&(c.roles.includes("search")||c.roles.includes("location"))).map(De),b=i.filter(c=>c.kind==="source"&&(c.roles.includes("search")||c.roles.includes("location"))).length,fe=d.filter(c=>c.kind==="source"&&(c.roles.includes("search")||c.roles.includes("location"))).length,k=r.searches.map(c=>Me(c,i,l)),ge=Fe(s),A=r.locations.every(c=>c.matched)&&r.evidence.every(c=>c.kind==="matched")&&r.searches.every(c=>Te(c.textCoverage))&&s.every(c=>!c.roles.some(h=>h==="location"||h==="definition")),D=k.reduce((c,h)=>c+h.omittedMatches,0),$=s.length===0&&D===0,B=$?void 0:me(n,!0),j=$e(n,s),Se=Le($,A,s.length+D,j,k,B),q=i.filter(c=>n.view==="behavior"&&c.kind==="source"&&c.roles.some(h=>h==="location"||h==="definition"||h==="search")).map(c=>({id:`inspect:${c.relativePath}:${c.startLine}-${c.endLine}`,label:c.ownerShort??`${c.relativePath}:${c.startLine+1}`,file:c.relativePath,startLine:c.startLine,endLine:c.endLine})),M=q.length>0?Z(e,q):void 0;return{searches:k,evidence:r.evidence,locations:r.locations,slices:v,candidateSlices:b,omittedSlices:b-fe,maxSlices:b,maxTotalLines:p,units:d,candidateUnits:i.length,omittedUnits:s.length,maxUnits:n.maxUnits,maxCharacters:n.maxCharacters,returnedLines:p,returnedCharacters:g,returnedViewCharacters:y,view:n.view,omissionGroups:j,packetCoverage:{mode:$?"complete":"bounded",candidateUnits:i.length,returnedUnits:d.length,omittedUnits:s.length,omittedByRole:ge,exactSelectorsComplete:A,maxUnits:n.maxUnits,maxCharacters:n.maxCharacters,channels:Oe(i,l,n.evidenceBudgets,n.view),...B?{expansionCommand:B}:{}},stoppingSummary:Se,...M&&M.candidateAnchors>0?{causalFrontier:M}:{},bindingClosure:m,continuation:null}}function Le(e,t,n,r,i,o){let u=f([...r.map(a=>a.drillCommand),...i.flatMap(a=>a.exactFollowup?[a.exactFollowup]:[]),...o?[o]:[]]);return e&&t?{queryStatus:"selection-complete",status:"stop-ready",openEvidence:0,guidance:"All evidence requested by this inspect query was materialized.",drillCommands:[]}:t?{queryStatus:"frontier-accounted",status:"relevance-check-required",openEvidence:n,guidance:"Withheld evidence is accounted for by recoverable groups; drill the groups relevant to the current decision.",drillCommands:u}:{queryStatus:"coverage-incomplete",status:"exact-evidence-withheld",openEvidence:n,guidance:"A requested identity, exact source unit, or current-text coverage requirement is unresolved; drill before relying on it.",drillCommands:u}}function xe(e){let t=E(e.searches),n=E(e.symbols),r=E(e.locations),i=t.length+n.length+r.length;if(i===0)throw new Error("inspect requires at least one --search, --symbol, or --at selector.");if(i>24)throw new RangeError(`inspect accepts at most ${24} selectors; received ${i}.`);let o=e.evidence??{};if(e.unitLines!==void 0&&C(e.unitLines,"unitLines"),e.totalLines!==void 0&&C(e.totalLines,"totalLines"),e.sliceLimit!==void 0&&C(e.sliceLimit,"sliceLimit"),e.maxCharacters!==void 0&&C(e.maxCharacters,"maxCharacters"),e.maxUnits!==void 0&&C(e.maxUnits,"maxUnits"),e.view!==void 0&&e.view!=="source"&&e.view!=="behavior")throw new Error(`Unknown inspect view: ${String(e.view)}. Use source or behavior.`);if(e.full&&(e.searchLimit!==void 0||e.maxUnits!==void 0||e.maxCharacters!==void 0||e.evidenceBudgets!==void 0))throw new Error("full inspect cannot be combined with searchLimit, maxUnits, maxCharacters, or evidenceBudgets.");let u=e.full??!1;return{searches:t,symbols:n,locations:r,...e.scope?.trim()?{scope:e.scope.trim()}:{},context:ae(e.context??le,"context"),searchLimit:C(e.searchLimit??(u?L:ve),"searchLimit"),maxUnits:C(u?L:e.maxUnits??be,"maxUnits"),maxCharacters:C(u?L:e.maxCharacters??Ce,"maxCharacters"),evidenceBudgets:u?Ue():Ie(e.evidenceBudgets??N),view:e.view??"source",evidence:{...o.parts?{parts:[...o.parts]}:n.length>0?{parts:[...ye]}:{},...o.referenceContext!==void 0?{referenceContext:ae(o.referenceContext,"referenceContext")}:{},relatedSourceLines:o.relatedSourceLines??60,...o.semantic!==void 0?{semantic:o.semantic}:{}}}}function Ie(e){let t={...N};for(let[n,r]of Object.entries(e)){if(!(n in t))throw new Error(`Unknown inspect evidence channel: ${n}.`);if(!Number.isSafeInteger(r)||(r??-1)<0)throw new RangeError(`Evidence budget ${n} must be a non-negative safe integer; received ${r}.`);t[n]=r}return t}function Ue(){return Object.fromEntries(Object.keys(N).map(e=>[e,L]))}function Ee(e,t){let n=[],r=0,i=te(e,t.searches,{scope:t.scope,context:0,limit:t.searchLimit,ranking:"structural"}).map((s,d)=>({pattern:t.searches[d],result:s,matches:s.matches})),o=Math.max(0,...i.map(s=>s.matches.length));for(let s=0;s<o;s+=1)for(let d of i){let m=d.matches[s];if(!m)continue;let p=w(e,m.relativePath,m.focusLine,L,t.context);p&&I(e,n,p,"search",`search:${d.pattern}`,m.ownerSymbol,m.ownerShort,1,r++)}let u=i.map(({pattern:s,result:d})=>{let m=d.omittedMatches>0?de(s,t.scope):void 0,p=d.fileCoverage??[],g=_e(s,p,t.scope);return{pattern:s,matchingLines:d.matchingLines,returnedMatches:d.matches.length,omittedMatches:d.omittedMatches,matchingFiles:p.length,returnedFiles:p.filter(y=>y.returnedMatches>0).length,omittedFiles:p.filter(y=>y.returnedMatches===0).length,candidateUnits:0,selectedUnits:0,omittedUnits:0,scopeHints:g.slice(0,ie),omittedScopeHints:Math.max(0,g.length-ie),textCoverage:d.textCoverage,...m?{exactFollowup:m}:{}}}),a=t.locations.map(s=>{let d=je(s),m=d?K(e,d.path):null,p=m?w(e,m,d.line-1,L,t.context):null;return p&&I(e,n,p,"location",`at:${s}`,null,null,0,r++),{target:s,matched:p!==null}}),l=t.symbols.map(s=>Q(e,s,t.evidence));for(let s of l)if(s.kind==="matched"){if(s.definition){let d=w(e,s.definition.relativePath,s.definition.startLine,L,t.context);d&&I(e,n,d,"definition",`definition:${s.shortName}`,s.symbol,s.shortName,0,r++)}for(let d of s.referenceWindows){let m=d.references[0];I(e,n,{...d,focusLine:m?.line??d.startLine,unitType:null,unitStartLine:d.startLine,unitEndLine:d.endLine,omittedLines:0},"reference",`reference:${s.shortName}`,m?.enclosingSymbol??null,m?.enclosingShort??null,x(d.relativePath)==="test"?5:4,r++,d.references.map(p=>p.line),s.symbol)}for(let d of s.callers)re(e,n,d,"caller",s,2,r++);for(let d of s.callees)re(e,n,d,"callee",s,3,r++);for(let d of s.dependencies)oe(e,n,"dependency",s.file,d.relativePath,s.symbol,t.context,6,r++);for(let d of s.consumers)oe(e,n,"consumer",d.relativePath,s.file,s.symbol,t.context,7,r++)}return{searches:u,evidence:l,locations:a,candidates:n}}function O(e,t){return e.priority-t.priority||t.roles.length-e.roles.length||t.reasons.length-e.reasons.length||F(x(e.relativePath))-F(x(t.relativePath))||e.sequence-t.sequence}function T(e,t){return{candidate:e,priority:e.priority,sequence:e.sequence,relativePath:e.relativePath,fileKind:x(e.relativePath),evidenceCharacters:pe(e,t),roles:e.roles,reasons:e.reasons,symbols:e.symbols,behaviorSignals:e.kind==="source"?e.behavior?.signals??[]:[],channel:_(e)}}function _(e){let t=e.roles;return t.includes("location")?"exact-source":t.includes("definition")?"definition":t.includes("caller")?"caller":t.includes("callee")?"callee":t.includes("reference")?x(e.relativePath)==="test"?"test-reference":"production-reference":t.includes("dependency")?"dependency":t.includes("consumer")?"consumer":"search"}function we(e,t){let n=t.filter(i=>i.kind==="source"),r=H(e,{files:f(n.map(i=>i.relativePath))});for(let i of n){i.behavior=V(e,i.relativePath,i.startLine,i.endLine,i.focusLines)??void 0;let o=r.filter(a=>a.source.file===i.relativePath&&a.source.startLine<=i.endLine&&a.source.endLine>=i.startLine),u=o.filter(a=>!Pe(a,o)).map(a=>({observationId:a.id,protocol:a.protocol,action:a.action,role:a.role,strength:a.strength,resolution:a.resolution,line:a.source.startLine,endLine:a.source.endLine,keyParts:a.keyParts.map(l=>({name:l.name,value:l.value,evidence:l.evidence})),derivation:{kind:a.derivation.kind,rule:a.derivation.rule,sourceSpans:a.derivation.sourceSpans.length}}));i.runtimeFacts=u.length>0?u:void 0}}function Pe(e,t){if(e.strength!=="candidate"||e.protocol!=="http")return!1;let n=e.keyParts.find(i=>i.name==="path")?.value,r=e.keyParts.find(i=>i.name==="method")?.value;return n?t.some(i=>{if(i===e||i.action!==e.action||i.role!==e.role||i.source.startLine!==e.source.startLine||i.derivation.rule!=="http.mount-prefix")return!1;let o=i.keyParts.find(a=>a.name==="path")?.value,u=i.keyParts.find(a=>a.name==="method")?.value;return!!(o&&o!==n&&o.endsWith(n)&&(!r||r===u))}):!1}function Re(e,t){for(let n of t){if(n.kind!=="source")continue;let r=X(e,n.relativePath,n.startLine,n.endLine,n.focusLines);r.startLine===n.startLine&&r.endLine===n.endLine||(n.startLine=r.startLine,n.endLine=r.endLine,n.source=U(e,n.relativePath).slice(r.startLine,r.endLine+1).join(`
2
2
  `),n.unitStartLine=r.startLine,n.unitEndLine=r.endLine,n.omittedLines=0)}}function ke(e,t){for(let n of t)n.kind==="source"&&(n.bindingClosure=z(e,n.relativePath,n.startLine,n.endLine))}function $e(e,t){let n=new Map;for(let r of t){let i=R(r.relativePath),o=_(r),u=[...r.roles].sort().join(","),a=r.kind==="path"?r.relationship:"",l=`${i}|${o}|${u}|${a}`,s=n.get(l)??[];s.push(r),n.set(l,s)}return[...n.entries()].map(([r,i])=>{let o=i[0],u=f(i.flatMap(l=>[...l.roles])).sort(),a=f(i.flatMap(l=>l.kind==="source"?l.behavior?.signals??[]:[])).sort();return{id:`g-${ue("sha256").update(r).digest("hex").slice(0,8)}`,scope:R(o.relativePath),channel:_(o),roles:u,behaviorSignals:a,candidateUnits:i.length,sourceCharacters:i.reduce((l,s)=>l+(s.kind==="source"?s.source.length:0),0),anchors:i.map(l=>({relativePath:l.relativePath,line:l.kind==="source"?l.focusLine:0,ownerShort:l.kind==="source"?l.ownerShort:null,roles:[...l.roles],behaviorSignals:l.kind==="source"?[...l.behavior?.signals??[]]:[]})),drillCommand:Be(e,i)}}).sort((r,i)=>i.candidateUnits-r.candidateUnits||i.sourceCharacters-r.sourceCharacters||r.scope.localeCompare(i.scope)||r.id.localeCompare(i.id))}function Be(e,t){let n=f(t.flatMap(o=>o.reasons.filter(u=>u.startsWith("search:")).map(u=>u.slice(7)))),r=R(t[0].relativePath);if(n.length>0&&t.every(o=>o.kind==="source"&&o.roles.includes("search"))){let o=["scip-query inspect"];for(let u of n)o.push(`--search ${S(u)}`);return o.push(`--scope ${S(r)}`,"--full"),e.view==="behavior"&&o.push("--view behavior"),o.join(" ")}let i=t.filter(o=>o.kind==="source");if(i.length>0&&i.length<=24){let o=["scip-query inspect"];for(let u of i)o.push(`--at ${S(`${u.relativePath}:${u.focusLine+1}`)}`);return e.view==="behavior"&&o.push("--view behavior"),o.join(" ")}return t.length===1&&t[0].kind==="path"?t[0].exactFollowup:me(e,!0)}function Me(e,t,n){let r=`search:${e.pattern}`,i=t.filter(a=>a.reasons.includes(r)).length,o=new Set(n),u=t.filter(a=>a.reasons.includes(r)&&o.has(a)).length;return{...e,candidateUnits:i,selectedUnits:u,omittedUnits:i-u}}function Fe(e){let t={};for(let n of e)for(let r of n.roles)t[r]=(t[r]??0)+1;return t}function Oe(e,t,n,r){let i=e.map(u=>T(u,r).channel),o=t.map(u=>T(u,r).channel);return Object.fromEntries(Object.keys(n).map(u=>{let a=i.filter(s=>s===u).length,l=o.filter(s=>s===u).length;return[u,{candidateUnits:a,returnedUnits:l,omittedUnits:a-l,maxUnits:n[u]}]}))}function Te(e){return!!(e&&e.skippedUnreadablePaths.length===0&&e.skippedOversizedPaths.length===0)}function _e(e,t,n){let r=new Map;for(let i of t){let o=R(i.relativePath),u=r.get(o)??{matchingLines:0,returnedMatches:0};u.matchingLines+=i.matchingLines,u.returnedMatches+=i.returnedMatches,r.set(o,u)}return[...r.entries()].map(([i,o])=>({scope:i,...o,exactFollowup:de(e,i||n)})).sort((i,o)=>o.matchingLines-i.matchingLines||o.returnedMatches-i.returnedMatches||i.scope.localeCompare(o.scope))}function R(e){let t=e.lastIndexOf("/");return t<0?e:e.slice(0,t)}function de(e,t){return`scip-query inspect --search ${S(e)}${t?` --scope ${S(t)}`:""} --full`}function me(e,t){let n=["scip-query inspect"];for(let r of e.searches)n.push(`--search ${S(r)}`);for(let r of e.symbols)n.push(`--symbol ${S(r)}`);for(let r of e.locations)n.push(`--at ${S(r)}`);return e.scope&&n.push(`--scope ${S(e.scope)}`),e.context!==le&&n.push(`--context ${e.context}`),e.evidence.parts&&n.push(`--include ${S(e.evidence.parts.join(","))}`),t&&n.push("--full"),e.view==="behavior"&&n.push("--view behavior"),n.join(" ")}function re(e,t,n,r,i,o,u){I(e,t,{...n,unitType:null,unitStartLine:n.startLine,unitEndLine:n.endLine+n.omittedLines},r,`${r}:${i.shortName}`,n.symbol,n.shortName,o,u,[n.focusLine],i.symbol)}function oe(e,t,n,r,i,o,u,a,l){let s=`${r} -> ${i}`,d=G(e,r).filter(b=>b.sourcePath===i),m=U(e,r),p=Ne(m,d,i),g=p===null?null:Y(e,r,p,Math.min(u,4));if(g){I(e,t,{...g,unitType:null,unitStartLine:g.startLine,unitEndLine:g.endLine,omittedLines:0},n,`${n}:${s}`,null,null,a,l,[g.focusLine],o);return}let y=`scip-query inspect --search ${S(he(i))} --scope ${S(r)}`,v=t.find(b=>b.kind==="path"&&b.relativePath===r&&b.relationship===s);if(v){v.roles=f([...v.roles,n]),v.reasons=f([...v.reasons,`${n}:${s}`]),v.symbols=f([...v.symbols,o]),v.priority=Math.min(v.priority,a);return}t.push({kind:"path",roles:[n],relativePath:r,relationship:s,reasons:[`${n}:${s}`],symbols:[o],exactFollowup:y,priority:a,sequence:l})}function Ne(e,t,n){let r=f(t.flatMap(l=>[l.importedName,l.localName??""]).filter(l=>l.length>1)),i=he(n).replace(/\.[^.]+$/u,""),o=f([...r,i]).filter(Boolean),u=/\b(?:from|import|include|require|use)\b/u,a=e.findIndex(l=>u.test(l)&&o.some(s=>l.includes(s)));return a>=0?a:null}function I(e,t,n,r,i,o,u,a,l,s=[n.focusLine],d){let m=t.find(p=>p.kind==="source"&&p.relativePath===n.relativePath&&p.startLine<=n.endLine&&n.startLine<=p.endLine);if(m){let p=Math.min(m.startLine,n.startLine),g=Math.max(m.endLine,n.endLine);m.startLine=p,m.endLine=g,m.source=U(e,n.relativePath).slice(p,g+1).join(`
3
3
  `),m.focusLine=Math.min(m.focusLine,n.focusLine),m.focusLines=ce([...m.focusLines,...s]),m.unitStartLine=Math.min(m.unitStartLine,n.unitStartLine),m.unitEndLine=Math.max(m.unitEndLine,n.unitEndLine),m.omittedLines=Math.max(m.omittedLines,n.omittedLines),m.reasons=f([...m.reasons,i]),m.roles=f([...m.roles,r]),m.symbols=f([...m.symbols,...d?[d]:[]]),!m.ownerSymbol&&o&&(m.ownerSymbol=o),!m.ownerShort&&u&&(m.ownerShort=u),m.priority=Math.min(m.priority,a);return}t.push({kind:"source",...n,reasons:[i],focusLines:ce(s),ownerSymbol:o,ownerShort:u,roles:[r],symbols:d?[d]:[],priority:a,sequence:l})}function Ae(e){if(e.kind==="path"){let{priority:o,sequence:u,...a}=e;return{...a,id:se(a)}}let{priority:t,sequence:n,bindingClosure:r,...i}=e;return{...i,id:se(i),omittedCharacters:0}}function De(e){let{kind:t,id:n,roles:r,symbols:i,omittedCharacters:o,behavior:u,runtimeFacts:a,...l}=e;return l}function se(e){return ue("sha256").update(JSON.stringify(e)).digest("hex").slice(0,16)}function je(e){let t=e.match(/^(.+\.\w+):(\d+)$/u);if(!t)return null;let n=Number(t[2]);return Number.isSafeInteger(n)&&n>0?{path:t[1],line:n}:null}function f(e){return[...new Set(e)]}function ce(e){return f(e).sort((t,n)=>t-n)}function qe(e){return e.length===0?0:e.split(`
4
4
  `).length}function pe(e,t){if(e.kind==="path")return e.relationship.length+e.exactFollowup.length;let n="bindingClosure"in e?J(e.bindingClosure):0,r=(e.runtimeFacts??[]).reduce((i,o)=>i+o.action.length+o.derivation.rule.length+o.keyParts.reduce((u,a)=>u+a.name.length+a.value.length+4,0)+24,0);return t!=="behavior"?e.source.length+n:e.behavior?e.behavior.lines.reduce((i,o)=>i+o.text.length+o.signals.join(",").length+12,0)+e.behavior.testCases.reduce((i,o)=>i+o.length+2,0)+r+n:e.source.length+n+r}function he(e){return e.split("/").at(-1)??e}function S(e){return`'${e.replaceAll("'","'\\''")}'`}function C(e,t){if(!Number.isSafeInteger(e)||e<=0)throw new RangeError(`${t} must be a positive safe integer; received ${e}`);return e}function ae(e,t){if(!Number.isSafeInteger(e)||e<0)throw new RangeError(`${t} must be a non-negative safe integer; received ${e}`);return e}export{rn as a};
5
- //# sourceMappingURL=chunk-PHSPBQM6.js.map
5
+ //# sourceMappingURL=chunk-Z2PZVKPR.js.map
@@ -1,2 +1,2 @@
1
- import{d}from"./chunk-B3X6KU75.js";import{O as p}from"./chunk-AA7K3XLM.js";function y(t,e={}){let{minTotalLines:i=800,minTemplateLines:n=300,minScriptLines:r=300,minStyleLines:u=500,limit:o=20,scope:a,scanLimit:l,filePattern:m}=e;return p(t).vueProfiles({scope:a,scanLimit:l}).filter(s=>!m||s.file.includes(m)).map(s=>L(s,{minTotalLines:i,minTemplateLines:n,minScriptLines:r,minStyleLines:u})).filter(s=>s!==null).sort((s,c)=>c.totalLines-s.totalLines||s.file.localeCompare(c.file)).slice(0,o)}function L(t,e){let i=d(t,b(e),"total"),{reasons:n}=i;if(n.length===0)return null;let r=i.dominantPressure,u=i.pressureKinds.includes("total")?[...new Set([...i.pressureKinds,r])]:i.pressureKinds,o=g(t.file),a=x(r,o),l=t.totalLines+t.delegatedComposableLines;return{file:t.file,totalLines:l,sfcLines:t.sfcLines,templateLines:t.templateLines,scriptLines:t.scriptLines,styleLines:t.styleLines,externalScriptLines:t.externalScriptLines,externalScriptPaths:t.externalScriptPaths,customBlockLines:t.customBlockLines,delegatedComposableLines:t.delegatedComposableLines,delegatedComposablePaths:t.delegatedComposablePaths,dominantPressure:r,pressureKinds:u,contextKind:o,recommendationKind:a,recommendation:f(a,o),reasons:n,loc:l}}function b(t){return[{axis:"total",value:e=>e.totalLines+e.delegatedComposableLines,qualifies:(e,i)=>i>=t.minTotalLines,reason:(e,i)=>e.delegatedComposableLines>0?`${i} total line(s) (${e.totalLines} component + ${e.delegatedComposableLines} delegated composable line(s) across ${e.delegatedComposablePaths.length} file(s))`:`${i} total component line(s)`,dominantEligible:!1},{axis:"template",value:e=>e.templateLines,qualifies:(e,i)=>i>=t.minTemplateLines,reason:(e,i)=>`${i} template line(s)`},{axis:"script",value:e=>e.scriptLines-e.externalScriptLines,qualifies:e=>e.scriptLines>=t.minScriptLines,reason:e=>`${e.scriptLines} script line(s)`},{axis:"style",value:e=>e.styleLines,qualifies:(e,i)=>i>=t.minStyleLines,reason:(e,i)=>`${i} style line(s)`},{axis:"external-script",value:e=>e.externalScriptLines,qualifies:(e,i)=>i>=t.minScriptLines},{axis:"custom-block",value:e=>e.customBlockLines,qualifies:()=>!1}]}function g(t){return t.toLowerCase().split(/[^a-z0-9]+/).filter(Boolean).some(n=>w.has(n))||/(?:view|page|route)\.vue$/i.test(t)||/(?:^|\/)(views|pages|routes)\//i.test(t)?"route-page":"component"}function x(t,e){return t==="style"?"style-decomposition":t==="template"?"template-decomposition":t==="external-script"?"external-script-boundary":t==="custom-block"?"custom-block-review":e==="route-page"?"route-page-decomposition":t==="script"?"script-behavior-extraction":"total-size-review"}function f(t,e){switch(t){case"template-decomposition":return e==="route-page"?"Split route template sections into named panels before extracting script behavior.":"Split repeated template sections into named presentational components.";case"script-behavior-extraction":return"Extract independent script behavior into composables, controllers, or feature modules.";case"style-decomposition":return"Review UI/style decomposition; move repeated styling to component or style primitives, not composables.";case"external-script-boundary":return"Review the external script boundary and split controller/composable modules by workflow.";case"custom-block-review":return"Review custom block ownership before splitting template or script code.";case"route-page-decomposition":return"Split route/page orchestration from reusable panels and feature controllers.";case"total-size-review":return"Review the largest block first, then split by the dominant reason to change."}}var w=new Set(["landing","page","pages","route","routes","view","views"]);export{y as a};
2
- //# sourceMappingURL=chunk-QXR5QPSF.js.map
1
+ import{d}from"./chunk-B3X6KU75.js";import{P as p}from"./chunk-7JYHQAH2.js";function y(t,e={}){let{minTotalLines:i=800,minTemplateLines:n=300,minScriptLines:r=300,minStyleLines:u=500,limit:o=20,scope:a,scanLimit:l,filePattern:m}=e;return p(t).vueProfiles({scope:a,scanLimit:l}).filter(s=>!m||s.file.includes(m)).map(s=>L(s,{minTotalLines:i,minTemplateLines:n,minScriptLines:r,minStyleLines:u})).filter(s=>s!==null).sort((s,c)=>c.totalLines-s.totalLines||s.file.localeCompare(c.file)).slice(0,o)}function L(t,e){let i=d(t,b(e),"total"),{reasons:n}=i;if(n.length===0)return null;let r=i.dominantPressure,u=i.pressureKinds.includes("total")?[...new Set([...i.pressureKinds,r])]:i.pressureKinds,o=g(t.file),a=x(r,o),l=t.totalLines+t.delegatedComposableLines;return{file:t.file,totalLines:l,sfcLines:t.sfcLines,templateLines:t.templateLines,scriptLines:t.scriptLines,styleLines:t.styleLines,externalScriptLines:t.externalScriptLines,externalScriptPaths:t.externalScriptPaths,customBlockLines:t.customBlockLines,delegatedComposableLines:t.delegatedComposableLines,delegatedComposablePaths:t.delegatedComposablePaths,dominantPressure:r,pressureKinds:u,contextKind:o,recommendationKind:a,recommendation:f(a,o),reasons:n,loc:l}}function b(t){return[{axis:"total",value:e=>e.totalLines+e.delegatedComposableLines,qualifies:(e,i)=>i>=t.minTotalLines,reason:(e,i)=>e.delegatedComposableLines>0?`${i} total line(s) (${e.totalLines} component + ${e.delegatedComposableLines} delegated composable line(s) across ${e.delegatedComposablePaths.length} file(s))`:`${i} total component line(s)`,dominantEligible:!1},{axis:"template",value:e=>e.templateLines,qualifies:(e,i)=>i>=t.minTemplateLines,reason:(e,i)=>`${i} template line(s)`},{axis:"script",value:e=>e.scriptLines-e.externalScriptLines,qualifies:e=>e.scriptLines>=t.minScriptLines,reason:e=>`${e.scriptLines} script line(s)`},{axis:"style",value:e=>e.styleLines,qualifies:(e,i)=>i>=t.minStyleLines,reason:(e,i)=>`${i} style line(s)`},{axis:"external-script",value:e=>e.externalScriptLines,qualifies:(e,i)=>i>=t.minScriptLines},{axis:"custom-block",value:e=>e.customBlockLines,qualifies:()=>!1}]}function g(t){return t.toLowerCase().split(/[^a-z0-9]+/).filter(Boolean).some(n=>w.has(n))||/(?:view|page|route)\.vue$/i.test(t)||/(?:^|\/)(views|pages|routes)\//i.test(t)?"route-page":"component"}function x(t,e){return t==="style"?"style-decomposition":t==="template"?"template-decomposition":t==="external-script"?"external-script-boundary":t==="custom-block"?"custom-block-review":e==="route-page"?"route-page-decomposition":t==="script"?"script-behavior-extraction":"total-size-review"}function f(t,e){switch(t){case"template-decomposition":return e==="route-page"?"Split route template sections into named panels before extracting script behavior.":"Split repeated template sections into named presentational components.";case"script-behavior-extraction":return"Extract independent script behavior into composables, controllers, or feature modules.";case"style-decomposition":return"Review UI/style decomposition; move repeated styling to component or style primitives, not composables.";case"external-script-boundary":return"Review the external script boundary and split controller/composable modules by workflow.";case"custom-block-review":return"Review custom block ownership before splitting template or script code.";case"route-page-decomposition":return"Split route/page orchestration from reusable panels and feature controllers.";case"total-size-review":return"Review the largest block first, then split by the dominant reason to change."}}var w=new Set(["landing","page","pages","route","routes","view","views"]);export{y as a};
2
+ //# sourceMappingURL=chunk-ZAZGGSM3.js.map
@@ -1,2 +1,2 @@
1
- import{c as a}from"./chunk-BOJ5SVE2.js";import{a as m}from"./chunk-6BJ7SOY7.js";import{a as b,b as S}from"./chunk-ICUQONOG.js";import{o as y}from"./chunk-RGCJ4646.js";import{a as f}from"./chunk-LPGDO2XA.js";import{d as r}from"./chunk-5IZTXSOL.js";function u(o,l,t={}){let i=f(o,l);if(!i)return null;let g=[{file:i.relativePath,line:i.startLine}],s=y(o,i,{semantic:t.semantic,semanticEvidence:m}).map(e=>({file:e.file,line:e.line,enclosingSymbol:e.enclosingSymbol??"(top-level)",enclosingShort:e.enclosingSymbol?r(e.enclosingSymbol):"(top-level)"})),{outgoingCalls:c,incomingCalls:n}=h(o,i,s,{semantic:t.semantic!==!1});return{symbol:i.symbol,shortName:r(i.symbol),relativePath:i.relativePath,definitionSites:g.filter(e=>!o.isIgnored(e.file)),referenceSites:s,outgoingCalls:c.filter(e=>!o.isIgnored(e.file)).map(e=>({symbol:e.symbol,shortName:r(e.symbol),file:e.file})),incomingCalls:n.filter(e=>!o.isIgnored(e.file)).map(e=>({symbol:e.symbol,shortName:e.symbol===e.file?"(top-level)":r(e.symbol),file:e.file}))}}function A(o,l,t={}){let i=u(o,l,t);return i?{symbol:i.symbol,shortName:i.shortName,relativePath:i.relativePath,definitionSites:i.definitionSites,usageSites:i.referenceSites,producers:i.outgoingCalls,consumers:i.incomingCalls}:null}function h(o,l,t,i){let g=a(b(o,l,{limit:30,semantic:i.semantic,semanticEvidence:m}).map(n=>({symbol:n.symbol,file:n.file}))),s=a(S(o,l,{limit:30,semantic:i.semantic,semanticEvidence:m})),c=s.length>0?s:a(t.map(n=>({symbol:n.enclosingSymbol==="(top-level)"?n.file:n.enclosingSymbol,file:n.file})));return{outgoingCalls:g,incomingCalls:c}}export{u as a,A as b};
2
- //# sourceMappingURL=chunk-5236NQV3.js.map
1
+ import{c as a}from"./chunk-BOJ5SVE2.js";import{a as m}from"./chunk-Z2AWCTN6.js";import{a as b,b as S}from"./chunk-BWVQP3LB.js";import{o as y}from"./chunk-AYPDH2LU.js";import{a as f}from"./chunk-5H5WTJSD.js";import{d as r}from"./chunk-TD7VKJ2Y.js";function u(o,l,t={}){let i=f(o,l);if(!i)return null;let g=[{file:i.relativePath,line:i.startLine}],s=y(o,i,{semantic:t.semantic,semanticEvidence:m}).map(e=>({file:e.file,line:e.line,enclosingSymbol:e.enclosingSymbol??"(top-level)",enclosingShort:e.enclosingSymbol?r(e.enclosingSymbol):"(top-level)"})),{outgoingCalls:c,incomingCalls:n}=h(o,i,s,{semantic:t.semantic!==!1});return{symbol:i.symbol,shortName:r(i.symbol),relativePath:i.relativePath,definitionSites:g.filter(e=>!o.isIgnored(e.file)),referenceSites:s,outgoingCalls:c.filter(e=>!o.isIgnored(e.file)).map(e=>({symbol:e.symbol,shortName:r(e.symbol),file:e.file})),incomingCalls:n.filter(e=>!o.isIgnored(e.file)).map(e=>({symbol:e.symbol,shortName:e.symbol===e.file?"(top-level)":r(e.symbol),file:e.file}))}}function A(o,l,t={}){let i=u(o,l,t);return i?{symbol:i.symbol,shortName:i.shortName,relativePath:i.relativePath,definitionSites:i.definitionSites,usageSites:i.referenceSites,producers:i.outgoingCalls,consumers:i.incomingCalls}:null}function h(o,l,t,i){let g=a(b(o,l,{limit:30,semantic:i.semantic,semanticEvidence:m}).map(n=>({symbol:n.symbol,file:n.file}))),s=a(S(o,l,{limit:30,semantic:i.semantic,semanticEvidence:m})),c=s.length>0?s:a(t.map(n=>({symbol:n.enclosingSymbol==="(top-level)"?n.file:n.enclosingSymbol,file:n.file})));return{outgoingCalls:g,incomingCalls:c}}export{u as a,A as b};
2
+ //# sourceMappingURL=chunk-ZGW4HLPD.js.map
@@ -0,0 +1,2 @@
1
+ import{h as I}from"./chunk-PBUH2P5S.js";import{a as p,e as g}from"./chunk-TD7VKJ2Y.js";import{z as v}from"./chunk-7JYHQAH2.js";import{c as b,i as D,j as F,r as _,t as y,w as E,y as x}from"./chunk-Q7GBK5T7.js";import{spawnSync as O}from"child_process";import{createHash as U}from"crypto";import{existsSync as k}from"fs";import{dirname as L,join as T}from"path";import{fileURLToPath as j}from"url";var N=b("definition-consumer-file-usage",{clearGroups:["whole-project","source-file"]}),M=E({kind:"consumer-file-usage",invalidation:x("consumer-file-usage"),serialize:W,deserialize:X});function Me(e,n){return{forDefinitions(t,r){return V(e,n,t,r)}}}function Re(e){let n=new Map;for(let[t,r]of e)n.set(t,new Set(r.files.map(i=>i.file)));return n}function Ne(e,n,t){return w(e,n,t).partition}function V(e,n,t,r){let i=h(t.length),s=_()?F(e):null,a=s?B(t,r,s):void 0,o=a?{workIdentity:a,workOutcome:"computed"}:{};return y("consumer-evidence.product",()=>{let l=y("consumer-evidence.provenance",()=>Y(e,n,t,r),()=>({...o,definitions:t.length,semantic:r.semantic,sourceFallback:r.sourceFallback!==!1})),u=new Map;i={...i,...l.counters};let c=z(t,l.sources);return y("consumer-evidence.classify",()=>{let f=q(e,t,l.sources,c);for(let d of t){let m=f.get(d.symbolId)??H();i.realFiles+=m.partition.realConsumers.length,i.reexportOnlyFiles+=m.partition.barrelConsumers,i.importOnlyFiles+=m.partition.importOnlyConsumers,u.set(d.symbolId,{definition:d,files:m.files,...m.partition})}},()=>({...o,...c,realFiles:i.realFiles,reexportOnlyFiles:i.reexportOnlyFiles,importOnlyFiles:i.importOnlyFiles})),u},()=>({...o,...i}))}function B(e,n,t){let r=U("sha256").update("consumer-evidence-v1\0").update(t).update("\0").update(n.semantic?"semantic\0":"indexed\0").update(n.sourceFallback===!1?"no-source-fallback":"source-fallback");for(let i of e.map(s=>s.symbol).sort())r.update("\0").update(i);return r.digest("hex").slice(0,24)}function h(e){return{definitions:e,indexedFiles:0,semanticFiles:0,fallbackFiles:0,totalFiles:0,realFiles:0,reexportOnlyFiles:0,importOnlyFiles:0}}function Y(e,n,t,r){let i=h(t.length),s=new Map;return S(s,i,"indexed",n.crossFileCallerMap(t,{semantic:!1})),r.semantic&&S(s,i,"semantic",I(e,t)),r.sourceFallback!==!1&&S(s,i,"source-fallback",n.sourceFallbackCallerFiles(t)),i.totalFiles=[...s.values()].reduce((a,o)=>a+o.size,0),{sources:s,counters:i}}function z(e,n){return{definitions:e.length,consumerFiles:[...n.values()].reduce((t,r)=>t+r.size,0),nativeAttempted:!1,nativeUsed:!1,nativeReason:"not-attempted"}}function S(e,n,t,r){let i=0;for(let[s,a]of r){let o=e.get(s);o||(o=new Map,e.set(s,o));for(let l of a){i++;let u=o.get(l)??new Set;u.add(t),o.set(l,u)}}t==="indexed"?n.indexedFiles+=i:t==="semantic"?n.semanticFiles+=i:n.fallbackFiles+=i}function q(e,n,t,r){let i=se(e,n,t,r);return i||$(e,n,t)}function $(e,n,t){let r=new Map;for(let i of n){let s=t.get(i.symbolId)??new Map;r.set(i.symbolId,w(e,i,[...s.keys()],s))}return r}function w(e,n,t,r=new Map){let i=[],s=0,a=0,o=g(n.symbol),l=[];for(let u of t){let c;Z(e,u,n.relativePath,o)?(s++,c="reexport-only"):J(e,u,o)?(a++,c="import-only"):(i.push(u),c="real"),l.push({file:u,sources:[...r.get(u)??[]],classification:c})}return{partition:{realConsumers:i,barrelConsumers:s,importOnlyConsumers:a},files:l}}function H(){return{partition:{realConsumers:[],barrelConsumers:0,importOnlyConsumers:0},files:[]}}function J(e,n,t){if(!t)return!1;let r=v(n);if(!r)return!1;let i=N.get(e,n,()=>A(e,n,r));return i.importedLeaves.has(t)&&!i.usedLeaves.has(t)}function A(e,n,t){let r=p(e).forFile(n,{text:!0}).text;if(!r)return Q();let i=D(e,n,r),s=M.read(e,n,i);if(s)return s;let a=G(p(e).forFile(n,{ast:!0}).ast,t);return M.write(e,n,i,a),a}var K=new Set(["identifier","type_identifier","property_identifier","field_identifier"]);function G(e,n){let t=new Set,r=new Set;if(!e)return{importedLeaves:t,usedLeaves:r};let i=n==="rust"?new Set(["use_declaration"]):n==="python"?new Set(["import_statement","import_from_statement"]):new Set(["import_statement"]),s=e.walk(),a=0,o=!1;for(;!o;){let l=s.nodeType,u=i.has(l);if(u&&(a+=1),K.has(l)&&(a>0?t:r).add(s.nodeText),!s.gotoFirstChild())for(u&&(a-=1);!s.gotoNextSibling();){if(!s.gotoParent()){o=!0;break}i.has(s.nodeType)&&(a-=1)}}return{importedLeaves:t,usedLeaves:r}}function Q(){return{importedLeaves:new Set,usedLeaves:new Set}}function W(e){return JSON.stringify({importedLeaves:[...e.importedLeaves],usedLeaves:[...e.usedLeaves]})}function X(e){try{let n=JSON.parse(e);return!Array.isArray(n.importedLeaves)||!Array.isArray(n.usedLeaves)?null:{importedLeaves:new Set(n.importedLeaves.filter(t=>typeof t=="string")),usedLeaves:new Set(n.usedLeaves.filter(t=>typeof t=="string"))}}catch{return null}}function Z(e,n,t,r){if(!r)return!1;let i=p(e).forFile(n,{lines:!0,reexports:!0}),s=i.lines??[];if(s.length===0)return!1;let a=i.reexports??[];return P(s,a,r)}function P(e,n,t){if(e.length===0||n.length===0)return!1;let r=t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),i=new RegExp(`\\b${r}\\b`),s=0;for(let a=0;a<e.length;a++){if(!i.test(e[a]??""))continue;if(s++,!n.find(l=>l.startLine<=a&&a<=l.endLine))return!1}return s>0}var ee="SCIP_QUERY_NATIVE_CONSUMER_CLASSIFY",ne="SCIP_QUERY_NATIVE_KERNELS_BIN",ie="SCIP_QUERY_NATIVE_CONSUMER_CLASSIFY_MIN_FILES",R=1e3,re=5e3,te=64*1024*1024,C;function se(e,n,t,r){let i=process.env[ee]?.toLowerCase();if(i!=="1"&&i!=="true")return r.nativeReason=i==="0"||i==="false"?"disabled":"opt-in-required",null;if(r.consumerFiles<me())return r.nativeReason="below-threshold",null;let s=de();if(!s)return r.nativeReason="binary-missing",null;r.nativeAttempted=!0;let a=oe(e,n,t),o=O(s,["consumer-classify"],{input:JSON.stringify(a),encoding:"utf8",timeout:re,maxBuffer:te});if(o.status!==0||o.error)return r.nativeReason=o.error?`spawn-error:${o.error.message}`:`exit-${o.status??"null"}`,null;try{let l=JSON.parse(o.stdout),u=le(l,n);return u?(r.nativeUsed=!0,r.nativeReason="used",u):(r.nativeReason="invalid-response",null)}catch{return r.nativeReason="invalid-json",null}}function oe(e,n,t){let r=new Map,i=[];for(let o of n){let l=g(o.symbol),c=[...(t.get(o.symbolId)??new Map).entries()].map(([f,d])=>{let m=r.get(f)??new Set;return l&&m.add(l),r.set(f,m),{file:f,sources:[...d]}});i.push({symbol_id:o.symbolId,leaf:l,consumer_files:c})}let s={},a={};for(let[o,l]of r){let u=v(o);if(u){let f=N.get(e,o,()=>A(e,o,u));s[o]={imported_leaves:[...f.importedLeaves],used_leaves:[...f.usedLeaves]}}let c=ae(e,o,l);c.length>0&&(a[o]=c)}return{definitions:i,file_usages:s,reexport_only_leaves:a}}function ae(e,n,t){if(t.size===0)return[];let r=p(e).forFile(n,{lines:!0,reexports:!0}),i=r.lines??[],s=r.reexports??[];return i.length===0||s.length===0?[]:[...t].filter(a=>P(i,s,a))}function le(e,n){if(!Array.isArray(e.entries)||e.entries.length!==n.length)return null;let t=new Set(n.map(i=>i.symbolId)),r=new Map;for(let i of e.entries){let s=ue(i);if(!s||!t.has(s.symbol_id))return null;r.set(s.symbol_id,{partition:{realConsumers:s.real_consumers,barrelConsumers:s.barrel_consumers,importOnlyConsumers:s.import_only_consumers},files:s.files})}for(let i of t)if(!r.has(i))return null;return r}function ue(e){if(!e||typeof e!="object")return null;let n=e;if(typeof n.symbol_id!="number"||!Array.isArray(n.real_consumers)||typeof n.barrel_consumers!="number"||typeof n.import_only_consumers!="number"||!Array.isArray(n.files)||!n.real_consumers.every(r=>typeof r=="string"))return null;let t=[];for(let r of n.files){if(!r||typeof r!="object")return null;let i=r;if(typeof i.file!="string"||!Array.isArray(i.sources)||!i.sources.every(ce)||!fe(i.classification))return null;t.push({file:i.file,sources:i.sources,classification:i.classification})}return{symbol_id:n.symbol_id,real_consumers:n.real_consumers,barrel_consumers:n.barrel_consumers,import_only_consumers:n.import_only_consumers,files:t}}function ce(e){return e==="indexed"||e==="semantic"||e==="source-fallback"}function fe(e){return e==="real"||e==="reexport-only"||e==="import-only"}function me(){let e=process.env[ie];if(!e)return R;let n=Number(e);return Number.isFinite(n)&&n>=0?n:R}function de(){if(C!==void 0)return C;let e=process.env[ne],n=process.platform==="win32"?"scip-query-kernels.exe":"scip-query-kernels";return C=[...e?[e]:[],...pe().map(r=>T(r,"target","release",n))].find(r=>k(r))??null,C}function pe(){let e=new Set,n=L(j(import.meta.url));for(let t=0;t<5;t++)e.add(n),n=L(n);return[...e]}export{Me as a,Re as b,Ne as c,J as d};
2
+ //# sourceMappingURL=chunk-ZOXKSQQB.js.map
@@ -1,2 +1,2 @@
1
- import{a as g}from"./chunk-35NLDRZC.js";import{c as d}from"./chunk-HEOMG7IM.js";import{b as u}from"./chunk-35IW3P4H.js";import{b as f}from"./chunk-7COHFNJK.js";function w(n,e={}){return C(n,e).cycles}function C(n,e={}){return b(n,e)}function W(n,e={}){return b(n,e).cycles}function b(n,e={}){let{scope:t,maxDepth:o=10,edgeBasis:r="symbol-references"}=e,s=f(n,t,r==="imports"?{scipEdges:"imports-only",sourceEdges:"imports-only"}:void 0),{components:a}=g(s),l=a.filter(i=>D(s,i)).map(i=>{let c=[...i].sort(),p=S(s,c),y=x(p);return{path:p,component:c,edgeBasis:r,witness:!0,classification:y==="real"?"dependency-cycle":"module-structure-candidate",kind:y}});return l.sort((i,c)=>i.kind!==c.kind?i.kind==="real"?-1:1:i.path.length-c.path.length),{cycles:l,truncated:!1,edgeBasis:r,maxDepth:o}}function D(n,e){if(e.length>1)return!0;let t=e[0];return t!==void 0&&n.get(t)?.has(t)===!0}function S(n,e){let t=e[0];if(!t)return[];let o=new Set(e);for(let r of[...n.get(t)??[]].filter(s=>o.has(s)).sort()){if(r===t)return[t,t];let s=B(n,r,t,o);if(s)return[t,...s]}throw new Error(`Cyclic component did not contain a witness path from ${t}.`)}function B(n,e,t,o){let r=[e],s=new Map([[e,null]]);for(let a=0;a<r.length;a+=1){let l=r[a];if(l===t){let i=[];for(let c=l;c!==null;c=s.get(c)??null)i.push(c);return i.reverse()}for(let i of[...n.get(l)??[]].filter(c=>o.has(c)).sort())s.has(i)||(s.set(i,l),r.push(i))}return null}function x(n){for(let o of n){let r=u(o);if(r==="test"||r==="barrel"||r==="entry")return"module-hierarchy"}if(n.length!==3)return"real";let[e,t]=n;return!e||!t?"real":d(e)||d(t)||m(e,t)||m(t,e)||h(e,t)||h(t,e)||u(e)==="entry"||u(t)==="entry"?"module-hierarchy":"real"}function m(n,e){if(!n.endsWith(".rs")||!e.endsWith(".rs"))return!1;let t=e.replace(/\.rs$/,"/");return n.startsWith(t)?!n.slice(t.length).includes("/"):!1}function h(n,e){if(!n.endsWith(".rs")||!e.endsWith(".rs"))return!1;let t=n.replace(/\.rs$/,""),o=e.replace(/\.rs$/,"");if(t===o+"_tests"||t===o+"/tests")return!0;let r=n.split("/"),s=e.split("/");if(r.length===s.length&&r.includes("tests")&&s.includes("src")){let a=r[r.length-1],l=s[s.length-1];if(a&&a===l)return!0}return!1}export{w as a,C as b,W as c,b as d};
2
- //# sourceMappingURL=chunk-BD6CV7PN.js.map
1
+ import{a as g}from"./chunk-35NLDRZC.js";import{c as d}from"./chunk-BECZLYNU.js";import{b as u}from"./chunk-Q6T2CAJL.js";import{b as f}from"./chunk-4GAQ6FI4.js";function w(n,e={}){return C(n,e).cycles}function C(n,e={}){return b(n,e)}function W(n,e={}){return b(n,e).cycles}function b(n,e={}){let{scope:t,maxDepth:o=10,edgeBasis:r="symbol-references"}=e,s=f(n,t,r==="imports"?{scipEdges:"imports-only",sourceEdges:"imports-only"}:void 0),{components:a}=g(s),l=a.filter(i=>D(s,i)).map(i=>{let c=[...i].sort(),p=S(s,c),y=x(p);return{path:p,component:c,edgeBasis:r,witness:!0,classification:y==="real"?"dependency-cycle":"module-structure-candidate",kind:y}});return l.sort((i,c)=>i.kind!==c.kind?i.kind==="real"?-1:1:i.path.length-c.path.length),{cycles:l,truncated:!1,edgeBasis:r,maxDepth:o}}function D(n,e){if(e.length>1)return!0;let t=e[0];return t!==void 0&&n.get(t)?.has(t)===!0}function S(n,e){let t=e[0];if(!t)return[];let o=new Set(e);for(let r of[...n.get(t)??[]].filter(s=>o.has(s)).sort()){if(r===t)return[t,t];let s=B(n,r,t,o);if(s)return[t,...s]}throw new Error(`Cyclic component did not contain a witness path from ${t}.`)}function B(n,e,t,o){let r=[e],s=new Map([[e,null]]);for(let a=0;a<r.length;a+=1){let l=r[a];if(l===t){let i=[];for(let c=l;c!==null;c=s.get(c)??null)i.push(c);return i.reverse()}for(let i of[...n.get(l)??[]].filter(c=>o.has(c)).sort())s.has(i)||(s.set(i,l),r.push(i))}return null}function x(n){for(let o of n){let r=u(o);if(r==="test"||r==="barrel"||r==="entry")return"module-hierarchy"}if(n.length!==3)return"real";let[e,t]=n;return!e||!t?"real":d(e)||d(t)||m(e,t)||m(t,e)||h(e,t)||h(t,e)||u(e)==="entry"||u(t)==="entry"?"module-hierarchy":"real"}function m(n,e){if(!n.endsWith(".rs")||!e.endsWith(".rs"))return!1;let t=e.replace(/\.rs$/,"/");return n.startsWith(t)?!n.slice(t.length).includes("/"):!1}function h(n,e){if(!n.endsWith(".rs")||!e.endsWith(".rs"))return!1;let t=n.replace(/\.rs$/,""),o=e.replace(/\.rs$/,"");if(t===o+"_tests"||t===o+"/tests")return!0;let r=n.split("/"),s=e.split("/");if(r.length===s.length&&r.includes("tests")&&s.includes("src")){let a=r[r.length-1],l=s[s.length-1];if(a&&a===l)return!0}return!1}export{w as a,C as b,W as c,b as d};
2
+ //# sourceMappingURL=chunk-ZPASRBLF.js.map
@@ -1,2 +1,2 @@
1
- import{a as P,b as y}from"./chunk-5SE323LF.js";import{a as C,c as b,e as r,f}from"./chunk-B3X6KU75.js";import{a as g,b as h,c as k}from"./chunk-KMVGRIO2.js";import{O as v}from"./chunk-AA7K3XLM.js";function L(e,i={}){let{minSimilarity:o=.62,minTokens:n=8,limit:c=20,scope:l,scanLimit:u,filePattern:m,focusFiles:d}=i,s=B(e,{scope:l,minTokens:n,scanLimit:u}),p=P(s,t=>t.tokens);return y({profiles:s,limit:c,filePattern:m,focusFiles:d,candidateIndex:p,profile:{name:"vue-component-duplicates"},compare:(t,a)=>V(t,a,o),sort:(t,a)=>a.similarity-t.similarity||t.fileA.localeCompare(a.fileA)||t.fileB.localeCompare(a.fileB)})}function B(e,i){return v(e).vueProfiles({scope:i.scope,minTemplateTokens:i.minTokens,scanLimit:i.scanLimit}).map(o=>({file:o.file,tokens:o.templateTokens,loc:T(o)}))}function T(e){return e.totalLines}function V(e,i,o){let n=g(e.tokens,i.tokens);if(n.size<6||!R(n))return null;let c=k(e.tokens,i.tokens);if(c<o)return null;let l=r(n,"component:"),u=r(n,"prop:"),m=r(n,"event:"),d=r(n,"directive:"),s=r(n,"slot:"),p=r(n,"id:"),t=S({sharedComponents:l,sharedProps:u,sharedEvents:m,sharedDirectives:d,sharedSlots:s,sharedIdentifiers:p});return{fileA:e.file,fileB:i.file,similarity:c,tokenCountA:e.tokens.size,tokenCountB:i.tokens.size,sharedTokens:f(n),sharedComponents:l,sharedProps:u,sharedEvents:m,sharedDirectives:d,sharedSlots:s,sharedIdentifiers:p,evidenceClass:t.evidenceClass,actionTier:t.actionTier,evidenceClassReasons:t.reasons,recommendation:t.recommendation,uniqueToA:f(h(e.tokens,i.tokens)).slice(0,25),uniqueToB:f(h(i.tokens,e.tokens)).slice(0,25),locA:e.loc,locB:i.loc}}function R(e){let i=0,o=0;for(let n of e)n.startsWith("component:")&&(i+=1),(n.startsWith("prop:")||n.startsWith("event:")||n.startsWith("directive:")||n.startsWith("slot:"))&&(o+=1);return b([{name:"component",count:i},{name:"behavior",count:o}],[{min:{component:1},reason:"shared custom component"},{min:{behavior:3},reason:"shared Vue template structure"}]).pass}function S(e){return C({genericWords:x,primitiveGroups:[{values:e.sharedProps,reasonPrefix:"shared props",bucket:"generic"},{values:e.sharedEvents,reasonPrefix:"shared events",bucket:"generic"},{values:e.sharedDirectives,reasonPrefix:"shared directives",bucket:"generic"},{values:e.sharedSlots,reasonPrefix:"shared slots",bucket:"generic"}],nameGroups:[{names:e.sharedComponents,label:"shared component",fallbackBucket:"generic"},{names:e.sharedIdentifiers,label:"shared identifier",fallbackBucket:"generic"}],recommendation:w})}function w(e){switch(e){case"domain-behavior":case"mixed":return"Review for a shared component or feature-specific Vue primitive around the named domain structure.";case"shared-abstraction":return"Review the existing shared component usage first; extract only if duplicated structure remains outside it.";case"generic-workflow-scaffolding":return"Generic structural overlap \u2014 verify intent before consolidating."}}var x=new Set(["actions","app","button","card","content","container","dialog","field","form","header","input","item","label","layout","list","modal","page","panel","row","section","shell","table","text","toolbar","ui","value","view","wrapper"]);export{L as a};
2
- //# sourceMappingURL=chunk-DMUGTKMD.js.map
1
+ import{a as P,b as y}from"./chunk-FGNCOQUX.js";import{a as C,c as b,e as r,f}from"./chunk-B3X6KU75.js";import{a as g,b as h,c as k}from"./chunk-KMVGRIO2.js";import{P as v}from"./chunk-7JYHQAH2.js";function L(e,i={}){let{minSimilarity:o=.62,minTokens:n=8,limit:c=20,scope:l,scanLimit:u,filePattern:m,focusFiles:d}=i,s=B(e,{scope:l,minTokens:n,scanLimit:u}),p=P(s,t=>t.tokens);return y({profiles:s,limit:c,filePattern:m,focusFiles:d,candidateIndex:p,profile:{name:"vue-component-duplicates"},compare:(t,a)=>V(t,a,o),sort:(t,a)=>a.similarity-t.similarity||t.fileA.localeCompare(a.fileA)||t.fileB.localeCompare(a.fileB)})}function B(e,i){return v(e).vueProfiles({scope:i.scope,minTemplateTokens:i.minTokens,scanLimit:i.scanLimit}).map(o=>({file:o.file,tokens:o.templateTokens,loc:T(o)}))}function T(e){return e.totalLines}function V(e,i,o){let n=g(e.tokens,i.tokens);if(n.size<6||!R(n))return null;let c=k(e.tokens,i.tokens);if(c<o)return null;let l=r(n,"component:"),u=r(n,"prop:"),m=r(n,"event:"),d=r(n,"directive:"),s=r(n,"slot:"),p=r(n,"id:"),t=S({sharedComponents:l,sharedProps:u,sharedEvents:m,sharedDirectives:d,sharedSlots:s,sharedIdentifiers:p});return{fileA:e.file,fileB:i.file,similarity:c,tokenCountA:e.tokens.size,tokenCountB:i.tokens.size,sharedTokens:f(n),sharedComponents:l,sharedProps:u,sharedEvents:m,sharedDirectives:d,sharedSlots:s,sharedIdentifiers:p,evidenceClass:t.evidenceClass,actionTier:t.actionTier,evidenceClassReasons:t.reasons,recommendation:t.recommendation,uniqueToA:f(h(e.tokens,i.tokens)).slice(0,25),uniqueToB:f(h(i.tokens,e.tokens)).slice(0,25),locA:e.loc,locB:i.loc}}function R(e){let i=0,o=0;for(let n of e)n.startsWith("component:")&&(i+=1),(n.startsWith("prop:")||n.startsWith("event:")||n.startsWith("directive:")||n.startsWith("slot:"))&&(o+=1);return b([{name:"component",count:i},{name:"behavior",count:o}],[{min:{component:1},reason:"shared custom component"},{min:{behavior:3},reason:"shared Vue template structure"}]).pass}function S(e){return C({genericWords:x,primitiveGroups:[{values:e.sharedProps,reasonPrefix:"shared props",bucket:"generic"},{values:e.sharedEvents,reasonPrefix:"shared events",bucket:"generic"},{values:e.sharedDirectives,reasonPrefix:"shared directives",bucket:"generic"},{values:e.sharedSlots,reasonPrefix:"shared slots",bucket:"generic"}],nameGroups:[{names:e.sharedComponents,label:"shared component",fallbackBucket:"generic"},{names:e.sharedIdentifiers,label:"shared identifier",fallbackBucket:"generic"}],recommendation:w})}function w(e){switch(e){case"domain-behavior":case"mixed":return"Review for a shared component or feature-specific Vue primitive around the named domain structure.";case"shared-abstraction":return"Review the existing shared component usage first; extract only if duplicated structure remains outside it.";case"generic-workflow-scaffolding":return"Generic structural overlap \u2014 verify intent before consolidating."}}var x=new Set(["actions","app","button","card","content","container","dialog","field","form","header","input","item","label","layout","list","modal","page","panel","row","section","shell","table","text","toolbar","ui","value","view","wrapper"]);export{L as a};
2
+ //# sourceMappingURL=chunk-ZYM4HOFA.js.map
@@ -1,2 +1,2 @@
1
- import{c as P}from"./chunk-JVZNWJBH.js";import{a as C}from"./chunk-6BJ7SOY7.js";import{d as x,g as v,k as T}from"./chunk-63MBA7EG.js";import{o as O}from"./chunk-RGCJ4646.js";import{d as A}from"./chunk-5IZTXSOL.js";import{l as b}from"./chunk-I3U2FN2T.js";import{z as g}from"./chunk-AA7K3XLM.js";function U(e,n={}){let{samples:o=50,scope:r,maxDisagreements:u=5}=n,l=new P(e),a=K(l.productionCallableDefinitions({scope:r,minLoc:2,requireFunctionLikeSymbol:!0}),o),c=z(e,a);if(a.length===0||!c)return{available:!1,sampleSize:a.length,oracleCoverage:0,scores:[],topDisagreements:[]};let t={references:Q(),callees:Q()},i=[],f=0,m=c==="semantic"?T(e,a):new Map,I=c==="source"?_(e,l,a):null;for(let s of a){let p=S(s,c==="semantic"?v(e,s).map(d=>d.file):[...I?.referencesBySymbolId.get(s.symbolId)??[]]),L=S(s,c==="semantic"?(m.get(s.symbolId)??[]).map(d=>d.file):[...I?.calleesBySymbolId.get(s.symbolId)??[]]);f+=1;let k=S(s,O(e,s,{semanticEvidence:C}).map(d=>d.file)),w=S(s,(l.calleeMap([s],{semantic:!1}).get(s.symbolId)??[]).map(d=>d.file)),R=y(c,"references"),B=y(c,"callees");M(t.references,s,"references",k,p,R,i),M(t.callees,s,"callees",w,L,B,i)}return i.sort((s,p)=>p.cheapOnly.length+p.oracleOnly.length-(s.cheapOnly.length+s.oracleOnly.length)),{available:!0,sampleSize:a.length,oracleCoverage:a.length>0?D(f/a.length):0,oracleKind:c,scores:["references","callees"].map(s=>F(s,t[s],c)),topDisagreements:i.slice(0,u)}}function Q(){return{comparedSymbols:0,agreed:0,cheapTotal:0,oracleTotal:0,skippedOraclePartial:0}}function K(e,n){let o=[...e].sort((l,a)=>l.symbolId-a.symbolId);if(o.length<=n)return o;let r=o.length/n,u=[];for(let l=0;l<n;l++)u.push(o[Math.floor(l*r)]);return u}function z(e,n){let o=n[0];if(!o)return null;if(h(e,o))return"source";try{if(x(e).capability("semantic-references",o.relativePath).available)return"semantic"}catch{}return n.some(r=>h(e,r))?"source":null}function S(e,n){let o=new Set;for(let r of n)r!==e.relativePath&&o.add(r);return o}function M(e,n,o,r,u,l,a){if(!l&&u.size===0){e.skippedOraclePartial+=1;return}e.comparedSymbols+=1,e.cheapTotal+=r.size,e.oracleTotal+=u.size;let c=[],t=[];for(let i of r)u.has(i)?e.agreed+=1:c.push(i);for(let i of u)r.has(i)||t.push(i);(c.length>0||t.length>0)&&a.push({symbol:A(n.symbol),question:o,cheapOnly:c,oracleOnly:t})}var E={references:!0,callees:!1};function F(e,n,o){let r=n.oracleTotal>0?n.agreed/n.oracleTotal:1,u=n.cheapTotal-n.agreed,l=y(o,e);return{question:e,comparedSymbols:n.comparedSymbols,precision:l&&n.cheapTotal>0?D(n.agreed/n.cheapTotal):null,recall:D(r),unverified:u,skippedOraclePartial:n.skippedOraclePartial}}function y(e,n){return e==="semantic"?E[n]:!1}function h(e,n){return g(n.relativePath)==="clojure"&&b(e,n.relativePath)!==null}function _(e,n,o){let r=new Map,u=new Map,l=o.filter(t=>h(e,t)),a=new Map;for(let t of l){let i=a.get(t.leaf)??[];i.push(t),a.set(t.leaf,i)}for(let t of n.sourceFiles()){if(g(t)!=="clojure")continue;let i=b(e,t);if(i)for(let f of i.fileIdentifiers)for(let m of a.get(f)??[])j(r,m.symbolId,t)}let c=new Map;for(let t of n.scopedDefinitions()){if(g(t.relativePath)!=="clojure")continue;let i=c.get(t.leaf)??[];i.push(t),c.set(t.leaf,i)}for(let t of l){let i=b(e,t.relativePath);if(i){for(let f of i.callSites)if(!(f.line<t.startLine||f.line>t.endLine))for(let m of c.get(f.calleeLeaf)??[])j(u,t.symbolId,m.relativePath)}}return{referencesBySymbolId:r,calleesBySymbolId:u}}function j(e,n,o){let r=e.get(n);if(r){r.add(o);return}e.set(n,new Set([o]))}function D(e){return Math.round(e*1e3)/1e3}export{U as a};
2
- //# sourceMappingURL=chunk-4ILHWBYF.js.map
1
+ import{c as P}from"./chunk-PLYUVM4F.js";import{a as C}from"./chunk-Z2AWCTN6.js";import{d as x,g as v,k as T}from"./chunk-PBUH2P5S.js";import{o as O}from"./chunk-AYPDH2LU.js";import{d as A}from"./chunk-TD7VKJ2Y.js";import{m as b}from"./chunk-42W3LFUK.js";import{z as g}from"./chunk-7JYHQAH2.js";function U(e,n={}){let{samples:o=50,scope:r,maxDisagreements:u=5}=n,l=new P(e),a=K(l.productionCallableDefinitions({scope:r,minLoc:2,requireFunctionLikeSymbol:!0}),o),c=z(e,a);if(a.length===0||!c)return{available:!1,sampleSize:a.length,oracleCoverage:0,scores:[],topDisagreements:[]};let t={references:Q(),callees:Q()},i=[],f=0,m=c==="semantic"?T(e,a):new Map,I=c==="source"?_(e,l,a):null;for(let s of a){let p=S(s,c==="semantic"?v(e,s).map(d=>d.file):[...I?.referencesBySymbolId.get(s.symbolId)??[]]),L=S(s,c==="semantic"?(m.get(s.symbolId)??[]).map(d=>d.file):[...I?.calleesBySymbolId.get(s.symbolId)??[]]);f+=1;let k=S(s,O(e,s,{semanticEvidence:C}).map(d=>d.file)),w=S(s,(l.calleeMap([s],{semantic:!1}).get(s.symbolId)??[]).map(d=>d.file)),R=y(c,"references"),B=y(c,"callees");M(t.references,s,"references",k,p,R,i),M(t.callees,s,"callees",w,L,B,i)}return i.sort((s,p)=>p.cheapOnly.length+p.oracleOnly.length-(s.cheapOnly.length+s.oracleOnly.length)),{available:!0,sampleSize:a.length,oracleCoverage:a.length>0?D(f/a.length):0,oracleKind:c,scores:["references","callees"].map(s=>F(s,t[s],c)),topDisagreements:i.slice(0,u)}}function Q(){return{comparedSymbols:0,agreed:0,cheapTotal:0,oracleTotal:0,skippedOraclePartial:0}}function K(e,n){let o=[...e].sort((l,a)=>l.symbolId-a.symbolId);if(o.length<=n)return o;let r=o.length/n,u=[];for(let l=0;l<n;l++)u.push(o[Math.floor(l*r)]);return u}function z(e,n){let o=n[0];if(!o)return null;if(h(e,o))return"source";try{if(x(e).capability("semantic-references",o.relativePath).available)return"semantic"}catch{}return n.some(r=>h(e,r))?"source":null}function S(e,n){let o=new Set;for(let r of n)r!==e.relativePath&&o.add(r);return o}function M(e,n,o,r,u,l,a){if(!l&&u.size===0){e.skippedOraclePartial+=1;return}e.comparedSymbols+=1,e.cheapTotal+=r.size,e.oracleTotal+=u.size;let c=[],t=[];for(let i of r)u.has(i)?e.agreed+=1:c.push(i);for(let i of u)r.has(i)||t.push(i);(c.length>0||t.length>0)&&a.push({symbol:A(n.symbol),question:o,cheapOnly:c,oracleOnly:t})}var E={references:!0,callees:!1};function F(e,n,o){let r=n.oracleTotal>0?n.agreed/n.oracleTotal:1,u=n.cheapTotal-n.agreed,l=y(o,e);return{question:e,comparedSymbols:n.comparedSymbols,precision:l&&n.cheapTotal>0?D(n.agreed/n.cheapTotal):null,recall:D(r),unverified:u,skippedOraclePartial:n.skippedOraclePartial}}function y(e,n){return e==="semantic"?E[n]:!1}function h(e,n){return g(n.relativePath)==="clojure"&&b(e,n.relativePath)!==null}function _(e,n,o){let r=new Map,u=new Map,l=o.filter(t=>h(e,t)),a=new Map;for(let t of l){let i=a.get(t.leaf)??[];i.push(t),a.set(t.leaf,i)}for(let t of n.sourceFiles()){if(g(t)!=="clojure")continue;let i=b(e,t);if(i)for(let f of i.fileIdentifiers)for(let m of a.get(f)??[])j(r,m.symbolId,t)}let c=new Map;for(let t of n.scopedDefinitions()){if(g(t.relativePath)!=="clojure")continue;let i=c.get(t.leaf)??[];i.push(t),c.set(t.leaf,i)}for(let t of l){let i=b(e,t.relativePath);if(i){for(let f of i.callSites)if(!(f.line<t.startLine||f.line>t.endLine))for(let m of c.get(f.calleeLeaf)??[])j(u,t.symbolId,m.relativePath)}}return{referencesBySymbolId:r,calleesBySymbolId:u}}function j(e,n,o){let r=e.get(n);if(r){r.add(o);return}e.set(n,new Set([o]))}function D(e){return Math.round(e*1e3)/1e3}export{U as a};
2
+ //# sourceMappingURL=chunk-ZZ3Z7D56.js.map
package/dist/cli-main.js CHANGED
@@ -1,8 +1,8 @@
1
1
  #!/usr/bin/env node
2
- import{c as pe,d as le,e as v,f as fe,i as he,l,n as P}from"./chunk-6T7H2AFY.js";import{a as re,b as oe,d as ie}from"./chunk-OVPS2ILI.js";import{c as ae,d as se,e as ce,f as me,g as de,h as ue}from"./chunk-COTMS5KM.js";import{$b as $e,Bb as X,Cb as K,Db as Z,Fb as ee,Nb as S,Ob as te,Qb as ne,lb as C,mb as B,wb as Y,xb as y,zb as Q}from"./chunk-4UUCUASK.js";import{Aa as H,B as _,Cd as J,Ma as m,Sa as R,V as T,W as $,ea as W,fa as M,ga as G,ha as F,ia as q,ra as U,rd as z,sa as b,va as L,xa as V}from"./chunk-OIVZ7PW6.js";import{Help as bt,program as d}from"commander";import{existsSync as Rt,realpathSync as _e}from"fs";import{fileURLToPath as St}from"url";var We=new Set(["code","outline","refs"]),Me=["--symbol","--at","--search","--view","--edge","--direction","--subtype","--connecting","--inventory-only","--fold","--depth","--max-edges"];function ge(e){if(e[2]!=="evidence")return;let n=e[3];if(!n||n.startsWith("-"))return;if(e.slice(4).some(o=>Me.some(r=>o===r||o.startsWith(`${r}=`)))){e.splice(3,1,"--symbol",n);return}e[2]="evidence-source"}function Ge(e){return e!==void 0&&We.has(e)}async function Ce(e){if(e==="continue"){let{outputContinuationCommandDescriptor:t}=await import("./output-continuation-command-LKBUTNRL.js");return[t]}if(Ge(e)){let{directNavigationQueryCommandDescriptors:t}=await import("./direct-navigation-6RUJKLAV.js"),i=t.find(o=>o.id===e);if(!i)throw new Error(`Direct navigation command descriptor is unavailable: ${e}`);return[i]}let{commandDescriptors:n}=await import("./command-descriptors-QH3G2OVD.js");return n}import{Option as Ue}from"commander";function O(e){return e.evidence?e.evidence:Fe.has(e.id)?"mixed":e.heuristic?"heuristic":"graph-fact"}var Fe=new Set(["health","context","co-change"]);function ye(e){if(e.claims){if(e.claims.origin==="mixed"&&!e.claims.families?.length)throw new Error(`Mixed command ${e.id} must declare at least one claim family.`);return e.claims}let n=O(e);if(n==="mixed")throw new Error(`Mixed command ${e.id} must declare claim families.`);let t=e.agent?se(e.agent.operation):[];return t.length>0&&t.every(o=>o==="repository-observation"||o==="repository-preview")?{origin:n==="heuristic"?"heuristic":"compiler-graph",observedSources:["index-generation"],producerValidation:{status:"not-evaluated"}}:{origin:"unknown",observedSources:["process"],producerValidation:{status:"not-evaluated"}}}import{basename as qe}from"path";function ve(e=process.argv,n=process.execPath){let t=e[1];return!t||qe(t)==="scip-query"?["scip-query"]:[n,t]}function Ee(e,n){return me(new Map(n.map(t=>[t.id,O(t)]))),ue(new Map(n.map(t=>[t.id,ye(t)]))),de(new Map(n.flatMap(t=>t.agent?[[t.id,{...t.agent,resultUnits:Ve(t)}]]:[]))),n.map(t=>{let i=t.hidden?e.command(t.command,{hidden:!0}):e.command(t.command);i.description(t.description),t.helpAfter&&i.addHelpText("after",`
2
+ import{i as pe,j as le,k as v,m as fe,q as he,w as l,y as j}from"./chunk-A77SCPW2.js";import{a as re,b as oe,d as ie}from"./chunk-Q5TA4OY4.js";import{c as ae,d as se,e as ce,f as me,g as de,h as ue}from"./chunk-CKRWA452.js";import{Ab as y,Cb as Q,Eb as X,Fb as K,Gb as Z,Hb as ee,Qb as P,Rb as te,Tb as ne,dc as $e,ob as C,pb as Y,zb as S}from"./chunk-V4NG5OMS.js";import{A as b,D as M,F as G,Hd as J,I as F,Va as q,Zd as B,_ as m,ea as R,ib as U,jb as L,kb as V,lb as H,mb as z,t as _,u as $,z as W}from"./chunk-2BTJALUS.js";import{Help as bt,program as d}from"commander";import{existsSync as Rt,realpathSync as Te}from"fs";import{fileURLToPath as St}from"url";var We=new Set(["code","outline","refs"]),Me=["--symbol","--at","--search","--view","--edge","--direction","--subtype","--connecting","--inventory-only","--fold","--depth","--max-edges"];function ge(e){if(e[2]!=="evidence")return;let n=e[3];if(!n||n.startsWith("-"))return;if(e.slice(4).some(o=>Me.some(r=>o===r||o.startsWith(`${r}=`)))){e.splice(3,1,"--symbol",n);return}e[2]="evidence-source"}function Ge(e){return e!==void 0&&We.has(e)}async function Ce(e){if(e==="continue"){let{outputContinuationCommandDescriptor:t}=await import("./output-continuation-command-JHMPH6NC.js");return[t]}if(Ge(e)){let{directNavigationQueryCommandDescriptors:t}=await import("./direct-navigation-O3LUAYWQ.js"),i=t.find(o=>o.id===e);if(!i)throw new Error(`Direct navigation command descriptor is unavailable: ${e}`);return[i]}let{commandDescriptors:n}=await import("./command-descriptors-ORNTVNYV.js");return n}import{Option as Ue}from"commander";function D(e){return e.evidence?e.evidence:Fe.has(e.id)?"mixed":e.heuristic?"heuristic":"graph-fact"}var Fe=new Set(["health","context","co-change"]);function ye(e){if(e.claims){if(e.claims.origin==="mixed"&&!e.claims.families?.length)throw new Error(`Mixed command ${e.id} must declare at least one claim family.`);return e.claims}let n=D(e);if(n==="mixed")throw new Error(`Mixed command ${e.id} must declare claim families.`);let t=e.agent?se(e.agent.operation):[];return t.length>0&&t.every(o=>o==="repository-observation"||o==="repository-preview")?{origin:n==="heuristic"?"heuristic":"compiler-graph",observedSources:["index-generation"],producerValidation:{status:"not-evaluated"}}:{origin:"unknown",observedSources:["process"],producerValidation:{status:"not-evaluated"}}}import{basename as qe}from"path";function ve(e=process.argv,n=process.execPath){let t=e[1];return!t||qe(t)==="scip-query"?["scip-query"]:[n,t]}function Ee(e,n){return me(new Map(n.map(t=>[t.id,D(t)]))),ue(new Map(n.map(t=>[t.id,ye(t)]))),de(new Map(n.flatMap(t=>t.agent?[[t.id,{...t.agent,resultUnits:Ve(t)}]]:[]))),n.map(t=>{let i=t.hidden?e.command(t.command,{hidden:!0}):e.command(t.command);i.description(t.description),t.helpAfter&&i.addHelpText("after",`
3
3
  ${t.helpAfter.trim()}
4
- `);for(let o of t.arguments??[])i.argument(o.name);for(let o of t.options??[])if(o.hidden){let r=new Ue(o.flags,o.description).hideHelp();o.parser&&r.argParser(o.parser),Object.hasOwn(o,"defaultValue")&&r.default(o.defaultValue),i.addOption(r)}else o.parser&&Object.hasOwn(o,"defaultValue")?i.option(o.flags,o.description,o.parser,o.defaultValue):o.parser?i.option(o.flags,o.description,o.parser):Object.hasOwn(o,"defaultValue")?i.option(o.flags,o.description,o.defaultValue):i.option(o.flags,o.description);return i.action(async(...o)=>{try{let r=i.optsWithGlobals();Le(r);let a=()=>t.id===re?t.handler(...o):oe({command:t.id,producerVersion:m,invocationPrefix:ve(),argv:process.argv.slice(2),cwd:process.cwd(),json:r.json===!0,agentOutput:r.agentOutput===!0,...typeof r.jsonOutput=="string"?{jsonOutputPath:r.jsonOutput}:{},sourceSession:r.session!==!1,reemitSource:r.reemit===!0,...typeof r.outputPageSize=="number"?{pageSize:r.outputPageSize}:{},...typeof r.outputCursor=="string"?{cursor:r.outputCursor}:{}},()=>t.handler(...o)),c=t.agent?ae(t.agent.operation,{args:o.slice(0,-1),options:r}):void 0;await(c?ce(c,a):a())}catch(r){He(r)}}),{descriptor:t,command:i}})}function Le(e){if(e.resultOnly===!0&&e.json!==!0)throw new Error("--result-only requires --json.");if(e.compact===!0&&e.json!==!0)throw new Error("--compact requires --json.");if(e.agentOutput===!0&&e.json!==!0)throw new Error("--agent-output requires --json.");if(typeof e.jsonOutput=="string"&&e.json!==!0)throw new Error("--json-output requires --json.");if(e.rawJson===!0&&e.json!==!0)throw new Error("--raw-json requires --json.");if(e.agentOutput===!0&&e.rawJson===!0)throw new Error("--agent-output cannot be combined with --raw-json.");if(typeof e.jsonOutput=="string"){if(e.agentOutput===!0||e.rawJson===!0)throw new Error("--json-output cannot be combined with --agent-output or --raw-json.");if(e.outputPageSize!==void 0||e.outputCursor!==void 0)throw new Error("--json-output cannot be combined with output pagination.")}if(e.rawJson===!0&&(e.outputPageSize!==void 0||e.outputCursor!==void 0))throw new Error("--raw-json cannot be combined with output pagination.")}function Ve(e){let n=e.agent?.resultUnits;if(n?.kind==="field"&&n.field.trim()==="")throw new Error(`Command ${e.id} declares an empty result-unit field.`);return n||(e.renderShape==="list"||e.renderShape==="table"||e.renderShape==="grouped-by-file"?{kind:"rows"}:{kind:"report"})}function He(e){let n=e instanceof Error?e.message:String(e);console.error(`error: ${te(n)}`),process.exitCode=1}var ze=new Set(P),xe=new Map(P.map((e,n)=>[e,n])),Je=new Set(["Navigation","Graph","Impact","Exploration"]),Be=new Set(["Cleanup","Health"]),Ye=new Set(["Indexing","Core","Maintenance"]);function Qe(e){if(e.hidden||e.agent?.semantic?.compatibility==="deprecated")return"compatibility";if(ze.has(e.id))return"primary-exploration";let n=e.docs?.category;if(n&&Je.has(n))return"specialized-analysis";if(n&&Be.has(n))return"quality-cleanup";if(n&&Ye.has(n))return"maintenance";if(n==="Formal Models")return"formal-modeling";throw new Error(`Visible command ${e.id} has no cockpit panel (docs category: ${n??"missing"}).`)}function Xe(e,n={}){let i=[{id:"primary-exploration",title:"Primary exploration",purpose:"Locate exact referents, project chosen relationships, and read only named implementation gaps."},{id:"specialized-analysis",title:"Specialized analysis",purpose:"Run a named graph, impact, or structural analysis when that exact analysis answers the task."},{id:"quality-cleanup",title:"Quality and cleanup",purpose:"Evaluate repository quality, cleanup candidates, and configured architecture findings."},{id:"maintenance",title:"Maintenance",purpose:"Build, inspect, configure, and maintain the project index and local integrations."},{id:"formal-modeling",title:"Formal modeling",purpose:"Create, verify, and check explicit state-machine models and traces."},{id:"compatibility",title:"Compatibility and deprecated controls",purpose:"Preserved invocation surfaces for existing consumers; do not choose these for new workflows."}].map(r=>({...r,commands:e.filter(a=>Qe(a)===r.id).sort((a,c)=>r.id==="primary-exploration"?(xe.get(a.id)??Number.MAX_SAFE_INTEGER)-(xe.get(c.id)??Number.MAX_SAFE_INTEGER):0)})),o=new Set(["primary-exploration","maintenance"]);return i.filter(r=>r.commands.length>0&&(n.includeCompatibility||o.has(r.id)))}function D(e,n,t={}){let i=[`Usage: ${e.name()} [options] [command]`,"",e.description(),"","Options:"],o=e.options.map(a=>a.flags),r=Math.max(...o.map(a=>a.length),0);for(let a of e.options)i.push(` ${a.flags.padEnd(r)} ${a.description}`);i.push(` ${"-h, --help".padEnd(r)} Display this grouped command help`);for(let a of Xe(n,t)){i.push("",`${a.title}:`,` ${a.purpose}`);let c=Math.max(...a.commands.map(s=>s.command.length),0);for(let s of a.commands)i.push(` ${s.command.padEnd(c)} ${s.description}`)}return t.includeCompatibility||i.push("","Run `scip-query --help-all` to include advanced, compatibility, and deprecated controls."),i.push("Run `scip-query <command> --help` for one control's options and examples.",""),i.join(`
5
- `)}import{createHash as Ke}from"crypto";import{lstatSync as Ze}from"fs";import{isAbsolute as et,join as Pe}from"path";var Oe="git-worktree-context.json",we=16*1024,be=/^[0-9a-f]{40,64}$/,Re=/^[0-9a-f]{24}$/,Se=/^[0-9a-f]{64}$/;function De(e,n,t=b){let i=t!==b||H(),o=i?tt(e,n):void 0;if(o){let a=V(e,o,t);if(a)return a}let r=L(e,t);if(r&&i)try{nt(e,n,r.context,o)}catch{}return r}function tt(e,n){try{let t=R(e,n),i=Pe(t.physicalCacheDir,Oe),o=Ze(i);if(!o.isFile()||o.isSymbolicLink()||o.size>we)return;let r=JSON.parse(T(i,{inputKind:"Git worktree context receipt",maxBytes:we}));return!rt(r)||r.requestedProjectRoot!==t.record.canonicalProjectRoot||r.cacheOwnerSha256!==t.ownerSha256||r.checksum!==je(r)?void 0:r}catch{return}}function nt(e,n,t,i){if(!t.headCommit||!t.treeOid)return;let o=R(e,n),r={version:1,requestedProjectRoot:o.record.canonicalProjectRoot,cacheOwnerSha256:o.ownerSha256,projectRoot:t.projectRoot,gitDir:t.gitDir,commonDir:t.commonDir,repositoryId:t.repositoryId,worktreeId:t.worktreeId,headCommit:t.headCommit,treeOid:t.treeOid},a={...r,checksum:je(r)};i?.checksum!==a.checksum&&z(Pe(o.physicalCacheDir,Oe),a,{spacing:2,trailingNewline:!0})}function rt(e){return ot(e)?e.version===1&&E(e.requestedProjectRoot)&&p(Se,e.cacheOwnerSha256)&&E(e.projectRoot)&&E(e.gitDir)&&E(e.commonDir)&&p(Re,e.repositoryId)&&p(Re,e.worktreeId)&&p(be,e.headCommit)&&p(be,e.treeOid)&&p(Se,e.checksum):!1}function ot(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function E(e){return typeof e=="string"&&et(e)}function je(e){return Ke("sha256").update(JSON.stringify({version:e.version,requestedProjectRoot:e.requestedProjectRoot,cacheOwnerSha256:e.cacheOwnerSha256,projectRoot:e.projectRoot,gitDir:e.gitDir,commonDir:e.commonDir,repositoryId:e.repositoryId,worktreeId:e.worktreeId,headCommit:e.headCommit,treeOid:e.treeOid})).digest("hex")}function p(e,n){return typeof n=="string"&&e.test(n)}import{existsSync as it,mkdirSync as at,writeFileSync as st}from"fs";import{homedir as ct}from"os";import{join as x}from"path";var mt=1440*60*1e3,Ae="update-check.json",dt="https://registry.npmjs.org/scip-query/latest";async function j(e={}){let n=e.env??process.env;if(n.SCIP_QUERY_UPDATE_CHECK==="0"||n.NO_UPDATE_NOTIFIER)return;let t=e.cacheDir??lt(n),i=e.now??Date.now(),o=e.currentVersion??m,r=ft(t),a=r&&i-r.checkedAt<mt?r.latestVersion:await ht(t,e.fetchLatestVersion??Ct,i);if(!a||!pt(a,o))return;(e.writeNotice??(s=>console.error(s)))(ut(o,a))}function ut(e,n){return[`scip-query update available: ${e} -> ${n}.`,"Agent: tell your human to update with: npm install -g scip-query@latest",""].join(`
4
+ `);for(let o of t.arguments??[])i.argument(o.name);for(let o of t.options??[])if(o.hidden){let r=new Ue(o.flags,o.description).hideHelp();o.parser&&r.argParser(o.parser),Object.hasOwn(o,"defaultValue")&&r.default(o.defaultValue),i.addOption(r)}else o.parser&&Object.hasOwn(o,"defaultValue")?i.option(o.flags,o.description,o.parser,o.defaultValue):o.parser?i.option(o.flags,o.description,o.parser):Object.hasOwn(o,"defaultValue")?i.option(o.flags,o.description,o.defaultValue):i.option(o.flags,o.description);return i.action(async(...o)=>{try{let r=i.optsWithGlobals();Le(r);let a=()=>t.id===re?t.handler(...o):oe({command:t.id,producerVersion:m,invocationPrefix:ve(),argv:process.argv.slice(2),cwd:process.cwd(),json:r.json===!0,agentOutput:r.agentOutput===!0,...typeof r.jsonOutput=="string"?{jsonOutputPath:r.jsonOutput}:{},sourceSession:r.session!==!1,reemitSource:r.reemit===!0,...typeof r.outputPageSize=="number"?{pageSize:r.outputPageSize}:{},...typeof r.outputCursor=="string"?{cursor:r.outputCursor}:{}},()=>t.handler(...o)),c=t.agent?ae(t.agent.operation,{args:o.slice(0,-1),options:r}):void 0;await(c?ce(c,a):a())}catch(r){He(r)}}),{descriptor:t,command:i}})}function Le(e){if(e.resultOnly===!0&&e.json!==!0)throw new Error("--result-only requires --json.");if(e.compact===!0&&e.json!==!0)throw new Error("--compact requires --json.");if(e.agentOutput===!0&&e.json!==!0)throw new Error("--agent-output requires --json.");if(typeof e.jsonOutput=="string"&&e.json!==!0)throw new Error("--json-output requires --json.");if(e.rawJson===!0&&e.json!==!0)throw new Error("--raw-json requires --json.");if(e.agentOutput===!0&&e.rawJson===!0)throw new Error("--agent-output cannot be combined with --raw-json.");if(typeof e.jsonOutput=="string"){if(e.agentOutput===!0||e.rawJson===!0)throw new Error("--json-output cannot be combined with --agent-output or --raw-json.");if(e.outputPageSize!==void 0||e.outputCursor!==void 0)throw new Error("--json-output cannot be combined with output pagination.")}if(e.rawJson===!0&&(e.outputPageSize!==void 0||e.outputCursor!==void 0))throw new Error("--raw-json cannot be combined with output pagination.")}function Ve(e){let n=e.agent?.resultUnits;if(n?.kind==="field"&&n.field.trim()==="")throw new Error(`Command ${e.id} declares an empty result-unit field.`);return n||(e.renderShape==="list"||e.renderShape==="table"||e.renderShape==="grouped-by-file"?{kind:"rows"}:{kind:"report"})}function He(e){let n=e instanceof Error?e.message:String(e);console.error(`error: ${te(n)}`),process.exitCode=1}var ze=new Set(j),xe=new Map(j.map((e,n)=>[e,n])),Je=new Set(["Navigation","Graph","Impact","Exploration"]),Be=new Set(["Cleanup","Health"]),Ye=new Set(["Indexing","Core","Maintenance"]);function Qe(e){if(e.hidden||e.agent?.semantic?.compatibility==="deprecated")return"compatibility";if(ze.has(e.id))return"primary-exploration";let n=e.docs?.category;if(n&&Je.has(n))return"specialized-analysis";if(n&&Be.has(n))return"quality-cleanup";if(n&&Ye.has(n))return"maintenance";if(n==="Formal Models")return"formal-modeling";throw new Error(`Visible command ${e.id} has no cockpit panel (docs category: ${n??"missing"}).`)}function Xe(e,n={}){let i=[{id:"primary-exploration",title:"Primary exploration",purpose:"Locate exact referents, project chosen relationships, and read only named implementation gaps."},{id:"specialized-analysis",title:"Specialized analysis",purpose:"Run a named graph, impact, or structural analysis when that exact analysis answers the task."},{id:"quality-cleanup",title:"Quality and cleanup",purpose:"Evaluate repository quality, cleanup candidates, and configured architecture findings."},{id:"maintenance",title:"Maintenance",purpose:"Build, inspect, configure, and maintain the project index and local integrations."},{id:"formal-modeling",title:"Formal modeling",purpose:"Create, verify, and check explicit state-machine models and traces."},{id:"compatibility",title:"Compatibility and deprecated controls",purpose:"Preserved invocation surfaces for existing consumers; do not choose these for new workflows."}].map(r=>({...r,commands:e.filter(a=>Qe(a)===r.id).sort((a,c)=>r.id==="primary-exploration"?(xe.get(a.id)??Number.MAX_SAFE_INTEGER)-(xe.get(c.id)??Number.MAX_SAFE_INTEGER):0)})),o=new Set(["primary-exploration","maintenance"]);return i.filter(r=>r.commands.length>0&&(n.includeCompatibility||o.has(r.id)))}function O(e,n,t={}){let i=[`Usage: ${e.name()} [options] [command]`,"",e.description(),"","Options:"],o=e.options.map(a=>a.flags),r=Math.max(...o.map(a=>a.length),0);for(let a of e.options)i.push(` ${a.flags.padEnd(r)} ${a.description}`);i.push(` ${"-h, --help".padEnd(r)} Display this grouped command help`);for(let a of Xe(n,t)){i.push("",`${a.title}:`,` ${a.purpose}`);let c=Math.max(...a.commands.map(s=>s.command.length),0);for(let s of a.commands)i.push(` ${s.command.padEnd(c)} ${s.description}`)}return t.includeCompatibility||i.push("","Run `scip-query --help-all` to include advanced, compatibility, and deprecated controls."),i.push("Run `scip-query <command> --help` for one control's options and examples.",""),i.join(`
5
+ `)}import{createHash as Ke}from"crypto";import{lstatSync as Ze}from"fs";import{isAbsolute as et,join as Pe}from"path";var je="git-worktree-context.json",we=16*1024,be=/^[0-9a-f]{40,64}$/,Re=/^[0-9a-f]{24}$/,Se=/^[0-9a-f]{64}$/;function De(e,n,t=b){let i=t!==b||F(),o=i?tt(e,n):void 0;if(o){let a=G(e,o,t);if(a)return a}let r=M(e,t);if(r&&i)try{nt(e,n,r.context,o)}catch{}return r}function tt(e,n){try{let t=R(e,n),i=Pe(t.physicalCacheDir,je),o=Ze(i);if(!o.isFile()||o.isSymbolicLink()||o.size>we)return;let r=JSON.parse(_(i,{inputKind:"Git worktree context receipt",maxBytes:we}));return!rt(r)||r.requestedProjectRoot!==t.record.canonicalProjectRoot||r.cacheOwnerSha256!==t.ownerSha256||r.checksum!==Oe(r)?void 0:r}catch{return}}function nt(e,n,t,i){if(!t.headCommit||!t.treeOid)return;let o=R(e,n),r={version:1,requestedProjectRoot:o.record.canonicalProjectRoot,cacheOwnerSha256:o.ownerSha256,projectRoot:t.projectRoot,gitDir:t.gitDir,commonDir:t.commonDir,repositoryId:t.repositoryId,worktreeId:t.worktreeId,headCommit:t.headCommit,treeOid:t.treeOid},a={...r,checksum:Oe(r)};i?.checksum!==a.checksum&&J(Pe(o.physicalCacheDir,je),a,{spacing:2,trailingNewline:!0})}function rt(e){return ot(e)?e.version===1&&E(e.requestedProjectRoot)&&p(Se,e.cacheOwnerSha256)&&E(e.projectRoot)&&E(e.gitDir)&&E(e.commonDir)&&p(Re,e.repositoryId)&&p(Re,e.worktreeId)&&p(be,e.headCommit)&&p(be,e.treeOid)&&p(Se,e.checksum):!1}function ot(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function E(e){return typeof e=="string"&&et(e)}function Oe(e){return Ke("sha256").update(JSON.stringify({version:e.version,requestedProjectRoot:e.requestedProjectRoot,cacheOwnerSha256:e.cacheOwnerSha256,projectRoot:e.projectRoot,gitDir:e.gitDir,commonDir:e.commonDir,repositoryId:e.repositoryId,worktreeId:e.worktreeId,headCommit:e.headCommit,treeOid:e.treeOid})).digest("hex")}function p(e,n){return typeof n=="string"&&e.test(n)}import{existsSync as it,mkdirSync as at,writeFileSync as st}from"fs";import{homedir as ct}from"os";import{join as x}from"path";var mt=1440*60*1e3,Ae="update-check.json",dt="https://registry.npmjs.org/scip-query/latest";async function I(e={}){let n=e.env??process.env;if(n.SCIP_QUERY_UPDATE_CHECK==="0"||n.NO_UPDATE_NOTIFIER)return;let t=e.cacheDir??lt(n),i=e.now??Date.now(),o=e.currentVersion??m,r=ft(t),a=r&&i-r.checkedAt<mt?r.latestVersion:await ht(t,e.fetchLatestVersion??Ct,i);if(!a||!pt(a,o))return;(e.writeNotice??(s=>console.error(s)))(ut(o,a))}function ut(e,n){return[`scip-query update available: ${e} -> ${n}.`,"Agent: tell your human to update with: npm install -g scip-query@latest",""].join(`
6
6
  `)}function pt(e,n){let t=Ie(e),i=Ie(n);if(!t||!i)return e!==n;for(let o=0;o<t.length;o++){let r=t[o]-i[o];if(r>0)return!0;if(r<0)return!1}return!1}function lt(e){let n=e.XDG_CACHE_HOME||x(ct(),".cache");return x(n,"scip-query")}function ft(e){let n=x(e,Ae);if(!it(n))return null;try{let t=JSON.parse($(n,"update notice cache"));return typeof t.checkedAt=="number"&&(typeof t.latestVersion=="string"||t.latestVersion===null)?{checkedAt:t.checkedAt,latestVersion:t.latestVersion}:null}catch{return null}}async function ht(e,n,t){let i;try{i=await n()}catch{i=null}return gt(e,{checkedAt:t,latestVersion:i}),i}function gt(e,n){try{at(e,{recursive:!0}),st(x(e,Ae),`${JSON.stringify(n,null,2)}
7
- `)}catch{}}async function Ct(){let e=await fetch(dt,{signal:AbortSignal.timeout(1e3)});if(!e.ok)return null;let n=await e.json();return typeof n.version=="string"?n.version:null}function Ie(e){let n=/^v?(\d+)\.(\d+)\.(\d+)(?:[-+].*)?$/.exec(e);return n?[Number(n[1]),Number(n[2]),Number(n[3])]:null}var yt=5e3,vt=100,Et={prepare:X,freshness:B,ensureService:v,inspectService:fe,requestRefresh:he,async reindex(e,n,t,i){let{reindexConfiguredProject:o}=await import("./project-reindex-4ARU6QCM.js");return o(e,n,t,i)},wait(e){return new Promise(n=>setTimeout(n,e))},now:Date.now};async function Ne(e,n=Et,t={}){if(e.dbPathSource==="env")return{source:"explicit-index",service:{kind:"skipped",reason:"environment"}};let i=xt(e,n),o=n.prepare(e.projectRoot,e.config,e.paths,{gitContext:e.gitContext,gitObservation:e.gitObservation,...i?{watcherGeneration:i}:{}}),r=o.kind==="local-fresh"&&o.freshness?o.freshness:n.freshness(e.projectRoot,e.config,e.paths,{gitContext:e.gitContext}),a=n.ensureService({commandName:e.commandName,projectRoot:e.projectRoot,cacheDir:e.paths.cacheDir,cliVersion:m,config:e.config,gitContext:e.gitContext});if(r.state==="fresh")return{source:o.kind==="local-fresh"?"existing":"shared-generation",service:a};let c=a.kind==="started"||a.kind==="reused";if(c&&n.requestRefresh(J(e.paths.cacheDir).activityPath,`evidence command ${e.commandName} requires a fresh generation`),C(r))return{source:"stale",service:a};if(c){let s=a.state.watcher.state;if(s==="budget-paused"||s==="indexing")throw new Error(`Could not prepare fresh evidence for scip-query ${e.commandName}: index remained ${r.state} (${r.reason}) while the watcher is ${s}`);if(r=await wt(e,r,n,t,a),r.state==="fresh")return{source:"watcher",service:a};if(C(r))return{source:"stale",service:a}}try{await n.reindex(e.projectRoot,e.config,e.paths,{allowPartial:!1,skipAutoInstall:!0,trigger:{kind:"watch-demand",detail:`scip-query ${e.commandName}`},onStatus:()=>{}})}catch(s){throw new Error(`Could not prepare fresh evidence for scip-query ${e.commandName}: ${s instanceof Error?s.message:String(s)}`,{cause:s})}if(r=n.freshness(e.projectRoot,e.config,e.paths,{gitContext:e.gitContext}),r.state!=="fresh"&&!C(r))throw new Error(`Could not prepare fresh evidence for scip-query ${e.commandName}: index remained ${r.state} (${r.reason})`);return{source:"synchronous-reindex",service:a}}function xt(e,n){if(e.config.watch?.enabled===!0)try{return pe(n.inspectService({projectRoot:e.projectRoot,cacheDir:e.paths.cacheDir,cliVersion:m,gitContext:e.gitContext}))}catch{return}}async function wt(e,n,t,i,o){if(o.state.watcher.state==="budget-paused")return n;let r=Math.max(0,i.waitMs??yt),a=Math.max(1,i.pollMs??vt),c=t.now()+r,s=n;for(;t.now()<c;)if(await t.wait(Math.min(a,Math.max(1,c-t.now()))),s=t.freshness(e.projectRoot,e.config,e.paths,{gitContext:e.gitContext}),s.state==="fresh")return s;return s}async function ke(e,n={}){try{await e()}catch(t){let i=t instanceof Error?t.message:String(t);console.error(`error: ${i}`),(n.debug??process.env.SCIP_QUERY_DEBUG!==void 0)&&t instanceof Error&&t.stack&&console.error(t.stack),process.exitCode=1}}var w=Dt();w&&(ne(),d.configureOutput({writeOut:e=>process.stdout.write(S(e)),writeErr:e=>process.stderr.write(S(e))}));d.name("scip-query").description("Language-agnostic code intelligence CLI powered by SCIP indexes").version(m).option("--output-page-size <characters>","Return bounded output pages with an exact continuation command",ie).option("--output-cursor <cursor>","Continue a bounded output page").option("--agent-output","Emit a bounded JSON projection for model-facing clients (requires --json)").option("--json-output <path>","Atomically write the complete JSON result and print a small receipt").option("--raw-json","Explicitly retain the legacy unpaged JSON stream (requires --json)").option("--no-session","Disable the explicit exploration evidence ledger").option("--reemit","Recovery only: render source and graph evidence again instead of citing session receipts").option("--help-all","Display every command, including compatibility and deprecated controls");w&&ge(process.argv);var A=await Ce(w?process.argv[2]:void 0);Ee(d,A);var f,Pt=new bt;d.configureHelp({formatHelp:(e,n)=>e===d?D(d,A):Pt.formatHelp(e,n)});d.hook("preAction",async(e,n)=>{let t=n.name();if(t==="continue"){I();return}let i=K(t),o=le(t);if(i&&(f=U()),!i&&!o){I(),await j({commandName:t});return}let r=Y(),a=Q(r);y(a),I(),await j({commandName:t});let c=De(r,a.paths.cacheDir),s=c?.context;a={...a,gitContext:s},y(a);let{config:N,paths:k}=a;if(i){let u;try{u=await Ne({commandName:t,projectRoot:r,config:N,paths:k,dbPathSource:a.dbPathSource,gitContext:s,gitObservation:c})}catch(g){if(!Z(t)||!Rt(a.dbPath))throw g;let Te=g instanceof Error?g.message:String(g);console.error(`warning: index refresh failed; ${t} is using the existing index. Current file text remains exact, but index-derived symbols and relationships may be stale. ${Te}`),l(r,m,{repositoryId:s?.repositoryId??null});return}process.env.SCIP_QUERY_DEBUG&&console.error(`evidence-freshness: ${u.source}`),u.service.kind==="failed"&&console.error(`warning: scip-query watch service did not start: ${u.service.message}`),(u.service.kind==="failed"||u.service.kind==="skipped")&&l(r,m,{repositoryId:s?.repositoryId??null});return}if(!o){l(r,m,{repositoryId:s?.repositoryId??null});return}let h=v({commandName:t,projectRoot:r,cacheDir:k.cacheDir,cliVersion:m,config:N,gitContext:s});h.kind==="failed"&&console.error(`warning: scip-query watch service did not start: ${h.message}`),(h.kind==="failed"||h.kind==="skipped")&&l(r,m,{repositoryId:s?.repositoryId??null})});d.hook("postAction",()=>{y(void 0),f?.(),f=void 0});function I(){if(G(),!W()||F())return;let e=null;try{e=ee(n=>_(n))}catch{}q({command:M()??`scip-query ${process.argv.slice(2).join(" ")}`,toolVersion:m,projectFingerprint:e})}async function Ot(){try{process.argv.includes("--help-all")?process.stdout.write(D(d,A,{includeCompatibility:!0})):await d.parseAsync()}finally{f?.(),f=void 0}}w&&await ke(Ot);function Dt(){if(!process.argv[1])return!1;let e=St(import.meta.url);try{return _e(e)===_e(process.argv[1])}catch{return e===process.argv[1]}}export{d as program,$e as renderHeuristicNotice,Ot as runCli};
7
+ `)}catch{}}async function Ct(){let e=await fetch(dt,{signal:AbortSignal.timeout(1e3)});if(!e.ok)return null;let n=await e.json();return typeof n.version=="string"?n.version:null}function Ie(e){let n=/^v?(\d+)\.(\d+)\.(\d+)(?:[-+].*)?$/.exec(e);return n?[Number(n[1]),Number(n[2]),Number(n[3])]:null}var yt=5e3,vt=100,Et={prepare:X,freshness:Y,ensureService:v,inspectService:fe,requestRefresh:he,async reindex(e,n,t,i){let{reindexConfiguredProject:o}=await import("./project-reindex-HYO4WD7Z.js");return o(e,n,t,i)},wait(e){return new Promise(n=>setTimeout(n,e))},now:Date.now};async function Ne(e,n=Et,t={}){if(e.dbPathSource==="env")return{source:"explicit-index",service:{kind:"skipped",reason:"environment"}};let i=xt(e,n),o=n.prepare(e.projectRoot,e.config,e.paths,{gitContext:e.gitContext,gitObservation:e.gitObservation,...i?{watcherGeneration:i}:{}}),r=o.kind==="local-fresh"&&o.freshness?o.freshness:n.freshness(e.projectRoot,e.config,e.paths,{gitContext:e.gitContext}),a=n.ensureService({commandName:e.commandName,projectRoot:e.projectRoot,cacheDir:e.paths.cacheDir,cliVersion:m,config:e.config,gitContext:e.gitContext});if(r.state==="fresh")return{source:o.kind==="local-fresh"?"existing":"shared-generation",service:a};let c=a.kind==="started"||a.kind==="reused";if(c&&n.requestRefresh(B(e.paths.cacheDir).activityPath,`evidence command ${e.commandName} requires a fresh generation`),C(r))return{source:"stale",service:a};if(c){let s=a.state.watcher.state;if(s==="budget-paused"||s==="indexing")throw new Error(`Could not prepare fresh evidence for scip-query ${e.commandName}: index remained ${r.state} (${r.reason}) while the watcher is ${s}`);if(r=await wt(e,r,n,t,a),r.state==="fresh")return{source:"watcher",service:a};if(C(r))return{source:"stale",service:a}}try{await n.reindex(e.projectRoot,e.config,e.paths,{allowPartial:!1,skipAutoInstall:!0,trigger:{kind:"watch-demand",detail:`scip-query ${e.commandName}`},onStatus:()=>{}})}catch(s){throw new Error(`Could not prepare fresh evidence for scip-query ${e.commandName}: ${s instanceof Error?s.message:String(s)}`,{cause:s})}if(r=n.freshness(e.projectRoot,e.config,e.paths,{gitContext:e.gitContext}),r.state!=="fresh"&&!C(r))throw new Error(`Could not prepare fresh evidence for scip-query ${e.commandName}: index remained ${r.state} (${r.reason})`);return{source:"synchronous-reindex",service:a}}function xt(e,n){if(e.config.watch?.enabled===!0)try{return pe(n.inspectService({projectRoot:e.projectRoot,cacheDir:e.paths.cacheDir,cliVersion:m,gitContext:e.gitContext}))}catch{return}}async function wt(e,n,t,i,o){if(o.state.watcher.state==="budget-paused")return n;let r=Math.max(0,i.waitMs??yt),a=Math.max(1,i.pollMs??vt),c=t.now()+r,s=n;for(;t.now()<c;)if(await t.wait(Math.min(a,Math.max(1,c-t.now()))),s=t.freshness(e.projectRoot,e.config,e.paths,{gitContext:e.gitContext}),s.state==="fresh")return s;return s}async function ke(e,n={}){try{await e()}catch(t){let i=t instanceof Error?t.message:String(t);console.error(`error: ${i}`),(n.debug??process.env.SCIP_QUERY_DEBUG!==void 0)&&t instanceof Error&&t.stack&&console.error(t.stack),process.exitCode=1}}var w=Dt();w&&(ne(),d.configureOutput({writeOut:e=>process.stdout.write(P(e)),writeErr:e=>process.stderr.write(P(e))}));d.name("scip-query").description("Language-agnostic code intelligence CLI powered by SCIP indexes").version(m).option("--output-page-size <characters>","Return bounded output pages with an exact continuation command",ie).option("--output-cursor <cursor>","Continue a bounded output page").option("--agent-output","Emit a bounded JSON projection for model-facing clients (requires --json)").option("--json-output <path>","Atomically write the complete JSON result and print a small receipt").option("--raw-json","Explicitly retain the legacy unpaged JSON stream (requires --json)").option("--no-session","Disable the explicit exploration evidence ledger").option("--reemit","Recovery only: render source and graph evidence again instead of citing session receipts").option("--help-all","Display every command, including compatibility and deprecated controls");w&&ge(process.argv);var N=await Ce(w?process.argv[2]:void 0);Ee(d,N);var f,Pt=new bt;d.configureHelp({formatHelp:(e,n)=>e===d?O(d,N):Pt.formatHelp(e,n)});d.hook("preAction",async(e,n)=>{let t=n.name();if(t==="continue"){A();return}let i=K(t),o=le(t);if(i&&(f=W()),!i&&!o){A(),await I({commandName:t});return}let r=S(),a=Q(r);y(a),A(),await I({commandName:t});let c=De(r,a.paths.cacheDir),s=c?.context;a={...a,gitContext:s},y(a);let{config:k,paths:T}=a;if(i){let u;try{u=await Ne({commandName:t,projectRoot:r,config:k,paths:T,dbPathSource:a.dbPathSource,gitContext:s,gitObservation:c})}catch(g){if(!Z(t)||!Rt(a.dbPath))throw g;let _e=g instanceof Error?g.message:String(g);console.error(`warning: index refresh failed; ${t} is using the existing index. Current file text remains exact, but index-derived symbols and relationships may be stale. ${_e}`),l(r,m,{repositoryId:s?.repositoryId??null});return}process.env.SCIP_QUERY_DEBUG&&console.error(`evidence-freshness: ${u.source}`),u.service.kind==="failed"&&console.error(`warning: scip-query watch service did not start: ${u.service.message}`),(u.service.kind==="failed"||u.service.kind==="skipped")&&l(r,m,{repositoryId:s?.repositoryId??null});return}if(!o){l(r,m,{repositoryId:s?.repositoryId??null});return}let h=v({commandName:t,projectRoot:r,cacheDir:T.cacheDir,cliVersion:m,config:k,gitContext:s});h.kind==="failed"&&console.error(`warning: scip-query watch service did not start: ${h.message}`),(h.kind==="failed"||h.kind==="skipped")&&l(r,m,{repositoryId:s?.repositoryId??null})});d.hook("postAction",()=>{y(void 0),f?.(),f=void 0});function A(){if(V(),!U()||H())return;let e=null,n=null;try{n=ee(S()),e=q(n)}catch{}finally{n?.close()}z({command:L()??`scip-query ${process.argv.slice(2).join(" ")}`,toolVersion:m,projectFingerprint:e})}async function jt(){try{process.argv.includes("--help-all")?process.stdout.write(O(d,N,{includeCompatibility:!0})):await d.parseAsync()}finally{f?.(),f=void 0}}w&&await ke(jt);function Dt(){if(!process.argv[1])return!1;let e=St(import.meta.url);try{return Te(e)===Te(process.argv[1])}catch{return e===process.argv[1]}}export{d as program,$e as renderHeuristicNotice,jt as runCli};
8
8
  //# sourceMappingURL=cli-main.js.map
@@ -1,5 +1,5 @@
1
1
  import { S as SourceObservationFreshness } from './repository-text-C0Q8VYdN.js';
2
- import { S as ScipDatabase } from './db-LKJXAlNS.js';
2
+ import { S as ScipDatabase } from './db-BwIVAYNB.js';
3
3
  import { OutlineNode } from './queries/outline.js';
4
4
 
5
5
  interface BindingDefinitionEvidence {
@@ -0,0 +1,2 @@
1
+ import{b as a,c as b}from"./chunk-TUQIPUDS.js";import"./chunk-XN22RGSR.js";import"./chunk-7KSO2OAP.js";import"./chunk-56NQAEPJ.js";import"./chunk-5YRQIE2B.js";import"./chunk-RNKPYYYE.js";import"./chunk-6NC3YSPY.js";import"./chunk-MTDBHTSF.js";import"./chunk-RYOYJMGF.js";import"./chunk-FELGD32K.js";import"./chunk-2XCGSDIT.js";import"./chunk-WRQXLNYE.js";import"./chunk-T6QD2ZQB.js";import"./chunk-EELPBR7E.js";import"./chunk-YUKYB54I.js";import"./chunk-BJT7LSPK.js";import"./chunk-C7IJMOFP.js";import"./chunk-YXPUP5G2.js";import"./chunk-DRENNWRG.js";import"./chunk-DKM723YF.js";import"./chunk-K3XFWJI2.js";import"./chunk-IW5XQG5G.js";import"./chunk-H5EXS3HM.js";import"./chunk-HGFDYOVB.js";import"./chunk-AK3PYTIK.js";export{a as code,b as codeBatch};
2
+ //# sourceMappingURL=code-EQJFDT6I.js.map
@@ -0,0 +1,2 @@
1
+ import{a,b,c,d,e}from"./chunk-CLG6DWVS.js";import"./chunk-EELPBR7E.js";import"./chunk-C7IJMOFP.js";import"./chunk-YXPUP5G2.js";import"./chunk-DRENNWRG.js";import"./chunk-DKM723YF.js";import"./chunk-K3XFWJI2.js";import"./chunk-IW5XQG5G.js";import"./chunk-H5EXS3HM.js";import"./chunk-HGFDYOVB.js";import"./chunk-AK3PYTIK.js";export{d as codeBatchResultOnlyJson,e as codeBatchResultOnlyJsonForSelectors,c as codeResultOnlyJson,b as singleExactCodeResult,a as symbolResolutionJson};
2
+ //# sourceMappingURL=code-result-json-7UWIWBOO.js.map