agentic-qe 3.10.2 → 3.10.4

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 (418) hide show
  1. package/.claude/skills/release/SKILL.md +10 -10
  2. package/.claude/skills/skills-manifest.json +1 -1
  3. package/CHANGELOG.md +88 -0
  4. package/assets/grammars/tree-sitter-c_sharp.wasm +0 -0
  5. package/assets/grammars/tree-sitter-java.wasm +0 -0
  6. package/assets/grammars/tree-sitter-javascript.wasm +0 -0
  7. package/assets/grammars/tree-sitter-python.wasm +0 -0
  8. package/assets/grammars/tree-sitter-rust.wasm +0 -0
  9. package/assets/grammars/tree-sitter-swift.wasm +0 -0
  10. package/assets/grammars/tree-sitter-tsx.wasm +0 -0
  11. package/assets/grammars/tree-sitter-typescript.wasm +0 -0
  12. package/assets/skills/skills-manifest.json +1 -1
  13. package/dist/agents/claim-verifier/claim-verifier-service.js +4 -2
  14. package/dist/agents/claim-verifier/verifiers/test-verifier.js +31 -23
  15. package/dist/agents/devils-advocate/agent.js +1 -1
  16. package/dist/cli/bundle.js +5 -5
  17. package/dist/cli/chunks/adapter-A62ETL5C.js +2 -0
  18. package/dist/cli/chunks/{agent-booster-wasm-DHSIPFTH.js → agent-booster-wasm-EJPDSWON.js} +2 -2
  19. package/dist/cli/chunks/{agent-handler-FPQVHGGT.js → agent-handler-2DZB7LGI.js} +2 -2
  20. package/dist/cli/chunks/{agent-memory-branch-OLOF5ZHV.js → agent-memory-branch-SSFYAVIK.js} +2 -2
  21. package/dist/cli/chunks/aqe-learning-engine-MTCRAV6N.js +2 -0
  22. package/dist/cli/chunks/audit-42XG5JFB.js +3 -0
  23. package/dist/cli/chunks/base-KKEBUHZC.js +2 -0
  24. package/dist/cli/chunks/{hnswlib-node-ZGSUMHDC.js → better-sqlite3-PX5JM3DG.js} +2 -2
  25. package/dist/cli/chunks/{brain-handler-ROZUHCOT.js → brain-handler-LFHX2TYP.js} +3 -3
  26. package/dist/cli/chunks/{branch-enumerator-VK7G4NKJ.js → branch-enumerator-AX7DKGV7.js} +2 -2
  27. package/dist/cli/chunks/{browser-Q2S75M2F.js → browser-4NYLZ7FA.js} +2 -2
  28. package/dist/cli/chunks/browser-workflow-XHYAJUB6.js +2 -0
  29. package/dist/cli/chunks/{chunk-XPCNUX2U.js → chunk-2B6ETC7C.js} +2 -2
  30. package/dist/cli/chunks/{chunk-YI6GNRQM.js → chunk-2G2PVVQG.js} +2 -2
  31. package/dist/cli/chunks/{chunk-2244IFZA.js → chunk-2L5VFVCG.js} +1 -1
  32. package/dist/cli/chunks/{chunk-EVCOCGVJ.js → chunk-2TYO4VZH.js} +4 -4
  33. package/dist/cli/chunks/{chunk-U3EUH6LX.js → chunk-3ISX5B77.js} +2 -2
  34. package/dist/cli/chunks/{chunk-WZJUMJ2S.js → chunk-3UGUX34A.js} +1 -1
  35. package/dist/cli/chunks/{chunk-6ZFHIKQG.js → chunk-4BX72XG4.js} +3 -3
  36. package/dist/cli/chunks/{chunk-UUFOHMUG.js → chunk-4FTLYIMW.js} +2 -2
  37. package/dist/cli/chunks/{chunk-XDU624HU.js → chunk-5FNNCVXR.js} +1 -1
  38. package/dist/cli/chunks/{chunk-7Z46RDDV.js → chunk-5Q3L4QEE.js} +3 -3
  39. package/dist/cli/chunks/{chunk-AH7FXNFE.js → chunk-5T2HDET6.js} +3 -3
  40. package/dist/cli/chunks/{chunk-24LUQICS.js → chunk-5T4J3IPG.js} +2 -2
  41. package/dist/cli/chunks/{chunk-HHCYSAH3.js → chunk-6OLHPWSN.js} +2 -2
  42. package/dist/cli/chunks/{chunk-5PRFFHFV.js → chunk-6SCIX2W2.js} +2 -2
  43. package/dist/cli/chunks/{chunk-2JDLQWSV.js → chunk-6WF2MOQB.js} +2 -2
  44. package/dist/cli/chunks/{chunk-YNNOY3XN.js → chunk-7BQXEYRV.js} +2 -2
  45. package/dist/cli/chunks/{chunk-MMIQ5DMA.js → chunk-7VO5IEJ2.js} +2 -2
  46. package/dist/cli/chunks/{chunk-XDSA7YUQ.js → chunk-AIBE3J4A.js} +1 -1
  47. package/dist/cli/chunks/{chunk-AV7KYE5P.js → chunk-AMW27FSS.js} +5 -5
  48. package/dist/cli/chunks/{chunk-22D6VBPD.js → chunk-AZJYDM2K.js} +2 -2
  49. package/dist/cli/chunks/{chunk-PYIHZXCI.js → chunk-B6CT4ILU.js} +4 -4
  50. package/dist/cli/chunks/{chunk-ZK2BH23O.js → chunk-BEFRQOLH.js} +2 -2
  51. package/dist/cli/chunks/{chunk-CIRPP7RQ.js → chunk-C2446H7G.js} +2 -2
  52. package/dist/cli/chunks/{chunk-ON4D4TJ4.js → chunk-D7IWGQTW.js} +2 -2
  53. package/dist/cli/chunks/{chunk-6KSCXPPL.js → chunk-D7PI4CYZ.js} +2 -2
  54. package/dist/cli/chunks/{chunk-BQCSCAUC.js → chunk-DAIM72HV.js} +2 -2
  55. package/dist/cli/chunks/{chunk-XMJTTF5N.js → chunk-DPKECIKN.js} +3 -3
  56. package/dist/cli/chunks/{chunk-DZZEHPSJ.js → chunk-E6CGBOZY.js} +3 -3
  57. package/dist/cli/chunks/{chunk-OIRZJCZY.js → chunk-EGTOSQZK.js} +2 -2
  58. package/dist/cli/chunks/{chunk-WDMPJ2M2.js → chunk-EMZ3DXMG.js} +2 -2
  59. package/dist/cli/chunks/{chunk-QBRHKTFT.js → chunk-EWI37TJA.js} +1 -1
  60. package/dist/cli/chunks/{chunk-A5RMQG4N.js → chunk-F34OO2Q7.js} +3 -3
  61. package/dist/cli/chunks/{chunk-7SWD3D6Y.js → chunk-F6QPAVWS.js} +2 -2
  62. package/dist/cli/chunks/chunk-F77X5DAF.js +2 -0
  63. package/dist/cli/chunks/{chunk-Y63MBMOV.js → chunk-FDFJJFQT.js} +2 -2
  64. package/dist/cli/chunks/{chunk-YWZHMXTO.js → chunk-FQ7I4JBQ.js} +2 -2
  65. package/dist/cli/chunks/{chunk-S3ZO7JXS.js → chunk-G5FPWH5O.js} +4 -4
  66. package/dist/cli/chunks/{chunk-QSE67XJO.js → chunk-GDMH7NPV.js} +2 -2
  67. package/dist/cli/chunks/{chunk-MEY43PIQ.js → chunk-GILL32E2.js} +2 -2
  68. package/dist/cli/chunks/{chunk-LQTWPSYL.js → chunk-GLMDRGJD.js} +1 -1
  69. package/dist/cli/chunks/{chunk-MNV3E5KY.js → chunk-GS33ZRJH.js} +4 -4
  70. package/dist/cli/chunks/chunk-HPYGMKZF.js +2 -0
  71. package/dist/cli/chunks/{chunk-EQBEGDTG.js → chunk-HTLAPMTK.js} +1 -1
  72. package/dist/cli/chunks/{chunk-C2M74HCN.js → chunk-IAK76TIZ.js} +1 -1
  73. package/dist/cli/chunks/{chunk-2EDWGHDA.js → chunk-ICF5RPQU.js} +2 -2
  74. package/dist/cli/chunks/{chunk-ZXTO4C7R.js → chunk-IPAQ4HVX.js} +2 -2
  75. package/dist/cli/chunks/{chunk-RLXTBL3H.js → chunk-ISRTT4I7.js} +22 -22
  76. package/dist/cli/chunks/{chunk-SW4OKUTC.js → chunk-IYFMDIYZ.js} +2 -2
  77. package/dist/cli/chunks/{chunk-7IZ2OPC2.js → chunk-JRBGHWAM.js} +2 -2
  78. package/dist/cli/chunks/{chunk-QJ2EHLJ2.js → chunk-JYR3X4OC.js} +1 -1
  79. package/dist/cli/chunks/{chunk-5QHSLWLP.js → chunk-K72J52JO.js} +2 -2
  80. package/dist/cli/chunks/{chunk-PIZYRPMT.js → chunk-K7CW2X6U.js} +2 -2
  81. package/dist/cli/chunks/{chunk-3Z4FHA2E.js → chunk-K7K4TFJM.js} +4 -4
  82. package/dist/cli/chunks/{chunk-5HB54RUS.js → chunk-KCXE2LZU.js} +2 -2
  83. package/dist/cli/chunks/{chunk-THRTUW4Z.js → chunk-KGPAWNNR.js} +1 -1
  84. package/dist/cli/chunks/{chunk-MYWQTCS4.js → chunk-KJ56OXH4.js} +1 -1
  85. package/dist/cli/chunks/{chunk-ZDHMZPSL.js → chunk-KUFC4DBX.js} +1 -1
  86. package/dist/cli/chunks/{chunk-CV2SBMBW.js → chunk-KWZEBHAP.js} +2 -2
  87. package/dist/cli/chunks/{chunk-X2VAOIUY.js → chunk-L6VNEEN6.js} +1 -1
  88. package/dist/cli/chunks/{chunk-S3OZ7XSY.js → chunk-LHPR7ROV.js} +1 -1
  89. package/dist/cli/chunks/{chunk-HO37VP4O.js → chunk-LKK3NIHC.js} +1 -1
  90. package/dist/cli/chunks/{chunk-XRJECWZE.js → chunk-LOFA3U4X.js} +1 -1
  91. package/dist/cli/chunks/{chunk-AWFIEGR3.js → chunk-LYKSIOOT.js} +2 -2
  92. package/dist/cli/chunks/chunk-M2PSXKTG.js +2 -0
  93. package/dist/cli/chunks/{chunk-CMACGG4Z.js → chunk-M3MKP5VN.js} +1 -1
  94. package/dist/cli/chunks/{chunk-UYYBPWU3.js → chunk-M4ARHDY4.js} +1 -1
  95. package/dist/cli/chunks/chunk-M5DBKHM4.js +2 -0
  96. package/dist/cli/chunks/{chunk-7IVQ6OVR.js → chunk-MDWJXSBA.js} +2 -2
  97. package/dist/cli/chunks/{chunk-IICTTDAA.js → chunk-MFWWPRBV.js} +2 -2
  98. package/dist/cli/chunks/{chunk-4BXGVM2C.js → chunk-MHWYQHGN.js} +1 -1
  99. package/dist/cli/chunks/{chunk-HJME6G5M.js → chunk-MIQBRVK2.js} +1 -1
  100. package/dist/cli/chunks/{chunk-FY3CUPNN.js → chunk-MKZQBBCU.js} +2 -2
  101. package/dist/cli/chunks/{chunk-MCOFJHSJ.js → chunk-MQ5WMWUK.js} +5 -5
  102. package/dist/cli/chunks/chunk-MQIAN57O.js +2 -0
  103. package/dist/cli/chunks/{chunk-6NZHEM4V.js → chunk-MU4P4P4E.js} +3 -3
  104. package/dist/cli/chunks/{chunk-ETN5563K.js → chunk-MWV4KPOB.js} +2 -2
  105. package/dist/cli/chunks/{chunk-XTCUN36Z.js → chunk-N244P4MM.js} +2 -2
  106. package/dist/cli/chunks/{chunk-DRWGK3YO.js → chunk-N3MM4Z33.js} +2 -2
  107. package/dist/cli/chunks/{chunk-QQNCSEZG.js → chunk-N4CXUGXE.js} +2 -2
  108. package/dist/cli/chunks/{chunk-PEK6NGVJ.js → chunk-ND6YSW5N.js} +1 -1
  109. package/dist/cli/chunks/{chunk-7V5UHLNY.js → chunk-NJYI7HX7.js} +3 -3
  110. package/dist/cli/chunks/{chunk-YACT5WFC.js → chunk-NSRDP7RD.js} +2 -2
  111. package/dist/cli/chunks/{chunk-L7VIX22Y.js → chunk-NZGLDOU4.js} +15 -15
  112. package/dist/cli/chunks/{chunk-MNUTRAUV.js → chunk-O3SG32PS.js} +1 -1
  113. package/dist/cli/chunks/{chunk-ZGNZJJFF.js → chunk-OIFJH7TF.js} +1 -1
  114. package/dist/cli/chunks/{chunk-LZCBSFAU.js → chunk-OKKTDHHF.js} +6 -6
  115. package/dist/cli/chunks/{chunk-3RHHKYUR.js → chunk-OO7KJ34Y.js} +2 -2
  116. package/dist/cli/chunks/{chunk-STEGWLH5.js → chunk-OV4BLIKJ.js} +2 -2
  117. package/dist/cli/chunks/{chunk-AOI67HA3.js → chunk-PISW5HUX.js} +1 -1
  118. package/dist/cli/chunks/{chunk-SJH3HYNC.js → chunk-PLD4IGDL.js} +2 -2
  119. package/dist/cli/chunks/{chunk-2OH3ALYB.js → chunk-PMWWWYUM.js} +1 -1
  120. package/dist/cli/chunks/{chunk-EA7ZSN3V.js → chunk-PWJZZCHJ.js} +1 -1
  121. package/dist/cli/chunks/{chunk-HA63NBFK.js → chunk-PZ4PRZXN.js} +37 -37
  122. package/dist/cli/chunks/chunk-PZCSJZVJ.js +2 -0
  123. package/dist/cli/chunks/{chunk-CTDLI2ON.js → chunk-Q53M4LI7.js} +1 -1
  124. package/dist/cli/chunks/{chunk-WSVUSIAZ.js → chunk-QPMAXDJ2.js} +2 -2
  125. package/dist/cli/chunks/{chunk-MCZHKXB4.js → chunk-RJKYPWFD.js} +2 -2
  126. package/dist/cli/chunks/{chunk-7QRMARM7.js → chunk-RUC3FCRK.js} +2 -2
  127. package/dist/cli/chunks/{chunk-5PL7WTCU.js → chunk-SC6UFGJ6.js} +2 -2
  128. package/dist/cli/chunks/{chunk-FO43SQXP.js → chunk-SJC7OKF3.js} +2 -2
  129. package/dist/cli/chunks/{chunk-R2O6OKT2.js → chunk-STMMZXS6.js} +1 -1
  130. package/dist/cli/chunks/{chunk-ORF2UKQH.js → chunk-SVILIQQQ.js} +1 -1
  131. package/dist/cli/chunks/{chunk-UVU7XLJY.js → chunk-SXMGNMFL.js} +5 -5
  132. package/dist/cli/chunks/{chunk-OIEQF7PG.js → chunk-SZKFT6CD.js} +2 -2
  133. package/dist/cli/chunks/{chunk-G5U6Q42D.js → chunk-TBJ566KV.js} +2 -2
  134. package/dist/cli/chunks/{chunk-SVYTN2GT.js → chunk-TCV5DASI.js} +2 -2
  135. package/dist/cli/chunks/chunk-TWAWEP4X.js +59 -0
  136. package/dist/cli/chunks/chunk-U27GVYXA.js +2 -0
  137. package/dist/cli/chunks/{chunk-FPAW77XV.js → chunk-UFKVKNAA.js} +1 -1
  138. package/dist/cli/chunks/{chunk-HJORBNXW.js → chunk-USB7GCIC.js} +1 -1
  139. package/dist/cli/chunks/{chunk-4GTDW2XL.js → chunk-UW3ZSFFB.js} +2 -2
  140. package/dist/cli/chunks/{chunk-OXCEUR5F.js → chunk-UWAUYDW4.js} +2 -2
  141. package/dist/cli/chunks/{chunk-4F3ZTXHP.js → chunk-UXJVR323.js} +2 -2
  142. package/dist/cli/chunks/{chunk-AIUSZC6K.js → chunk-V5G3SMAJ.js} +2 -2
  143. package/dist/cli/chunks/{chunk-DMQPO43S.js → chunk-VDKMBOUK.js} +1 -1
  144. package/dist/cli/chunks/{chunk-5WJ3FWL4.js → chunk-VJ2D6FST.js} +24 -24
  145. package/dist/cli/chunks/chunk-VJOPNK2L.js +2 -0
  146. package/dist/cli/chunks/{chunk-JF53LRBL.js → chunk-VRE2EBFI.js} +2 -2
  147. package/dist/cli/chunks/{chunk-WNR2KAUH.js → chunk-WI5WXYIS.js} +2 -2
  148. package/dist/cli/chunks/{chunk-OWQ6HEYI.js → chunk-WIYWDON4.js} +2 -2
  149. package/dist/cli/chunks/{chunk-KB5L5TTF.js → chunk-WYMQ6FZR.js} +5 -5
  150. package/dist/cli/chunks/{chunk-TJKDATEU.js → chunk-XBFEHVBO.js} +2 -2
  151. package/dist/cli/chunks/{chunk-7SJX4CFK.js → chunk-XDZXLEJK.js} +1 -1
  152. package/dist/cli/chunks/{chunk-QEPFXY6G.js → chunk-XJXCSCCP.js} +1 -1
  153. package/dist/cli/chunks/{chunk-OPFN5LFT.js → chunk-XVA56PXZ.js} +4 -4
  154. package/dist/cli/chunks/{chunk-PXTDEO65.js → chunk-Y2EDDV5U.js} +2 -2
  155. package/dist/cli/chunks/{chunk-VSUTI4G6.js → chunk-YSLE6NNG.js} +2 -2
  156. package/dist/cli/chunks/{chunk-XGBAHAGC.js → chunk-Z4BTPQLG.js} +4 -4
  157. package/dist/cli/chunks/{chunk-NZO4WUSO.js → chunk-ZM4QGYGK.js} +3 -3
  158. package/dist/cli/chunks/{ci-PYCRCL7G.js → ci-2BLMQNX3.js} +6 -6
  159. package/dist/cli/chunks/{ci-output-EKQQFE2D.js → ci-output-XK4PPSN7.js} +2 -2
  160. package/dist/cli/chunks/{circuit-breaker-RH3Q2MJO.js → circuit-breaker-W7X4NPFE.js} +2 -2
  161. package/dist/cli/chunks/{claude-flow-setup-DUDXB4VV.js → claude-flow-setup-GLBLSYNJ.js} +2 -2
  162. package/dist/cli/chunks/client-C6CJOCRN.js +2 -0
  163. package/dist/cli/chunks/{cline-installer-3Q4WIWUG.js → cline-installer-7WX7DBGI.js} +2 -2
  164. package/dist/cli/chunks/{code-E4Q6DGOO.js → code-SP3HAQWG.js} +20 -19
  165. package/dist/cli/chunks/{code-index-extractor-2PCISUOW.js → code-index-extractor-44HH36UG.js} +2 -2
  166. package/dist/cli/chunks/{codex-installer-YNNNOLJ6.js → codex-installer-LMXRWLPU.js} +2 -2
  167. package/dist/cli/chunks/{completions-2F7TUFBD.js → completions-GL5FTZAN.js} +2 -2
  168. package/dist/cli/chunks/{complexity-analyzer-2B6MHO7W.js → complexity-analyzer-CQMYGETL.js} +2 -2
  169. package/dist/cli/chunks/{continuedev-installer-ENOKRU5M.js → continuedev-installer-CYVYS5B7.js} +2 -2
  170. package/dist/cli/chunks/{copilot-installer-6YD2KM5F.js → copilot-installer-M7XVII2A.js} +2 -2
  171. package/dist/cli/chunks/{cost-tracker-FCH4QOEA.js → cost-tracker-S4ET4FH3.js} +2 -2
  172. package/dist/cli/chunks/{coverage-JTOXZE3T.js → coverage-DFVSSQ4A.js} +3 -3
  173. package/dist/cli/chunks/cross-domain-router-I3GEA5G6.js +2 -0
  174. package/dist/cli/chunks/{cursor-installer-QZFBUGLQ.js → cursor-installer-KWDSQPQC.js} +2 -2
  175. package/dist/cli/chunks/{daemon-K4QFB5FQ.js → daemon-2HD54QVO.js} +3 -3
  176. package/dist/cli/chunks/daemon-CRX46BBO.js +10 -0
  177. package/dist/cli/chunks/{dag-attention-scheduler-BXAAW33V.js → dag-attention-scheduler-SCP6WPZB.js} +2 -2
  178. package/dist/cli/chunks/{detect-UGSWIOAD.js → detect-XS2GDCEX.js} +2 -2
  179. package/dist/cli/chunks/{dist-node-FN3HX3OK.js → dist-node-U43MVQ3F.js} +2 -2
  180. package/dist/cli/chunks/{domain-handler-7PP7VYA7.js → domain-handler-HITMDULH.js} +2 -2
  181. package/dist/cli/chunks/{domain-transfer-XZM44W7I.js → domain-transfer-TJF7DNI4.js} +2 -2
  182. package/dist/cli/chunks/dream-JCQMG2RL.js +2 -0
  183. package/dist/cli/chunks/{embed-and-insert-pattern-JZVERJ5L.js → embed-and-insert-pattern-JKG33YZK.js} +2 -2
  184. package/dist/cli/chunks/{eval-466NFF2D.js → eval-NF5Y4W37.js} +3 -3
  185. package/dist/cli/chunks/{experience-capture-middleware-I7IQCC7V.js → experience-capture-middleware-VMMFYJ4D.js} +3 -3
  186. package/dist/cli/chunks/{fast-paths-34OICNZA.js → fast-paths-W2Q53IR2.js} +2 -2
  187. package/dist/cli/chunks/{feature-flags-6UBIVTAD.js → feature-flags-B4PBMQJO.js} +2 -2
  188. package/dist/cli/chunks/{feature-flags-X5WBBWSO.js → feature-flags-PVI7A4RE.js} +2 -2
  189. package/dist/cli/chunks/{file-discovery-NLMDBWXX.js → file-discovery-E4L3I33I.js} +2 -2
  190. package/dist/cli/chunks/{fleet-W7CYCHDI.js → fleet-LE5SHVLK.js} +3 -3
  191. package/dist/cli/chunks/{gnn-wrapper-K4VTAG5X.js → gnn-wrapper-MWWJBLOH.js} +2 -2
  192. package/dist/cli/chunks/{heartbeat-handler-ZGKF2Z6T.js → heartbeat-handler-XOUVNPQK.js} +4 -4
  193. package/dist/cli/chunks/heartbeat-scheduler-FBHE4ZWH.js +2 -0
  194. package/dist/cli/chunks/hnsw-adapter-EOOA4WXD.js +2 -0
  195. package/dist/cli/chunks/hnsw-index-TD3KRPND.js +2 -0
  196. package/dist/cli/chunks/{hnsw-legacy-bridge-ELDRLKK5.js → hnsw-legacy-bridge-W3T5ZDDP.js} +2 -2
  197. package/dist/cli/chunks/{better-sqlite3-5BT5FO64.js → hnswlib-node-3TZFES5I.js} +2 -2
  198. package/dist/cli/chunks/hooks-RUPQVIUM.js +250 -0
  199. package/dist/cli/chunks/hybrid-router-64O6PXZ2.js +2 -0
  200. package/dist/cli/chunks/{hypergraph-engine-UWFW3XP5.js → hypergraph-engine-VDFK3JYH.js} +2 -2
  201. package/dist/cli/chunks/{hypergraph-handler-PK2BI46K.js → hypergraph-handler-EUDGEF25.js} +3 -3
  202. package/dist/cli/chunks/impact-analyzer-ITQHXGTM.js +2 -0
  203. package/dist/cli/chunks/{init-handler-HNG6KJOU.js → init-handler-MZEAJOZK.js} +6 -6
  204. package/dist/cli/chunks/init-wizard-DZ4IKGQI.js +2 -0
  205. package/dist/cli/chunks/kernel-HSVY4ZYK.js +2 -0
  206. package/dist/cli/chunks/{kilocode-installer-25V7FEJ4.js → kilocode-installer-ECBYWT6M.js} +2 -2
  207. package/dist/cli/chunks/{kiro-installer-7RMTTCQB.js → kiro-installer-KYFCSYTG.js} +2 -2
  208. package/dist/cli/chunks/knowledge-graph-H32TXXX4.js +2 -0
  209. package/dist/cli/chunks/{learning-XQC2MG2R.js → learning-4RAFMDSB.js} +3 -3
  210. package/dist/cli/chunks/{llm-router-6KTTONH4.js → llm-router-JHBNLYP3.js} +12 -12
  211. package/dist/cli/chunks/llm-router-service-3FKESBUX.js +2 -0
  212. package/dist/cli/chunks/{load-BV64P3AL.js → load-4DVQML7P.js} +2 -2
  213. package/dist/cli/chunks/load-test-LKHURZGZ.js +2 -0
  214. package/dist/cli/chunks/{mcp-U5ZN77TA.js → mcp-LCWMU4GZ.js} +2 -2
  215. package/dist/cli/chunks/{memory-WB5BNBK7.js → memory-3DTJAURT.js} +5 -5
  216. package/dist/cli/chunks/memory-backend-XRJRZ6CK.js +2 -0
  217. package/dist/cli/chunks/memory-handlers-BL6E3XAK.js +2 -0
  218. package/dist/cli/chunks/{multi-model-executor-3X3W3UTY.js → multi-model-executor-AVR5SZOO.js} +2 -2
  219. package/dist/cli/chunks/{opencode-installer-TTTMG7ZZ.js → opencode-installer-DW2426QM.js} +3 -3
  220. package/dist/cli/chunks/{orchestrator-BLCGSHMZ.js → orchestrator-AHF4W5GS.js} +8 -8
  221. package/dist/cli/chunks/{pipeline-DZPGMRG7.js → pipeline-N6THEWYE.js} +2 -2
  222. package/dist/cli/chunks/{platform-EVMZAUNV.js → platform-MRCFQF7X.js} +2 -2
  223. package/dist/cli/chunks/{plugin-OR55K4HT.js → plugin-6YKUN5QM.js} +2 -2
  224. package/dist/cli/chunks/{prime-radiant-advanced-wasm-4ODV27HD.js → prime-radiant-advanced-wasm-2YPAHSVS.js} +2 -2
  225. package/dist/cli/chunks/protocol-executor-KABPB6PQ.js +2 -0
  226. package/dist/cli/chunks/{protocol-handler-ZOTI5PID.js → protocol-handler-Y2NMUKWQ.js} +2 -2
  227. package/dist/cli/chunks/{prove-DIMBYJ7V.js → prove-DZUNWBFD.js} +2 -2
  228. package/dist/cli/chunks/provider-manager-U7EBM3FA.js +2 -0
  229. package/dist/cli/chunks/qe-reasoning-bank-64O2OQIW.js +2 -0
  230. package/dist/cli/chunks/{quality-7MX4VL6M.js → quality-AIFQMGUV.js} +2 -2
  231. package/dist/cli/chunks/queen-coordinator-SV3COGIL.js +2 -0
  232. package/dist/cli/chunks/{real-embeddings-YPUHWRN2.js → real-embeddings-5XL4LOG2.js} +2 -2
  233. package/dist/cli/chunks/{roocode-installer-WG5AU4QM.js → roocode-installer-LV3WONT5.js} +2 -2
  234. package/dist/cli/chunks/router-QARRPMED.js +2 -0
  235. package/dist/cli/chunks/routing-feedback-KD2JFTPK.js +2 -0
  236. package/dist/cli/chunks/{routing-handler-LZB4MN2K.js → routing-handler-WSMUILGD.js} +2 -2
  237. package/dist/cli/chunks/{ruvector-commands-YE4ADBMC.js → ruvector-commands-BCEIDTW3.js} +2 -2
  238. package/dist/cli/chunks/{rvf-dual-writer-QS5ATW4C.js → rvf-dual-writer-LRSPC6H3.js} +2 -2
  239. package/dist/cli/chunks/{rvf-migration-adapter-YIGKSBD3.js → rvf-migration-adapter-QHNX6353.js} +2 -2
  240. package/dist/cli/chunks/{rvf-migration-coordinator-2NDCWP7F.js → rvf-migration-coordinator-SLNB3XPW.js} +2 -2
  241. package/dist/cli/chunks/rvf-native-adapter-4LLGF5AY.js +2 -0
  242. package/dist/cli/chunks/safe-db-RAX3H2P7.js +2 -0
  243. package/dist/cli/chunks/schedule-RQZGLLUY.js +2 -0
  244. package/dist/cli/chunks/scheduler-ACWTN4LN.js +2 -0
  245. package/dist/cli/chunks/{security-HT4SUT24.js → security-CYY6TECQ.js} +3 -3
  246. package/dist/cli/chunks/shared-rvf-adapter-U6JE4O6A.js +2 -0
  247. package/dist/cli/chunks/{shared-rvf-dual-writer-ZKFO7CBY.js → shared-rvf-dual-writer-PJBSNBRV.js} +2 -2
  248. package/dist/cli/chunks/sqlite-persistence-SWNBO257.js +2 -0
  249. package/dist/cli/chunks/{status-handler-AMEMKBI4.js → status-handler-W723LXX5.js} +2 -2
  250. package/dist/cli/chunks/{structural-health-RBADRLC3.js → structural-health-WZUPZBB5.js} +2 -2
  251. package/dist/cli/chunks/{sync-PCB23M4K.js → sync-UA22CKUS.js} +2 -2
  252. package/dist/cli/chunks/sync-ZLMF53TB.js +2 -0
  253. package/dist/cli/chunks/{task-handler-J26FSCH5.js → task-handler-SENTEEXZ.js} +2 -2
  254. package/dist/cli/chunks/{task-handlers-AQRLR6BL.js → task-handlers-FGVUZOCC.js} +3 -3
  255. package/dist/cli/chunks/{test-YXWSIOSB.js → test-Q37C3WI2.js} +4 -4
  256. package/dist/cli/chunks/{test-scheduling-XY532GI4.js → test-scheduling-E6SPIBTH.js} +4 -4
  257. package/dist/cli/chunks/token-bootstrap-HQFFMZUF.js +2 -0
  258. package/dist/cli/chunks/{token-usage-2MJVE4DT.js → token-usage-JHNWTZ7L.js} +3 -3
  259. package/dist/cli/chunks/{transformers-QSNTOD2Z.js → transformers-TEXDUVNI.js} +2 -2
  260. package/dist/cli/chunks/tree-sitter-wasm-parser-MWSS52H6.js +2 -0
  261. package/dist/cli/chunks/{types-RNKRSYMO.js → types-YQRKHYH3.js} +2 -2
  262. package/dist/cli/chunks/unified-memory-QG3FDRKR.js +2 -0
  263. package/dist/cli/chunks/unified-memory-hnsw-KOR4EOIG.js +2 -0
  264. package/dist/cli/chunks/unified-persistence-J6NIRYKM.js +2 -0
  265. package/dist/cli/chunks/{upgrade-EKJHIFWP.js → upgrade-JKMEDURI.js} +2 -2
  266. package/dist/cli/chunks/{validate-KS4T7LWC.js → validate-URO7G6OE.js} +4 -4
  267. package/dist/cli/chunks/validate-swarm-VZVJ56Z5.js +14 -0
  268. package/dist/cli/chunks/{vibium-FLUQO4IF.js → vibium-G5WZILL6.js} +2 -2
  269. package/dist/cli/chunks/visual-security-RAWV6YLN.js +2 -0
  270. package/dist/cli/chunks/{web-tree-sitter-UMC63DWD.js → web-tree-sitter-LECH5T6H.js} +2 -2
  271. package/dist/cli/chunks/{windsurf-installer-V3FQGJIQ.js → windsurf-installer-2NPLC2YW.js} +2 -2
  272. package/dist/cli/chunks/{witness-chain-GE74TLSO.js → witness-chain-X347C36A.js} +2 -2
  273. package/dist/cli/chunks/witness-chain-ZO7FIM35.js +2 -0
  274. package/dist/cli/chunks/{workflow-4YZ2RPWA.js → workflow-V4ALYZ73.js} +4 -4
  275. package/dist/cli/chunks/workflow-orchestrator-7SKITNIJ.js +2 -0
  276. package/dist/cli/chunks/wrappers-QXOPRPR4.js +2 -0
  277. package/dist/cli/commands/code.js +6 -0
  278. package/dist/cli/commands/hooks-handlers/task-hooks.js +50 -0
  279. package/dist/cli/commands/learning.js +5 -5
  280. package/dist/cli/commands/llm-router.js +1 -1
  281. package/dist/cli/commands/workflow.js +1 -0
  282. package/dist/coordination/consensus/providers/native-learning-provider.d.ts +1 -1
  283. package/dist/coordination/consensus/providers/ollama-provider.d.ts +1 -1
  284. package/dist/coordination/consensus/providers/openrouter-provider.d.ts +1 -1
  285. package/dist/coordination/handlers/code-intelligence-handlers.js +6 -0
  286. package/dist/coordination/mincut/neural-goap.js +24 -20
  287. package/dist/coordination/protocols/code-intelligence-index.js +31 -25
  288. package/dist/coordination/queen-coordinator.js +4 -0
  289. package/dist/coordination/queen-work-stealing.js +1 -2
  290. package/dist/domains/chaos-resilience/coordinator.js +19 -15
  291. package/dist/domains/chaos-resilience/services/chaos-engineer.js +5 -2
  292. package/dist/domains/chaos-resilience/services/load-tester.js +15 -11
  293. package/dist/domains/code-intelligence/interfaces.d.ts +5 -0
  294. package/dist/domains/code-intelligence/services/c4-model/index.js +12 -6
  295. package/dist/domains/code-intelligence/services/impact-analyzer.js +6 -2
  296. package/dist/domains/code-intelligence/services/knowledge-graph.d.ts +42 -0
  297. package/dist/domains/code-intelligence/services/knowledge-graph.js +278 -93
  298. package/dist/domains/code-intelligence/services/semantic-analyzer.js +8 -2
  299. package/dist/domains/contract-testing/coordinator.js +1 -1
  300. package/dist/domains/coverage-analysis/coordinator.js +4 -2
  301. package/dist/domains/learning-optimization/coordinator.js +1 -0
  302. package/dist/domains/quality-assessment/coherence/gate-controller.js +32 -26
  303. package/dist/domains/requirements-validation/coordinator.js +1 -0
  304. package/dist/domains/test-execution/services/e2e/wait-condition-handler.js +1 -1
  305. package/dist/domains/test-execution/services/retry-handler.js +18 -12
  306. package/dist/domains/test-generation/coordinator.js +1 -1
  307. package/dist/domains/test-generation/services/pattern-matcher.js +7 -5
  308. package/dist/domains/test-generation/services/test-generator.js +3 -2
  309. package/dist/domains/visual-accessibility/coordinator.js +24 -20
  310. package/dist/index.d.ts +2 -2
  311. package/dist/index.js +2 -2
  312. package/dist/init/phases/12-verification.js +3 -3
  313. package/dist/integrations/agentic-flow/model-router/router.js +1 -1
  314. package/dist/integrations/embeddings/base/EmbeddingGenerator.js +11 -7
  315. package/dist/integrations/ruvector/hypergraph-engine.js +2 -2
  316. package/dist/integrations/ruvector/shared-rvf-adapter.js +12 -1
  317. package/dist/integrations/ruvector/shared-rvf-dual-writer.js +6 -2
  318. package/dist/integrations/ruvector/spectral-math.js +2 -2
  319. package/dist/integrations/ruvector/spectral-sparsifier.js +1 -1
  320. package/dist/kernel/kernel.js +1 -1
  321. package/dist/kernel/project-root.d.ts +33 -0
  322. package/dist/kernel/project-root.js +86 -0
  323. package/dist/kernel/unified-memory-hnsw.js +1 -0
  324. package/dist/kernel/unified-memory.d.ts +2 -19
  325. package/dist/kernel/unified-memory.js +8 -64
  326. package/dist/learning/experience-capture.js +1 -1
  327. package/dist/learning/local-judge-client.d.ts +55 -0
  328. package/dist/learning/local-judge-client.js +127 -0
  329. package/dist/learning/nagual-client.d.ts +73 -0
  330. package/dist/learning/nagual-client.js +150 -0
  331. package/dist/learning/pattern-store.js +10 -3
  332. package/dist/learning/qe-reasoning-bank.js +9 -1
  333. package/dist/learning/qe-unified-memory.js +8 -6
  334. package/dist/mcp/bundle.js +405 -403
  335. package/dist/mcp/entry.js +44 -33
  336. package/dist/mcp/handlers/core-handlers.js +2 -2
  337. package/dist/mcp/handlers/cross-phase-handlers.js +5 -3
  338. package/dist/mcp/handlers/handler-factory.d.ts +5 -0
  339. package/dist/mcp/handlers/handler-factory.js +44 -4
  340. package/dist/mcp/http-server.js +1 -0
  341. package/dist/mcp/protocol-server.js +2 -2
  342. package/dist/mcp/tools/code-intelligence/analyze.js +1 -1
  343. package/dist/mcp/tools/learning-optimization/optimize.js +1 -1
  344. package/dist/mcp/tools/qx-analysis/heuristics-engine.js +195 -173
  345. package/dist/mcp/tools/visual-accessibility/index.js +1 -1
  346. package/dist/mcp/transport/stdio.d.ts +7 -0
  347. package/dist/mcp/transport/stdio.js +39 -2
  348. package/dist/mcp/transport/websocket/websocket-transport.js +1 -0
  349. package/dist/optimization/auto-tuner.js +1 -1
  350. package/dist/planning/goap-planner.js +1 -0
  351. package/dist/routing/agent-dependency-graph.js +4 -1
  352. package/dist/shared/llm/router/config-store.js +1 -1
  353. package/dist/shared/metrics/system-metrics.js +6 -4
  354. package/dist/shared/parsers/tree-sitter-wasm-parser.d.ts +12 -0
  355. package/dist/shared/parsers/tree-sitter-wasm-parser.js +35 -0
  356. package/dist/shared/parsers/treesitter-ts-extractor.d.ts +39 -0
  357. package/dist/shared/parsers/treesitter-ts-extractor.js +196 -0
  358. package/dist/shared/utils/safe-expression-evaluator.js +8 -5
  359. package/dist/sync/cloud/postgres-writer.js +2 -0
  360. package/dist/sync/readers/json-reader.js +1 -1
  361. package/dist/test-scheduling/git-aware/test-selector.js +1 -1
  362. package/dist/workers/daemon.js +2 -0
  363. package/dist/workers/quality-daemon/git-watcher.js +2 -0
  364. package/dist/workers/quality-daemon/index.js +28 -24
  365. package/dist/workers/worker-manager.js +4 -0
  366. package/package.json +5 -4
  367. package/dist/cli/chunks/adapter-CR6J5C76.js +0 -2
  368. package/dist/cli/chunks/aqe-learning-engine-2MNTHMB6.js +0 -2
  369. package/dist/cli/chunks/audit-ALRYPHGP.js +0 -3
  370. package/dist/cli/chunks/base-AOQNGMTL.js +0 -2
  371. package/dist/cli/chunks/browser-workflow-UJ4A2ZXO.js +0 -2
  372. package/dist/cli/chunks/chunk-7DKYCVJI.js +0 -2
  373. package/dist/cli/chunks/chunk-FO73PZVU.js +0 -2
  374. package/dist/cli/chunks/chunk-I677W5BT.js +0 -59
  375. package/dist/cli/chunks/chunk-IAZEDWRX.js +0 -2
  376. package/dist/cli/chunks/chunk-RNREAOY4.js +0 -2
  377. package/dist/cli/chunks/chunk-UWXH2UQK.js +0 -2
  378. package/dist/cli/chunks/chunk-ZQUXNG5X.js +0 -2
  379. package/dist/cli/chunks/client-RDPWGOSA.js +0 -2
  380. package/dist/cli/chunks/cross-domain-router-4K5ZVZEZ.js +0 -2
  381. package/dist/cli/chunks/daemon-M422U3ZA.js +0 -10
  382. package/dist/cli/chunks/dream-RPNWM7VS.js +0 -2
  383. package/dist/cli/chunks/heartbeat-scheduler-JBCXMMZO.js +0 -2
  384. package/dist/cli/chunks/hnsw-adapter-3SC2HZIG.js +0 -2
  385. package/dist/cli/chunks/hnsw-index-FQORAR6K.js +0 -2
  386. package/dist/cli/chunks/hooks-T4CBINAV.js +0 -248
  387. package/dist/cli/chunks/hybrid-router-6CBFDXPR.js +0 -2
  388. package/dist/cli/chunks/impact-analyzer-SOEFVZWG.js +0 -2
  389. package/dist/cli/chunks/init-wizard-3E4IU5M4.js +0 -2
  390. package/dist/cli/chunks/kernel-GFZP4G5J.js +0 -2
  391. package/dist/cli/chunks/knowledge-graph-BKRKBU26.js +0 -2
  392. package/dist/cli/chunks/llm-router-service-KE4IGZPP.js +0 -2
  393. package/dist/cli/chunks/load-test-VSYJV2AO.js +0 -2
  394. package/dist/cli/chunks/memory-backend-B72RGHRF.js +0 -2
  395. package/dist/cli/chunks/memory-handlers-NWCH7AUO.js +0 -2
  396. package/dist/cli/chunks/protocol-executor-V3F37FPO.js +0 -2
  397. package/dist/cli/chunks/provider-manager-2PN72TT6.js +0 -2
  398. package/dist/cli/chunks/qe-reasoning-bank-P665QNIR.js +0 -2
  399. package/dist/cli/chunks/queen-coordinator-XD4F7BGB.js +0 -2
  400. package/dist/cli/chunks/router-4SSNWDJC.js +0 -2
  401. package/dist/cli/chunks/routing-feedback-O2JSIBW6.js +0 -2
  402. package/dist/cli/chunks/rvf-native-adapter-WIUHYXRB.js +0 -2
  403. package/dist/cli/chunks/safe-db-WL5Y7ZNS.js +0 -2
  404. package/dist/cli/chunks/schedule-U7QDGU5A.js +0 -2
  405. package/dist/cli/chunks/scheduler-LXKGQYXA.js +0 -2
  406. package/dist/cli/chunks/shared-rvf-adapter-4IZOJL33.js +0 -2
  407. package/dist/cli/chunks/sqlite-persistence-4KFO3SEB.js +0 -2
  408. package/dist/cli/chunks/sync-ARDDLQBS.js +0 -2
  409. package/dist/cli/chunks/token-bootstrap-KL2QIQ36.js +0 -2
  410. package/dist/cli/chunks/tree-sitter-wasm-parser-QJOKHOIW.js +0 -2
  411. package/dist/cli/chunks/unified-memory-7AS4LIEF.js +0 -2
  412. package/dist/cli/chunks/unified-memory-hnsw-GREESNJX.js +0 -2
  413. package/dist/cli/chunks/unified-persistence-BPJOMZOA.js +0 -2
  414. package/dist/cli/chunks/validate-swarm-SKKWRP2H.js +0 -14
  415. package/dist/cli/chunks/visual-security-BW662FHQ.js +0 -2
  416. package/dist/cli/chunks/witness-chain-OXVDLNVT.js +0 -2
  417. package/dist/cli/chunks/workflow-orchestrator-KKNR46XV.js +0 -2
  418. package/dist/cli/chunks/wrappers-37NLMKPE.js +0 -2
