agentic-qe 3.10.0 → 3.10.1
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 +72 -0
- package/README.md +35 -8
- package/dist/cli/bundle.js +5 -5
- package/dist/cli/chunks/adapter-3JS2CN7C.js +2 -0
- package/dist/cli/chunks/{agent-booster-wasm-5UDM2PWG.js → agent-booster-wasm-FZLWOPSX.js} +2 -2
- package/dist/cli/chunks/{agent-handler-JSYER5YC.js → agent-handler-KAGRVCKS.js} +2 -2
- package/dist/cli/chunks/{agent-memory-branch-T2SAHI4F.js → agent-memory-branch-JJKFEXQW.js} +2 -2
- package/dist/cli/chunks/aqe-learning-engine-Q4GFNGU6.js +2 -0
- package/dist/cli/chunks/{audit-HIBRVGXG.js → audit-DN5SY4JJ.js} +2 -2
- package/dist/cli/chunks/base-Q3MAL22Y.js +2 -0
- package/dist/cli/chunks/{hnswlib-node-TA4DZV62.js → better-sqlite3-XGPW4HK5.js} +2 -2
- package/dist/cli/chunks/{brain-handler-N6AWIMXG.js → brain-handler-O7MP5BGY.js} +3 -3
- package/dist/cli/chunks/{branch-enumerator-VYQGBVEJ.js → branch-enumerator-ZPTN5J6V.js} +2 -2
- package/dist/cli/chunks/{browser-2X4WKZPT.js → browser-PAZE2JSD.js} +2 -2
- package/dist/cli/chunks/browser-workflow-JX3M2UWG.js +2 -0
- package/dist/cli/chunks/{chunk-SGONA5GS.js → chunk-25QGPRWN.js} +2 -2
- package/dist/cli/chunks/{chunk-NT4PI5HI.js → chunk-2ETDES5W.js} +2 -2
- package/dist/cli/chunks/{chunk-UGX4EHT5.js → chunk-2KTRRSKD.js} +2 -2
- package/dist/cli/chunks/{chunk-UCIJCRPB.js → chunk-2S4XHK26.js} +2 -2
- package/dist/cli/chunks/{chunk-KNL3QWVA.js → chunk-2TDWCXZ6.js} +2 -2
- package/dist/cli/chunks/{chunk-HZPXOAFW.js → chunk-2UN4DOBJ.js} +2 -2
- package/dist/cli/chunks/{chunk-T7DLX3LS.js → chunk-32R7EA7B.js} +3 -3
- package/dist/cli/chunks/{chunk-CU4IUJ2K.js → chunk-3YOPJ7DY.js} +2 -2
- package/dist/cli/chunks/{chunk-55JPAF56.js → chunk-4AWJ5PE4.js} +1 -1
- package/dist/cli/chunks/{chunk-GPKZ4MMH.js → chunk-57NJQV57.js} +1 -1
- package/dist/cli/chunks/{chunk-G2HA2O3R.js → chunk-5EU2VQK3.js} +2 -2
- package/dist/cli/chunks/{chunk-BXCS55GB.js → chunk-5KFCH7RH.js} +1 -1
- package/dist/cli/chunks/{chunk-WC6KZDPM.js → chunk-5OTYBWRL.js} +2 -2
- package/dist/cli/chunks/{chunk-ALCQRJDY.js → chunk-5ZCVMR5E.js} +2 -2
- package/dist/cli/chunks/{chunk-FX4SYT6Y.js → chunk-622MIAOR.js} +3 -3
- package/dist/cli/chunks/{chunk-J5RJYFRM.js → chunk-6A2NIR2E.js} +2 -2
- package/dist/cli/chunks/{chunk-6F3WJOU2.js → chunk-6D57DWQ6.js} +2 -2
- package/dist/cli/chunks/{chunk-Z6JLPPAY.js → chunk-6E7GI2UB.js} +1 -1
- package/dist/cli/chunks/{chunk-M73IL7FA.js → chunk-6LRCMFLV.js} +2 -2
- package/dist/cli/chunks/{chunk-L4N6PTIC.js → chunk-6QFONVEE.js} +2 -2
- package/dist/cli/chunks/{chunk-6H5MRVJS.js → chunk-6VQ5MFJ6.js} +3 -3
- package/dist/cli/chunks/{chunk-JUICZG3T.js → chunk-6ZRMQXVL.js} +2 -2
- package/dist/cli/chunks/{chunk-RARSTEUO.js → chunk-7CKVAYP3.js} +1 -1
- package/dist/cli/chunks/{chunk-KDFW7MVM.js → chunk-7MSYTHZM.js} +2 -2
- package/dist/cli/chunks/{chunk-DY7IRNE2.js → chunk-7SQD2TTQ.js} +1 -1
- package/dist/cli/chunks/{chunk-IQNR662U.js → chunk-AABKTWXC.js} +2 -2
- package/dist/cli/chunks/{chunk-LYVFC7C7.js → chunk-AUVC3DDB.js} +2 -2
- package/dist/cli/chunks/{chunk-OWMGD7FO.js → chunk-BECU52UY.js} +3 -3
- package/dist/cli/chunks/chunk-BF7MUYWC.js +2 -0
- package/dist/cli/chunks/{chunk-BQT4J3BD.js → chunk-BGBSYF3K.js} +2 -2
- package/dist/cli/chunks/{chunk-TR7BZLB6.js → chunk-BN7ERYXI.js} +1 -1
- package/dist/cli/chunks/{chunk-DQJJS4AX.js → chunk-CKECJH2A.js} +2 -2
- package/dist/cli/chunks/{chunk-I4T4JPR2.js → chunk-COZDJLIL.js} +1 -1
- package/dist/cli/chunks/{chunk-URVDWF2Y.js → chunk-CR4ERDS2.js} +2 -2
- package/dist/cli/chunks/chunk-DMIYWPQQ.js +2 -0
- package/dist/cli/chunks/{chunk-Y4I5JBOL.js → chunk-DQIS6J77.js} +2 -2
- package/dist/cli/chunks/{chunk-7ZIRDBXH.js → chunk-DVOH75S4.js} +1 -1
- package/dist/cli/chunks/{chunk-Z2SCTEZD.js → chunk-EBQ6YKP2.js} +2 -2
- package/dist/cli/chunks/{chunk-2GL4GH52.js → chunk-ECPB7IAH.js} +4 -4
- package/dist/cli/chunks/{chunk-LQ3TA22E.js → chunk-EIROAH6N.js} +2 -2
- package/dist/cli/chunks/{chunk-UCXQQCIP.js → chunk-ELUERFGA.js} +2 -2
- package/dist/cli/chunks/{chunk-KOSKGZK4.js → chunk-ELZ67OHQ.js} +2 -2
- package/dist/cli/chunks/{chunk-WVCIZIKH.js → chunk-EO4B5GS4.js} +1 -1
- package/dist/cli/chunks/{chunk-HD6CZBZV.js → chunk-EUJHHXE6.js} +2 -2
- package/dist/cli/chunks/{chunk-KCHFF4IE.js → chunk-F3OVFA6W.js} +2 -2
- package/dist/cli/chunks/{chunk-7Y54QZKF.js → chunk-FJSR2U65.js} +2 -2
- package/dist/cli/chunks/{chunk-5QJDH4Z5.js → chunk-G3BQU3Q6.js} +2 -2
- package/dist/cli/chunks/{chunk-LDMG4372.js → chunk-G5DTENO3.js} +2 -2
- package/dist/cli/chunks/{chunk-JKVNZASH.js → chunk-GMKGLZJU.js} +2 -2
- package/dist/cli/chunks/{chunk-O3NAUNFC.js → chunk-GRG3OP34.js} +2 -2
- package/dist/cli/chunks/{chunk-3U77XX6J.js → chunk-GRYXNWPF.js} +4 -4
- package/dist/cli/chunks/{chunk-3QULDB7K.js → chunk-GTGONWGX.js} +1 -1
- package/dist/cli/chunks/{chunk-OGT45MZN.js → chunk-GTRXZJNX.js} +2 -2
- package/dist/cli/chunks/{chunk-TEJPHJMW.js → chunk-GXJ4BCGC.js} +2 -2
- package/dist/cli/chunks/{chunk-4NQ6KANC.js → chunk-H22MMMYY.js} +2 -2
- package/dist/cli/chunks/{chunk-VTIXFHZR.js → chunk-H44WD7QX.js} +2 -2
- package/dist/cli/chunks/{chunk-X4U5NYB6.js → chunk-HPNEZ7YN.js} +1 -1
- package/dist/cli/chunks/{chunk-FQ5FT7IE.js → chunk-HRDGN3OK.js} +1 -1
- package/dist/cli/chunks/{chunk-6HCHW5TS.js → chunk-IHDUWPFY.js} +2 -2
- package/dist/cli/chunks/{chunk-DQLEZBWV.js → chunk-IITKJCPK.js} +2 -2
- package/dist/cli/chunks/{chunk-VMJXNTJT.js → chunk-IJ4BUSJN.js} +4 -4
- package/dist/cli/chunks/{chunk-MJBXQXSX.js → chunk-IK6AJX3C.js} +1 -1
- package/dist/cli/chunks/{chunk-NLCUQMUR.js → chunk-IPRDHKSI.js} +2 -2
- package/dist/cli/chunks/{chunk-ZYZWBNKT.js → chunk-JLKHPIQF.js} +1 -1
- package/dist/cli/chunks/chunk-K22TPWOJ.js +3 -0
- package/dist/cli/chunks/{chunk-L3IFZ4IX.js → chunk-K4T3RDCB.js} +2 -2
- package/dist/cli/chunks/{chunk-XFUU2RCA.js → chunk-KCTH5MHE.js} +2 -2
- package/dist/cli/chunks/{chunk-L2AIES7X.js → chunk-KEC5FBAW.js} +1 -1
- package/dist/cli/chunks/{chunk-M4HDBRVJ.js → chunk-KKNBYXYA.js} +1 -1
- package/dist/cli/chunks/{chunk-5UOV7T36.js → chunk-KRXKU54J.js} +2 -2
- package/dist/cli/chunks/{provider-manager-HV55NIIO.js → chunk-KZJXVIAW.js} +13 -13
- package/dist/cli/chunks/{chunk-YHNEBCYQ.js → chunk-LF7URN2X.js} +2 -2
- package/dist/cli/chunks/{chunk-HD5NQDOL.js → chunk-MQYTW2IN.js} +2 -2
- package/dist/cli/chunks/{chunk-66GIKUI2.js → chunk-MVGVD6LS.js} +2 -2
- package/dist/cli/chunks/{chunk-M3M7HXDH.js → chunk-NDCPEXDN.js} +2 -2
- package/dist/cli/chunks/{chunk-RF6QKV7M.js → chunk-NOCYYXK4.js} +2 -2
- package/dist/cli/chunks/{chunk-U56TIYGP.js → chunk-NPSBMDVU.js} +2 -2
- package/dist/cli/chunks/{chunk-OUJJ34JH.js → chunk-NQZYUH6S.js} +1 -1
- package/dist/cli/chunks/{chunk-F363JJUI.js → chunk-NRLT44YB.js} +1 -1
- package/dist/cli/chunks/{chunk-27ACATRH.js → chunk-OC3OJWLB.js} +2 -2
- package/dist/cli/chunks/{chunk-XFMSHTXG.js → chunk-OQP5OFRR.js} +1 -1
- package/dist/cli/chunks/{chunk-RGONSQ44.js → chunk-OVENSL64.js} +210 -210
- package/dist/cli/chunks/{chunk-DXV6NRG3.js → chunk-P7T5Y735.js} +2 -2
- package/dist/cli/chunks/{chunk-QU54GUEA.js → chunk-PLRSKAFZ.js} +2 -2
- package/dist/cli/chunks/{chunk-NWHSEXHA.js → chunk-PUXDXIUE.js} +1 -1
- package/dist/cli/chunks/{chunk-RH3PHCJT.js → chunk-PW6MOFXG.js} +2 -2
- package/dist/cli/chunks/{chunk-3BO7EKGO.js → chunk-PXFQSVA2.js} +3 -3
- package/dist/cli/chunks/{chunk-UE3XXKLN.js → chunk-Q24OJX44.js} +2 -2
- package/dist/cli/chunks/{chunk-LXHA55EB.js → chunk-Q5VHBI4U.js} +1 -1
- package/dist/cli/chunks/{chunk-OKGK7DBT.js → chunk-QNW335PD.js} +2 -2
- package/dist/cli/chunks/{chunk-S4CNA6Z5.js → chunk-RPL6K623.js} +3 -3
- package/dist/cli/chunks/{chunk-FCSJ7GIZ.js → chunk-RRLQFFCO.js} +4 -4
- package/dist/cli/chunks/{chunk-W6U7SIIK.js → chunk-RWYW573C.js} +3 -3
- package/dist/cli/chunks/{chunk-BTIVIWIG.js → chunk-SLNGJW4G.js} +1 -1
- package/dist/cli/chunks/{chunk-P6XYFDXN.js → chunk-SQBB2DC6.js} +1 -1
- package/dist/cli/chunks/{chunk-SCYF5CQA.js → chunk-T3UXMPXX.js} +1 -1
- package/dist/cli/chunks/{chunk-C5QESAYA.js → chunk-TFNLXAK5.js} +1 -1
- package/dist/cli/chunks/{chunk-ZFBMBCKN.js → chunk-TL5F2S3Z.js} +2 -2
- package/dist/cli/chunks/{chunk-HIWBW4IQ.js → chunk-TNGGVMPQ.js} +1 -1
- package/dist/cli/chunks/{chunk-5RQT7EJP.js → chunk-TNVYKYTO.js} +3 -3
- package/dist/cli/chunks/{chunk-4WYGUTSF.js → chunk-TP77PNN6.js} +2 -2
- package/dist/cli/chunks/{chunk-WG6I7YF3.js → chunk-TX7SNQKL.js} +1 -1
- package/dist/cli/chunks/{chunk-WLLE54TA.js → chunk-UDFLR7GR.js} +1 -1
- package/dist/cli/chunks/{chunk-KYLJERZ3.js → chunk-UDVX34ZG.js} +2 -2
- package/dist/cli/chunks/{chunk-YYDHTBHE.js → chunk-UU2Q6XWF.js} +1 -1
- package/dist/cli/chunks/{chunk-JCKX2LEJ.js → chunk-VKRMVTWU.js} +49 -49
- package/dist/cli/chunks/{chunk-AFFYJSW2.js → chunk-VOIWDPIU.js} +2 -2
- package/dist/cli/chunks/chunk-VPCE5CIT.js +2 -0
- package/dist/cli/chunks/{chunk-4UUDFWOP.js → chunk-W2DT3CDE.js} +2 -2
- package/dist/cli/chunks/{chunk-VTO5O7DA.js → chunk-W6ZF2CPN.js} +1 -1
- package/dist/cli/chunks/{chunk-BQX5QDU5.js → chunk-WDTCCPK4.js} +1 -1
- package/dist/cli/chunks/{chunk-PNDO4W4L.js → chunk-WL2J6ECN.js} +2 -2
- package/dist/cli/chunks/chunk-WMG5F6R6.js +2 -0
- package/dist/cli/chunks/{chunk-QL3U5VSM.js → chunk-WO7KYT3X.js} +2 -2
- package/dist/cli/chunks/{chunk-S33246T4.js → chunk-WPNZSL4S.js} +1 -1
- package/dist/cli/chunks/{chunk-IBXNBLGM.js → chunk-WQEZKAUR.js} +2 -2
- package/dist/cli/chunks/{chunk-3OSCWD7Z.js → chunk-WS4XVJHI.js} +1 -1
- package/dist/cli/chunks/{chunk-GXCD7GNH.js → chunk-XGUQYVJR.js} +2 -2
- package/dist/cli/chunks/{chunk-I4E6CLC4.js → chunk-XKOKMS5A.js} +2 -2
- package/dist/cli/chunks/{chunk-ZCNVFULO.js → chunk-XRK7FBTY.js} +2 -2
- package/dist/cli/chunks/{chunk-FEBXP74Y.js → chunk-Y2DPXMOR.js} +1 -1
- package/dist/cli/chunks/{chunk-MF3XRML3.js → chunk-Y357YFLF.js} +2 -2
- package/dist/cli/chunks/{chunk-LRISVDVO.js → chunk-YGRTMAWB.js} +1 -1
- package/dist/cli/chunks/{chunk-VEOQH4W6.js → chunk-YPOTBXPU.js} +2 -2
- package/dist/cli/chunks/{chunk-2POXDKUB.js → chunk-YYWIA5FX.js} +1 -1
- package/dist/cli/chunks/{chunk-QWBO76AU.js → chunk-ZEMXMDD3.js} +2 -2
- package/dist/cli/chunks/{chunk-V5TRAL57.js → chunk-ZTMWJQTZ.js} +2 -2
- package/dist/cli/chunks/{ci-7TR4NQ5I.js → ci-EHRUN7O6.js} +2 -2
- package/dist/cli/chunks/{ci-output-SLTICF3O.js → ci-output-EXDXVXKB.js} +2 -2
- package/dist/cli/chunks/{circuit-breaker-7GVVTMBY.js → circuit-breaker-LM4QRAAL.js} +2 -2
- package/dist/cli/chunks/{claude-flow-setup-TYCWYEMM.js → claude-flow-setup-ZHUCZVW7.js} +2 -2
- package/dist/cli/chunks/client-PA3UJIHH.js +2 -0
- package/dist/cli/chunks/{cline-installer-ESIAJOLK.js → cline-installer-WMFLQOW2.js} +2 -2
- package/dist/cli/chunks/{code-I42JGOVI.js → code-L7KRLU5E.js} +2 -2
- package/dist/cli/chunks/{code-index-extractor-2CCXPCQW.js → code-index-extractor-FTMUYQC6.js} +2 -2
- package/dist/cli/chunks/{codex-installer-HEZRDNUT.js → codex-installer-B3F6WI3Z.js} +2 -2
- package/dist/cli/chunks/{completions-44HLIZGI.js → completions-3JZQRNB6.js} +2 -2
- package/dist/cli/chunks/{complexity-analyzer-SOCSFDVO.js → complexity-analyzer-LB2FFEKX.js} +2 -2
- package/dist/cli/chunks/{continuedev-installer-Q7O4HLIM.js → continuedev-installer-WH6IMV7R.js} +2 -2
- package/dist/cli/chunks/{copilot-installer-GIWCVLCS.js → copilot-installer-NOIEOFJM.js} +2 -2
- package/dist/cli/chunks/{cost-tracker-G7BONKEV.js → cost-tracker-IKX2VYSA.js} +2 -2
- package/dist/cli/chunks/{coverage-5TWVP7KY.js → coverage-TD37CYSY.js} +3 -3
- package/dist/cli/chunks/cross-domain-router-BVJRP2ZX.js +2 -0
- package/dist/cli/chunks/{cursor-installer-43EQZSB5.js → cursor-installer-4NSVGRM5.js} +2 -2
- package/dist/cli/chunks/{daemon-ZXHFRDKG.js → daemon-LYDV7NRW.js} +3 -3
- package/dist/cli/chunks/{daemon-QQZE4BU2.js → daemon-UWEBUIDT.js} +4 -4
- package/dist/cli/chunks/{dag-attention-scheduler-GOZAVAZQ.js → dag-attention-scheduler-NECJGCHC.js} +2 -2
- package/dist/cli/chunks/{detect-X777GVJ4.js → detect-4XGC7ILO.js} +2 -2
- package/dist/cli/chunks/{dist-node-EZZK46TB.js → dist-node-GGJDXRKJ.js} +2 -2
- package/dist/cli/chunks/{domain-handler-ZT32DKYY.js → domain-handler-UOFONAUT.js} +2 -2
- package/dist/cli/chunks/{domain-transfer-LHQVSLJW.js → domain-transfer-6JLNOYPA.js} +2 -2
- package/dist/cli/chunks/dream-BXZUEIW2.js +2 -0
- package/dist/cli/chunks/{embed-and-insert-pattern-XFYPPWG7.js → embed-and-insert-pattern-ZM75DQ4J.js} +2 -2
- package/dist/cli/chunks/{eval-V4NYJZUZ.js → eval-CYZJTHEB.js} +2 -2
- package/dist/cli/chunks/{experience-capture-middleware-HXX2W4GL.js → experience-capture-middleware-RBOJLDUB.js} +3 -3
- package/dist/cli/chunks/{fast-paths-RBPWQSFJ.js → fast-paths-S5BWZR3L.js} +2 -2
- package/dist/cli/chunks/{feature-flags-NX5EXRO3.js → feature-flags-6E7H3NYP.js} +2 -2
- package/dist/cli/chunks/{feature-flags-INJJZBMN.js → feature-flags-DUNQPDU3.js} +2 -2
- package/dist/cli/chunks/{file-discovery-SNFSG6NK.js → file-discovery-PFFKDGYG.js} +2 -2
- package/dist/cli/chunks/{fleet-6SDN4UWE.js → fleet-RCDZZFXN.js} +3 -3
- package/dist/cli/chunks/{gnn-wrapper-2JDRTDDK.js → gnn-wrapper-5AG3WDWF.js} +2 -2
- package/dist/cli/chunks/{heartbeat-handler-QLK6E7KA.js → heartbeat-handler-O2KAEX4Y.js} +4 -4
- package/dist/cli/chunks/heartbeat-scheduler-LEKAWFJF.js +2 -0
- package/dist/cli/chunks/hnsw-adapter-2TCEG5M2.js +2 -0
- package/dist/cli/chunks/hnsw-index-VDPUTEES.js +2 -0
- package/dist/cli/chunks/{hnsw-legacy-bridge-Q2ZEZQKB.js → hnsw-legacy-bridge-C7FG6YGW.js} +2 -2
- package/dist/cli/chunks/{better-sqlite3-Y6GX6CGB.js → hnswlib-node-YX6OOBN6.js} +2 -2
- package/dist/cli/chunks/{hooks-D4YENHO2.js → hooks-FUHNE2P7.js} +10 -10
- package/dist/cli/chunks/hybrid-router-2EMDIYIG.js +2 -0
- package/dist/cli/chunks/{hypergraph-engine-G72U446M.js → hypergraph-engine-LQRYBNPV.js} +2 -2
- package/dist/cli/chunks/{hypergraph-handler-TRZ5FDRH.js → hypergraph-handler-AFFNLZVD.js} +3 -3
- package/dist/cli/chunks/impact-analyzer-HFD6CPWC.js +2 -0
- package/dist/cli/chunks/{init-handler-3ZD4GCT4.js → init-handler-BQ6IDBX4.js} +6 -6
- package/dist/cli/chunks/init-wizard-552QIVRC.js +2 -0
- package/dist/cli/chunks/kernel-5DN6O6EE.js +2 -0
- package/dist/cli/chunks/{kilocode-installer-AXSIW3XW.js → kilocode-installer-KS72HUSG.js} +2 -2
- package/dist/cli/chunks/{kiro-installer-JQGIFWBK.js → kiro-installer-2ZEFLGRX.js} +2 -2
- package/dist/cli/chunks/knowledge-graph-76Y77MB6.js +2 -0
- package/dist/cli/chunks/{learning-SPO7TGWX.js → learning-GGHGJ6B6.js} +3 -3
- package/dist/cli/chunks/llm-router-LP6K5BJF.js +36 -0
- package/dist/cli/chunks/llm-router-service-4O6GCEFH.js +2 -0
- package/dist/cli/chunks/{load-XIDDK64U.js → load-2MLKXOT2.js} +2 -2
- package/dist/cli/chunks/load-test-FCI2IWRJ.js +2 -0
- package/dist/cli/chunks/{mcp-3JXRGXO4.js → mcp-CDJBJG5H.js} +2 -2
- package/dist/cli/chunks/{memory-A66KRS2P.js → memory-4LAX7JZS.js} +5 -5
- package/dist/cli/chunks/memory-backend-MKNCBNDE.js +2 -0
- package/dist/cli/chunks/memory-handlers-OBAFR4WV.js +2 -0
- package/dist/cli/chunks/{multi-model-executor-XCDGUVCE.js → multi-model-executor-SLJV73HE.js} +2 -2
- package/dist/cli/chunks/{opencode-installer-GELXWLF2.js → opencode-installer-M76SONWV.js} +2 -2
- package/dist/cli/chunks/{orchestrator-CCS3K6NH.js → orchestrator-TJPUDJMP.js} +5 -5
- package/dist/cli/chunks/{pipeline-Z5C72H5S.js → pipeline-2PVNFT6J.js} +2 -2
- package/dist/cli/chunks/{platform-4AK7XJ3Y.js → platform-KCSEDKEE.js} +2 -2
- package/dist/cli/chunks/{plugin-7RYBIZI7.js → plugin-QX47QF5U.js} +2 -2
- package/dist/cli/chunks/{prime-radiant-advanced-wasm-E5PARKRX.js → prime-radiant-advanced-wasm-L6VWL7VR.js} +2 -2
- package/dist/cli/chunks/protocol-executor-IA7WNT23.js +2 -0
- package/dist/cli/chunks/{protocol-handler-R6QJQFNL.js → protocol-handler-WDNJDEUE.js} +2 -2
- package/dist/cli/chunks/{prove-7ESQ2YAL.js → prove-3B75DA3S.js} +2 -2
- package/dist/cli/chunks/provider-manager-3K5KB5A6.js +2 -0
- package/dist/cli/chunks/qe-reasoning-bank-V5Z3BBYY.js +2 -0
- package/dist/cli/chunks/{quality-4UE345QA.js → quality-UGASS5WM.js} +2 -2
- package/dist/cli/chunks/queen-coordinator-QOMPA27Z.js +2 -0
- package/dist/cli/chunks/{real-embeddings-TYIVN3N5.js → real-embeddings-COBP2LHS.js} +2 -2
- package/dist/cli/chunks/{roocode-installer-2KOANC47.js → roocode-installer-TOZ4VLFT.js} +2 -2
- package/dist/cli/chunks/router-P5RZUPC4.js +2 -0
- package/dist/cli/chunks/routing-feedback-3PS3OZQC.js +2 -0
- package/dist/cli/chunks/{routing-handler-JFEYTN7T.js → routing-handler-5TDVSILX.js} +2 -2
- package/dist/cli/chunks/{ruvector-commands-KSLSZRJX.js → ruvector-commands-AM63KWQN.js} +2 -2
- package/dist/cli/chunks/{rvf-dual-writer-EPBL226J.js → rvf-dual-writer-UANIFE2M.js} +2 -2
- package/dist/cli/chunks/{rvf-migration-adapter-25KSI6SF.js → rvf-migration-adapter-LNPYWAPI.js} +2 -2
- package/dist/cli/chunks/{rvf-migration-coordinator-2XBYHPZP.js → rvf-migration-coordinator-U47L63DQ.js} +2 -2
- package/dist/cli/chunks/rvf-native-adapter-TT7OJPKM.js +2 -0
- package/dist/cli/chunks/safe-db-PEW7VBAE.js +2 -0
- package/dist/cli/chunks/schedule-QHOTHBQE.js +2 -0
- package/dist/cli/chunks/scheduler-KXJBYTRT.js +2 -0
- package/dist/cli/chunks/{security-4XWYKI4O.js → security-KDQ2AH7G.js} +3 -3
- package/dist/cli/chunks/{shared-rvf-adapter-WRZ3HGDQ.js → shared-rvf-adapter-5MAGLLYJ.js} +2 -2
- package/dist/cli/chunks/{shared-rvf-dual-writer-DX2N5STR.js → shared-rvf-dual-writer-GF2OPPM5.js} +2 -2
- package/dist/cli/chunks/sqlite-persistence-TPXJK34J.js +2 -0
- package/dist/cli/chunks/{status-handler-V75OSXMQ.js → status-handler-XZKEL7LO.js} +2 -2
- package/dist/cli/chunks/{structural-health-TLX3JHZ6.js → structural-health-27QKWW25.js} +2 -2
- package/dist/cli/chunks/{sync-DXZFMVZQ.js → sync-INNKS6UK.js} +2 -2
- package/dist/cli/chunks/{sync-KGBEXUF7.js → sync-V3HGPEJT.js} +2 -2
- package/dist/cli/chunks/{task-handler-T3OJ6R7H.js → task-handler-LDUVOM6G.js} +2 -2
- package/dist/cli/chunks/{task-handlers-NJYR54AS.js → task-handlers-HTCPV7OO.js} +3 -3
- package/dist/cli/chunks/{test-KMVDNNQA.js → test-PCUVGVJL.js} +4 -4
- package/dist/cli/chunks/{test-scheduling-R5EQ2XGV.js → test-scheduling-GYVXWCAA.js} +3 -3
- package/dist/cli/chunks/{token-bootstrap-PFKVV3RO.js → token-bootstrap-MJ2ANC4P.js} +2 -2
- package/dist/cli/chunks/{token-usage-ZLOGA6LR.js → token-usage-ZREHROTF.js} +2 -2
- package/dist/cli/chunks/{transformers-TNPSPQI3.js → transformers-6B3FWFYL.js} +2 -2
- package/dist/cli/chunks/{tree-sitter-wasm-parser-A2EEB5BF.js → tree-sitter-wasm-parser-JVV234MN.js} +2 -2
- package/dist/cli/chunks/{types-DIXPI4NR.js → types-MVZTJI2F.js} +2 -2
- package/dist/cli/chunks/unified-memory-ROS2NKR5.js +2 -0
- package/dist/cli/chunks/unified-memory-hnsw-FLEUF3XO.js +2 -0
- package/dist/cli/chunks/unified-persistence-QC5L7UNQ.js +2 -0
- package/dist/cli/chunks/{upgrade-LX5KP6VO.js → upgrade-MKTFEILD.js} +2 -2
- package/dist/cli/chunks/{validate-3L6F7M36.js → validate-IABGALSW.js} +2 -2
- package/dist/cli/chunks/{validate-swarm-FD42ZKAQ.js → validate-swarm-RHF53RF6.js} +2 -2
- package/dist/cli/chunks/{vibium-GSBSJR53.js → vibium-RAKW6FMF.js} +2 -2
- package/dist/cli/chunks/visual-security-NLIOUQCR.js +2 -0
- package/dist/cli/chunks/{web-tree-sitter-TXHMO4BW.js → web-tree-sitter-PYK7F4JZ.js} +2 -2
- package/dist/cli/chunks/{windsurf-installer-3EUZ6RD3.js → windsurf-installer-S3U2HWZ4.js} +2 -2
- package/dist/cli/chunks/{witness-chain-ONAUEJ4M.js → witness-chain-435NKQLB.js} +2 -2
- package/dist/cli/chunks/witness-chain-U7X6JX5J.js +2 -0
- package/dist/cli/chunks/{workflow-E7A6BV4C.js → workflow-5UHJCZ6J.js} +4 -4
- package/dist/cli/chunks/workflow-orchestrator-APE6BAXH.js +2 -0
- package/dist/cli/chunks/{wrappers-AHHAQJM3.js → wrappers-RD3NCMLK.js} +2 -2
- package/dist/cli/commands/llm-router.js +83 -26
- package/dist/domains/chaos-resilience/coordinator.d.ts +2 -1
- package/dist/domains/chaos-resilience/coordinator.js +3 -2
- package/dist/domains/chaos-resilience/plugin.d.ts +4 -2
- package/dist/domains/chaos-resilience/plugin.js +8 -5
- package/dist/domains/code-intelligence/coordinator.d.ts +2 -1
- package/dist/domains/code-intelligence/coordinator.js +3 -2
- package/dist/domains/code-intelligence/plugin.d.ts +4 -2
- package/dist/domains/code-intelligence/plugin.js +8 -5
- package/dist/domains/contract-testing/coordinator.d.ts +2 -1
- package/dist/domains/contract-testing/coordinator.js +3 -2
- package/dist/domains/contract-testing/plugin.d.ts +4 -2
- package/dist/domains/contract-testing/plugin.js +8 -5
- package/dist/domains/coverage-analysis/coordinator.d.ts +2 -1
- package/dist/domains/coverage-analysis/coordinator.js +4 -3
- package/dist/domains/coverage-analysis/plugin.d.ts +3 -2
- package/dist/domains/coverage-analysis/plugin.js +4 -4
- package/dist/domains/defect-intelligence/coordinator.d.ts +2 -1
- package/dist/domains/defect-intelligence/coordinator.js +4 -3
- package/dist/domains/defect-intelligence/plugin.d.ts +4 -2
- package/dist/domains/defect-intelligence/plugin.js +9 -6
- package/dist/domains/learning-optimization/coordinator.d.ts +2 -1
- package/dist/domains/learning-optimization/coordinator.js +3 -2
- package/dist/domains/learning-optimization/plugin.d.ts +4 -2
- package/dist/domains/learning-optimization/plugin.js +8 -5
- package/dist/domains/quality-assessment/coordinator.d.ts +2 -1
- package/dist/domains/quality-assessment/coordinator.js +4 -3
- package/dist/domains/quality-assessment/plugin.d.ts +4 -2
- package/dist/domains/quality-assessment/plugin.js +10 -6
- package/dist/domains/requirements-validation/coordinator.d.ts +2 -1
- package/dist/domains/requirements-validation/coordinator.js +3 -2
- package/dist/domains/requirements-validation/plugin.d.ts +4 -2
- package/dist/domains/requirements-validation/plugin.js +8 -5
- package/dist/domains/security-compliance/coordinator.d.ts +2 -1
- package/dist/domains/security-compliance/coordinator.js +4 -2
- package/dist/domains/security-compliance/plugin.d.ts +4 -2
- package/dist/domains/security-compliance/plugin.js +11 -6
- package/dist/domains/test-execution/coordinator.d.ts +3 -2
- package/dist/domains/test-execution/coordinator.js +6 -5
- package/dist/domains/test-execution/plugin.d.ts +4 -2
- package/dist/domains/test-execution/plugin.js +6 -4
- package/dist/domains/test-generation/coordinator.d.ts +2 -1
- package/dist/domains/test-generation/coordinator.js +4 -3
- package/dist/domains/test-generation/plugin.d.ts +4 -2
- package/dist/domains/test-generation/plugin.js +12 -7
- package/dist/domains/visual-accessibility/coordinator.d.ts +2 -1
- package/dist/domains/visual-accessibility/coordinator.js +4 -3
- package/dist/domains/visual-accessibility/plugin.d.ts +4 -2
- package/dist/domains/visual-accessibility/plugin.js +9 -6
- package/dist/kernel/interfaces.d.ts +37 -0
- package/dist/kernel/kernel.d.ts +39 -0
- package/dist/kernel/kernel.js +157 -17
- package/dist/mcp/bundle.js +417 -395
- package/dist/mcp/qe-tool-bridge.js +8 -1
- package/dist/mcp/tools/base.d.ts +56 -0
- package/dist/mcp/tools/base.js +104 -1
- package/dist/mcp/tools/chaos-resilience/inject.js +4 -2
- package/dist/mcp/tools/code-intelligence/analyze.js +5 -3
- package/dist/mcp/tools/contract-testing/validate.js +4 -2
- package/dist/mcp/tools/coverage-analysis/index.js +11 -5
- package/dist/mcp/tools/defect-intelligence/predict.js +5 -10
- package/dist/mcp/tools/learning-optimization/optimize.js +4 -2
- package/dist/mcp/tools/registry.js +8 -1
- package/dist/mcp/tools/test-generation/generate.js +10 -6
- package/dist/mcp/tools/visual-accessibility/index.js +7 -4
- package/dist/shared/llm/llm-router-service.d.ts +77 -0
- package/dist/shared/llm/llm-router-service.js +166 -0
- package/dist/shared/llm/providers/gemini.js +5 -2
- package/dist/shared/llm/router/config-store.d.ts +89 -0
- package/dist/shared/llm/router/config-store.js +261 -0
- package/dist/shared/llm/router/hybrid-router.js +33 -11
- package/package.json +1 -1
- package/dist/cli/chunks/adapter-WTE6UVGP.js +0 -2
- package/dist/cli/chunks/aqe-learning-engine-LCLEBU7D.js +0 -2
- package/dist/cli/chunks/base-73I73HBF.js +0 -2
- package/dist/cli/chunks/browser-workflow-2NSV5O6W.js +0 -2
- package/dist/cli/chunks/chunk-6MONUYQ5.js +0 -2
- package/dist/cli/chunks/chunk-X73CRYF4.js +0 -2
- package/dist/cli/chunks/client-7GB4WWUD.js +0 -2
- package/dist/cli/chunks/cross-domain-router-7HQ74TLE.js +0 -2
- package/dist/cli/chunks/dream-G5SEFHI4.js +0 -2
- package/dist/cli/chunks/heartbeat-scheduler-NG7BY3FR.js +0 -2
- package/dist/cli/chunks/hnsw-adapter-TDSLUI7K.js +0 -2
- package/dist/cli/chunks/hnsw-index-OWLQSOQH.js +0 -2
- package/dist/cli/chunks/hybrid-router-URU2XLBD.js +0 -2
- package/dist/cli/chunks/impact-analyzer-NMTN75KA.js +0 -2
- package/dist/cli/chunks/init-wizard-SHBFYGBV.js +0 -2
- package/dist/cli/chunks/kernel-7KVY2JGO.js +0 -2
- package/dist/cli/chunks/knowledge-graph-V4G5J5B7.js +0 -2
- package/dist/cli/chunks/llm-router-G6N2OKDA.js +0 -36
- package/dist/cli/chunks/load-test-N4RNPLG4.js +0 -2
- package/dist/cli/chunks/memory-backend-HPGJ5YDQ.js +0 -2
- package/dist/cli/chunks/memory-handlers-K33YVCVQ.js +0 -2
- package/dist/cli/chunks/protocol-executor-GNVWUJUP.js +0 -2
- package/dist/cli/chunks/qe-reasoning-bank-DDSBHO6D.js +0 -2
- package/dist/cli/chunks/queen-coordinator-BQJ5O63C.js +0 -2
- package/dist/cli/chunks/router-C2RKWB7J.js +0 -2
- package/dist/cli/chunks/routing-feedback-RHATTSJ6.js +0 -2
- package/dist/cli/chunks/rvf-native-adapter-QG4CXHLL.js +0 -2
- package/dist/cli/chunks/safe-db-A4KQ2IDB.js +0 -2
- package/dist/cli/chunks/schedule-O7MLASQT.js +0 -2
- package/dist/cli/chunks/scheduler-HT7RNYQ2.js +0 -2
- package/dist/cli/chunks/sqlite-persistence-4NNKJ6CQ.js +0 -2
- package/dist/cli/chunks/unified-memory-CMNJVHOJ.js +0 -2
- package/dist/cli/chunks/unified-memory-hnsw-JQLU2KI6.js +0 -2
- package/dist/cli/chunks/unified-persistence-I25TEDIU.js +0 -2
- package/dist/cli/chunks/visual-security-AJJIEV5V.js +0 -2
- package/dist/cli/chunks/witness-chain-762QQBTN.js +0 -2
- package/dist/cli/chunks/workflow-orchestrator-ZGPYISKY.js +0 -2
|
@@ -0,0 +1,166 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Agentic QE v3 - LLM Router Service (kernel singleton)
|
|
3
|
+
*
|
|
4
|
+
* Thin wrapper around ProviderManager + HybridRouter that:
|
|
5
|
+
* 1. Loads RouterConfig via config-store (defaults <- disk <- env <- override)
|
|
6
|
+
* 2. Builds a ProviderManager whose enabled provider set matches what's
|
|
7
|
+
* actually available (key in env OR explicitly enabled on disk)
|
|
8
|
+
* 3. Picks `primary` and `fallbacks` from the enabled set in a sensible
|
|
9
|
+
* order, honoring the user's defaultProvider when possible
|
|
10
|
+
* 4. Constructs the HybridRouter and initializes it once
|
|
11
|
+
*
|
|
12
|
+
* This is what the QEKernelImpl instantiates and exposes as
|
|
13
|
+
* `kernel.llmRouter`. Domain plugins receive it via their factory's
|
|
14
|
+
* 4th argument and pass it down to coordinators/services so the
|
|
15
|
+
* isLLMAnalysisAvailable() branches in 14 services actually fire.
|
|
16
|
+
*
|
|
17
|
+
* Why a service wrapper rather than constructing HybridRouter inline
|
|
18
|
+
* in the kernel: the kernel already has too much going on, and the
|
|
19
|
+
* provider-selection + fallback-ordering logic is non-trivial enough
|
|
20
|
+
* to deserve its own test surface (see llm-router-service.test.ts).
|
|
21
|
+
*/
|
|
22
|
+
import { ProviderManager } from './provider-manager.js';
|
|
23
|
+
import { HybridRouter } from './router/hybrid-router.js';
|
|
24
|
+
import { loadRouterConfig, shouldEnableRouter, detectAvailableProvidersFromEnv, } from './router/config-store.js';
|
|
25
|
+
/**
|
|
26
|
+
* Order in which we pick fallbacks when the user hasn't specified any.
|
|
27
|
+
* Local-first (free), then cheapest cloud, then richer providers. This
|
|
28
|
+
* is a defensive default; users who care should set
|
|
29
|
+
* `routerConfig.fallbackChain` explicitly.
|
|
30
|
+
*/
|
|
31
|
+
const FALLBACK_PRIORITY = [
|
|
32
|
+
'ollama',
|
|
33
|
+
'onnx',
|
|
34
|
+
'gemini',
|
|
35
|
+
'openrouter',
|
|
36
|
+
'openai',
|
|
37
|
+
'claude',
|
|
38
|
+
'azure-openai',
|
|
39
|
+
'bedrock',
|
|
40
|
+
];
|
|
41
|
+
/**
|
|
42
|
+
* Build (and initialize) a HybridRouter for use as the kernel singleton.
|
|
43
|
+
* Returns null when no providers are available — caller decides whether
|
|
44
|
+
* that's an error or a "router-disabled" boot.
|
|
45
|
+
*/
|
|
46
|
+
export async function createLLMRouterService(options = {}) {
|
|
47
|
+
// Honor the test-injected ProviderManager path first.
|
|
48
|
+
if (options.providerManager) {
|
|
49
|
+
const config = loadRouterConfig({
|
|
50
|
+
projectRoot: options.projectRoot,
|
|
51
|
+
override: options.override,
|
|
52
|
+
env: options.env,
|
|
53
|
+
});
|
|
54
|
+
const router = new HybridRouter(options.providerManager, config);
|
|
55
|
+
await router.initialize();
|
|
56
|
+
return {
|
|
57
|
+
router,
|
|
58
|
+
resolvedConfig: config,
|
|
59
|
+
enabledProviders: providersFromConfig(config),
|
|
60
|
+
};
|
|
61
|
+
}
|
|
62
|
+
// Real path: detect env, load config, build provider manager.
|
|
63
|
+
if (!shouldEnableRouter({ projectRoot: options.projectRoot, env: options.env })) {
|
|
64
|
+
return null;
|
|
65
|
+
}
|
|
66
|
+
const config = loadRouterConfig({
|
|
67
|
+
projectRoot: options.projectRoot,
|
|
68
|
+
override: options.override,
|
|
69
|
+
env: options.env,
|
|
70
|
+
});
|
|
71
|
+
const enabled = pickEnabledProviders(config, options.env ?? process.env);
|
|
72
|
+
if (enabled.length === 0) {
|
|
73
|
+
return null;
|
|
74
|
+
}
|
|
75
|
+
const { primary, fallbacks } = pickPrimaryAndFallbacks(config, enabled);
|
|
76
|
+
const providerManagerConfig = {
|
|
77
|
+
primary: primary,
|
|
78
|
+
fallbacks: fallbacks,
|
|
79
|
+
providers: extractProviderConfigs(config, enabled),
|
|
80
|
+
loadBalancing: 'round-robin',
|
|
81
|
+
global: { enableCostTracking: true, enableMetrics: true },
|
|
82
|
+
};
|
|
83
|
+
const providerManager = new ProviderManager(providerManagerConfig);
|
|
84
|
+
const router = new HybridRouter(providerManager, config);
|
|
85
|
+
await router.initialize();
|
|
86
|
+
return {
|
|
87
|
+
router,
|
|
88
|
+
resolvedConfig: config,
|
|
89
|
+
enabledProviders: enabled,
|
|
90
|
+
};
|
|
91
|
+
}
|
|
92
|
+
/**
|
|
93
|
+
* Determine which providers are actually usable. A provider is enabled if:
|
|
94
|
+
* - its config has `enabled: true`, AND
|
|
95
|
+
* - it's either local (ollama, onnx) OR has a detected env key
|
|
96
|
+
*
|
|
97
|
+
* Returns a deduped list in FALLBACK_PRIORITY order with the user's
|
|
98
|
+
* defaultProvider hoisted to the front when present.
|
|
99
|
+
*/
|
|
100
|
+
export function pickEnabledProviders(config, env = process.env) {
|
|
101
|
+
const detected = detectAvailableProvidersFromEnv(env);
|
|
102
|
+
const result = [];
|
|
103
|
+
const consider = (p) => {
|
|
104
|
+
if (result.includes(p))
|
|
105
|
+
return;
|
|
106
|
+
const cfg = config.providers?.[p];
|
|
107
|
+
if (!cfg?.enabled)
|
|
108
|
+
return;
|
|
109
|
+
if (!detected.has(p))
|
|
110
|
+
return;
|
|
111
|
+
result.push(p);
|
|
112
|
+
};
|
|
113
|
+
// User's preferred default first
|
|
114
|
+
consider(config.defaultProvider);
|
|
115
|
+
// Then fallback chain order if user set it
|
|
116
|
+
for (const entry of config.fallbackChain?.entries ?? []) {
|
|
117
|
+
consider(entry.provider);
|
|
118
|
+
}
|
|
119
|
+
// Then our defensive priority
|
|
120
|
+
for (const p of FALLBACK_PRIORITY) {
|
|
121
|
+
consider(p);
|
|
122
|
+
}
|
|
123
|
+
return result;
|
|
124
|
+
}
|
|
125
|
+
/**
|
|
126
|
+
* Collect the unique provider list from a RouterConfig — used by the
|
|
127
|
+
* test-injected ProviderManager path where we don't run the env-detect
|
|
128
|
+
* filter.
|
|
129
|
+
*/
|
|
130
|
+
function providersFromConfig(config) {
|
|
131
|
+
const seen = new Set([config.defaultProvider]);
|
|
132
|
+
for (const entry of config.fallbackChain?.entries ?? []) {
|
|
133
|
+
seen.add(entry.provider);
|
|
134
|
+
}
|
|
135
|
+
return Array.from(seen);
|
|
136
|
+
}
|
|
137
|
+
/**
|
|
138
|
+
* Choose the primary provider and fallback chain from the enabled set.
|
|
139
|
+
* Honors config.defaultProvider when it's in the enabled set, otherwise
|
|
140
|
+
* picks the first enabled provider in priority order.
|
|
141
|
+
*/
|
|
142
|
+
export function pickPrimaryAndFallbacks(config, enabled) {
|
|
143
|
+
if (enabled.length === 0) {
|
|
144
|
+
throw new Error('pickPrimaryAndFallbacks: no enabled providers');
|
|
145
|
+
}
|
|
146
|
+
const preferred = enabled.includes(config.defaultProvider)
|
|
147
|
+
? config.defaultProvider
|
|
148
|
+
: enabled[0];
|
|
149
|
+
const fallbacks = enabled.filter((p) => p !== preferred);
|
|
150
|
+
return { primary: preferred, fallbacks };
|
|
151
|
+
}
|
|
152
|
+
/**
|
|
153
|
+
* Extract only the provider configs for the enabled set, so
|
|
154
|
+
* ProviderManager doesn't try to construct providers we don't need.
|
|
155
|
+
*/
|
|
156
|
+
function extractProviderConfigs(config, enabled) {
|
|
157
|
+
const out = {};
|
|
158
|
+
for (const p of enabled) {
|
|
159
|
+
const cfg = config.providers?.[p];
|
|
160
|
+
if (cfg) {
|
|
161
|
+
out[p] = cfg;
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
return out;
|
|
165
|
+
}
|
|
166
|
+
//# sourceMappingURL=llm-router-service.js.map
|
|
@@ -84,7 +84,7 @@ export class GeminiProvider {
|
|
|
84
84
|
if (!apiKey) {
|
|
85
85
|
return {
|
|
86
86
|
healthy: false,
|
|
87
|
-
error: 'API key not configured. Set GOOGLE_AI_API_KEY or
|
|
87
|
+
error: 'API key not configured. Set GOOGLE_AI_API_KEY, GEMINI_API_KEY, or GOOGLE_API_KEY environment variable.',
|
|
88
88
|
};
|
|
89
89
|
}
|
|
90
90
|
const start = Date.now();
|
|
@@ -438,7 +438,10 @@ export class GeminiProvider {
|
|
|
438
438
|
* Get API key from config or environment
|
|
439
439
|
*/
|
|
440
440
|
getApiKey() {
|
|
441
|
-
return this.config.apiKey ??
|
|
441
|
+
return (this.config.apiKey ??
|
|
442
|
+
process.env.GOOGLE_AI_API_KEY ??
|
|
443
|
+
process.env.GEMINI_API_KEY ??
|
|
444
|
+
process.env.GOOGLE_API_KEY);
|
|
442
445
|
}
|
|
443
446
|
/**
|
|
444
447
|
* Get base URL
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Agentic QE v3 - LLM Router Config Store (ADR-043)
|
|
3
|
+
*
|
|
4
|
+
* Persistent storage and environment-aware merging for HybridRouter
|
|
5
|
+
* configuration. Lives next to the project's .agentic-qe/ data dir so
|
|
6
|
+
* each project can carry its own routing policy without leaking secrets.
|
|
7
|
+
*
|
|
8
|
+
* Precedence (highest wins):
|
|
9
|
+
* 1. Explicit override passed to loadRouterConfig()
|
|
10
|
+
* 2. Environment variables (provider API keys, AQE_LLM_* settings)
|
|
11
|
+
* 3. .agentic-qe/llm-config.json (project file)
|
|
12
|
+
* 4. DEFAULT_ROUTER_CONFIG from types.ts
|
|
13
|
+
*
|
|
14
|
+
* Provider enablement: a provider whose API key is present in the
|
|
15
|
+
* environment is force-enabled (overriding any disk value of `enabled:
|
|
16
|
+
* false`). A provider whose key is absent is left in its disk/default
|
|
17
|
+
* state — we don't disable it implicitly, because users may set keys
|
|
18
|
+
* later via `aqe llm config --set`.
|
|
19
|
+
*/
|
|
20
|
+
import type { RouterConfig, ExtendedProviderType } from './types.js';
|
|
21
|
+
/** Filename under .agentic-qe/ */
|
|
22
|
+
export declare const ROUTER_CONFIG_FILENAME = "llm-config.json";
|
|
23
|
+
/**
|
|
24
|
+
* Return the resolved config-file path for a project.
|
|
25
|
+
* Caller may override projectRoot for tests; defaults to findProjectRoot().
|
|
26
|
+
*/
|
|
27
|
+
export declare function getRouterConfigPath(projectRoot?: string): string;
|
|
28
|
+
/**
|
|
29
|
+
* Detect which providers have a non-empty API key in the current env.
|
|
30
|
+
* Ollama and ONNX always count as detected (they're local).
|
|
31
|
+
*/
|
|
32
|
+
export declare function detectAvailableProvidersFromEnv(env?: NodeJS.ProcessEnv): Set<ExtendedProviderType>;
|
|
33
|
+
/**
|
|
34
|
+
* Load the project-level router config from disk. Returns the parsed
|
|
35
|
+
* partial config, or {} if the file doesn't exist or is unreadable.
|
|
36
|
+
* Malformed JSON throws — we don't silently corrupt user config.
|
|
37
|
+
*/
|
|
38
|
+
export declare function loadRouterConfigFile(projectRoot?: string): Partial<RouterConfig>;
|
|
39
|
+
/**
|
|
40
|
+
* Save the project-level router config to disk. Creates the .agentic-qe
|
|
41
|
+
* directory if missing. Writes atomically via a temp-file + rename so a
|
|
42
|
+
* crashed write can't leave a half-written config behind.
|
|
43
|
+
*
|
|
44
|
+
* IMPORTANT: this file is project-local and may end up checked into the
|
|
45
|
+
* repo. Callers MUST NOT pass API keys in `config.providers[*].apiKey`
|
|
46
|
+
* — keys belong in env vars. We strip apiKey fields defensively.
|
|
47
|
+
*/
|
|
48
|
+
export declare function saveRouterConfigFile(config: Partial<RouterConfig>, projectRoot?: string): void;
|
|
49
|
+
/**
|
|
50
|
+
* Merge a partial config onto a base. Provider entries are shallow-merged
|
|
51
|
+
* (so a partial provider override doesn't wipe the default model). The
|
|
52
|
+
* top-level scalars use last-wins.
|
|
53
|
+
*/
|
|
54
|
+
export declare function mergeRouterConfig(base: RouterConfig, override: Partial<RouterConfig>): RouterConfig;
|
|
55
|
+
/**
|
|
56
|
+
* Apply env-detection on top of a merged config: providers whose API
|
|
57
|
+
* keys are present in env are force-enabled (so a user who sets
|
|
58
|
+
* GOOGLE_API_KEY doesn't also have to remember to flip gemini.enabled
|
|
59
|
+
* to true). Providers without keys are left at their existing setting.
|
|
60
|
+
*
|
|
61
|
+
* COUNTERINTUITIVE: env presence OVERRIDES an explicit `enabled: false`
|
|
62
|
+
* on disk. The reasoning: env is more recent / more authoritative than
|
|
63
|
+
* a stale checked-in config file, and users who set an API key in env
|
|
64
|
+
* usually intend to use the provider. To truly disable a provider that
|
|
65
|
+
* has a key in env, either unset the env key OR set the env-only
|
|
66
|
+
* kill-switch `AQE_LLM_ROUTER_DISABLED=1` (which disables the entire
|
|
67
|
+
* router). This precedence is documented in ADR-043's addendum.
|
|
68
|
+
*/
|
|
69
|
+
export declare function applyEnvProviderDetection(config: RouterConfig, env?: NodeJS.ProcessEnv): RouterConfig;
|
|
70
|
+
/**
|
|
71
|
+
* The full load path: defaults <- disk <- env detection <- override.
|
|
72
|
+
* This is what the kernel and CLI both call. Returns a fully-resolved
|
|
73
|
+
* RouterConfig ready to hand to HybridRouter.
|
|
74
|
+
*/
|
|
75
|
+
export declare function loadRouterConfig(options?: {
|
|
76
|
+
projectRoot?: string;
|
|
77
|
+
override?: Partial<RouterConfig>;
|
|
78
|
+
env?: NodeJS.ProcessEnv;
|
|
79
|
+
}): RouterConfig;
|
|
80
|
+
/**
|
|
81
|
+
* Quick check used by the kernel to decide whether to construct a
|
|
82
|
+
* router at all. Returns true if at least one non-local provider has
|
|
83
|
+
* a key in env, OR the disk config explicitly enables a provider.
|
|
84
|
+
*/
|
|
85
|
+
export declare function shouldEnableRouter(options?: {
|
|
86
|
+
projectRoot?: string;
|
|
87
|
+
env?: NodeJS.ProcessEnv;
|
|
88
|
+
}): boolean;
|
|
89
|
+
//# sourceMappingURL=config-store.d.ts.map
|
|
@@ -0,0 +1,261 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Agentic QE v3 - LLM Router Config Store (ADR-043)
|
|
3
|
+
*
|
|
4
|
+
* Persistent storage and environment-aware merging for HybridRouter
|
|
5
|
+
* configuration. Lives next to the project's .agentic-qe/ data dir so
|
|
6
|
+
* each project can carry its own routing policy without leaking secrets.
|
|
7
|
+
*
|
|
8
|
+
* Precedence (highest wins):
|
|
9
|
+
* 1. Explicit override passed to loadRouterConfig()
|
|
10
|
+
* 2. Environment variables (provider API keys, AQE_LLM_* settings)
|
|
11
|
+
* 3. .agentic-qe/llm-config.json (project file)
|
|
12
|
+
* 4. DEFAULT_ROUTER_CONFIG from types.ts
|
|
13
|
+
*
|
|
14
|
+
* Provider enablement: a provider whose API key is present in the
|
|
15
|
+
* environment is force-enabled (overriding any disk value of `enabled:
|
|
16
|
+
* false`). A provider whose key is absent is left in its disk/default
|
|
17
|
+
* state — we don't disable it implicitly, because users may set keys
|
|
18
|
+
* later via `aqe llm config --set`.
|
|
19
|
+
*/
|
|
20
|
+
import * as fs from 'fs';
|
|
21
|
+
import * as path from 'path';
|
|
22
|
+
import { findProjectRoot } from '../../../kernel/unified-memory.js';
|
|
23
|
+
import { DEFAULT_ROUTER_CONFIG, ALL_PROVIDER_TYPES } from './types.js';
|
|
24
|
+
/** Filename under .agentic-qe/ */
|
|
25
|
+
export const ROUTER_CONFIG_FILENAME = 'llm-config.json';
|
|
26
|
+
/**
|
|
27
|
+
* Env var names per provider — multiple aliases supported where the
|
|
28
|
+
* upstream provider accepts more than one name. First non-empty wins.
|
|
29
|
+
*
|
|
30
|
+
* Empty array means "local provider, no key required". The set of
|
|
31
|
+
* runtime-constructible providers is narrower than ExtendedProviderType
|
|
32
|
+
* (e.g. onnx is in the type system but ProviderManager doesn't yet
|
|
33
|
+
* have a case for it) — see RUNTIME_CONSTRUCTIBLE_PROVIDERS below.
|
|
34
|
+
*/
|
|
35
|
+
const PROVIDER_ENV_KEYS = {
|
|
36
|
+
claude: ['ANTHROPIC_API_KEY', 'CLAUDE_API_KEY'],
|
|
37
|
+
openai: ['OPENAI_API_KEY'],
|
|
38
|
+
ollama: [], // ollama is local; no key required
|
|
39
|
+
openrouter: ['OPENROUTER_API_KEY'],
|
|
40
|
+
gemini: ['GOOGLE_AI_API_KEY', 'GEMINI_API_KEY', 'GOOGLE_API_KEY'],
|
|
41
|
+
'azure-openai': ['AZURE_OPENAI_API_KEY'],
|
|
42
|
+
bedrock: ['AWS_ACCESS_KEY_ID'], // bedrock auth is more complex; presence is a hint
|
|
43
|
+
onnx: [], // local
|
|
44
|
+
};
|
|
45
|
+
/**
|
|
46
|
+
* Providers that ProviderManager.createProvider() can actually
|
|
47
|
+
* instantiate today. Anything not in this set is dropped from the
|
|
48
|
+
* "available" set even if its env keys are present, so we don't emit
|
|
49
|
+
* a "Failed to create X provider" warning at every kernel boot.
|
|
50
|
+
*
|
|
51
|
+
* Keep this in sync with src/shared/llm/provider-manager.ts:createProvider().
|
|
52
|
+
*/
|
|
53
|
+
const RUNTIME_CONSTRUCTIBLE_PROVIDERS = new Set([
|
|
54
|
+
'claude',
|
|
55
|
+
'openai',
|
|
56
|
+
'ollama',
|
|
57
|
+
'openrouter',
|
|
58
|
+
'gemini',
|
|
59
|
+
'azure-openai',
|
|
60
|
+
'bedrock',
|
|
61
|
+
]);
|
|
62
|
+
/**
|
|
63
|
+
* Return the resolved config-file path for a project.
|
|
64
|
+
* Caller may override projectRoot for tests; defaults to findProjectRoot().
|
|
65
|
+
*/
|
|
66
|
+
export function getRouterConfigPath(projectRoot) {
|
|
67
|
+
const root = projectRoot ?? findProjectRoot();
|
|
68
|
+
return path.join(root, '.agentic-qe', ROUTER_CONFIG_FILENAME);
|
|
69
|
+
}
|
|
70
|
+
/**
|
|
71
|
+
* Detect which providers have a non-empty API key in the current env.
|
|
72
|
+
* Ollama and ONNX always count as detected (they're local).
|
|
73
|
+
*/
|
|
74
|
+
export function detectAvailableProvidersFromEnv(env = process.env) {
|
|
75
|
+
const available = new Set();
|
|
76
|
+
for (const provider of ALL_PROVIDER_TYPES) {
|
|
77
|
+
if (!RUNTIME_CONSTRUCTIBLE_PROVIDERS.has(provider)) {
|
|
78
|
+
// ProviderManager has no case for this provider yet (e.g. onnx).
|
|
79
|
+
// Pretending it's available leads to "Failed to create" noise.
|
|
80
|
+
continue;
|
|
81
|
+
}
|
|
82
|
+
const keys = PROVIDER_ENV_KEYS[provider];
|
|
83
|
+
if (keys.length === 0) {
|
|
84
|
+
// local providers — always available if their binary is, but at
|
|
85
|
+
// config-merge time we treat them as "potentially available"
|
|
86
|
+
available.add(provider);
|
|
87
|
+
continue;
|
|
88
|
+
}
|
|
89
|
+
if (keys.some((k) => (env[k] ?? '').trim().length > 0)) {
|
|
90
|
+
available.add(provider);
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
return available;
|
|
94
|
+
}
|
|
95
|
+
/**
|
|
96
|
+
* Load the project-level router config from disk. Returns the parsed
|
|
97
|
+
* partial config, or {} if the file doesn't exist or is unreadable.
|
|
98
|
+
* Malformed JSON throws — we don't silently corrupt user config.
|
|
99
|
+
*/
|
|
100
|
+
export function loadRouterConfigFile(projectRoot) {
|
|
101
|
+
const filePath = getRouterConfigPath(projectRoot);
|
|
102
|
+
if (!fs.existsSync(filePath)) {
|
|
103
|
+
return {};
|
|
104
|
+
}
|
|
105
|
+
const raw = fs.readFileSync(filePath, 'utf8');
|
|
106
|
+
if (!raw.trim()) {
|
|
107
|
+
return {};
|
|
108
|
+
}
|
|
109
|
+
const parsed = JSON.parse(raw);
|
|
110
|
+
if (typeof parsed !== 'object' || parsed === null) {
|
|
111
|
+
throw new Error(`Invalid ${ROUTER_CONFIG_FILENAME}: expected object, got ${typeof parsed}`);
|
|
112
|
+
}
|
|
113
|
+
return parsed;
|
|
114
|
+
}
|
|
115
|
+
/**
|
|
116
|
+
* Save the project-level router config to disk. Creates the .agentic-qe
|
|
117
|
+
* directory if missing. Writes atomically via a temp-file + rename so a
|
|
118
|
+
* crashed write can't leave a half-written config behind.
|
|
119
|
+
*
|
|
120
|
+
* IMPORTANT: this file is project-local and may end up checked into the
|
|
121
|
+
* repo. Callers MUST NOT pass API keys in `config.providers[*].apiKey`
|
|
122
|
+
* — keys belong in env vars. We strip apiKey fields defensively.
|
|
123
|
+
*/
|
|
124
|
+
export function saveRouterConfigFile(config, projectRoot) {
|
|
125
|
+
const filePath = getRouterConfigPath(projectRoot);
|
|
126
|
+
const dir = path.dirname(filePath);
|
|
127
|
+
if (!fs.existsSync(dir)) {
|
|
128
|
+
fs.mkdirSync(dir, { recursive: true });
|
|
129
|
+
}
|
|
130
|
+
const sanitized = stripApiKeys(config);
|
|
131
|
+
const json = JSON.stringify(sanitized, null, 2) + '\n';
|
|
132
|
+
const tmp = filePath + '.tmp-' + process.pid;
|
|
133
|
+
fs.writeFileSync(tmp, json, { encoding: 'utf8', mode: 0o600 });
|
|
134
|
+
fs.renameSync(tmp, filePath);
|
|
135
|
+
}
|
|
136
|
+
/**
|
|
137
|
+
* Strip apiKey fields from provider configs to prevent accidental
|
|
138
|
+
* commits of secrets. Returns a deep clone — input is untouched.
|
|
139
|
+
*
|
|
140
|
+
* Emits a console warning when any apiKey is stripped, so silent
|
|
141
|
+
* strips don't surprise callers. The kernel/CLI consume from env
|
|
142
|
+
* vars (ANTHROPIC_API_KEY, GEMINI_API_KEY, GOOGLE_API_KEY, etc.),
|
|
143
|
+
* never from disk config — see config-store doc header for the
|
|
144
|
+
* precedence rule.
|
|
145
|
+
*/
|
|
146
|
+
function stripApiKeys(config) {
|
|
147
|
+
if (!config.providers) {
|
|
148
|
+
return JSON.parse(JSON.stringify(config));
|
|
149
|
+
}
|
|
150
|
+
const cloned = JSON.parse(JSON.stringify(config));
|
|
151
|
+
let strippedProviders = [];
|
|
152
|
+
if (cloned.providers) {
|
|
153
|
+
for (const provider of Object.keys(cloned.providers)) {
|
|
154
|
+
const entry = cloned.providers[provider];
|
|
155
|
+
if (entry && 'apiKey' in entry && entry.apiKey) {
|
|
156
|
+
delete entry.apiKey;
|
|
157
|
+
strippedProviders.push(provider);
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
}
|
|
161
|
+
if (strippedProviders.length > 0) {
|
|
162
|
+
// eslint-disable-next-line no-console
|
|
163
|
+
console.warn(`[router-config] Refused to persist apiKey for: ${strippedProviders.join(', ')}. ` +
|
|
164
|
+
`API keys belong in environment variables (e.g. ANTHROPIC_API_KEY, GEMINI_API_KEY, ` +
|
|
165
|
+
`OPENAI_API_KEY, OPENROUTER_API_KEY), NOT in .agentic-qe/llm-config.json which may ` +
|
|
166
|
+
`be checked into source control.`);
|
|
167
|
+
}
|
|
168
|
+
return cloned;
|
|
169
|
+
}
|
|
170
|
+
/**
|
|
171
|
+
* Merge a partial config onto a base. Provider entries are shallow-merged
|
|
172
|
+
* (so a partial provider override doesn't wipe the default model). The
|
|
173
|
+
* top-level scalars use last-wins.
|
|
174
|
+
*/
|
|
175
|
+
export function mergeRouterConfig(base, override) {
|
|
176
|
+
const merged = {
|
|
177
|
+
...base,
|
|
178
|
+
...override,
|
|
179
|
+
providers: { ...(base.providers ?? {}) },
|
|
180
|
+
};
|
|
181
|
+
if (override.providers) {
|
|
182
|
+
for (const [provider, cfg] of Object.entries(override.providers)) {
|
|
183
|
+
if (!cfg)
|
|
184
|
+
continue;
|
|
185
|
+
const key = provider;
|
|
186
|
+
merged.providers[key] = {
|
|
187
|
+
...(base.providers?.[key] ?? {}),
|
|
188
|
+
...cfg,
|
|
189
|
+
};
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
return merged;
|
|
193
|
+
}
|
|
194
|
+
/**
|
|
195
|
+
* Apply env-detection on top of a merged config: providers whose API
|
|
196
|
+
* keys are present in env are force-enabled (so a user who sets
|
|
197
|
+
* GOOGLE_API_KEY doesn't also have to remember to flip gemini.enabled
|
|
198
|
+
* to true). Providers without keys are left at their existing setting.
|
|
199
|
+
*
|
|
200
|
+
* COUNTERINTUITIVE: env presence OVERRIDES an explicit `enabled: false`
|
|
201
|
+
* on disk. The reasoning: env is more recent / more authoritative than
|
|
202
|
+
* a stale checked-in config file, and users who set an API key in env
|
|
203
|
+
* usually intend to use the provider. To truly disable a provider that
|
|
204
|
+
* has a key in env, either unset the env key OR set the env-only
|
|
205
|
+
* kill-switch `AQE_LLM_ROUTER_DISABLED=1` (which disables the entire
|
|
206
|
+
* router). This precedence is documented in ADR-043's addendum.
|
|
207
|
+
*/
|
|
208
|
+
export function applyEnvProviderDetection(config, env = process.env) {
|
|
209
|
+
const available = detectAvailableProvidersFromEnv(env);
|
|
210
|
+
const merged = {
|
|
211
|
+
...config,
|
|
212
|
+
providers: { ...(config.providers ?? {}) },
|
|
213
|
+
};
|
|
214
|
+
for (const provider of available) {
|
|
215
|
+
const keys = PROVIDER_ENV_KEYS[provider];
|
|
216
|
+
if (keys.length === 0)
|
|
217
|
+
continue; // local provider, leave default
|
|
218
|
+
const current = merged.providers[provider] ?? { enabled: false };
|
|
219
|
+
if (!current.enabled) {
|
|
220
|
+
merged.providers[provider] = { ...current, enabled: true };
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
return merged;
|
|
224
|
+
}
|
|
225
|
+
/**
|
|
226
|
+
* The full load path: defaults <- disk <- env detection <- override.
|
|
227
|
+
* This is what the kernel and CLI both call. Returns a fully-resolved
|
|
228
|
+
* RouterConfig ready to hand to HybridRouter.
|
|
229
|
+
*/
|
|
230
|
+
export function loadRouterConfig(options = {}) {
|
|
231
|
+
const onDisk = loadRouterConfigFile(options.projectRoot);
|
|
232
|
+
const merged = mergeRouterConfig(DEFAULT_ROUTER_CONFIG, onDisk);
|
|
233
|
+
const withEnv = applyEnvProviderDetection(merged, options.env);
|
|
234
|
+
return options.override ? mergeRouterConfig(withEnv, options.override) : withEnv;
|
|
235
|
+
}
|
|
236
|
+
/**
|
|
237
|
+
* Quick check used by the kernel to decide whether to construct a
|
|
238
|
+
* router at all. Returns true if at least one non-local provider has
|
|
239
|
+
* a key in env, OR the disk config explicitly enables a provider.
|
|
240
|
+
*/
|
|
241
|
+
export function shouldEnableRouter(options = {}) {
|
|
242
|
+
const env = options.env ?? process.env;
|
|
243
|
+
for (const provider of ALL_PROVIDER_TYPES) {
|
|
244
|
+
const keys = PROVIDER_ENV_KEYS[provider];
|
|
245
|
+
if (keys.length === 0)
|
|
246
|
+
continue;
|
|
247
|
+
if (keys.some((k) => (env[k] ?? '').trim().length > 0)) {
|
|
248
|
+
return true;
|
|
249
|
+
}
|
|
250
|
+
}
|
|
251
|
+
// No env keys — fall back to disk config.
|
|
252
|
+
const onDisk = loadRouterConfigFile(options.projectRoot);
|
|
253
|
+
if (onDisk.providers) {
|
|
254
|
+
for (const cfg of Object.values(onDisk.providers)) {
|
|
255
|
+
if (cfg?.enabled)
|
|
256
|
+
return true;
|
|
257
|
+
}
|
|
258
|
+
}
|
|
259
|
+
return false;
|
|
260
|
+
}
|
|
261
|
+
//# sourceMappingURL=config-store.js.map
|
|
@@ -443,16 +443,31 @@ export class HybridRouter {
|
|
|
443
443
|
const executionOrder = [
|
|
444
444
|
{ provider: decision.providerType, model: decision.providerModelId },
|
|
445
445
|
];
|
|
446
|
-
//
|
|
446
|
+
// ADR-043 wiring fix: always include the user's defaultProvider as
|
|
447
|
+
// an implicit fallback. Without this, a request that matches a rule
|
|
448
|
+
// routing to provider X (e.g. small-requests-haiku → claude) but
|
|
449
|
+
// where X fails at API time has no way to recover for users who
|
|
450
|
+
// only have a non-X provider configured. This was a real bug
|
|
451
|
+
// surfaced by the rule-based E2E test in
|
|
452
|
+
// tests/e2e/llm-router-real-providers.test.ts.
|
|
453
|
+
const defaultProviderType = this.config.defaultProvider;
|
|
454
|
+
if (defaultProviderType && defaultProviderType !== decision.providerType) {
|
|
455
|
+
executionOrder.push({
|
|
456
|
+
provider: defaultProviderType,
|
|
457
|
+
model: this.config.defaultModel,
|
|
458
|
+
});
|
|
459
|
+
}
|
|
460
|
+
// Add explicit fallback chain entries. Previously this hardcoded
|
|
461
|
+
// ['claude', 'openai', 'ollama'] as "base providers" — but
|
|
462
|
+
// LLMProviderType includes 7 providers (claude/openai/ollama plus
|
|
463
|
+
// openrouter/gemini/azure-openai/bedrock from ADR-043) and
|
|
464
|
+
// ProviderManager.createProvider() builds all of them. The narrower
|
|
465
|
+
// list silently excluded users' actual fallback providers.
|
|
447
466
|
for (const entry of fallbackChain.entries) {
|
|
448
467
|
if (!entry.enabled)
|
|
449
468
|
continue;
|
|
450
469
|
if (entry.provider === decision.providerType)
|
|
451
470
|
continue;
|
|
452
|
-
// Only include providers that exist in the base system
|
|
453
|
-
const baseProviders = ['claude', 'openai', 'ollama'];
|
|
454
|
-
if (!baseProviders.includes(entry.provider))
|
|
455
|
-
continue;
|
|
456
471
|
for (const model of entry.models) {
|
|
457
472
|
executionOrder.push({ provider: entry.provider, model });
|
|
458
473
|
}
|
|
@@ -529,12 +544,19 @@ export class HybridRouter {
|
|
|
529
544
|
this.routerMetrics.recordFallback(providerType, nextProvider.provider, lastError.message, params.agentType);
|
|
530
545
|
}
|
|
531
546
|
}
|
|
532
|
-
//
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
//
|
|
537
|
-
|
|
547
|
+
// ADR-043 wiring fix: a non-retryable error from ONE provider
|
|
548
|
+
// (e.g. Claude returning "invalid x-api-key") tells us only that
|
|
549
|
+
// re-trying Claude is pointless — it does NOT tell us whether
|
|
550
|
+
// the NEXT provider in the fallback chain (e.g. Gemini) will
|
|
551
|
+
// work. Previously this `throw` short-circuited the fallback
|
|
552
|
+
// loop, defeating the whole point of having a fallback chain
|
|
553
|
+
// for users with multiple providers configured.
|
|
554
|
+
//
|
|
555
|
+
// New behavior: a non-retryable error skips the inter-attempt
|
|
556
|
+
// delay (because no need to wait) but DOES continue to the next
|
|
557
|
+
// entry in executionOrder. Only retryable errors get the delay.
|
|
558
|
+
const nonRetryable = isLLMError(error) && !error.retryable;
|
|
559
|
+
if (!nonRetryable && attempts < fallbackBehavior.maxAttempts) {
|
|
538
560
|
await this.delay(fallbackBehavior.delayMs);
|
|
539
561
|
}
|
|
540
562
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "agentic-qe",
|
|
3
|
-
"version": "3.10.
|
|
3
|
+
"version": "3.10.1",
|
|
4
4
|
"description": "Agentic Quality Engineering V3 - Domain-Driven Design Architecture with 13 Bounded Contexts, O(log n) coverage analysis, ReasoningBank learning, 60 specialized QE agents, mathematical Coherence verification, deep Claude Flow integration",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{createRequire as __cr}from"module";const require=__cr(import.meta.url);if(process.argv.includes('--version')||process.argv.includes('-v')){console.log("3.10.0");process.exit(0)}
|
|
2
|
-
import{a,b,c}from"./chunk-T7DLX3LS.js";import"./chunk-OGT45MZN.js";import"./chunk-TR7BZLB6.js";import"./chunk-OKGK7DBT.js";import"./chunk-KNL3QWVA.js";import"./chunk-55JPAF56.js";export{a as AgentBoosterAdapter,b as createAgentBoosterAdapter,c as createAgentBoosterAdapterSync};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{createRequire as __cr}from"module";const require=__cr(import.meta.url);if(process.argv.includes('--version')||process.argv.includes('-v')){console.log("3.10.0");process.exit(0)}
|
|
2
|
-
import{a,b,c,d,e,f}from"./chunk-OWMGD7FO.js";import"./chunk-5QJDH4Z5.js";import"./chunk-6H5MRVJS.js";import"./chunk-2GL4GH52.js";import"./chunk-C5QESAYA.js";import"./chunk-YHNEBCYQ.js";import"./chunk-WLLE54TA.js";import"./chunk-3OSCWD7Z.js";import"./chunk-F363JJUI.js";import"./chunk-VEOQH4W6.js";import"./chunk-LYVFC7C7.js";import"./chunk-U56TIYGP.js";import"./chunk-KCHFF4IE.js";import"./chunk-3BO7EKGO.js";import"./chunk-UE3XXKLN.js";import"./chunk-TEJPHJMW.js";import"./chunk-OKGK7DBT.js";import"./chunk-DXV6NRG3.js";import"./chunk-X73CRYF4.js";import"./chunk-BQT4J3BD.js";import"./chunk-FEBXP74Y.js";import"./chunk-KNL3QWVA.js";import"./chunk-MJBXQXSX.js";import"./chunk-ZCNVFULO.js";import"./chunk-QU54GUEA.js";import"./chunk-O3NAUNFC.js";import"./chunk-I4E6CLC4.js";import"./chunk-NT4PI5HI.js";import"./chunk-66GIKUI2.js";import"./chunk-SGONA5GS.js";import"./chunk-5UOV7T36.js";import"./chunk-KOSKGZK4.js";import"./chunk-55JPAF56.js";export{b as AQELearningEngine,a as DEFAULT_ENGINE_CONFIG,c as DEFAULT_META_LEARNING_CONFIG,d as MetaLearningEngine,e as createAQELearningEngine,f as createDefaultLearningEngine};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{createRequire as __cr}from"module";const require=__cr(import.meta.url);if(process.argv.includes('--version')||process.argv.includes('-v')){console.log("3.10.0");process.exit(0)}
|
|
2
|
-
import{a,b,c,d,e,f}from"./chunk-6MONUYQ5.js";import"./chunk-LQ3TA22E.js";import"./chunk-UE3XXKLN.js";import"./chunk-TEJPHJMW.js";import"./chunk-OKGK7DBT.js";import"./chunk-X73CRYF4.js";import"./chunk-BQT4J3BD.js";import"./chunk-KNL3QWVA.js";import"./chunk-MJBXQXSX.js";import"./chunk-ZCNVFULO.js";import"./chunk-QU54GUEA.js";import"./chunk-O3NAUNFC.js";import"./chunk-I4E6CLC4.js";import"./chunk-NT4PI5HI.js";import"./chunk-66GIKUI2.js";import"./chunk-SGONA5GS.js";import"./chunk-5UOV7T36.js";import"./chunk-KOSKGZK4.js";import"./chunk-55JPAF56.js";export{f as MCPToolBase,e as defaultToolLogger,d as getMemoryBackend,b as getSharedMemoryBackend,a as registerRvfResetFn,c as resetSharedMemoryBackend};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{createRequire as __cr}from"module";const require=__cr(import.meta.url);if(process.argv.includes('--version')||process.argv.includes('-v')){console.log("3.10.0");process.exit(0)}
|
|
2
|
-
import{a}from"./chunk-6F3WJOU2.js";import"./chunk-6MONUYQ5.js";import"./chunk-LQ3TA22E.js";import"./chunk-UE3XXKLN.js";import"./chunk-TEJPHJMW.js";import"./chunk-OKGK7DBT.js";import"./chunk-X73CRYF4.js";import"./chunk-BQT4J3BD.js";import"./chunk-KNL3QWVA.js";import"./chunk-MJBXQXSX.js";import"./chunk-ZCNVFULO.js";import"./chunk-QU54GUEA.js";import"./chunk-O3NAUNFC.js";import"./chunk-I4E6CLC4.js";import"./chunk-NT4PI5HI.js";import"./chunk-66GIKUI2.js";import"./chunk-SGONA5GS.js";import"./chunk-5UOV7T36.js";import"./chunk-KOSKGZK4.js";import"./chunk-55JPAF56.js";export{a as BrowserWorkflowTool};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{createRequire as __cr}from"module";const require=__cr(import.meta.url);if(process.argv.includes('--version')||process.argv.includes('-v')){console.log("3.10.0");process.exit(0)}
|
|
2
|
-
import{a as M}from"./chunk-LQ3TA22E.js";import{f as y,o as T}from"./chunk-UE3XXKLN.js";import{a as p,c as S}from"./chunk-KNL3QWVA.js";import{i as b}from"./chunk-MJBXQXSX.js";T();S();import*as c from"path";import*as d from"fs";var m=null,u=null,l=null;function R(o){l=o}async function P(){return m||u||(u=(async()=>{let o=y(),e=c.join(o,".agentic-qe");d.existsSync(e)||d.mkdirSync(e,{recursive:!0});let r=new M({sqlite:{path:c.join(e,"memory.db"),walMode:!0,poolSize:3,busyTimeout:5e3},enableFallback:!0,defaultNamespace:"mcp-tools"});return await r.initialize(),m=r,r})(),u)}function $(){if(l)try{l()}catch{}m&&(m.dispose().catch(()=>{}),m=null),u=null}async function D(o){return o?.memory?o.memory:P()}var C={info:(o,e)=>console.log(`[MCP-TOOL] ${o}`,e||""),warn:(o,e)=>console.warn(`[MCP-TOOL] \u26A0\uFE0F ${o}`,e||""),error:(o,e)=>console.error(`[MCP-TOOL] \u274C ${o}`,e||"")},h=class{logger=C;currentDataSource="real";setLogger(e){this.logger=e}markAsDemoData(e,r){this.currentDataSource=e.demoMode?"demo":"fallback",this.logger.warn(`${this.config.name} returning ${this.currentDataSource} data`,{reason:r,requestId:e.requestId,demoMode:e.demoMode})}markAsRealData(){this.currentDataSource="real"}isDemoMode(e){return e.demoMode===!0}validate(e){let r=[];if(typeof e!="object"||e===null)return{valid:!1,errors:["Parameters must be an object"]};let t=e,{properties:a,required:n}=this.config.schema;if(n)for(let i of n)i in t||r.push(`Missing required field: ${i}`);for(let[i,s]of Object.entries(t)){let g=a[i];if(!g)continue;let f=this.validateType(i,s,g);f&&r.push(f)}return{valid:r.length===0,errors:r}}validateType(e,r,t){if(r==null)return null;let a=Array.isArray(r)?"array":typeof r;if(t.type==="array"&&!Array.isArray(r))return`${e} must be an array`;if(t.type!=="array"&&a!==t.type)return`${e} must be of type ${t.type}, got ${a}`;if(t.enum&&!t.enum.includes(r))return`${e} must be one of: ${t.enum.join(", ")}`;if(t.type==="number"){let n=r;if(t.minimum!==void 0&&n<t.minimum)return`${e} must be >= ${t.minimum}`;if(t.maximum!==void 0&&n>t.maximum)return`${e} must be <= ${t.maximum}`}if(t.type==="string"){let n=r;if(t.minLength!==void 0&&n.length<t.minLength)return`${e} must be at least ${t.minLength} characters`;if(t.maxLength!==void 0&&n.length>t.maxLength)return`${e} must be at most ${t.maxLength} characters`}return null}async invoke(e,r={}){let t=Date.now(),a=b();this.currentDataSource="real";let n=this.validate(e);if(!n.valid)return{success:!1,error:`Validation failed: ${n.errors.join("; ")}`,metadata:this.createMetadata(t,a)};let i={requestId:a,startTime:t,streaming:r.streaming,onStream:r.onStream,abortSignal:r.abortSignal,demoMode:r.demoMode};try{let s=await this.execute(e,i);return{...s,metadata:{...s.metadata,...this.createMetadata(t,a)}}}catch(s){return{success:!1,error:p(s),metadata:this.createMetadata(t,a)}}}createMetadata(e,r){return{executionTime:Date.now()-e,timestamp:new Date().toISOString(),requestId:r,domain:this.config.domain,toolName:this.config.name,dataSource:this.currentDataSource}}emitStream(e,r){e.streaming&&e.onStream&&e.onStream(r)}isAborted(e){return e.abortSignal?.aborted??!1}get name(){return this.config.name}get description(){return this.config.description}get domain(){return this.config.domain}getSchema(){return this.config.schema}get timeout(){return this.config.timeout??6e4}get supportsStreaming(){return this.config.streaming??!1}resetInstanceCache(){}};export{R as a,P as b,$ as c,D as d,C as e,h as f};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{createRequire as __cr}from"module";const require=__cr(import.meta.url);if(process.argv.includes('--version')||process.argv.includes('-v')){console.log("3.10.0");process.exit(0)}
|
|
2
|
-
import{a as e,b as g,e as r}from"./chunk-BQT4J3BD.js";import{c as o}from"./chunk-55JPAF56.js";var L=o(()=>{"use strict";e();g();r()});export{L as a};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{createRequire as __cr}from"module";const require=__cr(import.meta.url);if(process.argv.includes('--version')||process.argv.includes('-v')){console.log("3.10.0");process.exit(0)}
|
|
2
|
-
import{c as a,d as b,e as c}from"./chunk-5RQT7EJP.js";import"./chunk-7Y54QZKF.js";import"./chunk-KNL3QWVA.js";import"./chunk-55JPAF56.js";c();export{a as VibiumClientImpl,b as VibiumClientProvider};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{createRequire as __cr}from"module";const require=__cr(import.meta.url);if(process.argv.includes('--version')||process.argv.includes('-v')){console.log("3.10.0");process.exit(0)}
|
|
2
|
-
import{a,b}from"./chunk-NLCUQMUR.js";import"./chunk-GPKZ4MMH.js";import"./chunk-FEBXP74Y.js";import"./chunk-MJBXQXSX.js";import"./chunk-55JPAF56.js";export{a as CrossDomainEventRouter,b as createCrossDomainRouter};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{createRequire as __cr}from"module";const require=__cr(import.meta.url);if(process.argv.includes('--version')||process.argv.includes('-v')){console.log("3.10.0");process.exit(0)}
|
|
2
|
-
import{b as a,c as b,d as c,e as d,f as e,g as f,h as g,i as h,j as i,k as j,l as k,m as l,n as m,o as n,p as o,q as p,r as q,s as r,t as s,u as t,v as u}from"./chunk-VMJXNTJT.js";import"./chunk-MF3XRML3.js";import"./chunk-OWMGD7FO.js";import"./chunk-5QJDH4Z5.js";import"./chunk-6H5MRVJS.js";import"./chunk-2GL4GH52.js";import"./chunk-C5QESAYA.js";import"./chunk-YHNEBCYQ.js";import"./chunk-WLLE54TA.js";import"./chunk-3OSCWD7Z.js";import"./chunk-F363JJUI.js";import"./chunk-VEOQH4W6.js";import"./chunk-LYVFC7C7.js";import"./chunk-U56TIYGP.js";import"./chunk-RH3PHCJT.js";import"./chunk-KCHFF4IE.js";import"./chunk-3BO7EKGO.js";import"./chunk-UE3XXKLN.js";import"./chunk-TEJPHJMW.js";import"./chunk-OKGK7DBT.js";import"./chunk-DXV6NRG3.js";import"./chunk-X73CRYF4.js";import"./chunk-BQT4J3BD.js";import"./chunk-FEBXP74Y.js";import"./chunk-KNL3QWVA.js";import"./chunk-MJBXQXSX.js";import"./chunk-ZCNVFULO.js";import"./chunk-QU54GUEA.js";import"./chunk-O3NAUNFC.js";import"./chunk-I4E6CLC4.js";import"./chunk-NT4PI5HI.js";import"./chunk-66GIKUI2.js";import"./chunk-SGONA5GS.js";import"./chunk-5UOV7T36.js";import"./chunk-KOSKGZK4.js";import"./chunk-55JPAF56.js";export{t as BUILT_IN_STRATEGIES,e as ConceptGraph,j as DEFAULT_ACTIVATION_CONFIG,d as DEFAULT_CONCEPT_GRAPH_CONFIG,p as DEFAULT_DREAM_CONFIG,a as DEFAULT_DREAM_SCHEDULER_CONFIG,l as DEFAULT_INSIGHT_CONFIG,n as DEFAULT_VALIDATION_THRESHOLDS,q as DreamEngine,b as DreamScheduler,i as HISTORY_TRIM_TARGET_RATIO,m as InsightGenerator,g as MAX_ACTIVATION_HISTORY_ENTRIES,h as MAX_COACTIVATION_ENTRIES,o as RVCOWBranchManager,u as SpeculativeDreamer,k as SpreadingActivation,f as createConceptGraph,r as createDreamEngine,c as createDreamScheduler,s as default};
|