agentic-qe 3.11.1 → 3.11.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (334) hide show
  1. package/.claude/skills/qe-code-intelligence/SKILL.md +3 -0
  2. package/.claude/skills/skills-manifest.json +1 -1
  3. package/CHANGELOG.md +35 -0
  4. package/README.md +1 -0
  5. package/assets/skills/qe-code-intelligence/SKILL.md +3 -0
  6. package/dist/cli/bundle.js +5 -5
  7. package/dist/cli/chunks/adapter-LDNYC4GH.js +2 -0
  8. package/dist/cli/chunks/{agent-booster-wasm-3OJAT664.js → agent-booster-wasm-FNCVODUJ.js} +2 -2
  9. package/dist/cli/chunks/{agent-handler-6TCTI5AT.js → agent-handler-JK7VK37B.js} +2 -2
  10. package/dist/cli/chunks/{agent-memory-branch-FAWCYEGJ.js → agent-memory-branch-EPVVJNNA.js} +2 -2
  11. package/dist/cli/chunks/aqe-learning-engine-CA4CT5Q7.js +2 -0
  12. package/dist/cli/chunks/{arena-O2TCUQBF.js → arena-EH2IMSRW.js} +4 -4
  13. package/dist/cli/chunks/{arena-UVYIGYUF.js → arena-NTHVDZTJ.js} +2 -2
  14. package/dist/cli/chunks/{audit-AYESKHAJ.js → audit-ODZV2T2B.js} +2 -2
  15. package/dist/cli/chunks/base-TSDAEMT4.js +2 -0
  16. package/dist/cli/chunks/{hnswlib-node-FUWQTM2D.js → better-sqlite3-5JTP47LA.js} +2 -2
  17. package/dist/cli/chunks/{brain-handler-KSJBVTHZ.js → brain-handler-NVB6OJ25.js} +3 -3
  18. package/dist/cli/chunks/{branch-enumerator-4O3S42EG.js → branch-enumerator-BIXSELMY.js} +2 -2
  19. package/dist/cli/chunks/{browser-5VXK323P.js → browser-S2Y2W33Z.js} +2 -2
  20. package/dist/cli/chunks/browser-workflow-3HCTJBLR.js +2 -0
  21. package/dist/cli/chunks/{chunk-XEVUW4QL.js → chunk-26ZMIYSK.js} +2 -2
  22. package/dist/cli/chunks/{chunk-7GP7ZG3K.js → chunk-27KNLVOY.js} +2 -2
  23. package/dist/cli/chunks/{chunk-5Y7GXQOM.js → chunk-2Q65LTJN.js} +2 -2
  24. package/dist/cli/chunks/{chunk-QOR4YAZY.js → chunk-3ATEYGVD.js} +2 -2
  25. package/dist/cli/chunks/{chunk-NVJIOCS5.js → chunk-3J3QXLWP.js} +2 -2
  26. package/dist/cli/chunks/{chunk-OUBYADPD.js → chunk-3KTOM7NN.js} +2 -2
  27. package/dist/cli/chunks/{chunk-EZBXCEBV.js → chunk-3NCVUFAL.js} +2 -2
  28. package/dist/cli/chunks/{chunk-2RE32VOF.js → chunk-42DCMEUM.js} +1 -1
  29. package/dist/cli/chunks/{chunk-ZRWAFMM7.js → chunk-4FTVTAMN.js} +2 -2
  30. package/dist/cli/chunks/{chunk-437XL5VZ.js → chunk-4PYJCIRO.js} +2 -2
  31. package/dist/cli/chunks/{chunk-4RUS5E3Q.js → chunk-527U4AHC.js} +2 -2
  32. package/dist/cli/chunks/{chunk-OX2PGDUM.js → chunk-5AFO7ZZG.js} +3 -3
  33. package/dist/cli/chunks/{chunk-S7IHSELP.js → chunk-5BDVFFYF.js} +2 -2
  34. package/dist/cli/chunks/{chunk-IAHJ62JS.js → chunk-5KMGG3QW.js} +4 -4
  35. package/dist/cli/chunks/{chunk-LNV76GGB.js → chunk-6LQIVIZB.js} +2 -2
  36. package/dist/cli/chunks/{chunk-FOD6JEEU.js → chunk-6SOGYNJG.js} +2 -2
  37. package/dist/cli/chunks/{chunk-5PSIKJL5.js → chunk-6VAFRS5N.js} +2 -2
  38. package/dist/cli/chunks/chunk-72VVTMEL.js +2 -0
  39. package/dist/cli/chunks/{chunk-SU4YXUVK.js → chunk-75C5GX7D.js} +2 -2
  40. package/dist/cli/chunks/{chunk-B6U56VWG.js → chunk-76RO2RHG.js} +1 -1
  41. package/dist/cli/chunks/{chunk-OUSD2RWO.js → chunk-7HYO76F2.js} +2 -2
  42. package/dist/cli/chunks/{chunk-PY4YQDBM.js → chunk-7KHZZVF2.js} +4 -4
  43. package/dist/cli/chunks/{chunk-NKCL6RAF.js → chunk-7MKF52GT.js} +2 -2
  44. package/dist/cli/chunks/{chunk-FK3XYV3A.js → chunk-7VM4ZUHT.js} +2 -2
  45. package/dist/cli/chunks/{chunk-VS2G6LX5.js → chunk-7XIQR6VU.js} +2 -2
  46. package/dist/cli/chunks/{chunk-OHBZON7T.js → chunk-A4ZDKF5F.js} +1 -1
  47. package/dist/cli/chunks/{chunk-K7XPKGOL.js → chunk-AAVUZVM6.js} +2 -2
  48. package/dist/cli/chunks/{chunk-44HXRFOP.js → chunk-AINAWVGD.js} +2 -2
  49. package/dist/cli/chunks/{chunk-P7CMWL7Y.js → chunk-AK5Q2WCJ.js} +2 -2
  50. package/dist/cli/chunks/{chunk-Z6ADE3KJ.js → chunk-AKZK46TQ.js} +2 -2
  51. package/dist/cli/chunks/{chunk-4UHWZ47M.js → chunk-ARUXFZDY.js} +1 -1
  52. package/dist/cli/chunks/{chunk-7DQLYWLR.js → chunk-AYXRT2ND.js} +1 -1
  53. package/dist/cli/chunks/{chunk-X2OVUBF6.js → chunk-AZQ6HDPM.js} +2 -2
  54. package/dist/cli/chunks/{chunk-CN2HMHIY.js → chunk-BGVEBYV4.js} +2 -2
  55. package/dist/cli/chunks/{chunk-LOPM3YIO.js → chunk-C6UTRG66.js} +2 -2
  56. package/dist/cli/chunks/{chunk-4OYC5TIZ.js → chunk-CAUTOCLZ.js} +2 -2
  57. package/dist/cli/chunks/{chunk-6WNYBIPS.js → chunk-CAVBEZV4.js} +2 -2
  58. package/dist/cli/chunks/{chunk-BOQNPFO5.js → chunk-CEMROADY.js} +1 -1
  59. package/dist/cli/chunks/{chunk-ATQTTGSE.js → chunk-CMVNYVKL.js} +2 -2
  60. package/dist/cli/chunks/{chunk-N52WQO3G.js → chunk-CUDGKSFX.js} +2 -2
  61. package/dist/cli/chunks/{chunk-X4GKYSOH.js → chunk-CZYSCUJ4.js} +2 -2
  62. package/dist/cli/chunks/{chunk-72UPBNVF.js → chunk-DMUQV2YU.js} +2 -2
  63. package/dist/cli/chunks/{chunk-BXLWERBR.js → chunk-DPFLJMEI.js} +3 -3
  64. package/dist/cli/chunks/{chunk-H5GCRC2D.js → chunk-DU4GQKTH.js} +2 -2
  65. package/dist/cli/chunks/{chunk-S7ZHD6VN.js → chunk-EDH4H55B.js} +2 -2
  66. package/dist/cli/chunks/{chunk-MILWEZSZ.js → chunk-EIWZDVMT.js} +3 -3
  67. package/dist/cli/chunks/{chunk-O5NF6BBD.js → chunk-FPZLOVEF.js} +1 -1
  68. package/dist/cli/chunks/{chunk-6CH7476R.js → chunk-FV53RMVB.js} +1 -1
  69. package/dist/cli/chunks/{chunk-QEDS3MOJ.js → chunk-FYY7OJ6Y.js} +2 -2
  70. package/dist/cli/chunks/{chunk-CXIFCN6G.js → chunk-G4CQBQBV.js} +1 -1
  71. package/dist/cli/chunks/{chunk-CZU5G6J4.js → chunk-G6LIQFT2.js} +1 -1
  72. package/dist/cli/chunks/{chunk-TUEDIQHY.js → chunk-H3LGBH4Y.js} +1 -1
  73. package/dist/cli/chunks/{chunk-BR4ERWVD.js → chunk-H4ZPPHOI.js} +2 -2
  74. package/dist/cli/chunks/{chunk-N6RSJGTW.js → chunk-H5TM4KIB.js} +2 -2
  75. package/dist/cli/chunks/{chunk-K3BBLIWW.js → chunk-H6MBRYA7.js} +2 -2
  76. package/dist/cli/chunks/{chunk-YFY35CSD.js → chunk-HDBJORV7.js} +2 -2
  77. package/dist/cli/chunks/{chunk-QXDZN2WX.js → chunk-I3AD523O.js} +1 -1
  78. package/dist/cli/chunks/{chunk-HOFEAA4R.js → chunk-I7UWFV6N.js} +1 -1
  79. package/dist/cli/chunks/{chunk-4BMPFEEG.js → chunk-IMPSB5WW.js} +2 -2
  80. package/dist/cli/chunks/{chunk-ILZHECWZ.js → chunk-IO7ZUP2G.js} +3 -3
  81. package/dist/cli/chunks/{chunk-QUTKELAS.js → chunk-IQOCTGA2.js} +2 -2
  82. package/dist/cli/chunks/{chunk-S456W64P.js → chunk-IXYF5BZY.js} +2 -2
  83. package/dist/cli/chunks/{chunk-B5EE63VE.js → chunk-JC4Z2ADP.js} +2 -2
  84. package/dist/cli/chunks/{chunk-IUVAWWQG.js → chunk-JCH2FHJ7.js} +2 -2
  85. package/dist/cli/chunks/{chunk-MX6M2VPB.js → chunk-JDFF2QMZ.js} +1 -1
  86. package/dist/cli/chunks/{chunk-EFRIMR74.js → chunk-JELN5XTK.js} +1 -1
  87. package/dist/cli/chunks/{chunk-3G25ZBQ6.js → chunk-JSZNI3AO.js} +1 -1
  88. package/dist/cli/chunks/{chunk-AEZMNFXM.js → chunk-K3YM2Z3E.js} +1 -1
  89. package/dist/cli/chunks/{chunk-QMN563LV.js → chunk-K426HTEQ.js} +44 -44
  90. package/dist/cli/chunks/{chunk-7OAKIXNM.js → chunk-K6IQBVD7.js} +2 -2
  91. package/dist/cli/chunks/{chunk-C7FYDE5F.js → chunk-KEJEZY2R.js} +125 -150
  92. package/dist/cli/chunks/{chunk-SZPTUV3B.js → chunk-KFE6LB4I.js} +2 -2
  93. package/dist/cli/chunks/{chunk-TOQJWLJV.js → chunk-KO3WB4SU.js} +2 -2
  94. package/dist/cli/chunks/{chunk-3IMEDZIS.js → chunk-LAY35POY.js} +3 -3
  95. package/dist/cli/chunks/{chunk-NYWK7ZSX.js → chunk-LFXXA325.js} +1 -1
  96. package/dist/cli/chunks/{chunk-IVZVVZZ3.js → chunk-LI3T5YNC.js} +3 -3
  97. package/dist/cli/chunks/{chunk-7SRSOZMP.js → chunk-LIEA5EON.js} +1 -1
  98. package/dist/cli/chunks/{chunk-76UVJLPM.js → chunk-LRJWKFGY.js} +2 -2
  99. package/dist/cli/chunks/{chunk-N6NSZG7Z.js → chunk-LY6PTRVL.js} +2 -2
  100. package/dist/cli/chunks/{chunk-L2QHZFC3.js → chunk-MAXOIEUG.js} +1 -1
  101. package/dist/cli/chunks/{chunk-7WQKKYYG.js → chunk-MN6W7ZNL.js} +1 -1
  102. package/dist/cli/chunks/{chunk-DZT4A7R3.js → chunk-NGE5YNKC.js} +2 -2
  103. package/dist/cli/chunks/{chunk-O75SVMMB.js → chunk-NIW4CLN2.js} +2 -2
  104. package/dist/cli/chunks/{chunk-BVFNF3RW.js → chunk-NPT7BYGF.js} +1 -1
  105. package/dist/cli/chunks/{chunk-CII57TME.js → chunk-NZNXEEZR.js} +1 -1
  106. package/dist/cli/chunks/{chunk-J2LAYCYZ.js → chunk-O3IIAIXB.js} +1 -1
  107. package/dist/cli/chunks/{chunk-3D4HNUZM.js → chunk-OC2W7KIW.js} +2 -2
  108. package/dist/cli/chunks/{chunk-ZKPOKMJZ.js → chunk-OFUF3APC.js} +2 -2
  109. package/dist/cli/chunks/{chunk-4G4GTF36.js → chunk-OU52V67H.js} +4 -4
  110. package/dist/cli/chunks/{chunk-5QFZEEJ2.js → chunk-P2RR4SW5.js} +3 -3
  111. package/dist/cli/chunks/{chunk-JGHEGMLD.js → chunk-P3VRXQ3H.js} +3 -3
  112. package/dist/cli/chunks/{chunk-KIBP3LGY.js → chunk-P5SGBQLY.js} +1 -1
  113. package/dist/cli/chunks/{chunk-5LDUW2FD.js → chunk-P7MIOTVP.js} +1 -1
  114. package/dist/cli/chunks/{chunk-VGR65B4Y.js → chunk-PFDILSVO.js} +1 -1
  115. package/dist/cli/chunks/{chunk-WIC5UZCQ.js → chunk-PPD5ZLNA.js} +2 -2
  116. package/dist/cli/chunks/{chunk-4565IIF6.js → chunk-QFJDR4HC.js} +2 -2
  117. package/dist/cli/chunks/{chunk-7QICU44H.js → chunk-QZ2GQGJX.js} +2 -2
  118. package/dist/cli/chunks/{chunk-EQYDPF52.js → chunk-QZLTIGLB.js} +1 -1
  119. package/dist/cli/chunks/{chunk-3V5DAM37.js → chunk-RHSUXQNF.js} +2 -2
  120. package/dist/cli/chunks/{chunk-HMVL55QX.js → chunk-S6BWEZKK.js} +2 -2
  121. package/dist/cli/chunks/{chunk-IIX5Y7BO.js → chunk-SE4S23C7.js} +1 -1
  122. package/dist/cli/chunks/{chunk-6ZAUNPAI.js → chunk-TOGZ37RL.js} +2 -2
  123. package/dist/cli/chunks/{chunk-D6MPGK7R.js → chunk-UCXW24HY.js} +2 -2
  124. package/dist/cli/chunks/{chunk-D4DAZ3P2.js → chunk-UQ6WB4N2.js} +2 -2
  125. package/dist/cli/chunks/{chunk-22FHOXEE.js → chunk-UQBGA4UA.js} +1 -1
  126. package/dist/cli/chunks/{chunk-UDLN2THT.js → chunk-VNFL2TPU.js} +1 -1
  127. package/dist/cli/chunks/{chunk-U5GCSSYX.js → chunk-WARFZ626.js} +1 -1
  128. package/dist/cli/chunks/{chunk-XMDZRULK.js → chunk-WEBHFIWS.js} +2 -2
  129. package/dist/cli/chunks/{chunk-N4OWZLH5.js → chunk-WKIYYF3G.js} +2 -2
  130. package/dist/cli/chunks/{chunk-3DS7ZHA7.js → chunk-WZC4HKGZ.js} +2 -2
  131. package/dist/cli/chunks/{chunk-T7PUM6OY.js → chunk-X36TZXDK.js} +1 -1
  132. package/dist/cli/chunks/{chunk-4S3UIY3G.js → chunk-XN4G3SRU.js} +2 -2
  133. package/dist/cli/chunks/{chunk-V6YDM37M.js → chunk-XNREA3FG.js} +1 -1
  134. package/dist/cli/chunks/{chunk-EJSDQQZH.js → chunk-XRDPGJNW.js} +2 -2
  135. package/dist/cli/chunks/{chunk-GUSW3OGX.js → chunk-XXCSJMSR.js} +1 -1
  136. package/dist/cli/chunks/{chunk-VRHLHGKR.js → chunk-XY2B2BEJ.js} +2 -2
  137. package/dist/cli/chunks/{chunk-CIDTFU3C.js → chunk-XY4JS3IZ.js} +2 -2
  138. package/dist/cli/chunks/{chunk-W6RS5S4Q.js → chunk-Y4M2HMPR.js} +2 -2
  139. package/dist/cli/chunks/{chunk-AG4BYKUV.js → chunk-YDPBCN7H.js} +2 -2
  140. package/dist/cli/chunks/{chunk-56PICCZN.js → chunk-YGR54EAA.js} +2 -2
  141. package/dist/cli/chunks/{chunk-6YNXH6H4.js → chunk-YGRY2TVI.js} +2 -2
  142. package/dist/cli/chunks/{chunk-H4V6WCF7.js → chunk-YJUJCLXV.js} +2 -2
  143. package/dist/cli/chunks/{chunk-KRUKMGPF.js → chunk-YWG4LHFU.js} +2 -2
  144. package/dist/cli/chunks/{chunk-FBOPSWF6.js → chunk-Z2QNTRUX.js} +2 -2
  145. package/dist/cli/chunks/{chunk-3XCEFSUK.js → chunk-ZBJMVWQR.js} +2 -2
  146. package/dist/cli/chunks/{chunk-C27UV6DO.js → chunk-ZH6HYT7C.js} +1 -1
  147. package/dist/cli/chunks/{chunk-WEPZOCN7.js → chunk-ZP2GE6DM.js} +1 -1
  148. package/dist/cli/chunks/{chunk-LSZLXLZA.js → chunk-ZQYEBLTL.js} +2 -2
  149. package/dist/cli/chunks/{chunk-AL54LED5.js → chunk-ZRU3OZEU.js} +2 -2
  150. package/dist/cli/chunks/{chunk-HYT5EMES.js → chunk-ZU3V4CJ4.js} +2 -2
  151. package/dist/cli/chunks/{chunk-TCKBICJ3.js → chunk-ZWMXF6AX.js} +2 -2
  152. package/dist/cli/chunks/{ci-KTWY7BZT.js → ci-SM3EVLZ4.js} +2 -2
  153. package/dist/cli/chunks/{ci-output-WOX6QBMS.js → ci-output-YYXICZBC.js} +2 -2
  154. package/dist/cli/chunks/{circuit-breaker-6XKOSFIF.js → circuit-breaker-CV5UGKXT.js} +2 -2
  155. package/dist/cli/chunks/{claude-flow-setup-5JA4MNE4.js → claude-flow-setup-BSBUZ4B7.js} +2 -2
  156. package/dist/cli/chunks/client-WRDYZGM2.js +2 -0
  157. package/dist/cli/chunks/{cline-installer-Z2ANHEKW.js → cline-installer-P2O6STIC.js} +2 -2
  158. package/dist/cli/chunks/code-M7DDLBGS.js +58 -0
  159. package/dist/cli/chunks/{code-index-extractor-VV4OEPG7.js → code-index-extractor-3QZIUYOG.js} +2 -2
  160. package/dist/cli/chunks/{codex-installer-BP7Y2NYR.js → codex-installer-5JVZCCTC.js} +2 -2
  161. package/dist/cli/chunks/{completions-YULJQUF4.js → completions-EM7IL2BJ.js} +8 -5
  162. package/dist/cli/chunks/{complexity-analyzer-D7XYPQ76.js → complexity-analyzer-VJXVB2CV.js} +2 -2
  163. package/dist/cli/chunks/{continuedev-installer-E3L7UF72.js → continuedev-installer-RCKJIAEC.js} +2 -2
  164. package/dist/cli/chunks/{copilot-installer-5TRUMJC5.js → copilot-installer-DZ7LTDOZ.js} +2 -2
  165. package/dist/cli/chunks/core-handlers-O6E5DNHT.js +2 -0
  166. package/dist/cli/chunks/{cost-tracker-QTYSJMSV.js → cost-tracker-QLOLXVAM.js} +2 -2
  167. package/dist/cli/chunks/{coverage-D5DKZ3XT.js → coverage-LYHTLWRV.js} +3 -3
  168. package/dist/cli/chunks/cross-domain-router-EV7LQMDO.js +2 -0
  169. package/dist/cli/chunks/{cursor-installer-UDBHGUIG.js → cursor-installer-PSIZ3Y53.js} +2 -2
  170. package/dist/cli/chunks/{daemon-IVWUMQKL.js → daemon-IYDTMA5M.js} +4 -4
  171. package/dist/cli/chunks/{daemon-2GXYN7F7.js → daemon-YLOAXM4X.js} +3 -3
  172. package/dist/cli/chunks/{dag-attention-scheduler-PWXR4QTU.js → dag-attention-scheduler-I2UIO3Z7.js} +2 -2
  173. package/dist/cli/chunks/{detect-C6P7ONFB.js → detect-ZXQ7X7GZ.js} +2 -2
  174. package/dist/cli/chunks/{dist-node-2BUFM2JK.js → dist-node-GK6OZX4H.js} +2 -2
  175. package/dist/cli/chunks/{domain-handler-Q2GWZLDM.js → domain-handler-NS3IBLRQ.js} +2 -2
  176. package/dist/cli/chunks/{domain-transfer-GMUBAM3J.js → domain-transfer-5G4RZEWF.js} +2 -2
  177. package/dist/cli/chunks/dream-E4C236UL.js +2 -0
  178. package/dist/cli/chunks/{embed-and-insert-pattern-EFUERRM2.js → embed-and-insert-pattern-V4JJUFR6.js} +2 -2
  179. package/dist/cli/chunks/{eval-24FIC43F.js → eval-7Q6PPYKR.js} +2 -2
  180. package/dist/cli/chunks/{experience-capture-middleware-R4UP2Q2M.js → experience-capture-middleware-DUBKSYFM.js} +3 -3
  181. package/dist/cli/chunks/{fast-paths-RQCGGTXB.js → fast-paths-IDPPMBUW.js} +2 -2
  182. package/dist/cli/chunks/{feature-flags-SOXVYIBN.js → feature-flags-EPTMAAKA.js} +2 -2
  183. package/dist/cli/chunks/{feature-flags-APTWWVNQ.js → feature-flags-KXI6FDY7.js} +2 -2
  184. package/dist/cli/chunks/{file-discovery-66KRMXVF.js → file-discovery-EDX2OJO7.js} +2 -2
  185. package/dist/cli/chunks/{fleet-EMBNKO5Q.js → fleet-67BO3LJ4.js} +3 -3
  186. package/dist/cli/chunks/{gnn-wrapper-6TKDWFJF.js → gnn-wrapper-YARORYT7.js} +2 -2
  187. package/dist/cli/chunks/{heartbeat-handler-4ODKJ75H.js → heartbeat-handler-K3JGPBYR.js} +4 -4
  188. package/dist/cli/chunks/heartbeat-scheduler-WMADLDKT.js +2 -0
  189. package/dist/cli/chunks/hnsw-adapter-STRDGJ65.js +2 -0
  190. package/dist/cli/chunks/hnsw-index-DBHX3TSC.js +2 -0
  191. package/dist/cli/chunks/{hnsw-legacy-bridge-25KFCLUC.js → hnsw-legacy-bridge-CDDRSV5E.js} +2 -2
  192. package/dist/cli/chunks/{better-sqlite3-MJNUEPYB.js → hnswlib-node-2KL54YUA.js} +2 -2
  193. package/dist/cli/chunks/{hooks-JIDA2COE.js → hooks-6SCAE6LC.js} +10 -10
  194. package/dist/cli/chunks/hybrid-router-L2K55I4T.js +2 -0
  195. package/dist/cli/chunks/{hypergraph-engine-3YDFDPE3.js → hypergraph-engine-I3LUMO7I.js} +2 -2
  196. package/dist/cli/chunks/{hypergraph-handler-VWZX2OJX.js → hypergraph-handler-YAKAIVCN.js} +3 -3
  197. package/dist/cli/chunks/impact-analyzer-WMO7ZGS7.js +2 -0
  198. package/dist/cli/chunks/{init-handler-DH7VQAMF.js → init-handler-NBKCZD7Q.js} +6 -6
  199. package/dist/cli/chunks/init-wizard-ZAB7UZZS.js +2 -0
  200. package/dist/cli/chunks/kernel-4MUFDEQI.js +2 -0
  201. package/dist/cli/chunks/{kilocode-installer-2W2KZCGH.js → kilocode-installer-YGPJCPU3.js} +2 -2
  202. package/dist/cli/chunks/{kiro-installer-E5KP7OMD.js → kiro-installer-JV3ONVMN.js} +2 -2
  203. package/dist/cli/chunks/knowledge-graph-GZRFGXLX.js +2 -0
  204. package/dist/cli/chunks/{learning-XJRUVPLF.js → learning-2FEZJ5CX.js} +3 -3
  205. package/dist/cli/chunks/{llm-router-AEEKEMF5.js → llm-router-SILI4KLU.js} +4 -4
  206. package/dist/cli/chunks/llm-router-service-5ODLU5U5.js +2 -0
  207. package/dist/cli/chunks/{load-PZ4YOTBJ.js → load-EGXLQVR3.js} +2 -2
  208. package/dist/cli/chunks/load-test-ZDQFS5XS.js +2 -0
  209. package/dist/cli/chunks/{mcp-IVA6LC2S.js → mcp-OJH775TL.js} +2 -2
  210. package/dist/cli/chunks/{memory-Y3DHXFQE.js → memory-FNEOK4FW.js} +5 -5
  211. package/dist/cli/chunks/memory-backend-UK7SQ6ZM.js +2 -0
  212. package/dist/cli/chunks/{memory-handlers-V5PXEJWL.js → memory-handlers-6LDUH3JZ.js} +2 -2
  213. package/dist/cli/chunks/{multi-model-executor-646G4S4Y.js → multi-model-executor-ORTFWLLE.js} +2 -2
  214. package/dist/cli/chunks/{opencode-installer-P6KOOTUS.js → opencode-installer-UAQLW6XX.js} +2 -2
  215. package/dist/cli/chunks/{orchestrator-T2GVKYMX.js → orchestrator-VE5KJ2V4.js} +5 -5
  216. package/dist/cli/chunks/pattern-null-store-LO2QTIBU.js +2 -0
  217. package/dist/cli/chunks/{pipeline-CK2ON45P.js → pipeline-FNMDRWTU.js} +2 -2
  218. package/dist/cli/chunks/{platform-OQNSD3A3.js → platform-MGAKRUQN.js} +2 -2
  219. package/dist/cli/chunks/{plugin-UOG6RNRM.js → plugin-YX7THX3I.js} +2 -2
  220. package/dist/cli/chunks/{prime-radiant-advanced-wasm-37UE6TG5.js → prime-radiant-advanced-wasm-XJV4RLMK.js} +2 -2
  221. package/dist/cli/chunks/protocol-executor-JWMYQEOI.js +2 -0
  222. package/dist/cli/chunks/{protocol-handler-V722S6YH.js → protocol-handler-QFET442Y.js} +2 -2
  223. package/dist/cli/chunks/{prove-ANGY6W3W.js → prove-QBAESCOC.js} +2 -2
  224. package/dist/cli/chunks/provider-manager-PEXOHGNB.js +2 -0
  225. package/dist/cli/chunks/qe-reasoning-bank-7B2G4UGQ.js +2 -0
  226. package/dist/cli/chunks/{quality-KG4ALI2L.js → quality-ZTNRL6EG.js} +2 -2
  227. package/dist/cli/chunks/queen-coordinator-6OF4HT3S.js +2 -0
  228. package/dist/cli/chunks/{real-embeddings-GUZDO5UN.js → real-embeddings-ZFFDV6HC.js} +2 -2
  229. package/dist/cli/chunks/{roocode-installer-WROAR6MJ.js → roocode-installer-J4LFL4AE.js} +2 -2
  230. package/dist/cli/chunks/router-GMWRF6DU.js +2 -0
  231. package/dist/cli/chunks/routing-feedback-XKJSQK3I.js +2 -0
  232. package/dist/cli/chunks/{routing-handler-UFPSSS5D.js → routing-handler-A5QG2TP2.js} +2 -2
  233. package/dist/cli/chunks/{ruvector-commands-XJQMKDRM.js → ruvector-commands-J5JL5WX5.js} +2 -2
  234. package/dist/cli/chunks/{rvf-dual-writer-QPRMDKYX.js → rvf-dual-writer-H7442GMO.js} +2 -2
  235. package/dist/cli/chunks/{rvf-migration-adapter-SOHBK23K.js → rvf-migration-adapter-PTFQUYKC.js} +2 -2
  236. package/dist/cli/chunks/{rvf-migration-coordinator-MTWUSPEJ.js → rvf-migration-coordinator-RSNROYRX.js} +2 -2
  237. package/dist/cli/chunks/rvf-native-adapter-YEA6TMXB.js +2 -0
  238. package/dist/cli/chunks/safe-db-5DOP2J3V.js +2 -0
  239. package/dist/cli/chunks/schedule-SUWTOBHP.js +2 -0
  240. package/dist/cli/chunks/scheduler-P4VTC5SQ.js +2 -0
  241. package/dist/cli/chunks/{security-5MAMQKP6.js → security-LHHLMCBA.js} +3 -3
  242. package/dist/cli/chunks/{shared-rvf-adapter-YEUBSRNN.js → shared-rvf-adapter-NPSHVUTM.js} +2 -2
  243. package/dist/cli/chunks/{shared-rvf-dual-writer-DBQJHG42.js → shared-rvf-dual-writer-INQDY5WE.js} +2 -2
  244. package/dist/cli/chunks/sqlite-persistence-5Z2RAXH7.js +2 -0
  245. package/dist/cli/chunks/{status-handler-ZUB2UKQZ.js → status-handler-R2KIAMAE.js} +2 -2
  246. package/dist/cli/chunks/{structural-health-B2GHENWX.js → structural-health-2VPPIOZX.js} +2 -2
  247. package/dist/cli/chunks/{sync-7VMXJTR2.js → sync-ASZ3T5GT.js} +2 -2
  248. package/dist/cli/chunks/{sync-YCUUW3IP.js → sync-NLASP7AK.js} +2 -2
  249. package/dist/cli/chunks/{task-handler-N7LJTXZM.js → task-handler-UV5R6LJG.js} +2 -2
  250. package/dist/cli/chunks/{task-handlers-GDHNJV2E.js → task-handlers-I6YJXPYP.js} +3 -3
  251. package/dist/cli/chunks/{test-6COGC5KI.js → test-TE43TNTI.js} +4 -4
  252. package/dist/cli/chunks/{test-scheduling-CUERHJMF.js → test-scheduling-WWWWF2TZ.js} +3 -3
  253. package/dist/cli/chunks/{token-bootstrap-JTGSL6PP.js → token-bootstrap-HEWP7KKS.js} +2 -2
  254. package/dist/cli/chunks/{token-usage-LSG3JYGX.js → token-usage-3FVHUAW6.js} +2 -2
  255. package/dist/cli/chunks/{transformers-ODIITRCT.js → transformers-O5OFM4XM.js} +2 -2
  256. package/dist/cli/chunks/{tree-sitter-wasm-parser-KSP7ZZ5H.js → tree-sitter-wasm-parser-YOYWFW63.js} +2 -2
  257. package/dist/cli/chunks/{types-6N6SUU2O.js → types-42GR6PLO.js} +2 -2
  258. package/dist/cli/chunks/unified-memory-HCKOPFAY.js +2 -0
  259. package/dist/cli/chunks/unified-memory-hnsw-6NQPYA5C.js +2 -0
  260. package/dist/cli/chunks/unified-persistence-NIMKNAFR.js +2 -0
  261. package/dist/cli/chunks/{upgrade-7SCVOCPS.js → upgrade-BU6DJ4LT.js} +2 -2
  262. package/dist/cli/chunks/{validate-762ISH2Y.js → validate-MPTBARGN.js} +2 -2
  263. package/dist/cli/chunks/{validate-swarm-R6WYYXGO.js → validate-swarm-5LUQYHPP.js} +2 -2
  264. package/dist/cli/chunks/{vibium-5GZYSUDQ.js → vibium-MJJDANDL.js} +2 -2
  265. package/dist/cli/chunks/visual-security-HFGHA57Z.js +2 -0
  266. package/dist/cli/chunks/{web-tree-sitter-VYYVAJTY.js → web-tree-sitter-5TF4UGB3.js} +2 -2
  267. package/dist/cli/chunks/{windsurf-installer-RRIOR3B6.js → windsurf-installer-NQAOSVCN.js} +2 -2
  268. package/dist/cli/chunks/{witness-chain-SRVBEKDB.js → witness-chain-23UWK2JT.js} +2 -2
  269. package/dist/cli/chunks/witness-chain-VZGGJ7TJ.js +2 -0
  270. package/dist/cli/chunks/{workflow-XNUDHGEC.js → workflow-3QOLXRJC.js} +4 -4
  271. package/dist/cli/chunks/workflow-orchestrator-45L7D4SN.js +2 -0
  272. package/dist/cli/chunks/{wrappers-3STST7QW.js → wrappers-S6EUZBCX.js} +2 -2
  273. package/dist/cli/commands/code.js +78 -2
  274. package/dist/cli/completions/index.js +4 -1
  275. package/dist/domains/code-intelligence/coordinator.js +8 -4
  276. package/dist/domains/code-intelligence/services/c4-model/from-detected.d.ts +41 -0
  277. package/dist/domains/code-intelligence/services/c4-model/from-detected.js +152 -0
  278. package/dist/domains/code-intelligence/services/c4-model/kg-relationships.d.ts +71 -0
  279. package/dist/domains/code-intelligence/services/c4-model/kg-relationships.js +87 -0
  280. package/dist/domains/code-intelligence/services/knowledge-graph.d.ts +6 -0
  281. package/dist/domains/code-intelligence/services/knowledge-graph.js +3 -3
  282. package/dist/domains/code-intelligence/services/product-factors-bridge.d.ts +26 -5
  283. package/dist/domains/code-intelligence/services/product-factors-bridge.js +72 -65
  284. package/dist/mcp/bundle.js +429 -454
  285. package/dist/mcp/tools/code-intelligence/c4.d.ts +56 -0
  286. package/dist/mcp/tools/code-intelligence/c4.js +145 -0
  287. package/dist/mcp/tools/index.d.ts +1 -0
  288. package/dist/mcp/tools/index.js +1 -0
  289. package/dist/mcp/tools/registry.d.ts +1 -0
  290. package/dist/mcp/tools/registry.js +3 -0
  291. package/dist/shared/c4-model/confidence.d.ts +38 -0
  292. package/dist/shared/c4-model/confidence.js +69 -0
  293. package/dist/shared/c4-model/index.d.ts +4 -0
  294. package/dist/shared/c4-model/index.js +1 -0
  295. package/package.json +1 -1
  296. package/dist/cli/chunks/adapter-A6GCBONS.js +0 -2
  297. package/dist/cli/chunks/aqe-learning-engine-FRCSXNMG.js +0 -2
  298. package/dist/cli/chunks/base-CZ3EHBU5.js +0 -2
  299. package/dist/cli/chunks/browser-workflow-EKTGQQBQ.js +0 -2
  300. package/dist/cli/chunks/chunk-57WGS6BI.js +0 -2
  301. package/dist/cli/chunks/client-X3KUJ6R5.js +0 -2
  302. package/dist/cli/chunks/code-NO4ZKNDU.js +0 -39
  303. package/dist/cli/chunks/core-handlers-A2EQB3UH.js +0 -2
  304. package/dist/cli/chunks/cross-domain-router-OKZ2PDHT.js +0 -2
  305. package/dist/cli/chunks/dream-ZBP4Z5C3.js +0 -2
  306. package/dist/cli/chunks/heartbeat-scheduler-6JUWQXWG.js +0 -2
  307. package/dist/cli/chunks/hnsw-adapter-JT4BU7XJ.js +0 -2
  308. package/dist/cli/chunks/hnsw-index-JC5YELJX.js +0 -2
  309. package/dist/cli/chunks/hybrid-router-SLTXHUFG.js +0 -2
  310. package/dist/cli/chunks/impact-analyzer-JXHCMZXY.js +0 -2
  311. package/dist/cli/chunks/init-wizard-EX37TYOG.js +0 -2
  312. package/dist/cli/chunks/kernel-JPHAG27D.js +0 -2
  313. package/dist/cli/chunks/knowledge-graph-5QJZIRYB.js +0 -2
  314. package/dist/cli/chunks/llm-router-service-SE2RO4P5.js +0 -2
  315. package/dist/cli/chunks/load-test-LOTBWIIS.js +0 -2
  316. package/dist/cli/chunks/memory-backend-BSDKTFAN.js +0 -2
  317. package/dist/cli/chunks/pattern-null-store-LRSXCZWM.js +0 -2
  318. package/dist/cli/chunks/protocol-executor-WPUVJEL7.js +0 -2
  319. package/dist/cli/chunks/provider-manager-EVPWSH3E.js +0 -2
  320. package/dist/cli/chunks/qe-reasoning-bank-IH63FG33.js +0 -2
  321. package/dist/cli/chunks/queen-coordinator-TTCAGYQO.js +0 -2
  322. package/dist/cli/chunks/router-64Q4ILOQ.js +0 -2
  323. package/dist/cli/chunks/routing-feedback-KCZV4XXC.js +0 -2
  324. package/dist/cli/chunks/rvf-native-adapter-GNJKMURU.js +0 -2
  325. package/dist/cli/chunks/safe-db-6VBZQIJI.js +0 -2
  326. package/dist/cli/chunks/schedule-4V7O5IPX.js +0 -2
  327. package/dist/cli/chunks/scheduler-CQDMHEHN.js +0 -2
  328. package/dist/cli/chunks/sqlite-persistence-7DHUFTHL.js +0 -2
  329. package/dist/cli/chunks/unified-memory-MQA72NLP.js +0 -2
  330. package/dist/cli/chunks/unified-memory-hnsw-K7HA3CWV.js +0 -2
  331. package/dist/cli/chunks/unified-persistence-2DXB4OE4.js +0 -2
  332. package/dist/cli/chunks/visual-security-UD6CARIJ.js +0 -2
  333. package/dist/cli/chunks/witness-chain-LWALPPMC.js +0 -2
  334. package/dist/cli/chunks/workflow-orchestrator-QU652FLH.js +0 -2
