agentic-qe 3.14.5 → 3.14.7
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/skills/skills-manifest.json +1 -1
- package/CHANGELOG.md +150 -0
- package/assets/skills/skills-manifest.json +1 -1
- package/dist/adapters/ag-ui/event-types.d.ts +1 -1
- package/dist/audit/witness-chain-hash.d.ts +18 -0
- package/dist/audit/witness-chain-hash.js +37 -0
- package/dist/audit/witness-chain-repair.d.ts +71 -0
- package/dist/audit/witness-chain-repair.js +203 -0
- package/dist/audit/witness-chain-verifier.d.ts +152 -0
- package/dist/audit/witness-chain-verifier.js +293 -0
- package/dist/audit/witness-chain.d.ts +10 -43
- package/dist/audit/witness-chain.js +16 -106
- package/dist/audit/witness-findings.js +4 -1
- package/dist/cli/bundle.js +8 -8
- package/dist/cli/chunks/adapter-TVQKH65T.js +2 -0
- package/dist/cli/chunks/agent-booster-wasm-AK2W76RG.js +2 -0
- package/dist/cli/chunks/{agent-handler-V6CZ7Q6S.js → agent-handler-MGZCWHIY.js} +2 -2
- package/dist/cli/chunks/{agent-memory-branch-ZMD6ULC3.js → agent-memory-branch-JZ54MCSP.js} +2 -2
- package/dist/cli/chunks/aqe-learning-engine-ULGTVVWE.js +2 -0
- package/dist/cli/chunks/{arena-QLSBESC7.js → arena-CUVH3V7H.js} +2 -2
- package/dist/cli/chunks/{arena-4UPAEHFT.js → arena-YSWTKBCL.js} +4 -4
- package/dist/cli/chunks/audit-LVU76QGA.js +4 -0
- package/dist/cli/chunks/base-W42BURDL.js +2 -0
- package/dist/cli/chunks/{better-sqlite3-4DSBPDRH.js → better-sqlite3-DB3LOJQU.js} +2 -2
- package/dist/cli/chunks/{brain-handler-GBY4EZ4P.js → brain-handler-SD63KOQ6.js} +3 -3
- package/dist/cli/chunks/{branch-enumerator-XYBVXCNO.js → branch-enumerator-4MNOPUC7.js} +2 -2
- package/dist/cli/chunks/{browser-32F6MREU.js → browser-OLPNTWQE.js} +2 -2
- package/dist/cli/chunks/browser-workflow-HKGHFFFT.js +2 -0
- package/dist/cli/chunks/{chunk-WLXK2KNU.js → chunk-23CX7JNL.js} +2 -2
- package/dist/cli/chunks/{chunk-O3JTQ7N4.js → chunk-25P6JA6V.js} +1 -1
- package/dist/cli/chunks/{chunk-DO6EI5KB.js → chunk-2G63VIJE.js} +1 -1
- package/dist/cli/chunks/{chunk-G3L5L6YQ.js → chunk-2IMSJ7IO.js} +1 -1
- package/dist/cli/chunks/{chunk-RD6TEZ64.js → chunk-36VKMAMN.js} +2 -2
- package/dist/cli/chunks/{chunk-KIP6WZGV.js → chunk-3M7J4U74.js} +3 -3
- package/dist/cli/chunks/chunk-3QJU4Q4R.js +5 -0
- package/dist/cli/chunks/{chunk-2JGEZHWY.js → chunk-4EKV7PHB.js} +2 -2
- package/dist/cli/chunks/chunk-4INST4ZL.js +4 -0
- package/dist/cli/chunks/{chunk-DPBRWP4J.js → chunk-53BXTTRO.js} +3 -3
- package/dist/cli/chunks/chunk-5D7ZFWDS.js +2 -0
- package/dist/cli/chunks/{chunk-XLAUGSW7.js → chunk-5FSLMYAC.js} +2 -2
- package/dist/cli/chunks/chunk-5GFKTJ65.js +4 -0
- package/dist/cli/chunks/{chunk-WOIGKU2N.js → chunk-5U6N4V5M.js} +11 -11
- package/dist/cli/chunks/{chunk-PSPKSUF6.js → chunk-6EGS77BB.js} +1 -1
- package/dist/cli/chunks/{chunk-QIRL6B3C.js → chunk-6PJPQGF4.js} +2 -2
- package/dist/cli/chunks/{chunk-I6X3EGJI.js → chunk-6RD44SCE.js} +1 -1
- package/dist/cli/chunks/{chunk-IGBEJ4UJ.js → chunk-74IOEOMH.js} +2 -2
- package/dist/cli/chunks/{chunk-E3W6XQ57.js → chunk-77QZHIVX.js} +2 -2
- package/dist/cli/chunks/{chunk-R74ZKREV.js → chunk-7EZ2Z2CK.js} +1 -1
- package/dist/cli/chunks/{chunk-UTBYJ4RF.js → chunk-7MIOK72I.js} +18 -35
- package/dist/cli/chunks/{chunk-URVHZPWY.js → chunk-7QYOTUOX.js} +2 -2
- package/dist/cli/chunks/{chunk-K27SU3RE.js → chunk-A2VUCUTT.js} +2 -2
- package/dist/cli/chunks/{chunk-2KJQ2UQE.js → chunk-A3DK3XNZ.js} +1 -1
- package/dist/cli/chunks/{chunk-5D36YHS3.js → chunk-A5MA7A23.js} +4 -4
- package/dist/cli/chunks/{chunk-WJHWH5D2.js → chunk-AEUEMVJK.js} +2 -2
- package/dist/cli/chunks/{chunk-6CR4VQBQ.js → chunk-AJUBT4NP.js} +2 -2
- package/dist/cli/chunks/chunk-B2YGVSOP.js +27 -0
- package/dist/cli/chunks/{chunk-D6OUCB2H.js → chunk-B4I43GE2.js} +2 -2
- package/dist/cli/chunks/{chunk-WK7B4B6Y.js → chunk-BD7FEUN3.js} +2 -2
- package/dist/cli/chunks/{chunk-OEIQTWQP.js → chunk-BE4KALTE.js} +1 -1
- package/dist/cli/chunks/{chunk-JROVR6YS.js → chunk-BEFTQVEW.js} +2 -2
- package/dist/cli/chunks/{chunk-HBCGYMQU.js → chunk-BLG7SH4A.js} +1 -1
- package/dist/cli/chunks/{chunk-2OMLTYQK.js → chunk-C3FXFU2T.js} +1 -1
- package/dist/cli/chunks/{chunk-6A44AOGN.js → chunk-CBONQM5D.js} +2 -2
- package/dist/cli/chunks/{chunk-73EI4C2E.js → chunk-CQNMGK6Y.js} +2 -2
- package/dist/cli/chunks/{chunk-IIAR5S7Q.js → chunk-CVOQ6ESD.js} +2 -2
- package/dist/cli/chunks/{chunk-6TU7FEMD.js → chunk-DOBKEXMJ.js} +1 -1
- package/dist/cli/chunks/{chunk-BHFR2EXL.js → chunk-DYTQHRUS.js} +1 -1
- package/dist/cli/chunks/{chunk-E4AZXCT5.js → chunk-EADSQN5T.js} +1 -1
- package/dist/cli/chunks/{chunk-CYE2TJFV.js → chunk-EGOIIUBD.js} +2 -2
- package/dist/cli/chunks/{chunk-DKUBQQFG.js → chunk-EIGRV3J6.js} +2 -2
- package/dist/cli/chunks/{chunk-RP2ZKPYV.js → chunk-EJ6MMYLK.js} +1 -1
- package/dist/cli/chunks/{chunk-HSVKZ5KI.js → chunk-ENK44A6Q.js} +2 -2
- package/dist/cli/chunks/{chunk-67YV75XP.js → chunk-EYXE2XKP.js} +2 -2
- package/dist/cli/chunks/{chunk-HYEJJJY3.js → chunk-F2OPFVQH.js} +1 -1
- package/dist/cli/chunks/{chunk-XUR2M2WB.js → chunk-FBZC4IGB.js} +2 -2
- package/dist/cli/chunks/{chunk-BXVAVFGU.js → chunk-FSSR6WBE.js} +2 -2
- package/dist/cli/chunks/{chunk-W2XCZU62.js → chunk-FW4DJ4FJ.js} +1 -1
- package/dist/cli/chunks/{chunk-KKHYJF5U.js → chunk-FYPX5WBJ.js} +1 -1
- package/dist/cli/chunks/{chunk-K7NJHFLZ.js → chunk-G367W7XR.js} +3 -3
- package/dist/cli/chunks/{chunk-IUDWEOLX.js → chunk-GLGKQX2V.js} +2 -2
- package/dist/cli/chunks/{chunk-JVQBWYHW.js → chunk-GV4DYPJP.js} +2 -2
- package/dist/cli/chunks/{chunk-GTKCGPJZ.js → chunk-GVVFTFMB.js} +2 -2
- package/dist/cli/chunks/{chunk-AFEDJ3RU.js → chunk-H5RQPO3X.js} +2 -2
- package/dist/cli/chunks/{chunk-4FWTLJEP.js → chunk-HPWWYT67.js} +2 -2
- package/dist/cli/chunks/{chunk-G3W6BMVJ.js → chunk-HXXHMLJ5.js} +1 -1
- package/dist/cli/chunks/{chunk-NU7UTXMP.js → chunk-HYFQUWNB.js} +2 -2
- package/dist/cli/chunks/chunk-HYOPJHHW.js +2 -0
- package/dist/cli/chunks/{chunk-6LKDHEBY.js → chunk-HZY42OVU.js} +2 -2
- package/dist/cli/chunks/{chunk-C3HQL6S4.js → chunk-IAENZ2DR.js} +2 -2
- package/dist/cli/chunks/{chunk-M23ZOZVY.js → chunk-IEJ7ZV3M.js} +1 -1
- package/dist/cli/chunks/{chunk-RIZVC4XY.js → chunk-IWFFO6VT.js} +2 -2
- package/dist/cli/chunks/chunk-J7AQZLIH.js +21 -0
- package/dist/cli/chunks/{chunk-3KDL6QDK.js → chunk-JHJUSSAU.js} +2 -2
- package/dist/cli/chunks/{chunk-DLF5BOJD.js → chunk-JOZ47MV6.js} +1 -1
- package/dist/cli/chunks/{chunk-ELBZON4V.js → chunk-JZT7BU44.js} +2 -2
- package/dist/cli/chunks/{chunk-3DDXWYMO.js → chunk-KD2BLA5Y.js} +1 -1
- package/dist/cli/chunks/{chunk-VD5IO5EO.js → chunk-KUHLTVWC.js} +1 -1
- package/dist/cli/chunks/{chunk-YDFL445W.js → chunk-LU2EDWQK.js} +2 -2
- package/dist/cli/chunks/chunk-LXZMP3VX.js +736 -0
- package/dist/cli/chunks/{chunk-3YUB5HER.js → chunk-LY7MFGBD.js} +196 -187
- package/dist/cli/chunks/chunk-MM56VPNE.js +180 -0
- package/dist/cli/chunks/{chunk-37TUN44F.js → chunk-MNQN7UZX.js} +2 -2
- package/dist/cli/chunks/{chunk-7DETTOPZ.js → chunk-MQZ53OR3.js} +2 -2
- package/dist/cli/chunks/{chunk-BYG36QC5.js → chunk-MT7UNBZ7.js} +2 -2
- package/dist/cli/chunks/{chunk-JES6R5KP.js → chunk-MZB2UV2O.js} +1 -1
- package/dist/cli/chunks/{chunk-QZMUXJHZ.js → chunk-MZMG6CUJ.js} +2 -2
- package/dist/cli/chunks/chunk-N5XOXPHZ.js +4 -0
- package/dist/cli/chunks/{chunk-RD2VGOUH.js → chunk-NBLDBVAW.js} +1 -1
- package/dist/cli/chunks/{chunk-HVU64GP5.js → chunk-ND4QTZOL.js} +2 -2
- package/dist/cli/chunks/{chunk-SQF6HRXR.js → chunk-NHUGHAY6.js} +1 -1
- package/dist/cli/chunks/{chunk-TUSSPKRM.js → chunk-NOHWJOBS.js} +1 -1
- package/dist/cli/chunks/{chunk-NVYBM3R4.js → chunk-O5V7RHVG.js} +2 -2
- package/dist/cli/chunks/{chunk-6VAZAHQG.js → chunk-O6MO5KMR.js} +2 -2
- package/dist/cli/chunks/{chunk-IUHB5GVS.js → chunk-OAZX6WFU.js} +2 -2
- package/dist/cli/chunks/{chunk-LSUILON7.js → chunk-OEPNNLR4.js} +1 -1
- package/dist/cli/chunks/{chunk-IJHCIXJC.js → chunk-OIDWDGLG.js} +2 -2
- package/dist/cli/chunks/{chunk-CPC7FN52.js → chunk-ON2UTP2U.js} +2 -2
- package/dist/cli/chunks/{chunk-UJWAWIRV.js → chunk-ONR2NXXD.js} +7 -7
- package/dist/cli/chunks/{chunk-7VFY7TUR.js → chunk-OXHF3L2T.js} +2 -2
- package/dist/cli/chunks/{chunk-QYOGD2VW.js → chunk-OZGIOKEA.js} +1 -1
- package/dist/cli/chunks/{chunk-WJTSY5MC.js → chunk-P2UPYSDJ.js} +1 -1
- package/dist/cli/chunks/{chunk-52L77RMG.js → chunk-P7XSPP5D.js} +2 -2
- package/dist/cli/chunks/{chunk-M5AEL7IS.js → chunk-PCJQCEBA.js} +2 -2
- package/dist/cli/chunks/chunk-PELENDDQ.js +2 -0
- package/dist/cli/chunks/{chunk-C3Z4VVHP.js → chunk-PYKY22GC.js} +5 -5
- package/dist/cli/chunks/{chunk-AF4XKLXO.js → chunk-Q3NSU24F.js} +2 -2
- package/dist/cli/chunks/chunk-Q6NTEICT.js +2 -0
- package/dist/cli/chunks/chunk-QFETNCNN.js +12 -0
- package/dist/cli/chunks/{chunk-KYA5LARK.js → chunk-QGOWNVVG.js} +1 -1
- package/dist/cli/chunks/{chunk-Y5L3ES4L.js → chunk-QPLSYEWJ.js} +2 -2
- package/dist/cli/chunks/{chunk-F34OAHOM.js → chunk-QQFQDEUE.js} +2 -2
- package/dist/cli/chunks/{chunk-EFV4ADMO.js → chunk-QUORH2MG.js} +55 -79
- package/dist/cli/chunks/{chunk-QWUXCG2L.js → chunk-QVH5Y7AP.js} +1 -1
- package/dist/cli/chunks/{chunk-I2NENQ44.js → chunk-RC2A4JZ5.js} +2 -2
- package/dist/cli/chunks/{chunk-XZSMZHM2.js → chunk-RDGPXENG.js} +2 -2
- package/dist/cli/chunks/{chunk-N7H767TP.js → chunk-RKI3IQKQ.js} +2 -2
- package/dist/cli/chunks/{chunk-LULD4JV2.js → chunk-RKUAWQOF.js} +2 -2
- package/dist/cli/chunks/chunk-RLW25X66.js +2 -0
- package/dist/cli/chunks/{chunk-UKGXWW64.js → chunk-ROVZSZCS.js} +3 -3
- package/dist/cli/chunks/{chunk-EOR2UT72.js → chunk-RT6O2HW2.js} +2 -2
- package/dist/cli/chunks/{chunk-75QJ5HWE.js → chunk-SM2YJ2AL.js} +2 -2
- package/dist/cli/chunks/{chunk-KO4FNAUR.js → chunk-SRPLERER.js} +3 -3
- package/dist/cli/chunks/{chunk-NRE4NAVA.js → chunk-T77GZF4B.js} +1 -1
- package/dist/cli/chunks/{chunk-R6IU3EWP.js → chunk-TFK2AYIN.js} +2 -2
- package/dist/cli/chunks/chunk-TW3SR4TS.js +2 -0
- package/dist/cli/chunks/{chunk-IYTLXUBO.js → chunk-TXSPBLBT.js} +2 -2
- package/dist/cli/chunks/chunk-UA7TDVL7.js +12 -0
- package/dist/cli/chunks/{chunk-WX6RRIGW.js → chunk-UBJG3IHT.js} +2 -2
- package/dist/cli/chunks/{chunk-NQI7FWCS.js → chunk-UFSVUBTR.js} +2 -2
- package/dist/cli/chunks/{chunk-FUNGTIF2.js → chunk-UOI6ULCH.js} +2 -2
- package/dist/cli/chunks/{chunk-HVXJC3OC.js → chunk-UYUJT6QO.js} +2 -2
- package/dist/cli/chunks/{chunk-KEY43ANX.js → chunk-V5AK56DA.js} +2 -2
- package/dist/cli/chunks/{chunk-XFPPERA2.js → chunk-V6RE4YRQ.js} +2 -2
- package/dist/cli/chunks/{chunk-DDCIYOGT.js → chunk-VW6FRMLW.js} +2 -2
- package/dist/cli/chunks/chunk-VXKWNRGA.js +2 -0
- package/dist/cli/chunks/{chunk-CVMNJSCB.js → chunk-VYDVI6FZ.js} +2 -2
- package/dist/cli/chunks/{chunk-7JZJJA7U.js → chunk-WF6UISKW.js} +3 -3
- package/dist/cli/chunks/{chunk-SQKW3B6B.js → chunk-WIH522AP.js} +1 -1
- package/dist/cli/chunks/{chunk-KLTP5IDB.js → chunk-WOV6XI3A.js} +1 -1
- package/dist/cli/chunks/{chunk-VTOVWHEM.js → chunk-X7ADKL7T.js} +2 -2
- package/dist/cli/chunks/{chunk-SX4JLSLV.js → chunk-XBYQ2BS4.js} +2 -2
- package/dist/cli/chunks/{chunk-E4EYPYR3.js → chunk-XL5KIYE3.js} +2 -2
- package/dist/cli/chunks/{chunk-3VIXOHMS.js → chunk-XWYELBZS.js} +1 -1
- package/dist/cli/chunks/{chunk-YQGPQBCX.js → chunk-XYLQZWF6.js} +2 -2
- package/dist/cli/chunks/{chunk-XEZIIQYJ.js → chunk-Y6AKKQIQ.js} +1 -1
- package/dist/cli/chunks/{chunk-BJPL6THQ.js → chunk-YMW57PEL.js} +1 -1
- package/dist/cli/chunks/{chunk-JSZ663MU.js → chunk-YO4ESCB4.js} +1 -1
- package/dist/cli/chunks/{chunk-AMMQOV35.js → chunk-YRHTQZU4.js} +2 -2
- package/dist/cli/chunks/chunk-Z4Q5PCRZ.js +65 -0
- package/dist/cli/chunks/{chunk-RKOUXVZZ.js → chunk-ZELWDJXT.js} +2 -2
- package/dist/cli/chunks/{chunk-QRCIZFNK.js → chunk-ZQZD55MN.js} +2 -2
- package/dist/cli/chunks/{chunk-UMGFMKDW.js → chunk-ZS4XVJGV.js} +2 -2
- package/dist/cli/chunks/{chunk-6ITZZIQX.js → chunk-ZUB5YOCM.js} +2 -2
- package/dist/cli/chunks/chunk-ZUOVNFXK.js +2 -0
- package/dist/cli/chunks/{chunk-RGGK6VZ7.js → chunk-ZWEKAEEV.js} +1 -1
- package/dist/cli/chunks/{ci-RACDAJMR.js → ci-J3TDK5RA.js} +8 -8
- package/dist/cli/chunks/{ci-output-EHRSZBKG.js → ci-output-RLS32FUY.js} +2 -2
- package/dist/cli/chunks/{circuit-breaker-GBV7M5XG.js → circuit-breaker-MRCC7WCM.js} +2 -2
- package/dist/cli/chunks/claude-flow-setup-LIZCEKDF.js +2 -0
- package/dist/cli/chunks/client-3BD2DI4N.js +2 -0
- package/dist/cli/chunks/{cline-installer-W4NMXJSG.js → cline-installer-T7H6R2RC.js} +2 -2
- package/dist/cli/chunks/{code-JWXJMYXB.js → code-XMBLI7OF.js} +3 -3
- package/dist/cli/chunks/{code-index-extractor-RVI2IFTM.js → code-index-extractor-QS7BYLEX.js} +2 -2
- package/dist/cli/chunks/{codex-installer-3BORJINH.js → codex-installer-6PGT5FM6.js} +6 -6
- package/dist/cli/chunks/{completions-A55NCTAO.js → completions-2A3WRXY2.js} +2 -2
- package/dist/cli/chunks/{complexity-analyzer-JCXHGGLY.js → complexity-analyzer-23HOOGJ7.js} +2 -2
- package/dist/cli/chunks/{continuedev-installer-PUVFMGYW.js → continuedev-installer-4FSF7B3N.js} +2 -2
- package/dist/cli/chunks/{copilot-installer-4DCMYWHB.js → copilot-installer-A5GRQQUU.js} +2 -2
- package/dist/cli/chunks/core-handlers-C3H2ZCS2.js +2 -0
- package/dist/cli/chunks/{cost-tracker-5TV2GGKY.js → cost-tracker-Z4STQ5VB.js} +2 -2
- package/dist/cli/chunks/{coverage-NNWM7TX3.js → coverage-NUPP6KZZ.js} +3 -3
- package/dist/cli/chunks/cross-domain-router-JCQ7SWDP.js +2 -0
- package/dist/cli/chunks/{cursor-installer-4NCHGJGK.js → cursor-installer-FVJ7ROPJ.js} +2 -2
- package/dist/cli/chunks/{daemon-QIKCXKWO.js → daemon-7ZZA2MMN.js} +4 -4
- package/dist/cli/chunks/{daemon-T4JO4IXP.js → daemon-D662EX5N.js} +3 -3
- package/dist/cli/chunks/{dag-attention-scheduler-RPAAIDAD.js → dag-attention-scheduler-IB4TQ2KA.js} +2 -2
- package/dist/cli/chunks/{detect-SBEEVDSN.js → detect-LGLBZN4I.js} +2 -2
- package/dist/cli/chunks/{dist-node-ZHI6NCSU.js → dist-node-Z3OL42YE.js} +2 -2
- package/dist/cli/chunks/{domain-handler-LBC3GJ7Z.js → domain-handler-L3CLNL7U.js} +2 -2
- package/dist/cli/chunks/{domain-plugins-H6IZ5USZ.js → domain-plugins-GQ3V5X6L.js} +2 -2
- package/dist/cli/chunks/domain-transfer-MFCI76IY.js +2 -0
- package/dist/cli/chunks/dream-FTP33IJB.js +2 -0
- package/dist/cli/chunks/{embed-and-insert-pattern-AHTR7CRU.js → embed-and-insert-pattern-UGD6USYH.js} +2 -2
- package/dist/cli/chunks/{eval-DZU2KISM.js → eval-3B7UIYGY.js} +2 -2
- package/dist/cli/chunks/{experience-capture-middleware-5IQCWKSL.js → experience-capture-middleware-3RQ4NYY3.js} +3 -3
- package/dist/cli/chunks/{fast-paths-2KLDUWCY.js → fast-paths-QOSAEPYD.js} +2 -2
- package/dist/cli/chunks/{feature-flags-7AC3XDZA.js → feature-flags-3S5TH6P4.js} +2 -2
- package/dist/cli/chunks/{feature-flags-N6UAEZY4.js → feature-flags-TLF4NKOH.js} +2 -2
- package/dist/cli/chunks/{file-discovery-5SDIW4V2.js → file-discovery-AEVMJRNB.js} +2 -2
- package/dist/cli/chunks/{fleet-ZIQCAZ2Y.js → fleet-E6WTXWFL.js} +3 -3
- package/dist/cli/chunks/{gnn-wrapper-DUMBZJEV.js → gnn-wrapper-MCKH3AUU.js} +2 -2
- package/dist/cli/chunks/{heartbeat-handler-6HVM6ZMR.js → heartbeat-handler-U7XENHRR.js} +4 -4
- package/dist/cli/chunks/heartbeat-scheduler-HXBJVJL2.js +2 -0
- package/dist/cli/chunks/hnsw-adapter-TU6WG2ME.js +2 -0
- package/dist/cli/chunks/hnsw-index-MS5KODD7.js +2 -0
- package/dist/cli/chunks/{hnsw-legacy-bridge-5DRL5FLX.js → hnsw-legacy-bridge-5GW4SAEI.js} +2 -2
- package/dist/cli/chunks/{hnswlib-node-GW67GTCL.js → hnswlib-node-7BLZBK5T.js} +2 -2
- package/dist/cli/chunks/{hooks-QHH6FVO4.js → hooks-F3O2SB6H.js} +10 -10
- package/dist/cli/chunks/hybrid-backend-HT45LBHC.js +2 -0
- package/dist/cli/chunks/{hypergraph-engine-7XDCCVG2.js → hypergraph-engine-PV4EKXHB.js} +2 -2
- package/dist/cli/chunks/{hypergraph-handler-QHF7NOU5.js → hypergraph-handler-VOWO5ZTW.js} +3 -3
- package/dist/cli/chunks/impact-analyzer-AP4AGTG5.js +2 -0
- package/dist/cli/chunks/{init-handler-5UIVOM7K.js → init-handler-ENJ5ONJX.js} +16 -14
- package/dist/cli/chunks/init-wizard-I5DFZUQL.js +2 -0
- package/dist/cli/chunks/kernel-MISPSPPA.js +2 -0
- package/dist/cli/chunks/{kilocode-installer-TGGV6K5Q.js → kilocode-installer-HNNJOOPE.js} +2 -2
- package/dist/cli/chunks/{kiro-installer-4XYBHZWW.js → kiro-installer-UZBIQ3IC.js} +2 -2
- package/dist/cli/chunks/knowledge-graph-L26JESGE.js +2 -0
- package/dist/cli/chunks/{learning-STE5W6BS.js → learning-YMLCVFUT.js} +3 -3
- package/dist/cli/chunks/{llm-router-NKF7J3RI.js → llm-router-YWTARCCT.js} +4 -4
- package/dist/cli/chunks/llm-router-service-MWGC43ZA.js +2 -0
- package/dist/cli/chunks/{load-B2T77UJQ.js → load-DKE3F3IP.js} +2 -2
- package/dist/cli/chunks/load-test-H5ISNNM5.js +2 -0
- package/dist/cli/chunks/mcp-5PSGIUCW.js +2 -0
- package/dist/cli/chunks/{memory-WRFZKG56.js → memory-3L3O6JMM.js} +5 -5
- package/dist/cli/chunks/memory-backend-HWDNOBKW.js +2 -0
- package/dist/cli/chunks/memory-handlers-ZFDVQZM5.js +2 -0
- package/dist/cli/chunks/multi-model-executor-AEEO7IA4.js +14 -0
- package/dist/cli/chunks/{opencode-installer-J36EMQU7.js → opencode-installer-ABBO355U.js} +2 -2
- package/dist/cli/chunks/orchestrator-E36Q7MKE.js +393 -0
- package/dist/cli/chunks/pattern-null-store-GQP6ICWK.js +2 -0
- package/dist/cli/chunks/{pattern-usage-recorder-BVMTWI3E.js → pattern-usage-recorder-H4XKSID4.js} +2 -2
- package/dist/cli/chunks/{pipeline-OWAHDUAQ.js → pipeline-BGFEHXIN.js} +2 -2
- package/dist/cli/chunks/{platform-ANGBFWBV.js → platform-GK7ZVDJI.js} +2 -2
- package/dist/cli/chunks/{plugin-OO7ON2YW.js → plugin-CAH2CKI6.js} +2 -2
- package/dist/cli/chunks/{prime-radiant-advanced-wasm-HFG3BXWU.js → prime-radiant-advanced-wasm-M5EYRONA.js} +2 -2
- package/dist/cli/chunks/{project-root-LNOYVTYY.js → project-root-BSNZC243.js} +2 -2
- package/dist/cli/chunks/protocol-executor-AD5A4DAI.js +2 -0
- package/dist/cli/chunks/{protocol-handler-CE3Q6LY4.js → protocol-handler-JDSSC2SF.js} +2 -2
- package/dist/cli/chunks/{prove-7XPN53PY.js → prove-ANPTOZJE.js} +2 -2
- package/dist/cli/chunks/qe-reasoning-bank-W3Z2PKTR.js +2 -0
- package/dist/cli/chunks/{quality-TT23JRFX.js → quality-SXWGYRQR.js} +2 -2
- package/dist/cli/chunks/{quality-gate-PPPRP255.js → quality-gate-GYNCA4ZY.js} +3 -3
- package/dist/cli/chunks/queen-coordinator-HQRHLIJX.js +2 -0
- package/dist/cli/chunks/{real-embeddings-EYNZIFJE.js → real-embeddings-WSRYAOZM.js} +2 -2
- package/dist/cli/chunks/{ref-validation-QQR64ZXD.js → ref-validation-AZ3LRWEK.js} +2 -2
- package/dist/cli/chunks/{roocode-installer-UIGS7ZJD.js → roocode-installer-2QKGFIEU.js} +2 -2
- package/dist/cli/chunks/router-MTP5LH4H.js +2 -0
- package/dist/cli/chunks/routing-feedback-GWETVB4L.js +2 -0
- package/dist/cli/chunks/{routing-handler-6AENUIRG.js → routing-handler-UYDC5MMD.js} +2 -2
- package/dist/cli/chunks/{ruvector-commands-5AWMEV34.js → ruvector-commands-QXADPVEY.js} +2 -2
- package/dist/cli/chunks/rvf-dual-writer-4UE5S7WP.js +2 -0
- package/dist/cli/chunks/rvf-migration-adapter-PHH3HF4Q.js +2 -0
- package/dist/cli/chunks/{rvf-migration-coordinator-NWRJ7C22.js → rvf-migration-coordinator-GD4NBFKT.js} +2 -2
- package/dist/cli/chunks/rvf-native-adapter-KTLZBUWV.js +2 -0
- package/dist/cli/chunks/{rvf-store-integrity-ISKRP563.js → rvf-store-integrity-7SXG66IL.js} +2 -2
- package/dist/cli/chunks/safe-db-FWWGAPVE.js +2 -0
- package/dist/cli/chunks/schedule-TPA4V4D5.js +2 -0
- package/dist/cli/chunks/scheduler-5ZTEPNDD.js +2 -0
- package/dist/cli/chunks/{security-325A7FMB.js → security-YKB622PK.js} +3 -3
- package/dist/cli/chunks/shared-rvf-adapter-KMLAV7JK.js +2 -0
- package/dist/cli/chunks/{shared-rvf-dual-writer-THFDYS2Z.js → shared-rvf-dual-writer-OYY27DFV.js} +2 -2
- package/dist/cli/chunks/sqlite-persistence-HPTT624C.js +2 -0
- package/dist/cli/chunks/{standalone-memory-UD4MJ6GZ.js → standalone-memory-2DOABVLC.js} +2 -2
- package/dist/cli/chunks/{status-handler-CPFTN4XL.js → status-handler-EXRKETV7.js} +2 -2
- package/dist/cli/chunks/{structural-health-2MG2IVBL.js → structural-health-2SKK6DU6.js} +2 -2
- package/dist/cli/chunks/sync-DQ2YUNI6.js +2 -0
- package/dist/cli/chunks/{sync-EE4VVKOW.js → sync-UW7SX7GO.js} +2 -2
- package/dist/cli/chunks/{task-handler-7H5OYJG4.js → task-handler-LYQ6WYUY.js} +2 -2
- package/dist/cli/chunks/task-handlers-DIJO232S.js +9 -0
- package/dist/cli/chunks/test-WRHZMUCW.js +33 -0
- package/dist/cli/chunks/{test-scheduling-CHQ4ZLLJ.js → test-scheduling-HI23RXFK.js} +3 -3
- package/dist/cli/chunks/token-bootstrap-23SA6SWZ.js +2 -0
- package/dist/cli/chunks/{token-usage-EBXUJNRB.js → token-usage-M7RRDPXO.js} +2 -2
- package/dist/cli/chunks/{transformers-ZEKS2OJZ.js → transformers-4TC35KKS.js} +2 -2
- package/dist/cli/chunks/tree-sitter-wasm-parser-F4LTKAWD.js +2 -0
- package/dist/cli/chunks/{types-KYAA5VLV.js → types-NBXV6LXQ.js} +2 -2
- package/dist/cli/chunks/unified-memory-OVFEPRPS.js +2 -0
- package/dist/cli/chunks/unified-memory-hnsw-KKRSCZHR.js +2 -0
- package/dist/cli/chunks/unified-persistence-7GLR4RI3.js +2 -0
- package/dist/cli/chunks/{upgrade-UJBJ5AYM.js → upgrade-4BGOU5RM.js} +2 -2
- package/dist/cli/chunks/{validate-RUV6YMWS.js → validate-EDWAR63H.js} +2 -2
- package/dist/cli/chunks/{validate-swarm-IVEVMGVM.js → validate-swarm-VI72CPR7.js} +2 -2
- package/dist/cli/chunks/visual-security-2FUM5GLI.js +2 -0
- package/dist/cli/chunks/{web-tree-sitter-AVWA6HKE.js → web-tree-sitter-Y5XBRQXF.js} +2 -2
- package/dist/cli/chunks/{windsurf-installer-DAH7HI2W.js → windsurf-installer-VEX23WAF.js} +2 -2
- package/dist/cli/chunks/witness-chain-3YNL6YGY.js +2 -0
- package/dist/cli/chunks/witness-chain-MH6GA5L6.js +2 -0
- package/dist/cli/chunks/witness-chain-repair-MJZGZRWT.js +2 -0
- package/dist/cli/chunks/witness-chain-verifier-TTJYXTBE.js +2 -0
- package/dist/cli/chunks/{witness-key-manager-JSTBMG43.js → witness-key-manager-EM6YXYOY.js} +2 -2
- package/dist/cli/chunks/{workflow-TWOIA6LZ.js → workflow-2RBDOM7V.js} +4 -4
- package/dist/cli/chunks/workflow-orchestrator-H6G65YKU.js +2 -0
- package/dist/cli/chunks/wrappers-5OTAVVOV.js +2 -0
- package/dist/cli/commands/audit.d.ts +20 -2
- package/dist/cli/commands/audit.js +158 -16
- package/dist/cli/commands/ci.js +1 -1
- package/dist/cli/commands/claude-flow-setup.js +5 -4
- package/dist/cli/commands/test.js +18 -3
- package/dist/cli/handlers/init-handler.d.ts +2 -0
- package/dist/cli/handlers/init-handler.js +8 -2
- package/dist/cli/index.js +10 -1
- package/dist/coordination/handlers/test-execution-handlers.js +13 -8
- package/dist/coordination/index.d.ts +1 -1
- package/dist/coordination/queen-event-handlers.js +9 -6
- package/dist/coordination/result-saver.js +1 -1
- package/dist/coordination/services/index.d.ts +1 -1
- package/dist/coordination/services/task-audit-logger.d.ts +38 -13
- package/dist/coordination/services/task-audit-logger.js +33 -5
- package/dist/coordination/task-executor.d.ts +5 -0
- package/dist/coordination/task-executor.js +10 -5
- package/dist/domains/test-generation/coordinator.js +6 -5
- package/dist/domains/test-generation/interfaces.d.ts +11 -1
- package/dist/domains/test-generation/services/behavior-example-validation.d.ts +36 -0
- package/dist/domains/test-generation/services/behavior-example-validation.js +89 -0
- package/dist/domains/test-generation/services/behavior-examples.d.ts +8 -0
- package/dist/domains/test-generation/services/behavior-examples.js +65 -0
- package/dist/domains/test-generation/services/test-generator.d.ts +1 -1
- package/dist/domains/test-generation/services/test-generator.js +59 -30
- package/dist/domains/visual-accessibility/services/axe-core-audit.d.ts +0 -15
- package/dist/domains/visual-accessibility/services/axe-core-audit.js +12 -10
- package/dist/init/agents-installer.d.ts +4 -0
- package/dist/init/agents-installer.js +24 -11
- package/dist/init/browser-engine-installer.d.ts +5 -5
- package/dist/init/browser-engine-installer.js +28 -6
- package/dist/init/codex-installer.js +4 -2
- package/dist/init/idempotent-write.d.ts +53 -0
- package/dist/init/idempotent-write.js +160 -0
- package/dist/init/init-wizard.d.ts +2 -0
- package/dist/init/orchestrator.js +1 -0
- package/dist/init/phases/05-learning.js +3 -1
- package/dist/init/phases/07-hooks.js +32 -16
- package/dist/init/phases/08-mcp.js +4 -2
- package/dist/init/phases/09-assets.js +8 -18
- package/dist/init/phases/10-workers.js +7 -5
- package/dist/init/phases/12-verification.js +7 -2
- package/dist/init/phases/phase-interface.d.ts +2 -0
- package/dist/init/project-analyzer.d.ts +9 -0
- package/dist/init/project-analyzer.js +20 -1
- package/dist/init/self-configurator.d.ts +5 -3
- package/dist/init/self-configurator.js +18 -29
- package/dist/init/skills-installer.js +4 -2
- package/dist/init/types.d.ts +6 -0
- package/dist/init/types.js +20 -24
- package/dist/integrations/agentic-flow/reasoning-bank/index.d.ts +2 -5
- package/dist/integrations/coherence/coherence-service.js +84 -24
- package/dist/integrations/coherence/vote-tally.d.ts +38 -0
- package/dist/integrations/coherence/vote-tally.js +39 -0
- package/dist/integrations/ruvector/shared-rvf-adapter.d.ts +23 -0
- package/dist/integrations/ruvector/shared-rvf-adapter.js +24 -0
- package/dist/integrations/vibium/client.d.ts +1 -0
- package/dist/integrations/vibium/client.js +24 -11
- package/dist/integrations/vibium/runtime.d.ts +14 -0
- package/dist/integrations/vibium/runtime.js +94 -0
- package/dist/kernel/kernel.js +3 -2
- package/dist/kernel/pattern-fts-self-heal.d.ts +63 -0
- package/dist/kernel/pattern-fts-self-heal.js +193 -0
- package/dist/kernel/process-lifecycle.d.ts +60 -0
- package/dist/kernel/process-lifecycle.js +91 -0
- package/dist/kernel/unified-memory-schemas.d.ts +15 -1
- package/dist/kernel/unified-memory-schemas.js +53 -25
- package/dist/kernel/unified-memory.js +31 -34
- package/dist/kernel/unified-persistence.js +12 -6
- package/dist/learning/experience-capture.d.ts +2 -1
- package/dist/learning/experience-capture.js +23 -8
- package/dist/learning/pattern-store.d.ts +12 -1
- package/dist/learning/pattern-store.js +45 -30
- package/dist/learning/qe-patterns.d.ts +12 -0
- package/dist/learning/qe-patterns.js +7 -1
- package/dist/learning/qe-reasoning-bank.d.ts +1 -0
- package/dist/learning/qe-reasoning-bank.js +17 -4
- package/dist/learning/real-qe-reasoning-bank.d.ts +9 -4
- package/dist/learning/real-qe-reasoning-bank.js +28 -4
- package/dist/learning/rvf-pattern-store.js +36 -23
- package/dist/learning/sqlite-persistence.d.ts +8 -1
- package/dist/learning/sqlite-persistence.js +58 -33
- package/dist/logging/console-logger.d.ts +2 -5
- package/dist/logging/console-logger.js +10 -46
- package/dist/logging/index.d.ts +2 -0
- package/dist/logging/index.js +1 -0
- package/dist/logging/redaction.d.ts +27 -0
- package/dist/logging/redaction.js +170 -0
- package/dist/mcp/bundle.js +522 -545
- package/dist/mcp/entry.js +52 -6
- package/dist/mcp/handlers/core-handlers.js +5 -4
- package/dist/mcp/handlers/domain-handler-configs.js +12 -4
- package/dist/mcp/handlers/task-handlers.js +11 -7
- package/dist/mcp/protocol-server.js +20 -4
- package/dist/mcp/services/reasoning-bank-service.d.ts +6 -1
- package/dist/mcp/services/reasoning-bank-service.js +5 -1
- package/dist/mcp/tools/base.d.ts +9 -2
- package/dist/mcp/tools/base.js +7 -0
- package/dist/mcp/tools/coherence/consensus.js +51 -2
- package/dist/mcp/tools/planning/goap-plan.d.ts +20 -7
- package/dist/mcp/tools/planning/goap-plan.js +92 -20
- package/dist/mcp/tools/planning/goap-status.d.ts +37 -12
- package/dist/mcp/tools/planning/goap-status.js +52 -23
- package/dist/mcp/tools/planning/world-state.d.ts +101 -0
- package/dist/mcp/tools/planning/world-state.js +274 -0
- package/dist/mcp/tools/test-execution/e2e-execute.js +9 -1
- package/dist/mcp/tools/test-generation/generate.d.ts +6 -1
- package/dist/mcp/tools/test-generation/generate.js +8 -0
- package/dist/mcp/types.d.ts +10 -4
- package/dist/planning/goap-planner.d.ts +60 -4
- package/dist/planning/goap-planner.js +218 -60
- package/dist/planning/index.d.ts +1 -1
- package/dist/planning/index.js +1 -1
- package/dist/planning/plan-executor.d.ts +20 -1
- package/dist/planning/plan-executor.js +209 -100
- package/dist/planning/types.d.ts +16 -0
- package/dist/planning/types.js +17 -0
- package/dist/shared/error-utils.d.ts +15 -0
- package/dist/shared/error-utils.js +21 -0
- package/dist/shared/events/domain-events.d.ts +2 -1
- package/package.json +10 -6
- package/dist/cli/chunks/adapter-IYC62SXA.js +0 -2
- package/dist/cli/chunks/agent-booster-wasm-EDNKP3SP.js +0 -2
- package/dist/cli/chunks/aqe-learning-engine-LLOU2IXD.js +0 -2
- package/dist/cli/chunks/audit-CVZQMF55.js +0 -3
- package/dist/cli/chunks/base-P3Z4IKCT.js +0 -2
- package/dist/cli/chunks/browser-workflow-YYHQQ25X.js +0 -2
- package/dist/cli/chunks/chunk-3EZ5DR2R.js +0 -21
- package/dist/cli/chunks/chunk-5WOSWNDN.js +0 -2
- package/dist/cli/chunks/chunk-7CD7PBHY.js +0 -3
- package/dist/cli/chunks/chunk-7X7JYWT4.js +0 -27
- package/dist/cli/chunks/chunk-CZO4BJG5.js +0 -2
- package/dist/cli/chunks/chunk-J27F4NSB.js +0 -2
- package/dist/cli/chunks/chunk-J5UNP6W3.js +0 -2
- package/dist/cli/chunks/chunk-MI5Q55DG.js +0 -65
- package/dist/cli/chunks/chunk-TY5WC3FT.js +0 -12
- package/dist/cli/chunks/chunk-UDHVCKGA.js +0 -5
- package/dist/cli/chunks/chunk-XQSIRBKT.js +0 -180
- package/dist/cli/chunks/chunk-YXP6BKGS.js +0 -730
- package/dist/cli/chunks/chunk-ZBABIZ2D.js +0 -2
- package/dist/cli/chunks/chunk-ZCWERUYB.js +0 -12
- package/dist/cli/chunks/claude-flow-setup-5LVJOFKP.js +0 -2
- package/dist/cli/chunks/client-HUVFA5PF.js +0 -2
- package/dist/cli/chunks/core-handlers-UEXO3VAA.js +0 -2
- package/dist/cli/chunks/cross-domain-router-ODU5IZD6.js +0 -2
- package/dist/cli/chunks/domain-transfer-JZA5TMW3.js +0 -2
- package/dist/cli/chunks/dream-HE3OX42F.js +0 -2
- package/dist/cli/chunks/heartbeat-scheduler-QUIFGGLX.js +0 -2
- package/dist/cli/chunks/hnsw-adapter-42KB37KP.js +0 -2
- package/dist/cli/chunks/hnsw-index-T2PGO77J.js +0 -2
- package/dist/cli/chunks/hybrid-backend-FRNWYRKH.js +0 -2
- package/dist/cli/chunks/impact-analyzer-A5QYOYBR.js +0 -2
- package/dist/cli/chunks/init-wizard-XBU674YH.js +0 -2
- package/dist/cli/chunks/kernel-DV5MTNZD.js +0 -2
- package/dist/cli/chunks/knowledge-graph-4ACGVJQK.js +0 -2
- package/dist/cli/chunks/llm-router-service-PSMASERT.js +0 -2
- package/dist/cli/chunks/load-test-MRUO2VPF.js +0 -2
- package/dist/cli/chunks/mcp-JGSFCEMH.js +0 -2
- package/dist/cli/chunks/memory-backend-2MPGI6JW.js +0 -2
- package/dist/cli/chunks/memory-handlers-XT4HMITB.js +0 -2
- package/dist/cli/chunks/multi-model-executor-26Q5BSVG.js +0 -14
- package/dist/cli/chunks/orchestrator-D5IFV65I.js +0 -393
- package/dist/cli/chunks/pattern-null-store-TGWUL237.js +0 -2
- package/dist/cli/chunks/protocol-executor-GEVH5KD6.js +0 -2
- package/dist/cli/chunks/qe-reasoning-bank-DJ2JL6QB.js +0 -2
- package/dist/cli/chunks/queen-coordinator-F7E3AS26.js +0 -2
- package/dist/cli/chunks/router-OZH3QSAU.js +0 -2
- package/dist/cli/chunks/routing-feedback-J2E3ADZB.js +0 -2
- package/dist/cli/chunks/rvf-dual-writer-HK525Y5Y.js +0 -2
- package/dist/cli/chunks/rvf-migration-adapter-Q7FB3BKR.js +0 -2
- package/dist/cli/chunks/rvf-native-adapter-5ZRCGUI6.js +0 -2
- package/dist/cli/chunks/safe-db-3OYEPVEH.js +0 -2
- package/dist/cli/chunks/schedule-AG4C2EIQ.js +0 -2
- package/dist/cli/chunks/scheduler-SQS2CZFZ.js +0 -2
- package/dist/cli/chunks/shared-rvf-adapter-NFL6QSZ6.js +0 -2
- package/dist/cli/chunks/sqlite-persistence-MAKDFSHC.js +0 -2
- package/dist/cli/chunks/sync-MBTW5XBF.js +0 -2
- package/dist/cli/chunks/task-handlers-NH4GJHCJ.js +0 -9
- package/dist/cli/chunks/test-MPHGT4T6.js +0 -33
- package/dist/cli/chunks/token-bootstrap-SSDCYEKK.js +0 -2
- package/dist/cli/chunks/tree-sitter-wasm-parser-J6ZMAK37.js +0 -2
- package/dist/cli/chunks/unified-memory-DDWMC435.js +0 -2
- package/dist/cli/chunks/unified-memory-hnsw-4JA7SGBK.js +0 -2
- package/dist/cli/chunks/unified-persistence-F6OSNTXY.js +0 -2
- package/dist/cli/chunks/vibium-HOGMFJ2Z.js +0 -2
- package/dist/cli/chunks/visual-security-25SMBIYT.js +0 -2
- package/dist/cli/chunks/witness-chain-PJOQPFUX.js +0 -2
- package/dist/cli/chunks/witness-chain-ZW6KKUZU.js +0 -2
- package/dist/cli/chunks/workflow-orchestrator-UKSIDM7Q.js +0 -2
- package/dist/cli/chunks/wrappers-UR7BLXKV.js +0 -2
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Idempotent file writers for `aqe init` (#778).
|
|
3
|
+
*
|
|
4
|
+
* A repeat `aqe init` on an unchanged project must be a byte-stable
|
|
5
|
+
* convergence step: files whose content would not change are left alone (no
|
|
6
|
+
* rewrite, so the mtime is preserved too), and volatile fields such as
|
|
7
|
+
* generation timestamps are carried over from the existing file unless
|
|
8
|
+
* something else in that file actually changed.
|
|
9
|
+
*/
|
|
10
|
+
import { copyFileSync, existsSync, readFileSync, writeFileSync } from 'fs';
|
|
11
|
+
import { safeJsonParse } from '../shared/safe-json.js';
|
|
12
|
+
/**
|
|
13
|
+
* Write `content` to `path` only when the bytes on disk differ.
|
|
14
|
+
* @returns true when the file was written.
|
|
15
|
+
*/
|
|
16
|
+
export function writeFileIfChanged(path, content) {
|
|
17
|
+
const next = typeof content === 'string' ? Buffer.from(content, 'utf-8') : content;
|
|
18
|
+
try {
|
|
19
|
+
if (existsSync(path) && readFileSync(path).equals(next))
|
|
20
|
+
return false;
|
|
21
|
+
}
|
|
22
|
+
catch {
|
|
23
|
+
// Unreadable target — fall through and (re)write it.
|
|
24
|
+
}
|
|
25
|
+
if (typeof content === 'string')
|
|
26
|
+
writeFileSync(path, content, 'utf-8');
|
|
27
|
+
else
|
|
28
|
+
writeFileSync(path, content);
|
|
29
|
+
return true;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Copy `src` to `dest` only when `dest` is missing or its bytes differ.
|
|
33
|
+
* Uses copyFileSync for the actual copy so file-mode semantics are unchanged.
|
|
34
|
+
* @returns true when the file was copied.
|
|
35
|
+
*/
|
|
36
|
+
export function copyFileIfChanged(src, dest) {
|
|
37
|
+
try {
|
|
38
|
+
if (existsSync(dest) && readFileSync(dest).equals(readFileSync(src)))
|
|
39
|
+
return false;
|
|
40
|
+
}
|
|
41
|
+
catch {
|
|
42
|
+
// Unreadable target — fall through and copy.
|
|
43
|
+
}
|
|
44
|
+
copyFileSync(src, dest);
|
|
45
|
+
return true;
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* Write a text file whose content embeds a volatile line (e.g. a generation
|
|
49
|
+
* timestamp). When the existing file matches `content` on every line except
|
|
50
|
+
* the lines matching `volatileLine`, the file is left untouched.
|
|
51
|
+
* @returns true when the file was written.
|
|
52
|
+
*/
|
|
53
|
+
export function writeTextIfChangedIgnoring(path, content, volatileLine) {
|
|
54
|
+
try {
|
|
55
|
+
if (existsSync(path)) {
|
|
56
|
+
const strip = (text) => text.split('\n').filter((line) => !volatileLine.test(line)).join('\n');
|
|
57
|
+
if (strip(readFileSync(path, 'utf-8')) === strip(content))
|
|
58
|
+
return false;
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
catch {
|
|
62
|
+
// Unreadable target — fall through and write.
|
|
63
|
+
}
|
|
64
|
+
writeFileSync(path, content, 'utf-8');
|
|
65
|
+
return true;
|
|
66
|
+
}
|
|
67
|
+
/** The `*Generated by AQE v3 init on <ISO>*` footer of generated index docs. */
|
|
68
|
+
export const GENERATED_ON_LINE = /^\*Generated by AQE v3 init on [^*]+\*$/;
|
|
69
|
+
function isPlainObject(value) {
|
|
70
|
+
return typeof value === 'object' && value !== null && !Array.isArray(value);
|
|
71
|
+
}
|
|
72
|
+
/** JSON serialization with object keys sorted, for order-insensitive comparison. */
|
|
73
|
+
export function canonicalJson(value) {
|
|
74
|
+
return JSON.stringify(value, (_key, v) => {
|
|
75
|
+
if (!isPlainObject(v))
|
|
76
|
+
return v;
|
|
77
|
+
const sorted = {};
|
|
78
|
+
for (const k of Object.keys(v).sort())
|
|
79
|
+
sorted[k] = v[k];
|
|
80
|
+
return sorted;
|
|
81
|
+
});
|
|
82
|
+
}
|
|
83
|
+
/** Deep structural equality of two JSON values, ignoring object key order. */
|
|
84
|
+
export function jsonEquivalent(a, b) {
|
|
85
|
+
return canonicalJson(a) === canonicalJson(b);
|
|
86
|
+
}
|
|
87
|
+
function getPath(obj, path) {
|
|
88
|
+
let cur = obj;
|
|
89
|
+
for (const key of path) {
|
|
90
|
+
if (!isPlainObject(cur))
|
|
91
|
+
return undefined;
|
|
92
|
+
cur = cur[key];
|
|
93
|
+
}
|
|
94
|
+
return cur;
|
|
95
|
+
}
|
|
96
|
+
function setPath(obj, path, value) {
|
|
97
|
+
let cur = obj;
|
|
98
|
+
for (const key of path.slice(0, -1)) {
|
|
99
|
+
if (!isPlainObject(cur[key]))
|
|
100
|
+
return;
|
|
101
|
+
cur = cur[key];
|
|
102
|
+
}
|
|
103
|
+
const last = path[path.length - 1];
|
|
104
|
+
if (last in cur)
|
|
105
|
+
cur[last] = value;
|
|
106
|
+
}
|
|
107
|
+
/**
|
|
108
|
+
* Carry volatile fields (timestamps) over from `previous` into `next` when
|
|
109
|
+
* `next` is otherwise identical to `previous`.
|
|
110
|
+
*
|
|
111
|
+
* - Unchanged (apart from the volatile fields): `next` is mutated to hold the
|
|
112
|
+
* previous values and `false` is returned — the caller should not write.
|
|
113
|
+
* - Changed, or no previous document: `next` keeps its fresh values and
|
|
114
|
+
* `true` is returned — the caller should write.
|
|
115
|
+
*/
|
|
116
|
+
export function stabilizeVolatileFields(previous, next, volatilePaths) {
|
|
117
|
+
if (!isPlainObject(previous))
|
|
118
|
+
return true;
|
|
119
|
+
const candidate = JSON.parse(JSON.stringify(next));
|
|
120
|
+
for (const path of volatilePaths) {
|
|
121
|
+
const prevValue = getPath(previous, path);
|
|
122
|
+
if (prevValue !== undefined && getPath(candidate, path) !== undefined) {
|
|
123
|
+
setPath(candidate, path, prevValue);
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
if (!jsonEquivalent(previous, candidate))
|
|
127
|
+
return true;
|
|
128
|
+
for (const path of volatilePaths) {
|
|
129
|
+
const prevValue = getPath(previous, path);
|
|
130
|
+
if (prevValue !== undefined && getPath(next, path) !== undefined)
|
|
131
|
+
setPath(next, path, prevValue);
|
|
132
|
+
}
|
|
133
|
+
return false;
|
|
134
|
+
}
|
|
135
|
+
/** Read and parse a JSON file, or return undefined when missing/unparseable. */
|
|
136
|
+
export function readJsonIfPresent(path) {
|
|
137
|
+
if (!existsSync(path))
|
|
138
|
+
return undefined;
|
|
139
|
+
try {
|
|
140
|
+
return safeJsonParse(readFileSync(path, 'utf-8'));
|
|
141
|
+
}
|
|
142
|
+
catch {
|
|
143
|
+
return undefined;
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
/**
|
|
147
|
+
* Write a generated JSON document (2-space indent) unless it is equivalent to
|
|
148
|
+
* the one already on disk, preserving the existing values of `volatilePaths`
|
|
149
|
+
* (e.g. `[['createdAt']]`) when nothing else changed.
|
|
150
|
+
* @returns true when the file was written.
|
|
151
|
+
*/
|
|
152
|
+
export function writeJsonIfChanged(path, doc, volatilePaths = []) {
|
|
153
|
+
const previous = readJsonIfPresent(path);
|
|
154
|
+
if (previous !== undefined && !stabilizeVolatileFields(previous, doc, volatilePaths)) {
|
|
155
|
+
return false;
|
|
156
|
+
}
|
|
157
|
+
writeFileSync(path, JSON.stringify(doc, null, 2), 'utf-8');
|
|
158
|
+
return true;
|
|
159
|
+
}
|
|
160
|
+
//# sourceMappingURL=idempotent-write.js.map
|
|
@@ -16,6 +16,8 @@ export interface InitOrchestratorOptions {
|
|
|
16
16
|
autoMode?: boolean;
|
|
17
17
|
/** Skip pattern loading */
|
|
18
18
|
skipPatterns?: boolean;
|
|
19
|
+
/** Explicitly install the optional browser engine and browser payload. */
|
|
20
|
+
browserEngine?: boolean;
|
|
19
21
|
/** Minimal configuration */
|
|
20
22
|
minimal?: boolean;
|
|
21
23
|
/** Pre-trained patterns library */
|
|
@@ -33,6 +33,7 @@ export class ModularInitOrchestrator {
|
|
|
33
33
|
skipPatterns: options.skipPatterns,
|
|
34
34
|
skipCodeIndex: options.skipCodeIndex,
|
|
35
35
|
minimal: options.minimal,
|
|
36
|
+
browserEngine: options.browserEngine,
|
|
36
37
|
withN8n: options.withN8n,
|
|
37
38
|
withOpenCode: options.withOpenCode,
|
|
38
39
|
withKiro: options.withKiro,
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
* Initializes the learning system with HNSW index and pattern storage
|
|
4
4
|
*/
|
|
5
5
|
import { existsSync, mkdirSync, writeFileSync } from 'fs';
|
|
6
|
+
import { writeJsonIfChanged } from '../idempotent-write.js';
|
|
6
7
|
import { join } from 'path';
|
|
7
8
|
import { BasePhase, } from './phase-interface.js';
|
|
8
9
|
import { getAQEVersion } from '../types.js';
|
|
@@ -54,7 +55,8 @@ export class LearningPhase extends BasePhase {
|
|
|
54
55
|
hnswIndexPath: join(hnswDir, 'index.bin'),
|
|
55
56
|
initialized: new Date().toISOString(),
|
|
56
57
|
};
|
|
57
|
-
|
|
58
|
+
// #778: leave an equivalent file (and its `initialized` stamp) untouched.
|
|
59
|
+
writeJsonIfChanged(learningConfigPath, learningConfig, [['initialized']]);
|
|
58
60
|
// Load pre-trained patterns if available and not skipped
|
|
59
61
|
let patternsLoaded = 0;
|
|
60
62
|
if (config.learning.pretrainedPatterns && !options.skipPatterns) {
|
|
@@ -14,7 +14,10 @@ import { safeJsonParse } from '../../shared/safe-json.js';
|
|
|
14
14
|
const __filename = fileURLToPath(import.meta.url);
|
|
15
15
|
const __dirname = dirname(__filename);
|
|
16
16
|
import { isAqeHookEntry, mergeHooksSmart, generateAqeEnvVars, generateV3SettingsSections, applyV3Sections, mergeAqeEnv, backupSettingsFile, } from '../settings-merge.js';
|
|
17
|
+
import { copyFileIfChanged, stabilizeVolatileFields } from '../idempotent-write.js';
|
|
17
18
|
import { BasePhase, } from './phase-interface.js';
|
|
19
|
+
/** settings.json fields that change on every run without a real change (#778). */
|
|
20
|
+
const SETTINGS_VOLATILE_FIELDS = [['aqe', 'initialized']];
|
|
18
21
|
/**
|
|
19
22
|
* Hooks phase - configures Claude Code hooks
|
|
20
23
|
*/
|
|
@@ -53,13 +56,16 @@ export class HooksPhase extends BasePhase {
|
|
|
53
56
|
if (!existsSync(hooksDir)) {
|
|
54
57
|
mkdirSync(hooksDir, { recursive: true });
|
|
55
58
|
}
|
|
56
|
-
// Load existing settings
|
|
59
|
+
// Load existing settings. `previousSettings` is an untouched parse used to
|
|
60
|
+
// decide whether this run changes anything (#778); `settings` is mutated.
|
|
57
61
|
const settingsPath = join(claudeDir, 'settings.json');
|
|
58
62
|
let settings = {};
|
|
63
|
+
let previousSettings;
|
|
59
64
|
if (existsSync(settingsPath)) {
|
|
60
65
|
try {
|
|
61
66
|
const content = readFileSync(settingsPath, 'utf-8');
|
|
62
67
|
settings = safeJsonParse(content);
|
|
68
|
+
previousSettings = safeJsonParse(content);
|
|
63
69
|
}
|
|
64
70
|
catch {
|
|
65
71
|
settings = {};
|
|
@@ -98,13 +104,23 @@ export class HooksPhase extends BasePhase {
|
|
|
98
104
|
existingMcp.push('agentic-qe');
|
|
99
105
|
}
|
|
100
106
|
settings.enabledMcpjsonServers = existingMcp;
|
|
101
|
-
//
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
107
|
+
// Converge instead of rewriting (#778): keep the original `aqe.initialized`
|
|
108
|
+
// stamp and skip the write (and the backup) entirely when the merged
|
|
109
|
+
// settings are equivalent to what is already on disk. Any real change —
|
|
110
|
+
// a version upgrade, a restored AQE hook, a new flag — still writes, and
|
|
111
|
+
// then records a fresh initialization timestamp.
|
|
112
|
+
const settingsChanged = stabilizeVolatileFields(previousSettings, settings, SETTINGS_VOLATILE_FIELDS);
|
|
113
|
+
if (settingsChanged) {
|
|
114
|
+
// Back up the pristine original settings.json before writing (like CLAUDE.md)
|
|
115
|
+
const backupPath = backupSettingsFile(settingsPath);
|
|
116
|
+
if (backupPath) {
|
|
117
|
+
context.services.log(` Backup created: ${backupPath}`);
|
|
118
|
+
}
|
|
119
|
+
writeFileSync(settingsPath, JSON.stringify(settings, null, 2), 'utf-8');
|
|
120
|
+
}
|
|
121
|
+
else {
|
|
122
|
+
context.services.log(' Settings unchanged — .claude/settings.json left as-is');
|
|
105
123
|
}
|
|
106
|
-
// Write settings
|
|
107
|
-
writeFileSync(settingsPath, JSON.stringify(settings, null, 2), 'utf-8');
|
|
108
124
|
// Write README and install hook assets (bridge script, cross-phase memory)
|
|
109
125
|
this.writeHooksReadme(hooksDir, hookTypes);
|
|
110
126
|
this.installHookAssets(hooksDir, context);
|
|
@@ -250,9 +266,9 @@ export class HooksPhase extends BasePhase {
|
|
|
250
266
|
];
|
|
251
267
|
for (const src of sourcePaths) {
|
|
252
268
|
if (existsSync(src) && src !== destPath) {
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
269
|
+
if (copyFileIfChanged(src, destPath)) {
|
|
270
|
+
context.services.log(' Installed brain-checkpoint.cjs (copied)');
|
|
271
|
+
}
|
|
256
272
|
return;
|
|
257
273
|
}
|
|
258
274
|
}
|
|
@@ -280,9 +296,9 @@ export class HooksPhase extends BasePhase {
|
|
|
280
296
|
];
|
|
281
297
|
for (const src of sourcePaths) {
|
|
282
298
|
if (existsSync(src) && src !== destPath) {
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
299
|
+
if (copyFileIfChanged(src, destPath)) {
|
|
300
|
+
context.services.log(' Installed statusline-v3.cjs (copied)');
|
|
301
|
+
}
|
|
286
302
|
return;
|
|
287
303
|
}
|
|
288
304
|
}
|
|
@@ -312,9 +328,9 @@ export class HooksPhase extends BasePhase {
|
|
|
312
328
|
];
|
|
313
329
|
for (const src of sourcePaths) {
|
|
314
330
|
if (existsSync(src) && src !== destPath) {
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
331
|
+
if (copyFileIfChanged(src, destPath)) {
|
|
332
|
+
context.services.log(' Installed aqe-hook.cjs (copied)');
|
|
333
|
+
}
|
|
318
334
|
return;
|
|
319
335
|
}
|
|
320
336
|
}
|
|
@@ -11,7 +11,8 @@
|
|
|
11
11
|
* walks up looking for .agentic-qe/, .git/, or package.json. This
|
|
12
12
|
* makes the config portable across machines, devcontainers, and CI.
|
|
13
13
|
*/
|
|
14
|
-
import { existsSync, readFileSync
|
|
14
|
+
import { existsSync, readFileSync } from 'fs';
|
|
15
|
+
import { writeFileIfChanged } from '../idempotent-write.js';
|
|
15
16
|
import { join } from 'path';
|
|
16
17
|
import { safeJsonParse } from '../../shared/safe-json.js';
|
|
17
18
|
import { BasePhase, } from './phase-interface.js';
|
|
@@ -85,7 +86,8 @@ export class MCPPhase extends BasePhase {
|
|
|
85
86
|
}
|
|
86
87
|
const rootServers = rootMcpConfig.mcpServers;
|
|
87
88
|
rootServers['agentic-qe'] = aqeServerConfig;
|
|
88
|
-
|
|
89
|
+
// #778: no rewrite (mtime churn) when the merged config is unchanged.
|
|
90
|
+
writeFileIfChanged(rootMcpPath, JSON.stringify(rootMcpConfig, null, 2));
|
|
89
91
|
context.services.log(` MCP config: ${rootMcpPath}`);
|
|
90
92
|
context.services.log(` Server: agentic-qe`);
|
|
91
93
|
if (dbFree) {
|
|
@@ -79,19 +79,9 @@ export class AssetsPhase extends BasePhase {
|
|
|
79
79
|
// Initialize overlay configs in agent registry for runtime use
|
|
80
80
|
initializeOverlays(projectRoot);
|
|
81
81
|
}
|
|
82
|
-
//
|
|
83
|
-
// Graceful — never fails init if Vibium cannot be installed.
|
|
84
|
-
// Skipped in --minimal mode per ADR-086 minimal-footprint guidance.
|
|
85
|
-
//
|
|
86
|
-
// H6 (devil's-advocate finding): the install can take up to 3 minutes
|
|
87
|
-
// on cold caches because npm downloads Vibium AND lazily downloads a
|
|
88
|
-
// Chrome for Testing binary. spawnSync blocks the event loop, so the
|
|
89
|
-
// user sees no output for the entire duration. We log a clear pre-spawn
|
|
90
|
-
// message so users don't Ctrl-C thinking init hung. Future work: move
|
|
91
|
-
// this to a lazy/on-first-use install path so non-browser users never
|
|
92
|
-
// pay the cost.
|
|
82
|
+
// Browser setup is explicitly requested; normal init never downloads a browser.
|
|
93
83
|
let browserEngine;
|
|
94
|
-
if (!options.minimal) {
|
|
84
|
+
if (options.browserEngine === true && !options.minimal) {
|
|
95
85
|
try {
|
|
96
86
|
// Pre-flight check: if vibium is already on PATH, skip the loud
|
|
97
87
|
// banner so we don't scare users on the common path.
|
|
@@ -108,7 +98,7 @@ export class AssetsPhase extends BasePhase {
|
|
|
108
98
|
else {
|
|
109
99
|
// Not installed → we're about to spawn `npm install -g vibium`
|
|
110
100
|
// which can take 1–3 minutes on a cold cache. Tell the user.
|
|
111
|
-
context.services.log(' Browser engine: installing vibium via npm (this can take 1–3 minutes on first run; downloads Chrome for Testing
|
|
101
|
+
context.services.log(' Browser engine: installing vibium via npm (this can take 1–3 minutes on first run; downloads Chrome for Testing)…');
|
|
112
102
|
browserEngine = installBrowserEngine({ skip: false });
|
|
113
103
|
switch (browserEngine.status) {
|
|
114
104
|
case 'installed':
|
|
@@ -118,10 +108,10 @@ export class AssetsPhase extends BasePhase {
|
|
|
118
108
|
context.services.log(' Browser engine: skipped');
|
|
119
109
|
break;
|
|
120
110
|
case 'install-failed':
|
|
121
|
-
context.services.warn(`Browser engine install failed (qe-browser skill will be unavailable until you run \`
|
|
111
|
+
context.services.warn(`Browser engine install failed (qe-browser skill will be unavailable until you run \`aqe init --browser-engine\`): ${browserEngine.message || 'unknown'}`);
|
|
122
112
|
break;
|
|
123
113
|
case 'npm-unavailable':
|
|
124
|
-
context.services.warn('Browser engine: npm not on PATH — install Node.js + npm, then `
|
|
114
|
+
context.services.warn('Browser engine: npm not on PATH — install Node.js + npm, then `aqe init --browser-engine` to enable qe-browser');
|
|
125
115
|
break;
|
|
126
116
|
// 'already-installed' handled by the pre-flight branch above
|
|
127
117
|
}
|
|
@@ -141,12 +131,12 @@ export class AssetsPhase extends BasePhase {
|
|
|
141
131
|
const msg = error instanceof Error ? error.message : String(error);
|
|
142
132
|
context.services.warn(`Browser engine install error: ${msg}\n` +
|
|
143
133
|
` qe-browser fleet skill will be unavailable until you run:\n` +
|
|
144
|
-
` npm install -g
|
|
145
|
-
` Then re-run \`aqe init\` to verify. The rest of the AQE install will continue.`);
|
|
134
|
+
` npm install -g ${DEFAULT_VIBIUM_SPEC}\n` +
|
|
135
|
+
` Then re-run \`aqe init --browser-engine\` to verify. The rest of the AQE install will continue.`);
|
|
146
136
|
}
|
|
147
137
|
}
|
|
148
138
|
else {
|
|
149
|
-
browserEngine = { status: 'skipped', packageSpec: DEFAULT_VIBIUM_SPEC, message: 'minimal mode' };
|
|
139
|
+
browserEngine = { status: 'skipped', packageSpec: DEFAULT_VIBIUM_SPEC, message: options.minimal ? 'minimal mode' : 'browser setup not requested; run aqe init --browser-engine' };
|
|
150
140
|
}
|
|
151
141
|
// Install n8n platform (optional)
|
|
152
142
|
if (options.withN8n) {
|
|
@@ -2,7 +2,8 @@
|
|
|
2
2
|
* Phase 10: Workers
|
|
3
3
|
* Configures background workers for continuous monitoring
|
|
4
4
|
*/
|
|
5
|
-
import { existsSync, mkdirSync
|
|
5
|
+
import { existsSync, mkdirSync } from 'fs';
|
|
6
|
+
import { writeFileIfChanged, writeJsonIfChanged } from '../idempotent-write.js';
|
|
6
7
|
import { join, dirname } from 'path';
|
|
7
8
|
import { fileURLToPath } from 'url';
|
|
8
9
|
import { BasePhase, } from './phase-interface.js';
|
|
@@ -86,7 +87,8 @@ export class WorkersPhase extends BasePhase {
|
|
|
86
87
|
createdAt: new Date().toISOString(),
|
|
87
88
|
daemonPid: null,
|
|
88
89
|
};
|
|
89
|
-
|
|
90
|
+
// #778: an unchanged registry keeps its bytes and original createdAt.
|
|
91
|
+
writeJsonIfChanged(registryPath, registryData, [['createdAt']]);
|
|
90
92
|
// Write individual worker configs
|
|
91
93
|
for (const workerName of config.workers.enabled) {
|
|
92
94
|
const workerConfigPath = join(workersDir, `${workerName}.json`);
|
|
@@ -98,7 +100,7 @@ export class WorkersPhase extends BasePhase {
|
|
|
98
100
|
dataDir: join(projectRoot, '.agentic-qe', 'data'),
|
|
99
101
|
createdAt: new Date().toISOString(),
|
|
100
102
|
};
|
|
101
|
-
|
|
103
|
+
writeJsonIfChanged(workerConfigPath, workerConfig, [['createdAt']]);
|
|
102
104
|
}
|
|
103
105
|
// Write cross-platform daemon startup script
|
|
104
106
|
const daemonScriptPath = join(workersDir, 'start-daemon.cjs');
|
|
@@ -178,7 +180,7 @@ console.log('AQE v3 Worker Daemon started (PID: ' + child.pid + ')');
|
|
|
178
180
|
console.log('Log file: ' + logFile);
|
|
179
181
|
console.log('To stop: node ' + join(workersDir, 'stop-daemon.cjs'));
|
|
180
182
|
`;
|
|
181
|
-
|
|
183
|
+
writeFileIfChanged(daemonScriptPath, daemonScript);
|
|
182
184
|
// Also write a cross-platform stop script
|
|
183
185
|
const stopScriptPath = join(workersDir, 'stop-daemon.cjs');
|
|
184
186
|
const stopScript = `#!/usr/bin/env node
|
|
@@ -205,7 +207,7 @@ try {
|
|
|
205
207
|
try { unlinkSync(pidFile); } catch {}
|
|
206
208
|
}
|
|
207
209
|
`;
|
|
208
|
-
|
|
210
|
+
writeFileIfChanged(stopScriptPath, stopScript);
|
|
209
211
|
context.services.log(` Workers dir: ${workersDir}`);
|
|
210
212
|
context.services.log(` Workers: ${config.workers.enabled.join(', ')}`);
|
|
211
213
|
context.services.log(` Registry: ${registryPath}`);
|
|
@@ -7,9 +7,12 @@
|
|
|
7
7
|
*/
|
|
8
8
|
import { existsSync, readFileSync } from 'fs';
|
|
9
9
|
import { join, dirname } from 'path';
|
|
10
|
-
import { mkdirSync
|
|
10
|
+
import { mkdirSync } from 'fs';
|
|
11
|
+
import { writeTextIfChangedIgnoring } from '../idempotent-write.js';
|
|
11
12
|
import { BasePhase, } from './phase-interface.js';
|
|
12
13
|
import { openDatabase } from '../../shared/safe-db.js';
|
|
14
|
+
/** The `# <ISO timestamp>` header line written by configToYAML(). */
|
|
15
|
+
const CONFIG_TIMESTAMP_LINE = /^# \d{4}-\d{2}-\d{2}T[\d:.]+Z$/;
|
|
13
16
|
/**
|
|
14
17
|
* Verification phase - verifies installation and writes markers
|
|
15
18
|
*/
|
|
@@ -135,7 +138,9 @@ export class VerificationPhase extends BasePhase {
|
|
|
135
138
|
}
|
|
136
139
|
}
|
|
137
140
|
const yaml = this.configToYAML(config);
|
|
138
|
-
|
|
141
|
+
// #778: the header carries a generation timestamp; ignore that line when
|
|
142
|
+
// deciding whether the file actually changed, so a repeat init is a no-op.
|
|
143
|
+
writeTextIfChangedIgnoring(configPath, yaml, CONFIG_TIMESTAMP_LINE);
|
|
139
144
|
}
|
|
140
145
|
/**
|
|
141
146
|
* Load existing config.yaml and parse it
|
|
@@ -92,6 +92,8 @@ export interface InitOptions {
|
|
|
92
92
|
*/
|
|
93
93
|
skipCodeIndex?: boolean;
|
|
94
94
|
/** Minimal configuration (no skills, patterns, workers) */
|
|
95
|
+
/** Explicitly install the optional browser engine and browser payload. */
|
|
96
|
+
browserEngine?: boolean;
|
|
95
97
|
minimal?: boolean;
|
|
96
98
|
/** Automatically migrate from v2 if detected */
|
|
97
99
|
/** Install n8n workflow testing platform */
|
|
@@ -5,6 +5,15 @@
|
|
|
5
5
|
* Analyzes a project to detect frameworks, languages, tests, and configuration.
|
|
6
6
|
*/
|
|
7
7
|
import type { ProjectAnalysis, DetectedFramework, DetectedLanguage, ExistingTests, CodeComplexity, CoverageMetrics } from './types.js';
|
|
8
|
+
/**
|
|
9
|
+
* Directories never scanned by the analyzer: build/vendor output plus the
|
|
10
|
+
* tool-generated trees that `aqe init` itself (and the agent platforms it
|
|
11
|
+
* configures) writes into the project. Scanning AQE's own installed skills,
|
|
12
|
+
* helpers and hook scripts made a repeat `aqe init` "see" a different project
|
|
13
|
+
* than the first run (new languages, tests, complexity) and silently change
|
|
14
|
+
* the generated configuration (#778).
|
|
15
|
+
*/
|
|
16
|
+
export declare const ANALYZER_EXCLUDED_DIRS: readonly string[];
|
|
8
17
|
export declare class ProjectAnalyzer {
|
|
9
18
|
private projectRoot;
|
|
10
19
|
constructor(projectRoot: string);
|
|
@@ -165,8 +165,27 @@ function getPackageVersion(root, packageName) {
|
|
|
165
165
|
return undefined;
|
|
166
166
|
return pkg.devDependencies?.[packageName] || pkg.dependencies?.[packageName];
|
|
167
167
|
}
|
|
168
|
+
/**
|
|
169
|
+
* Directories never scanned by the analyzer: build/vendor output plus the
|
|
170
|
+
* tool-generated trees that `aqe init` itself (and the agent platforms it
|
|
171
|
+
* configures) writes into the project. Scanning AQE's own installed skills,
|
|
172
|
+
* helpers and hook scripts made a repeat `aqe init` "see" a different project
|
|
173
|
+
* than the first run (new languages, tests, complexity) and silently change
|
|
174
|
+
* the generated configuration (#778).
|
|
175
|
+
*/
|
|
176
|
+
export const ANALYZER_EXCLUDED_DIRS = [
|
|
177
|
+
// build / vendor output
|
|
178
|
+
'node_modules', '.git', 'dist', 'build', 'coverage', '.next', '__pycache__',
|
|
179
|
+
// AQE-generated state and assets
|
|
180
|
+
'.agentic-qe', '.claude',
|
|
181
|
+
// agent-platform trees written by `aqe init --with-<platform>`
|
|
182
|
+
'.agents', '.codex', '.opencode', '.kiro', '.cursor', '.roo', '.kilocode',
|
|
183
|
+
'.windsurf', '.continue', '.clinerules',
|
|
184
|
+
// companion tooling state (claude-flow / ruflo)
|
|
185
|
+
'.swarm', '.claude-flow', '.hive-mind',
|
|
186
|
+
];
|
|
168
187
|
function walkDir(dir, callback, options = {}) {
|
|
169
|
-
const { maxDepth = 10, exclude =
|
|
188
|
+
const { maxDepth = 10, exclude = ANALYZER_EXCLUDED_DIRS } = options;
|
|
170
189
|
function walk(currentDir, depth) {
|
|
171
190
|
if (depth > maxDepth)
|
|
172
191
|
return;
|
|
@@ -56,9 +56,11 @@ export declare class SelfConfigurator {
|
|
|
56
56
|
/**
|
|
57
57
|
* Recommend enabled domains
|
|
58
58
|
*
|
|
59
|
-
* IMPORTANT: Always enable ALL
|
|
60
|
-
* Limiting domains causes "No factory
|
|
61
|
-
* when MCP tools try to use domains that
|
|
59
|
+
* IMPORTANT: Always enable ALL default domains (init's ALL_DOMAINS, derived
|
|
60
|
+
* from the canonical shared domain list). Limiting domains causes "No factory
|
|
61
|
+
* registered" errors in fleet_init when MCP tools try to use domains that
|
|
62
|
+
* aren't enabled. A hand-maintained copy here previously omitted
|
|
63
|
+
* enterprise-integration, so fresh and repeat inits disagreed (#778).
|
|
62
64
|
*
|
|
63
65
|
* Project analysis is used for prioritization and worker selection,
|
|
64
66
|
* but all domains remain available for users who need them.
|
|
@@ -51,7 +51,7 @@ const configurationRules = [
|
|
|
51
51
|
// Complex code needs more careful testing
|
|
52
52
|
config.autoTuning.parameters.push('complexity.analysisDepth');
|
|
53
53
|
// Enable all quality domains
|
|
54
|
-
config.domains.enabled = ALL_DOMAINS;
|
|
54
|
+
config.domains.enabled = [...ALL_DOMAINS];
|
|
55
55
|
},
|
|
56
56
|
},
|
|
57
57
|
// Low coverage rules
|
|
@@ -136,10 +136,11 @@ const configurationRules = [
|
|
|
136
136
|
// Focus on test generation - but keep ALL domains enabled
|
|
137
137
|
// Limiting domains causes "No factory registered" errors in fleet_init
|
|
138
138
|
config.workers.enabled = ['pattern-consolidator'];
|
|
139
|
-
// Don't override domains.enabled - keep
|
|
140
|
-
//
|
|
141
|
-
|
|
142
|
-
|
|
139
|
+
// Don't override domains.enabled - keep every default domain.
|
|
140
|
+
// Pattern-promotion thresholds are NOT lowered here: the learning
|
|
141
|
+
// runtime always enforces PROMOTION_THRESHOLD / PROMOTION_MIN_SUCCESS_RATE,
|
|
142
|
+
// so a per-project override only made the generated settings misreport
|
|
143
|
+
// the runtime and flip between fresh and repeat inits (#778).
|
|
143
144
|
},
|
|
144
145
|
},
|
|
145
146
|
// Many existing tests
|
|
@@ -222,7 +223,7 @@ export class SelfConfigurator {
|
|
|
222
223
|
* Recommend learning configuration
|
|
223
224
|
*/
|
|
224
225
|
recommendLearning(analysis) {
|
|
225
|
-
const config =
|
|
226
|
+
const config = structuredClone(DEFAULT_LEARNING_CONFIG);
|
|
226
227
|
// Adjust HNSW based on project size
|
|
227
228
|
if (analysis.codeComplexity.totalFiles > 1000) {
|
|
228
229
|
config.hnswConfig = {
|
|
@@ -248,7 +249,7 @@ export class SelfConfigurator {
|
|
|
248
249
|
* Recommend routing configuration
|
|
249
250
|
*/
|
|
250
251
|
recommendRouting(analysis) {
|
|
251
|
-
const config =
|
|
252
|
+
const config = structuredClone(DEFAULT_ROUTING_CONFIG);
|
|
252
253
|
// ML routing for complex projects, rules for simple
|
|
253
254
|
if (analysis.codeComplexity.recommendation === 'simple') {
|
|
254
255
|
config.mode = 'rules';
|
|
@@ -265,7 +266,7 @@ export class SelfConfigurator {
|
|
|
265
266
|
* Recommend workers configuration
|
|
266
267
|
*/
|
|
267
268
|
recommendWorkers(analysis) {
|
|
268
|
-
const config =
|
|
269
|
+
const config = structuredClone(DEFAULT_WORKERS_CONFIG);
|
|
269
270
|
// Always enable core workers
|
|
270
271
|
const workers = new Set(['pattern-consolidator', 'routing-accuracy-monitor']);
|
|
271
272
|
// Add coverage scanner if coverage is low or missing
|
|
@@ -290,7 +291,7 @@ export class SelfConfigurator {
|
|
|
290
291
|
* Recommend hooks configuration
|
|
291
292
|
*/
|
|
292
293
|
recommendHooks(analysis) {
|
|
293
|
-
const config =
|
|
294
|
+
const config = structuredClone(DEFAULT_HOOKS_CONFIG);
|
|
294
295
|
// Enable CI integration if CI is configured
|
|
295
296
|
config.ciIntegration = analysis.hasCIConfig;
|
|
296
297
|
// Enable pre-commit for projects with many tests
|
|
@@ -301,7 +302,7 @@ export class SelfConfigurator {
|
|
|
301
302
|
* Recommend skills configuration
|
|
302
303
|
*/
|
|
303
304
|
recommendSkills(analysis) {
|
|
304
|
-
const config =
|
|
305
|
+
const config = structuredClone(DEFAULT_SKILLS_CONFIG);
|
|
305
306
|
// Always install by default
|
|
306
307
|
config.install = true;
|
|
307
308
|
// Install v2 methodology skills - version-agnostic best practices
|
|
@@ -316,7 +317,7 @@ export class SelfConfigurator {
|
|
|
316
317
|
* Recommend auto-tuning configuration
|
|
317
318
|
*/
|
|
318
319
|
recommendAutoTuning(analysis) {
|
|
319
|
-
const config =
|
|
320
|
+
const config = structuredClone(DEFAULT_AUTO_TUNING_CONFIG);
|
|
320
321
|
// Disable auto-tuning for small projects
|
|
321
322
|
if (analysis.codeComplexity.totalFiles < 20) {
|
|
322
323
|
config.enabled = false;
|
|
@@ -326,30 +327,18 @@ export class SelfConfigurator {
|
|
|
326
327
|
/**
|
|
327
328
|
* Recommend enabled domains
|
|
328
329
|
*
|
|
329
|
-
* IMPORTANT: Always enable ALL
|
|
330
|
-
* Limiting domains causes "No factory
|
|
331
|
-
* when MCP tools try to use domains that
|
|
330
|
+
* IMPORTANT: Always enable ALL default domains (init's ALL_DOMAINS, derived
|
|
331
|
+
* from the canonical shared domain list). Limiting domains causes "No factory
|
|
332
|
+
* registered" errors in fleet_init when MCP tools try to use domains that
|
|
333
|
+
* aren't enabled. A hand-maintained copy here previously omitted
|
|
334
|
+
* enterprise-integration, so fresh and repeat inits disagreed (#778).
|
|
332
335
|
*
|
|
333
336
|
* Project analysis is used for prioritization and worker selection,
|
|
334
337
|
* but all domains remain available for users who need them.
|
|
335
338
|
*/
|
|
336
339
|
recommendDomains(_analysis) {
|
|
337
|
-
// All 12 DDD domains - always enabled to prevent fleet_init failures
|
|
338
340
|
// Users can disable domains manually in config.yaml if needed
|
|
339
|
-
return [
|
|
340
|
-
'test-generation',
|
|
341
|
-
'test-execution',
|
|
342
|
-
'coverage-analysis',
|
|
343
|
-
'quality-assessment',
|
|
344
|
-
'defect-intelligence',
|
|
345
|
-
'requirements-validation',
|
|
346
|
-
'code-intelligence',
|
|
347
|
-
'security-compliance',
|
|
348
|
-
'contract-testing',
|
|
349
|
-
'visual-accessibility',
|
|
350
|
-
'chaos-resilience',
|
|
351
|
-
'learning-optimization',
|
|
352
|
-
];
|
|
341
|
+
return [...ALL_DOMAINS];
|
|
353
342
|
}
|
|
354
343
|
/**
|
|
355
344
|
* Recommend max concurrent agents
|