agentic-qe 3.15.12 → 3.15.14
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.
- package/.claude/helpers/brain-checkpoint.cjs +124 -5
- package/.claude/skills/skills-manifest.json +1 -1
- package/CHANGELOG.md +196 -0
- package/assets/skills/skills-manifest.json +1 -1
- package/dist/cli/bundle.js +6 -6
- package/dist/cli/chunks/adapter-23KA2YW7.js +2 -0
- package/dist/cli/chunks/{agent-booster-wasm-5VZCKTIJ.js → agent-booster-wasm-2DLAEZK6.js} +2 -2
- package/dist/cli/chunks/{agent-handler-K3C6CQCD.js → agent-handler-P3IY7XEE.js} +2 -2
- package/dist/cli/chunks/{agent-memory-branch-NVFQ25WS.js → agent-memory-branch-WWKC2H3G.js} +2 -2
- package/dist/cli/chunks/aqe-learning-engine-MUICAXW5.js +2 -0
- package/dist/cli/chunks/{arena-TSZVDSXS.js → arena-4BMFF6BS.js} +4 -4
- package/dist/cli/chunks/{arena-QGWIJADQ.js → arena-EIV5OALF.js} +2 -2
- package/dist/cli/chunks/{audit-KIEE2SHJ.js → audit-DNTI453H.js} +3 -3
- package/dist/cli/chunks/base-XPWGYDKD.js +2 -0
- package/dist/cli/chunks/{better-sqlite3-BNB32NW3.js → better-sqlite3-TQBQGNC6.js} +2 -2
- package/dist/cli/chunks/brain-handler-HY57CNAO.js +95 -0
- package/dist/cli/chunks/{branch-enumerator-LZ7UXKAY.js → branch-enumerator-THPMZPHQ.js} +2 -2
- package/dist/cli/chunks/{browser-VDHAW4RK.js → browser-O6JJOZCK.js} +2 -2
- package/dist/cli/chunks/browser-workflow-UMQVBVGK.js +2 -0
- package/dist/cli/chunks/{chunk-4PU5GTZW.js → chunk-2HPNGK7A.js} +2 -2
- package/dist/cli/chunks/{chunk-MCPXNUDK.js → chunk-2IJO3657.js} +2 -2
- package/dist/cli/chunks/{chunk-4Y6OEBJZ.js → chunk-2QLE6NDW.js} +1 -1
- package/dist/cli/chunks/{chunk-DZGPUGUG.js → chunk-2UZBLC5H.js} +2 -2
- package/dist/cli/chunks/{chunk-5A66EGEW.js → chunk-2W5MQDHM.js} +2 -2
- package/dist/cli/chunks/{chunk-JRYWLOBD.js → chunk-3FITMWWJ.js} +2 -2
- package/dist/cli/chunks/{chunk-RCOLPF3B.js → chunk-3TF27MG5.js} +2 -2
- package/dist/cli/chunks/{chunk-KGA7VAI4.js → chunk-3XACRXBY.js} +2 -2
- package/dist/cli/chunks/{chunk-SQVZ3TRU.js → chunk-43XHGWYH.js} +2 -2
- package/dist/cli/chunks/{chunk-JR6CUKAI.js → chunk-4RPBODN5.js} +2 -2
- package/dist/cli/chunks/{chunk-C3YOVASQ.js → chunk-4T7XV5KQ.js} +1 -1
- package/dist/cli/chunks/{chunk-N7O3PF6Y.js → chunk-4WLIOPHX.js} +2 -2
- package/dist/cli/chunks/{chunk-PGSJBXTD.js → chunk-52KOPIMI.js} +2 -2
- package/dist/cli/chunks/{chunk-4KUOYDY2.js → chunk-56NSE3LJ.js} +2 -2
- package/dist/cli/chunks/{chunk-3IU4LDZR.js → chunk-57DRT6UA.js} +2 -2
- package/dist/cli/chunks/{chunk-2JYUA27M.js → chunk-57FX3GP6.js} +1 -1
- package/dist/cli/chunks/{chunk-7QEUHNKO.js → chunk-5PLBQZ5J.js} +1 -1
- package/dist/cli/chunks/{chunk-VF7FTD64.js → chunk-5Y7UFHJD.js} +1 -1
- package/dist/cli/chunks/{chunk-7JFDLL2F.js → chunk-5Z4MO2F3.js} +1 -1
- package/dist/cli/chunks/chunk-65EE2EST.js +8 -0
- package/dist/cli/chunks/{chunk-66PXR3NI.js → chunk-6NIGSY5L.js} +2 -2
- package/dist/cli/chunks/chunk-6O63ZTVX.js +3 -0
- package/dist/cli/chunks/{chunk-ZYOYR3UR.js → chunk-6OI5SK7M.js} +1 -1
- package/dist/cli/chunks/{chunk-5TAEW5OV.js → chunk-6P4Q4RTC.js} +1 -1
- package/dist/cli/chunks/{chunk-W5HQIYQU.js → chunk-7724KXM2.js} +3 -3
- package/dist/cli/chunks/{chunk-A2JCRXTK.js → chunk-7MISCSL5.js} +2 -2
- package/dist/cli/chunks/{chunk-OHVYINGM.js → chunk-7MUO4DEH.js} +3 -3
- package/dist/cli/chunks/{chunk-QCPVUNN3.js → chunk-7QUSNBAA.js} +2 -2
- package/dist/cli/chunks/{chunk-YUA6ZKKY.js → chunk-7SQTLUEN.js} +2 -2
- package/dist/cli/chunks/{chunk-CA5UNWQF.js → chunk-7T6L3LFN.js} +2 -2
- package/dist/cli/chunks/{chunk-UREDS662.js → chunk-7TH4PJSU.js} +2 -2
- package/dist/cli/chunks/{chunk-TVA5GRIU.js → chunk-7Y3LXH57.js} +2 -2
- package/dist/cli/chunks/{chunk-A5Y7DAVQ.js → chunk-A2T56XVL.js} +2 -2
- package/dist/cli/chunks/{chunk-ZROAMFX2.js → chunk-AJVLVF7V.js} +2 -2
- package/dist/cli/chunks/{chunk-26672ISV.js → chunk-ARRBXCII.js} +2 -2
- package/dist/cli/chunks/{chunk-5S4UIDFK.js → chunk-AYLEH2UF.js} +1 -1
- package/dist/cli/chunks/{chunk-DRCBRUGN.js → chunk-BBYJBZHG.js} +2 -2
- package/dist/cli/chunks/{chunk-BMG2JLSQ.js → chunk-BM3EJLMV.js} +2 -2
- package/dist/cli/chunks/{chunk-6QRI3JVE.js → chunk-BNG4J3CE.js} +2 -2
- package/dist/cli/chunks/{chunk-EN7GRVEQ.js → chunk-BPDAQB3F.js} +2 -2
- package/dist/cli/chunks/{chunk-J7Y7ZBIT.js → chunk-BQJ7CV53.js} +9 -9
- package/dist/cli/chunks/{chunk-ADUAJIAU.js → chunk-C3OIBFAA.js} +2 -2
- package/dist/cli/chunks/{chunk-4LWMAAWK.js → chunk-CAZM63TP.js} +2 -2
- package/dist/cli/chunks/{chunk-UZED4YZ5.js → chunk-CIINJHOX.js} +1 -1
- package/dist/cli/chunks/{chunk-C74M4WUI.js → chunk-CPPYZYXC.js} +2 -2
- package/dist/cli/chunks/chunk-D3ZZ2NLL.js +62 -0
- package/dist/cli/chunks/{chunk-U7ZHDGXG.js → chunk-D5GB5PUU.js} +1 -1
- package/dist/cli/chunks/{chunk-HZBXJFGN.js → chunk-DLTB5KCR.js} +2 -2
- package/dist/cli/chunks/{chunk-NNBQZR73.js → chunk-DRLSJJIC.js} +2 -2
- package/dist/cli/chunks/{chunk-HLGFHHWV.js → chunk-DSQESXL4.js} +2 -2
- package/dist/cli/chunks/{chunk-LFBA735S.js → chunk-E2JLAW3U.js} +3 -3
- package/dist/cli/chunks/{chunk-PT2NXS43.js → chunk-E3QIQMMN.js} +1 -1
- package/dist/cli/chunks/{chunk-35MIUSXQ.js → chunk-E7OR6V3V.js} +2 -2
- package/dist/cli/chunks/{chunk-G24SWTAX.js → chunk-E7QTWGPI.js} +413 -413
- package/dist/cli/chunks/{chunk-PX5OPXY6.js → chunk-EC65UZ77.js} +1 -1
- package/dist/cli/chunks/{chunk-JNXK47OL.js → chunk-EIEEST4T.js} +2 -2
- package/dist/cli/chunks/{chunk-2PPSS4JD.js → chunk-FHPNWHY7.js} +2 -2
- package/dist/cli/chunks/{chunk-PTBOLBM4.js → chunk-FJOIBZUB.js} +2 -2
- package/dist/cli/chunks/{chunk-TXEUVUMO.js → chunk-FTYRPEJS.js} +1 -1
- package/dist/cli/chunks/{chunk-ZPVGX4DI.js → chunk-G7HGUQAE.js} +2 -2
- package/dist/cli/chunks/{chunk-EF6OERRR.js → chunk-GY4P7KAI.js} +1 -1
- package/dist/cli/chunks/{chunk-UUZZXHUF.js → chunk-H3C5FJRH.js} +2 -2
- package/dist/cli/chunks/{chunk-L3PV7VXK.js → chunk-H4LYXLAT.js} +1 -1
- package/dist/cli/chunks/{chunk-5Z23ZMXZ.js → chunk-HAYKLXCT.js} +63 -61
- package/dist/cli/chunks/{chunk-IPA7K556.js → chunk-HEDGFKC5.js} +2 -2
- package/dist/cli/chunks/{chunk-BC4T6SCV.js → chunk-HHBF2BZC.js} +4 -4
- package/dist/cli/chunks/{chunk-IVTQF55W.js → chunk-HSDWPQQY.js} +3 -3
- package/dist/cli/chunks/{chunk-SG2TX72G.js → chunk-HTVGHHX2.js} +2 -2
- package/dist/cli/chunks/{chunk-FZJCBSN4.js → chunk-HV43NX4A.js} +2 -2
- package/dist/cli/chunks/{chunk-MMEALJ4D.js → chunk-IDBA5GK2.js} +2 -2
- package/dist/cli/chunks/{chunk-IA55PFLG.js → chunk-INGXD5IX.js} +2 -2
- package/dist/cli/chunks/{chunk-RYHG3I7J.js → chunk-IQRPR4KB.js} +2 -2
- package/dist/cli/chunks/{chunk-7OEFBWAG.js → chunk-IRPNEXOU.js} +2 -2
- package/dist/cli/chunks/{chunk-P7UFJ6DO.js → chunk-J35JWDJE.js} +1 -1
- package/dist/cli/chunks/chunk-J6ASX536.js +2 -0
- package/dist/cli/chunks/{chunk-2ASQRBK2.js → chunk-JAOCHPYX.js} +2 -2
- package/dist/cli/chunks/{chunk-G3AABG4Q.js → chunk-JB7R77SH.js} +2 -2
- package/dist/cli/chunks/{chunk-HSA5IGGW.js → chunk-JI67T6Q2.js} +2 -2
- package/dist/cli/chunks/{chunk-ZGROHCOW.js → chunk-JJHLGGPP.js} +1 -1
- package/dist/cli/chunks/{chunk-L7NGKANW.js → chunk-JK6PMLQQ.js} +2 -2
- package/dist/cli/chunks/{chunk-IL7GQNNE.js → chunk-JO26SG47.js} +2 -2
- package/dist/cli/chunks/{chunk-3EWQN37E.js → chunk-JSSU4RIK.js} +2 -2
- package/dist/cli/chunks/{chunk-TOWOJGEI.js → chunk-K2SMP4OD.js} +1 -1
- package/dist/cli/chunks/{chunk-YVJEUX3I.js → chunk-K7GFYFBO.js} +2 -2
- package/dist/cli/chunks/{chunk-DAUEK66C.js → chunk-K7RT6ITZ.js} +1 -1
- package/dist/cli/chunks/{chunk-33I2ZP6E.js → chunk-KJ5A54ZH.js} +2 -2
- package/dist/cli/chunks/{chunk-W4II6SIH.js → chunk-L5VSLPMW.js} +2 -2
- package/dist/cli/chunks/{chunk-NVRYELCY.js → chunk-L752CNG3.js} +3 -3
- package/dist/cli/chunks/{chunk-MAJXZYGK.js → chunk-L7PC675Y.js} +1 -1
- package/dist/cli/chunks/{chunk-YWWMNTBF.js → chunk-LTGQJYYO.js} +2 -2
- package/dist/cli/chunks/{chunk-7DNR4KKR.js → chunk-M2TG7VDK.js} +1 -1
- package/dist/cli/chunks/{chunk-2E2QO44T.js → chunk-M5JEA6ZY.js} +2 -2
- package/dist/cli/chunks/{chunk-IETBWYHW.js → chunk-MB4UKUBV.js} +2 -2
- package/dist/cli/chunks/{chunk-W7H55PY4.js → chunk-MKYOE7NE.js} +1 -1
- package/dist/cli/chunks/{chunk-FNUFTWEO.js → chunk-MQXWG55U.js} +3 -3
- package/dist/cli/chunks/{chunk-O4QJMANM.js → chunk-MR2OPUSA.js} +1 -1
- package/dist/cli/chunks/{chunk-KA5SHLMW.js → chunk-N736GLWZ.js} +2 -2
- package/dist/cli/chunks/{chunk-NV74SICL.js → chunk-NHEG2DLN.js} +2 -2
- package/dist/cli/chunks/chunk-NKOLILT7.js +86 -0
- package/dist/cli/chunks/{chunk-KJDI5CHX.js → chunk-NPCXGX7N.js} +2 -2
- package/dist/cli/chunks/{chunk-2IVE5AR3.js → chunk-NZQYJCO6.js} +1 -1
- package/dist/cli/chunks/{chunk-4SA7M34P.js → chunk-O2AAYJUV.js} +1 -1
- package/dist/cli/chunks/{chunk-ULCW6IVQ.js → chunk-O32BFQV4.js} +2 -2
- package/dist/cli/chunks/{chunk-JOWUS2X5.js → chunk-O3ERGUXH.js} +1 -1
- package/dist/cli/chunks/{chunk-BYRCB5JT.js → chunk-O5CEL447.js} +2 -2
- package/dist/cli/chunks/{chunk-CPIBIR3X.js → chunk-O756AOUX.js} +2 -2
- package/dist/cli/chunks/{chunk-TSOQ2QLT.js → chunk-OCN53CCK.js} +2 -2
- package/dist/cli/chunks/{chunk-YLKIXEPP.js → chunk-OGEIHS76.js} +1 -1
- package/dist/cli/chunks/{chunk-ICKUINKD.js → chunk-OLUOVNUF.js} +2 -2
- package/dist/cli/chunks/{chunk-5ADXFUMO.js → chunk-P2TPH3TC.js} +2 -2
- package/dist/cli/chunks/{chunk-SBHM5X2S.js → chunk-PCQZIAXB.js} +2 -2
- package/dist/cli/chunks/{chunk-CDA5Z74H.js → chunk-PGN4TARY.js} +2 -2
- package/dist/cli/chunks/{chunk-P5E26N2X.js → chunk-PNRPVQGI.js} +2 -2
- package/dist/cli/chunks/{chunk-23PQF7NN.js → chunk-PWQWKYBG.js} +1 -1
- package/dist/cli/chunks/{chunk-T4EN5VVK.js → chunk-QNQE3EOH.js} +2 -2
- package/dist/cli/chunks/chunk-QP2HLKTS.js +2 -0
- package/dist/cli/chunks/{chunk-7TA5MUPW.js → chunk-QP6GL3O5.js} +1 -1
- package/dist/cli/chunks/{chunk-GKFV6CUD.js → chunk-QUZ745UQ.js} +2 -2
- package/dist/cli/chunks/{chunk-INZARYUD.js → chunk-R5RRWLRI.js} +2 -2
- package/dist/cli/chunks/{chunk-VZBC6DP7.js → chunk-RE6JTSDM.js} +1 -1
- package/dist/cli/chunks/{chunk-JGIJPDGD.js → chunk-TOJF3ZG4.js} +2 -2
- package/dist/cli/chunks/{chunk-WLRU6ESI.js → chunk-TSP6SU5V.js} +2 -2
- package/dist/cli/chunks/{chunk-6E6HB4N4.js → chunk-TW6Z6W4X.js} +4 -4
- package/dist/cli/chunks/{chunk-ENGL7FIJ.js → chunk-TWOV3I3A.js} +1 -1
- package/dist/cli/chunks/chunk-U4TML2VD.js +3 -0
- package/dist/cli/chunks/{chunk-O3IM4WRZ.js → chunk-U6IOQKCT.js} +2 -2
- package/dist/cli/chunks/{chunk-SPC4RBLF.js → chunk-UDSB3XCG.js} +2 -2
- package/dist/cli/chunks/{chunk-URSTP3WI.js → chunk-UFP7SN5V.js} +2 -2
- package/dist/cli/chunks/{chunk-MYF5CNGV.js → chunk-UMHFTQTR.js} +2 -2
- package/dist/cli/chunks/{chunk-65TH6RPD.js → chunk-UNYTHZDZ.js} +1 -1
- package/dist/cli/chunks/{chunk-FAGKBOX2.js → chunk-UPWLMIDY.js} +2 -2
- package/dist/cli/chunks/{chunk-4CB3QPZM.js → chunk-USAKCGHC.js} +2 -2
- package/dist/cli/chunks/{chunk-QUJJYTJH.js → chunk-V3MGY76S.js} +2 -2
- package/dist/cli/chunks/{chunk-WDEXOLK2.js → chunk-V6SE2ZU2.js} +1 -1
- package/dist/cli/chunks/{chunk-JW5PDJ5O.js → chunk-VCVRZD4Y.js} +3 -3
- package/dist/cli/chunks/{chunk-TGMXUZZC.js → chunk-VG32EEUG.js} +2 -2
- package/dist/cli/chunks/{chunk-MYUMJ2ZI.js → chunk-VGZOPQQY.js} +1 -1
- package/dist/cli/chunks/{chunk-BOSMELJX.js → chunk-VJBJRFUO.js} +2 -2
- package/dist/cli/chunks/{chunk-K3A3NWT3.js → chunk-WBC6WB32.js} +2 -2
- package/dist/cli/chunks/{chunk-QWG3SILX.js → chunk-WCM6WE7G.js} +5 -5
- package/dist/cli/chunks/{chunk-GJKZ7UQO.js → chunk-WCPSR4MJ.js} +2 -2
- package/dist/cli/chunks/{chunk-U6IXYQO4.js → chunk-WKI46WWN.js} +2 -2
- package/dist/cli/chunks/{chunk-NX4BCSOZ.js → chunk-WM2QRIRD.js} +2 -2
- package/dist/cli/chunks/{chunk-32UTHIY5.js → chunk-WRC3HLUY.js} +3 -3
- package/dist/cli/chunks/{chunk-AJEXPFAB.js → chunk-WUGXXNK4.js} +1 -1
- package/dist/cli/chunks/{chunk-NA3F6FEO.js → chunk-WZQADC5R.js} +2 -2
- package/dist/cli/chunks/{chunk-SDRJJUPO.js → chunk-X6NJOT3V.js} +1 -1
- package/dist/cli/chunks/{chunk-CU36D7TN.js → chunk-X6Q2N5S5.js} +2 -2
- package/dist/cli/chunks/{chunk-UIKQPO4Y.js → chunk-X7CUI7KH.js} +2 -2
- package/dist/cli/chunks/{chunk-MCPEC6OO.js → chunk-XMCSKYDE.js} +1 -1
- package/dist/cli/chunks/{chunk-WTAUF6O4.js → chunk-XN3KCKAM.js} +2 -2
- package/dist/cli/chunks/{chunk-TLRHAMX5.js → chunk-XSPMLJCQ.js} +1 -1
- package/dist/cli/chunks/{chunk-VUR5THML.js → chunk-XTZGAG6P.js} +2 -2
- package/dist/cli/chunks/{chunk-47RMGDG4.js → chunk-YE54T2NQ.js} +2 -2
- package/dist/cli/chunks/{chunk-HM3LSFTY.js → chunk-YEFTK4HD.js} +2 -2
- package/dist/cli/chunks/{chunk-4HWUECVD.js → chunk-YGC5QKQ4.js} +2 -2
- package/dist/cli/chunks/{chunk-SUX5XB2Z.js → chunk-YGOSSVY5.js} +2 -2
- package/dist/cli/chunks/{chunk-UJNGGFGX.js → chunk-YKQWIXUY.js} +2 -2
- package/dist/cli/chunks/{chunk-SITL5YZV.js → chunk-Z2S7DNFP.js} +2 -2
- package/dist/cli/chunks/{chunk-WGTEZT7G.js → chunk-Z54G2YOL.js} +2 -2
- package/dist/cli/chunks/{chunk-YNVEDFPQ.js → chunk-ZJGFQK27.js} +1 -1
- package/dist/cli/chunks/{chunk-35NW676P.js → chunk-ZUE524JL.js} +2 -2
- package/dist/cli/chunks/{ci-BZNWW3I3.js → ci-UMA2SMNW.js} +2 -2
- package/dist/cli/chunks/{ci-config-LOHNXOKV.js → ci-config-UQSILJFQ.js} +2 -2
- package/dist/cli/chunks/{ci-output-LCOQBSJL.js → ci-output-U6YZLLKH.js} +2 -2
- package/dist/cli/chunks/{circuit-breaker-7LRXTLFE.js → circuit-breaker-ATYQP6X2.js} +2 -2
- package/dist/cli/chunks/{claude-flow-setup-HBU4VWC3.js → claude-flow-setup-6YHFD7AN.js} +2 -2
- package/dist/cli/chunks/client-E43GWLQH.js +2 -0
- package/dist/cli/chunks/{cline-installer-CO6MLH6X.js → cline-installer-EPE7IOZE.js} +2 -2
- package/dist/cli/chunks/{code-SIXBS6JM.js → code-NUEJ4XYO.js} +19 -18
- package/dist/cli/chunks/{code-index-extractor-GWJKZ2IQ.js → code-index-extractor-D4DBT6OL.js} +2 -2
- package/dist/cli/chunks/{codex-installer-6NINVWXJ.js → codex-installer-633SM4LR.js} +2 -2
- package/dist/cli/chunks/{completions-7VIX3GML.js → completions-WUKVIW3L.js} +2 -2
- package/dist/cli/chunks/{complexity-analyzer-FBQR6ZP2.js → complexity-analyzer-F73ACR5H.js} +2 -2
- package/dist/cli/chunks/{continuedev-installer-VA7RIXW5.js → continuedev-installer-QH42TKMS.js} +2 -2
- package/dist/cli/chunks/{copilot-installer-4QEBC4MU.js → copilot-installer-Y3XC7BTT.js} +2 -2
- package/dist/cli/chunks/core-handlers-R5A3SQDY.js +2 -0
- package/dist/cli/chunks/{cost-tracker-GRYKHPWL.js → cost-tracker-57QPV7E3.js} +2 -2
- package/dist/cli/chunks/coverage-IBCHMBCR.js +51 -0
- package/dist/cli/chunks/cross-domain-router-LLYVPZF6.js +2 -0
- package/dist/cli/chunks/{cursor-installer-ZXIPSZVH.js → cursor-installer-F4UYQHIN.js} +2 -2
- package/dist/cli/chunks/{daemon-N2VRHPSJ.js → daemon-BYYPIJ7G.js} +4 -4
- package/dist/cli/chunks/{daemon-D7F3RGI5.js → daemon-XR4Q6YZF.js} +3 -3
- package/dist/cli/chunks/{dag-attention-scheduler-NL6BA7BY.js → dag-attention-scheduler-ZR5ZD3TW.js} +2 -2
- package/dist/cli/chunks/{detect-XC2HCIIT.js → detect-GEGYURLL.js} +2 -2
- package/dist/cli/chunks/{dist-node-A3Y26MEI.js → dist-node-JU3KT2JO.js} +2 -2
- package/dist/cli/chunks/{domain-handler-WV6SFXRB.js → domain-handler-7QI3FJGE.js} +2 -2
- package/dist/cli/chunks/{domain-plugins-KJIF6Z2B.js → domain-plugins-O2YRM2PD.js} +2 -2
- package/dist/cli/chunks/domain-transfer-7J3S2OS6.js +2 -0
- package/dist/cli/chunks/dream-6C4NURSE.js +2 -0
- package/dist/cli/chunks/{embed-and-insert-pattern-PA3Y4KGO.js → embed-and-insert-pattern-URES5Q6J.js} +2 -2
- package/dist/cli/chunks/{eval-YGEZNUVE.js → eval-RVMCIUOR.js} +2 -2
- package/dist/cli/chunks/{experience-capture-middleware-D4T7NW6B.js → experience-capture-middleware-SYJQSBKE.js} +3 -3
- package/dist/cli/chunks/{fast-paths-6JYK7RYQ.js → fast-paths-QUKPKWKZ.js} +2 -2
- package/dist/cli/chunks/{feature-flags-DKXMDVPE.js → feature-flags-5JCSKL2P.js} +2 -2
- package/dist/cli/chunks/{feature-flags-RBH2GDSR.js → feature-flags-K7JXNKJI.js} +2 -2
- package/dist/cli/chunks/file-discovery-J5IE5KP7.js +2 -0
- package/dist/cli/chunks/fleet-II4Q6HXK.js +44 -0
- package/dist/cli/chunks/{gnn-wrapper-MV54UC4C.js → gnn-wrapper-M7VO2EMS.js} +2 -2
- package/dist/cli/chunks/{heartbeat-handler-7DKMVQQH.js → heartbeat-handler-ND5CY26N.js} +4 -4
- package/dist/cli/chunks/heartbeat-scheduler-FC5PBTMN.js +2 -0
- package/dist/cli/chunks/hnsw-adapter-47UIVOBG.js +2 -0
- package/dist/cli/chunks/hnsw-index-3AKVLOZQ.js +2 -0
- package/dist/cli/chunks/{hnsw-legacy-bridge-6IWREDQC.js → hnsw-legacy-bridge-N3AUUUU7.js} +2 -2
- package/dist/cli/chunks/{hnswlib-node-5BIESSCK.js → hnswlib-node-NZY3E5EN.js} +2 -2
- package/dist/cli/chunks/{hooks-3EETRM62.js → hooks-QVJDTII5.js} +10 -10
- package/dist/cli/chunks/hybrid-backend-YAOSNX47.js +2 -0
- package/dist/cli/chunks/{hypergraph-engine-RSWCB2D3.js → hypergraph-engine-ZRY6MTDV.js} +2 -2
- package/dist/cli/chunks/{hypergraph-handler-552LXKL3.js → hypergraph-handler-56DO4XZQ.js} +3 -3
- package/dist/cli/chunks/impact-analyzer-4FMJXM4M.js +2 -0
- package/dist/cli/chunks/{init-guard-OTDBJ5HD.js → init-guard-DTF4EVUY.js} +2 -2
- package/dist/cli/chunks/{init-handler-3FK3TKEA.js → init-handler-M6CNQHMX.js} +6 -6
- package/dist/cli/chunks/init-wizard-RTLCRWDT.js +2 -0
- package/dist/cli/chunks/kernel-2OWIGGGT.js +2 -0
- package/dist/cli/chunks/{kilocode-installer-KZ2O4LF3.js → kilocode-installer-IJN7XKBH.js} +2 -2
- package/dist/cli/chunks/{kiro-installer-MLCCXRF7.js → kiro-installer-UKKPGPDC.js} +2 -2
- package/dist/cli/chunks/knowledge-graph-25XXKDJN.js +2 -0
- package/dist/cli/chunks/learning-W2HETWQ4.js +131 -0
- package/dist/cli/chunks/{llm-router-PDEV3UP2.js → llm-router-Y546K4VX.js} +4 -4
- package/dist/cli/chunks/llm-router-service-G3EIN4UB.js +2 -0
- package/dist/cli/chunks/{load-XFVVLO7E.js → load-MKAB2AXE.js} +2 -2
- package/dist/cli/chunks/load-test-D6QYNIVT.js +2 -0
- package/dist/cli/chunks/{mcp-74G3CL2S.js → mcp-AZKUS6K3.js} +2 -2
- package/dist/cli/chunks/{memory-XIFM6JNX.js → memory-ZDOQN2KU.js} +5 -5
- package/dist/cli/chunks/memory-backend-LDFFZMEQ.js +2 -0
- package/dist/cli/chunks/{memory-handlers-ZCKURV6S.js → memory-handlers-3SQVY7FE.js} +2 -2
- package/dist/cli/chunks/{multi-model-executor-7L4W3O2Q.js → multi-model-executor-WWVXDHG4.js} +2 -2
- package/dist/cli/chunks/{opencode-installer-BPG422LF.js → opencode-installer-YUJNXXWS.js} +2 -2
- package/dist/cli/chunks/{orchestrator-OEAFLAEV.js → orchestrator-Z6PWPLRE.js} +109 -25
- package/dist/cli/chunks/pattern-null-store-KDVRM7PW.js +2 -0
- package/dist/cli/chunks/{pattern-usage-recorder-LOPNCULT.js → pattern-usage-recorder-TPWPX32U.js} +2 -2
- package/dist/cli/chunks/{pipeline-VWTYUZB7.js → pipeline-4BBGTE4M.js} +2 -2
- package/dist/cli/chunks/{platform-WFJJ3X2E.js → platform-5GSHXCV5.js} +2 -2
- package/dist/cli/chunks/{plugin-744TPUSG.js → plugin-OFDVF5HS.js} +2 -2
- package/dist/cli/chunks/{prime-radiant-advanced-wasm-BD5BLNDR.js → prime-radiant-advanced-wasm-NC6MUYGJ.js} +2 -2
- package/dist/cli/chunks/project-root-DDGBWDP6.js +2 -0
- package/dist/cli/chunks/protocol-executor-KBOLLCWA.js +2 -0
- package/dist/cli/chunks/{protocol-handler-JIBILI74.js → protocol-handler-MPOAAEPA.js} +2 -2
- package/dist/cli/chunks/{prove-MNOL5FYW.js → prove-CDKMAIVM.js} +2 -2
- package/dist/cli/chunks/qe-reasoning-bank-GRXBT7FC.js +2 -0
- package/dist/cli/chunks/{quality-JEGBDGGX.js → quality-ZH4F7R7R.js} +2 -2
- package/dist/cli/chunks/{quality-gate-SYJ6ROMI.js → quality-gate-IDRMW6OE.js} +3 -3
- package/dist/cli/chunks/queen-coordinator-L2QWMJ5Q.js +2 -0
- package/dist/cli/chunks/{real-embeddings-ZWXS5ZFV.js → real-embeddings-I2UVNNB3.js} +2 -2
- package/dist/cli/chunks/{ref-validation-RRHUFW2N.js → ref-validation-Z5GCGVXK.js} +2 -2
- package/dist/cli/chunks/{roocode-installer-XFO6JSVN.js → roocode-installer-IZ2S7PH2.js} +2 -2
- package/dist/cli/chunks/router-FT5WJPUH.js +2 -0
- package/dist/cli/chunks/routing-feedback-EO2MKOUX.js +2 -0
- package/dist/cli/chunks/{routing-handler-L2K3JASE.js → routing-handler-NAX35VUW.js} +2 -2
- package/dist/cli/chunks/{ruvector-commands-A6CINHGM.js → ruvector-commands-5YW2SOFF.js} +2 -2
- package/dist/cli/chunks/rvf-dual-writer-WHBFQJVU.js +2 -0
- package/dist/cli/chunks/rvf-migration-adapter-YT3APF2I.js +2 -0
- package/dist/cli/chunks/{rvf-migration-coordinator-T4RY7L53.js → rvf-migration-coordinator-VUIZHTVG.js} +2 -2
- package/dist/cli/chunks/rvf-native-adapter-37PUFKQD.js +2 -0
- package/dist/cli/chunks/{rvf-store-integrity-IR33TGQS.js → rvf-store-integrity-IPGCAT6C.js} +2 -2
- package/dist/cli/chunks/safe-db-TDZKUOZJ.js +2 -0
- package/dist/cli/chunks/schedule-CRKTRY2A.js +2 -0
- package/dist/cli/chunks/scheduler-6ZBDVQWN.js +2 -0
- package/dist/cli/chunks/{security-Z5GDE2IH.js → security-3IH4BO5Z.js} +3 -3
- package/dist/cli/chunks/{shared-rvf-adapter-SIZMEHPM.js → shared-rvf-adapter-ABY7PAY2.js} +2 -2
- package/dist/cli/chunks/{shared-rvf-dual-writer-HLM65RDS.js → shared-rvf-dual-writer-6KENLN2W.js} +2 -2
- package/dist/cli/chunks/sqlite-persistence-FFJQAIKW.js +2 -0
- package/dist/cli/chunks/{standalone-memory-SKSZG7P5.js → standalone-memory-RLFAUGOW.js} +2 -2
- package/dist/cli/chunks/{status-handler-766YOOMJ.js → status-handler-FCOZBPE5.js} +2 -2
- package/dist/cli/chunks/{structural-health-M45FNOLT.js → structural-health-4RDA5UUM.js} +2 -2
- package/dist/cli/chunks/{sync-B2U366I3.js → sync-54LUAUTK.js} +2 -2
- package/dist/cli/chunks/{sync-6CJ24B5T.js → sync-KGEEXXCC.js} +2 -2
- package/dist/cli/chunks/task-handler-K3OXHYKU.js +62 -0
- package/dist/cli/chunks/task-handlers-6H7L2UT4.js +9 -0
- package/dist/cli/chunks/{test-TODH7KRF.js → test-S7IG6EIX.js} +4 -4
- package/dist/cli/chunks/test-runner-process-OTQDAJLN.js +2 -0
- package/dist/cli/chunks/{test-scheduling-VMVMVRHT.js → test-scheduling-7XYXI4L2.js} +3 -3
- package/dist/cli/chunks/{token-bootstrap-XQW7BMCK.js → token-bootstrap-3QMABE45.js} +2 -2
- package/dist/cli/chunks/{token-usage-JCZEIRKO.js → token-usage-Y2YTPOFE.js} +2 -2
- package/dist/cli/chunks/{transformers-U2ML3OHE.js → transformers-UCJ3HHHC.js} +2 -2
- package/dist/cli/chunks/tree-sitter-wasm-parser-D6JTTHTP.js +2 -0
- package/dist/cli/chunks/{types-GGEPCHP6.js → types-6CMFPETH.js} +2 -2
- package/dist/cli/chunks/unified-memory-QARWQKJ2.js +2 -0
- package/dist/cli/chunks/unified-memory-hnsw-LHY3DXCP.js +2 -0
- package/dist/cli/chunks/unified-persistence-WEYYGLHM.js +2 -0
- package/dist/cli/chunks/{upgrade-T5GRM7HS.js → upgrade-K25DN6WU.js} +2 -2
- package/dist/cli/chunks/{validate-XMUJPLP3.js → validate-T4V3TBY3.js} +2 -2
- package/dist/cli/chunks/{validate-swarm-KJLF7JEH.js → validate-swarm-XSRC576T.js} +2 -2
- package/dist/cli/chunks/visual-security-O4ALMCXQ.js +2 -0
- package/dist/cli/chunks/{web-tree-sitter-LOHVZ7G5.js → web-tree-sitter-YOZXHRTN.js} +2 -2
- package/dist/cli/chunks/{windsurf-installer-33FBTXJU.js → windsurf-installer-ITPU2IYL.js} +2 -2
- package/dist/cli/chunks/witness-chain-B3YW5NMS.js +2 -0
- package/dist/cli/chunks/witness-chain-PIYR72HJ.js +2 -0
- package/dist/cli/chunks/{witness-chain-repair-VWBO4NXE.js → witness-chain-repair-YUG7E3UX.js} +2 -2
- package/dist/cli/chunks/{witness-chain-verifier-BHJ3ZAEK.js → witness-chain-verifier-DTDSVKOG.js} +2 -2
- package/dist/cli/chunks/{witness-key-manager-WNVPH2Z3.js → witness-key-manager-EWACWGAW.js} +2 -2
- package/dist/cli/chunks/{workflow-6QR5MQTO.js → workflow-ZIQ4FV42.js} +4 -4
- package/dist/cli/chunks/workflow-orchestrator-3ZN2BCGY.js +2 -0
- package/dist/cli/chunks/{wrappers-EHOL62TS.js → wrappers-PW2O27LL.js} +2 -2
- package/dist/cli/commands/code.js +6 -0
- package/dist/cli/commands/coverage.js +6 -0
- package/dist/cli/commands/fleet-run.d.ts +12 -0
- package/dist/cli/commands/fleet-run.js +175 -0
- package/dist/cli/commands/fleet.js +2 -117
- package/dist/cli/commands/learning-prune.d.ts +14 -0
- package/dist/cli/commands/learning-prune.js +105 -0
- package/dist/cli/commands/learning.js +9 -0
- package/dist/cli/handlers/brain-handler.js +12 -1
- package/dist/cli/handlers/task-handler.d.ts +5 -0
- package/dist/cli/handlers/task-handler.js +20 -0
- package/dist/cli/utils/coverage-verdict.js +14 -3
- package/dist/cli/utils/fleet-operation.d.ts +5 -2
- package/dist/cli/utils/fleet-operation.js +13 -2
- package/dist/cli/utils/fleet-result.d.ts +16 -2
- package/dist/cli/utils/fleet-result.js +26 -21
- package/dist/cli/utils/fleet-shard.d.ts +36 -0
- package/dist/cli/utils/fleet-shard.js +110 -0
- package/dist/context/compaction/index.d.ts +7 -0
- package/dist/context/compaction/index.js +30 -6
- package/dist/coordination/handlers/code-intelligence-handlers.js +21 -1
- package/dist/coordination/handlers/coverage-evidence.d.ts +19 -0
- package/dist/coordination/handlers/coverage-evidence.js +31 -2
- package/dist/coordination/handlers/coverage-handlers.js +5 -1
- package/dist/coordination/handlers/coverage-target.js +8 -1
- package/dist/coordination/handlers/handler-types.d.ts +2 -2
- package/dist/coordination/handlers/handler-utils.d.ts +6 -0
- package/dist/coordination/handlers/handler-utils.js +14 -4
- package/dist/coordination/handlers/misc-handlers.js +5 -2
- package/dist/coordination/handlers/quality-handlers.js +11 -3
- package/dist/coordination/handlers/security-handlers.js +12 -2
- package/dist/coordination/protocols/security-audit.js +11 -1
- package/dist/coordination/result-saver-adapters.js +1 -0
- package/dist/coordination/result-saver.js +9 -5
- package/dist/coordination/task-executor.js +7 -2
- package/dist/domains/chaos-resilience/services/chaos-engineer.d.ts +1 -0
- package/dist/domains/chaos-resilience/services/chaos-engineer.js +23 -45
- package/dist/domains/code-intelligence/coordinator-gnn.d.ts +2 -16
- package/dist/domains/code-intelligence/coordinator-gnn.js +1 -62
- package/dist/domains/code-intelligence/coordinator.d.ts +12 -6
- package/dist/domains/code-intelligence/coordinator.js +24 -27
- package/dist/domains/code-intelligence/interfaces.d.ts +9 -0
- package/dist/domains/code-intelligence/services/semantic-analyzer.d.ts +43 -5
- package/dist/domains/code-intelligence/services/semantic-analyzer.js +134 -71
- package/dist/domains/coverage-analysis/collected-metrics.d.ts +26 -0
- package/dist/domains/coverage-analysis/collected-metrics.js +54 -0
- package/dist/domains/coverage-analysis/services/coverage-analyzer.js +13 -3
- package/dist/domains/coverage-analysis/services/coverage-parser.d.ts +2 -0
- package/dist/domains/coverage-analysis/services/coverage-parser.js +18 -2
- package/dist/domains/defect-intelligence/services/defect-predictor.js +3 -6
- package/dist/domains/quality-assessment/coherence/gate-controller.js +16 -4
- package/dist/domains/quality-assessment/coherence/lambda-calculator.d.ts +8 -0
- package/dist/domains/quality-assessment/coherence/lambda-calculator.js +57 -14
- package/dist/domains/quality-assessment/coherence/types.d.ts +12 -7
- package/dist/domains/quality-assessment/coordinator-gate-evaluation.js +3 -1
- package/dist/domains/quality-assessment/coordinator-reports.d.ts +30 -10
- package/dist/domains/quality-assessment/coordinator-reports.js +93 -57
- package/dist/domains/quality-assessment/coordinator.d.ts +14 -40
- package/dist/domains/quality-assessment/coordinator.js +10 -4
- package/dist/domains/quality-assessment/coverage-report-event.d.ts +8 -0
- package/dist/domains/quality-assessment/coverage-report-event.js +22 -1
- package/dist/domains/quality-assessment/interfaces.d.ts +8 -0
- package/dist/domains/quality-assessment/services/coherence-gate.js +15 -2
- package/dist/domains/quality-assessment/services/quality-analyzer.d.ts +4 -0
- package/dist/domains/quality-assessment/services/quality-analyzer.js +63 -17
- package/dist/domains/quality-assessment/services/quality-gate.js +6 -4
- package/dist/domains/security-compliance/index.d.ts +1 -1
- package/dist/domains/security-compliance/interfaces.d.ts +46 -5
- package/dist/domains/security-compliance/services/scanners/dast-auth-testing.d.ts +3 -3
- package/dist/domains/security-compliance/services/scanners/dast-auth-testing.js +15 -14
- package/dist/domains/security-compliance/services/scanners/dast-helpers.d.ts +8 -9
- package/dist/domains/security-compliance/services/scanners/dast-helpers.js +19 -44
- package/dist/domains/security-compliance/services/scanners/dast-injection-testing.d.ts +3 -3
- package/dist/domains/security-compliance/services/scanners/dast-injection-testing.js +13 -9
- package/dist/domains/security-compliance/services/scanners/dast-requests.d.ts +54 -0
- package/dist/domains/security-compliance/services/scanners/dast-requests.js +125 -0
- package/dist/domains/security-compliance/services/scanners/dast-scanner.d.ts +5 -1
- package/dist/domains/security-compliance/services/scanners/dast-scanner.js +125 -155
- package/dist/domains/security-compliance/services/scanners/index.d.ts +1 -1
- package/dist/domains/security-compliance/services/scanners/index.js +1 -1
- package/dist/domains/security-compliance/services/scanners/scanner-types.d.ts +2 -2
- package/dist/domains/security-compliance/services/security-auditor-dast.js +183 -212
- package/dist/domains/security-compliance/services/security-auditor-reports.js +5 -1
- package/dist/domains/security-compliance/services/security-auditor.d.ts +11 -3
- package/dist/domains/security-compliance/services/security-auditor.js +106 -65
- package/dist/domains/test-execution/coordinator.d.ts +2 -1
- package/dist/domains/test-execution/coordinator.js +33 -27
- package/dist/domains/test-execution/interfaces.d.ts +10 -0
- package/dist/domains/test-execution/services/test-executor.d.ts +6 -0
- package/dist/domains/test-execution/services/test-executor.js +22 -4
- package/dist/domains/visual-accessibility/coordinator.js +34 -9
- package/dist/domains/visual-accessibility/interfaces.d.ts +27 -0
- package/dist/domains/visual-accessibility/plugin.js +5 -0
- package/dist/domains/visual-accessibility/services/accessibility-tester-heuristics.d.ts +13 -21
- package/dist/domains/visual-accessibility/services/accessibility-tester-heuristics.js +13 -297
- package/dist/domains/visual-accessibility/services/accessibility-tester.d.ts +13 -5
- package/dist/domains/visual-accessibility/services/accessibility-tester.js +96 -73
- package/dist/init/phases/07-hooks.js +90 -6
- package/dist/integrations/embeddings/index/HNSWIndex.js +8 -4
- package/dist/integrations/ruvector/brain-rvf-exporter.d.ts +25 -0
- package/dist/integrations/ruvector/brain-rvf-exporter.js +154 -61
- package/dist/integrations/ruvector/transfer-coherence-stub.js +5 -10
- package/dist/learning/dream/dream-engine.d.ts +24 -1
- package/dist/learning/dream/dream-engine.js +57 -6
- package/dist/learning/learning-retention.d.ts +103 -0
- package/dist/learning/learning-retention.js +213 -0
- package/dist/mcp/bundle.js +508 -503
- package/dist/mcp/handlers/domain-handler-configs.d.ts +17 -1
- package/dist/mcp/handlers/domain-handler-configs.js +33 -16
- package/dist/mcp/handlers/handler-factory.js +3 -0
- package/dist/mcp/handlers/model-route-handlers.d.ts +107 -0
- package/dist/mcp/handlers/model-route-handlers.js +139 -0
- package/dist/mcp/handlers/orchestrate-routes.js +41 -3
- package/dist/mcp/handlers/task-handlers.d.ts +3 -251
- package/dist/mcp/handlers/task-handlers.js +6 -828
- package/dist/mcp/handlers/task-inference.d.ts +26 -0
- package/dist/mcp/handlers/task-inference.js +156 -0
- package/dist/mcp/handlers/task-learning-handlers.d.ts +92 -0
- package/dist/mcp/handlers/task-learning-handlers.js +230 -0
- package/dist/mcp/handlers/task-orchestrate-handler.d.ts +73 -0
- package/dist/mcp/handlers/task-orchestrate-handler.js +361 -0
- package/dist/mcp/protocol-server.js +13 -3
- package/dist/mcp/tools/chaos-resilience/inject.d.ts +3 -4
- package/dist/mcp/tools/chaos-resilience/inject.js +11 -81
- package/dist/mcp/tools/code-intelligence/analyze.js +3 -6
- package/dist/mcp/tools/coverage-analysis/index.d.ts +4 -0
- package/dist/mcp/tools/coverage-analysis/index.js +8 -2
- package/dist/mcp/tools/learning-optimization/dream.d.ts +8 -0
- package/dist/mcp/tools/learning-optimization/dream.js +4 -0
- package/dist/mcp/tools/visual-accessibility/index.d.ts +7 -0
- package/dist/mcp/tools/visual-accessibility/index.js +29 -13
- package/dist/shared/events/domain-events.d.ts +2 -0
- package/dist/shared/metrics/code-metrics.js +21 -3
- package/dist/shared/parsers/typescript-parser.d.ts +6 -0
- package/dist/shared/parsers/typescript-parser.js +13 -1
- package/package.json +1 -1
- package/dist/cli/chunks/adapter-HL7MOCQN.js +0 -2
- package/dist/cli/chunks/aqe-learning-engine-OZ2DXB4G.js +0 -2
- package/dist/cli/chunks/base-WIM7G3HC.js +0 -2
- package/dist/cli/chunks/brain-handler-MPC5SPYI.js +0 -94
- package/dist/cli/chunks/browser-workflow-QRKCFVR3.js +0 -2
- package/dist/cli/chunks/chunk-4A76VPU4.js +0 -3
- package/dist/cli/chunks/chunk-QSGEBCDB.js +0 -62
- package/dist/cli/chunks/chunk-UCSK2RMI.js +0 -2
- package/dist/cli/chunks/chunk-VXVTFKRA.js +0 -2
- package/dist/cli/chunks/chunk-XCNSGSKV.js +0 -3
- package/dist/cli/chunks/chunk-XZOYKB22.js +0 -79
- package/dist/cli/chunks/chunk-YIDAXOUX.js +0 -8
- package/dist/cli/chunks/client-4PNYDFYS.js +0 -2
- package/dist/cli/chunks/core-handlers-ODO6LUWQ.js +0 -2
- package/dist/cli/chunks/coverage-USPMNKOU.js +0 -50
- package/dist/cli/chunks/cross-domain-router-DT4MHJKK.js +0 -2
- package/dist/cli/chunks/domain-transfer-L3F6AES2.js +0 -2
- package/dist/cli/chunks/dream-QOB3JCOM.js +0 -2
- package/dist/cli/chunks/file-discovery-BN76S2PR.js +0 -2
- package/dist/cli/chunks/fleet-43YMXACN.js +0 -46
- package/dist/cli/chunks/heartbeat-scheduler-3NNP4WCP.js +0 -2
- package/dist/cli/chunks/hnsw-adapter-MZR7Y4WF.js +0 -2
- package/dist/cli/chunks/hnsw-index-HE4AX22U.js +0 -2
- package/dist/cli/chunks/hybrid-backend-IHUHB3Y2.js +0 -2
- package/dist/cli/chunks/impact-analyzer-FI6GI6PD.js +0 -2
- package/dist/cli/chunks/init-wizard-WLQKH5Y5.js +0 -2
- package/dist/cli/chunks/kernel-2WZOQEZS.js +0 -2
- package/dist/cli/chunks/knowledge-graph-G3LVKK6P.js +0 -2
- package/dist/cli/chunks/learning-QUCMBD77.js +0 -122
- package/dist/cli/chunks/llm-router-service-MM75HKWJ.js +0 -2
- package/dist/cli/chunks/load-test-BEWEE44J.js +0 -2
- package/dist/cli/chunks/memory-backend-NYKBBKZR.js +0 -2
- package/dist/cli/chunks/pattern-null-store-QGPUIV6M.js +0 -2
- package/dist/cli/chunks/project-root-C7ELXZRK.js +0 -2
- package/dist/cli/chunks/protocol-executor-SUVE33BM.js +0 -2
- package/dist/cli/chunks/qe-reasoning-bank-YWZMMGJB.js +0 -2
- package/dist/cli/chunks/queen-coordinator-ZFAKXRN7.js +0 -2
- package/dist/cli/chunks/router-4FTAVYLJ.js +0 -2
- package/dist/cli/chunks/routing-feedback-IO2KOWMJ.js +0 -2
- package/dist/cli/chunks/rvf-dual-writer-KCIRNE7C.js +0 -2
- package/dist/cli/chunks/rvf-migration-adapter-MFC5WTJU.js +0 -2
- package/dist/cli/chunks/rvf-native-adapter-I3KWHE7X.js +0 -2
- package/dist/cli/chunks/safe-db-QXDZ6QY3.js +0 -2
- package/dist/cli/chunks/schedule-CZKD6RIY.js +0 -2
- package/dist/cli/chunks/scheduler-BLA3Q4CH.js +0 -2
- package/dist/cli/chunks/sqlite-persistence-XIUYDJC4.js +0 -2
- package/dist/cli/chunks/task-handler-P6IFLCKP.js +0 -62
- package/dist/cli/chunks/task-handlers-DPWMUKFC.js +0 -9
- package/dist/cli/chunks/test-runner-process-46IPK3GH.js +0 -2
- package/dist/cli/chunks/tree-sitter-wasm-parser-MOI2WWNJ.js +0 -2
- package/dist/cli/chunks/unified-memory-FL26RTV3.js +0 -2
- package/dist/cli/chunks/unified-memory-hnsw-E2BPTH3U.js +0 -2
- package/dist/cli/chunks/unified-persistence-5ZOUPKHF.js +0 -2
- package/dist/cli/chunks/visual-security-IJVPO5FA.js +0 -2
- package/dist/cli/chunks/witness-chain-5FAFCQKP.js +0 -2
- package/dist/cli/chunks/witness-chain-V2M32W5D.js +0 -2
- package/dist/cli/chunks/workflow-orchestrator-3JLF3IX7.js +0 -2
|
@@ -1,28 +1,28 @@
|
|
|
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.15.
|
|
2
|
-
import{a as Qe}from"./chunk-
|
|
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.15.14");process.exit(0)}
|
|
2
|
+
import{a as Qe}from"./chunk-TSP6SU5V.js";import{a as ue,b as ke,c as Fe,d as Ne,e as Ve,f as We,g as He,h as Ge,i as Ue,j as Ke,k as ze,l as Je,m as Ye,n as ve,o as Ze,p as et}from"./chunk-VJBJRFUO.js";import{a as V,b as pe,c as Le,e as Be,f as W}from"./chunk-ZUE524JL.js";import{a as Xe}from"./chunk-FTYRPEJS.js";import"./chunk-6P4Q4RTC.js";import{c as Me}from"./chunk-IQRPR4KB.js";import"./chunk-J35JWDJE.js";import"./chunk-JJHLGGPP.js";import"./chunk-HTVGHHX2.js";import"./chunk-QUZ745UQ.js";import"./chunk-JK6PMLQQ.js";import"./chunk-6NIGSY5L.js";import{b as x,d as de}from"./chunk-XN3KCKAM.js";import"./chunk-UDSB3XCG.js";import"./chunk-Z54G2YOL.js";import"./chunk-HEDGFKC5.js";import"./chunk-AJVLVF7V.js";import"./chunk-7SQTLUEN.js";import"./chunk-57DRT6UA.js";import"./chunk-K7GFYFBO.js";import"./chunk-BNG4J3CE.js";import"./chunk-RE6JTSDM.js";import"./chunk-LTGQJYYO.js";import"./chunk-YKQWIXUY.js";import"./chunk-C3OIBFAA.js";import"./chunk-IRPNEXOU.js";import"./chunk-7QUSNBAA.js";import"./chunk-E7OR6V3V.js";import"./chunk-2UZBLC5H.js";import"./chunk-CAZM63TP.js";import{a as Oe,b as je,c as It,d as D,e as ye}from"./chunk-INGXD5IX.js";import{a as S,b as qe,e as Q}from"./chunk-L5VSLPMW.js";import"./chunk-U6IOQKCT.js";import{a as Rt}from"./chunk-V6SE2ZU2.js";Q();Q();var k=class{requiresPhases;requiresEnhancements;async shouldRun(e){return!0}async execute(e){let t=Date.now();try{return{success:!0,data:await this.run(e),durationMs:Date.now()-t,message:`${this.description} completed`}}catch(s){return{success:!1,error:qe(s),durationMs:Date.now()-t,message:`${this.description} failed: ${S(s)}`}}}checkDependencies(e){if(!this.requiresPhases?.length)return!0;for(let t of this.requiresPhases)if(!e.results.get(t)?.success)return e.services.warn(`Phase ${this.name} requires ${t} which has not completed`),!1;return!0}checkEnhancements(e){if(!this.requiresEnhancements?.length)return!0;for(let t of this.requiresEnhancements)if(!(t==="claudeFlow"?e.enhancements.claudeFlow:t==="ruvector"?e.enhancements.ruvector:!1))return e.services.warn(`Phase ${this.name} requires ${t} which is not available`),!1;return!0}};de();ye();import{existsSync as O}from"fs";import{join as j}from"path";var H=class extends k{name="detection";description="Detect existing installations";order=10;critical=!0;async run(e){let{projectRoot:t}=e,s=await this.detectV2Installation(t),n=O(j(t,".agentic-qe","config.yaml")),o=s.version?.startsWith("3."),r=s.detected,i=n||o||!1,d=!r&&!i;return e.v2Detection=s,{v2Detected:r,v3Detected:i,freshInstall:d,v2Detection:s}}async detectV2Installation(e){let t=j(e,".agentic-qe","memory.db"),s=j(e,".agentic-qe","config"),n=j(e,".claude","agents"),o=j(e,".agentic-qe","config","learning.json"),r=O(t),i=O(s),d=O(n),p=O(o),l=O(j(e,".agentic-qe","config.yaml")),u,m=!1;return r&&(u=this.readVersionFromDb(t),u?m=u.startsWith("3."):u="2.x.x"),{detected:!m&&r&&(!u?.startsWith("3.")||p&&!l),memoryDbPath:r?t:void 0,configPath:i?s:void 0,agentsPath:d?n:void 0,hasMemoryDb:r,hasConfig:i,hasAgents:d,version:u}}readVersionFromDb(e){try{let t=D(e,{readonly:!0,fileMustExist:!0});try{if(!t.prepare(`
|
|
3
3
|
SELECT name FROM sqlite_master
|
|
4
4
|
WHERE type='table' AND name='kv_store'
|
|
5
5
|
`).get()){t.close();return}let n=t.prepare(`
|
|
6
6
|
SELECT value FROM kv_store
|
|
7
7
|
WHERE key = 'aqe_version' AND namespace = '_system'
|
|
8
|
-
`).get();return t.close(),n?x(n.value):void 0}catch{t.close();return}}catch{return}}};var
|
|
8
|
+
`).get();return t.close(),n?x(n.value):void 0}catch{t.close();return}}catch{return}}};var G=class extends k{name="analysis";description="Analyze project structure";order=20;critical=!0;requiresPhases=["detection"];async run(e){let s=await Fe(e.projectRoot).analyze();return e.analysis=s,e.services.log(` Project: ${s.projectName}`),e.services.log(` Languages: ${s.languages.map(n=>n.name).join(", ")}`),e.services.log(` Frameworks: ${s.frameworks.map(n=>n.name).join(", ")}`),s}};var U=class extends k{name="configuration";description="Generate configuration";order=30;critical=!0;requiresPhases=["analysis"];async run(e){if(!e.analysis)throw new Error("Analysis phase must complete before configuration");let s=Ne({minimal:e.options.minimal}).recommend(e.analysis);return s=this.applyOptions(s,e),e.config=s,e.services.log(` Version: ${s.version}`),e.services.log(` Learning: ${s.learning.enabled?"enabled":"disabled"}`),e.services.log(` Workers: ${s.workers.enabled.length}`),s}applyOptions(e,t){let{options:s}=t;return s.minimal&&(e.skills.install=!1,e.learning.pretrainedPatterns=!1,e.workers.enabled=[],e.workers.daemonAutoStart=!1),s.skipPatterns&&(e.learning.pretrainedPatterns=!1),s.wizardAnswers&&(e=this.applyWizardAnswers(e,s.wizardAnswers)),e}applyWizardAnswers(e,t){switch(t["project-type"]&&t["project-type"]!=="auto"&&(e.project.type=t["project-type"]),t["learning-mode"]){case"full":e.learning.enabled=!0,e.learning.embeddingModel="transformer";break;case"basic":e.learning.enabled=!0,e.learning.embeddingModel="hash";break;case"disabled":e.learning.enabled=!1;break}return t["load-patterns"]===!1&&(e.learning.pretrainedPatterns=!1),t.hooks===!1&&(e.hooks.claudeCode=!1),t.workers===!1&&(e.workers.daemonAutoStart=!1),t.skills===!1&&(e.skills.install=!1),e}};import{existsSync as K,mkdirSync as be}from"fs";import{join as z}from"path";Q();It();var J=class extends k{name="database";description="Initialize persistence database";order=40;critical=!0;requiresPhases=["configuration"];async shouldRun(e){return e.options.memoryBackend!=="memory"}async run(e){let{projectRoot:t}=e,s=z(t,"vectors.db");K(s)&&e.services.log(` \u26A0 Stale vectors.db detected at ${s}
|
|
9
9
|
This file is left over from @ruvector/router (pre-v3.9.6).
|
|
10
10
|
It is no longer read or written by AQE. Safe to delete:
|
|
11
|
-
rm "${s}"`);let n=z(t,".agentic-qe");K(n)||
|
|
11
|
+
rm "${s}"`);let n=z(t,".agentic-qe");K(n)||be(n,{recursive:!0});let o=z(n,"workers");K(o)||be(o,{recursive:!0});let r=z(n,"data");K(r)||be(r,{recursive:!0});let i=z(n,"memory.db"),d=!K(i);try{let{initializeUnifiedMemory:p,resetUnifiedMemory:l}=await import("./unified-memory-QARWQKJ2.js"),u=await p({dbPath:i,walMode:!0,busyTimeout:5e3}),y=u.getStats().tables.map(B=>B.name);await u.kvSet("_init_marker",{initialized:new Date().toISOString(),projectRoot:t,version:ue()},"_system");let E=u.getDatabase().prepare("SELECT version FROM schema_version WHERE id = 1").get()?.version??0;return l(),e.services.log(` Database: ${i}`),e.services.log(` Schema version: v${E}`),e.services.log(` Tables: ${y.length} (v3 full schema)`),{dbPath:i,created:d,tablesCreated:y,schemaVersion:E}}catch(p){throw je(p)?new Error(`SQLite persistence initialization FAILED: ${S(Oe(p))}`,{cause:p}):new Error(`SQLite persistence initialization FAILED: ${p}
|
|
12
12
|
Database path: ${i}
|
|
13
|
-
Ensure the directory is writable and has sufficient disk space.`)}}};import{existsSync as
|
|
13
|
+
Ensure the directory is writable and has sufficient disk space.`)}}};import{existsSync as me,mkdirSync as we,writeFileSync as At}from"fs";import{join as T}from"path";var Y=class extends k{name="learning";description="Initialize learning system";order=50;critical=!1;requiresPhases=["database","configuration"];async shouldRun(e){return e.options.memoryBackend==="memory"?!1:e.config?.learning?.enabled??!0}async run(e){let t=e.config,{projectRoot:s,options:n}=e;if(!t.learning.enabled)return{enabled:!1,dataDir:"",hnswDir:"",patternsLoaded:0};let o=T(s,".agentic-qe","data");me(o)||we(o,{recursive:!0});let r=T(o,"hnsw");me(r)||we(r,{recursive:!0});let i=T(o,"learning-config.json"),d={embeddingModel:t.learning.embeddingModel,hnswConfig:t.learning.hnswConfig,qualityThreshold:t.learning.qualityThreshold,promotionThreshold:t.learning.promotionThreshold,databasePath:T(o,"memory.db"),hnswIndexPath:T(r,"index.bin"),initialized:new Date().toISOString()};W(i,d,[["initialized"]]);let p=0;return t.learning.pretrainedPatterns&&!n.skipPatterns&&(p=await this.loadPretrainedPatterns(o,e)),e.services.log(` Data dir: ${o}`),e.services.log(` HNSW dir: ${r}`),e.services.log(` Patterns loaded: ${p}`),{enabled:!0,dataDir:o,hnswDir:r,patternsLoaded:p}}async loadPretrainedPatterns(e,t){try{let s=T(e,"patterns");me(s)||we(s,{recursive:!0});let n=T(s,"index.json");return me(n)||At(n,JSON.stringify({version:ue(),domains:[],loadedAt:new Date().toISOString()},null,2),"utf-8"),0}catch(s){return t.services.warn(`Could not load pre-trained patterns: ${s}`),0}}};de();ye();import{existsSync as _t,statSync as xt}from"fs";import{join as fe}from"path";var tt=3e4,nt=18e4,st=["**/node_modules/**","**/dist/**","**/build/**","**/out/**","**/coverage/**","**/.agentic-qe/**","**/.git/**","**/.next/**","**/.nuxt/**","**/.output/**","**/__pycache__/**","**/.pytest_cache/**","**/target/**","**/vendor/**","**/.venv/**","**/venv/**","**/.tox/**","**/*.min.js","**/*.min.css","**/*.bundle.js","**/*.map","**/package-lock.json","**/yarn.lock","**/pnpm-lock.yaml","**/Pipfile.lock","**/poetry.lock","**/.env","**/.env.*"],X=class extends k{name="code-intelligence";description="Code intelligence pre-scan";order=60;critical=!1;requiresPhases=["database"];async shouldRun(e){if(e.options.memoryBackend==="memory")return e.services.log(" Code intelligence skipped (database-free mode)"),!1;let t=process.env.AQE_SKIP_CODE_INDEX;return t==="1"||t==="true"?(e.services.log(" Code intelligence skipped (AQE_SKIP_CODE_INDEX=1)"),e.services.log(" Run `aqe code index` later to build the KG on demand."),!1):e.options.skipCodeIndex?(e.services.log(" Code intelligence skipped (--skip-code-index)"),e.services.log(" Run `aqe code index` later to build the KG on demand."),!1):!0}async run(e){let{projectRoot:t}=e,s=fe(t,".agentic-qe","memory.db");if(!_t(s))return e.services.log(" Building knowledge graph..."),await this.runCodeIntelligenceScan(t,e,!1);let n=D(s);try{if(!this.checkCodeIntelligenceIndex(n))return n.close(),e.services.log(" Building knowledge graph..."),await this.runCodeIntelligenceScan(t,e,!1);let r=this.getLastIndexedAt(n);if(!r){let p=this.getKGEntryCount(n);return n.close(),e.services.log(` Using existing index (${p} entries)`),{status:"existing",entries:p}}let i=this.getKGEntryCount(n);n.close();let d=await this.findChangedFiles(t,r);return d.length===0?(e.services.log(` Index up to date (${i} entries)`),{status:"existing",entries:i}):(e.services.log(` Delta scan: ${d.length} files changed since last index...`),await this.runCodeIntelligenceScan(t,e,!0,d))}catch(o){try{n.close()}catch{}throw o}}checkCodeIntelligenceIndex(e){try{return e.prepare(`
|
|
14
14
|
SELECT COUNT(*) as count FROM kv_store
|
|
15
15
|
WHERE namespace = 'code-intelligence:kg'
|
|
16
16
|
`).get().count>0}catch{return!1}}getKGEntryCount(e){try{return e.prepare(`
|
|
17
17
|
SELECT COUNT(*) as count FROM kv_store
|
|
18
18
|
WHERE namespace LIKE 'code-intelligence:kg%'
|
|
19
|
-
`).get().count}catch{return 0}}async runCodeIntelligenceScan(e,t,s,n){let{KnowledgeGraphService:o}=await import("./knowledge-graph-
|
|
19
|
+
`).get().count}catch{return 0}}async runCodeIntelligenceScan(e,t,s,n){let{KnowledgeGraphService:o}=await import("./knowledge-graph-25XXKDJN.js"),r=fe(e,".agentic-qe","memory.db"),i={type:"sqlite",sqlite:{path:r,walMode:!0}},{backend:d}=await Qe(i,!0),p=new o(d,{namespace:"code-intelligence:kg",enableVectorEmbeddings:!0,projectRoot:e});try{let l;if(n)l=n;else{let{glob:m}=await import("tinyglobby");l=(await m(["**/*.ts","**/*.tsx","**/*.js","**/*.jsx","**/*.py"],{cwd:e,ignore:st,expandDirectories:!1})).map(g=>fe(e,g))}t.services.log(` Scanning ${l.length} source files...`);let u=await this.runBoundedScan(p,l,s,t);if(u.status==="timeout")return t.services.warn(` \u26A0 Code intelligence pre-scan exceeded ${nt/1e3}s phase cap. Indexed ${u.entries} entries before timeout. Last file: ${u.timeoutFile??"(unknown)"}. Init is continuing \u2014 re-run 'aqe code index' later, or report this file to https://github.com/proffesor-for-testing/agentic-qe/issues.`),u;if(u.status==="indexed"){let m=s?"Delta indexed":"Indexed";t.services.log(` ${m} ${u.entries} entries to ${r}`),await this.buildHypergraph(r,l,t)}return u}finally{try{p.destroy()}catch{}try{await d.dispose()}catch{}}}async runBoundedScan(e,t,s,n){let o=0,r=0,i=0,d="",p=Date.now(),l=!1;s||await e.clear();let u=n.projectRoot,m=g=>g.startsWith(u)?g.slice(u.length+1):g;for(let g of t){if(Date.now()-p>nt){l=!0;break}d=g,n.services.log(` [${i+1}/${t.length}] ${m(g)}`);try{let b=await this.withTimeout(e.index({paths:[g],incremental:!0,includeTests:!0}),tt,g);b.success&&(o+=b.value.nodesCreated,r+=b.value.edgesCreated)}catch(b){let E=b instanceof Error?b.message:String(b);E.startsWith("AQE_PER_FILE_TIMEOUT")?n.services.warn(` \u26A0 Skipped ${m(g)} \u2014 indexing exceeded ${tt/1e3}s`):n.services.warn(` \u26A0 Failed to index ${m(g)}: ${E}`)}i++}let y=o+r;return l?{status:"timeout",entries:y,timeoutFile:d}:{status:"indexed",entries:y}}withTimeout(e,t,s){return new Promise((n,o)=>{let r=setTimeout(()=>{o(new Error(`AQE_PER_FILE_TIMEOUT: ${s}`))},t);typeof r.unref=="function"&&r.unref(),e.then(i=>{clearTimeout(r),n(i)},i=>{clearTimeout(r),o(i)})})}async buildHypergraph(e,t,s){try{let{extractCodeIndex:n}=await import("./code-index-extractor-D4DBT6OL.js"),{createHypergraphEngine:o}=await import("./hypergraph-engine-ZRY6MTDV.js"),r=D(e),i=await o({db:r,maxTraversalDepth:10,maxQueryResults:1e3,enableVectorSearch:!1}),d=await n(t),p=await i.buildFromIndexResult(d);r.close(),p.nodesCreated+p.edgesCreated>0&&s.services.log(` Hypergraph: ${p.nodesCreated} nodes, ${p.edgesCreated} edges`)}catch(n){s.services.warn?.(` Hypergraph build skipped: ${n}`)}}getLastIndexedAt(e){try{let t=e.prepare(`
|
|
20
20
|
SELECT value FROM kv_store
|
|
21
21
|
WHERE namespace = 'code-intelligence:kg'
|
|
22
22
|
AND key = 'metadata:index'
|
|
23
|
-
`).get();if(!t)return null;let s=x(t.value);if(!s.indexedAt)return null;let n=new Date(s.indexedAt);return isNaN(n.getTime())?null:n}catch{return null}}async findChangedFiles(e,t){let{glob:s}=await import("tinyglobby"),n=await s(["**/*.ts","**/*.tsx","**/*.js","**/*.jsx","**/*.py"],{cwd:e,ignore:st,expandDirectories:!1}),o=t.getTime(),r=[];for(let i of n){let d=
|
|
24
|
-
`);M(s,n,"utf-8")}installHookAssets(e,t){let{projectRoot:s}=t;this.installBrainCheckpoint(s,t),this.installStatusline(s,t),this.installHookShim(s,t);let n=
|
|
25
|
-
`),"utf-8")}let o=
|
|
23
|
+
`).get();if(!t)return null;let s=x(t.value);if(!s.indexedAt)return null;let n=new Date(s.indexedAt);return isNaN(n.getTime())?null:n}catch{return null}}async findChangedFiles(e,t){let{glob:s}=await import("tinyglobby"),n=await s(["**/*.ts","**/*.tsx","**/*.js","**/*.jsx","**/*.py"],{cwd:e,ignore:st,expandDirectories:!1}),o=t.getTime(),r=[];for(let i of n){let d=fe(e,i);try{xt(d).mtimeMs>o&&r.push(d)}catch{}}return r}};de();import{existsSync as w,mkdirSync as Z,readFileSync as rt,writeFileSync as M}from"fs";import{join as v,dirname as Dt}from"path";import{fileURLToPath as Tt}from"url";var $t=Tt(import.meta.url),ot=Dt($t),qt=[["aqe","initialized"]],ee=class extends k{name="hooks";description="Configure Claude Code hooks";order=70;critical=!1;requiresPhases=["configuration"];async shouldRun(e){return e.options.noClaude?(e.services.log(" Hooks skipped (--no-claude)"),!1):e.config?.hooks?.claudeCode??!0}async run(e){let t=e.config,{projectRoot:s}=e;if(!t.hooks.claudeCode)return{configured:!1,settingsPath:"",hookTypes:[],existingAqeDetected:!1};let n=v(s,".claude");w(n)||Z(n,{recursive:!0});let o=v(n,"hooks");w(o)||Z(o,{recursive:!0});let r=v(n,"settings.json"),i={},d;if(w(r))try{let R=rt(r,"utf-8");i=x(R),d=x(R)}catch{i={}}let p=this.generateHooksConfig(t,s),l=Object.keys(p),u=i.hooks||{},m=this.hasExistingAqeHooks(u);m&&e.services.log(" Detected existing AQE hooks \u2014 replacing with updated config"),i.hooks=He(u,p);let y=i.env,g={memoryBackend:e.options.memoryBackend};i.env=Ge(y,Ue(t,g),g);let b=ze(t,s,g);Ke(i,b,{statusLine:!e.options.noStatusLine,...g});let E=i.enabledMcpjsonServers||[];if(E=E.filter(R=>R!=="aqe"),E.includes("agentic-qe")||E.push("agentic-qe"),i.enabledMcpjsonServers=E,Be(d,i,qt)){let R=Ve(r);R&&e.services.log(` Backup created: ${R}`),M(r,JSON.stringify(i,null,2),"utf-8")}else e.services.log(" Settings unchanged \u2014 .claude/settings.json left as-is");this.writeHooksReadme(o,l),this.installHookAssets(o,e);try{let R=rt(r,"utf-8"),P=x(R).hooks;(!P||!this.hasExistingAqeHooks(P))&&e.services.log(" WARNING: settings.json written but AQE hooks not detected \u2014 check settings-merge logic")}catch{e.services.log(" WARNING: Could not verify settings.json after write")}return e.services.log(` Settings: ${r}`),e.services.log(` Hooks dir: ${o}`),e.services.log(` Hook types: ${l.join(", ")}`),{configured:!0,settingsPath:r,hookTypes:l,existingAqeDetected:m}}writeHooksReadme(e,t){let s=v(e,"README.txt");if(w(s))return;let n=["AQE Hooks Directory","====================","","Claude Code hooks are configured in .claude/settings.json (not as files here).","This directory contains supporting infrastructure for the learning system.","","Configured hook types: "+t.join(", "),"","Files:"," settings.json \u2014 Hook definitions (in parent .claude/ directory)"," helpers/brain-checkpoint.cjs \u2014 Auto-exports brain to aqe.rvf on session end"," cross-phase-memory.yaml \u2014 QCSD feedback loop configuration","","Manual testing:"," npx agentic-qe hooks session-start --session-id test --json",' npx agentic-qe hooks route --task "generate tests" --json'," npx agentic-qe hooks post-edit --file src/example.ts --success --json",""].join(`
|
|
24
|
+
`);M(s,n,"utf-8")}installHookAssets(e,t){let{projectRoot:s}=t;this.installBrainCheckpoint(s,t),this.installStatusline(s,t),this.installHookShim(s,t);let n=v(e,"cross-phase-memory.yaml");if(!w(n)){let r=[v(s,"v3","assets","hooks","cross-phase-memory.yaml"),v(s,"assets","hooks","cross-phase-memory.yaml"),v(s,"node_modules","agentic-qe","v3","assets","hooks","cross-phase-memory.yaml")],i=!1;for(let d of r)if(w(d)){let{copyFileSync:p}=Rt("fs");p(d,n),t.services.log(" Installed cross-phase memory config"),i=!0;break}i||M(n,["# Cross-Phase Memory Hooks Configuration","# Generated by aqe init",'version: "1.0"',"enabled: true",""].join(`
|
|
25
|
+
`),"utf-8")}let o=v(e,"v3-domain-workers.json");w(o)||M(o,JSON.stringify({version:"3.0",workers:[{name:"pattern-consolidator",interval:"5m",enabled:!0},{name:"routing-accuracy-monitor",interval:"10m",enabled:!0},{name:"coverage-gap-scanner",interval:"15m",enabled:!0},{name:"flaky-test-detector",interval:"30m",enabled:!0}]},null,2),"utf-8")}hasExistingAqeHooks(e){for(let t of Object.values(e))if(Array.isArray(t)){for(let s of t)if(We(s))return!0}return!1}installBrainCheckpoint(e,t){let s=v(e,".claude","helpers");w(s)||Z(s,{recursive:!0});let n=v(s,"brain-checkpoint.cjs"),o=[v(e,".claude","helpers","brain-checkpoint.cjs"),v(e,"node_modules","agentic-qe",".claude","helpers","brain-checkpoint.cjs"),v(ot,"..","..","..",".claude","helpers","brain-checkpoint.cjs")];for(let r of o)if(w(r)&&r!==n){pe(r,n)&&t.services.log(" Installed brain-checkpoint.cjs (copied)");return}w(n)||(M(n,this.generateBrainCheckpointScript(),"utf-8"),t.services.log(" Installed brain-checkpoint.cjs (generated)"))}installStatusline(e,t){let s=v(e,".claude","helpers");w(s)||Z(s,{recursive:!0});let n=v(s,"statusline-v3.cjs"),o=[v(e,"node_modules","agentic-qe","assets","helpers","statusline-v3.cjs"),v(e,"assets","helpers","statusline-v3.cjs")];for(let r of o)if(w(r)&&r!==n){pe(r,n)&&t.services.log(" Installed statusline-v3.cjs (copied)");return}w(n)||(M(n,this.generateMinimalStatuslineScript(),"utf-8"),t.services.log(" Installed statusline-v3.cjs (generated)"))}installHookShim(e,t){let s=v(e,".claude","hooks");w(s)||Z(s,{recursive:!0});let n=v(s,"aqe-hook.cjs"),o=[v(e,"node_modules","agentic-qe",".claude","hooks","aqe-hook.cjs"),v(ot,"..","..","..",".claude","hooks","aqe-hook.cjs")];for(let r of o)if(w(r)&&r!==n){pe(r,n)&&t.services.log(" Installed aqe-hook.cjs (copied)");return}w(n)||t.services.log(" \u26A0 aqe-hook.cjs source not found \u2014 lifecycle hooks cannot run until AQE is reinstalled")}generateMinimalStatuslineScript(){return`#!/usr/bin/env node
|
|
26
26
|
/**
|
|
27
27
|
* Agentic QE v3 Statusline (minimal fallback, generated by aqe init)
|
|
28
28
|
* For the full statusline, reinstall: npx agentic-qe init --auto
|
|
@@ -60,6 +60,7 @@ console.log(\`\\x1b[1m\\x1b[35m\u258A Agentic QE v3\\x1b[0m\${branchStr}\${patSt
|
|
|
60
60
|
* node brain-checkpoint.cjs verify # Verify aqe.rvf exists (session-start)
|
|
61
61
|
*/
|
|
62
62
|
const { execFileSync } = require('child_process');
|
|
63
|
+
const crypto = require('crypto');
|
|
63
64
|
const fs = require('fs');
|
|
64
65
|
const path = require('path');
|
|
65
66
|
|
|
@@ -68,6 +69,11 @@ const AQE_DIR = path.join(PROJECT_ROOT, '.agentic-qe');
|
|
|
68
69
|
const RVF_PATH = path.join(AQE_DIR, 'aqe.rvf');
|
|
69
70
|
const DB_PATH = path.join(AQE_DIR, 'memory.db');
|
|
70
71
|
const MAX_AGE_HOURS = 24;
|
|
72
|
+
// #1238: after a too-large export, skip the Stop-hook export for a while
|
|
73
|
+
// unless a newer aqe.rvf shows that an export has succeeded since.
|
|
74
|
+
const SKIP_PATH = path.join(AQE_DIR, 'brain-checkpoint.skip.json');
|
|
75
|
+
const RETRY_ENV = Number.parseFloat(process.env.AQE_BRAIN_CHECKPOINT_RETRY_HOURS || '');
|
|
76
|
+
const TOO_LARGE_RETRY_HOURS = Number.isFinite(RETRY_ENV) && RETRY_ENV >= 0 ? RETRY_ENV : 6;
|
|
71
77
|
// Windows (#872): never execFile aqe.cmd (EINVAL without a shell); reuse the
|
|
72
78
|
// hook shim's resolver, which runs the AQE bundle via node instead.
|
|
73
79
|
function aqeInvocation() {
|
|
@@ -88,32 +94,110 @@ function aqeInvocation() {
|
|
|
88
94
|
|
|
89
95
|
function log(msg) { process.stderr.write('[brain-checkpoint] ' + msg + '\\n'); }
|
|
90
96
|
|
|
97
|
+
function activeSkip() {
|
|
98
|
+
let st; try { st = fs.lstatSync(SKIP_PATH); } catch { return null; }
|
|
99
|
+
let skip = null;
|
|
100
|
+
if (st.isFile()) { try { skip = JSON.parse(fs.readFileSync(SKIP_PATH, 'utf8')); } catch { /* unreadable */ } }
|
|
101
|
+
const at = skip ? Date.parse(skip.at) : NaN;
|
|
102
|
+
let rvfMtime = 0; try { rvfMtime = fs.lstatSync(RVF_PATH).mtimeMs; } catch { /* absent */ }
|
|
103
|
+
if (!Number.isFinite(at) || Date.now() >= at + TOO_LARGE_RETRY_HOURS * 3600000 || rvfMtime > at) {
|
|
104
|
+
try { fs.unlinkSync(SKIP_PATH); } catch { /* best-effort */ }
|
|
105
|
+
return null;
|
|
106
|
+
}
|
|
107
|
+
return skip;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
function writeSkip(reason) {
|
|
111
|
+
const at = new Date();
|
|
112
|
+
const skip = { reason, at: at.toISOString(), retryAfter: new Date(at.getTime() + TOO_LARGE_RETRY_HOURS * 3600000).toISOString() };
|
|
113
|
+
// 'wx' after unlink: never write through a planted symlink (#970).
|
|
114
|
+
try { try { fs.unlinkSync(SKIP_PATH); } catch { /* absent */ } fs.writeFileSync(SKIP_PATH, JSON.stringify(skip) + '\\n', { flag: 'wx' }); } catch { /* best-effort */ }
|
|
115
|
+
return skip;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
// Export to a temp store next to aqe.rvf; rename it over aqe.rvf only on
|
|
119
|
+
// success, so a failed, too-large or killed export keeps the last checkpoint.
|
|
120
|
+
const RVF_SIDECARS = ['.idmap.json', '.manifest.json'];
|
|
121
|
+
const TMP_PREFIX = path.basename(RVF_PATH) + '.tmp-';
|
|
122
|
+
function removeEntry(p) { try { fs.unlinkSync(p); } catch (e) { if (!e || e.code !== 'ENOENT') throw e; } }
|
|
123
|
+
function isPidAlive(pid) { try { process.kill(pid, 0); return true; } catch (e) { return !!e && e.code === 'EPERM'; } }
|
|
124
|
+
function removeByPrefix(prefix, keep) {
|
|
125
|
+
let entries = []; try { entries = fs.readdirSync(AQE_DIR); } catch { return; }
|
|
126
|
+
for (const entry of entries) {
|
|
127
|
+
if (!entry.startsWith(prefix) || (keep && keep(entry))) continue;
|
|
128
|
+
try { removeEntry(path.join(AQE_DIR, entry)); } catch { /* best-effort */ }
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
function sweepStaleTmp() {
|
|
132
|
+
removeByPrefix(TMP_PREFIX, (entry) => {
|
|
133
|
+
const pid = Number.parseInt(entry.slice(TMP_PREFIX.length).split('-')[0], 10);
|
|
134
|
+
return !Number.isInteger(pid) || pid <= 0 || isPidAlive(pid);
|
|
135
|
+
});
|
|
136
|
+
}
|
|
137
|
+
function lexists(p) { try { fs.lstatSync(p); return true; } catch { return false; } }
|
|
138
|
+
// rename() replaces a planted symlink without writing through it (#970). The
|
|
139
|
+
// store goes first: if that fails nothing changed. If a sidecar rename fails
|
|
140
|
+
// afterwards, the stale sidecar is removed, so the new store is never read
|
|
141
|
+
// with the previous export's idmap.
|
|
142
|
+
function promote(tmp) {
|
|
143
|
+
fs.renameSync(tmp, RVF_PATH);
|
|
144
|
+
for (const suffix of RVF_SIDECARS) {
|
|
145
|
+
try {
|
|
146
|
+
if (lexists(tmp + suffix)) fs.renameSync(tmp + suffix, RVF_PATH + suffix);
|
|
147
|
+
else removeEntry(RVF_PATH + suffix);
|
|
148
|
+
} catch { try { removeEntry(RVF_PATH + suffix); } catch { /* best-effort */ } }
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
|
|
91
152
|
function exportBrain() {
|
|
92
153
|
if (!fs.existsSync(DB_PATH)) { log('No memory.db, skipping'); return { exported: false }; }
|
|
93
154
|
const aqe = aqeInvocation();
|
|
94
155
|
if (!aqe.cmd) { log('Export skipped: ' + aqe.reason); return { exported: false, reason: aqe.reason }; }
|
|
95
|
-
// Never write through a committed symlink: .agentic-qe must be a real dir
|
|
96
|
-
// unlink (not existsSync) drops a planted aqe.rvf link, even a dangling one.
|
|
156
|
+
// Never write through a committed symlink: .agentic-qe must be a real dir.
|
|
97
157
|
let st; try { st = fs.lstatSync(AQE_DIR); } catch { /* missing */ }
|
|
98
158
|
if (!st || !st.isDirectory()) { log('Export skipped: .agentic-qe is a symlink'); return { exported: false }; }
|
|
99
|
-
|
|
159
|
+
const skip = activeSkip();
|
|
160
|
+
if (skip) {
|
|
161
|
+
log('Export skipped until ' + skip.retryAfter + ': ' + skip.reason);
|
|
162
|
+
return { exported: false, skipped: true, reason: skip.reason, retryAfter: skip.retryAfter };
|
|
163
|
+
}
|
|
164
|
+
sweepStaleTmp();
|
|
165
|
+
const tmp = path.join(AQE_DIR, TMP_PREFIX + process.pid + '-' + crypto.randomBytes(4).toString('hex'));
|
|
100
166
|
try {
|
|
167
|
+
for (const suffix of ['', ...RVF_SIDECARS]) removeEntry(tmp + suffix);
|
|
101
168
|
const result = execFileSync(
|
|
102
|
-
aqe.cmd, [...aqe.args, 'brain', 'export', '-o',
|
|
103
|
-
{ timeout: 60000, encoding: 'utf-8', windowsHide: true }
|
|
169
|
+
aqe.cmd, [...aqe.args, 'brain', 'export', '-o', tmp, '--format', 'rvf'],
|
|
170
|
+
{ timeout: 60000, encoding: 'utf-8', windowsHide: true, stdio: ['ignore', 'pipe', 'pipe'] }
|
|
104
171
|
);
|
|
172
|
+
// A zero exit without a store is a failure, not an empty checkpoint.
|
|
173
|
+
if (!lexists(tmp)) throw new Error('brain export exited 0 but wrote no store');
|
|
174
|
+
promote(tmp);
|
|
105
175
|
const m = result.match(/Patterns:\\s+(\\d+)/);
|
|
106
176
|
const p = m ? m[1] : '0';
|
|
107
177
|
log('Exported ' + p + ' patterns to aqe.rvf');
|
|
108
178
|
return { exported: true, patterns: parseInt(p) };
|
|
109
179
|
} catch (e) {
|
|
110
|
-
|
|
180
|
+
const tooLarge = (String(e.stderr || '') + String(e.stdout || '')).match(/RVF_KERNEL_TOO_LARGE:[^\\n]*/);
|
|
181
|
+
if (tooLarge) {
|
|
182
|
+
const skip = writeSkip(tooLarge[0].trim());
|
|
183
|
+
log('Export failed: ' + skip.reason);
|
|
184
|
+
log('Skipping the checkpoint export until ' + skip.retryAfter + ' (AQE_BRAIN_CHECKPOINT_RETRY_HOURS sets the wait).');
|
|
185
|
+
return { exported: false, tooLarge: true, reason: skip.reason, retryAfter: skip.retryAfter };
|
|
186
|
+
}
|
|
187
|
+
log('Export failed: ' + e.message + ' (previous aqe.rvf kept)');
|
|
111
188
|
return { exported: false, reason: e.message };
|
|
189
|
+
} finally {
|
|
190
|
+
removeByPrefix(path.basename(tmp));
|
|
112
191
|
}
|
|
113
192
|
}
|
|
114
193
|
|
|
115
194
|
function verifyBrain() {
|
|
116
195
|
if (!fs.existsSync(RVF_PATH)) {
|
|
196
|
+
const skip = activeSkip();
|
|
197
|
+
if (skip) {
|
|
198
|
+
log('No aqe.rvf found; checkpoint export paused until ' + skip.retryAfter + ': ' + skip.reason);
|
|
199
|
+
return { valid: false, reason: 'missing', skippedUntil: skip.retryAfter };
|
|
200
|
+
}
|
|
117
201
|
log('No aqe.rvf found');
|
|
118
202
|
return { valid: false, reason: 'missing' };
|
|
119
203
|
}
|
|
@@ -128,10 +212,10 @@ function verifyBrain() {
|
|
|
128
212
|
const cmd = process.argv[2] || 'verify';
|
|
129
213
|
const result = cmd === 'export' ? exportBrain() : verifyBrain();
|
|
130
214
|
if (process.argv.includes('--json')) process.stdout.write(JSON.stringify(result));
|
|
131
|
-
`}generateHooksConfig(e,t){return{PreToolUse:[{matcher:"^(Write|Edit|MultiEdit)$",hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" guard --file "$TOOL_INPUT_file_path" --json',timeout:3,continueOnError:!0}]},{matcher:"^(Write|Edit|MultiEdit)$",hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" pre-edit --file "$TOOL_INPUT_file_path" --json',timeout:5,continueOnError:!0}]},{matcher:"^Bash$",hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" pre-command --command "$TOOL_INPUT_command" --json',timeout:3,continueOnError:!0}]},{matcher:"^(Task|Agent)$",hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" pre-task --description "$TOOL_INPUT_prompt" --json',timeout:5,continueOnError:!0}]}],PostToolUse:[{matcher:"^(Write|Edit|MultiEdit)$",hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" post-edit --file "$TOOL_INPUT_file_path" --success --json',timeout:5,continueOnError:!0}]},{matcher:"^Bash$",hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" post-command --command "$TOOL_INPUT_command" --success true --json',timeout:5,continueOnError:!0}]},{matcher:"^(Task|Agent)$",hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" post-task --task-id "$TOOL_RESULT_agent_id" --agent "$TOOL_INPUT_subagent_type" --success true --description "$TOOL_INPUT_prompt" --json',timeout:5,continueOnError:!0}]}],UserPromptSubmit:[{hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" route --json',timeout:5,continueOnError:!0}]}],SessionStart:[{hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" session-start --session-id "$SESSION_ID" --json',timeout:10,continueOnError:!0}]},{hooks:[{type:"command",command:`sh -c 'exec node "\${CLAUDE_PROJECT_DIR:-.}/.claude/helpers/brain-checkpoint.cjs" verify --json'`,timeout:5,continueOnError:!0}]}],Stop:[{hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" session-end --save-state --json',timeout:5,continueOnError:!0}]},{hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" post-route --success true --json',timeout:5,continueOnError:!0}]},{hooks:[{type:"command",command:`sh -c 'exec node "\${CLAUDE_PROJECT_DIR:-.}/.claude/helpers/brain-checkpoint.cjs" export --json'`,timeout:60,continueOnError:!0}]}]}}};import{existsSync as Tt,readFileSync as Ot}from"fs";de();import{join as Mt}from"path";var te=class extends v{constructor(t=s=>Je(s)){super();this.detectPlugin=t}detectPlugin;name="mcp";description="Configure MCP server";order=80;critical=!1;requiresPhases=["configuration","database"];async run(t){let{projectRoot:s}=t;if(t.options.noClaude)return t.services.log(" MCP: skipped (--no-claude \u2014 .mcp.json is the Claude Code surface)"),{configured:!1,mcpPath:"",serverName:""};if(t.options.noMcp)return t.services.log(" MCP: skipped (--no-mcp)"),t.services.log(" CLI commands available: aqe memory, aqe test, aqe coverage, etc."),{configured:!1,mcpPath:"",serverName:""};if(!t.options.withMcp){let l=this.detectPlugin(s);if(l.enabled)return t.services.log(Ye(s)),{configured:!1,mcpPath:"",serverName:"",skippedForPlugin:l.pluginKey}}let n=t.options.memoryBackend==="memory",r={command:"aqe-mcp",args:[],env:n?{AQE_MEMORY_BACKEND:"memory",AQE_LEARNING_ENABLED:"false",AQE_WORKERS_ENABLED:"false",NODE_ENV:"production"}:{AQE_LEARNING_ENABLED:"true",AQE_WORKERS_ENABLED:"true",NODE_ENV:"production"}},i=Mt(s,".mcp.json"),d={};if(Tt(i))try{let l=Ot(i,"utf-8");d=x(l)}catch{d={}}d.mcpServers||(d.mcpServers={});let m=d.mcpServers;return m["agentic-qe"]=r,W(i,JSON.stringify(d,null,2)),t.services.log(` MCP config: ${i}`),t.services.log(" Server: agentic-qe"),n?(t.services.log(" Memory backend: in-memory (database-free)"),t.services.log(" Learning: disabled (db-free)"),t.services.log(" Workers: disabled (db-free)")):(t.services.log(" Learning: enabled"),t.services.log(" Workers: enabled")),{configured:!0,mcpPath:i,serverName:"agentic-qe"}}};import{existsSync as A,readFileSync as Ut,readdirSync as Kt}from"fs";import{join as _}from"path";import{createHash as Ft}from"crypto";import{constants as Nt,copyFileSync as it,existsSync as Ce,lstatSync as Se,readFileSync as lt,realpathSync as ct,unlinkSync as Lt}from"fs";import{dirname as dt,join as Ee,sep as Bt}from"path";var ne=".claude/skills/qe-court/evals/fixtures/seeded-mutant-delivery",Pe="qe-court/evals/fixtures/seeded-mutant-delivery",at=".claude/skills/testability-scoring/resources/templates",Qt="testability-scoring/resources/templates",Wt=Object.freeze([{id:"qe-court-seeded-mutant",retired:[{relPath:`${ne}/budget.test.ts`,shippedSha256:["add1ff4cb05978c136f8c2c5cc50059d920f06f409e5f6f304239b7dad3cf65d"]},{relPath:`${ne}/budget.ts`,shippedSha256:["11fc97cad19bb4fc0d31151a6d216ab99d0df0521b60be8fb19581d412147ef6"]}],replacements:[{relPath:`${ne}/budget-tests.ts.fixture`,source:`${Pe}/budget-tests.ts.fixture`},{relPath:`${ne}/budget.ts.fixture`,source:`${Pe}/budget.ts.fixture`}],refresh:[{relPath:`${ne}/README.md`,source:`${Pe}/README.md`,previousSha256:["d3988b92856d0023a7ae210dce3e0bdf76204f41d635fd29f7e243c168ff6109"]},{relPath:".claude/skills/qe-court/evals/qe-court.yaml",source:"qe-court/evals/qe-court.yaml",previousSha256:["412899013a51a099224bad04491d49dca19f2c567c5599adedabd0e1d58556c7","27c8be547dc032e2dbe488156dd7a30f79b1cc921fe92efec5b9bb0a151f0e9b"]}],advice:"3.15.6 renamed the qe-court seeded-mutant fixture to budget.ts.fixture / budget-tests.ts.fixture because budget.test.ts matches test-runner globs, so your vitest/jest collects it (#1017). The pair was left as is; delete or rename both files if you do not want your test runner to collect it"},{id:"testability-scoring-spec-template",retired:[{relPath:`${at}/testability-scoring.spec.template.js`,shippedSha256:["e85a3e25bb458f3d090834e121b02e8db83cdc589149b5cf7549853e1a067edf"]}],replacements:[{relPath:`${at}/testability-scoring-spec.template.js`,source:`${Qt}/testability-scoring-spec.template.js`}],refresh:[],advice:"3.15.6 renamed it to testability-scoring-spec.template.js because its name matches the `*.spec.*` test glob (#1017); delete or rename it if your test runner should not collect it"}]);function ut(c){return Ft("sha256").update(c).digest("hex")}function Ie(c,e){let t;try{t=ct(dt(e))}catch{return!1}return t===c||t.startsWith(c+Bt)}function Vt(c,e,t,s){let n;try{n=Se(e)}catch{return{state:"absent"}}if(!Ie(c,e))return{state:"blocked",why:`${t} resolves outside the project (symlinked directory)`};if(!n.isFile())return{state:"blocked",why:`${t} is not a regular file`};try{if(!s.includes(ut(lt(e))))return{state:"blocked",why:`${t} was modified since AQE installed it`}}catch(o){return{state:"blocked",why:`${t} is unreadable (${o instanceof Error?o.message:String(o)})`}}return{state:"removable"}}function mt(c,e={}){let t=e.groups??Wt,s={removed:[],installed:[],refreshed:[],kept:[],missingReplacements:[],replacementWarnings:[]},n;try{n=ct(c)}catch{return s}let o=r=>Ee(c,...r.split("/"));for(let r of t){let d=r.retired.map(l=>({file:l,probe:Vt(n,o(l.relPath),l.relPath.split("/").pop(),l.shippedSha256)})).filter(l=>l.probe.state!=="absent");if(d.length===0)continue;let m=d.filter(l=>l.probe.state==="blocked");if(m.length>0){s.kept.push({group:r.id,files:d.map(l=>l.file.relPath),why:m.map(l=>l.probe.why).join("; "),advice:r.advice});continue}for(let{file:l}of d)try{Lt(o(l.relPath)),s.removed.push(l.relPath)}catch(u){s.kept.push({group:r.id,files:[l.relPath],why:`could not remove (${u instanceof Error?u.message:String(u)})`,advice:r.advice})}for(let l of r.replacements){let u=o(l.relPath),p=e.sourceSkillsDir?Ee(e.sourceSkillsDir,...l.source.split("/")):void 0,y;try{y=Se(u)}catch{y=void 0}if(!y?.isFile()){if(y){s.missingReplacements.push(l.relPath),s.replacementWarnings.push(`${l.relPath} exists and is not a regular file (e.g. a symlink); not replaced`);continue}if(!p||!Ce(p)){s.missingReplacements.push(l.relPath);continue}try{if(!Ce(dt(u))||!Ie(n,u)){s.missingReplacements.push(l.relPath);continue}it(p,u,Nt.COPYFILE_EXCL),s.installed.push(l.relPath)}catch(f){s.missingReplacements.push(l.relPath),f?.code==="EEXIST"&&s.replacementWarnings.push(`${l.relPath} appeared during install; not replaced`)}}}for(let l of r.refresh){let u=o(l.relPath),p=e.sourceSkillsDir?Ee(e.sourceSkillsDir,...l.source.split("/")):void 0;if(!(!p||!Ce(p)))try{if(!Se(u).isFile()||!Ie(n,u)||!l.previousSha256.includes(ut(lt(u))))continue;it(p,u),s.refreshed.push(l.relPath)}catch{}}}return s}Q();import{spawnSync as Gt}from"node:child_process";import*as fe from"node:os";import*as gt from"node:fs";var F="vibium@^26.8.21",ft={platform:()=>fe.platform(),arch:()=>fe.arch(),existsSync:c=>gt.existsSync(c)},pt=["/usr/bin/chromium","/usr/bin/chromium-browser","/usr/bin/google-chrome","/usr/bin/google-chrome-stable","/snap/bin/chromium"];function Re(c=ft){if(c.platform()!=="linux"||c.arch()!=="arm64")return;let e=pt.find(t=>c.existsSync(t));return e?{code:"linux-arm64-system-chromium-found",browserPath:e,message:`Linux aarch64 detected. Vibium v26.3.x does not auto-download Chrome for Testing on ARM64. Found system browser at ${e}. Export VIBIUM_BROWSER_PATH=${e} before running vibium.`}:{code:"linux-arm64-no-system-chromium",message:`Linux aarch64 detected. Vibium v26.3.x does not auto-download Chrome for Testing on ARM64, and no system chromium was found on PATH (checked: ${pt.join(", ")}). Install via \`apt-get install chromium\` (or your distro's equivalent), then export VIBIUM_BROWSER_PATH=/usr/bin/chromium before running vibium.`}}function se(c,e,t,s){return c(e,t,{encoding:"utf8",timeout:s,maxBuffer:8*1024*1024})}var Ae=(c,e,t)=>Gt(c,e,t);function Ht(c=Ae,e=5e3){let t=se(c,"vibium",["--version"],e);if(t.status!==0)return null;let s=(t.stdout||"").trim(),n=(t.stderr||"").trim(),o=s||n;if(!o)return"unknown";let r=o.match(/v?(\d+\.\d+\.\d+(?:[-+][\w.]+)?)/);return r?r[1]:o.split(/\s+/)[0]||"unknown"}function re(c=Ae,e=5e3){let t=Ht(c,e);if(!t)return{status:"cli-missing"};let s=/^(\d+)\.(\d+)\.(\d+)(?:\+[\w.]+)?$/.exec(t);if(!s||Number(s[1])!==26||Number(s[2])<8||Number(s[2])===8&&Number(s[3])<21)return{status:"unsupported-version",version:t,message:`Vibium ${t} is unsupported; install ${F} for the browser.start() API`};let n=se(c,"vibium",["is-installed"],e);return n.status===0?{status:"ready",version:t}:{status:"payload-missing",version:t,message:n.stderr?.trim()||n.stdout?.trim()||P(n.error)||"Vibium Chrome/chromedriver payload is missing or incomplete"}}function ht(c={}){let e=c.packageSpec||F;if(c.skip)return{status:"skipped",packageSpec:e,message:"install skipped by options"};let t=c.spawner||Ae,s=c.platformProbe||ft,n=Re(s),o=re(t);if(o.status==="ready")return{status:"already-installed",version:o.version,packageSpec:e,platformHint:n};let r=c.npmBin||"npm",i=se(t,r,["--version"],5e3);if(i.error||i.status!==0)return{status:"npm-unavailable",packageSpec:e,message:`npm is not available on PATH. Install Node.js + npm, then run \`npm install -g ${e}\`.`};let d=c.timeoutMs||18e4,m=se(t,r,["install","-g",e],d);if(m.status!==0)return{status:"install-failed",packageSpec:e,message:m.stderr?.trim()||m.stdout?.trim()||P(m.error)||"unknown npm install failure"};let l=re(t);if(l.status==="payload-missing"){let u=se(t,"vibium",["install"],d);if(u.status!==0)return{status:"install-failed",packageSpec:e,platformHint:n,message:`Browser payload installation failed: ${u.stderr?.trim()||u.stdout?.trim()||"vibium install failed"}. Run \`vibium install\` and verify with \`vibium is-installed\`.`};l=re(t)}if(l.status!=="ready"){let u=l.message?`: ${l.message}`:"";return{status:"install-failed",packageSpec:e,platformHint:n,message:`npm completed, but Vibium readiness verification failed (${l.status})${u}. Run \`npm install -g ${e}\`, then verify with \`vibium is-installed\`.`}}return{status:"installed",version:l.version,packageSpec:e,platformHint:n}}var oe=class extends v{name="assets";description="Install skills and agents";order=90;critical=!1;requiresPhases=["configuration"];async run(e){let t=e.config,{projectRoot:s,options:n}=e,o=this.detectVersionUpgrade(e),r=n.upgrade||t.skills.overwrite||n.autoMode&&o,i=0,d=0,m=0,l=0,u=0,p=0,y=0,f=0,k=0,E,B,I=[],he=[];if(n.upgrade?e.services.log(" Upgrade mode: overwriting existing files"):n.autoMode&&o&&e.services.log(" Version upgrade detected: updating skills and agents"),!n.noClaude&&t.skills.install){let h=await be({projectRoot:s,installV2Skills:t.skills.installV2,installV3Skills:t.skills.installV3,overwrite:r}).install();i=h.installed.length,h.errors.length>0&&e.services.warn(`Skills warnings: ${h.errors.join(", ")}`)}if(!n.noClaude){let g=mt(s,{sourceSkillsDir:be({projectRoot:s}).getSourceSkillsDir()});I=g.removed,he=g.kept.flatMap(h=>h.files);for(let h of g.removed)e.services.log(` Removed retired asset: ${h}`);for(let h of[...g.installed,...g.refreshed])e.services.log(` Updated skill file: ${h}`);for(let h of g.kept)e.services.warn(`Kept ${h.files.join(", ")}: ${h.why}. ${h.advice}.`);for(let h of g.replacementWarnings)e.services.warn(`Skill file kept: ${h}.`);g.missingReplacements.length>0&&e.services.warn(`Could not install ${g.missingReplacements.join(", ")}; run "aqe init --upgrade" to refresh the skills.`)}if(!n.noClaude){try{let h=await Ze({projectRoot:s,installQEAgents:!0,installSubagents:!0,overwrite:r}).install();d=h.installed.length,h.errors.length>0&&e.services.warn(`Agents warnings: ${h.errors.join(", ")}`)}catch(g){e.services.warn(`Agents install error: ${g instanceof Error?g.message:g}`)}Me(s)}let S;if(n.browserEngine===!0&&!n.minimal)try{let g=re();if(g.status==="ready")S={status:"already-installed",version:g.version,packageSpec:F,platformHint:Re()},e.services.log(` Browser engine: vibium ${S.version} (already installed)`);else switch(e.services.log(" Browser engine: installing vibium via npm (this can take 1\u20133 minutes on first run; downloads Chrome for Testing)\u2026"),S=ht({skip:!1}),S.status){case"installed":e.services.log(` Browser engine: vibium ${S.version} installed`);break;case"skipped":e.services.log(" Browser engine: skipped");break;case"install-failed":e.services.warn(`Browser engine install failed (qe-browser skill will be unavailable until you run \`aqe init --browser-engine\`): ${S.message||"unknown"}`);break;case"npm-unavailable":e.services.warn("Browser engine: npm not on PATH \u2014 install Node.js + npm, then `aqe init --browser-engine` to enable qe-browser");break}S?.platformHint&&e.services.warn(` Browser engine platform hint: ${S.platformHint.message}`)}catch(g){let h=g instanceof Error?g.message:String(g);e.services.warn(`Browser engine install error: ${h}
|
|
215
|
+
`}generateHooksConfig(e,t){return{PreToolUse:[{matcher:"^(Write|Edit|MultiEdit)$",hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" guard --file "$TOOL_INPUT_file_path" --json',timeout:3,continueOnError:!0}]},{matcher:"^(Write|Edit|MultiEdit)$",hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" pre-edit --file "$TOOL_INPUT_file_path" --json',timeout:5,continueOnError:!0}]},{matcher:"^Bash$",hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" pre-command --command "$TOOL_INPUT_command" --json',timeout:3,continueOnError:!0}]},{matcher:"^(Task|Agent)$",hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" pre-task --description "$TOOL_INPUT_prompt" --json',timeout:5,continueOnError:!0}]}],PostToolUse:[{matcher:"^(Write|Edit|MultiEdit)$",hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" post-edit --file "$TOOL_INPUT_file_path" --success --json',timeout:5,continueOnError:!0}]},{matcher:"^Bash$",hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" post-command --command "$TOOL_INPUT_command" --success true --json',timeout:5,continueOnError:!0}]},{matcher:"^(Task|Agent)$",hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" post-task --task-id "$TOOL_RESULT_agent_id" --agent "$TOOL_INPUT_subagent_type" --success true --description "$TOOL_INPUT_prompt" --json',timeout:5,continueOnError:!0}]}],UserPromptSubmit:[{hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" route --json',timeout:5,continueOnError:!0}]}],SessionStart:[{hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" session-start --session-id "$SESSION_ID" --json',timeout:10,continueOnError:!0}]},{hooks:[{type:"command",command:`sh -c 'exec node "\${CLAUDE_PROJECT_DIR:-.}/.claude/helpers/brain-checkpoint.cjs" verify --json'`,timeout:5,continueOnError:!0}]}],Stop:[{hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" session-end --save-state --json',timeout:5,continueOnError:!0}]},{hooks:[{type:"command",command:'node "${CLAUDE_PROJECT_DIR:-.}/.claude/hooks/aqe-hook.cjs" post-route --success true --json',timeout:5,continueOnError:!0}]},{hooks:[{type:"command",command:`sh -c 'exec node "\${CLAUDE_PROJECT_DIR:-.}/.claude/helpers/brain-checkpoint.cjs" export --json'`,timeout:60,continueOnError:!0}]}]}}};import{existsSync as Ot,readFileSync as jt}from"fs";de();import{join as Mt}from"path";var te=class extends k{constructor(t=s=>Je(s)){super();this.detectPlugin=t}detectPlugin;name="mcp";description="Configure MCP server";order=80;critical=!1;requiresPhases=["configuration","database"];async run(t){let{projectRoot:s}=t;if(t.options.noClaude)return t.services.log(" MCP: skipped (--no-claude \u2014 .mcp.json is the Claude Code surface)"),{configured:!1,mcpPath:"",serverName:""};if(t.options.noMcp)return t.services.log(" MCP: skipped (--no-mcp)"),t.services.log(" CLI commands available: aqe memory, aqe test, aqe coverage, etc."),{configured:!1,mcpPath:"",serverName:""};if(!t.options.withMcp){let l=this.detectPlugin(s);if(l.enabled)return t.services.log(Ye(s)),{configured:!1,mcpPath:"",serverName:"",skippedForPlugin:l.pluginKey}}let n=t.options.memoryBackend==="memory",r={command:"aqe-mcp",args:[],env:n?{AQE_MEMORY_BACKEND:"memory",AQE_LEARNING_ENABLED:"false",AQE_WORKERS_ENABLED:"false",NODE_ENV:"production"}:{AQE_LEARNING_ENABLED:"true",AQE_WORKERS_ENABLED:"true",NODE_ENV:"production"}},i=Mt(s,".mcp.json"),d={};if(Ot(i))try{let l=jt(i,"utf-8");d=x(l)}catch{d={}}d.mcpServers||(d.mcpServers={});let p=d.mcpServers;return p["agentic-qe"]=r,V(i,JSON.stringify(d,null,2)),t.services.log(` MCP config: ${i}`),t.services.log(" Server: agentic-qe"),n?(t.services.log(" Memory backend: in-memory (database-free)"),t.services.log(" Learning: disabled (db-free)"),t.services.log(" Workers: disabled (db-free)")):(t.services.log(" Learning: enabled"),t.services.log(" Workers: enabled")),{configured:!0,mcpPath:i,serverName:"agentic-qe"}}};import{existsSync as A,readFileSync as Ut,readdirSync as Kt}from"fs";import{join as _}from"path";import{createHash as Ft}from"crypto";import{constants as Nt,copyFileSync as it,existsSync as Ce,lstatSync as Pe,readFileSync as lt,realpathSync as ct,unlinkSync as Lt}from"fs";import{dirname as dt,join as Ee,sep as Bt}from"path";var ne=".claude/skills/qe-court/evals/fixtures/seeded-mutant-delivery",Se="qe-court/evals/fixtures/seeded-mutant-delivery",at=".claude/skills/testability-scoring/resources/templates",Qt="testability-scoring/resources/templates",Vt=Object.freeze([{id:"qe-court-seeded-mutant",retired:[{relPath:`${ne}/budget.test.ts`,shippedSha256:["add1ff4cb05978c136f8c2c5cc50059d920f06f409e5f6f304239b7dad3cf65d"]},{relPath:`${ne}/budget.ts`,shippedSha256:["11fc97cad19bb4fc0d31151a6d216ab99d0df0521b60be8fb19581d412147ef6"]}],replacements:[{relPath:`${ne}/budget-tests.ts.fixture`,source:`${Se}/budget-tests.ts.fixture`},{relPath:`${ne}/budget.ts.fixture`,source:`${Se}/budget.ts.fixture`}],refresh:[{relPath:`${ne}/README.md`,source:`${Se}/README.md`,previousSha256:["d3988b92856d0023a7ae210dce3e0bdf76204f41d635fd29f7e243c168ff6109"]},{relPath:".claude/skills/qe-court/evals/qe-court.yaml",source:"qe-court/evals/qe-court.yaml",previousSha256:["412899013a51a099224bad04491d49dca19f2c567c5599adedabd0e1d58556c7","27c8be547dc032e2dbe488156dd7a30f79b1cc921fe92efec5b9bb0a151f0e9b"]}],advice:"3.15.6 renamed the qe-court seeded-mutant fixture to budget.ts.fixture / budget-tests.ts.fixture because budget.test.ts matches test-runner globs, so your vitest/jest collects it (#1017). The pair was left as is; delete or rename both files if you do not want your test runner to collect it"},{id:"testability-scoring-spec-template",retired:[{relPath:`${at}/testability-scoring.spec.template.js`,shippedSha256:["e85a3e25bb458f3d090834e121b02e8db83cdc589149b5cf7549853e1a067edf"]}],replacements:[{relPath:`${at}/testability-scoring-spec.template.js`,source:`${Qt}/testability-scoring-spec.template.js`}],refresh:[],advice:"3.15.6 renamed it to testability-scoring-spec.template.js because its name matches the `*.spec.*` test glob (#1017); delete or rename it if your test runner should not collect it"}]);function ut(c){return Ft("sha256").update(c).digest("hex")}function Re(c,e){let t;try{t=ct(dt(e))}catch{return!1}return t===c||t.startsWith(c+Bt)}function Wt(c,e,t,s){let n;try{n=Pe(e)}catch{return{state:"absent"}}if(!Re(c,e))return{state:"blocked",why:`${t} resolves outside the project (symlinked directory)`};if(!n.isFile())return{state:"blocked",why:`${t} is not a regular file`};try{if(!s.includes(ut(lt(e))))return{state:"blocked",why:`${t} was modified since AQE installed it`}}catch(o){return{state:"blocked",why:`${t} is unreadable (${o instanceof Error?o.message:String(o)})`}}return{state:"removable"}}function pt(c,e={}){let t=e.groups??Vt,s={removed:[],installed:[],refreshed:[],kept:[],missingReplacements:[],replacementWarnings:[]},n;try{n=ct(c)}catch{return s}let o=r=>Ee(c,...r.split("/"));for(let r of t){let d=r.retired.map(l=>({file:l,probe:Wt(n,o(l.relPath),l.relPath.split("/").pop(),l.shippedSha256)})).filter(l=>l.probe.state!=="absent");if(d.length===0)continue;let p=d.filter(l=>l.probe.state==="blocked");if(p.length>0){s.kept.push({group:r.id,files:d.map(l=>l.file.relPath),why:p.map(l=>l.probe.why).join("; "),advice:r.advice});continue}for(let{file:l}of d)try{Lt(o(l.relPath)),s.removed.push(l.relPath)}catch(u){s.kept.push({group:r.id,files:[l.relPath],why:`could not remove (${u instanceof Error?u.message:String(u)})`,advice:r.advice})}for(let l of r.replacements){let u=o(l.relPath),m=e.sourceSkillsDir?Ee(e.sourceSkillsDir,...l.source.split("/")):void 0,y;try{y=Pe(u)}catch{y=void 0}if(!y?.isFile()){if(y){s.missingReplacements.push(l.relPath),s.replacementWarnings.push(`${l.relPath} exists and is not a regular file (e.g. a symlink); not replaced`);continue}if(!m||!Ce(m)){s.missingReplacements.push(l.relPath);continue}try{if(!Ce(dt(u))||!Re(n,u)){s.missingReplacements.push(l.relPath);continue}it(m,u,Nt.COPYFILE_EXCL),s.installed.push(l.relPath)}catch(g){s.missingReplacements.push(l.relPath),g?.code==="EEXIST"&&s.replacementWarnings.push(`${l.relPath} appeared during install; not replaced`)}}}for(let l of r.refresh){let u=o(l.relPath),m=e.sourceSkillsDir?Ee(e.sourceSkillsDir,...l.source.split("/")):void 0;if(!(!m||!Ce(m)))try{if(!Pe(u).isFile()||!Re(n,u)||!l.previousSha256.includes(ut(lt(u))))continue;it(m,u),s.refreshed.push(l.relPath)}catch{}}}return s}Q();import{spawnSync as Ht}from"node:child_process";import*as ge from"node:os";import*as ft from"node:fs";var F="vibium@^26.8.21",gt={platform:()=>ge.platform(),arch:()=>ge.arch(),existsSync:c=>ft.existsSync(c)},mt=["/usr/bin/chromium","/usr/bin/chromium-browser","/usr/bin/google-chrome","/usr/bin/google-chrome-stable","/snap/bin/chromium"];function Ie(c=gt){if(c.platform()!=="linux"||c.arch()!=="arm64")return;let e=mt.find(t=>c.existsSync(t));return e?{code:"linux-arm64-system-chromium-found",browserPath:e,message:`Linux aarch64 detected. Vibium v26.3.x does not auto-download Chrome for Testing on ARM64. Found system browser at ${e}. Export VIBIUM_BROWSER_PATH=${e} before running vibium.`}:{code:"linux-arm64-no-system-chromium",message:`Linux aarch64 detected. Vibium v26.3.x does not auto-download Chrome for Testing on ARM64, and no system chromium was found on PATH (checked: ${mt.join(", ")}). Install via \`apt-get install chromium\` (or your distro's equivalent), then export VIBIUM_BROWSER_PATH=/usr/bin/chromium before running vibium.`}}function se(c,e,t,s){return c(e,t,{encoding:"utf8",timeout:s,maxBuffer:8*1024*1024})}var Ae=(c,e,t)=>Ht(c,e,t);function Gt(c=Ae,e=5e3){let t=se(c,"vibium",["--version"],e);if(t.status!==0)return null;let s=(t.stdout||"").trim(),n=(t.stderr||"").trim(),o=s||n;if(!o)return"unknown";let r=o.match(/v?(\d+\.\d+\.\d+(?:[-+][\w.]+)?)/);return r?r[1]:o.split(/\s+/)[0]||"unknown"}function re(c=Ae,e=5e3){let t=Gt(c,e);if(!t)return{status:"cli-missing"};let s=/^(\d+)\.(\d+)\.(\d+)(?:\+[\w.]+)?$/.exec(t);if(!s||Number(s[1])!==26||Number(s[2])<8||Number(s[2])===8&&Number(s[3])<21)return{status:"unsupported-version",version:t,message:`Vibium ${t} is unsupported; install ${F} for the browser.start() API`};let n=se(c,"vibium",["is-installed"],e);return n.status===0?{status:"ready",version:t}:{status:"payload-missing",version:t,message:n.stderr?.trim()||n.stdout?.trim()||S(n.error)||"Vibium Chrome/chromedriver payload is missing or incomplete"}}function ht(c={}){let e=c.packageSpec||F;if(c.skip)return{status:"skipped",packageSpec:e,message:"install skipped by options"};let t=c.spawner||Ae,s=c.platformProbe||gt,n=Ie(s),o=re(t);if(o.status==="ready")return{status:"already-installed",version:o.version,packageSpec:e,platformHint:n};let r=c.npmBin||"npm",i=se(t,r,["--version"],5e3);if(i.error||i.status!==0)return{status:"npm-unavailable",packageSpec:e,message:`npm is not available on PATH. Install Node.js + npm, then run \`npm install -g ${e}\`.`};let d=c.timeoutMs||18e4,p=se(t,r,["install","-g",e],d);if(p.status!==0)return{status:"install-failed",packageSpec:e,message:p.stderr?.trim()||p.stdout?.trim()||S(p.error)||"unknown npm install failure"};let l=re(t);if(l.status==="payload-missing"){let u=se(t,"vibium",["install"],d);if(u.status!==0)return{status:"install-failed",packageSpec:e,platformHint:n,message:`Browser payload installation failed: ${u.stderr?.trim()||u.stdout?.trim()||"vibium install failed"}. Run \`vibium install\` and verify with \`vibium is-installed\`.`};l=re(t)}if(l.status!=="ready"){let u=l.message?`: ${l.message}`:"";return{status:"install-failed",packageSpec:e,platformHint:n,message:`npm completed, but Vibium readiness verification failed (${l.status})${u}. Run \`npm install -g ${e}\`, then verify with \`vibium is-installed\`.`}}return{status:"installed",version:l.version,packageSpec:e,platformHint:n}}var oe=class extends k{name="assets";description="Install skills and agents";order=90;critical=!1;requiresPhases=["configuration"];async run(e){let t=e.config,{projectRoot:s,options:n}=e,o=this.detectVersionUpgrade(e),r=n.upgrade||t.skills.overwrite||n.autoMode&&o,i=0,d=0,p=0,l=0,u=0,m=0,y=0,g=0,b=0,E,B,R=[],he=[];if(n.upgrade?e.services.log(" Upgrade mode: overwriting existing files"):n.autoMode&&o&&e.services.log(" Version upgrade detected: updating skills and agents"),!n.noClaude&&t.skills.install){let h=await ve({projectRoot:s,installV2Skills:t.skills.installV2,installV3Skills:t.skills.installV3,overwrite:r}).install();i=h.installed.length,h.errors.length>0&&e.services.warn(`Skills warnings: ${h.errors.join(", ")}`)}if(!n.noClaude){let f=pt(s,{sourceSkillsDir:ve({projectRoot:s}).getSourceSkillsDir()});R=f.removed,he=f.kept.flatMap(h=>h.files);for(let h of f.removed)e.services.log(` Removed retired asset: ${h}`);for(let h of[...f.installed,...f.refreshed])e.services.log(` Updated skill file: ${h}`);for(let h of f.kept)e.services.warn(`Kept ${h.files.join(", ")}: ${h.why}. ${h.advice}.`);for(let h of f.replacementWarnings)e.services.warn(`Skill file kept: ${h}.`);f.missingReplacements.length>0&&e.services.warn(`Could not install ${f.missingReplacements.join(", ")}; run "aqe init --upgrade" to refresh the skills.`)}if(!n.noClaude){try{let h=await Ze({projectRoot:s,installQEAgents:!0,installSubagents:!0,overwrite:r}).install();d=h.installed.length,h.errors.length>0&&e.services.warn(`Agents warnings: ${h.errors.join(", ")}`)}catch(f){e.services.warn(`Agents install error: ${f instanceof Error?f.message:f}`)}Me(s)}let P;if(n.browserEngine===!0&&!n.minimal)try{let f=re();if(f.status==="ready")P={status:"already-installed",version:f.version,packageSpec:F,platformHint:Ie()},e.services.log(` Browser engine: vibium ${P.version} (already installed)`);else switch(e.services.log(" Browser engine: installing vibium via npm (this can take 1\u20133 minutes on first run; downloads Chrome for Testing)\u2026"),P=ht({skip:!1}),P.status){case"installed":e.services.log(` Browser engine: vibium ${P.version} installed`);break;case"skipped":e.services.log(" Browser engine: skipped");break;case"install-failed":e.services.warn(`Browser engine install failed (qe-browser skill will be unavailable until you run \`aqe init --browser-engine\`): ${P.message||"unknown"}`);break;case"npm-unavailable":e.services.warn("Browser engine: npm not on PATH \u2014 install Node.js + npm, then `aqe init --browser-engine` to enable qe-browser");break}P?.platformHint&&e.services.warn(` Browser engine platform hint: ${P.platformHint.message}`)}catch(f){let h=f instanceof Error?f.message:String(f);e.services.warn(`Browser engine install error: ${h}
|
|
132
216
|
qe-browser fleet skill will be unavailable until you run:
|
|
133
217
|
npm install -g ${F}
|
|
134
|
-
Then re-run \`aqe init --browser-engine\` to verify. The rest of the AQE install will continue.`)}else
|
|
218
|
+
Then re-run \`aqe init --browser-engine\` to verify. The rest of the AQE install will continue.`)}else P={status:"skipped",packageSpec:F,message:n.minimal?"minimal mode":"browser setup not requested; run aqe init --browser-engine"};if(n.withN8n){let h=await et({projectRoot:s,installAgents:!0,installSkills:!0,overwrite:r,n8nApiConfig:n.n8nApiConfig}).install();p=h.agentsInstalled.length,l=h.skillsInstalled.length,h.errors.length>0&&e.services.warn(`N8n warnings: ${h.errors.join(", ")}`)}let $e=n.autoMode&&A(_(s,"opencode.json"));if(n.withOpenCode||$e){let{createOpenCodeInstaller:f}=await import("./opencode-installer-YUJNXXWS.js"),a=await f({projectRoot:s,installAgents:!0,installSkills:!0,installTools:!1,overwrite:r,memoryBackend:n.memoryBackend==="memory"?"memory":void 0}).install();u=a.agentsInstalled.length,m=a.skillsInstalled.length,a.errors.length>0&&e.services.warn(`OpenCode warnings: ${a.errors.join(", ")}`)}e.services.log(` Skills: ${i}`),e.services.log(` Agents: ${d}`),n.withN8n&&(e.services.log(` N8n agents: ${p}`),e.services.log(` N8n skills: ${l}`)),(n.withOpenCode||$e)&&(e.services.log(` OpenCode agents: ${u}`),e.services.log(` OpenCode skills: ${m}`));let Pt=n.autoMode&&A(_(s,".kiro"));if(n.withKiro||Pt){let{createKiroInstaller:f}=await import("./kiro-installer-UKKPGPDC.js"),a=await f({projectRoot:s,installAgents:!0,installSkills:!0,installHooks:!0,installSteering:!0,overwrite:r,memoryBackend:n.memoryBackend==="memory"?"memory":void 0}).install();y=a.agentsInstalled.length,g=a.skillsInstalled.length,b=a.hooksInstalled.length,a.errors.length>0&&e.services.warn(`Kiro warnings: ${a.errors.join(", ")}`),e.services.log(` Kiro agents: ${y}`),e.services.log(` Kiro skills: ${g}`),e.services.log(` Kiro hooks: ${b}`),e.services.log(` Kiro steering: ${a.steeringInstalled.length}`),a.mcpConfigured&&e.services.log(" Kiro MCP: .kiro/settings/mcp.json")}let I=[];if(n.withCopilot||n.autoMode&&A(_(s,".vscode"))){let{createCopilotInstaller:f}=await import("./copilot-installer-Y3XC7BTT.js"),a=await f({projectRoot:s,overwrite:r,memoryBackend:n.memoryBackend==="memory"?"memory":void 0}).install();a.mcpConfigured&&I.push("copilot"),a.errors.length>0&&e.services.warn(`Copilot warnings: ${a.errors.join(", ")}`),a.mcpConfigured&&e.services.log(` Copilot MCP: ${a.configPath}`),a.rulesInstalled&&e.services.log(` Copilot rules: ${a.rulesPath}`)}if(n.withCursor||n.autoMode&&A(_(s,".cursor"))){let{createCursorInstaller:f}=await import("./cursor-installer-F4UYQHIN.js"),a=await f({projectRoot:s,overwrite:r,memoryBackend:n.memoryBackend==="memory"?"memory":void 0}).install();a.mcpConfigured&&I.push("cursor"),a.errors.length>0&&e.services.warn(`Cursor warnings: ${a.errors.join(", ")}`),a.mcpConfigured&&e.services.log(` Cursor MCP: ${a.configPath}`),a.rulesInstalled&&e.services.log(` Cursor rules: ${a.rulesPath}`)}if(n.withCline){let{createClineInstaller:f}=await import("./cline-installer-EPE7IOZE.js"),a=await f({projectRoot:s,overwrite:r,memoryBackend:n.memoryBackend==="memory"?"memory":void 0}).install();a.mcpConfigured&&I.push("cline"),a.errors.length>0&&e.services.warn(`Cline warnings: ${a.errors.join(", ")}`),a.mcpConfigured&&e.services.log(` Cline MCP: ${a.configPath}`),a.modeInstalled&&e.services.log(` Cline mode: ${a.modePath}`)}if(n.withKiloCode||n.autoMode&&A(_(s,".kilocode"))){let{createKiloCodeInstaller:f}=await import("./kilocode-installer-IJN7XKBH.js"),a=await f({projectRoot:s,overwrite:r,memoryBackend:n.memoryBackend==="memory"?"memory":void 0}).install();a.mcpConfigured&&I.push("kilocode"),a.errors.length>0&&e.services.warn(`Kilo Code warnings: ${a.errors.join(", ")}`),a.mcpConfigured&&e.services.log(` Kilo Code MCP: ${a.configPath}`),a.modeInstalled&&e.services.log(` Kilo Code mode: ${a.modePath}`)}if(n.withRooCode||n.autoMode&&A(_(s,".roo"))){let{createRooCodeInstaller:f}=await import("./roocode-installer-IZ2S7PH2.js"),a=await f({projectRoot:s,overwrite:r,memoryBackend:n.memoryBackend==="memory"?"memory":void 0}).install();a.mcpConfigured&&I.push("roocode"),a.errors.length>0&&e.services.warn(`Roo Code warnings: ${a.errors.join(", ")}`),a.mcpConfigured&&e.services.log(` Roo Code MCP: ${a.configPath}`),a.modeInstalled&&e.services.log(` Roo Code mode: ${a.modePath}`)}if(n.withCodex||n.autoMode&&A(_(s,".codex"))){let{createCodexInstaller:f}=await import("./codex-installer-633SM4LR.js"),a=await f({projectRoot:s,overwrite:r,installMcp:!n.noMcp,includeRuflo:n.withRuflo,guidancePolicy:n.codexGuidance,memoryBackend:n.memoryBackend==="memory"?"memory":void 0}).install();E={policy:a.guidancePolicy,ownedBytes:a.ownedGuidanceBytes},B={hooks:a.components.hooks,skills:a.components.skills},a.mcpConfigured&&I.push("codex"),a.errors.length>0&&e.services.warn(`Codex warnings: ${a.errors.join(", ")}`),a.mcpConfigured&&e.services.log(` Codex MCP: ${a.configPath}`),a.agentsMdInstalled&&e.services.log(` Codex AGENTS.md: ${a.agentsMdPath}`),a.hooksConfigured&&e.services.log(` Codex hooks: ${a.hooksPath}`),a.skillsInstalled>0&&e.services.log(` Codex skills: ${a.skillsInstalled} installed`),e.services.log(n.withRuflo?" Codex Ruflo integration: enabled":" Codex Ruflo integration: not installed (opt in with --with-ruflo)")}if(n.withWindsurf||n.autoMode&&A(_(s,".windsurf"))){let{createWindsurfInstaller:f}=await import("./windsurf-installer-ITPU2IYL.js"),a=await f({projectRoot:s,overwrite:r,memoryBackend:n.memoryBackend==="memory"?"memory":void 0}).install();a.mcpConfigured&&I.push("windsurf"),a.errors.length>0&&e.services.warn(`Windsurf warnings: ${a.errors.join(", ")}`),a.mcpConfigured&&e.services.log(` Windsurf MCP: ${a.configPath}`),a.rulesInstalled&&e.services.log(` Windsurf rules: ${a.rulesPath}`)}if(n.withContinueDev||n.autoMode&&A(_(s,".continue"))){let{createContinueDevInstaller:f}=await import("./continuedev-installer-QH42TKMS.js"),a=await f({projectRoot:s,overwrite:r,memoryBackend:n.memoryBackend==="memory"?"memory":void 0}).install();a.mcpConfigured&&I.push("continuedev"),a.errors.length>0&&e.services.warn(`Continue.dev warnings: ${a.errors.join(", ")}`),a.mcpConfigured&&e.services.log(` Continue.dev MCP: ${a.configPath}`),a.rulesInstalled&&e.services.log(` Continue.dev rules: ${a.rulesPath}`)}return I.length>0&&e.services.log(` Platforms configured: ${I.join(", ")}`),{skillsInstalled:i,agentsInstalled:d,n8nAgents:p,n8nSkills:l,openCodeAgents:u,openCodeSkills:m,kiroAgents:y,kiroSkills:g,kiroHooks:b,platformsConfigured:I,browserEngine:P,codexGuidance:E,codexComponents:B,retiredAssetsRemoved:R,retiredAssetsKept:he}}detectVersionUpgrade(e){let t=e.config.version,s=_(e.projectRoot,".agentic-qe","config.yaml");if(A(s))try{let i=Ut(s,"utf-8").match(/version:\s*"?([^"\n]+)"?/)?.[1];if(i===t)return!1;if(i!==void 0)return!0}catch{}let n=_(e.projectRoot,".claude","agents","v3");try{return A(n)&&Kt(n).some(o=>o.endsWith(".md")&&o.startsWith("qe-"))}catch{return!1}}};import{existsSync as zt,mkdirSync as Jt}from"fs";import{join as N,dirname as Yt}from"path";import{fileURLToPath as Xt}from"url";var Zt=Xt(import.meta.url),Bs=Yt(Zt),ie=class extends k{name="workers";description="Configure background workers";order=100;critical=!1;requiresPhases=["configuration"];async shouldRun(e){if(e.options.memoryBackend==="memory")return!1;let t=e.config;return t?.workers?.daemonAutoStart&&(t?.workers?.enabled?.length??0)>0}async run(e){let t=e.config,{projectRoot:s}=e;if(!t.workers.daemonAutoStart||t.workers.enabled.length===0)return{workersDir:"",workersConfigured:0,registryPath:"",daemonStarted:!1,daemonPid:null};let n=N(s,".agentic-qe","workers");zt(n)||Jt(n,{recursive:!0});let o={"learning-consolidation":18e5,"pattern-consolidator":18e5,"test-health":3e5,"coverage-tracker":6e5,"coverage-gap-scanner":6e5,"flaky-detector":9e5,"flaky-test-detector":9e5,"security-scan":18e5,"quality-gate":3e5,"compliance-checker":18e5,"defect-predictor":9e5,"regression-monitor":6e5,"routing-accuracy-monitor":9e5,"performance-baseline":36e5,"cloud-sync":3e5},r={};for(let y of t.workers.enabled)r[y]={name:y,enabled:!0,interval:t.workers.intervals[y]||o[y]||6e4,lastRun:null,status:"pending"};let i=N(n,"registry.json"),d={version:t.version,maxConcurrent:t.workers.maxConcurrent,workers:r,createdAt:new Date().toISOString(),daemonPid:null};W(i,d,[["createdAt"]]);for(let y of t.workers.enabled){let g=N(n,`${y}.json`),b={name:y,enabled:!0,interval:t.workers.intervals[y]||o[y]||6e4,projectRoot:s,dataDir:N(s,".agentic-qe","data"),createdAt:new Date().toISOString()};W(g,b,[["createdAt"]])}let p=N(n,"start-daemon.cjs");V(p,`#!/usr/bin/env node
|
|
135
219
|
// AQE v3 Worker Daemon Startup Script (cross-platform)
|
|
136
220
|
// Generated by aqe init
|
|
137
221
|
// Starts the MCP server with background workers enabled
|
|
@@ -325,7 +409,7 @@ setTimeout(() => {
|
|
|
325
409
|
console.log('Log file: ' + logFile);
|
|
326
410
|
console.log('To stop: node ' + join(workersDir, 'stop-daemon.cjs'));
|
|
327
411
|
}, 3000);
|
|
328
|
-
`);let u=N(n,"stop-daemon.cjs");return
|
|
412
|
+
`);let u=N(n,"stop-daemon.cjs");return V(u,`#!/usr/bin/env node
|
|
329
413
|
// AQE v3 Worker Daemon Stop Script (cross-platform)
|
|
330
414
|
// Generated by aqe init
|
|
331
415
|
|
|
@@ -348,7 +432,7 @@ try {
|
|
|
348
432
|
console.log('Daemon not running (stale PID file)');
|
|
349
433
|
try { unlinkSync(pidFile); } catch {}
|
|
350
434
|
}
|
|
351
|
-
`),e.services.log(` Workers dir: ${n}`),e.services.log(` Workers: ${t.workers.enabled.join(", ")}`),e.services.log(` Registry: ${i}`),{workersDir:n,workersConfigured:t.workers.enabled.length,registryPath:i,daemonStarted:!1,daemonPid:null}}};import{existsSync as en,readFileSync as tn,writeFileSync as _e}from"fs";import{join as yt}from"path";var ae=class extends
|
|
435
|
+
`),e.services.log(` Workers dir: ${n}`),e.services.log(` Workers: ${t.workers.enabled.join(", ")}`),e.services.log(` Registry: ${i}`),{workersDir:n,workersConfigured:t.workers.enabled.length,registryPath:i,daemonStarted:!1,daemonPid:null}}};import{existsSync as en,readFileSync as tn,writeFileSync as _e}from"fs";import{join as yt}from"path";var ae=class extends k{name="claude-md";description="Generate CLAUDE.md";order=110;critical=!1;requiresPhases=["configuration"];async shouldRun(e){return e.options.noClaude?(e.services.log(" CLAUDE.md skipped (--no-claude)"),!1):!0}async run(e){let t=e.config,{projectRoot:s}=e,n=yt(s,"CLAUDE.md"),o=this.generateContent(t),r=!1;if(en(n)){let i=tn(n,"utf-8");if(i.includes("## Agentic QE v3"))return e.services.log(" CLAUDE.md already has AQE section"),{generated:!1,path:n,backupCreated:!1};let d=yt(s,"CLAUDE.md.backup");_e(d,i,"utf-8"),r=!0,_e(n,i+`
|
|
352
436
|
|
|
353
437
|
`+o,"utf-8")}else _e(n,o,"utf-8");return e.services.log(` Path: ${n}`),r&&e.services.log(" Backup created"),{generated:!0,path:n,backupCreated:r}}generateContent(e){let t=e.domains.enabled.slice(0,6).join(", "),s=Math.max(0,e.domains.enabled.length-6);return`## Agentic QE v3
|
|
354
438
|
|
|
@@ -512,7 +596,7 @@ Task({ prompt: "Security audit", subagent_type: "qe-security-scanner", run_in_ba
|
|
|
512
596
|
|
|
513
597
|
---
|
|
514
598
|
*Generated by AQE v3 init - ${new Date().toISOString()}*
|
|
515
|
-
`}};import{existsSync as
|
|
599
|
+
`}};import{existsSync as $,readFileSync as nn}from"fs";import{join as L,dirname as sn}from"path";import{mkdirSync as kt}from"fs";ye();var rn=/^# \d{4}-\d{2}-\d{2}T[\d:.]+Z$/,xe=new Set(["__proto__","constructor","prototype"]),le=class extends k{name="verification";description="Verify installation";order=120;critical=!0;requiresPhases=["database","configuration"];async run(e){let t=e.config,{projectRoot:s}=e,n=[],o=e.options.memoryBackend==="memory",r=L(s,".agentic-qe","memory.db");n.push({name:o?"Database (in-memory mode)":"Database exists",passed:o||$(r)}),n.push({name:".agentic-qe directory",passed:$(L(s,".agentic-qe"))});let i=L(s,".agentic-qe","config.yaml");await this.saveConfig(t,s),n.push({name:"Config saved",passed:$(i)});let d=o?!0:await this.writeVersionToDb(t.version,s);n.push({name:"Version marker",passed:d});let p=["Database exists",".agentic-qe directory","Config saved"],l=n.filter(u=>p.includes(u.name)).every(u=>u.passed);e.services.log(" Verification checks:");for(let u of n){let m=p.includes(u.name),y=u.passed?"\u2713":m?"\u2717":"\u26A0",g=!m&&!u.passed?" (optional)":"";e.services.log(` ${y} ${u.name}${g}`)}return{verified:l,versionWritten:d,configSaved:$(i),checks:n}}async writeVersionToDb(e,t){let s=L(t,".agentic-qe","memory.db");try{let n=sn(s);$(n)||kt(n,{recursive:!0});let o=D(s);try{o.exec(`
|
|
516
600
|
CREATE TABLE IF NOT EXISTS kv_store (
|
|
517
601
|
key TEXT NOT NULL,
|
|
518
602
|
namespace TEXT NOT NULL,
|
|
@@ -527,9 +611,9 @@ Task({ prompt: "Security audit", subagent_type: "qe-security-scanner", run_in_ba
|
|
|
527
611
|
`).run("aqe_version",JSON.stringify(e),r),o.prepare(`
|
|
528
612
|
INSERT OR REPLACE INTO kv_store (key, namespace, value, created_at)
|
|
529
613
|
VALUES (?, '_system', ?, ?)
|
|
530
|
-
`).run("init_timestamp",JSON.stringify(new Date().toISOString()),r),o.close(),!0}catch{return o.close(),!1}}catch{return!1}}async saveConfig(e,t){let s=L(t,".agentic-qe")
|
|
531
|
-
`),n="",o="";for(let i of s){if(i.trim().startsWith("#")||i.trim()==="")continue;let d=i.match(/^(\w+):\s*(.*)$/);if(d){if(n=xe.has(d[1])?"":d[1],o="",!n)continue;let
|
|
532
|
-
`)}};Q();import{existsSync as
|
|
614
|
+
`).run("init_timestamp",JSON.stringify(new Date().toISOString()),r),o.close(),!0}catch{return o.close(),!1}}catch{return!1}}async saveConfig(e,t){let s=L(t,".agentic-qe");$(s)||kt(s,{recursive:!0});let n=L(s,"config.yaml");if($(n)){let r=this.loadExistingConfig(n);r&&(e=this.mergeConfigs(e,r))}let o=this.configToYAML(e);Le(n,o,rn)}loadExistingConfig(e){try{let t=nn(e,"utf-8");return this.parseYAML(t)}catch{return null}}parseYAML(e){try{let t={},s=e.split(`
|
|
615
|
+
`),n="",o="";for(let i of s){if(i.trim().startsWith("#")||i.trim()==="")continue;let d=i.match(/^(\w+):\s*(.*)$/);if(d){if(n=xe.has(d[1])?"":d[1],o="",!n)continue;let m=d[2].trim();m&&!m.startsWith('"')?t[n]=this.parseValue(m):m?t[n]=this.parseValue(m):t[n]={};continue}let p=i.match(/^ {2}(\w+):\s*(.*)$/);if(p&&n){if(o=xe.has(p[1])?"":p[1],!o)continue;let m=p[2].trim();(!Object.hasOwn(t,n)||!t[n])&&(t[n]={}),m?t[n][o]=this.parseValue(m):t[n][o]={};continue}let l=i.match(/^ {4}([\w-]+):\s*(.*)$/);if(l&&n&&o){let m=l[1],y=l[2].trim();if(xe.has(m))continue;let g=t[n];(!Object.hasOwn(g,o)||!g[o])&&(g[o]={}),typeof g[o]=="object"&&!Array.isArray(g[o])&&(g[o][m]=this.parseValue(y));continue}let u=i.match(/^ {4}- "?([^"]*)"?$/);if(u&&n&&o){let m=t[n];Array.isArray(m[o])||(m[o]=[]),m[o].push(u[1])}}let r=[["domains","enabled"],["domains","disabled"],["workers","enabled"]];for(let[i,d]of r){let p=t[i];p&&d in p&&!Array.isArray(p[d])&&(p[d]=[])}return t}catch{return null}}parseValue(e){return e==="true"?!0:e==="false"?!1:/^\d+$/.test(e)?parseInt(e,10):/^\d+\.\d+$/.test(e)?parseFloat(e):e.startsWith('"')&&e.endsWith('"')?e.slice(1,-1):e}mergeConfigs(e,t){if(t.domains?.enabled&&Array.isArray(t.domains.enabled)){let s=new Set(t.domains.enabled),n=new Set(e.domains.enabled);for(let r of n)s.add(r);let o=new Set(Array.isArray(t.domains?.disabled)?t.domains.disabled:[]);e.domains.enabled=Array.from(s).filter(r=>!o.has(r))}return t.domains?.disabled&&Array.isArray(t.domains.disabled)&&(e.domains.disabled=t.domains.disabled),t.learning?.enabled!==void 0&&(e.learning.enabled=t.learning.enabled),t.learning?.qualityThreshold!==void 0&&(e.learning.qualityThreshold=t.learning.qualityThreshold),t.learning?.promotionThreshold!==void 0&&(e.learning.promotionThreshold=t.learning.promotionThreshold),t.hooks?.claudeCode!==void 0&&(e.hooks.claudeCode=t.hooks.claudeCode),t.hooks?.preCommit!==void 0&&(e.hooks.preCommit=t.hooks.preCommit),t.hooks?.ciIntegration!==void 0&&(e.hooks.ciIntegration=t.hooks.ciIntegration),t.workers?.enabled&&Array.isArray(t.workers.enabled)&&(e.workers.enabled=t.workers.enabled),t.workers?.daemonAutoStart!==void 0&&(e.workers.daemonAutoStart=t.workers.daemonAutoStart),t.agents?.maxConcurrent!==void 0&&(e.agents.maxConcurrent=t.agents.maxConcurrent),t.agents?.defaultTimeout!==void 0&&(e.agents.defaultTimeout=t.agents.defaultTimeout),e}configToYAML(e){return["# Agentic QE v3 Configuration","# Generated by aqe init",`# ${new Date().toISOString()}`,"#",'# NOTE: Your customizations are PRESERVED when you run "aqe init" again.','# You do NOT need to re-run "aqe init" after editing this file - changes',"# take effect immediately. The following settings are merged on reinstall:","# - domains.enabled (custom domains like visual-accessibility)","# - domains.disabled","# - learning.enabled, qualityThreshold, and promotionThreshold","# - hooks.* preferences","# - workers.enabled","# - agents.maxConcurrent and defaultTimeout","",`version: "${e.version}"`,"","project:",` name: "${e.project.name}"`,` root: "${e.project.root}"`,` type: "${e.project.type}"`,"","learning:",` enabled: ${e.learning.enabled}`,` embeddingModel: "${e.learning.embeddingModel}"`," hnswConfig:",` M: ${e.learning.hnswConfig.M}`,` efConstruction: ${e.learning.hnswConfig.efConstruction}`,` efSearch: ${e.learning.hnswConfig.efSearch}`,` qualityThreshold: ${e.learning.qualityThreshold}`,` promotionThreshold: ${e.learning.promotionThreshold}`,` pretrainedPatterns: ${e.learning.pretrainedPatterns}`,"","routing:",` mode: "${e.routing.mode}"`,` confidenceThreshold: ${e.routing.confidenceThreshold}`,` feedbackEnabled: ${e.routing.feedbackEnabled}`,"","# ADR-092: Advisor Strategy \u2014 agents consult a stronger model for strategic guidance","# Set provider/model to override auto-detection from environment API keys","advisor:",' # provider: "openrouter" # openrouter | claude | ollama (auto-detected if not set)',' # model: "anthropic/claude-opus-5.5" # provider-specific model ID',' # maxUses: "3" # per-task advisor call cap',' redact: "strict" # strict | balanced | off',"","workers:"," enabled:",...e.workers.enabled.map(s=>` - "${s}"`)," intervals:",...Object.entries(e.workers.intervals).map(([s,n])=>` ${s}: ${n}`),` maxConcurrent: ${e.workers.maxConcurrent}`,` daemonAutoStart: ${e.workers.daemonAutoStart}`,"","hooks:",` claudeCode: ${e.hooks.claudeCode}`,` preCommit: ${e.hooks.preCommit}`,` ciIntegration: ${e.hooks.ciIntegration}`,"","skills:",` install: ${e.skills.install}`,` installV2: ${e.skills.installV2}`,` installV3: ${e.skills.installV3}`,` overwrite: ${e.skills.overwrite}`,"","domains:"," enabled:",...e.domains.enabled.map(s=>` - "${s}"`)," disabled:",...e.domains.disabled.map(s=>` - "${s}"`),"","agents:",` maxConcurrent: ${e.agents.maxConcurrent}`,` defaultTimeout: ${e.agents.defaultTimeout}`,""].join(`
|
|
616
|
+
`)}};Q();import{existsSync as q,mkdirSync as vt,readdirSync as bt,copyFileSync as wt}from"fs";import{join as C,dirname as on}from"path";import{fileURLToPath as an}from"url";var ln=an(import.meta.url),Ct=on(ln);function cn(){let c=[C(Ct,"../../assets/governance"),C(Ct,"../assets/governance")],e=Xe(import.meta.url);e&&(c.push(C(e,"assets/governance")),c.push(C(e,"dist/assets/governance"))),c.push(C(process.cwd(),"node_modules/agentic-qe/assets/governance")),c.push(C(process.cwd(),"assets/governance"));for(let t of c)if(q(t))return t;throw new Error(`Governance assets not found. Package may be corrupted. Searched: ${c.join(", ")}`)}var De=class{projectRoot;overwrite;skipShards;assetsPath;constructor(e){this.projectRoot=e.projectRoot,this.overwrite=e.overwrite??!1,this.skipShards=e.skipShards??!1,this.assetsPath=cn()}async install(){let e=[],t=[],s=[],n=C(this.projectRoot,".claude","guidance"),o=C(n,"shards");try{vt(n,{recursive:!0}),this.skipShards||vt(o,{recursive:!0})}catch(l){return s.push(`Failed to create governance directory: ${S(l)}`),{installed:e,skipped:t,errors:s,governanceDir:n,constitutionInstalled:!1,shardsInstalled:0}}let r=!1,i=C(this.assetsPath,"constitution.md"),d=C(n,"constitution.md");if(q(i))try{!q(d)||this.overwrite?(wt(i,d),e.push("constitution.md"),r=!0):t.push("constitution.md")}catch(l){s.push(`Failed to install constitution.md: ${S(l)}`)}else s.push("constitution.md not found in assets");let p=0;if(!this.skipShards){let l=C(this.assetsPath,"shards");if(q(l))try{let u=bt(l).filter(m=>m.endsWith(".shard.md"));for(let m of u){let y=C(l,m),g=C(o,m);try{!q(g)||this.overwrite?(wt(y,g),e.push(`shards/${m}`),p++):t.push(`shards/${m}`)}catch(b){s.push(`Failed to install ${m}: ${S(b)}`)}}}catch(u){s.push(`Failed to read shards directory: ${S(u)}`)}else s.push("Shards directory not found in assets")}return{installed:e,skipped:t,errors:s,governanceDir:n,constitutionInstalled:r,shardsInstalled:p}}isInstalled(){let e=C(this.projectRoot,".claude","guidance","constitution.md");return q(e)}getInstalledShards(){let e=C(this.projectRoot,".claude","guidance","shards");if(!q(e))return[];try{return bt(e).filter(t=>t.endsWith(".shard.md"))}catch{return[]}}};function Et(c){return new De(c)}var ce=class extends k{name="governance";description="Install governance configuration";order=95;critical=!1;requiresPhases=["configuration"];async shouldRun(e){return e.options.noClaude?(e.services.log(" Governance skipped (--no-claude)"),!1):e.options.noGovernance?(e.services.log(" Governance skipped (--no-governance flag)"),!1):e.options.minimal?(e.services.log(" Governance skipped (minimal mode)"),!1):!0}async run(e){let{projectRoot:t,options:s}=e,n=s.upgrade,o=Et({projectRoot:t,overwrite:n});if(o.isInstalled()&&!n){let i=o.getInstalledShards();return e.services.log(` Governance already installed (${i.length} shards)`),e.services.log(" Use --upgrade to overwrite existing files"),{filesInstalled:0,filesSkipped:1+i.length,constitutionInstalled:!1,shardsInstalled:0,governanceDir:`${t}/.claude/guidance`,skippedByFlag:!1}}let r=await o.install();if(r.errors.length>0)for(let i of r.errors)e.services.warn(` ${i}`);return e.services.log(` Constitution: ${r.constitutionInstalled?"installed":"skipped"}`),e.services.log(` Shards: ${r.shardsInstalled} installed, ${r.skipped.filter(i=>i.startsWith("shards/")).length} skipped`),r.installed.length>0&&(e.services.log(" Governance enabled (non-strict mode by default)"),e.services.log(" Set GOVERNANCE_STRICT_MODE=true for strict enforcement")),{filesInstalled:r.installed.length,filesSkipped:r.skipped.length,constitutionInstalled:r.constitutionInstalled,shardsInstalled:r.shardsInstalled,governanceDir:r.governanceDir,skippedByFlag:!1}}};var dn=new H,un=new G,pn=new U,mn=new J,fn=new Y,gn=new X,hn=new ee,yn=new te,kn=new oe,vn=new ie,bn=new ae,wn=new le,Cn=new ce;function St(){return[dn,un,pn,mn,fn,gn,hn,yn,kn,Cn,vn,bn,wn]}var Te=class{phases;context;constructor(e){this.context=this.createContext(e),this.phases=e.customPhases??St()}createContext(e){let t=e.withAllPlatforms;return{projectRoot:e.projectRoot,options:{autoMode:e.autoMode,upgrade:e.upgrade,skipPatterns:e.skipPatterns,skipCodeIndex:e.skipCodeIndex,minimal:e.minimal,browserEngine:e.browserEngine,withN8n:e.withN8n,withOpenCode:e.withOpenCode,withKiro:e.withKiro,withCopilot:e.withCopilot||t,withCursor:e.withCursor||t,withCline:e.withCline||t,withKiloCode:e.withKiloCode||t,withRooCode:e.withRooCode||t,withCodex:e.withCodex||t,withRuflo:e.withRuflo,codexGuidance:e.codexGuidance,withWindsurf:e.withWindsurf||t,withContinueDev:e.withContinueDev||t,withAllPlatforms:e.withAllPlatforms,n8nApiConfig:e.n8nApiConfig,wizardAnswers:e.wizardAnswers,noGovernance:e.noGovernance,noMcp:e.noMcp,withMcp:e.withMcp,noClaude:e.noClaude,noStatusLine:e.noStatusLine,memoryBackend:e.memoryBackend},config:{},enhancements:{claudeFlow:!1,ruvector:!1},results:new Map,services:{log:s=>console.log(s),warn:s=>console.warn(s),error:s=>console.error(s)}}}async initialize(){let e=Date.now(),t=[];try{let s=[...this.phases].sort((n,o)=>n.order-o.order);for(let n of s){if(!await n.shouldRun(this.context))continue;console.log(`
|
|
533
617
|
\u{1F4CB} ${n.description}...`);let r=await n.execute(this.context);if(this.context.results.set(n.name,r),t.push({step:n.description,status:r.success?"success":"error",message:r.message||"",durationMs:r.durationMs}),!r.success&&n.critical){if(console.error(`
|
|
534
|
-
\u274C Critical phase failed: ${n.name}`),n.rollback)try{await n.rollback(this.context)}catch(i){console.error(`Rollback failed: ${i}`)}return this.createFailureResult(t,e)}if(r.skipRemaining)break}return this.createSuccessResult(t,e)}catch(s){return t.push({step:"Initialization Failed",status:"error",message:
|
|
535
|
-
`)}export{
|
|
618
|
+
\u274C Critical phase failed: ${n.name}`),n.rollback)try{await n.rollback(this.context)}catch(i){console.error(`Rollback failed: ${i}`)}return this.createFailureResult(t,e)}if(r.skipRemaining)break}return this.createSuccessResult(t,e)}catch(s){return t.push({step:"Initialization Failed",status:"error",message:S(s),durationMs:0}),this.createFailureResult(t,e)}}createSuccessResult(e,t){let s=this.context.config,n=this.context.results.get("learning"),o=this.context.results.get("code-intelligence"),r=this.context.results.get("assets"),i=this.context.results.get("hooks"),d=this.context.results.get("mcp"),p=this.context.results.get("claude-md"),l=this.context.results.get("workers");return{success:!0,config:s||ke("unknown",this.context.projectRoot),steps:e,summary:{projectAnalyzed:this.context.results.has("analysis"),configGenerated:this.context.results.has("configuration"),codeIntelligenceIndexed:o?.data?.entries??0,patternsLoaded:n?.data?.patternsLoaded??0,skillsInstalled:r?.data?.skillsInstalled??0,agentsInstalled:r?.data?.agentsInstalled??0,hooksConfigured:i?.data?.configured??!1,mcpConfigured:d?.data?.configured??!1,claudeMdGenerated:p?.data?.generated??!1,workersStarted:l?.data?.workersConfigured??0,codexGuidance:r?.data?.codexGuidance,codexComponents:r?.data?.codexComponents,retiredAssetsRemoved:r?.data?.retiredAssetsRemoved,retiredAssetsKept:r?.data?.retiredAssetsKept},totalDurationMs:Date.now()-t,timestamp:new Date}}createFailureResult(e,t){return{success:!1,config:ke("unknown",this.context.projectRoot),steps:e,summary:{projectAnalyzed:!1,configGenerated:!1,codeIntelligenceIndexed:0,patternsLoaded:0,skillsInstalled:0,agentsInstalled:0,hooksConfigured:!1,mcpConfigured:!1,claudeMdGenerated:!1,workersStarted:0},totalDurationMs:Date.now()-t,timestamp:new Date}}getPhase(e){return this.phases.find(t=>t.name===e)}getPhases(){return[...this.phases]}getContext(){return this.context}};function En(c){return new Te(c)}async function Qr(c){return await En({projectRoot:c,autoMode:!0}).initialize()}function Vr(c){let e=[];e.push(""),e.push("\u250C\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2510"),e.push("\u2502 AQE v3 Initialization \u2502"),e.push("\u251C\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2524");for(let s of c.steps){let n=s.status==="success"?"\u2713":s.status==="error"?"\u2717":"\u25CB",o=s.step.substring(0,48).padEnd(48);e.push(`\u2502 ${n} ${o} ${String(s.durationMs).padStart(4)}ms \u2502`)}e.push("\u251C\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2524"),e.push(`\u2502 Project: ${c.config.project.name.substring(0,45).padEnd(45)} \u2502`),e.push(`\u2502 Type: ${c.config.project.type.padEnd(48)} \u2502`),e.push(`\u2502 Code Intel: ${String(c.summary.codeIntelligenceIndexed).padEnd(43)} \u2502`),e.push(`\u2502 Patterns: ${String(c.summary.patternsLoaded).padEnd(45)} \u2502`),e.push(`\u2502 Skills: ${String(c.summary.skillsInstalled).padEnd(47)} \u2502`),e.push(`\u2502 Agents: ${String(c.summary.agentsInstalled).padEnd(47)} \u2502`),e.push(`\u2502 Workers: ${String(c.summary.workersStarted).padEnd(46)} \u2502`),e.push(`\u2502 Hooks: ${c.summary.hooksConfigured?"Yes":"No".padEnd(48)} \u2502`),e.push(`\u2502 MCP: ${c.summary.mcpConfigured?"Yes":"No".padEnd(50)} \u2502`),e.push(`\u2502 CLAUDE.md: ${c.summary.claudeMdGenerated?"Yes":"No".padEnd(44)} \u2502`),e.push("\u251C\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2524");let t=c.success?"\u2713 AQE v3 initialized successfully":"\u2717 Initialization failed";return e.push(`\u2502 ${t.padEnd(57)} \u2502`),e.push("\u2514\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2518"),e.push(""),e.join(`
|
|
619
|
+
`)}export{Te as ModularInitOrchestrator,En as createModularInitOrchestrator,Vr as formatInitResultModular,Qr as quickInitModular};
|
|
@@ -0,0 +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.15.14");process.exit(0)}
|
|
2
|
+
import{a}from"./chunk-UMHFTQTR.js";import"./chunk-Z54G2YOL.js";import"./chunk-QP6GL3O5.js";import"./chunk-V6SE2ZU2.js";export{a as PatternNullStore};
|
package/dist/cli/chunks/{pattern-usage-recorder-LOPNCULT.js → pattern-usage-recorder-TPWPX32U.js}
RENAMED
|
@@ -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.15.
|
|
2
|
-
import{a,b}from"./chunk-
|
|
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.15.14");process.exit(0)}
|
|
2
|
+
import{a,b}from"./chunk-UNYTHZDZ.js";import"./chunk-V6SE2ZU2.js";export{a as recordPatternUsage,b as recordPatternUsageBatch};
|