@@ -1,2 +1,2 @@
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.11.1");process.exit(0)}
2
- import{a as l}from"./chunk-VGR65B4Y.js";import{a as m}from"./chunk-EQYDPF52.js";import{i as a}from"./chunk-B6U56VWG.js";var u=class{constructor(t,e){this.eventBus=t;this.maxHistorySize=e?.maxHistorySize??1e4,this.eventHistory=new l(this.maxHistorySize),this.correlationTimeout=e?.correlationTimeout??6e4,this.maxEventsPerCorrelation=e?.maxEventsPerCorrelation??100}eventBus;subscriptions=new Map;correlations=new Map;eventHistory;routes=[];domainSubscriptions=new Map;maxHistorySize;correlationTimeout;maxEventsPerCorrelation;initialized=!1;async initialize(){if(!this.initialized){for(let t of m){let e=this.eventBus.subscribeToChannel(t,async i=>{await this.handleIncomingEvent(i)});this.domainSubscriptions.set(t,e)}this.eventBus.subscribe("*",async t=>{m.includes(t.source)||await this.handleIncomingEvent(t)}),this.initialized=!0}}subscribeToDoamin(t,e){let i=`sub_domain_${a()}`;return this.subscriptions.set(i,{id:i,type:"domain",filter:t,handler:e,active:!0}),i}subscribeToEventType(t,e){let i=`sub_type_${a()}`;return this.subscriptions.set(i,{id:i,type:"eventType",filter:t,handler:e,active:!0}),i}unsubscribe(t){let e=this.subscriptions.get(t);return e?(e.active=!1,this.subscriptions.delete(t),!0):!1}async route(t){this.addToHistory(t),t.correlationId&&this.trackCorrelation(t);let i=this.findMatchingSubscriptions(t).map(async o=>{try{await o.handler(t)}catch(n){console.error(`Error in subscription handler ${o.id}:`,n instanceof Error?n.message:n)}}),r=await this.applyRoutes(t);await Promise.allSettled([...i,...r])}getCorrelation(t){let e=this.correlations.get(t);if(e)return{correlationId:e.correlationId,events:[...e.events],domains:new Set(e.domains),startedAt:e.startedAt,lastEventAt:e.lastEventAt,complete:e.complete}}trackCorrelation(t){if(!t.correlationId)return;let e=this.correlations.get(t.correlationId);e||(e={correlationId:t.correlationId,events:[],domains:new Set,startedAt:t.timestamp,lastEventAt:t.timestamp,complete:!1,timeout:null},this.correlations.set(t.correlationId,e)),e.events.length<this.maxEventsPerCorrelation&&(e.events.push(t),e.domains.add(t.source),e.lastEventAt=t.timestamp),e.timeout&&clearTimeout(e.timeout),e.timeout=setTimeout(()=>{e.complete=!0,e.timeout=null},this.correlationTimeout)}aggregate(t,e){let i=this.eventHistory.toArray().filter(s=>s.timestamp>=t&&s.timestamp<=e),r=new Map,o=new Map;for(let s of i)r.set(s.type,(r.get(s.type)??0)+1),o.set(s.source,(o.get(s.source)??0)+1);let n={totalEvents:i.length,uniqueEventTypes:r.size,uniqueDomains:o.size,eventsPerSecond:i.length>0?i.length/((e.getTime()-t.getTime())/1e3):0};return{id:a(),windowStart:t,windowEnd:e,events:i,countByType:r,countByDomain:o,metrics:n}}getHistory(t){let e=this.eventHistory.toArray();return t&&(t.eventTypes?.length&&(e=e.filter(i=>t.eventTypes.includes(i.type))),t.domains?.length&&(e=e.filter(i=>t.domains.includes(i.source))),t.fromTimestamp&&(e=e.filter(i=>i.timestamp>=t.fromTimestamp)),t.toTimestamp&&(e=e.filter(i=>i.timestamp<=t.toTimestamp)),t.limit&&(e=e.slice(-t.limit))),e}addRoute(t){let e=t.priority??0,i=this.routes.findIndex(r=>(r.priority??0)<e);i===-1?this.routes.push(t):this.routes.splice(i,0,t)}removeRoute(t,e){let i=this.routes.findIndex(r=>r.eventPattern===t&&(e===void 0||r.source===e));return i!==-1?(this.routes.splice(i,1),!0):!1}async dispose(){this.subscriptions.clear();for(let t of this.domainSubscriptions.values())t.unsubscribe();this.domainSubscriptions.clear();for(let t of this.correlations.values())t.timeout&&clearTimeout(t.timeout);this.correlations.clear(),this.eventHistory.clear(),this.initialized=!1}async handleIncomingEvent(t){await this.route(t)}findMatchingSubscriptions(t){let e=[];for(let i of this.subscriptions.values())i.active&&(i.type==="domain"&&i.filter===t.source||i.type==="eventType"&&this.matchEventType(t.type,i.filter))&&e.push(i);return e}matchEventType(t,e){if(e==="*")return!0;let i=e.replace(/\\/g,"\\\\").replace(/\./g,"\\.").replace(/\*/g,".*");return new RegExp(`^${i}$`).test(t)}async applyRoutes(t){let e=[];for(let i of this.routes){if(!(i.source==="*"||i.source===t.source||Array.isArray(i.source)&&i.source.includes(t.source))||!this.matchEventType(t.type,i.eventPattern)||i.filter&&!i.filter(t))continue;let o=i.transform?i.transform(t):t;for(let n of i.targets)n!==t.source&&e.push(this.eventBus.publish({...o,id:a(),correlationId:t.correlationId??t.id}))}return e}addToHistory(t){this.eventHistory.push(t)}};function y(c,t){return new u(c,t)}export{u as a,y as b};
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.11.2");process.exit(0)}
2
+ import{a as l}from"./chunk-PFDILSVO.js";import{a as m}from"./chunk-QZLTIGLB.js";import{i as a}from"./chunk-76RO2RHG.js";var u=class{constructor(t,e){this.eventBus=t;this.maxHistorySize=e?.maxHistorySize??1e4,this.eventHistory=new l(this.maxHistorySize),this.correlationTimeout=e?.correlationTimeout??6e4,this.maxEventsPerCorrelation=e?.maxEventsPerCorrelation??100}eventBus;subscriptions=new Map;correlations=new Map;eventHistory;routes=[];domainSubscriptions=new Map;maxHistorySize;correlationTimeout;maxEventsPerCorrelation;initialized=!1;async initialize(){if(!this.initialized){for(let t of m){let e=this.eventBus.subscribeToChannel(t,async i=>{await this.handleIncomingEvent(i)});this.domainSubscriptions.set(t,e)}this.eventBus.subscribe("*",async t=>{m.includes(t.source)||await this.handleIncomingEvent(t)}),this.initialized=!0}}subscribeToDoamin(t,e){let i=`sub_domain_${a()}`;return this.subscriptions.set(i,{id:i,type:"domain",filter:t,handler:e,active:!0}),i}subscribeToEventType(t,e){let i=`sub_type_${a()}`;return this.subscriptions.set(i,{id:i,type:"eventType",filter:t,handler:e,active:!0}),i}unsubscribe(t){let e=this.subscriptions.get(t);return e?(e.active=!1,this.subscriptions.delete(t),!0):!1}async route(t){this.addToHistory(t),t.correlationId&&this.trackCorrelation(t);let i=this.findMatchingSubscriptions(t).map(async o=>{try{await o.handler(t)}catch(n){console.error(`Error in subscription handler ${o.id}:`,n instanceof Error?n.message:n)}}),r=await this.applyRoutes(t);await Promise.allSettled([...i,...r])}getCorrelation(t){let e=this.correlations.get(t);if(e)return{correlationId:e.correlationId,events:[...e.events],domains:new Set(e.domains),startedAt:e.startedAt,lastEventAt:e.lastEventAt,complete:e.complete}}trackCorrelation(t){if(!t.correlationId)return;let e=this.correlations.get(t.correlationId);e||(e={correlationId:t.correlationId,events:[],domains:new Set,startedAt:t.timestamp,lastEventAt:t.timestamp,complete:!1,timeout:null},this.correlations.set(t.correlationId,e)),e.events.length<this.maxEventsPerCorrelation&&(e.events.push(t),e.domains.add(t.source),e.lastEventAt=t.timestamp),e.timeout&&clearTimeout(e.timeout),e.timeout=setTimeout(()=>{e.complete=!0,e.timeout=null},this.correlationTimeout)}aggregate(t,e){let i=this.eventHistory.toArray().filter(s=>s.timestamp>=t&&s.timestamp<=e),r=new Map,o=new Map;for(let s of i)r.set(s.type,(r.get(s.type)??0)+1),o.set(s.source,(o.get(s.source)??0)+1);let n={totalEvents:i.length,uniqueEventTypes:r.size,uniqueDomains:o.size,eventsPerSecond:i.length>0?i.length/((e.getTime()-t.getTime())/1e3):0};return{id:a(),windowStart:t,windowEnd:e,events:i,countByType:r,countByDomain:o,metrics:n}}getHistory(t){let e=this.eventHistory.toArray();return t&&(t.eventTypes?.length&&(e=e.filter(i=>t.eventTypes.includes(i.type))),t.domains?.length&&(e=e.filter(i=>t.domains.includes(i.source))),t.fromTimestamp&&(e=e.filter(i=>i.timestamp>=t.fromTimestamp)),t.toTimestamp&&(e=e.filter(i=>i.timestamp<=t.toTimestamp)),t.limit&&(e=e.slice(-t.limit))),e}addRoute(t){let e=t.priority??0,i=this.routes.findIndex(r=>(r.priority??0)<e);i===-1?this.routes.push(t):this.routes.splice(i,0,t)}removeRoute(t,e){let i=this.routes.findIndex(r=>r.eventPattern===t&&(e===void 0||r.source===e));return i!==-1?(this.routes.splice(i,1),!0):!1}async dispose(){this.subscriptions.clear();for(let t of this.domainSubscriptions.values())t.unsubscribe();this.domainSubscriptions.clear();for(let t of this.correlations.values())t.timeout&&clearTimeout(t.timeout);this.correlations.clear(),this.eventHistory.clear(),this.initialized=!1}async handleIncomingEvent(t){await this.route(t)}findMatchingSubscriptions(t){let e=[];for(let i of this.subscriptions.values())i.active&&(i.type==="domain"&&i.filter===t.source||i.type==="eventType"&&this.matchEventType(t.type,i.filter))&&e.push(i);return e}matchEventType(t,e){if(e==="*")return!0;let i=e.replace(/\\/g,"\\\\").replace(/\./g,"\\.").replace(/\*/g,".*");return new RegExp(`^${i}$`).test(t)}async applyRoutes(t){let e=[];for(let i of this.routes){if(!(i.source==="*"||i.source===t.source||Array.isArray(i.source)&&i.source.includes(t.source))||!this.matchEventType(t.type,i.eventPattern)||i.filter&&!i.filter(t))continue;let o=i.transform?i.transform(t):t;for(let n of i.targets)n!==t.source&&e.push(this.eventBus.publish({...o,id:a(),correlationId:t.correlationId??t.id}))}return e}addToHistory(t){this.eventHistory.push(t)}};function y(c,t){return new u(c,t)}export{u as a,y as b};
@@ -1,2 +1,2 @@
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.11.1");process.exit(0)}
2
- import{k as d}from"./chunk-X4GKYSOH.js";import{a as u,c as g}from"./chunk-QEDS3MOJ.js";g();var m=[{type:"email",pattern:/[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}/g,mask:n=>n[0]+"***@"+n.split("@")[1]},{type:"ssn",pattern:/\b\d{3}-\d{2}-\d{4}\b/g,mask:()=>"***-**-****"},{type:"credit-card",pattern:/\b(?:\d[ -]*?){13,19}\b/g,mask:n=>"****-****-****-"+n.replace(/\D/g,"").slice(-4)},{type:"phone",pattern:/\b(?:\+?1[-.\s]?)?(?:\(?\d{3}\)?[-.\s]?)?\d{3}[-.\s]?\d{4}\b/g,mask:n=>n.slice(0,3)+"***"+n.slice(-2)},{type:"api-key",pattern:/(?:key|token|api_key|apikey|secret|password|passwd|auth)=([A-Za-z0-9_\-]{16,})/gi,mask:()=>"***REDACTED***"}],y=class extends d{config={name:"qe/security/url-validate",description:"Validate URL security: checks for XSS/injection patterns, unsafe protocols, and scans URL query parameters for PII exposure (emails, SSNs, credit cards, API keys).",domain:"security-compliance",schema:this.buildSchema()};buildSchema(){return{type:"object",properties:{url:{type:"string",description:"URL to validate for security threats and PII exposure"},enablePII:{type:"boolean",description:"Enable PII exposure scanning in URL and query parameters",default:!0}},required:["url"]}}async execute(s,r){try{let e=this.validateURLSecurity(s.url),t=s.enablePII!==!1?this.scanForPII(s.url):{scanned:!1,found:!1,types:[],details:[]},c=e.issues.length+(t.found?t.types.length:0)===0?`URL passed all checks (security: clean, PII: ${t.scanned?"none found":"not scanned"})`:`URL has ${e.issues.length} security issue(s)${t.found?` and ${t.types.length} PII type(s) exposed in URL`:""}`;return{success:!0,data:{url:s.url,urlSecurity:e,piiExposure:t,summary:c}}}catch(e){return{success:!1,error:u(e)}}}validateURLSecurity(s){let r=[],e="none";try{let t=new URL(s);["http:","https:"].includes(t.protocol)||(r.push({type:"unsafe-protocol",description:`Protocol ${t.protocol} is not allowed`,severity:"high"}),e="high");let o=[/<script/i,/javascript:/i,/on\w+=/i,/data:text\/html/i];for(let i of o)if(i.test(s)){r.push({type:"xss",description:"Potential XSS pattern detected in URL",severity:"critical"}),e="critical";break}let c=[/'.*or.*'/i,/union.*select/i,/drop.*table/i,/;\s*--/i];for(let i of c)if(i.test(s)){r.push({type:"sql-injection",description:"Potential SQL injection pattern detected in URL",severity:"critical"}),e="critical";break}/\.\.[/\\]/.test(s)&&(r.push({type:"path-traversal",description:"Potential path traversal pattern (../) detected",severity:"high"}),e!=="critical"&&(e="high"));let a=["redirect","url","next","return","returnUrl","goto"];for(let i of a){let l=t.searchParams.get(i);l&&/^https?:\/\//.test(l)&&(r.push({type:"open-redirect",description:`Query parameter "${i}" contains an external URL \u2014 potential open redirect`,severity:"medium"}),e==="none"&&(e="medium"))}}catch{r.push({type:"invalid-url",description:"URL could not be parsed",severity:"critical"}),e="critical"}return{valid:r.length===0,riskLevel:e,issues:r}}scanForPII(s){let r=[],e=new Set,t;try{t=decodeURIComponent(s)}catch{t=s}let o="",c="";try{let a=new URL(t);o=a.search,c=a.pathname}catch{o=t}for(let{type:a,pattern:i,mask:l}of m){i.lastIndex=0;let p;for(;(p=i.exec(t))!==null;){e.add(a);let h=o.includes(p[0])?"query-parameter":c.includes(p[0])?"path":"url";r.push({type:a,location:h,masked:l(p[0])})}}return{scanned:!0,found:e.size>0,types:Array.from(e),details:r}}};export{y as a};
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.11.2");process.exit(0)}
2
+ import{k as d}from"./chunk-CZYSCUJ4.js";import{a as u,c as g}from"./chunk-FYY7OJ6Y.js";g();var m=[{type:"email",pattern:/[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}/g,mask:n=>n[0]+"***@"+n.split("@")[1]},{type:"ssn",pattern:/\b\d{3}-\d{2}-\d{4}\b/g,mask:()=>"***-**-****"},{type:"credit-card",pattern:/\b(?:\d[ -]*?){13,19}\b/g,mask:n=>"****-****-****-"+n.replace(/\D/g,"").slice(-4)},{type:"phone",pattern:/\b(?:\+?1[-.\s]?)?(?:\(?\d{3}\)?[-.\s]?)?\d{3}[-.\s]?\d{4}\b/g,mask:n=>n.slice(0,3)+"***"+n.slice(-2)},{type:"api-key",pattern:/(?:key|token|api_key|apikey|secret|password|passwd|auth)=([A-Za-z0-9_\-]{16,})/gi,mask:()=>"***REDACTED***"}],y=class extends d{config={name:"qe/security/url-validate",description:"Validate URL security: checks for XSS/injection patterns, unsafe protocols, and scans URL query parameters for PII exposure (emails, SSNs, credit cards, API keys).",domain:"security-compliance",schema:this.buildSchema()};buildSchema(){return{type:"object",properties:{url:{type:"string",description:"URL to validate for security threats and PII exposure"},enablePII:{type:"boolean",description:"Enable PII exposure scanning in URL and query parameters",default:!0}},required:["url"]}}async execute(s,r){try{let e=this.validateURLSecurity(s.url),t=s.enablePII!==!1?this.scanForPII(s.url):{scanned:!1,found:!1,types:[],details:[]},c=e.issues.length+(t.found?t.types.length:0)===0?`URL passed all checks (security: clean, PII: ${t.scanned?"none found":"not scanned"})`:`URL has ${e.issues.length} security issue(s)${t.found?` and ${t.types.length} PII type(s) exposed in URL`:""}`;return{success:!0,data:{url:s.url,urlSecurity:e,piiExposure:t,summary:c}}}catch(e){return{success:!1,error:u(e)}}}validateURLSecurity(s){let r=[],e="none";try{let t=new URL(s);["http:","https:"].includes(t.protocol)||(r.push({type:"unsafe-protocol",description:`Protocol ${t.protocol} is not allowed`,severity:"high"}),e="high");let o=[/<script/i,/javascript:/i,/on\w+=/i,/data:text\/html/i];for(let i of o)if(i.test(s)){r.push({type:"xss",description:"Potential XSS pattern detected in URL",severity:"critical"}),e="critical";break}let c=[/'.*or.*'/i,/union.*select/i,/drop.*table/i,/;\s*--/i];for(let i of c)if(i.test(s)){r.push({type:"sql-injection",description:"Potential SQL injection pattern detected in URL",severity:"critical"}),e="critical";break}/\.\.[/\\]/.test(s)&&(r.push({type:"path-traversal",description:"Potential path traversal pattern (../) detected",severity:"high"}),e!=="critical"&&(e="high"));let a=["redirect","url","next","return","returnUrl","goto"];for(let i of a){let l=t.searchParams.get(i);l&&/^https?:\/\//.test(l)&&(r.push({type:"open-redirect",description:`Query parameter "${i}" contains an external URL \u2014 potential open redirect`,severity:"medium"}),e==="none"&&(e="medium"))}}catch{r.push({type:"invalid-url",description:"URL could not be parsed",severity:"critical"}),e="critical"}return{valid:r.length===0,riskLevel:e,issues:r}}scanForPII(s){let r=[],e=new Set,t;try{t=decodeURIComponent(s)}catch{t=s}let o="",c="";try{let a=new URL(t);o=a.search,c=a.pathname}catch{o=t}for(let{type:a,pattern:i,mask:l}of m){i.lastIndex=0;let p;for(;(p=i.exec(t))!==null;){e.add(a);let h=o.includes(p[0])?"query-parameter":c.includes(p[0])?"path":"url";r.push({type:a,location:h,masked:l(p[0])})}}return{scanned:!0,found:e.size>0,types:Array.from(e),details:r}}};export{y as a};
@@ -1,4 +1,4 @@
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.11.1");process.exit(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.11.2");process.exit(0)}
2
2
  import{readFileSync as O,existsSync as x,readdirSync as A}from"fs";import{join as y,basename as v}from"path";function m(r){let e=[];if(!r||typeof r!="object")return e.push("Overlay must be a non-null object"),e;let t=r;if((!t.agent||typeof t.agent!="string")&&e.push('Overlay must have a string "agent" field'),t.replace!==void 0)if(typeof t.replace!="object"||t.replace===null)e.push('"replace" must be an object');else{let n=t.replace;n.description!==void 0&&typeof n.description!="string"&&e.push('"replace.description" must be a string'),n.domains!==void 0&&!Array.isArray(n.domains)&&e.push('"replace.domains" must be an array'),n.complexity!==void 0&&typeof n.complexity!="string"&&e.push('"replace.complexity" must be a string')}if(t.append!==void 0)if(typeof t.append!="object"||t.append===null)e.push('"append" must be an object');else{let n=t.append;n.instructions!==void 0&&typeof n.instructions!="string"&&e.push('"append.instructions" must be a string'),n.capabilities!==void 0&&!Array.isArray(n.capabilities)&&e.push('"append.capabilities" must be an array'),n.tags!==void 0&&!Array.isArray(n.tags)&&e.push('"append.tags" must be an array')}if(t.config!==void 0)if(typeof t.config!="object"||t.config===null)e.push('"config" must be an object');else{let n=t.config;n.minimumFindings!==void 0&&typeof n.minimumFindings!="number"&&e.push('"config.minimumFindings" must be a number'),n.maxParallelAgents!==void 0&&typeof n.maxParallelAgents!="number"&&e.push('"config.maxParallelAgents" must be a number'),n.preferredFrameworks!==void 0&&!Array.isArray(n.preferredFrameworks)&&e.push('"config.preferredFrameworks" must be an array'),n.needsContext!==void 0&&typeof n.needsContext!="boolean"&&e.push('"config.needsContext" must be a boolean')}return e}var w=".claude/agent-overrides";function $(r){let e={},t=r.split(`
3
3
  `),n=null,i=null,s=null,a=null;for(let o of t){let l=o.replace(/\r$/,"");if(l.trim().startsWith("#")||l.trim()==="")continue;let u=l.length-l.trimStart().length,g=l.trim();if(g.startsWith("- ")){let c=g.slice(2).trim().replace(/^["']|["']$/g,"");s&&s.push(c);continue}if(s&&a){if(i&&n){let c=e[n]||{};c[a]=s,e[n]=c}else if(n){let c=e[n]||{};c[a]=s,e[n]=c}s=null,a=null}let f=g.match(/^(\w[\w.-]*)\s*:\s*(.*)$/);if(!f)continue;let[,p,b]=f,d=b.trim().replace(/^["']|["']$/g,"");if(u===0)d===""||d===void 0?(n=p,i=null,e[p]||(e[p]={})):(e[p]=h(d),n=null,i=null);else if(u<=4&&n)if(d===""||d===void 0)i=p,s=[],a=p;else{let c=e[n]||{};c[p]=h(d),e[n]=c}}if(s&&a&&n){let o=e[n]||{};o[a]=s,e[n]=o}return e}function h(r){if(r==="true")return!0;if(r==="false")return!1;if(r==="null")return null;let e=Number(r);return!isNaN(e)&&r!==""?e:r}function N(r){let e=y(r,w),t={overlays:[],warnings:[],errors:[]};if(!x(e))return t;let n;try{n=A(e).filter(i=>(i.endsWith(".yaml")||i.endsWith(".yml"))&&!i.startsWith("_"))}catch(i){return t.errors.push(`Failed to read overrides directory: ${i.message}`),t}for(let i of n){let s=y(e,i);try{let a=O(s,"utf-8"),o=$(a);if(!o.agent){let u=v(i).replace(/\.(override|customize)\.(yaml|yml)$/,"");o.agent=u}let l=m(o);if(l.length>0){t.warnings.push(`Overlay ${i} has validation issues: ${l.join("; ")}. Loading without overlay.`);continue}t.overlays.push(o)}catch(a){t.warnings.push(`Failed to parse overlay ${i}: ${a.message}. Agent loads without overlay.`)}}return t}function E(r,e){let t=r,n={agentName:e.agent,overlayFile:`${e.agent}.override.yaml`,replacedFields:[],appendedFields:[],configOverrides:[]};if(e.replace){if(e.replace.description){let i=/^(description:\s*).+$/m;i.test(t)&&(t=t.replace(i,`$1${e.replace.description}`),n.replacedFields.push("description"))}if(e.replace.domains){let i=/^(domain:\s*).+$/m;i.test(t)&&(t=t.replace(i,`$1${e.replace.domains.join(", ")}`),n.replacedFields.push("domains"))}if(e.replace.complexity){let i=/^(complexity:\s*).+$/m;i.test(t)&&(t=t.replace(i,`$1${e.replace.complexity}`),n.replacedFields.push("complexity"))}}if(e.append){if(e.append.instructions&&(t+=`
4
4
 
@@ -1,2 +1,2 @@
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.11.1");process.exit(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.11.2");process.exit(0)}
2
2
  var l=class m{vertices=new Map;edges=new Map;adjacencyList=new Map;totalWeight=0;addVertex(e){if(this.vertices.has(e.id)){this.vertices.set(e.id,e);return}this.vertices.set(e.id,e),this.adjacencyList.set(e.id,[])}removeVertex(e){if(!this.vertices.has(e))return!1;let t=this.adjacencyList.get(e)||[];for(let r of t)this.removeEdge(e,r.neighborId);for(let[,r]of this.adjacencyList){let n=r.findIndex(i=>i.neighborId===e);n!==-1&&(this.totalWeight-=r[n].weight,r.splice(n,1))}return this.vertices.delete(e),this.adjacencyList.delete(e),!0}getVertex(e){return this.vertices.get(e)}hasVertex(e){return this.vertices.has(e)}getVertices(){return Array.from(this.vertices.values())}getVertexIds(){return Array.from(this.vertices.keys())}getVerticesByDomain(e){return this.getVertices().filter(t=>t.domain===e)}getVerticesByType(e){return this.getVertices().filter(t=>t.type===e)}addEdge(e){if(!this.vertices.has(e.source))throw new Error(`Source vertex ${e.source} does not exist`);if(!this.vertices.has(e.target))throw new Error(`Target vertex ${e.target} does not exist`);let t=this.edgeKey(e.source,e.target);if(this.edges.has(t)){let r=this.edges.get(t);this.totalWeight-=r.weight,this.removeFromAdjacency(e.source,e.target),r.bidirectional&&this.removeFromAdjacency(e.target,e.source)}this.edges.set(t,e),this.totalWeight+=e.weight,this.addToAdjacency(e.source,e.target,e.weight,e),e.bidirectional&&this.addToAdjacency(e.target,e.source,e.weight,e)}removeEdge(e,t){let r=this.edgeKey(e,t),n=this.edges.get(r);return n?(this.totalWeight-=n.weight,this.edges.delete(r),this.removeFromAdjacency(e,t),n.bidirectional&&this.removeFromAdjacency(t,e),!0):!1}getEdge(e,t){return this.edges.get(this.edgeKey(e,t))}hasEdge(e,t){return this.edges.has(this.edgeKey(e,t))}getEdges(){return Array.from(this.edges.values())}getEdgesForVertex(e){return(this.adjacencyList.get(e)||[]).map(r=>r.edge)}degree(e){return this.adjacencyList.get(e)?.length||0}weightedDegree(e){let t=this.adjacencyList.get(e);return t?t.reduce((r,n)=>r+n.weight,0):0}neighbors(e){return(this.adjacencyList.get(e)||[]).map(r=>({vertex:this.vertices.get(r.neighborId),weight:r.weight})).filter(r=>r.vertex!==void 0)}neighborIds(e){return(this.adjacencyList.get(e)||[]).map(r=>r.neighborId)}getStats(){let e=this.vertices.size,t=this.edges.size,r=0;for(let[,s]of this.adjacencyList)r+=s.length;let n=e>0?r/e:0,i=e>1?e*(e-1)/2:0,a=i>0?t/i:0,o=this.countConnectedComponents(),c=o===1&&e>0;return{vertexCount:e,edgeCount:t,totalWeight:this.totalWeight,averageDegree:n,density:a,isConnected:c,componentCount:o}}countConnectedComponents(){let e=new Set,t=0;for(let r of this.vertices.keys())e.has(r)||(this.dfs(r,e),t++);return t}dfs(e,t){t.add(e);let r=this.adjacencyList.get(e)||[];for(let n of r)t.has(n.neighborId)||this.dfs(n.neighborId,t)}isConnected(){if(this.vertices.size===0||this.vertices.size===1)return!0;let e=new Set,t=this.vertices.keys().next().value;return t===void 0?!0:(this.dfs(t,e),e.size===this.vertices.size)}getConnectedComponent(e){if(!this.vertices.has(e))return[];let t=new Set;return this.dfs(e,t),Array.from(t)}snapshot(){return{timestamp:new Date,vertices:this.getVertices(),edges:this.getEdges(),stats:this.getStats()}}clone(){let e=new m;for(let t of this.vertices.values())e.addVertex({...t});for(let t of this.edges.values())e.addEdge({...t});return e}static fromSnapshot(e){let t=new m;for(let r of e.vertices)t.addVertex(r);for(let r of e.edges)t.addEdge(r);return t}clear(){this.vertices.clear(),this.edges.clear(),this.adjacencyList.clear(),this.totalWeight=0}get vertexCount(){return this.vertices.size}get edgeCount(){return this.edges.size}isEmpty(){return this.vertices.size===0}edgeKey(e,t){return e<t?`${e}:${t}`:`${t}:${e}`}addToAdjacency(e,t,r,n){let i=this.adjacencyList.get(e);i&&(i.find(o=>o.neighborId===t)||i.push({neighborId:t,weight:r,edge:n}))}removeFromAdjacency(e,t){let r=this.adjacencyList.get(e);if(r){let n=r.findIndex(i=>i.neighborId===t);n!==-1&&r.splice(n,1)}}};function p(){return new l}var f=class{approxMinCut(e){let t=Date.now();if(e.isEmpty())return this.emptyResult(t,"weighted-degree");let r=e.getVertexIds(),n=1/0,i=null;for(let o of r){let c=e.weightedDegree(o);c<n&&(n=c,i=o)}if(i===null||r.length===1)return this.emptyResult(t,"weighted-degree");let a=e.getEdgesForVertex(i);return{value:n,sourceSide:[i],targetSide:r.filter(o=>o!==i),cutEdges:a,calculatedAt:new Date,algorithm:"weighted-degree",durationMs:Date.now()-t}}findWeakVertices(e,t){if(e.isEmpty())return[];let r=e.getVertices(),n=[],i=new Map,a=0;for(let g of r){let h=e.weightedDegree(g.id);i.set(g.id,h),a+=h}let o=a/r.length,c=0;for(let g of i.values())c+=(g-o)**2;let s=Math.sqrt(c/r.length),d=1/0;for(let g of i.values())g<d&&(d=g);let u=t??o-s;for(let g of r){let h=i.get(g.id);if(h<=u){let w=this.calculateRiskScore(h,o,s,d),y=this.determineWeakReason(g,h,o,e),v=this.generateStrengtheningActions(g,e,h);n.push({vertexId:g.id,vertex:g,weightedDegree:h,riskScore:w,reason:y,suggestions:v})}}return n.sort((g,h)=>h.riskScore-g.riskScore),n}getMinCutValue(e){if(e.isEmpty())return 0;let t=1/0;for(let r of e.getVertexIds()){let n=e.weightedDegree(r);n<t&&(t=n)}return t===1/0?0:t}isConnectivityCritical(e,t){return this.getMinCutValue(e)<t}getMinDegreeVertex(e){if(e.isEmpty())return null;let t=1/0,r=null;for(let n of e.getVertexIds()){let i=e.weightedDegree(n);i<t&&(t=i,r=n)}return r?{vertexId:r,degree:t}:null}getLocalMinCut(e,t){return e.hasVertex(t)?e.weightedDegree(t):0}findPartitioningPoints(e){if(e.isEmpty()||e.vertexCount<2)return[];let t=this.findArticulationPoints(e),r=[];for(let n of e.getVertices()){let i=this.getLocalMinCut(e,n.id);r.push({vertexId:n.id,localMinCut:i,wouldDisconnect:t.has(n.id)&&e.vertexCount>2})}return r.sort((n,i)=>n.localMinCut-i.localMinCut),r}findArticulationPoints(e){let t=new Map,r=new Map,n=new Map,i=new Set,a=0,o=e.getVertexIds();for(let s of o)t.set(s,-1),r.set(s,-1),n.set(s,null);let c=s=>{let d=0;t.set(s,a),r.set(s,a),a++;for(let u of e.neighborIds(s))t.get(u)===-1?(d++,n.set(u,s),c(u),r.set(s,Math.min(r.get(s),r.get(u))),n.get(s)===null&&d>1&&i.add(s),n.get(s)!==null&&r.get(u)>=t.get(s)&&i.add(s)):u!==n.get(s)&&r.set(s,Math.min(r.get(s),t.get(u)))};for(let s of o)t.get(s)===-1&&c(s);return i}suggestEdgeAdditions(e,t){let r=this.findWeakVertices(e),n=[],i=0,a=e.getVertices().map(o=>({vertex:o,degree:e.weightedDegree(o.id)})).sort((o,c)=>c.degree-o.degree);for(let o of r){if(i>=t)break;let c=new Set(e.neighborIds(o.vertexId));for(let{vertex:s}of a){if(s.id===o.vertexId||c.has(s.id))continue;let d={source:o.vertexId,target:s.id,weight:1,type:"coordination",bidirectional:!0};n.push(d),i+=1;break}}return n}emptyResult(e,t){return{value:0,sourceSide:[],targetSide:[],cutEdges:[],calculatedAt:new Date,algorithm:t,durationMs:Date.now()-e}}calculateRiskScore(e,t,r,n){if(r===0)return .5;let i=(t-e)/r,a=1/(1+Math.exp(-i)),o=n>0?n/e:1;return Math.min(1,a*o)}determineWeakReason(e,t,r,n){return t===0?"Isolated vertex with no connections":n.degree(e.id)===1?"Single connection point (leaf node)":t<r*.5?`Low connectivity (${(t/r*100).toFixed(0)}% of average)`:"Below average connectivity threshold"}generateStrengtheningActions(e,t,r){let n=[],i=new Set(t.neighborIds(e.id)),a=t.getStats().averageDegree,o=Math.max(a,3),c=Math.ceil(o-r),s=t.getVertices().filter(d=>d.id!==e.id&&!i.has(d.id)).sort((d,u)=>t.weightedDegree(u.id)-t.weightedDegree(d.id)).slice(0,c);for(let d of s)n.push({type:"add_edge",targetVertex:d.id,priority:"high",estimatedImprovement:1});return e.type==="agent"&&e.domain&&r<1&&n.push({type:"spawn_agent",domain:e.domain,priority:"critical",estimatedImprovement:2}),i.size>0&&i.size<3&&n.push({type:"increase_weight",weightDelta:.5,priority:"medium",estimatedImprovement:.5*i.size}),n}};function x(){return new f}export{l as a,p as b,f as c,x as d};
@@ -1,3 +1,3 @@
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.11.1");process.exit(0)}
2
- import{b as c,d as p}from"./chunk-N6NSZG7Z.js";import{a as f}from"./chunk-7SRSOZMP.js";p();import{existsSync as l,readFileSync as i}from"node:fs";import{join as a}from"node:path";import{execSync as m}from"node:child_process";var s=null,d=0,g=6e4;function S(){s=null,d=0}function b(e){if(s&&Date.now()-d<g)return s;let n=w(e);return s=n,d=Date.now(),n}function w(e){let n=h(e);if(n)return n;let r=v(e);if(r)return r;let t=k(e);return t||{available:!1}}function h(e){let n=a(e,".mcp.json");if(l(n))try{let o=c(i(n,"utf-8"));if(o.mcpServers?.ruflo||o.mcpServers?.["claude-flow"])return{available:!0,method:"mcp-config"}}catch{}let r=a(e,".claude","mcp.json");if(l(r))try{let o=c(i(r,"utf-8"));if(o.mcpServers?.ruflo||o.mcpServers?.["claude-flow"])return{available:!0,method:"mcp-config"}}catch{}let t=a(e,".claude","settings.json");if(l(t))try{let o=c(i(t,"utf-8")),u=o.mcpServers||o.mcp?.servers||{};if(u.ruflo||u["claude-flow"]||u["@anthropic/claude-flow"])return{available:!0,method:"mcp-config"}}catch{}return null}function v(e){let n=a(e,"package.json");if(!l(n))return null;try{let r=c(i(n,"utf-8")),t={...r.dependencies,...r.devDependencies};if(t.ruflo||t["@claude-flow/cli"]||t["claude-flow"])return{available:!0,method:"npm-dependency"}}catch{}return null}function k(e){for(let n of["ruflo","@claude-flow/cli"])try{return{available:!0,method:"npx-cached",version:m(`npx --no-install ${n} --version`,{encoding:"utf-8",timeout:5e3,cwd:e,stdio:["pipe","pipe","pipe"]}).trim().match(/\d+\.\d+\.\d+[\w.-]*/)?.[0]}}catch{}return null}function x(){for(let e of["ruflo","@claude-flow/cli"])try{return f.resolve(`${e}/package.json`),e}catch{}return"ruflo"}function P(){return[" Claude Flow not found \u2014 running in standalone mode.",""," Claude Flow adds optional features:"," - SONA trajectory tracking (reinforcement learning)"," - 3-tier model routing (haiku / sonnet / opus)"," - Codebase pretrain analysis",""," To install later:"," npm install -g ruflo"," claude mcp add ruflo -- npx -y ruflo@3.5.18"," aqe init --auto --with-claude-flow"].join(`
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.11.2");process.exit(0)}
2
+ import{b as c,d as p}from"./chunk-LY6PTRVL.js";import{a as f}from"./chunk-LIEA5EON.js";p();import{existsSync as l,readFileSync as i}from"node:fs";import{join as a}from"node:path";import{execSync as m}from"node:child_process";var s=null,d=0,g=6e4;function S(){s=null,d=0}function b(e){if(s&&Date.now()-d<g)return s;let n=w(e);return s=n,d=Date.now(),n}function w(e){let n=h(e);if(n)return n;let r=v(e);if(r)return r;let t=k(e);return t||{available:!1}}function h(e){let n=a(e,".mcp.json");if(l(n))try{let o=c(i(n,"utf-8"));if(o.mcpServers?.ruflo||o.mcpServers?.["claude-flow"])return{available:!0,method:"mcp-config"}}catch{}let r=a(e,".claude","mcp.json");if(l(r))try{let o=c(i(r,"utf-8"));if(o.mcpServers?.ruflo||o.mcpServers?.["claude-flow"])return{available:!0,method:"mcp-config"}}catch{}let t=a(e,".claude","settings.json");if(l(t))try{let o=c(i(t,"utf-8")),u=o.mcpServers||o.mcp?.servers||{};if(u.ruflo||u["claude-flow"]||u["@anthropic/claude-flow"])return{available:!0,method:"mcp-config"}}catch{}return null}function v(e){let n=a(e,"package.json");if(!l(n))return null;try{let r=c(i(n,"utf-8")),t={...r.dependencies,...r.devDependencies};if(t.ruflo||t["@claude-flow/cli"]||t["claude-flow"])return{available:!0,method:"npm-dependency"}}catch{}return null}function k(e){for(let n of["ruflo","@claude-flow/cli"])try{return{available:!0,method:"npx-cached",version:m(`npx --no-install ${n} --version`,{encoding:"utf-8",timeout:5e3,cwd:e,stdio:["pipe","pipe","pipe"]}).trim().match(/\d+\.\d+\.\d+[\w.-]*/)?.[0]}}catch{}return null}function x(){for(let e of["ruflo","@claude-flow/cli"])try{return f.resolve(`${e}/package.json`),e}catch{}return"ruflo"}function P(){return[" Claude Flow not found \u2014 running in standalone mode.",""," Claude Flow adds optional features:"," - SONA trajectory tracking (reinforcement learning)"," - 3-tier model routing (haiku / sonnet / opus)"," - Codebase pretrain analysis",""," To install later:"," npm install -g ruflo"," claude mcp add ruflo -- npx -y ruflo@3.5.18"," aqe init --auto --with-claude-flow"].join(`
3
3
  `)}export{S as a,b,x as c,P as d};
@@ -1,5 +1,5 @@
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.11.1");process.exit(0)}
2
- import{a as D,b as _,c as $,d as I}from"./chunk-TUEDIQHY.js";import{a as X}from"./chunk-PY4YQDBM.js";import{c as K,d as Y,e as J,f as Z}from"./chunk-7OAKIXNM.js";import{b as C,f as G,i as U}from"./chunk-5LDUW2FD.js";import{g as R}from"./chunk-N6RSJGTW.js";import{e as H}from"./chunk-TCKBICJ3.js";import{i as j,m as de}from"./chunk-437XL5VZ.js";import{a as z}from"./chunk-57WGS6BI.js";import{c as T}from"./chunk-S7IHSELP.js";import{b as k,c as A}from"./chunk-EQYDPF52.js";import{a as h,b as V,c as W}from"./chunk-QEDS3MOJ.js";import{S as pe,b as B}from"./chunk-N4OWZLH5.js";z();W();var N={enableLearning:!0,enableGuidance:!0,enableRouting:!0,embeddingDimension:384,useONNXEmbeddings:!0,maxRoutingCandidates:10,routingWeights:{similarity:.3,performance:.4,capabilities:.3},coherenceThreshold:.4};var q=[{patternType:"test-template",name:"AAA Unit Test",description:"Arrange-Act-Assert pattern for clear, maintainable unit tests",template:{type:"code",content:`describe('{{className}}', () => {
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.11.2");process.exit(0)}
2
+ import{a as D,b as _,c as $,d as I}from"./chunk-H3LGBH4Y.js";import{a as X}from"./chunk-7KHZZVF2.js";import{c as K,d as Y,e as J,f as Z}from"./chunk-K6IQBVD7.js";import{b as C,f as G,i as U}from"./chunk-P7MIOTVP.js";import{g as R}from"./chunk-H5TM4KIB.js";import{e as H}from"./chunk-ZWMXF6AX.js";import{i as j,m as de}from"./chunk-4PYJCIRO.js";import{a as z}from"./chunk-72VVTMEL.js";import{c as T}from"./chunk-5BDVFFYF.js";import{b as k,c as A}from"./chunk-QZLTIGLB.js";import{a as h,b as V,c as W}from"./chunk-FYY7OJ6Y.js";import{S as pe,b as B}from"./chunk-WKIYYF3G.js";z();W();var N={enableLearning:!0,enableGuidance:!0,enableRouting:!0,embeddingDimension:384,useONNXEmbeddings:!0,maxRoutingCandidates:10,routingWeights:{similarity:.3,performance:.4,capabilities:.3},coherenceThreshold:.4};var q=[{patternType:"test-template",name:"AAA Unit Test",description:"Arrange-Act-Assert pattern for clear, maintainable unit tests",template:{type:"code",content:`describe('{{className}}', () => {
3
3
  describe('{{methodName}}', () => {
4
4
  it('should {{expectedBehavior}}', {{async}} () => {
5
5
  // Arrange
@@ -317,4 +317,4 @@ On promotion:
317
317
  AND agent_id = 'aqe-hook-router'
318
318
  AND state_key = ?
319
319
  AND action_key = ?
320
- `);return s=>{try{let a=o.get(e,s);return a?{qValue:a.q_value,visits:a.visits}:void 0}catch{return}}}catch{return()=>{}}}getGuidance(e,r){return D(e)}generateContext(e,r){return I(e,r||{})}checkAntiPatterns(e,r){return $(e,r)}async embed(e){if(this.config.useONNXEmbeddings)try{let{computeRealEmbedding:r}=await import("./real-embeddings-GUZDO5UN.js"),t=await r(e);return t.length!==this.config.embeddingDimension?oe(t,this.config.embeddingDimension):t}catch(r){let{isUsingEndpoint:t}=await import("./real-embeddings-GUZDO5UN.js");if(t())throw r;process.env.DEBUG&&f.warn("ONNX embeddings unavailable, using hash fallback",{error:h(r)})}return se(e,this.config.embeddingDimension)}async getStats(){this.initialized||await this.initialize();let e=await this.patternStore.getStats(),r={};for(let a of U)r[a]=e.byDomain[a]||0;let t=this.stats.routingRequests,i=this.stats.routingRequests>0?this.stats.totalRoutingConfidence/this.stats.routingRequests:0,o=this.stats.learningOutcomes,s=this.stats.learningOutcomes>0?this.stats.successfulOutcomes/this.stats.learningOutcomes:0;if(t===0||o===0)try{let a=this.getSqliteStore().getAggregateOutcomeStats();t===0&&a.routingRequests>0&&(t=a.routingRequests,i=a.avgRoutingConfidence),o===0&&a.learningOutcomes>0&&(o=a.learningOutcomes,s=a.learningOutcomes>0?a.successfulOutcomes/a.learningOutcomes:a.avgPatternSuccessRate)}catch{}return{totalPatterns:e.totalPatterns,byDomain:r,routingRequests:t,avgRoutingConfidence:i,learningOutcomes:o,patternSuccessRate:s,patternStoreStats:e}}async dispose(){if(await this.patternStore.dispose(),this.sqliteStore&&(this.sqliteStore.close(),this.sqliteStore=null),this.rvfDualWriter){try{this.rvfDualWriter.close()}catch{}this.rvfDualWriter=null}this.initialized=!1}};function pt(n,e,r,t){return new L(n,e,r,t)}export{N as a,q as b,x as c,ne as d,Q as e,M as f,L as g,pt as h};
320
+ `);return s=>{try{let a=o.get(e,s);return a?{qValue:a.q_value,visits:a.visits}:void 0}catch{return}}}catch{return()=>{}}}getGuidance(e,r){return D(e)}generateContext(e,r){return I(e,r||{})}checkAntiPatterns(e,r){return $(e,r)}async embed(e){if(this.config.useONNXEmbeddings)try{let{computeRealEmbedding:r}=await import("./real-embeddings-ZFFDV6HC.js"),t=await r(e);return t.length!==this.config.embeddingDimension?oe(t,this.config.embeddingDimension):t}catch(r){let{isUsingEndpoint:t}=await import("./real-embeddings-ZFFDV6HC.js");if(t())throw r;process.env.DEBUG&&f.warn("ONNX embeddings unavailable, using hash fallback",{error:h(r)})}return se(e,this.config.embeddingDimension)}async getStats(){this.initialized||await this.initialize();let e=await this.patternStore.getStats(),r={};for(let a of U)r[a]=e.byDomain[a]||0;let t=this.stats.routingRequests,i=this.stats.routingRequests>0?this.stats.totalRoutingConfidence/this.stats.routingRequests:0,o=this.stats.learningOutcomes,s=this.stats.learningOutcomes>0?this.stats.successfulOutcomes/this.stats.learningOutcomes:0;if(t===0||o===0)try{let a=this.getSqliteStore().getAggregateOutcomeStats();t===0&&a.routingRequests>0&&(t=a.routingRequests,i=a.avgRoutingConfidence),o===0&&a.learningOutcomes>0&&(o=a.learningOutcomes,s=a.learningOutcomes>0?a.successfulOutcomes/a.learningOutcomes:a.avgPatternSuccessRate)}catch{}return{totalPatterns:e.totalPatterns,byDomain:r,routingRequests:t,avgRoutingConfidence:i,learningOutcomes:o,patternSuccessRate:s,patternStoreStats:e}}async dispose(){if(await this.patternStore.dispose(),this.sqliteStore&&(this.sqliteStore.close(),this.sqliteStore=null),this.rvfDualWriter){try{this.rvfDualWriter.close()}catch{}this.rvfDualWriter=null}this.initialized=!1}};function pt(n,e,r,t){return new L(n,e,r,t)}export{N as a,q as b,x as c,ne as d,Q as e,M as f,L as g,pt as h};
@@ -1,4 +1,4 @@
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.11.1");process.exit(0)}
2
- import{b as f,d as v}from"./chunk-N6NSZG7Z.js";import q,{MultiBar as F,Presets as k}from"cli-progress";import O from"ora";import o from"chalk";v();import{existsSync as w,readFileSync as y,writeFileSync as j,mkdirSync as W,unlinkSync as V}from"fs";import{join as p}from"path";import{homedir as C}from"os";var u={wizards:{enabled:!0,themes:["default","minimal","detailed"],defaultTheme:"default"},progress:{style:"multi-bar",updateIntervalMs:100,showETA:!0,colors:!0},completion:{maxSuggestions:10,historyWeight:.3,contextWeight:.7,fuzzyMatch:!0},streaming:{enabled:!0,bufferSize:100,updateIntervalMs:50}};function x(){return p(C(),".aqe")}function E(){return p(x(),"cli-config.json")}var g=null,d=0,T=5e3;function S(){return g?Date.now()-d<T:!1}function A(s){let e=[],t=s;if(typeof t.enabled!="boolean"&&t.enabled!==void 0&&e.push({path:"wizards.enabled",message:"must be a boolean"}),t.themes!==void 0)if(!Array.isArray(t.themes))e.push({path:"wizards.themes",message:"must be an array"});else{let r=["default","minimal","detailed"];for(let n of t.themes)r.includes(n)||e.push({path:"wizards.themes",message:`invalid theme: ${n}`})}return t.defaultTheme!==void 0&&(["default","minimal","detailed"].includes(t.defaultTheme)||e.push({path:"wizards.defaultTheme",message:`invalid theme: ${t.defaultTheme}`})),e}function P(s){let e=[],t=s;return t.style!==void 0&&(["multi-bar","single-bar","spinner"].includes(t.style)||e.push({path:"progress.style",message:`invalid style: ${t.style}`})),t.updateIntervalMs!==void 0&&(typeof t.updateIntervalMs!="number"||t.updateIntervalMs<10)&&e.push({path:"progress.updateIntervalMs",message:"must be a number >= 10"}),typeof t.showETA!="boolean"&&t.showETA!==void 0&&e.push({path:"progress.showETA",message:"must be a boolean"}),typeof t.colors!="boolean"&&t.colors!==void 0&&e.push({path:"progress.colors",message:"must be a boolean"}),e}function $(s){let e=[],t=s;return t.maxSuggestions!==void 0&&(typeof t.maxSuggestions!="number"||t.maxSuggestions<1)&&e.push({path:"completion.maxSuggestions",message:"must be a number >= 1"}),t.historyWeight!==void 0&&(typeof t.historyWeight!="number"||t.historyWeight<0||t.historyWeight>1)&&e.push({path:"completion.historyWeight",message:"must be a number between 0 and 1"}),t.contextWeight!==void 0&&(typeof t.contextWeight!="number"||t.contextWeight<0||t.contextWeight>1)&&e.push({path:"completion.contextWeight",message:"must be a number between 0 and 1"}),typeof t.fuzzyMatch!="boolean"&&t.fuzzyMatch!==void 0&&e.push({path:"completion.fuzzyMatch",message:"must be a boolean"}),e}function I(s){let e=[],t=s;return typeof t.enabled!="boolean"&&t.enabled!==void 0&&e.push({path:"streaming.enabled",message:"must be a boolean"}),t.bufferSize!==void 0&&(typeof t.bufferSize!="number"||t.bufferSize<1)&&e.push({path:"streaming.bufferSize",message:"must be a number >= 1"}),t.updateIntervalMs!==void 0&&(typeof t.updateIntervalMs!="number"||t.updateIntervalMs<10)&&e.push({path:"streaming.updateIntervalMs",message:"must be a number >= 10"}),e}function M(s){let e=[];if(typeof s!="object"||s===null)return{valid:!1,errors:[{path:"",message:"config must be an object"}]};let t=s;return t.wizards!==void 0&&(typeof t.wizards!="object"||t.wizards===null?e.push({path:"wizards",message:"must be an object"}):e.push(...A(t.wizards))),t.progress!==void 0&&(typeof t.progress!="object"||t.progress===null?e.push({path:"progress",message:"must be an object"}):e.push(...P(t.progress))),t.completion!==void 0&&(typeof t.completion!="object"||t.completion===null?e.push({path:"completion",message:"must be an object"}):e.push(...$(t.completion))),t.streaming!==void 0&&(typeof t.streaming!="object"||t.streaming===null?e.push({path:"streaming",message:"must be an object"}):e.push(...I(t.streaming))),{valid:e.length===0,errors:e}}var z=["__proto__","constructor","prototype"];function m(s,e){let t={...s};for(let r of Object.keys(e)){if(z.includes(r)){console.warn(`Security: Skipping forbidden key '${String(r)}' in configuration merge`);continue}let n=e[r],i=s[r];n!==void 0&&typeof n=="object"&&!Array.isArray(n)&&typeof i=="object"&&!Array.isArray(i)?t[r]=m(i,n):n!==void 0&&(t[r]=n)}return t}function D(){let s=E();if(!w(s))return{...u};try{let e=y(s,"utf-8"),t=f(e),r=M(t);return r.valid?m(u,t):(console.warn(`CLI config validation errors: ${r.errors.map(n=>`${n.path}: ${n.message}`).join(", ")}`),console.warn("Using default configuration"),{...u})}catch(e){return console.warn(`Failed to load CLI config: ${e instanceof Error?e.message:"Unknown error"}`),{...u}}}function c(){return S()||(g=D(),d=Date.now()),g}function B(){return process.stdout.isTTY===!0}function h(){let s=c();return process.env.NO_COLOR!==void 0?!1:process.env.FORCE_COLOR!==void 0?!0:s.progress.colors&&B()}var b=class{multiBar;agentBars=new Map;agentStates=new Map;fleetBar=null;startTime=Date.now();options;isActive=!1;constructor(e={}){let t=c(),r=h();this.options={title:"Fleet Progress",showEta:t.progress.showETA,showPercentage:!0,...e};let n=r?o.cyan("{bar}"):"{bar}",i=this.options.format||`{name} ${n} {percentage}% | {status} {eta}`;this.multiBar=new F({clearOnComplete:!1,hideCursor:!0,format:i,barCompleteChar:"\u2588",barIncompleteChar:"\u2591",forceRedraw:!0,fps:Math.round(1e3/t.progress.updateIntervalMs)},k.shades_classic)}start(e){this.isActive=!0,this.startTime=Date.now(),console.log(o.blue(`
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.11.2");process.exit(0)}
2
+ import{b as f,d as v}from"./chunk-LY6PTRVL.js";import q,{MultiBar as F,Presets as k}from"cli-progress";import O from"ora";import o from"chalk";v();import{existsSync as w,readFileSync as y,writeFileSync as j,mkdirSync as W,unlinkSync as V}from"fs";import{join as p}from"path";import{homedir as C}from"os";var u={wizards:{enabled:!0,themes:["default","minimal","detailed"],defaultTheme:"default"},progress:{style:"multi-bar",updateIntervalMs:100,showETA:!0,colors:!0},completion:{maxSuggestions:10,historyWeight:.3,contextWeight:.7,fuzzyMatch:!0},streaming:{enabled:!0,bufferSize:100,updateIntervalMs:50}};function x(){return p(C(),".aqe")}function E(){return p(x(),"cli-config.json")}var g=null,d=0,T=5e3;function S(){return g?Date.now()-d<T:!1}function A(s){let e=[],t=s;if(typeof t.enabled!="boolean"&&t.enabled!==void 0&&e.push({path:"wizards.enabled",message:"must be a boolean"}),t.themes!==void 0)if(!Array.isArray(t.themes))e.push({path:"wizards.themes",message:"must be an array"});else{let r=["default","minimal","detailed"];for(let n of t.themes)r.includes(n)||e.push({path:"wizards.themes",message:`invalid theme: ${n}`})}return t.defaultTheme!==void 0&&(["default","minimal","detailed"].includes(t.defaultTheme)||e.push({path:"wizards.defaultTheme",message:`invalid theme: ${t.defaultTheme}`})),e}function P(s){let e=[],t=s;return t.style!==void 0&&(["multi-bar","single-bar","spinner"].includes(t.style)||e.push({path:"progress.style",message:`invalid style: ${t.style}`})),t.updateIntervalMs!==void 0&&(typeof t.updateIntervalMs!="number"||t.updateIntervalMs<10)&&e.push({path:"progress.updateIntervalMs",message:"must be a number >= 10"}),typeof t.showETA!="boolean"&&t.showETA!==void 0&&e.push({path:"progress.showETA",message:"must be a boolean"}),typeof t.colors!="boolean"&&t.colors!==void 0&&e.push({path:"progress.colors",message:"must be a boolean"}),e}function $(s){let e=[],t=s;return t.maxSuggestions!==void 0&&(typeof t.maxSuggestions!="number"||t.maxSuggestions<1)&&e.push({path:"completion.maxSuggestions",message:"must be a number >= 1"}),t.historyWeight!==void 0&&(typeof t.historyWeight!="number"||t.historyWeight<0||t.historyWeight>1)&&e.push({path:"completion.historyWeight",message:"must be a number between 0 and 1"}),t.contextWeight!==void 0&&(typeof t.contextWeight!="number"||t.contextWeight<0||t.contextWeight>1)&&e.push({path:"completion.contextWeight",message:"must be a number between 0 and 1"}),typeof t.fuzzyMatch!="boolean"&&t.fuzzyMatch!==void 0&&e.push({path:"completion.fuzzyMatch",message:"must be a boolean"}),e}function I(s){let e=[],t=s;return typeof t.enabled!="boolean"&&t.enabled!==void 0&&e.push({path:"streaming.enabled",message:"must be a boolean"}),t.bufferSize!==void 0&&(typeof t.bufferSize!="number"||t.bufferSize<1)&&e.push({path:"streaming.bufferSize",message:"must be a number >= 1"}),t.updateIntervalMs!==void 0&&(typeof t.updateIntervalMs!="number"||t.updateIntervalMs<10)&&e.push({path:"streaming.updateIntervalMs",message:"must be a number >= 10"}),e}function M(s){let e=[];if(typeof s!="object"||s===null)return{valid:!1,errors:[{path:"",message:"config must be an object"}]};let t=s;return t.wizards!==void 0&&(typeof t.wizards!="object"||t.wizards===null?e.push({path:"wizards",message:"must be an object"}):e.push(...A(t.wizards))),t.progress!==void 0&&(typeof t.progress!="object"||t.progress===null?e.push({path:"progress",message:"must be an object"}):e.push(...P(t.progress))),t.completion!==void 0&&(typeof t.completion!="object"||t.completion===null?e.push({path:"completion",message:"must be an object"}):e.push(...$(t.completion))),t.streaming!==void 0&&(typeof t.streaming!="object"||t.streaming===null?e.push({path:"streaming",message:"must be an object"}):e.push(...I(t.streaming))),{valid:e.length===0,errors:e}}var z=["__proto__","constructor","prototype"];function m(s,e){let t={...s};for(let r of Object.keys(e)){if(z.includes(r)){console.warn(`Security: Skipping forbidden key '${String(r)}' in configuration merge`);continue}let n=e[r],i=s[r];n!==void 0&&typeof n=="object"&&!Array.isArray(n)&&typeof i=="object"&&!Array.isArray(i)?t[r]=m(i,n):n!==void 0&&(t[r]=n)}return t}function D(){let s=E();if(!w(s))return{...u};try{let e=y(s,"utf-8"),t=f(e),r=M(t);return r.valid?m(u,t):(console.warn(`CLI config validation errors: ${r.errors.map(n=>`${n.path}: ${n.message}`).join(", ")}`),console.warn("Using default configuration"),{...u})}catch(e){return console.warn(`Failed to load CLI config: ${e instanceof Error?e.message:"Unknown error"}`),{...u}}}function c(){return S()||(g=D(),d=Date.now()),g}function B(){return process.stdout.isTTY===!0}function h(){let s=c();return process.env.NO_COLOR!==void 0?!1:process.env.FORCE_COLOR!==void 0?!0:s.progress.colors&&B()}var b=class{multiBar;agentBars=new Map;agentStates=new Map;fleetBar=null;startTime=Date.now();options;isActive=!1;constructor(e={}){let t=c(),r=h();this.options={title:"Fleet Progress",showEta:t.progress.showETA,showPercentage:!0,...e};let n=r?o.cyan("{bar}"):"{bar}",i=this.options.format||`{name} ${n} {percentage}% | {status} {eta}`;this.multiBar=new F({clearOnComplete:!1,hideCursor:!0,format:i,barCompleteChar:"\u2588",barIncompleteChar:"\u2591",forceRedraw:!0,fps:Math.round(1e3/t.progress.updateIntervalMs)},k.shades_classic)}start(e){this.isActive=!0,this.startTime=Date.now(),console.log(o.blue(`
3
3
  ${this.options.title}
4
4
  `)),this.fleetBar=this.multiBar.create(100,0,{name:o.white("Fleet Progress".padEnd(30)),status:"",eta:""})}addAgent(e){if(!this.isActive)return;this.agentStates.set(e.id,e);let t=this.multiBar.create(100,e.progress,{name:o.gray(this.truncateName(e.name,30).padEnd(30)),status:this.getStatusIcon(e.status),eta:e.eta?this.formatEta(e.eta):""});this.agentBars.set(e.id,t),this.updateFleetProgress()}updateAgent(e,t,r){if(!this.isActive)return;let n=this.agentStates.get(e),i=this.agentBars.get(e);!n||!i||(n.progress=Math.min(100,Math.max(0,t)),r?.status&&(n.status=r.status),r?.message&&(n.message=r.message),r?.eta!==void 0&&(n.eta=r.eta),i.update(n.progress,{name:this.getAgentNameDisplay(n),status:this.getStatusIcon(n.status),eta:n.eta?this.formatEta(n.eta):""}),this.updateFleetProgress())}completeAgent(e,t=!0){if(!this.isActive)return;let r=this.agentStates.get(e),n=this.agentBars.get(e);!r||!n||(r.status=t?"completed":"failed",r.progress=t?100:r.progress,n.update(r.progress,{name:this.getAgentNameDisplay(r),status:this.getStatusIcon(r.status),eta:""}),this.updateFleetProgress())}stop(){if(!this.isActive)return;this.isActive=!1,this.multiBar.stop();let e=Array.from(this.agentStates.values()).filter(i=>i.status==="completed").length,t=Array.from(this.agentStates.values()).filter(i=>i.status==="failed").length,r=this.agentStates.size,n=Date.now()-this.startTime;console.log(""),console.log(t===0?o.green(`All ${e}/${r} agents completed successfully (${this.formatDuration(n)})`):o.yellow(`${e}/${r} agents completed, ${t} failed (${this.formatDuration(n)})`)),console.log("")}updateFleetProgress(){if(!this.fleetBar)return;let e=Array.from(this.agentStates.values()),t=e.reduce((a,l)=>a+l.progress,0),r=e.length>0?Math.round(t/e.length):0,n=e.filter(a=>a.status==="completed").length,i=e.filter(a=>a.status==="running").length;this.fleetBar.update(r,{status:o.gray(`${n}/${e.length} complete, ${i} running`),eta:this.options.showEta?this.estimateFleetEta(e):""})}getAgentNameDisplay(e){let t=this.truncateName(e.name,26);switch(e.status){case"completed":return o.green(t.padEnd(30));case"failed":return o.red(t.padEnd(30));case"running":return o.yellow(t.padEnd(30));default:return o.gray(t.padEnd(30))}}getStatusIcon(e){switch(e){case"completed":return o.green("\u2713");case"failed":return o.red("\u2717");case"running":return o.yellow("\u25B6");default:return o.gray("\u25CB")}}truncateName(e,t){return e.length<=t?e:e.slice(0,t-3)+"..."}formatEta(e){return e<=0?"":e<1e3?`${e}ms`:e<6e4?`${Math.round(e/1e3)}s`:e<36e5?`${Math.round(e/6e4)}m`:`${Math.round(e/36e5)}h`}formatDuration(e){return e<1e3?`${e}ms`:e<6e4?`${(e/1e3).toFixed(1)}s`:e<36e5?`${(e/6e4).toFixed(1)}m`:`${(e/36e5).toFixed(1)}h`}estimateFleetEta(e){let t=e.filter(a=>a.status==="running"||a.status==="pending");if(t.length===0)return"";let r=t.map(a=>a.eta||0).filter(a=>a>0);if(r.length>0){let a=Math.max(...r);return o.gray(`ETA: ${this.formatEta(a)}`)}let n=Date.now()-this.startTime,i=t.reduce((a,l)=>a+l.progress,0)/t.length;if(i>0){let a=n/(i/100),l=Math.max(0,a-n);return o.gray(`ETA: ${this.formatEta(l)}`)}return""}};function X(s){let e=Date.now(),t=O({text:s,color:"cyan"}).start(),r=setInterval(()=>{let i=((Date.now()-e)/1e3).toFixed(1);t.text=`${s} (${i}s)`},100);r.unref?.();let n=()=>{clearInterval(r)};return{spinner:t,stop:()=>{n(),t.stop()},succeed:i=>{n();let a=((Date.now()-e)/1e3).toFixed(1);t.succeed(i||`${s} (${a}s)`)},fail:i=>{n();let a=((Date.now()-e)/1e3).toFixed(1);t.fail(i||`${s} failed (${a}s)`)}}}export{b as a,X as b};
@@ -1,5 +1,5 @@
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.11.1");process.exit(0)}
2
- import{c as e}from"./chunk-7SRSOZMP.js";function r(t){t.exec(n)}var n,a=e(()=>{"use strict";n=`
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.11.2");process.exit(0)}
2
+ import{c as e}from"./chunk-LIEA5EON.js";function r(t){t.exec(n)}var n,a=e(()=>{"use strict";n=`
3
3
  -- Negative pattern records (ADR-110 kept nulls)
4
4
  CREATE TABLE IF NOT EXISTS qe_pattern_nulls (
5
5
  id TEXT PRIMARY KEY,
@@ -1,5 +1,5 @@
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.11.1");process.exit(0)}
2
- import{a as w,b as A,c as O,e as D,f as z}from"./chunk-W6RS5S4Q.js";import{b as S,d as $}from"./chunk-N6NSZG7Z.js";import{a as N,c as F}from"./chunk-QEDS3MOJ.js";import{i as v}from"./chunk-B6U56VWG.js";import*as I from"node:path";z();$();var P=["function","module","test","file","class"],L=["calls","imports","tests","depends_on","covers"],b=class{ensureSchema(e){e.transaction(()=>{e.exec(w),e.exec(A),e.exec(O)})()}schemaExists(e){return D(e)}getNodeTypes(){return P}getEdgeTypes(){return L}isValidNodeType(e){return P.includes(e)}isValidEdgeType(e){return L.includes(e)}getStats(e){if(!this.schemaExists(e))return{nodeCount:0,edgeCount:0};let t=e.prepare("SELECT COUNT(*) as count FROM hypergraph_nodes").get().count,r=e.prepare("SELECT COUNT(*) as count FROM hypergraph_edges").get().count;return{nodeCount:t,edgeCount:r}}dropSchema(e){let t=e.prepare("SELECT COUNT(*) as cnt FROM hypergraph_nodes").get()?.cnt??0,r=e.prepare("SELECT COUNT(*) as cnt FROM hypergraph_edges").get()?.cnt??0;if(t>0||r>0)throw new Error(`REFUSING to drop hypergraph schema: tables contain data (${t} nodes, ${r} edges). Backup and manually drop if needed.`);e.transaction(()=>{e.exec("DROP TABLE IF EXISTS hypergraph_edges"),e.exec("DROP TABLE IF EXISTS hypergraph_nodes")})()}};function C(n){return{id:n.id,type:n.type,name:n.name,file_path:n.filePath??null,line_start:n.lineStart??null,line_end:n.lineEnd??null,complexity:n.complexity??null,coverage:n.coverage??null,metadata:n.metadata?JSON.stringify(n.metadata):null,embedding:n.embedding?U(n.embedding):null}}function T(n){return{id:n.id,type:n.type,name:n.name,filePath:n.file_path??void 0,lineStart:n.line_start??void 0,lineEnd:n.line_end??void 0,complexity:n.complexity??void 0,coverage:n.coverage??void 0,metadata:n.metadata?S(n.metadata):void 0,embedding:n.embedding?W(n.embedding):void 0,createdAt:n.created_at,updatedAt:n.updated_at}}function M(n){return{id:n.id,source_id:n.sourceId,target_id:n.targetId,type:n.type,weight:n.weight??1,properties:n.properties?JSON.stringify(n.properties):null}}function H(n){return{id:n.id,sourceId:n.source_id,targetId:n.target_id,type:n.type,weight:n.weight,properties:n.properties?S(n.properties):void 0,createdAt:n.created_at}}function x(n,e,t){return`${n}--${t}-->${e}`}function U(n){let e=Buffer.alloc(n.length*4);for(let t=0;t<n.length;t++)e.writeFloatLE(n[t],t*4);return e}function W(n){let e=[],t=n.length/4;for(let r=0;r<t;r++)e.push(n.readFloatLE(r*4));return e}F();var B={maxTraversalDepth:10,maxQueryResults:1e3,enableVectorSearch:!1},R=class{config;schemaManager;initialized=!1;constructor(e){this.config={...B,...e},this.schemaManager=new b}async initialize(){this.initialized||(this.schemaManager.ensureSchema(this.config.db),this.initialized=!0)}isInitialized(){return this.initialized}async addNode(e){this.ensureInitialized();let t=v(),r={id:t,...e},s=C(r);return this.config.db.prepare(`
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.11.2");process.exit(0)}
2
+ import{a as w,b as A,c as O,e as D,f as z}from"./chunk-Y4M2HMPR.js";import{b as S,d as $}from"./chunk-LY6PTRVL.js";import{a as N,c as F}from"./chunk-FYY7OJ6Y.js";import{i as v}from"./chunk-76RO2RHG.js";import*as I from"node:path";z();$();var P=["function","module","test","file","class"],L=["calls","imports","tests","depends_on","covers"],b=class{ensureSchema(e){e.transaction(()=>{e.exec(w),e.exec(A),e.exec(O)})()}schemaExists(e){return D(e)}getNodeTypes(){return P}getEdgeTypes(){return L}isValidNodeType(e){return P.includes(e)}isValidEdgeType(e){return L.includes(e)}getStats(e){if(!this.schemaExists(e))return{nodeCount:0,edgeCount:0};let t=e.prepare("SELECT COUNT(*) as count FROM hypergraph_nodes").get().count,r=e.prepare("SELECT COUNT(*) as count FROM hypergraph_edges").get().count;return{nodeCount:t,edgeCount:r}}dropSchema(e){let t=e.prepare("SELECT COUNT(*) as cnt FROM hypergraph_nodes").get()?.cnt??0,r=e.prepare("SELECT COUNT(*) as cnt FROM hypergraph_edges").get()?.cnt??0;if(t>0||r>0)throw new Error(`REFUSING to drop hypergraph schema: tables contain data (${t} nodes, ${r} edges). Backup and manually drop if needed.`);e.transaction(()=>{e.exec("DROP TABLE IF EXISTS hypergraph_edges"),e.exec("DROP TABLE IF EXISTS hypergraph_nodes")})()}};function C(n){return{id:n.id,type:n.type,name:n.name,file_path:n.filePath??null,line_start:n.lineStart??null,line_end:n.lineEnd??null,complexity:n.complexity??null,coverage:n.coverage??null,metadata:n.metadata?JSON.stringify(n.metadata):null,embedding:n.embedding?U(n.embedding):null}}function T(n){return{id:n.id,type:n.type,name:n.name,filePath:n.file_path??void 0,lineStart:n.line_start??void 0,lineEnd:n.line_end??void 0,complexity:n.complexity??void 0,coverage:n.coverage??void 0,metadata:n.metadata?S(n.metadata):void 0,embedding:n.embedding?W(n.embedding):void 0,createdAt:n.created_at,updatedAt:n.updated_at}}function M(n){return{id:n.id,source_id:n.sourceId,target_id:n.targetId,type:n.type,weight:n.weight??1,properties:n.properties?JSON.stringify(n.properties):null}}function H(n){return{id:n.id,sourceId:n.source_id,targetId:n.target_id,type:n.type,weight:n.weight,properties:n.properties?S(n.properties):void 0,createdAt:n.created_at}}function x(n,e,t){return`${n}--${t}-->${e}`}function U(n){let e=Buffer.alloc(n.length*4);for(let t=0;t<n.length;t++)e.writeFloatLE(n[t],t*4);return e}function W(n){let e=[],t=n.length/4;for(let r=0;r<t;r++)e.push(n.readFloatLE(r*4));return e}F();var B={maxTraversalDepth:10,maxQueryResults:1e3,enableVectorSearch:!1},R=class{config;schemaManager;initialized=!1;constructor(e){this.config={...B,...e},this.schemaManager=new b}async initialize(){this.initialized||(this.schemaManager.ensureSchema(this.config.db),this.initialized=!0)}isInitialized(){return this.initialized}async addNode(e){this.ensureInitialized();let t=v(),r={id:t,...e},s=C(r);return this.config.db.prepare(`
3
3
  INSERT INTO hypergraph_nodes (id, type, name, file_path, line_start, line_end, complexity, coverage, metadata, embedding)
4
4
  VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
5
5
  `).run(s.id,s.type,s.name,s.file_path,s.line_start,s.line_end,s.complexity,s.coverage,s.metadata,s.embedding),t}async addEdge(e){this.ensureInitialized();let t=x(e.sourceId,e.targetId,e.type),r={id:t,...e},s=M(r);return this.config.db.prepare(`
@@ -1,2 +1,2 @@
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.11.1");process.exit(0)}
2
- import{c as f}from"./chunk-7SRSOZMP.js";import*as o from"fs";import*as n from"path";function u(){t=null}function g(c=process.cwd()){if(t)return t;if(process.env.AQE_PROJECT_ROOT)return t=process.env.AQE_PROJECT_ROOT,t;let l=c,a=n.parse(l).root,e=l,i=null,s=null,r=null;for(;e!==a;)o.existsSync(n.join(e,".agentic-qe"))&&i===null&&(i=e),o.existsSync(n.join(e,".git"))&&s===null&&(s=e),o.existsSync(n.join(e,"package.json"))&&(r=e),e=n.dirname(e);return i?t=i:s?t=s:r?t=r:t=process.cwd(),t}var t,p=f(()=>{"use strict";t=null});export{u as a,g as b,p as c};
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.11.2");process.exit(0)}
2
+ import{c as f}from"./chunk-LIEA5EON.js";import*as o from"fs";import*as n from"path";function u(){t=null}function g(c=process.cwd()){if(t)return t;if(process.env.AQE_PROJECT_ROOT)return t=process.env.AQE_PROJECT_ROOT,t;let l=c,a=n.parse(l).root,e=l,i=null,s=null,r=null;for(;e!==a;)o.existsSync(n.join(e,".agentic-qe"))&&i===null&&(i=e),o.existsSync(n.join(e,".git"))&&s===null&&(s=e),o.existsSync(n.join(e,"package.json"))&&(r=e),e=n.dirname(e);return i?t=i:s?t=s:r?t=r:t=process.cwd(),t}var t,p=f(()=>{"use strict";t=null});export{u as a,g as b,p as c};
@@ -1,2 +1,2 @@
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.11.1");process.exit(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.11.2");process.exit(0)}
2
2
  var h=class{executionHistory=[];learnedDurations=new Map;runCount=0;lastPrunedCount=0;learningRate;maxHistorySize;constructor(t){this.learningRate=t?.learningRate??.3,this.maxHistorySize=t?.maxHistorySize??1e4}buildTestDAG(t){let e=new Map,n=new Map;for(let i of t){let s=this.applyLearnedDuration(i);e.set(s.id,s),n.set(s.id,[])}for(let i of t)for(let s of i.dependencies){if(!e.has(s))throw new Error(`Test '${i.id}' depends on '${s}' which does not exist in the test set`);n.get(s).push(i.id)}let o=this.computeCriticalPath(e,n),a=this.computeParallelGroups(e,n);return{nodes:e,edges:n,criticalPath:o,parallelGroups:a}}findCriticalPath(t){return t.criticalPath.map(e=>t.nodes.get(e)).filter(e=>e!==void 0)}findParallelBranches(t){return t.parallelGroups.map(e=>e.map(n=>t.nodes.get(n)).filter(n=>n!==void 0))}pruneByMinCut(t,e){let n=this.sumDurations(t.nodes);if(n<=e)return this.lastPrunedCount=0,t;let o=this.computeAttentionScores(t),a=Array.from(o.entries()).sort((r,l)=>r[1]-l[1]),i=new Set(t.criticalPath),s=new Set,c=n;for(let[r]of a){if(c<=e)break;if(i.has(r)||(t.edges.get(r)??[]).some(p=>!s.has(p)))continue;let d=t.nodes.get(r);d&&(s.add(r),c-=d.estimatedDuration)}this.lastPrunedCount=s.size;let u=Array.from(t.nodes.values()).filter(r=>!s.has(r.id));return this.buildTestDAG(u)}schedule(t){if(t.length===0)return{phases:[],totalEstimatedTime:0,criticalPathTime:0,parallelism:0};let e=this.buildTestDAG(t),o=this.findParallelBranches(e).map(u=>({tests:u,canRunInParallel:u.length>1})),a=this.computeCriticalPathDuration(e),i=this.sumDurations(e.nodes),s=o.reduce((u,r)=>r.canRunInParallel?u+Math.max(...r.tests.map(l=>l.estimatedDuration)):u+r.tests.reduce((l,d)=>l+d.estimatedDuration,0),0),c=s>0?i/s:1;return this.runCount++,{phases:o,totalEstimatedTime:s,criticalPathTime:a,parallelism:c}}getOptimizationStats(){return{totalTests:0,criticalPathLength:0,parallelGroupCount:0,prunedTests:this.lastPrunedCount,estimatedTimeSaved:0,historicalRuns:this.runCount,usingNativeBackend:!1}}recordExecution(t,e,n){this.executionHistory.push({testId:t,actualDuration:e,result:n,timestamp:Date.now()}),this.executionHistory.length>this.maxHistorySize&&(this.executionHistory=this.executionHistory.slice(-this.maxHistorySize));let o=this.learnedDurations.get(t);o!==void 0?this.learnedDurations.set(t,o*(1-this.learningRate)+e*this.learningRate):this.learnedDurations.set(t,e)}getLearnedDuration(t){return this.learnedDurations.get(t)}isNativeBackendAvailable(){return!1}computeCriticalPath(t,e){let n=this.topologicalSort(t,e);if(n.length===0)return[];let o=new Map,a=new Map;for(let r of n)o.set(r,t.get(r).estimatedDuration),a.set(r,null);for(let r of n){let l=o.get(r);for(let d of e.get(r)??[]){let p=t.get(d);if(!p)continue;let g=l+p.estimatedDuration;g>(o.get(d)??0)&&(o.set(d,g),a.set(d,r))}}let i=0,s=null;for(let[r,l]of o)l>i&&(i=l,s=r);if(!s)return[];let c=[],u=s;for(;u!==null;)c.unshift(u),u=a.get(u)??null;return c}computeCriticalPathDuration(t){return t.criticalPath.reduce((e,n)=>e+(t.nodes.get(n)?.estimatedDuration??0),0)}computeParallelGroups(t,e){let n=this.topologicalSort(t,e);if(n.length===0)return[];let o=new Map;for(let[u,r]of t)o.set(u,new Set(r.dependencies));let a=new Map;for(let u of n){let r=-1;for(let l of o.get(u)??new Set){let d=a.get(l);d!==void 0&&d>r&&(r=d)}a.set(u,r+1)}let i=new Map;for(let u of n){let r=a.get(u)??0;i.has(r)||i.set(r,[]),i.get(r).push(u)}let s=Math.max(...Array.from(i.keys()),-1),c=[];for(let u=0;u<=s;u++){let r=i.get(u);r&&r.length>0&&c.push(r)}return c}computeAttentionScores(t){let e=new Map,n=this.countTransitiveDependents(t);for(let[o,a]of t.nodes){let i=a.lastResult==="fail"?2:1,s=n.get(o)??0;e.set(o,a.priority*i*(1+s))}return e}countTransitiveDependents(t){let e=new Map,n=new Map,o=a=>{if(n.has(a))return n.get(a);let i=new Set;for(let s of t.edges.get(a)??[]){i.add(s);for(let c of o(s))i.add(c)}return n.set(a,i),i};for(let a of t.nodes.keys())e.set(a,o(a).size);return e}topologicalSort(t,e){let n=new Map;for(let i of t.keys())n.set(i,0);for(let i of e.values())for(let s of i)n.has(s)&&n.set(s,(n.get(s)??0)+1);let o=[];for(let[i,s]of n)s===0&&o.push(i);let a=[];for(;o.length>0;){let i=o.shift();a.push(i);for(let s of e.get(i)??[]){let c=(n.get(s)??0)-1;n.set(s,c),c===0&&o.push(s)}}if(a.length!==t.size)throw new Error(`Cycle detected in test DAG: sorted ${a.length} of ${t.size} nodes`);return a}applyLearnedDuration(t){let e=this.learnedDurations.get(t.id);return e!==void 0?{...t,estimatedDuration:Math.round(e)}:t}sumDurations(t){let e=0;for(let n of t.values())e+=n.estimatedDuration;return e}};function m(f){return new h(f)}export{h as a,m as b};
@@ -1,2 +1,2 @@
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.11.1");process.exit(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.11.2");process.exit(0)}
2
2
  import{isIP as o}from"net";import{lookup as n}from"dns/promises";var f=[/^10\./,/^172\.(1[6-9]|2\d|3[01])\./,/^192\.168\./,/^127\./,/^0\./,/^169\.254\./,/^::1$/,/^fc00:/,/^fe80:/,/^fd[0-9a-f]{2}:/i];function t(r){return f.some(s=>s.test(r))}async function u(r){if(process.env.AQE_HOOKS_SSRF_DISABLED==="true")return{safe:!0};let s;try{s=new URL(r)}catch{return{safe:!1,reason:`Invalid URL: ${r}`}}let e=s.hostname.replace(/^\[|\]$/g,"");if(o(e))return t(e)?{safe:!1,reason:`Private IP blocked: ${e}`}:{safe:!0};try{let a=await n(e);if(t(a.address))return{safe:!1,reason:`DNS resolves to private IP: ${a.address}`}}catch(a){return{safe:!1,reason:`DNS lookup failed for ${e}: ${a.message}`}}return{safe:!0}}export{t as a,u as b};
@@ -1,2 +1,2 @@
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.11.1");process.exit(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.11.2");process.exit(0)}
2
2
  var u={0:{tier:0,name:"Agent Booster",description:"Mechanical code transforms via Rust/WASM",useCases:["var-to-const conversion","add-types","remove-console statements","promise-to-async","cjs-to-esm","func-to-arrow"],typicalLatencyMs:1,relativeCost:0,exampleModels:["agent-booster-wasm","agent-booster-typescript"],requiresNetwork:!1,complexityRange:[0,10]},1:{tier:1,name:"Haiku",description:"Fast, cost-effective for simple tasks",useCases:["Simple bug fixes","Code formatting","Documentation updates","Basic refactoring","Test generation (simple)"],typicalLatencyMs:500,relativeCost:1,exampleModels:["claude-haiku-4-5-20251001","gpt-4o-mini","gemini-flash"],requiresNetwork:!0,complexityRange:[10,35]},2:{tier:2,name:"Sonnet",description:"Balanced capability for complex reasoning",useCases:["Feature implementation","Complex refactoring","Security analysis","Performance optimization","Test generation (complex)"],typicalLatencyMs:3e3,relativeCost:2,exampleModels:["claude-sonnet-4-6","gpt-4o","gemini-pro"],requiresNetwork:!0,complexityRange:[35,70]},3:{tier:3,name:"Sonnet Extended",description:"Extended context for multi-step workflows",useCases:["Multi-file refactoring","Workflow orchestration","Cross-domain coordination","Large codebase analysis"],typicalLatencyMs:7e3,relativeCost:3,exampleModels:["claude-sonnet-4-6"],requiresNetwork:!0,complexityRange:[60,85]},4:{tier:4,name:"Opus",description:"Maximum capability for critical decisions",useCases:["Architecture design","Security audits","Complex algorithm design","Critical bug analysis","System-wide refactoring"],typicalLatencyMs:5e3,relativeCost:4,exampleModels:["claude-opus-4-7","gpt-4-turbo"],requiresNetwork:!0,complexityRange:[75,100]}},d={enabled:!0,tierBudgets:{0:{tier:0,maxCostPerRequest:0,maxRequestsPerHour:1e4,maxRequestsPerDay:1e5,maxDailyCostUsd:0,enabled:!0},1:{tier:1,maxCostPerRequest:.01,maxRequestsPerHour:100,maxRequestsPerDay:1e3,maxDailyCostUsd:5,enabled:!0},2:{tier:2,maxCostPerRequest:.1,maxRequestsPerHour:50,maxRequestsPerDay:500,maxDailyCostUsd:20,enabled:!0},3:{tier:3,maxCostPerRequest:.5,maxRequestsPerHour:20,maxRequestsPerDay:100,maxDailyCostUsd:30,enabled:!0},4:{tier:4,maxCostPerRequest:2,maxRequestsPerHour:10,maxRequestsPerDay:50,maxDailyCostUsd:50,enabled:!0}},maxDailyCostUsd:100,warningThreshold:.8,onBudgetExceeded:"downgrade",onBudgetWarning:"warn",allowCriticalOverrides:!0},y={budgetConfig:d,enableAgentBooster:!0,agentBoosterThreshold:.7,enableAutoRouting:!0,complexityThresholds:{0:10,1:35,2:70,3:85,4:100},allowManualOverrides:!0,enableDecisionCache:!0,decisionCacheTtlMs:300*1e3,enableMetrics:!0,maxDecisionTimeMs:10,fallbackTier:2,tierModels:{0:"agent-booster",1:"claude-haiku-4-5-20251001",2:"claude-sonnet-4-6",3:"claude-sonnet-4-6",4:"claude-opus-4-7"}},r=class extends Error{constructor(e,t,l){super(e);this.code=t;this.cause=l;this.name="ModelRouterError"}code;cause},a=class extends r{constructor(e,t,l){super(e,"BUDGET_EXCEEDED");this.tier=t;this.usage=l;this.name="BudgetExceededError"}tier;usage},i=class extends r{constructor(o,e){super(o,"COMPLEXITY_ANALYSIS_ERROR",e),this.name="ComplexityAnalysisError"}},s=class extends r{constructor(e,t){super(e,"ROUTING_TIMEOUT");this.timeoutMs=t;this.name="RoutingTimeoutError"}timeoutMs};export{u as a,d as b,y as c,r as d,a as e,i as f,s as g};
@@ -1,2 +1,2 @@
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.11.1");process.exit(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.11.2");process.exit(0)}
2
2
  function c(r,e,o){let n=new Error(r);return n.name="LLMError",n.code=e,n.provider=o?.provider,n.model=o?.model,n.retryable=o?.retryable??!1,n.retryAfterMs=o?.retryAfterMs,n.cause=o?.cause,n}function p(r){return r instanceof Error&&"code"in r&&typeof r.code=="string"}var a={"claude-sonnet-4-5":{canonical:"Claude Sonnet 4.5",family:"claude",tier:"standard",providers:{anthropic:"claude-sonnet-4-5-20250929",openrouter:"anthropic/claude-sonnet-4.5",bedrock:"anthropic.claude-sonnet-4-5-v2:0"}},"claude-opus-4":{canonical:"Claude Opus 4",family:"claude",tier:"flagship",providers:{anthropic:"claude-opus-4-20250514",openrouter:"anthropic/claude-opus-4",bedrock:"anthropic.claude-opus-4-v1:0"}},"claude-opus-4-5":{canonical:"Claude Opus 4.5",family:"claude",tier:"flagship",providers:{anthropic:"claude-opus-4-5-20251101",openrouter:"anthropic/claude-opus-4.5",bedrock:"anthropic.claude-opus-4-5-v1:0"}},"claude-haiku-3-5":{canonical:"Claude Haiku 3.5",family:"claude",tier:"economy",providers:{anthropic:"claude-3-5-haiku-20241022",openrouter:"anthropic/claude-3.5-haiku",bedrock:"anthropic.claude-3-5-haiku-v1:0"}},"claude-sonnet-4":{canonical:"Claude Sonnet 4",family:"claude",tier:"standard",providers:{anthropic:"claude-sonnet-4-20250514",openrouter:"anthropic/claude-sonnet-4",bedrock:"anthropic.claude-sonnet-4-v1:0"}},"claude-opus-4-7":{canonical:"Claude Opus 4.7",family:"claude",tier:"flagship",providers:{anthropic:"claude-opus-4-7",openrouter:"anthropic/claude-opus-4.7",bedrock:"anthropic.claude-opus-4-7-v1:0"}},"claude-sonnet-4-6":{canonical:"Claude Sonnet 4.6",family:"claude",tier:"standard",providers:{anthropic:"claude-sonnet-4-6",openrouter:"anthropic/claude-sonnet-4.6",bedrock:"anthropic.claude-sonnet-4-6-v1:0"}},"claude-haiku-4-5":{canonical:"Claude Haiku 4.5",family:"claude",tier:"economy",providers:{anthropic:"claude-haiku-4-5-20251001",openrouter:"anthropic/claude-haiku-4.5",bedrock:"anthropic.claude-haiku-4-5-v1:0"}},"gpt-4o":{canonical:"GPT-4o",family:"gpt",tier:"standard",providers:{openai:"gpt-4o",azure:"gpt-4o",openrouter:"openai/gpt-4o"}},"gpt-4o-mini":{canonical:"GPT-4o Mini",family:"gpt",tier:"economy",providers:{openai:"gpt-4o-mini",azure:"gpt-4o-mini",openrouter:"openai/gpt-4o-mini"}},"gpt-4-turbo":{canonical:"GPT-4 Turbo",family:"gpt",tier:"premium",providers:{openai:"gpt-4-turbo",azure:"gpt-4-turbo",openrouter:"openai/gpt-4-turbo"}},"gpt-4":{canonical:"GPT-4",family:"gpt",tier:"premium",providers:{openai:"gpt-4",azure:"gpt-4",openrouter:"openai/gpt-4"}},o1:{canonical:"OpenAI o1",family:"gpt",tier:"flagship",providers:{openai:"o1",azure:"o1",openrouter:"openai/o1"}},"o1-mini":{canonical:"OpenAI o1 Mini",family:"gpt",tier:"standard",providers:{openai:"o1-mini",azure:"o1-mini",openrouter:"openai/o1-mini"}},"gemini-pro":{canonical:"Gemini Pro",family:"gemini",tier:"standard",providers:{gemini:"gemini-pro",openrouter:"google/gemini-pro"}},"gemini-pro-1.5":{canonical:"Gemini Pro 1.5",family:"gemini",tier:"standard",providers:{gemini:"gemini-1.5-pro",openrouter:"google/gemini-pro-1.5"}},"gemini-flash-1.5":{canonical:"Gemini Flash 1.5",family:"gemini",tier:"economy",providers:{gemini:"gemini-1.5-flash",openrouter:"google/gemini-flash-1.5"}},"gemini-ultra":{canonical:"Gemini Ultra",family:"gemini",tier:"flagship",providers:{gemini:"gemini-ultra",openrouter:"google/gemini-ultra"}},llama3:{canonical:"Llama 3",family:"llama",tier:"economy",providers:{ollama:"llama3",openrouter:"meta-llama/llama-3-8b-instruct"}},"llama3.1":{canonical:"Llama 3.1",family:"llama",tier:"economy",providers:{ollama:"llama3.1",openrouter:"meta-llama/llama-3.1-8b-instruct"}},codellama:{canonical:"CodeLlama",family:"llama",tier:"economy",providers:{ollama:"codellama",openrouter:"meta-llama/codellama-34b-instruct"}},mistral:{canonical:"Mistral",family:"mistral",tier:"economy",providers:{ollama:"mistral",openrouter:"mistralai/mistral-7b-instruct"}},mixtral:{canonical:"Mixtral",family:"mistral",tier:"standard",providers:{ollama:"mixtral",openrouter:"mistralai/mixtral-8x7b-instruct"}},phi3:{canonical:"Phi-3",family:"phi",tier:"economy",providers:{ollama:"phi3",azure:"phi-3-mini-128k-instruct"}},qwen2:{canonical:"Qwen 2",family:"qwen",tier:"economy",providers:{ollama:"qwen2",openrouter:"qwen/qwen-2-7b-instruct"}}};function l(){let r=new Map;for(let[e,o]of Object.entries(a)){r.set(e,e),r.set(e.toLowerCase(),e);for(let[n,t]of Object.entries(o.providers))t&&(r.set(t,e),r.set(t.toLowerCase(),e),r.set(`${n}/${t}`,e),r.set(`${n}/${t}`.toLowerCase(),e))}return r}var i=l();function m(r,e){let o=s(r),n=a[o];if(!n)throw new Error(`Unknown model: ${r}`);let t=n.providers[e];if(!t)throw new Error(`Model '${o}' (${n.canonical}) is not available on provider '${e}'`);return t}function s(r){let e=i.get(r);if(e||(e=i.get(r.toLowerCase()),e))return e;let o=[/^anthropic\//i,/^openai\//i,/^google\//i,/^meta-llama\//i,/^mistralai\//i,/^qwen\//i];for(let n of o){let t=r.replace(n,"");if(e=i.get(t),e||(e=i.get(t.toLowerCase()),e))return e}throw new Error(`Unknown model ID: ${r}`)}function d(r){try{let e=s(r);return a[e]}catch{return}}export{c as a,p as b,m as c,s as d,d as e};