@@ -1027,6 +1027,41 @@ export function isWasmAvailable() {
1027
1027
  return false;
1028
1028
  }
1029
1029
  }
1030
+ // Cache of loaded grammars keyed by wasm filename, for the generic loader below.
1031
+ const loadedGrammarsByFile = new Map();
1032
+ /**
1033
+ * Generic grammar loader for callers outside the GRAMMAR_CONFIG set (e.g. the
1034
+ * code-intelligence TS/JS extractor). Reuses the proven WASM init + grammar
1035
+ * path resolution. Returns a `parse(code)` that yields a tree-sitter tree
1036
+ * (caller must call `tree.delete()`), or null if WASM/grammar is unavailable so
1037
+ * the caller can fall back.
1038
+ */
1039
+ export async function loadWasmGrammar(wasmFile) {
1040
+ if (!isWasmAvailable())
1041
+ return null;
1042
+ try {
1043
+ await ensureTreeSitterInit();
1044
+ let language = loadedGrammarsByFile.get(wasmFile);
1045
+ if (!language) {
1046
+ language = await treeSitterModule.Language.load(resolveGrammarPath(wasmFile));
1047
+ loadedGrammarsByFile.set(wasmFile, language);
1048
+ }
1049
+ return {
1050
+ parse: (code) => {
1051
+ // New parser per call (cheap) to avoid cross-call setLanguage races.
1052
+ const ParserCtor = treeSitterModule.Parser ?? treeSitterModule;
1053
+ const parser = new ParserCtor();
1054
+ parser.setLanguage(language);
1055
+ const tree = parser.parse(code);
1056
+ parser.delete?.();
1057
+ return tree;
1058
+ },
1059
+ };
1060
+ }
1061
+ catch {
1062
+ return null;
1063
+ }
1064
+ }
1030
1065
  /**
1031
1066
  * Reset internal state — for testing only.
1032
1067
  */
