agentic-qe 3.11.1 → 3.11.3
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/.validation/templates/eval.template.yaml +36 -0
- package/.claude/skills/qe-code-intelligence/SKILL.md +3 -0
- package/.claude/skills/qe-quality-assessment/SKILL.md +25 -0
- package/.claude/skills/qe-test-generation/SKILL.md +58 -20
- package/.claude/skills/qe-test-generation/evals/qe-test-generation.yaml +37 -0
- package/.claude/skills/skills-manifest.json +1 -1
- package/CHANGELOG.md +71 -0
- package/README.md +1 -0
- package/assets/skills/.validation/templates/eval.template.yaml +36 -0
- package/assets/skills/enterprise-integration-testing/SKILL.md +1 -1
- package/assets/skills/pentest-validation/SKILL.md +1 -1
- package/assets/skills/qcsd-development-swarm/SKILL.md +27 -6
- package/assets/skills/qe-code-intelligence/SKILL.md +3 -0
- package/assets/skills/qe-quality-assessment/SKILL.md +25 -0
- package/assets/skills/qe-test-generation/SKILL.md +58 -20
- package/assets/skills/qe-test-generation/evals/qe-test-generation.yaml +37 -0
- package/dist/cli/bundle.js +5 -5
- package/dist/cli/chunks/adapter-IU3H3MD7.js +2 -0
- package/dist/cli/chunks/{agent-booster-wasm-3OJAT664.js → agent-booster-wasm-BFRW7HEU.js} +2 -2
- package/dist/cli/chunks/{agent-handler-6TCTI5AT.js → agent-handler-ZVC3VFPC.js} +2 -2
- package/dist/cli/chunks/{agent-memory-branch-FAWCYEGJ.js → agent-memory-branch-3WU3CVSX.js} +2 -2
- package/dist/cli/chunks/aqe-learning-engine-BGOC63IN.js +2 -0
- package/dist/cli/chunks/{arena-UVYIGYUF.js → arena-JMVTWWG5.js} +2 -2
- package/dist/cli/chunks/{arena-O2TCUQBF.js → arena-QMRLNQUC.js} +4 -4
- package/dist/cli/chunks/{audit-AYESKHAJ.js → audit-TTWAAV7P.js} +2 -2
- package/dist/cli/chunks/base-DVPRE3WO.js +2 -0
- package/dist/cli/chunks/{hnswlib-node-FUWQTM2D.js → better-sqlite3-QNZJOJAB.js} +2 -2
- package/dist/cli/chunks/{brain-handler-KSJBVTHZ.js → brain-handler-FXPLJCPV.js} +3 -3
- package/dist/cli/chunks/{branch-enumerator-4O3S42EG.js → branch-enumerator-CJJG6X3I.js} +2 -2
- package/dist/cli/chunks/{browser-5VXK323P.js → browser-LI2CDWVR.js} +2 -2
- package/dist/cli/chunks/browser-workflow-MP5P7KZF.js +2 -0
- package/dist/cli/chunks/{chunk-ZKPOKMJZ.js → chunk-22CUJA33.js} +2 -2
- package/dist/cli/chunks/{chunk-N52WQO3G.js → chunk-242B625Q.js} +2 -2
- package/dist/cli/chunks/{chunk-T7PUM6OY.js → chunk-26KHL4VO.js} +1 -1
- package/dist/cli/chunks/{chunk-IIX5Y7BO.js → chunk-27MMZQ7X.js} +1 -1
- package/dist/cli/chunks/{chunk-FBOPSWF6.js → chunk-2OUXYSQV.js} +2 -2
- package/dist/cli/chunks/{chunk-AEZMNFXM.js → chunk-2SZQDTI5.js} +1 -1
- package/dist/cli/chunks/{chunk-44HXRFOP.js → chunk-36HTS4EP.js} +2 -2
- package/dist/cli/chunks/{chunk-3XCEFSUK.js → chunk-3BREKEL5.js} +2 -2
- package/dist/cli/chunks/{chunk-56PICCZN.js → chunk-3CBYKKRW.js} +2 -2
- package/dist/cli/chunks/{chunk-EJSDQQZH.js → chunk-3E3PSEC5.js} +2 -2
- package/dist/cli/chunks/{chunk-5PSIKJL5.js → chunk-3FOFPGHH.js} +2 -2
- package/dist/cli/chunks/{chunk-J2LAYCYZ.js → chunk-3XLGXCSX.js} +1 -1
- package/dist/cli/chunks/{chunk-YFY35CSD.js → chunk-4ITHKHR5.js} +2 -2
- package/dist/cli/chunks/{chunk-5QFZEEJ2.js → chunk-54TDOQAH.js} +3 -3
- package/dist/cli/chunks/{chunk-S7ZHD6VN.js → chunk-5746QYRF.js} +2 -2
- package/dist/cli/chunks/{chunk-4OYC5TIZ.js → chunk-5EW36WTI.js} +2 -2
- package/dist/cli/chunks/{chunk-C27UV6DO.js → chunk-6F43POT6.js} +1 -1
- package/dist/cli/chunks/{chunk-SU4YXUVK.js → chunk-6GVRP64A.js} +2 -2
- package/dist/cli/chunks/{chunk-SZPTUV3B.js → chunk-6IHB3T6M.js} +2 -2
- package/dist/cli/chunks/{chunk-CN2HMHIY.js → chunk-6JR2RSY2.js} +2 -2
- package/dist/cli/chunks/{chunk-VGR65B4Y.js → chunk-6KKKPVOF.js} +1 -1
- package/dist/cli/chunks/{chunk-C7FYDE5F.js → chunk-6WWNK67C.js} +125 -150
- package/dist/cli/chunks/{chunk-VRHLHGKR.js → chunk-77QJQRL2.js} +2 -2
- package/dist/cli/chunks/{chunk-W6RS5S4Q.js → chunk-7FVWETN4.js} +2 -2
- package/dist/cli/chunks/{chunk-X4GKYSOH.js → chunk-7PDUD7FF.js} +2 -2
- package/dist/cli/chunks/{chunk-V6YDM37M.js → chunk-7QIYYYUE.js} +1 -1
- package/dist/cli/chunks/{chunk-CII57TME.js → chunk-7S7QF4HJ.js} +1 -1
- package/dist/cli/chunks/{chunk-ILZHECWZ.js → chunk-7SBMTSGY.js} +3 -3
- package/dist/cli/chunks/{chunk-S7IHSELP.js → chunk-7UOH55UT.js} +2 -2
- package/dist/cli/chunks/{chunk-6ZAUNPAI.js → chunk-A43MKBSX.js} +2 -2
- package/dist/cli/chunks/{chunk-HMVL55QX.js → chunk-A4NYOH7P.js} +2 -2
- package/dist/cli/chunks/{chunk-OHBZON7T.js → chunk-ABD6JBNO.js} +1 -1
- package/dist/cli/chunks/{chunk-WIC5UZCQ.js → chunk-AC6OZTY4.js} +2 -2
- package/dist/cli/chunks/{chunk-LNV76GGB.js → chunk-AKOGQT3A.js} +2 -2
- package/dist/cli/chunks/{chunk-XMDZRULK.js → chunk-ATFADWGD.js} +2 -2
- package/dist/cli/chunks/{chunk-UDLN2THT.js → chunk-B65CRJN6.js} +1 -1
- package/dist/cli/chunks/{chunk-7DQLYWLR.js → chunk-B6USJW5E.js} +1 -1
- package/dist/cli/chunks/{chunk-NVJIOCS5.js → chunk-B7XPSXK6.js} +2 -2
- package/dist/cli/chunks/{chunk-IUVAWWQG.js → chunk-BA7PJS3Y.js} +2 -2
- package/dist/cli/chunks/{chunk-2RE32VOF.js → chunk-BFBZFUBP.js} +1 -1
- package/dist/cli/chunks/{chunk-KIBP3LGY.js → chunk-BHZI6PDR.js} +1 -1
- package/dist/cli/chunks/{chunk-EFRIMR74.js → chunk-BQ5EJPK3.js} +1 -1
- package/dist/cli/chunks/{chunk-3DS7ZHA7.js → chunk-CCDGNJZX.js} +2 -2
- package/dist/cli/chunks/{chunk-QOR4YAZY.js → chunk-CGKHG46K.js} +2 -2
- package/dist/cli/chunks/{chunk-3V5DAM37.js → chunk-CLZ5RQVA.js} +2 -2
- package/dist/cli/chunks/{chunk-H4V6WCF7.js → chunk-CYJ6O5VZ.js} +2 -2
- package/dist/cli/chunks/{chunk-X2OVUBF6.js → chunk-DNOBN3IR.js} +2 -2
- package/dist/cli/chunks/{chunk-AG4BYKUV.js → chunk-DPYNXEBC.js} +2 -2
- package/dist/cli/chunks/{chunk-76UVJLPM.js → chunk-DS7AZD26.js} +2 -2
- package/dist/cli/chunks/{chunk-7QICU44H.js → chunk-DZ7PWB6E.js} +2 -2
- package/dist/cli/chunks/{chunk-TOQJWLJV.js → chunk-DZZ4AJQI.js} +2 -2
- package/dist/cli/chunks/{chunk-N6RSJGTW.js → chunk-EBCUWMLX.js} +2 -2
- package/dist/cli/chunks/{chunk-FK3XYV3A.js → chunk-ECGASTG7.js} +2 -2
- package/dist/cli/chunks/{chunk-3IMEDZIS.js → chunk-ED7MD6OI.js} +3 -3
- package/dist/cli/chunks/{chunk-BOQNPFO5.js → chunk-EHEFI6LR.js} +1 -1
- package/dist/cli/chunks/{chunk-GUSW3OGX.js → chunk-EXCU4J7T.js} +1 -1
- package/dist/cli/chunks/{chunk-7GP7ZG3K.js → chunk-EZ4GKHSI.js} +2 -2
- package/dist/cli/chunks/{chunk-CZU5G6J4.js → chunk-FJRRXCIS.js} +1 -1
- package/dist/cli/chunks/{chunk-WEPZOCN7.js → chunk-FPKKKUWF.js} +1 -1
- package/dist/cli/chunks/{chunk-CIDTFU3C.js → chunk-FZLCKIPP.js} +2 -2
- package/dist/cli/chunks/{chunk-N6NSZG7Z.js → chunk-G6MPXBCD.js} +2 -2
- package/dist/cli/chunks/{chunk-KRUKMGPF.js → chunk-GBCDJJWH.js} +2 -2
- package/dist/cli/chunks/{chunk-72UPBNVF.js → chunk-GCIL7PK7.js} +2 -2
- package/dist/cli/chunks/{chunk-K3BBLIWW.js → chunk-H2YOWAEB.js} +2 -2
- package/dist/cli/chunks/{chunk-HOFEAA4R.js → chunk-H6YFMUFG.js} +1 -1
- package/dist/cli/chunks/{chunk-U5GCSSYX.js → chunk-H7Y43HBQ.js} +1 -1
- package/dist/cli/chunks/{chunk-6CH7476R.js → chunk-HRD5I7ES.js} +1 -1
- package/dist/cli/chunks/{chunk-LOPM3YIO.js → chunk-IJHPZMEQ.js} +2 -2
- package/dist/cli/chunks/{chunk-437XL5VZ.js → chunk-JVXPKHND.js} +2 -2
- package/dist/cli/chunks/{chunk-LSZLXLZA.js → chunk-JWTMVC6E.js} +2 -2
- package/dist/cli/chunks/{chunk-BVFNF3RW.js → chunk-KHUN65Q3.js} +1 -1
- package/dist/cli/chunks/{chunk-ATQTTGSE.js → chunk-KTYESESI.js} +2 -2
- package/dist/cli/chunks/{chunk-Z6ADE3KJ.js → chunk-KULBMV6K.js} +2 -2
- package/dist/cli/chunks/{chunk-H5GCRC2D.js → chunk-KXRI4MR3.js} +2 -2
- package/dist/cli/chunks/{chunk-VS2G6LX5.js → chunk-L44XXD3X.js} +2 -2
- package/dist/cli/chunks/{chunk-N4OWZLH5.js → chunk-L6PH7JIE.js} +2 -2
- package/dist/cli/chunks/{chunk-QEDS3MOJ.js → chunk-LGEZ3ZJX.js} +2 -2
- package/dist/cli/chunks/{chunk-QXDZN2WX.js → chunk-LKLWIP4Z.js} +1 -1
- package/dist/cli/chunks/{chunk-MX6M2VPB.js → chunk-LMA6KEZH.js} +1 -1
- package/dist/cli/chunks/{chunk-4565IIF6.js → chunk-LW5TUN5F.js} +2 -2
- package/dist/cli/chunks/{chunk-O5NF6BBD.js → chunk-MU36VPXV.js} +1 -1
- package/dist/cli/chunks/{chunk-3G25ZBQ6.js → chunk-MX5FMAY5.js} +1 -1
- package/dist/cli/chunks/{chunk-D4DAZ3P2.js → chunk-N2K2EQFH.js} +2 -2
- package/dist/cli/chunks/{chunk-5LDUW2FD.js → chunk-NBOEXSV2.js} +1 -1
- package/dist/cli/chunks/{chunk-5Y7GXQOM.js → chunk-NJ2RY4OL.js} +2 -2
- package/dist/cli/chunks/{chunk-PY4YQDBM.js → chunk-NWUVXLBB.js} +4 -4
- package/dist/cli/chunks/{chunk-JGHEGMLD.js → chunk-O7ZDQ5FF.js} +3 -3
- package/dist/cli/chunks/{chunk-OUSD2RWO.js → chunk-OCACCUFO.js} +2 -2
- package/dist/cli/chunks/{chunk-L2QHZFC3.js → chunk-OFMVC6P3.js} +1 -1
- package/dist/cli/chunks/{chunk-DZT4A7R3.js → chunk-OQGELUM2.js} +2 -2
- package/dist/cli/chunks/{chunk-O75SVMMB.js → chunk-OVEG5MEL.js} +2 -2
- package/dist/cli/chunks/{chunk-TUEDIQHY.js → chunk-P4UGVVVX.js} +1 -1
- package/dist/cli/chunks/{chunk-D6MPGK7R.js → chunk-PLQADRA6.js} +2 -2
- package/dist/cli/chunks/{chunk-OX2PGDUM.js → chunk-PMHSTMHV.js} +3 -3
- package/dist/cli/chunks/{chunk-QMN563LV.js → chunk-PSL53AQ4.js} +44 -44
- package/dist/cli/chunks/{chunk-7SRSOZMP.js → chunk-PUK5NE47.js} +1 -1
- package/dist/cli/chunks/{chunk-7OAKIXNM.js → chunk-PUUGIBFF.js} +2 -2
- package/dist/cli/chunks/{chunk-CXIFCN6G.js → chunk-PW4GGJMP.js} +1 -1
- package/dist/cli/chunks/{chunk-4RUS5E3Q.js → chunk-PY2Q6MN3.js} +6 -6
- package/dist/cli/chunks/{chunk-6YNXH6H4.js → chunk-Q2A2XQGF.js} +2 -2
- package/dist/cli/chunks/{chunk-4G4GTF36.js → chunk-QCCXH5DK.js} +4 -4
- package/dist/cli/chunks/{chunk-22FHOXEE.js → chunk-QPMISAWB.js} +1 -1
- package/dist/cli/chunks/{chunk-EQYDPF52.js → chunk-REZ2GZQ3.js} +1 -1
- package/dist/cli/chunks/{chunk-EZBXCEBV.js → chunk-RRSUW2TK.js} +2 -2
- package/dist/cli/chunks/{chunk-IVZVVZZ3.js → chunk-RWUGXU2K.js} +3 -3
- package/dist/cli/chunks/{chunk-BR4ERWVD.js → chunk-RXN5DWVM.js} +2 -2
- package/dist/cli/chunks/{chunk-XEVUW4QL.js → chunk-S2T2BXUL.js} +2 -2
- package/dist/cli/chunks/{chunk-IAHJ62JS.js → chunk-S7KDHA6P.js} +4 -4
- package/dist/cli/chunks/{chunk-6WNYBIPS.js → chunk-SFDBIO64.js} +2 -2
- package/dist/cli/chunks/{chunk-TCKBICJ3.js → chunk-SFGBC5RP.js} +2 -2
- package/dist/cli/chunks/{chunk-P7CMWL7Y.js → chunk-SIAJP3YA.js} +2 -2
- package/dist/cli/chunks/{chunk-QUTKELAS.js → chunk-SLU35IDJ.js} +2 -2
- package/dist/cli/chunks/{chunk-HYT5EMES.js → chunk-SMHYPPO6.js} +2 -2
- package/dist/cli/chunks/{chunk-BXLWERBR.js → chunk-SWRGPCZ2.js} +3 -3
- package/dist/cli/chunks/{chunk-B6U56VWG.js → chunk-UFZCHVLH.js} +1 -1
- package/dist/cli/chunks/{chunk-OUBYADPD.js → chunk-UMWYL37S.js} +2 -2
- package/dist/cli/chunks/chunk-UNH2DE2G.js +2 -0
- package/dist/cli/chunks/{chunk-S456W64P.js → chunk-UTGW75AZ.js} +2 -2
- package/dist/cli/chunks/{chunk-3D4HNUZM.js → chunk-VFEU4JM4.js} +2 -2
- package/dist/cli/chunks/{chunk-K7XPKGOL.js → chunk-VTDWQ7WI.js} +2 -2
- package/dist/cli/chunks/{chunk-4S3UIY3G.js → chunk-VUEYLW5P.js} +2 -2
- package/dist/cli/chunks/{chunk-B5EE63VE.js → chunk-WCVZHXWL.js} +2 -2
- package/dist/cli/chunks/{chunk-7WQKKYYG.js → chunk-WLLGPGQY.js} +1 -1
- package/dist/cli/chunks/{chunk-NKCL6RAF.js → chunk-WTKT2AD3.js} +2 -2
- package/dist/cli/chunks/{chunk-FOD6JEEU.js → chunk-WV66MXJI.js} +2 -2
- package/dist/cli/chunks/{chunk-ZRWAFMM7.js → chunk-WYJFVSEB.js} +2 -2
- package/dist/cli/chunks/{chunk-AL54LED5.js → chunk-XCSEJQXR.js} +2 -2
- package/dist/cli/chunks/{chunk-MILWEZSZ.js → chunk-XKUN5PDH.js} +3 -3
- package/dist/cli/chunks/{chunk-4BMPFEEG.js → chunk-YPRM6ZFL.js} +2 -2
- package/dist/cli/chunks/{chunk-4UHWZ47M.js → chunk-ZDPQB67L.js} +1 -1
- package/dist/cli/chunks/{chunk-NYWK7ZSX.js → chunk-ZM7WOA3K.js} +1 -1
- package/dist/cli/chunks/{ci-KTWY7BZT.js → ci-JW4O2J3W.js} +2 -2
- package/dist/cli/chunks/{ci-output-WOX6QBMS.js → ci-output-JNXJV4B2.js} +2 -2
- package/dist/cli/chunks/{circuit-breaker-6XKOSFIF.js → circuit-breaker-XDD4KUGR.js} +2 -2
- package/dist/cli/chunks/{claude-flow-setup-5JA4MNE4.js → claude-flow-setup-L6IZOGYZ.js} +2 -2
- package/dist/cli/chunks/client-ADCDBTEE.js +2 -0
- package/dist/cli/chunks/{cline-installer-Z2ANHEKW.js → cline-installer-PK5SMN2B.js} +2 -2
- package/dist/cli/chunks/code-ZDVX3SQH.js +58 -0
- package/dist/cli/chunks/{code-index-extractor-VV4OEPG7.js → code-index-extractor-VXZNKEU5.js} +2 -2
- package/dist/cli/chunks/{codex-installer-BP7Y2NYR.js → codex-installer-OXKSIX7H.js} +2 -2
- package/dist/cli/chunks/{completions-YULJQUF4.js → completions-VRFFK223.js} +8 -5
- package/dist/cli/chunks/{complexity-analyzer-D7XYPQ76.js → complexity-analyzer-FTIMV74J.js} +2 -2
- package/dist/cli/chunks/{continuedev-installer-E3L7UF72.js → continuedev-installer-KTYBBPN4.js} +2 -2
- package/dist/cli/chunks/{copilot-installer-5TRUMJC5.js → copilot-installer-WDC3YNUR.js} +2 -2
- package/dist/cli/chunks/core-handlers-HCACMLUW.js +2 -0
- package/dist/cli/chunks/{cost-tracker-QTYSJMSV.js → cost-tracker-6MH4H33B.js} +2 -2
- package/dist/cli/chunks/{coverage-D5DKZ3XT.js → coverage-NHATLNS4.js} +3 -3
- package/dist/cli/chunks/cross-domain-router-HXFQAU4M.js +2 -0
- package/dist/cli/chunks/{cursor-installer-UDBHGUIG.js → cursor-installer-VQSUJDFB.js} +2 -2
- package/dist/cli/chunks/{daemon-2GXYN7F7.js → daemon-3VAOEKQW.js} +3 -3
- package/dist/cli/chunks/{daemon-IVWUMQKL.js → daemon-ZSK6CLQR.js} +4 -4
- package/dist/cli/chunks/{dag-attention-scheduler-PWXR4QTU.js → dag-attention-scheduler-HZ6OGYIH.js} +2 -2
- package/dist/cli/chunks/{detect-C6P7ONFB.js → detect-CGU3SC63.js} +2 -2
- package/dist/cli/chunks/{dist-node-2BUFM2JK.js → dist-node-DIBQ7PTA.js} +2 -2
- package/dist/cli/chunks/{domain-handler-Q2GWZLDM.js → domain-handler-DCMGAYXS.js} +2 -2
- package/dist/cli/chunks/{domain-transfer-GMUBAM3J.js → domain-transfer-UWFKBZTJ.js} +2 -2
- package/dist/cli/chunks/dream-SVWQH62A.js +2 -0
- package/dist/cli/chunks/{embed-and-insert-pattern-EFUERRM2.js → embed-and-insert-pattern-7247LAU3.js} +2 -2
- package/dist/cli/chunks/{eval-24FIC43F.js → eval-6KR7TFOK.js} +2 -2
- package/dist/cli/chunks/{experience-capture-middleware-R4UP2Q2M.js → experience-capture-middleware-IIOR6RVV.js} +3 -3
- package/dist/cli/chunks/{fast-paths-RQCGGTXB.js → fast-paths-M7OGD4ZI.js} +2 -2
- package/dist/cli/chunks/{feature-flags-SOXVYIBN.js → feature-flags-GGUXHRJI.js} +2 -2
- package/dist/cli/chunks/{feature-flags-APTWWVNQ.js → feature-flags-U75KFIGH.js} +2 -2
- package/dist/cli/chunks/{file-discovery-66KRMXVF.js → file-discovery-V52AYEB7.js} +2 -2
- package/dist/cli/chunks/{fleet-EMBNKO5Q.js → fleet-2UH72CK4.js} +3 -3
- package/dist/cli/chunks/{gnn-wrapper-6TKDWFJF.js → gnn-wrapper-J2GDLT3P.js} +2 -2
- package/dist/cli/chunks/{heartbeat-handler-4ODKJ75H.js → heartbeat-handler-QIDQHRXT.js} +4 -4
- package/dist/cli/chunks/heartbeat-scheduler-QW5TW5QS.js +2 -0
- package/dist/cli/chunks/hnsw-adapter-D6EJWYAL.js +2 -0
- package/dist/cli/chunks/hnsw-index-4MWR4U5W.js +2 -0
- package/dist/cli/chunks/{hnsw-legacy-bridge-25KFCLUC.js → hnsw-legacy-bridge-IU62PIY5.js} +2 -2
- package/dist/cli/chunks/{better-sqlite3-MJNUEPYB.js → hnswlib-node-EBRXKEX5.js} +2 -2
- package/dist/cli/chunks/{hooks-JIDA2COE.js → hooks-ZI4D3ATS.js} +10 -10
- package/dist/cli/chunks/hybrid-router-BYVUBHER.js +2 -0
- package/dist/cli/chunks/{hypergraph-engine-3YDFDPE3.js → hypergraph-engine-6JEERAGA.js} +2 -2
- package/dist/cli/chunks/{hypergraph-handler-VWZX2OJX.js → hypergraph-handler-YMDGYCB6.js} +3 -3
- package/dist/cli/chunks/impact-analyzer-OK2UIMSG.js +2 -0
- package/dist/cli/chunks/{init-handler-DH7VQAMF.js → init-handler-N57NW3QI.js} +6 -6
- package/dist/cli/chunks/init-wizard-6NNPNS6J.js +2 -0
- package/dist/cli/chunks/kernel-F4A4GRNO.js +2 -0
- package/dist/cli/chunks/{kilocode-installer-2W2KZCGH.js → kilocode-installer-7ABTGXJ5.js} +2 -2
- package/dist/cli/chunks/{kiro-installer-E5KP7OMD.js → kiro-installer-2JFOHLVI.js} +2 -2
- package/dist/cli/chunks/knowledge-graph-MSJDEZCF.js +2 -0
- package/dist/cli/chunks/{learning-XJRUVPLF.js → learning-3P3ZXRGD.js} +3 -3
- package/dist/cli/chunks/{llm-router-AEEKEMF5.js → llm-router-AWB2KHDW.js} +4 -4
- package/dist/cli/chunks/llm-router-service-27IQAO7G.js +2 -0
- package/dist/cli/chunks/{load-PZ4YOTBJ.js → load-GGVBCBGX.js} +2 -2
- package/dist/cli/chunks/load-test-TT5VLAN7.js +2 -0
- package/dist/cli/chunks/{mcp-IVA6LC2S.js → mcp-33NHIBN3.js} +2 -2
- package/dist/cli/chunks/{memory-Y3DHXFQE.js → memory-IVAQS4OW.js} +5 -5
- package/dist/cli/chunks/memory-backend-FVSK53IM.js +2 -0
- package/dist/cli/chunks/{memory-handlers-V5PXEJWL.js → memory-handlers-OPUDOZNT.js} +2 -2
- package/dist/cli/chunks/{multi-model-executor-646G4S4Y.js → multi-model-executor-NWQY6IN2.js} +2 -2
- package/dist/cli/chunks/{opencode-installer-P6KOOTUS.js → opencode-installer-FBB4JOEV.js} +2 -2
- package/dist/cli/chunks/{orchestrator-T2GVKYMX.js → orchestrator-GDAXR7DH.js} +5 -5
- package/dist/cli/chunks/pattern-null-store-7MVEDWCY.js +2 -0
- package/dist/cli/chunks/{pipeline-CK2ON45P.js → pipeline-VIKAOIBE.js} +2 -2
- package/dist/cli/chunks/{platform-OQNSD3A3.js → platform-FFVP36LH.js} +2 -2
- package/dist/cli/chunks/{plugin-UOG6RNRM.js → plugin-TI6QOLXH.js} +2 -2
- package/dist/cli/chunks/{prime-radiant-advanced-wasm-37UE6TG5.js → prime-radiant-advanced-wasm-AZRNI2OL.js} +2 -2
- package/dist/cli/chunks/protocol-executor-BLDDYEJ4.js +2 -0
- package/dist/cli/chunks/{protocol-handler-V722S6YH.js → protocol-handler-J4EA34B3.js} +2 -2
- package/dist/cli/chunks/{prove-ANGY6W3W.js → prove-ADVRMAWS.js} +2 -2
- package/dist/cli/chunks/provider-manager-ZYCFRYZQ.js +2 -0
- package/dist/cli/chunks/qe-reasoning-bank-P66CCPHM.js +2 -0
- package/dist/cli/chunks/{quality-KG4ALI2L.js → quality-GB5SJFSD.js} +2 -2
- package/dist/cli/chunks/queen-coordinator-LPHT3SX5.js +2 -0
- package/dist/cli/chunks/{real-embeddings-GUZDO5UN.js → real-embeddings-GDRJ4XSH.js} +2 -2
- package/dist/cli/chunks/{roocode-installer-WROAR6MJ.js → roocode-installer-Q6EISUDV.js} +2 -2
- package/dist/cli/chunks/router-XQ2TERUT.js +2 -0
- package/dist/cli/chunks/routing-feedback-K52O752B.js +2 -0
- package/dist/cli/chunks/{routing-handler-UFPSSS5D.js → routing-handler-RO4RTRAG.js} +2 -2
- package/dist/cli/chunks/{ruvector-commands-XJQMKDRM.js → ruvector-commands-FFIHCGVQ.js} +2 -2
- package/dist/cli/chunks/{rvf-dual-writer-QPRMDKYX.js → rvf-dual-writer-JGEK3A5Y.js} +2 -2
- package/dist/cli/chunks/{rvf-migration-adapter-SOHBK23K.js → rvf-migration-adapter-OVYC4QM6.js} +2 -2
- package/dist/cli/chunks/{rvf-migration-coordinator-MTWUSPEJ.js → rvf-migration-coordinator-U6L77QTS.js} +2 -2
- package/dist/cli/chunks/rvf-native-adapter-G4DV7FK3.js +2 -0
- package/dist/cli/chunks/safe-db-TMSEITES.js +2 -0
- package/dist/cli/chunks/schedule-RWFLA43O.js +2 -0
- package/dist/cli/chunks/scheduler-2V55MJJR.js +2 -0
- package/dist/cli/chunks/{security-5MAMQKP6.js → security-QPQIDAIL.js} +3 -3
- package/dist/cli/chunks/{shared-rvf-adapter-YEUBSRNN.js → shared-rvf-adapter-JRJTI4UD.js} +2 -2
- package/dist/cli/chunks/{shared-rvf-dual-writer-DBQJHG42.js → shared-rvf-dual-writer-DSHGURDA.js} +2 -2
- package/dist/cli/chunks/sqlite-persistence-L7QM6IWF.js +2 -0
- package/dist/cli/chunks/{status-handler-ZUB2UKQZ.js → status-handler-SBT3MZTX.js} +2 -2
- package/dist/cli/chunks/{structural-health-B2GHENWX.js → structural-health-UVECCN7U.js} +2 -2
- package/dist/cli/chunks/{sync-7VMXJTR2.js → sync-XXIGTGCG.js} +2 -2
- package/dist/cli/chunks/{sync-YCUUW3IP.js → sync-ZLZ4CZFJ.js} +2 -2
- package/dist/cli/chunks/{task-handler-N7LJTXZM.js → task-handler-73YAVOKJ.js} +2 -2
- package/dist/cli/chunks/{task-handlers-GDHNJV2E.js → task-handlers-PKECV27D.js} +3 -3
- package/dist/cli/chunks/{test-6COGC5KI.js → test-U3SXW4SV.js} +4 -4
- package/dist/cli/chunks/{test-scheduling-CUERHJMF.js → test-scheduling-POJND3GV.js} +3 -3
- package/dist/cli/chunks/{token-bootstrap-JTGSL6PP.js → token-bootstrap-ICX6SIXJ.js} +2 -2
- package/dist/cli/chunks/{token-usage-LSG3JYGX.js → token-usage-WCHJUVGT.js} +2 -2
- package/dist/cli/chunks/{transformers-ODIITRCT.js → transformers-L77UIHIY.js} +2 -2
- package/dist/cli/chunks/{tree-sitter-wasm-parser-KSP7ZZ5H.js → tree-sitter-wasm-parser-CVAXURQP.js} +2 -2
- package/dist/cli/chunks/{types-6N6SUU2O.js → types-LNVJBDM2.js} +2 -2
- package/dist/cli/chunks/unified-memory-ZSULA46X.js +2 -0
- package/dist/cli/chunks/unified-memory-hnsw-SQEWFUBN.js +2 -0
- package/dist/cli/chunks/unified-persistence-EDCTT6SE.js +2 -0
- package/dist/cli/chunks/{upgrade-7SCVOCPS.js → upgrade-4ND5RQFY.js} +2 -2
- package/dist/cli/chunks/{validate-762ISH2Y.js → validate-ZA4XT6K2.js} +2 -2
- package/dist/cli/chunks/{validate-swarm-R6WYYXGO.js → validate-swarm-FNK3GCJ4.js} +2 -2
- package/dist/cli/chunks/{vibium-5GZYSUDQ.js → vibium-E2CK2GBQ.js} +2 -2
- package/dist/cli/chunks/visual-security-SOGAETFP.js +2 -0
- package/dist/cli/chunks/{web-tree-sitter-VYYVAJTY.js → web-tree-sitter-63VRNKZV.js} +2 -2
- package/dist/cli/chunks/{windsurf-installer-RRIOR3B6.js → windsurf-installer-5BTCVOLH.js} +2 -2
- package/dist/cli/chunks/{witness-chain-SRVBEKDB.js → witness-chain-6CUUGISD.js} +2 -2
- package/dist/cli/chunks/witness-chain-AJCECBH5.js +2 -0
- package/dist/cli/chunks/{workflow-XNUDHGEC.js → workflow-V7ED22XT.js} +4 -4
- package/dist/cli/chunks/workflow-orchestrator-UXRUCOZR.js +2 -0
- package/dist/cli/chunks/{wrappers-3STST7QW.js → wrappers-7S3NTTLW.js} +2 -2
- package/dist/cli/commands/code.js +78 -2
- package/dist/cli/completions/index.js +4 -1
- package/dist/domains/code-intelligence/coordinator.js +8 -4
- package/dist/domains/code-intelligence/services/c4-model/from-detected.d.ts +41 -0
- package/dist/domains/code-intelligence/services/c4-model/from-detected.js +152 -0
- package/dist/domains/code-intelligence/services/c4-model/kg-relationships.d.ts +71 -0
- package/dist/domains/code-intelligence/services/c4-model/kg-relationships.js +87 -0
- package/dist/domains/code-intelligence/services/knowledge-graph.d.ts +6 -0
- package/dist/domains/code-intelligence/services/knowledge-graph.js +3 -3
- package/dist/domains/code-intelligence/services/product-factors-bridge.d.ts +26 -5
- package/dist/domains/code-intelligence/services/product-factors-bridge.js +72 -65
- package/dist/feedback/regenerability-gate.d.ts +70 -0
- package/dist/feedback/regenerability-gate.js +91 -0
- package/dist/mcp/bundle.js +429 -454
- package/dist/mcp/tools/code-intelligence/c4.d.ts +56 -0
- package/dist/mcp/tools/code-intelligence/c4.js +145 -0
- package/dist/mcp/tools/index.d.ts +1 -0
- package/dist/mcp/tools/index.js +1 -0
- package/dist/mcp/tools/registry.d.ts +1 -0
- package/dist/mcp/tools/registry.js +3 -0
- package/dist/shared/c4-model/confidence.d.ts +38 -0
- package/dist/shared/c4-model/confidence.js +69 -0
- package/dist/shared/c4-model/index.d.ts +4 -0
- package/dist/shared/c4-model/index.js +1 -0
- package/dist/shared/llm/providers/gemini.js +16 -10
- package/dist/shared/llm/providers/openrouter.js +20 -20
- package/dist/validation/conservation-guard.d.ts +39 -0
- package/dist/validation/conservation-guard.js +54 -0
- package/dist/validation/oracle-eval.d.ts +46 -0
- package/dist/validation/oracle-eval.js +108 -0
- package/dist/validation/skill-parity.d.ts +58 -0
- package/dist/validation/skill-parity.js +94 -0
- package/dist/validation/test-gen-prompt.d.ts +10 -0
- package/dist/validation/test-gen-prompt.js +26 -0
- package/package.json +8 -1
- package/dist/cli/chunks/adapter-A6GCBONS.js +0 -2
- package/dist/cli/chunks/aqe-learning-engine-FRCSXNMG.js +0 -2
- package/dist/cli/chunks/base-CZ3EHBU5.js +0 -2
- package/dist/cli/chunks/browser-workflow-EKTGQQBQ.js +0 -2
- package/dist/cli/chunks/chunk-57WGS6BI.js +0 -2
- package/dist/cli/chunks/client-X3KUJ6R5.js +0 -2
- package/dist/cli/chunks/code-NO4ZKNDU.js +0 -39
- package/dist/cli/chunks/core-handlers-A2EQB3UH.js +0 -2
- package/dist/cli/chunks/cross-domain-router-OKZ2PDHT.js +0 -2
- package/dist/cli/chunks/dream-ZBP4Z5C3.js +0 -2
- package/dist/cli/chunks/heartbeat-scheduler-6JUWQXWG.js +0 -2
- package/dist/cli/chunks/hnsw-adapter-JT4BU7XJ.js +0 -2
- package/dist/cli/chunks/hnsw-index-JC5YELJX.js +0 -2
- package/dist/cli/chunks/hybrid-router-SLTXHUFG.js +0 -2
- package/dist/cli/chunks/impact-analyzer-JXHCMZXY.js +0 -2
- package/dist/cli/chunks/init-wizard-EX37TYOG.js +0 -2
- package/dist/cli/chunks/kernel-JPHAG27D.js +0 -2
- package/dist/cli/chunks/knowledge-graph-5QJZIRYB.js +0 -2
- package/dist/cli/chunks/llm-router-service-SE2RO4P5.js +0 -2
- package/dist/cli/chunks/load-test-LOTBWIIS.js +0 -2
- package/dist/cli/chunks/memory-backend-BSDKTFAN.js +0 -2
- package/dist/cli/chunks/pattern-null-store-LRSXCZWM.js +0 -2
- package/dist/cli/chunks/protocol-executor-WPUVJEL7.js +0 -2
- package/dist/cli/chunks/provider-manager-EVPWSH3E.js +0 -2
- package/dist/cli/chunks/qe-reasoning-bank-IH63FG33.js +0 -2
- package/dist/cli/chunks/queen-coordinator-TTCAGYQO.js +0 -2
- package/dist/cli/chunks/router-64Q4ILOQ.js +0 -2
- package/dist/cli/chunks/routing-feedback-KCZV4XXC.js +0 -2
- package/dist/cli/chunks/rvf-native-adapter-GNJKMURU.js +0 -2
- package/dist/cli/chunks/safe-db-6VBZQIJI.js +0 -2
- package/dist/cli/chunks/schedule-4V7O5IPX.js +0 -2
- package/dist/cli/chunks/scheduler-CQDMHEHN.js +0 -2
- package/dist/cli/chunks/sqlite-persistence-7DHUFTHL.js +0 -2
- package/dist/cli/chunks/unified-memory-MQA72NLP.js +0 -2
- package/dist/cli/chunks/unified-memory-hnsw-K7HA3CWV.js +0 -2
- package/dist/cli/chunks/unified-persistence-2DXB4OE4.js +0 -2
- package/dist/cli/chunks/visual-security-UD6CARIJ.js +0 -2
- package/dist/cli/chunks/witness-chain-LWALPPMC.js +0 -2
- package/dist/cli/chunks/workflow-orchestrator-QU652FLH.js +0 -2
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Agentic QE v3 - C4 Architecture MCP Tool (ADR-112)
|
|
3
|
+
*
|
|
4
|
+
* qe/code/c4 - Generate C4 architecture diagrams (Context/Container/Component,
|
|
5
|
+
* Mermaid) from codebase analysis, plus semantic search over stored diagrams.
|
|
6
|
+
*
|
|
7
|
+
* Wraps the SAME pipeline the CLI `aqe code c4` drives:
|
|
8
|
+
* ProductFactorsBridgeService (detect) → C4ModelService (render+store) →
|
|
9
|
+
* deterministic confidence gate. This keeps MCP-CLI parity by construction.
|
|
10
|
+
*/
|
|
11
|
+
import { MCPToolBase, MCPToolConfig, MCPToolContext } from '../base';
|
|
12
|
+
import { ToolResult } from '../../types';
|
|
13
|
+
import type { C4Diagrams, C4ConfidenceAssessment } from '../../../shared/c4-model';
|
|
14
|
+
export type C4Level = 'context' | 'container' | 'component' | 'all';
|
|
15
|
+
export interface CodeC4Params {
|
|
16
|
+
action: 'generate' | 'search';
|
|
17
|
+
projectPath?: string;
|
|
18
|
+
level?: C4Level;
|
|
19
|
+
query?: string;
|
|
20
|
+
limit?: number;
|
|
21
|
+
[key: string]: unknown;
|
|
22
|
+
}
|
|
23
|
+
export interface C4GenerateResult {
|
|
24
|
+
diagrams: C4Diagrams;
|
|
25
|
+
confidence?: C4ConfidenceAssessment;
|
|
26
|
+
componentsDetected: number;
|
|
27
|
+
externalSystemsDetected: number;
|
|
28
|
+
relationshipsDetected: number;
|
|
29
|
+
circularDependencies: number;
|
|
30
|
+
}
|
|
31
|
+
export interface C4SearchHit {
|
|
32
|
+
key: string;
|
|
33
|
+
type: 'context' | 'container' | 'component';
|
|
34
|
+
title: string;
|
|
35
|
+
score: number;
|
|
36
|
+
preview: string;
|
|
37
|
+
}
|
|
38
|
+
export interface C4SearchResult {
|
|
39
|
+
results: C4SearchHit[];
|
|
40
|
+
total: number;
|
|
41
|
+
}
|
|
42
|
+
export interface CodeC4Result {
|
|
43
|
+
action: string;
|
|
44
|
+
generateResult?: C4GenerateResult;
|
|
45
|
+
searchResult?: C4SearchResult;
|
|
46
|
+
}
|
|
47
|
+
export declare class CodeC4Tool extends MCPToolBase<CodeC4Params, CodeC4Result> {
|
|
48
|
+
readonly config: MCPToolConfig;
|
|
49
|
+
private bridge;
|
|
50
|
+
private searchService;
|
|
51
|
+
private getBridge;
|
|
52
|
+
/** Embeddings ON here so stored diagrams are semantically searchable. */
|
|
53
|
+
private getSearchService;
|
|
54
|
+
execute(params: CodeC4Params, context: MCPToolContext): Promise<ToolResult<CodeC4Result>>;
|
|
55
|
+
}
|
|
56
|
+
//# sourceMappingURL=c4.d.ts.map
|
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Agentic QE v3 - C4 Architecture MCP Tool (ADR-112)
|
|
3
|
+
*
|
|
4
|
+
* qe/code/c4 - Generate C4 architecture diagrams (Context/Container/Component,
|
|
5
|
+
* Mermaid) from codebase analysis, plus semantic search over stored diagrams.
|
|
6
|
+
*
|
|
7
|
+
* Wraps the SAME pipeline the CLI `aqe code c4` drives:
|
|
8
|
+
* ProductFactorsBridgeService (detect) → C4ModelService (render+store) →
|
|
9
|
+
* deterministic confidence gate. This keeps MCP-CLI parity by construction.
|
|
10
|
+
*/
|
|
11
|
+
import { MCPToolBase, getSharedMemoryBackend } from '../base';
|
|
12
|
+
import { ProductFactorsBridgeService } from '../../../domains/code-intelligence/services/product-factors-bridge';
|
|
13
|
+
import { C4ModelService } from '../../../domains/code-intelligence/services/c4-model';
|
|
14
|
+
import { KnowledgeGraphService } from '../../../domains/code-intelligence/services/knowledge-graph';
|
|
15
|
+
import { createKnowledgeGraphRelationshipResolver } from '../../../domains/code-intelligence/services/c4-model/kg-relationships';
|
|
16
|
+
import { InMemoryEventBus } from '../../../kernel/event-bus';
|
|
17
|
+
import { toErrorMessage } from '../../../shared/error-utils.js';
|
|
18
|
+
const want = (level, l) => level === 'all' || level === l;
|
|
19
|
+
// ============================================================================
|
|
20
|
+
// Tool Implementation
|
|
21
|
+
// ============================================================================
|
|
22
|
+
export class CodeC4Tool extends MCPToolBase {
|
|
23
|
+
config = {
|
|
24
|
+
name: 'qe/code/c4',
|
|
25
|
+
description: 'Generate C4 architecture diagrams (Context/Container/Component, Mermaid) from a codebase with a deterministic confidence gate, or semantically search previously generated diagrams.',
|
|
26
|
+
domain: 'code-intelligence',
|
|
27
|
+
schema: CODE_C4_SCHEMA,
|
|
28
|
+
streaming: false,
|
|
29
|
+
timeout: 300000,
|
|
30
|
+
};
|
|
31
|
+
bridge = null;
|
|
32
|
+
searchService = null;
|
|
33
|
+
async getBridge(context) {
|
|
34
|
+
if (!this.bridge) {
|
|
35
|
+
const memory = context.memory ?? (await getSharedMemoryBackend());
|
|
36
|
+
// ADR-112 C2: KG-backed resolver (project-scoped) so MCP matches the CLI.
|
|
37
|
+
// publishEvents:false — the MCP path doesn't need the cross-domain event.
|
|
38
|
+
this.bridge = new ProductFactorsBridgeService(new InMemoryEventBus(), memory, {
|
|
39
|
+
publishEvents: false,
|
|
40
|
+
// ADR-112: embed generated diagrams so `search` can find them.
|
|
41
|
+
enableC4Embeddings: true,
|
|
42
|
+
relationshipResolver: createKnowledgeGraphRelationshipResolver((projectPath) => new KnowledgeGraphService(memory, { basePath: projectPath })),
|
|
43
|
+
});
|
|
44
|
+
}
|
|
45
|
+
return this.bridge;
|
|
46
|
+
}
|
|
47
|
+
/** Embeddings ON here so stored diagrams are semantically searchable. */
|
|
48
|
+
async getSearchService(context) {
|
|
49
|
+
if (!this.searchService) {
|
|
50
|
+
const memory = context.memory ?? (await getSharedMemoryBackend());
|
|
51
|
+
this.searchService = new C4ModelService(memory, { enableEmbeddings: true });
|
|
52
|
+
}
|
|
53
|
+
return this.searchService;
|
|
54
|
+
}
|
|
55
|
+
async execute(params, context) {
|
|
56
|
+
const { action, projectPath = '.', level = 'all', query, limit = 10 } = params;
|
|
57
|
+
try {
|
|
58
|
+
if (this.isAborted(context)) {
|
|
59
|
+
return { success: false, error: 'Operation aborted' };
|
|
60
|
+
}
|
|
61
|
+
const result = { action };
|
|
62
|
+
switch (action) {
|
|
63
|
+
case 'generate': {
|
|
64
|
+
const bridge = await this.getBridge(context);
|
|
65
|
+
const res = await bridge.requestC4Diagrams({
|
|
66
|
+
projectPath,
|
|
67
|
+
includeContext: want(level, 'context'),
|
|
68
|
+
includeContainer: want(level, 'container'),
|
|
69
|
+
includeComponent: want(level, 'component'),
|
|
70
|
+
includeDependency: level === 'all',
|
|
71
|
+
analyzeComponents: true,
|
|
72
|
+
detectExternalSystems: true,
|
|
73
|
+
analyzeCoupling: true,
|
|
74
|
+
});
|
|
75
|
+
if (!res.success) {
|
|
76
|
+
return { success: false, error: toErrorMessage(res.error) };
|
|
77
|
+
}
|
|
78
|
+
const c4 = res.value;
|
|
79
|
+
result.generateResult = {
|
|
80
|
+
diagrams: c4.diagrams,
|
|
81
|
+
confidence: c4.metadata.analysisMetadata?.confidence,
|
|
82
|
+
componentsDetected: c4.components.length,
|
|
83
|
+
externalSystemsDetected: c4.externalSystems.length,
|
|
84
|
+
relationshipsDetected: c4.relationships.length,
|
|
85
|
+
circularDependencies: (c4.couplingAnalysis ?? []).filter((co) => co.isCircular).length,
|
|
86
|
+
};
|
|
87
|
+
break;
|
|
88
|
+
}
|
|
89
|
+
case 'search': {
|
|
90
|
+
if (!query) {
|
|
91
|
+
return { success: false, error: 'Query is required for search action' };
|
|
92
|
+
}
|
|
93
|
+
const service = await this.getSearchService(context);
|
|
94
|
+
const res = await service.searchDiagrams(query, limit);
|
|
95
|
+
if (!res.success) {
|
|
96
|
+
return { success: false, error: toErrorMessage(res.error) };
|
|
97
|
+
}
|
|
98
|
+
result.searchResult = {
|
|
99
|
+
results: res.value.map((r) => ({ key: r.key, type: r.type, title: r.title, score: r.score, preview: r.preview })),
|
|
100
|
+
total: res.value.length,
|
|
101
|
+
};
|
|
102
|
+
break;
|
|
103
|
+
}
|
|
104
|
+
default:
|
|
105
|
+
return { success: false, error: `Unknown action: ${action}` };
|
|
106
|
+
}
|
|
107
|
+
return { success: true, data: result };
|
|
108
|
+
}
|
|
109
|
+
catch (error) {
|
|
110
|
+
return { success: false, error: toErrorMessage(error) };
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
// ============================================================================
|
|
115
|
+
// Schema
|
|
116
|
+
// ============================================================================
|
|
117
|
+
const CODE_C4_SCHEMA = {
|
|
118
|
+
type: 'object',
|
|
119
|
+
properties: {
|
|
120
|
+
action: {
|
|
121
|
+
type: 'string',
|
|
122
|
+
description: 'C4 action to perform',
|
|
123
|
+
enum: ['generate', 'search'],
|
|
124
|
+
},
|
|
125
|
+
projectPath: {
|
|
126
|
+
type: 'string',
|
|
127
|
+
description: 'Project root to analyze (generate action). Defaults to the current directory.',
|
|
128
|
+
},
|
|
129
|
+
level: {
|
|
130
|
+
type: 'string',
|
|
131
|
+
description: 'C4 level to generate (generate action)',
|
|
132
|
+
enum: ['context', 'container', 'component', 'all'],
|
|
133
|
+
},
|
|
134
|
+
query: {
|
|
135
|
+
type: 'string',
|
|
136
|
+
description: 'Semantic search query over stored diagrams (search action)',
|
|
137
|
+
},
|
|
138
|
+
limit: {
|
|
139
|
+
type: 'number',
|
|
140
|
+
description: 'Max search results (search action)',
|
|
141
|
+
},
|
|
142
|
+
},
|
|
143
|
+
required: ['action'],
|
|
144
|
+
};
|
|
145
|
+
//# sourceMappingURL=c4.js.map
|
|
@@ -37,6 +37,7 @@ export { DefectPredictTool, type DefectPredictParams, type DefectPredictResult,
|
|
|
37
37
|
export { RequirementsValidateTool, type RequirementsValidateParams, type RequirementsValidateResult, type RequirementInput, type ValidationResult, type TestabilityScore, type BDDScenario, } from './requirements-validation/validate';
|
|
38
38
|
export { QualityCriteriaTool, qualityCriteriaTool, type QualityCriteriaParams, type QualityCriteriaResult, type EvidencePointInput, type AgentInvocation, } from './requirements-validation/quality-criteria';
|
|
39
39
|
export { CodeAnalyzeTool, type CodeAnalyzeParams, type CodeAnalyzeResult, type IndexResult, type SearchResult, type ImpactResult, type DependencyResult, } from './code-intelligence/analyze';
|
|
40
|
+
export { CodeC4Tool, type CodeC4Params, type CodeC4Result, type C4GenerateResult, type C4SearchResult, } from './code-intelligence/c4';
|
|
40
41
|
export { SecurityScanTool, type SecurityScanParams, type SecurityScanResult, type Vulnerability, type ScanSummary, type ComplianceResult, } from './security-compliance/scan';
|
|
41
42
|
export { ContractValidateTool, type ContractValidateParams, type ContractValidateResult, type BreakingChange, type VerificationResult, type CompatibilityReport, } from './contract-testing/validate';
|
|
42
43
|
export { VisualCompareTool, A11yAuditTool, type VisualCompareParams, type VisualCompareResult, type A11yAuditParams, type A11yAuditResult, type A11yViolation, type VisualComparison, } from './visual-accessibility';
|
package/dist/mcp/tools/index.js
CHANGED
|
@@ -61,6 +61,7 @@ export { QualityCriteriaTool, qualityCriteriaTool, } from './requirements-valida
|
|
|
61
61
|
// Code Intelligence Domain
|
|
62
62
|
// ============================================================================
|
|
63
63
|
export { CodeAnalyzeTool, } from './code-intelligence/analyze';
|
|
64
|
+
export { CodeC4Tool, } from './code-intelligence/c4';
|
|
64
65
|
// ============================================================================
|
|
65
66
|
// Security Compliance Domain
|
|
66
67
|
// ============================================================================
|
|
@@ -33,6 +33,7 @@ export declare const QE_TOOL_NAMES: {
|
|
|
33
33
|
readonly REQUIREMENTS_VALIDATE: "qe/requirements/validate";
|
|
34
34
|
readonly QUALITY_CRITERIA: "qe/requirements/quality-criteria";
|
|
35
35
|
readonly CODE_ANALYZE: "qe/code/analyze";
|
|
36
|
+
readonly CODE_C4: "qe/code/c4";
|
|
36
37
|
readonly SECURITY_SCAN: "qe/security/scan";
|
|
37
38
|
readonly CONTRACT_VALIDATE: "qe/contracts/validate";
|
|
38
39
|
readonly VISUAL_COMPARE: "qe/visual/compare";
|
|
@@ -13,6 +13,7 @@ import { DefectPredictTool } from './defect-intelligence/predict';
|
|
|
13
13
|
import { RequirementsValidateTool } from './requirements-validation/validate';
|
|
14
14
|
import { QualityCriteriaTool } from './requirements-validation/quality-criteria';
|
|
15
15
|
import { CodeAnalyzeTool } from './code-intelligence/analyze';
|
|
16
|
+
import { CodeC4Tool } from './code-intelligence/c4';
|
|
16
17
|
import { SecurityScanTool } from './security-compliance/scan';
|
|
17
18
|
import { ContractValidateTool } from './contract-testing/validate';
|
|
18
19
|
import { VisualCompareTool, A11yAuditTool } from './visual-accessibility';
|
|
@@ -48,6 +49,7 @@ export const QE_TOOL_NAMES = {
|
|
|
48
49
|
QUALITY_CRITERIA: 'qe/requirements/quality-criteria',
|
|
49
50
|
// Code Intelligence
|
|
50
51
|
CODE_ANALYZE: 'qe/code/analyze',
|
|
52
|
+
CODE_C4: 'qe/code/c4',
|
|
51
53
|
// Security Compliance
|
|
52
54
|
SECURITY_SCAN: 'qe/security/scan',
|
|
53
55
|
// Contract Testing
|
|
@@ -110,6 +112,7 @@ export const QE_TOOLS = [
|
|
|
110
112
|
new QualityCriteriaTool(),
|
|
111
113
|
// Code Intelligence Domain
|
|
112
114
|
new CodeAnalyzeTool(),
|
|
115
|
+
new CodeC4Tool(),
|
|
113
116
|
// Security Compliance Domain
|
|
114
117
|
new SecurityScanTool(),
|
|
115
118
|
// Contract Testing Domain
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ADR-112 — Deterministic C4 confidence gate.
|
|
3
|
+
*
|
|
4
|
+
* Pure, code-only (NO LLM in the gate — same discipline as ADR-111's accept
|
|
5
|
+
* gate). Turns the code-intelligence detector's known limits (the
|
|
6
|
+
* qe-code-intelligence skill records ~18% success on complex queries and
|
|
7
|
+
* degradation above ~50K LOC) into an explicit, surfaced signal so a
|
|
8
|
+
* confident-but-wrong diagram is never presented as ground truth.
|
|
9
|
+
*/
|
|
10
|
+
export type C4Confidence = 'high' | 'medium' | 'low';
|
|
11
|
+
export interface C4ConfidenceInputs {
|
|
12
|
+
/** Number of components the detector found. */
|
|
13
|
+
componentsDetected: number;
|
|
14
|
+
/** Number of component relationships (edges) detected. */
|
|
15
|
+
relationshipsDetected: number;
|
|
16
|
+
/** Number of external systems detected. */
|
|
17
|
+
externalSystemsDetected: number;
|
|
18
|
+
/** Number of source files analyzed. */
|
|
19
|
+
filesAnalyzed: number;
|
|
20
|
+
/** Total lines of code, if known (e.g. from MetricCollector). Optional. */
|
|
21
|
+
totalLoc?: number;
|
|
22
|
+
}
|
|
23
|
+
export interface C4ConfidenceAssessment {
|
|
24
|
+
/** Bucketed level for quick display. */
|
|
25
|
+
level: C4Confidence;
|
|
26
|
+
/** Continuous score in [0,1] the level is derived from. */
|
|
27
|
+
score: number;
|
|
28
|
+
/** Human-readable reasons (always populated). */
|
|
29
|
+
reasons: string[];
|
|
30
|
+
}
|
|
31
|
+
/** Repo size (LOC) beyond which the skill records detection degradation. */
|
|
32
|
+
export declare const C4_LOC_DEGRADE_THRESHOLD = 50000;
|
|
33
|
+
/**
|
|
34
|
+
* Assess how much to trust an auto-generated C4 diagram. Deterministic: the same
|
|
35
|
+
* inputs always yield the same level + reasons.
|
|
36
|
+
*/
|
|
37
|
+
export declare function assessC4Confidence(inputs: C4ConfidenceInputs): C4ConfidenceAssessment;
|
|
38
|
+
//# sourceMappingURL=confidence.d.ts.map
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ADR-112 — Deterministic C4 confidence gate.
|
|
3
|
+
*
|
|
4
|
+
* Pure, code-only (NO LLM in the gate — same discipline as ADR-111's accept
|
|
5
|
+
* gate). Turns the code-intelligence detector's known limits (the
|
|
6
|
+
* qe-code-intelligence skill records ~18% success on complex queries and
|
|
7
|
+
* degradation above ~50K LOC) into an explicit, surfaced signal so a
|
|
8
|
+
* confident-but-wrong diagram is never presented as ground truth.
|
|
9
|
+
*/
|
|
10
|
+
/** Repo size (LOC) beyond which the skill records detection degradation. */
|
|
11
|
+
export const C4_LOC_DEGRADE_THRESHOLD = 50_000;
|
|
12
|
+
const clamp01 = (x) => Math.max(0, Math.min(1, x));
|
|
13
|
+
/**
|
|
14
|
+
* Assess how much to trust an auto-generated C4 diagram. Deterministic: the same
|
|
15
|
+
* inputs always yield the same level + reasons.
|
|
16
|
+
*/
|
|
17
|
+
export function assessC4Confidence(inputs) {
|
|
18
|
+
const { componentsDetected, relationshipsDetected, externalSystemsDetected, totalLoc } = inputs;
|
|
19
|
+
const reasons = [];
|
|
20
|
+
// Empty diagram — nothing to trust.
|
|
21
|
+
if (componentsDetected === 0) {
|
|
22
|
+
return {
|
|
23
|
+
level: 'low',
|
|
24
|
+
score: 0,
|
|
25
|
+
reasons: ['No components detected — the diagram is effectively empty; verify against the source.'],
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
let score = 0.5;
|
|
29
|
+
// Relationships are the weakest link in heuristic detection. Their presence is
|
|
30
|
+
// the strongest signal that the STRUCTURE (not just a node list) is real.
|
|
31
|
+
const relDensity = relationshipsDetected / Math.max(1, componentsDetected);
|
|
32
|
+
if (relationshipsDetected === 0 && componentsDetected > 1) {
|
|
33
|
+
score -= 0.25;
|
|
34
|
+
reasons.push('No relationships detected between components — edges are heuristic-only or missing; the structure is unverified.');
|
|
35
|
+
}
|
|
36
|
+
else if (relDensity >= 0.5) {
|
|
37
|
+
score += 0.2;
|
|
38
|
+
reasons.push(`${relationshipsDetected} relationship(s) detected across ${componentsDetected} components.`);
|
|
39
|
+
}
|
|
40
|
+
else {
|
|
41
|
+
score += 0.05;
|
|
42
|
+
reasons.push(`${relationshipsDetected} relationship(s) detected (sparse) across ${componentsDetected} components.`);
|
|
43
|
+
}
|
|
44
|
+
// External systems detected → the Platform/Interfaces picture is grounded.
|
|
45
|
+
if (externalSystemsDetected > 0) {
|
|
46
|
+
score += 0.1;
|
|
47
|
+
reasons.push(`${externalSystemsDetected} external system(s) detected from dependencies.`);
|
|
48
|
+
}
|
|
49
|
+
// Repo size vs the known degradation threshold.
|
|
50
|
+
if (totalLoc !== undefined && totalLoc > C4_LOC_DEGRADE_THRESHOLD) {
|
|
51
|
+
score -= 0.3;
|
|
52
|
+
reasons.push(`Repository is large (${totalLoc.toLocaleString()} LOC > ~${C4_LOC_DEGRADE_THRESHOLD / 1000}K) — detection accuracy degrades; treat the diagram as a draft.`);
|
|
53
|
+
}
|
|
54
|
+
// A healthy component count adds confidence; a single component is thin.
|
|
55
|
+
if (componentsDetected >= 5) {
|
|
56
|
+
score += 0.1;
|
|
57
|
+
}
|
|
58
|
+
else if (componentsDetected === 1) {
|
|
59
|
+
score -= 0.05;
|
|
60
|
+
reasons.push('Only one component detected — likely an under-segmented view.');
|
|
61
|
+
}
|
|
62
|
+
score = clamp01(score);
|
|
63
|
+
const level = score >= 0.7 ? 'high' : score >= 0.4 ? 'medium' : 'low';
|
|
64
|
+
if (level !== 'high' && !reasons.some((r) => r.includes('draft') || r.includes('verify'))) {
|
|
65
|
+
reasons.push('Auto-generated draft — verify against the source before relying on it.');
|
|
66
|
+
}
|
|
67
|
+
return { level, score: Math.round(score * 1000) / 1000, reasons };
|
|
68
|
+
}
|
|
69
|
+
//# sourceMappingURL=confidence.js.map
|
|
@@ -8,6 +8,8 @@
|
|
|
8
8
|
* Based on the C4 Model by Simon Brown:
|
|
9
9
|
* https://c4model.com/
|
|
10
10
|
*/
|
|
11
|
+
export * from './confidence';
|
|
12
|
+
import type { C4ConfidenceAssessment } from './confidence';
|
|
11
13
|
/**
|
|
12
14
|
* C4 Diagrams container for all diagram levels
|
|
13
15
|
*/
|
|
@@ -52,6 +54,8 @@ export interface C4AnalysisMetadata {
|
|
|
52
54
|
externalSystemsDetected: number;
|
|
53
55
|
/** Analysis duration in milliseconds */
|
|
54
56
|
analysisTimeMs: number;
|
|
57
|
+
/** ADR-112: deterministic confidence gate for the generated diagrams */
|
|
58
|
+
confidence?: C4ConfidenceAssessment;
|
|
55
59
|
}
|
|
56
60
|
/**
|
|
57
61
|
* C4 Person element - represents a user of the system
|
|
@@ -17,7 +17,7 @@ import { safeJsonParse } from '../../safe-json.js';
|
|
|
17
17
|
* Default Gemini configuration
|
|
18
18
|
*/
|
|
19
19
|
export const DEFAULT_GEMINI_CONFIG = {
|
|
20
|
-
model: 'gemini-1.5-pro
|
|
20
|
+
model: 'gemini-2.5-flash', // gemini-1.5-pro was retired ("not found for API version"); 2.5-flash is current
|
|
21
21
|
maxTokens: 8192,
|
|
22
22
|
temperature: 0.7,
|
|
23
23
|
timeoutMs: 60000,
|
|
@@ -42,6 +42,10 @@ export const GEMINI_PRICING = {
|
|
|
42
42
|
'gemini-1.5-flash': { input: 0.075, output: 0.3 },
|
|
43
43
|
'gemini-1.5-flash-latest': { input: 0.075, output: 0.3 },
|
|
44
44
|
'gemini-2.0-flash-exp': { input: 0.075, output: 0.3 },
|
|
45
|
+
// Gemini 2.5 (current generation)
|
|
46
|
+
'gemini-2.5-pro': { input: 1.25, output: 10.0 },
|
|
47
|
+
'gemini-2.5-flash': { input: 0.3, output: 2.5 },
|
|
48
|
+
'gemini-flash-latest': { input: 0.3, output: 2.5 },
|
|
45
49
|
// Gemini Ultra (flagship)
|
|
46
50
|
'gemini-ultra': { input: 7.0, output: 21.0 },
|
|
47
51
|
'gemini-1.0-ultra': { input: 7.0, output: 21.0 },
|
|
@@ -393,15 +397,18 @@ export class GeminiProvider {
|
|
|
393
397
|
if (this.cachedModels) {
|
|
394
398
|
return this.cachedModels;
|
|
395
399
|
}
|
|
400
|
+
// Current text-generation models (verified via Gemini ListModels API 2026-06-27).
|
|
401
|
+
// Prefer the `-latest` aliases as defaults so they don't rot (gemini-1.5-pro was retired).
|
|
396
402
|
return [
|
|
397
|
-
'gemini-
|
|
398
|
-
'gemini-
|
|
399
|
-
'gemini-
|
|
400
|
-
'gemini-
|
|
401
|
-
'gemini-
|
|
402
|
-
'gemini-
|
|
403
|
-
'gemini-2.0-flash
|
|
404
|
-
'gemini-
|
|
403
|
+
'gemini-flash-latest',
|
|
404
|
+
'gemini-pro-latest',
|
|
405
|
+
'gemini-flash-lite-latest',
|
|
406
|
+
'gemini-2.5-pro',
|
|
407
|
+
'gemini-2.5-flash',
|
|
408
|
+
'gemini-2.5-flash-lite',
|
|
409
|
+
'gemini-2.0-flash',
|
|
410
|
+
'gemini-2.0-flash-lite',
|
|
411
|
+
'gemini-3.5-flash',
|
|
405
412
|
];
|
|
406
413
|
}
|
|
407
414
|
/**
|
|
@@ -485,7 +492,6 @@ export class GeminiProvider {
|
|
|
485
492
|
*/
|
|
486
493
|
handleApiError(status, data, model) {
|
|
487
494
|
const message = data.error?.message ?? 'Unknown API error';
|
|
488
|
-
const errorStatus = data.error?.status ?? '';
|
|
489
495
|
switch (status) {
|
|
490
496
|
case 400:
|
|
491
497
|
// Check for context length exceeded FIRST (message-based detection)
|
|
@@ -61,7 +61,7 @@ export const OPENROUTER_PRICING = {
|
|
|
61
61
|
* OpenRouter LLM provider implementation
|
|
62
62
|
*/
|
|
63
63
|
export class OpenRouterProvider {
|
|
64
|
-
type = '
|
|
64
|
+
type = 'openrouter';
|
|
65
65
|
name = 'OpenRouter';
|
|
66
66
|
config;
|
|
67
67
|
requestId = 0;
|
|
@@ -138,7 +138,7 @@ export class OpenRouterProvider {
|
|
|
138
138
|
async generate(input, options) {
|
|
139
139
|
const apiKey = this.getApiKey();
|
|
140
140
|
if (!apiKey) {
|
|
141
|
-
throw createLLMError('OpenRouter API key not configured', 'API_KEY_MISSING', { provider: '
|
|
141
|
+
throw createLLMError('OpenRouter API key not configured', 'API_KEY_MISSING', { provider: 'openrouter', retryable: false });
|
|
142
142
|
}
|
|
143
143
|
const messages = this.formatMessages(input, options?.systemPrompt);
|
|
144
144
|
const model = options?.model ?? this.config.model;
|
|
@@ -193,7 +193,7 @@ export class OpenRouterProvider {
|
|
|
193
193
|
return {
|
|
194
194
|
content,
|
|
195
195
|
model: data.model,
|
|
196
|
-
provider: '
|
|
196
|
+
provider: 'openrouter',
|
|
197
197
|
usage,
|
|
198
198
|
cost,
|
|
199
199
|
latencyMs,
|
|
@@ -206,7 +206,7 @@ export class OpenRouterProvider {
|
|
|
206
206
|
if (error instanceof Error && 'code' in error) {
|
|
207
207
|
throw error; // Re-throw LLM errors
|
|
208
208
|
}
|
|
209
|
-
throw createLLMError(error instanceof Error ? error.message : 'Request failed', 'NETWORK_ERROR', { provider: '
|
|
209
|
+
throw createLLMError(error instanceof Error ? error.message : 'Request failed', 'NETWORK_ERROR', { provider: 'openrouter', model, retryable: true, cause: error });
|
|
210
210
|
}
|
|
211
211
|
}
|
|
212
212
|
/**
|
|
@@ -216,7 +216,7 @@ export class OpenRouterProvider {
|
|
|
216
216
|
async *generateStream(input, options) {
|
|
217
217
|
const apiKey = this.getApiKey();
|
|
218
218
|
if (!apiKey) {
|
|
219
|
-
throw createLLMError('OpenRouter API key not configured', 'API_KEY_MISSING', { provider: '
|
|
219
|
+
throw createLLMError('OpenRouter API key not configured', 'API_KEY_MISSING', { provider: 'openrouter', retryable: false });
|
|
220
220
|
}
|
|
221
221
|
const messages = this.formatMessages(input, options?.systemPrompt);
|
|
222
222
|
const model = options?.model ?? this.config.model;
|
|
@@ -246,7 +246,7 @@ export class OpenRouterProvider {
|
|
|
246
246
|
throw this.handleApiError(response.status, errorData, model);
|
|
247
247
|
}
|
|
248
248
|
if (!response.body) {
|
|
249
|
-
throw createLLMError('No response body for streaming', 'NETWORK_ERROR', { provider: '
|
|
249
|
+
throw createLLMError('No response body for streaming', 'NETWORK_ERROR', { provider: 'openrouter', model, retryable: true });
|
|
250
250
|
}
|
|
251
251
|
let fullContent = '';
|
|
252
252
|
let finishReason = 'stop';
|
|
@@ -311,7 +311,7 @@ export class OpenRouterProvider {
|
|
|
311
311
|
return {
|
|
312
312
|
content: fullContent,
|
|
313
313
|
model: responseModel,
|
|
314
|
-
provider: '
|
|
314
|
+
provider: 'openrouter',
|
|
315
315
|
usage,
|
|
316
316
|
cost,
|
|
317
317
|
latencyMs,
|
|
@@ -327,7 +327,7 @@ export class OpenRouterProvider {
|
|
|
327
327
|
async embed(text, options) {
|
|
328
328
|
const apiKey = this.getApiKey();
|
|
329
329
|
if (!apiKey) {
|
|
330
|
-
throw createLLMError('OpenRouter API key not configured', 'API_KEY_MISSING', { provider: '
|
|
330
|
+
throw createLLMError('OpenRouter API key not configured', 'API_KEY_MISSING', { provider: 'openrouter', retryable: false });
|
|
331
331
|
}
|
|
332
332
|
const model = options?.model ?? 'openai/text-embedding-3-small';
|
|
333
333
|
const start = Date.now();
|
|
@@ -351,7 +351,7 @@ export class OpenRouterProvider {
|
|
|
351
351
|
return {
|
|
352
352
|
embedding: data.data[0].embedding,
|
|
353
353
|
model: data.model,
|
|
354
|
-
provider: '
|
|
354
|
+
provider: 'openrouter',
|
|
355
355
|
tokenCount: data.usage.total_tokens,
|
|
356
356
|
latencyMs,
|
|
357
357
|
cached: false,
|
|
@@ -361,7 +361,7 @@ export class OpenRouterProvider {
|
|
|
361
361
|
if (error instanceof Error && 'code' in error) {
|
|
362
362
|
throw error;
|
|
363
363
|
}
|
|
364
|
-
throw createLLMError(error instanceof Error ? error.message : 'Embedding request failed', 'NETWORK_ERROR', { provider: '
|
|
364
|
+
throw createLLMError(error instanceof Error ? error.message : 'Embedding request failed', 'NETWORK_ERROR', { provider: 'openrouter', model, retryable: true, cause: error });
|
|
365
365
|
}
|
|
366
366
|
}
|
|
367
367
|
/**
|
|
@@ -378,7 +378,7 @@ export class OpenRouterProvider {
|
|
|
378
378
|
return {
|
|
379
379
|
completion: response.content,
|
|
380
380
|
model: response.model,
|
|
381
|
-
provider: '
|
|
381
|
+
provider: 'openrouter',
|
|
382
382
|
usage: response.usage,
|
|
383
383
|
latencyMs: response.latencyMs,
|
|
384
384
|
cached: response.cached,
|
|
@@ -525,19 +525,19 @@ export class OpenRouterProvider {
|
|
|
525
525
|
switch (status) {
|
|
526
526
|
case 401:
|
|
527
527
|
throw createLLMError(message, 'API_KEY_INVALID', {
|
|
528
|
-
provider: '
|
|
528
|
+
provider: 'openrouter',
|
|
529
529
|
model,
|
|
530
530
|
retryable: false,
|
|
531
531
|
});
|
|
532
532
|
case 402:
|
|
533
533
|
throw createLLMError(message, 'COST_LIMIT_EXCEEDED', {
|
|
534
|
-
provider: '
|
|
534
|
+
provider: 'openrouter',
|
|
535
535
|
model,
|
|
536
536
|
retryable: false,
|
|
537
537
|
});
|
|
538
538
|
case 429:
|
|
539
539
|
throw createLLMError(message, 'RATE_LIMITED', {
|
|
540
|
-
provider: '
|
|
540
|
+
provider: 'openrouter',
|
|
541
541
|
model,
|
|
542
542
|
retryable: true,
|
|
543
543
|
retryAfterMs: 60000,
|
|
@@ -545,19 +545,19 @@ export class OpenRouterProvider {
|
|
|
545
545
|
case 400:
|
|
546
546
|
if (errorCode === 'context_length_exceeded' || errorType === 'invalid_request_error') {
|
|
547
547
|
throw createLLMError(message, 'CONTEXT_LENGTH_EXCEEDED', {
|
|
548
|
-
provider: '
|
|
548
|
+
provider: 'openrouter',
|
|
549
549
|
model,
|
|
550
550
|
retryable: false,
|
|
551
551
|
});
|
|
552
552
|
}
|
|
553
553
|
throw createLLMError(message, 'UNKNOWN', {
|
|
554
|
-
provider: '
|
|
554
|
+
provider: 'openrouter',
|
|
555
555
|
model,
|
|
556
556
|
retryable: false,
|
|
557
557
|
});
|
|
558
558
|
case 404:
|
|
559
559
|
throw createLLMError(message, 'MODEL_NOT_FOUND', {
|
|
560
|
-
provider: '
|
|
560
|
+
provider: 'openrouter',
|
|
561
561
|
model,
|
|
562
562
|
retryable: false,
|
|
563
563
|
});
|
|
@@ -565,14 +565,14 @@ export class OpenRouterProvider {
|
|
|
565
565
|
case 502:
|
|
566
566
|
case 503:
|
|
567
567
|
throw createLLMError(message, 'PROVIDER_UNAVAILABLE', {
|
|
568
|
-
provider: '
|
|
568
|
+
provider: 'openrouter',
|
|
569
569
|
model,
|
|
570
570
|
retryable: true,
|
|
571
571
|
retryAfterMs: 5000,
|
|
572
572
|
});
|
|
573
573
|
default:
|
|
574
574
|
throw createLLMError(message, 'UNKNOWN', {
|
|
575
|
-
provider: '
|
|
575
|
+
provider: 'openrouter',
|
|
576
576
|
model,
|
|
577
577
|
retryable: false,
|
|
578
578
|
});
|
|
@@ -594,7 +594,7 @@ export class OpenRouterProvider {
|
|
|
594
594
|
catch (error) {
|
|
595
595
|
if (error instanceof Error && error.name === 'AbortError') {
|
|
596
596
|
throw createLLMError('Request timed out', 'TIMEOUT', {
|
|
597
|
-
provider: '
|
|
597
|
+
provider: 'openrouter',
|
|
598
598
|
retryable: true,
|
|
599
599
|
});
|
|
600
600
|
}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Conservation Guard (Phoenix essay 14 "UI Is a Conservation Layer", ADR-114)
|
|
3
|
+
*
|
|
4
|
+
* AQE's human/agent-facing surfaces — CLI commands, output schemas, MCP tools,
|
|
5
|
+
* the dashboard — are its conservation layer: users and CI pipelines build muscle
|
|
6
|
+
* memory and scripts around them. Internals may regenerate freely; these surfaces
|
|
7
|
+
* must change slowly and ADDITIVELY. This module diffs a captured baseline against
|
|
8
|
+
* the current surface and flags breaking removals/renames that are not in the
|
|
9
|
+
* deprecation registry.
|
|
10
|
+
*
|
|
11
|
+
* Pure functions only — extraction + I/O live in scripts/conservation-guard.ts.
|
|
12
|
+
*/
|
|
13
|
+
export interface SurfaceDiff {
|
|
14
|
+
surface: string;
|
|
15
|
+
/** Entries present now but not in the baseline — additive, always allowed. */
|
|
16
|
+
added: string[];
|
|
17
|
+
/** Entries removed from the baseline and NOT in the deprecation registry — breaking. */
|
|
18
|
+
removedBreaking: string[];
|
|
19
|
+
/** Entries removed but listed as deprecated — an allowed, deliberate removal. */
|
|
20
|
+
removedDeprecated: string[];
|
|
21
|
+
/** True when there are no breaking removals. */
|
|
22
|
+
clean: boolean;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* Diff one surface. Additive changes pass; a removal/rename is breaking unless the
|
|
26
|
+
* removed entry appears in `deprecated` (the deprecation window has been honored).
|
|
27
|
+
*/
|
|
28
|
+
export declare function diffSurface(surface: string, baseline: string[], current: string[], deprecated?: string[]): SurfaceDiff;
|
|
29
|
+
export interface ConservationReport {
|
|
30
|
+
diffs: SurfaceDiff[];
|
|
31
|
+
clean: boolean;
|
|
32
|
+
/** Total breaking removals across all surfaces. */
|
|
33
|
+
breakingCount: number;
|
|
34
|
+
}
|
|
35
|
+
/** Aggregate per-surface diffs into an overall verdict. */
|
|
36
|
+
export declare function aggregate(diffs: SurfaceDiff[]): ConservationReport;
|
|
37
|
+
/** Human-readable report (used by the CLI guard and CI logs). */
|
|
38
|
+
export declare function formatReport(report: ConservationReport): string;
|
|
39
|
+
//# sourceMappingURL=conservation-guard.d.ts.map
|