@@ -0,0 +1,39 @@
1
+ /**
2
+ * Tree-sitter TypeScript/JavaScript extractor for code-intelligence.
3
+ *
4
+ * Extracts functions, classes (+ methods), interfaces and imports from TS/JS/TSX
5
+ * source using bundled tree-sitter WASM grammars — so code-intelligence works
6
+ * WITHOUT the multi-megabyte `typescript` compiler dependency (#511).
7
+ *
8
+ * The KnowledgeGraphService uses this as a fallback when the TypeScript compiler
9
+ * API isn't available. Returns `null` when WASM/grammar can't load so the caller
10
+ * can degrade gracefully.
11
+ */
12
+ export interface TsFunction {
13
+ name: string;
14
+ startLine: number;
15
+ isAsync: boolean;
16
+ visibility: 'public' | 'private' | 'protected';
17
+ }
18
+ export interface TsClass {
19
+ name: string;
20
+ startLine: number;
21
+ methods: TsFunction[];
22
+ }
23
+ export interface TsInterface {
24
+ name: string;
25
+ startLine: number;
26
+ }
27
+ export interface TsExtraction {
28
+ functions: TsFunction[];
29
+ classes: TsClass[];
30
+ interfaces: TsInterface[];
31
+ imports: string[];
32
+ }
33
+ export declare function isTreeSitterTsExtension(ext: string): boolean;
34
+ /**
35
+ * Extract entities/imports from TS/JS/TSX source. Returns null if the grammar
36
+ * could not be loaded (WASM unavailable) so callers can fall back.
37
+ */
38
+ export declare function extractTsJs(content: string, extension: string): Promise<TsExtraction | null>;
39
+ //# sourceMappingURL=treesitter-ts-extractor.d.ts.map
@@ -0,0 +1,196 @@
1
+ /**
2
+ * Tree-sitter TypeScript/JavaScript extractor for code-intelligence.
3
+ *
4
+ * Extracts functions, classes (+ methods), interfaces and imports from TS/JS/TSX
5
+ * source using bundled tree-sitter WASM grammars — so code-intelligence works
6
+ * WITHOUT the multi-megabyte `typescript` compiler dependency (#511).
7
+ *
8
+ * The KnowledgeGraphService uses this as a fallback when the TypeScript compiler
9
+ * API isn't available. Returns `null` when WASM/grammar can't load so the caller
10
+ * can degrade gracefully.
11
+ */
12
+ import { loadWasmGrammar } from './tree-sitter-wasm-parser.js';
13
+ /** Map a file extension to its grammar wasm file. */
14
+ function grammarFor(ext) {
15
+ switch (ext) {
16
+ case 'ts':
17
+ case 'mts':
18
+ case 'cts':
19
+ return 'tree-sitter-typescript.wasm';
20
+ case 'tsx':
21
+ return 'tree-sitter-tsx.wasm';
22
+ case 'js':
23
+ case 'jsx':
24
+ case 'mjs':
25
+ case 'cjs':
26
+ return 'tree-sitter-javascript.wasm';
27
+ default:
28
+ return null;
29
+ }
30
+ }
31
+ export function isTreeSitterTsExtension(ext) {
32
+ return grammarFor(ext) !== null;
33
+ }
34
+ const line = (n) => n.startPosition.row + 1;
35
+ const fieldText = (n, field) => n.childForFieldName(field)?.text ?? '';
36
+ /** Whether a declaration node begins with the `async` keyword. */
37
+ function isAsync(n) {
38
+ for (let i = 0; i < n.childCount; i++) {
39
+ const c = n.child(i);
40
+ if (!c)
41
+ continue;
42
+ if (c.type === 'async')
43
+ return true;
44
+ // keyword precedes the function/method keyword; stop once we pass it
45
+ if (c.type === 'function' || c.type === 'function_declaration')
46
+ break;
47
+ }
48
+ return false;
49
+ }
50
+ function methodVisibility(n) {
51
+ for (let i = 0; i < n.childCount; i++) {
52
+ const t = n.child(i)?.type;
53
+ if (t === 'accessibility_modifier') {
54
+ const text = n.child(i).text;
55
+ if (text === 'private')
56
+ return 'private';
57
+ if (text === 'protected')
58
+ return 'protected';
59
+ }
60
+ }
61
+ return 'public';
62
+ }
63
+ function extractClass(node) {
64
+ const name = fieldText(node, 'name') || '(anonymous)';
65
+ const body = node.childForFieldName('body');
66
+ const methods = [];
67
+ if (body) {
68
+ for (let i = 0; i < body.childCount; i++) {
69
+ const m = body.child(i);
70
+ if (m && m.type === 'method_definition') {
71
+ methods.push({
72
+ name: fieldText(m, 'name'),
73
+ startLine: line(m),
74
+ isAsync: isAsync(m),
75
+ visibility: methodVisibility(m),
76
+ });
77
+ }
78
+ }
79
+ }
80
+ return { name, startLine: line(node), methods };
81
+ }
82
+ /** Strip surrounding quotes from an import source literal. */
83
+ function unquote(s) {
84
+ return s.replace(/^['"`]|['"`]$/g, '');
85
+ }
86
+ /**
87
+ * Extract entities/imports from TS/JS/TSX source. Returns null if the grammar
88
+ * could not be loaded (WASM unavailable) so callers can fall back.
89
+ */
90
+ export async function extractTsJs(content, extension) {
91
+ const wasmFile = grammarFor(extension);
92
+ if (!wasmFile)
93
+ return null;
94
+ const grammar = await loadWasmGrammar(wasmFile);
95
+ if (!grammar)
96
+ return null;
97
+ let tree = null;
98
+ try {
99
+ const parsed = grammar.parse(content);
100
+ tree = parsed;
101
+ const root = parsed.rootNode;
102
+ if (!root)
103
+ return null;
104
+ const out = { functions: [], classes: [], interfaces: [], imports: [] };
105
+ // Iterative walk. We do NOT recurse into function/class bodies (entities are
106
+ // top-level / exported; methods are collected with their class).
107
+ const stack = [root];
108
+ while (stack.length) {
109
+ const node = stack.pop();
110
+ let recurse = true;
111
+ switch (node.type) {
112
+ case 'function_declaration':
113
+ case 'generator_function_declaration':
114
+ out.functions.push({
115
+ name: fieldText(node, 'name'),
116
+ startLine: line(node),
117
+ isAsync: isAsync(node),
118
+ visibility: 'public',
119
+ });
120
+ recurse = false;
121
+ break;
122
+ case 'class_declaration':
123
+ case 'class':
124
+ out.classes.push(extractClass(node));
125
+ recurse = false;
126
+ break;
127
+ case 'interface_declaration':
128
+ out.interfaces.push({ name: fieldText(node, 'name'), startLine: line(node) });
129
+ recurse = false;
130
+ break;
131
+ case 'lexical_declaration':
132
+ case 'variable_declaration': {
133
+ // const/let foo = () => {} | function() {} → treat as a function
134
+ for (let i = 0; i < node.childCount; i++) {
135
+ const d = node.child(i);
136
+ if (!d || d.type !== 'variable_declarator')
137
+ continue;
138
+ const value = d.childForFieldName('value');
139
+ if (value && (value.type === 'arrow_function' ||
140
+ value.type === 'function' ||
141
+ value.type === 'function_expression')) {
142
+ out.functions.push({
143
+ name: fieldText(d, 'name'),
144
+ startLine: line(d),
145
+ isAsync: isAsync(value),
146
+ visibility: 'public',
147
+ });
148
+ }
149
+ else if (value && value.type === 'call_expression' &&
150
+ value.child(0)?.text === 'require') {
151
+ // const x = require('y')
152
+ const arg = value.childForFieldName('arguments')?.child(1);
153
+ if (arg && arg.type === 'string')
154
+ out.imports.push(unquote(arg.text));
155
+ }
156
+ }
157
+ recurse = false;
158
+ break;
159
+ }
160
+ case 'import_statement': {
161
+ const src = node.childForFieldName('source');
162
+ if (src)
163
+ out.imports.push(unquote(src.text));
164
+ recurse = false;
165
+ break;
166
+ }
167
+ case 'call_expression': {
168
+ // require('x')
169
+ const fn = node.child(0);
170
+ if (fn && fn.text === 'require') {
171
+ const args = node.childForFieldName('arguments');
172
+ const arg = args?.child(1); // ( <string> )
173
+ if (arg && (arg.type === 'string'))
174
+ out.imports.push(unquote(arg.text));
175
+ }
176
+ break;
177
+ }
178
+ }
179
+ if (recurse) {
180
+ for (let i = node.childCount - 1; i >= 0; i--) {
181
+ const c = node.child(i);
182
+ if (c)
183
+ stack.push(c);
184
+ }
185
+ }
186
+ }
187
+ return out;
188
+ }
189
+ catch {
190
+ return null;
191
+ }
192
+ finally {
193
+ tree?.delete?.();
194
+ }
195
+ }
196
+ //# sourceMappingURL=treesitter-ts-extractor.js.map
@@ -192,6 +192,7 @@ class Parser {
192
192
  }
193
193
  parseExpression(minPrecedence) {
194
194
  let left = this.parseUnary();
195
+ // eslint-disable-next-line no-constant-condition -- tokenizer loop; breaks internally
195
196
  while (true) {
196
197
  const token = this.current();
197
198
  if (token.type !== 'OPERATOR' || !BINARY_OPERATORS.has(token.value)) {
@@ -229,17 +230,19 @@ class Parser {
229
230
  case 'IDENTIFIER':
230
231
  return this.parseIdentifier();
231
232
  case 'LPAREN':
232
- this.advance();
233
- const result = this.parseExpression(0);
234
- this.expect('RPAREN');
235
- return result;
233
+ {
234
+ this.advance();
235
+ const result = this.parseExpression(0);
236
+ this.expect('RPAREN');
237
+ return result;
238
+ }
236
239
  default:
237
240
  throw new Error(`Unexpected token: ${token.raw}`);
238
241
  }
239
242
  }
240
243
  parseIdentifier() {
241
244
  let value = this.context;
242
- let name = this.advance().value;
245
+ const name = this.advance().value;
243
246
  // Get initial value from context
244
247
  if (typeof value === 'object' && value !== null && name in value) {
245
248
  value = value[name];
@@ -285,6 +285,7 @@ export class PostgresWriter {
285
285
  let jsonStr = JSON.stringify(value);
286
286
  if (columnName && this.isJsonbColumn(columnName)) {
287
287
  // Remove NUL chars (PostgreSQL JSONB rejects \u0000)
288
+ // eslint-disable-next-line no-control-regex -- NUL stripping required: PostgreSQL JSONB rejects \u0000
288
289
  jsonStr = jsonStr.replace(/\u0000/g, '');
289
290
  try {
290
291
  JSON.parse(jsonStr);
@@ -316,6 +317,7 @@ export class PostgresWriter {
316
317
  }
317
318
  // JSONB columns: validate JSON, sanitize NUL chars, wrap if invalid
318
319
  if (columnName && this.isJsonbColumn(columnName)) {
320
+ // eslint-disable-next-line no-control-regex -- NUL stripping required: PostgreSQL JSONB rejects \u0000
319
321
  const sanitized = value.replace(/\u0000/g, '');
320
322
  try {
321
323
  JSON.parse(sanitized);
@@ -50,7 +50,7 @@ export class JSONReader {
50
50
  const content = fs.readFileSync(this.filePath, 'utf-8');
51
51
  const parsed = secureJsonParse.parse(content);
52
52
  // Extract data based on JSON path if specified
53
- let records = this.extractRecords(parsed);
53
+ const records = this.extractRecords(parsed);
54
54
  // Transform records
55
55
  return records.map(record => this.transformRecord(record));
56
56
  }
@@ -191,7 +191,7 @@ export class GitAwareTestSelector {
191
191
  async mapChangesToTests(changedFiles) {
192
192
  const selectedTests = [];
193
193
  const mappings = [];
194
- let runAllTests = false;
194
+ const runAllTests = false;
195
195
  let runAllReason;
196
196
  // Check for config file changes first - these require full test run
197
197
  for (const file of changedFiles) {
@@ -56,6 +56,8 @@ export class QEDaemon {
56
56
  this._healthCheckTimer = setInterval(() => {
57
57
  this.performHealthCheck();
58
58
  }, this.config.healthCheckIntervalMs);
59
+ // Issue #513: never keep an orphaned process alive on the health timer alone.
60
+ this._healthCheckTimer.unref?.();
59
61
  // Auto-start workers if configured
60
62
  if (this.config.autoStart) {
61
63
  await this.workerManager.startAll();
@@ -65,6 +65,8 @@ export class GitWatcher {
65
65
  console.debug('[GitWatcher] Poll error:', err);
66
66
  });
67
67
  }, this.options.pollIntervalMs);
68
+ // Issue #513: don't keep an orphaned process alive on the git poll timer.
69
+ this.pollTimer.unref?.();
68
70
  }
69
71
  this._running = true;
70
72
  }
@@ -139,6 +139,8 @@ export class QualityDaemon {
139
139
  if (!this._running)
140
140
  return;
141
141
  this.tickTimer = setTimeout(() => this.tick(), this.config.tickIntervalMs);
142
+ // Issue #513: the tick loop must not keep an orphaned process alive on its own.
143
+ this.tickTimer.unref?.();
142
144
  }
143
145
  async tick() {
144
146
  if (!this._running || !this._memory)
@@ -185,35 +187,37 @@ export class QualityDaemon {
185
187
  const payload = item.payload;
186
188
  switch (payload.type) {
187
189
  case 'git_commit':
188
- this._commitsAnalyzed++;
189
- // Trigger coverage analysis for changed files
190
- const snapshot = await this.coverageDelta.buildSnapshot(memory);
191
- if (snapshot) {
192
- const delta = await this.coverageDelta.analyze(snapshot, memory, payload.changedFiles);
193
- if (delta.regressionDetected) {
194
- await this.notificationService.send({
195
- type: 'coverage_drop',
196
- title: 'Coverage Regression Detected',
197
- message: `Line coverage delta: ${delta.overallDelta.line.toFixed(1)}% (${delta.affectedFiles.length} files affected)`,
198
- severity: 'high',
199
- metadata: { delta: delta.overallDelta, commit: payload.commitHash },
200
- });
201
- }
202
- if (delta.newGaps.length > 0) {
203
- const suggestions = await this.testSuggester.suggest(delta.newGaps, payload.changedFiles, memory);
204
- this._suggestionsGenerated += suggestions.length;
205
- if (suggestions.length > 0) {
190
+ {
191
+ this._commitsAnalyzed++;
192
+ // Trigger coverage analysis for changed files
193
+ const snapshot = await this.coverageDelta.buildSnapshot(memory);
194
+ if (snapshot) {
195
+ const delta = await this.coverageDelta.analyze(snapshot, memory, payload.changedFiles);
196
+ if (delta.regressionDetected) {
206
197
  await this.notificationService.send({
207
- type: 'suggestion_available',
208
- title: 'New Test Suggestions Available',
209
- message: `${suggestions.length} test suggestions generated for uncovered code`,
210
- severity: 'info',
211
- metadata: { count: suggestions.length },
198
+ type: 'coverage_drop',
199
+ title: 'Coverage Regression Detected',
200
+ message: `Line coverage delta: ${delta.overallDelta.line.toFixed(1)}% (${delta.affectedFiles.length} files affected)`,
201
+ severity: 'high',
202
+ metadata: { delta: delta.overallDelta, commit: payload.commitHash },
212
203
  });
213
204
  }
205
+ if (delta.newGaps.length > 0) {
206
+ const suggestions = await this.testSuggester.suggest(delta.newGaps, payload.changedFiles, memory);
207
+ this._suggestionsGenerated += suggestions.length;
208
+ if (suggestions.length > 0) {
209
+ await this.notificationService.send({
210
+ type: 'suggestion_available',
211
+ title: 'New Test Suggestions Available',
212
+ message: `${suggestions.length} test suggestions generated for uncovered code`,
213
+ severity: 'info',
214
+ metadata: { count: suggestions.length },
215
+ });
216
+ }
217
+ }
214
218
  }
219
+ break;
215
220
  }
216
- break;
217
221
  case 'coverage_delta': {
218
222
  // coverage_delta items are enqueued by analyze() when regression/gaps
219
223
  // are found. The analysis itself was already completed by the
@@ -367,6 +367,10 @@ export class WorkerManagerImpl {
367
367
  this.scheduleNextRun(worker);
368
368
  }
369
369
  }, worker.config.intervalMs);
370
+ // Issue #513: don't let a background worker tick keep an orphaned process
371
+ // alive. The timer still fires while the process lives for other reasons;
372
+ // unref() only removes it as a standalone reason to stay running.
373
+ timer.unref?.();
370
374
  this.timers.set(worker.config.id, timer);
371
375
  }
372
376
  createContext(workerId, signal) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "agentic-qe",
3
- "version": "3.10.2",
3
+ "version": "3.10.4",
4
4
  "description": "Agentic Quality Engineering V3 - Domain-Driven Design Architecture with 13 Bounded Contexts, O(log n) coverage analysis, ReasoningBank learning, 60 specialized QE agents, mathematical Coherence verification, deep Claude Flow integration",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -139,13 +139,13 @@
139
139
  "author": "AQE Development Team",
140
140
  "license": "MIT",
141
141
  "dependencies": {
142
+ "@huggingface/transformers": "^4.2.0",
142
143
  "@ruvector/attention": "0.1.3",
143
144
  "@ruvector/gnn": "0.1.25",
144
145
  "@ruvector/learning-wasm": "^0.1.29",
145
146
  "@ruvector/router": "^0.1.28",
146
147
  "@ruvector/rvf-node": "^0.1.7",
147
148
  "@ruvector/sona": "0.1.5",
148
- "@huggingface/transformers": "^4.2.0",
149
149
  "axe-core": "^4.11.1",
150
150
  "better-sqlite3": "^12.5.0",
151
151
  "chalk": "^5.6.2",
@@ -176,7 +176,6 @@
176
176
  }
177
177
  },
178
178
  "optionalDependencies": {
179
- "hnswlib-node": "^3.0.0",
180
179
  "@ruvector/attention-darwin-arm64": "0.1.3",
181
180
  "@ruvector/attention-darwin-x64": "0.1.3",
182
181
  "@ruvector/attention-linux-arm64-gnu": "0.1.3",
@@ -190,6 +189,7 @@
190
189
  "@ruvector/gnn-linux-x64-gnu": "0.1.25",
191
190
  "@ruvector/gnn-linux-x64-musl": "npm:@ruvector/gnn-linux-x64-gnu@0.1.25",
192
191
  "@ruvector/tiny-dancer-linux-arm64-gnu": "^0.1.17",
192
+ "hnswlib-node": "^3.0.0",
193
193
  "rvlite": "^0.2.4"
194
194
  },
195
195
  "resolutions": {
@@ -211,6 +211,7 @@
211
211
  "@opentelemetry/exporter-prometheus": ">=0.217.0"
212
212
  },
213
213
  "devDependencies": {
214
+ "@claude-flow/guidance": "3.0.0-alpha.1",
214
215
  "@faker-js/faker": "^10.2.0",
215
216
  "@types/better-sqlite3": "^7.6.13",
216
217
  "@types/cli-progress": "^3.11.6",
@@ -218,13 +219,13 @@
218
219
  "@types/pg": "^8.16.0",
219
220
  "@types/uuid": "^10.0.0",
220
221
  "@types/ws": "^8.18.1",
221
- "@claude-flow/guidance": "3.0.0-alpha.1",
222
222
  "@typescript-eslint/eslint-plugin": "^8.59.3",
223
223
  "@typescript-eslint/parser": "^8.59.3",
224
224
  "@vitest/coverage-v8": "^4.0.16",
225
225
  "dotenv": "^17.2.3",
226
226
  "esbuild": "^0.28.0",
227
227
  "eslint": "^8.55.0",
228
+ "eslint-plugin-unused-imports": "^4.1.4",
228
229
  "glob": "^13.0.0",
229
230
  "msw": "^2.12.7",
230
231
  "tsx": "^4.21.0",
@@ -1,2 +0,0 @@
1
- import{createRequire as __cr}from"module";const require=__cr(import.meta.url);if(process.argv.includes('--version')||process.argv.includes('-v')){console.log("3.10.2");process.exit(0)}
2
- import{a,b,c}from"./chunk-NZO4WUSO.js";import"./chunk-AWFIEGR3.js";import"./chunk-HJORBNXW.js";import"./chunk-SW4OKUTC.js";import"./chunk-XPCNUX2U.js";import"./chunk-ORF2UKQH.js";export{a as AgentBoosterAdapter,b as createAgentBoosterAdapter,c as createAgentBoosterAdapterSync};
@@ -1,2 +0,0 @@
1
- import{createRequire as __cr}from"module";const require=__cr(import.meta.url);if(process.argv.includes('--version')||process.argv.includes('-v')){console.log("3.10.2");process.exit(0)}
2
- import{a,b,c,d,e,f}from"./chunk-EVCOCGVJ.js";import"./chunk-7Z46RDDV.js";import"./chunk-AV7KYE5P.js";import"./chunk-LQTWPSYL.js";import"./chunk-LZCBSFAU.js";import"./chunk-5PL7WTCU.js";import"./chunk-DMQPO43S.js";import"./chunk-THRTUW4Z.js";import"./chunk-ZGNZJJFF.js";import"./chunk-7DKYCVJI.js";import"./chunk-VSUTI4G6.js";import"./chunk-TJKDATEU.js";import"./chunk-SVYTN2GT.js";import"./chunk-AH7FXNFE.js";import"./chunk-L7VIX22Y.js";import"./chunk-5QHSLWLP.js";import"./chunk-SW4OKUTC.js";import"./chunk-CV2SBMBW.js";import"./chunk-IAZEDWRX.js";import"./chunk-JF53LRBL.js";import"./chunk-FPAW77XV.js";import"./chunk-XPCNUX2U.js";import"./chunk-AOI67HA3.js";import"./chunk-MCZHKXB4.js";import"./chunk-YI6GNRQM.js";import"./chunk-OXCEUR5F.js";import"./chunk-DRWGK3YO.js";import"./chunk-HHCYSAH3.js";import"./chunk-WNR2KAUH.js";import"./chunk-WDMPJ2M2.js";import"./chunk-IICTTDAA.js";import"./chunk-ON4D4TJ4.js";import"./chunk-ORF2UKQH.js";export{b as AQELearningEngine,a as DEFAULT_ENGINE_CONFIG,c as DEFAULT_META_LEARNING_CONFIG,d as MetaLearningEngine,e as createAQELearningEngine,f as createDefaultLearningEngine};
@@ -1,3 +0,0 @@
1
- import{createRequire as __cr}from"module";const require=__cr(import.meta.url);if(process.argv.includes('--version')||process.argv.includes('-v')){console.log("3.10.2");process.exit(0)}
2
- import{d as c,e as u,f as h,g as m}from"./chunk-4GTDW2XL.js";import{f as s,o as p}from"./chunk-L7VIX22Y.js";import"./chunk-5QHSLWLP.js";import"./chunk-SW4OKUTC.js";import"./chunk-IAZEDWRX.js";import"./chunk-JF53LRBL.js";import"./chunk-XPCNUX2U.js";import"./chunk-MCZHKXB4.js";import{p as l,q as d}from"./chunk-YI6GNRQM.js";import"./chunk-OXCEUR5F.js";import"./chunk-DRWGK3YO.js";import"./chunk-HHCYSAH3.js";import"./chunk-WNR2KAUH.js";import"./chunk-WDMPJ2M2.js";import"./chunk-IICTTDAA.js";import"./chunk-ON4D4TJ4.js";import{g as f}from"./chunk-ORF2UKQH.js";import{Command as g}from"commander";import a from"chalk";p();import{existsSync as y}from"node:fs";import b from"node:path";function C(n,i){let t=[];t.push(a.bold("Witness Chain Audit Verification")),t.push("");let e=i?a.green("ENABLED"):a.yellow("DISABLED");t.push(` Feature Flag: ${e}`),t.push(` Chain Length: ${n.length} receipts`);let r=n.valid?a.green("VALID"):a.red("BROKEN");return t.push(` Integrity: ${r}`),n.length>0&&t.push(` Last Hash: ${n.lastHash.slice(0,16)}...`),!n.valid&&n.brokenAt>=0&&(t.push(""),t.push(a.red(` Break detected at index ${n.brokenAt}`)),t.push(a.red(` ${n.message}`))),t.push(""),t.join(`
3
- `)}function x(){try{let n=s(),i=b.join(n,".agentic-qe","memory.db");if(!y(i))return null;let t=(d(),f(l)),e=new t(i),r=c(e),o=h(r);return e.close(),o}catch{return null}}async function A(n){let i=m(),e=(x()??u()).verifyChain(),r={featureEnabled:i,chainLength:e.length,integrity:e.valid,brokenAt:e.brokenAt,lastHash:e.lastHash,message:e.message};return n.format==="json"?console.log(JSON.stringify(r,null,2)):console.log(C(e,i)),r}function v(n,i,t){let e=new g("audit").description("Witness chain audit trail management");return e.command("verify").description("Verify witness chain integrity").option("-F, --format <format>","Output format (json|text)","text").action(async r=>{try{await A({format:r.format}),await i(0)}catch(o){console.error("Failed to verify witness chain:",o),await i(1)}}),e}export{v as createAuditCommand,C as formatVerificationText,A as handleAuditVerify};
@@ -1,2 +0,0 @@
1
- import{createRequire as __cr}from"module";const require=__cr(import.meta.url);if(process.argv.includes('--version')||process.argv.includes('-v')){console.log("3.10.2");process.exit(0)}
2
- import{a,b,c,d,e,f,g,h,i,j}from"./chunk-UWXH2UQK.js";import"./chunk-G5U6Q42D.js";import"./chunk-L7VIX22Y.js";import"./chunk-5QHSLWLP.js";import"./chunk-SW4OKUTC.js";import"./chunk-IAZEDWRX.js";import"./chunk-JF53LRBL.js";import"./chunk-XPCNUX2U.js";import"./chunk-AOI67HA3.js";import"./chunk-MCZHKXB4.js";import"./chunk-YI6GNRQM.js";import"./chunk-OXCEUR5F.js";import"./chunk-DRWGK3YO.js";import"./chunk-HHCYSAH3.js";import"./chunk-WNR2KAUH.js";import"./chunk-WDMPJ2M2.js";import"./chunk-IICTTDAA.js";import"./chunk-ON4D4TJ4.js";import"./chunk-ORF2UKQH.js";export{j as MCPToolBase,i as defaultToolLogger,h as getLLMRouter,d as getMemoryBackend,f as getSharedLLMRouter,b as getSharedMemoryBackend,a as registerRvfResetFn,g as resetSharedLLMRouter,c as resetSharedMemoryBackend,e as setSharedLLMRouter};
@@ -1,2 +0,0 @@
1
- import{createRequire as __cr}from"module";const require=__cr(import.meta.url);if(process.argv.includes('--version')||process.argv.includes('-v')){console.log("3.10.2");process.exit(0)}
2
- import{a}from"./chunk-4F3ZTXHP.js";import"./chunk-UWXH2UQK.js";import"./chunk-G5U6Q42D.js";import"./chunk-L7VIX22Y.js";import"./chunk-5QHSLWLP.js";import"./chunk-SW4OKUTC.js";import"./chunk-IAZEDWRX.js";import"./chunk-JF53LRBL.js";import"./chunk-XPCNUX2U.js";import"./chunk-AOI67HA3.js";import"./chunk-MCZHKXB4.js";import"./chunk-YI6GNRQM.js";import"./chunk-OXCEUR5F.js";import"./chunk-DRWGK3YO.js";import"./chunk-HHCYSAH3.js";import"./chunk-WNR2KAUH.js";import"./chunk-WDMPJ2M2.js";import"./chunk-IICTTDAA.js";import"./chunk-ON4D4TJ4.js";import"./chunk-ORF2UKQH.js";export{a as BrowserWorkflowTool};
@@ -1,2 +0,0 @@
1
- import{createRequire as __cr}from"module";const require=__cr(import.meta.url);if(process.argv.includes('--version')||process.argv.includes('-v')){console.log("3.10.2");process.exit(0)}
2
- import{e as b,f as y}from"./chunk-CV2SBMBW.js";import{a as m,c as v,e as g,g as h}from"./chunk-ORF2UKQH.js";var F={};g(F,{__setSharedRvfAdapterForTests:()=>S,compactSharedRvfAdapter:()=>$,decideCompactionFromStatus:()=>d,getSharedRvfAdapter:()=>C,resetSharedRvfAdapter:()=>B,runBootCompactGuard:()=>R});function S(e){s=e,u=e!==null}function C(e=".agentic-qe",r=384){if(u)return s;u=!0;try{let{isRvfNativeAvailable:t,createRvfStore:n,openRvfStore:o}=(y(),h(b));if(!t())return console.warn("[RVF] Native bindings unavailable \u2014 agent branching and dream COW disabled. Install @ruvector/rvf-node to enable."),null;let c=m("path").join(e,"patterns.rvf");return s=N(o,n,c,r),R(s,c),s}catch(t){return console.warn("[RVF] Shared adapter init failed:",t instanceof Error?t.message:t),null}}function N(e,r,t,n){let o=()=>{try{return{adapter:e(t),err:null}}catch(a){return{adapter:null,err:a}}},f=a=>{let i=a instanceof Error?a.message:String(a);return i.includes("LockHeld")||i.includes("0x0300")},{adapter:c,err:p}=o();if(!c&&f(p))try{let a=m("fs"),i=`${t}.lock`;a.existsSync(i)&&(a.unlinkSync(i),console.warn(`[RVF] Removed stale lock file at ${i} (prior process exited without closing). Retrying open. If you see this repeatedly under live concurrency, file an issue.`),{adapter:c,err:p}=o())}catch(a){process.env.DEBUG&&console.debug("[RVF] stale-lock recovery failed:",a instanceof Error?a.message:a)}if(c){let a=c.dimension();if(a===n)return c;console.warn(`[RVF] patterns.rvf dimension mismatch: file=${a} requested=${n} \u2014 closing and degrading. Delete the .rvf file to recreate at the requested dim.`);try{c.close()}catch{}throw new Error(`RVF dimension mismatch (file=${a}, requested=${n})`)}try{return r(t,n)}catch(a){try{let i=e(t);if(i.dimension()!==n){try{i.close()}catch{}throw new Error(`RVF dimension mismatch after race (file=${i.dimension()}, requested=${n})`)}return i}catch{throw a instanceof Error?a:new Error(String(a))}}}function d(e,r){if(r?.force)return{shouldCompact:!0,trigger:"force"};let t=r?.sizeGuardBytes??A,n=r?.deadRatioThreshold??E;return e.fileSizeBytes>=t?{shouldCompact:!0,trigger:"size-guard"}:(e.deadSpaceRatio??0)>=n?{shouldCompact:!0,trigger:"dead-ratio"}:{shouldCompact:!1,trigger:"none"}}function $(e){if(!s)return null;let r;try{r=s.status()}catch{return null}let t=d(r,e);if(!t.shouldCompact)return null;let n=r.fileSizeBytes,o;try{o=s.compact()}catch{return null}return o?((o.bytesReclaimed>0||o.segmentsCompacted>0)&&console.log(`[RVF] compacted patterns.rvf: reclaimed ${l(o.bytesReclaimed)} (${o.segmentsCompacted} segments, fileSize ${l(n)} \u2192 ${l(Math.max(0,n-o.bytesReclaimed))}, trigger: ${t.trigger})`),o):null}function R(e,r){try{let t=e.status(),n=d(t);if(!n.shouldCompact)return null;let o=e.compact();return o&&(o.bytesReclaimed>0||o.segmentsCompacted>0)&&console.log(`[RVF] boot-time compact (${r}): reclaimed ${l(o.bytesReclaimed)} from ${o.segmentsCompacted} segments (trigger: ${n.trigger})`),o}catch(t){return process.env.DEBUG&&console.debug("[RVF] boot-time compact guard skipped:",t instanceof Error?t.message:t),null}}function l(e){if(!Number.isFinite(e)||e<0)return`${e}B`;let r=["B","KB","MB","GB","TB"],t=0,n=e;for(;n>=1024&&t<r.length-1;)n/=1024,t++;return`${n.toFixed(t===0?0:1)}${r[t]}`}function B(){if(s){try{s.close()}catch{}s=null}u=!1}var s,u,A,E,w=v(()=>{s=null,u=!1;A=(()=>{let e=process.env.AQE_RVF_SIZE_GUARD_BYTES,r=e?Number(e):NaN;return Number.isFinite(r)&&r>0?r:256*1024*1024})(),E=(()=>{let e=process.env.AQE_RVF_DEAD_RATIO_THRESHOLD,r=e?Number(e):NaN;return Number.isFinite(r)&&r>0&&r<=1?r:.3})()});export{S as a,C as b,d as c,$ as d,R as e,B as f,F as g,w as h};
@@ -1,2 +0,0 @@
1
- import{createRequire as __cr}from"module";const require=__cr(import.meta.url);if(process.argv.includes('--version')||process.argv.includes('-v')){console.log("3.10.2");process.exit(0)}
2
- import{g}from"./chunk-I677W5BT.js";import{b as p,c as d}from"./chunk-FPAW77XV.js";import{b as m,c as f}from"./chunk-XPCNUX2U.js";import{i as h}from"./chunk-AOI67HA3.js";f();var I={maxDepth:5,riskWeights:{directImpact:.4,transitiveImpact:.2,testCoverage:.2,criticalPath:.15,dependencyCount:.05},testPatterns:["**/*.test.ts","**/*.test.tsx","**/*.spec.ts","**/*.spec.tsx","**/test_*.py","**/*_test.py","**/*_test.go"],criticalPaths:["**/auth/**","**/security/**","**/payment/**","**/api/**","**/core/**"],namespace:"code-intelligence:impact"},u=class{constructor(e,t,i={}){this.memory=e;this.config={...I,...i},this.knowledgeGraph=t||new g(e)}memory;config;knowledgeGraph;async analyzeImpact(e){try{let{changedFiles:t,depth:i=this.config.maxDepth,includeTests:n=!0}=e;if(t.length===0)return p({directImpact:[],transitiveImpact:[],impactedTests:[],riskLevel:"info",recommendations:[]});let r=await this.analyzeDirectImpact(t),l=await this.analyzeTransitiveImpact(t,r,i),s=[];if(n){let a=await this.getImpactedTests(t);a.success&&(s=a.value)}let c={directImpact:r,transitiveImpact:l,impactedTests:s,riskLevel:"info",recommendations:[]};return c.riskLevel=this.calculateRiskLevel(c),c.recommendations=this.getRecommendations(c),await this.storeAnalysis(t,c),p(c)}catch(t){return d(m(t))}}async getImpactedTests(e){try{let t=new Set;for(let i of e){if(this.isTestFile(i)){t.add(i);continue}let n=await this.knowledgeGraph.mapDependencies({files:[i],direction:"incoming",depth:3});if(n.success)for(let s of n.value.nodes)this.isTestFile(s.path)&&t.add(s.path);let r=this.getBaseName(i),l=[`${r}.test`,`${r}.spec`,`test_${r}`,`${r}_test`];for(let s of l){let c=await this.memory.search(`code-intelligence:kg:node:*${s}*`,10);for(let a of c){let o=await this.memory.get(a);o?.properties?.path&&this.isTestFile(o.properties.path)&&t.add(o.properties.path)}}}return p(Array.from(t))}catch(t){return d(m(t))}}calculateRiskLevel(e){let t=this.config.riskWeights,i=0,n=Math.min(1,e.directImpact.length/10);i+=n*t.directImpact;let r=Math.min(1,e.transitiveImpact.length/20);i+=r*t.transitiveImpact;let l=e.impactedTests.length>0?Math.max(0,1-e.impactedTests.length/(e.directImpact.length||1)):1;i+=l*t.testCoverage;let s=this.countCriticalFiles([...e.directImpact.map(o=>o.file),...e.transitiveImpact.map(o=>o.file)]),c=Math.min(1,s/5);i+=c*t.criticalPath;let a=this.calculateAverageRiskScore([...e.directImpact,...e.transitiveImpact]);return i+=a*t.dependencyCount,i>=.8?"critical":i>=.6?"high":i>=.4?"medium":i>=.2?"low":"info"}getRecommendations(e){let t=[];(e.riskLevel==="critical"||e.riskLevel==="high")&&t.push("This change has significant impact - consider peer review before merging"),e.impactedTests.length===0&&e.directImpact.length>0?t.push("No tests found for impacted files - add test coverage"):e.impactedTests.length<e.directImpact.length/2&&t.push("Test coverage appears low for impacted files"),e.impactedTests.length>0&&(e.impactedTests.length<=10?t.push(`Run these ${e.impactedTests.length} tests: ${e.impactedTests.slice(0,3).join(", ")}${e.impactedTests.length>3?"...":""}`):t.push(`Run all ${e.impactedTests.length} impacted tests before deployment`));let i=[...e.directImpact,...e.transitiveImpact].filter(r=>this.isCriticalPath(r.file));i.length>0&&t.push(`${i.length} critical path files affected - extra scrutiny recommended`),e.transitiveImpact.length>10&&t.push("Large transitive impact - consider breaking down into smaller changes");let n=[...e.directImpact,...e.transitiveImpact].filter(r=>r.riskScore>=.7);return n.length>0&&t.push(`${n.length} high-risk files impacted: ${n.slice(0,2).map(r=>this.getFileName(r.file)).join(", ")}`),t}async analyzeDirectImpact(e){let t=[];for(let i of e){let n=await this.knowledgeGraph.mapDependencies({files:[i],direction:"incoming",depth:1});if(n.success){let{nodes:r,edges:l}=n.value;for(let s of r){if(s.path===i)continue;let c=l.find(o=>o.target===s.id||o.source===s.id),a=this.calculateFileRiskScore(s.path,s.inDegree,s.outDegree);t.push({file:s.path,reason:`Directly ${c?.type||"depends on"} ${this.getFileName(i)}`,distance:1,riskScore:a})}}}return this.deduplicateImpact(t)}async analyzeTransitiveImpact(e,t,i){let n=[],r=new Set([...e,...t.map(s=>s.file)]),l=t.map(s=>({file:s.file,distance:1}));for(;l.length>0;){let s=l.shift();if(s.distance>=i)continue;let c=await this.knowledgeGraph.mapDependencies({files:[s.file],direction:"incoming",depth:1});if(c.success)for(let a of c.value.nodes){if(r.has(a.path)||a.path===s.file)continue;r.add(a.path);let o=this.calculateFileRiskScore(a.path,a.inDegree,a.outDegree,s.distance+1);n.push({file:a.path,reason:`Transitively depends via ${this.getFileName(s.file)}`,distance:s.distance+1,riskScore:o}),l.push({file:a.path,distance:s.distance+1})}}return this.deduplicateImpact(n)}calculateFileRiskScore(e,t,i,n=1){let r=0;return r+=Math.min(.3,t/20),r+=Math.min(.2,i/30),this.isCriticalPath(e)&&(r+=.3),this.isEntryPoint(e)&&(r+=.2),r=r*Math.pow(.8,n-1),Math.min(1,Math.max(0,r))}calculateAverageRiskScore(e){return e.length===0?0:e.reduce((i,n)=>i+n.riskScore,0)/e.length}countCriticalFiles(e){return e.filter(t=>this.isCriticalPath(t)).length}isTestFile(e){return[/\.test\.[tj]sx?$/,/\.spec\.[tj]sx?$/,/_test\.[tj]sx?$/,/test_.*\.py$/,/.*_test\.py$/,/.*_test\.go$/].some(i=>i.test(e))}isCriticalPath(e){return this.config.criticalPaths.map(i=>i.replace(/\*\*/g,".*").replace(/\*/g,"[^/]*")).some(i=>new RegExp(i).test(e))}isEntryPoint(e){return[/\/index\.[tj]sx?$/,/\/main\.[tj]sx?$/,/\/app\.[tj]sx?$/,/^src\/[^/]+\.[tj]sx?$/,/\/server\.[tj]sx?$/,/\/__init__\.py$/,/\/main\.go$/].some(i=>i.test(e))}getBaseName(e){return this.getFileName(e).replace(/\.[^.]+$/,"")}getFileName(e){return e.split(/[/\\]/).pop()||e}deduplicateImpact(e){let t=new Map;for(let i of e){let n=t.get(i.file);(!n||i.distance<n.distance)&&t.set(i.file,i)}return Array.from(t.values()).sort((i,n)=>n.riskScore!==i.riskScore?n.riskScore-i.riskScore:i.distance-n.distance)}async storeAnalysis(e,t){let i=h();await this.memory.set(`${this.config.namespace}:analysis:${i}`,{id:i,changedFiles:e,analysis:t,timestamp:new Date().toISOString()},{namespace:this.config.namespace,persist:!0})}};export{u as a};