@oscharko-dev/keiko 1.1.13 → 1.2.0
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/README.md +21 -5
- package/dist/ui/csp-hashes.json +7 -7
- package/dist/ui/static/404.html +1 -1
- package/dist/ui/static/__next.__PAGE__.txt +12 -12
- package/dist/ui/static/__next._full.txt +23 -22
- package/dist/ui/static/__next._tree.txt +3 -3
- package/dist/ui/static/_next/static/chunks/0--s8pmsbkf62.js +1 -0
- package/dist/ui/static/_next/static/chunks/00_o0v2hokzqm.js +1 -0
- package/dist/ui/static/_next/static/chunks/0339vdalk0q6h.js +3 -0
- package/dist/ui/static/_next/static/chunks/{13fx5sqcncq4_.js → 05k2u3763ih_i.js} +1 -1
- package/dist/ui/static/_next/static/chunks/07f-n_9zq-s8q.js +1 -0
- package/dist/ui/static/_next/static/chunks/07l0sfn1-mid2.js +1 -0
- package/dist/ui/static/_next/static/chunks/07skh7tlpfo1v.js +1 -0
- package/dist/ui/static/_next/static/chunks/{2cn33khz2ae-h.js → 08v-jyhi2uk8t.js} +1 -1
- package/dist/ui/static/_next/static/chunks/09i_8713x46yr.js +1 -0
- package/dist/ui/static/_next/static/chunks/{199p3upt-xa37.js → 09zc5hgtb7s-z.js} +1 -1
- package/dist/ui/static/_next/static/chunks/0_yx8_bs1t-27.js +1 -0
- package/dist/ui/static/_next/static/chunks/0a6ri2ug5xf10.js +1 -0
- package/dist/ui/static/_next/static/chunks/0bbrrvuzilpy5.js +1 -0
- package/dist/ui/static/_next/static/chunks/0bg7uh6tq8-dx.js +1 -0
- package/dist/ui/static/_next/static/chunks/0bpexy600ffpg.js +1 -0
- package/dist/ui/static/_next/static/chunks/0bz731buimrpv.js +1 -0
- package/dist/ui/static/_next/static/chunks/0cwy6mtvshbuo.js +1 -0
- package/dist/ui/static/_next/static/chunks/{3i0iog52c1ajg.js → 0fpbvpzg-omn0.js} +1 -1
- package/dist/ui/static/_next/static/chunks/0fz9qig_5p73f.js +1 -0
- package/dist/ui/static/_next/static/chunks/0gf88p0jy1g5w.js +1 -0
- package/dist/ui/static/_next/static/chunks/0hvxxuef1gw9p.js +1 -0
- package/dist/ui/static/_next/static/chunks/0iu3dyqe7m7_7.js +1 -0
- package/dist/ui/static/_next/static/chunks/0ktvc8fs3spkb.js +1 -0
- package/dist/ui/static/_next/static/chunks/0kvy_ru-kodgv.js +1 -0
- package/dist/ui/static/_next/static/chunks/{25f22x86d_a1n.js → 0l72usw6suk0h.js} +1 -1
- package/dist/ui/static/_next/static/chunks/0mcg_spbohpl3.css +1 -0
- package/dist/ui/static/_next/static/chunks/{02epwnm5oro9c.css → 0mjsj7bp-ukgh.css} +16 -20
- package/dist/ui/static/_next/static/chunks/0parm4c86umwk.js +1 -0
- package/dist/ui/static/_next/static/chunks/0q_08tk2d3m2n.js +1 -0
- package/dist/ui/static/_next/static/chunks/0r2lwkgws6jm8.js +1 -0
- package/dist/ui/static/_next/static/chunks/0t73kckx3olud.js +1 -0
- package/dist/ui/static/_next/static/chunks/0w2fp3hjrfx32.js +1 -0
- package/dist/ui/static/_next/static/chunks/0wdn9qetndtsj.js +1 -0
- package/dist/ui/static/_next/static/chunks/0weojtwxo6qw7.js +1 -0
- package/dist/ui/static/_next/static/chunks/0x-r45yl06rdn.js +1 -0
- package/dist/ui/static/_next/static/chunks/0x42c1na2ia6m.js +1 -0
- package/dist/ui/static/_next/static/chunks/0xu2rnpdr4kzd.js +1 -0
- package/dist/ui/static/_next/static/chunks/{0o_lmzxpjfeky.js → 0yzmg9aoglud6.js} +1 -1
- package/dist/ui/static/_next/static/chunks/0zuaq_9l5pma_.js +1 -0
- package/dist/ui/static/_next/static/chunks/10kb8j7vggfwk.js +1 -0
- package/dist/ui/static/_next/static/chunks/14qdwomthzucj.js +1 -0
- package/dist/ui/static/_next/static/chunks/196257vfyrtgu.js +1 -0
- package/dist/ui/static/_next/static/chunks/{3kmozkq6tgqnz.js → 196x_tfexoucg.js} +1 -1
- package/dist/ui/static/_next/static/chunks/1a6ri-sriyu-m.js +1 -0
- package/dist/ui/static/_next/static/chunks/1a7ko-_7t4wjo.js +1 -0
- package/dist/ui/static/_next/static/chunks/1aivbuztyv67o.js +10 -0
- package/dist/ui/static/_next/static/chunks/1c0u0qq0vwkc4.js +1 -0
- package/dist/ui/static/_next/static/chunks/1czgn62g6km38.js +3 -0
- package/dist/ui/static/_next/static/chunks/1f05h21irrvbs.js +1 -0
- package/dist/ui/static/_next/static/chunks/1juiifi_xnx68.js +1 -0
- package/dist/ui/static/_next/static/chunks/1m-9yzfpcm7wc.js +1 -0
- package/dist/ui/static/_next/static/chunks/{29dj-5kj_vfl_.js → 1qh0x9_258ol2.js} +1 -1
- package/dist/ui/static/_next/static/chunks/{2kh0qihno0n1w.js → 1rp_smu1jjw45.js} +1 -1
- package/dist/ui/static/_next/static/chunks/1wg1s3jm779ro.js +3 -0
- package/dist/ui/static/_next/static/chunks/{0l7cc8q83migz.css → 1wj7exxi550gi.css} +1 -1
- package/dist/ui/static/_next/static/chunks/1zczte6xkwvcl.js +1 -0
- package/dist/ui/static/_next/static/chunks/1zudszthinjcb.js +1 -0
- package/dist/ui/static/_next/static/chunks/{1kacubgk0y2ki.js → 21-6b7rkmtvg8.js} +1 -1
- package/dist/ui/static/_next/static/chunks/224bbe_3ksnlw.js +1 -0
- package/dist/ui/static/_next/static/chunks/{3chx0gpjqrhod.js → 24u-5fslcj3n9.js} +3 -3
- package/dist/ui/static/_next/static/chunks/25x9hf4wdlde7.js +1 -0
- package/dist/ui/static/_next/static/chunks/263_uck8el32f.js +1 -0
- package/dist/ui/static/_next/static/chunks/26gmn1z4oegqh.js +1 -0
- package/dist/ui/static/_next/static/chunks/28ylcw-leje_k.js +1 -0
- package/dist/ui/static/_next/static/chunks/2937s9os9u2tn.js +1 -0
- package/dist/ui/static/_next/static/chunks/29rlw6dih8owf.js +1 -0
- package/dist/ui/static/_next/static/chunks/2b_t95bbpmtej.js +1 -0
- package/dist/ui/static/_next/static/chunks/2hq0zlnvfqol9.js +1 -0
- package/dist/ui/static/_next/static/chunks/{3inx1ugcc-jd-.css → 2hu5w89yy7_s-.css} +1 -0
- package/dist/ui/static/_next/static/chunks/2kylv1kq1_4p1.js +1 -0
- package/dist/ui/static/_next/static/chunks/{0m1163red7mw7.js → 2nlmtsm3kjmbh.js} +1 -1
- package/dist/ui/static/_next/static/chunks/2o584howfzzak.js +3 -0
- package/dist/ui/static/_next/static/chunks/{1c1gbfapof8m0.js → 2oq1uk07ft9l0.js} +1 -1
- package/dist/ui/static/_next/static/chunks/2ov72plu69iiv.js +1 -0
- package/dist/ui/static/_next/static/chunks/2p66e_a0j23r8.js +1 -0
- package/dist/ui/static/_next/static/chunks/2ribv7pn1hr-l.js +1 -0
- package/dist/ui/static/_next/static/chunks/2ta3xj9td_qot.js +1 -0
- package/dist/ui/static/_next/static/chunks/2tb2nt2wvu643.js +1 -0
- package/dist/ui/static/_next/static/chunks/2wuj7qxm6mleh.js +1 -0
- package/dist/ui/static/_next/static/chunks/2y98z-sun8_ew.js +1 -0
- package/dist/ui/static/_next/static/chunks/2yot6vshhc19p.css +1 -0
- package/dist/ui/static/_next/static/chunks/2z5c2glupanq_.js +1 -0
- package/dist/ui/static/_next/static/chunks/3-7tka4cib69h.js +1 -0
- package/dist/ui/static/_next/static/chunks/3-dorttkhs3i2.js +1 -0
- package/dist/ui/static/_next/static/chunks/30j8jo5v60ga1.js +2 -0
- package/dist/ui/static/_next/static/chunks/30q9b_aw8driv.js +1 -0
- package/dist/ui/static/_next/static/chunks/{18qu5m_in_h3x.js → 3603jy78awb1p.js} +1 -1
- package/dist/ui/static/_next/static/chunks/36c8jty3kllje.js +1 -0
- package/dist/ui/static/_next/static/chunks/387k5c-bf1b2e.js +1 -0
- package/dist/ui/static/_next/static/chunks/388eokaf_2t9k.js +1 -0
- package/dist/ui/static/_next/static/chunks/3946_dfcd9xr-.js +1 -0
- package/dist/ui/static/_next/static/chunks/3_alxp77ewgk_.js +1 -0
- package/dist/ui/static/_next/static/chunks/3_ycy0h8pq58a.js +1 -0
- package/dist/ui/static/_next/static/chunks/3eduf6vevclfm.js +1 -0
- package/dist/ui/static/_next/static/chunks/3eg8pcox5copv.js +1 -0
- package/dist/ui/static/_next/static/chunks/3gyetohi_flhb.js +1 -0
- package/dist/ui/static/_next/static/chunks/{39w0xj7fyy7sp.js → 3h-rh_lx0l8_3.js} +1 -1
- package/dist/ui/static/_next/static/chunks/{1o2cihsnxhmh6.js → 3hclt6m3ok4n9.js} +1 -1
- package/dist/ui/static/_next/static/chunks/3ho1f5n8lir4r.js +1 -0
- package/dist/ui/static/_next/static/chunks/3kgc_j74tblcn.js +1 -0
- package/dist/ui/static/_next/static/chunks/3ksbq-nwkgwob.js +1 -0
- package/dist/ui/static/_next/static/chunks/3mxpjroefk8ou.js +1 -0
- package/dist/ui/static/_next/static/chunks/3or_0c84ozskx.js +1 -0
- package/dist/ui/static/_next/static/chunks/3q5jidle0lb3-.js +1 -0
- package/dist/ui/static/_next/static/chunks/3qjkuhjy_-_br.js +1 -0
- package/dist/ui/static/_next/static/chunks/3sgbsntbbci5y.js +1 -0
- package/dist/ui/static/_next/static/chunks/3tcw3qy3rrkyf.js +1 -0
- package/dist/ui/static/_next/static/chunks/3tqd6avtamgd5.js +1 -0
- package/dist/ui/static/_next/static/chunks/3ua7si017r4dg.js +1 -0
- package/dist/ui/static/_next/static/chunks/3v2iluxqnsug9.css +15 -0
- package/dist/ui/static/_next/static/chunks/{1ydfda18zlx4w.js → 3vjm30f1if00s.js} +1 -1
- package/dist/ui/static/_next/static/chunks/3z5edm1fpkcuq.js +1 -0
- package/dist/ui/static/_next/static/chunks/3z5f2s7yd35cu.js +1 -0
- package/dist/ui/static/_next/static/chunks/40co1uetczqcs.js +1 -0
- package/dist/ui/static/_next/static/chunks/43kutp14mqi-j.js +1 -0
- package/dist/ui/static/_next/static/chunks/43y3xn64quyo2.js +1 -0
- package/dist/ui/static/_next/static/chunks/{turbopack-2fb3mn6go2p-t.js → turbopack-2rwr7ign9ynaa.js} +1 -1
- package/dist/ui/static/_not-found/__next._full.txt +13 -13
- package/dist/ui/static/_not-found/__next._not-found.__PAGE__.txt +9 -9
- package/dist/ui/static/_not-found/__next._tree.txt +2 -2
- package/dist/ui/static/_not-found.html +1 -1
- package/dist/ui/static/_not-found.txt +13 -13
- package/dist/ui/static/atlassian-connectors/__next._full.txt +15 -15
- package/dist/ui/static/atlassian-connectors/__next._tree.txt +2 -2
- package/dist/ui/static/atlassian-connectors/__next.atlassian-connectors.__PAGE__.txt +11 -11
- package/dist/ui/static/atlassian-connectors.html +1 -1
- package/dist/ui/static/atlassian-connectors.txt +15 -15
- package/dist/ui/static/index.html +1 -1
- package/dist/ui/static/index.txt +23 -22
- package/dist/ui/static/launch/__next._full.txt +16 -16
- package/dist/ui/static/launch/__next._tree.txt +3 -3
- package/dist/ui/static/launch/__next.launch.__PAGE__.txt +12 -12
- package/dist/ui/static/launch.html +1 -1
- package/dist/ui/static/launch.txt +16 -16
- package/dist/ui/static/local-knowledge/__next._full.txt +16 -16
- package/dist/ui/static/local-knowledge/__next._tree.txt +3 -3
- package/dist/ui/static/local-knowledge/__next.local-knowledge.__PAGE__.txt +12 -12
- package/dist/ui/static/local-knowledge/capsule/__next._full.txt +25 -24
- package/dist/ui/static/local-knowledge/capsule/__next._tree.txt +2 -2
- package/dist/ui/static/local-knowledge/capsule/__next.local-knowledge.capsule.__PAGE__.txt +11 -11
- package/dist/ui/static/local-knowledge/capsule.html +1 -1
- package/dist/ui/static/local-knowledge/capsule.txt +25 -24
- package/dist/ui/static/local-knowledge.html +1 -1
- package/dist/ui/static/local-knowledge.txt +16 -16
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/activity-log-store.d.ts +6 -2
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/activity-log-store.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/activity-log-store.js +54 -8
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/defect-fingerprint.d.ts +35 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/defect-fingerprint.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/defect-fingerprint.js +66 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/index.d.ts +2 -1
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/index.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/index.js +2 -1
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/log-redaction.d.ts +13 -2
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/log-redaction.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/log-redaction.js +67 -126
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/index.d.ts +4 -1
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/index.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/index.js +4 -1
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-analyze-sufficiency.d.ts +10 -2
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-analyze-sufficiency.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-analyze-sufficiency.js +59 -46
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-analyze.d.ts +13 -2
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-analyze.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-analyze.js +150 -52
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-code-inventory.generated.d.ts +30 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-code-inventory.generated.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-code-inventory.generated.js +3539 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-desktop-report-attribution.d.ts +5 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-desktop-report-attribution.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-desktop-report-attribution.js +74 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-desktop-report.d.ts +25 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-desktop-report.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-desktop-report.js +184 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-incident-resolution.d.ts +33 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-incident-resolution.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-incident-resolution.js +195 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-lifetime.d.ts +7 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-lifetime.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-lifetime.js +19 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-local-query.d.ts +11 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-local-query.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-local-query.js +20 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-query.d.ts +6 -2
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-query.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-query.js +442 -60
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-registry-history.generated.d.ts +38 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-registry-history.generated.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-registry-history.generated.js +45 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-registry.d.ts +27 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-registry.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-registry.js +46 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-report-json.d.ts +3 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-report-json.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-report-json.js +5 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-report-privacy.d.ts +12 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-report-privacy.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-report-privacy.js +226 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-report.d.ts +41 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-report.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-report.js +672 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-segment-manifest.d.ts +4 -1
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-segment-manifest.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-segment-manifest.js +17 -5
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-segment-scan.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-segment-scan.js +16 -9
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/server-log.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/server-log.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/server-log.js +16 -10
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/support-incident-retention.d.ts +10 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/support-incident-retention.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/support-incident-retention.js +21 -0
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/support-incident-store.d.ts +11 -3
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/support-incident-store.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/support-incident-store.js +142 -23
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/support-incident.d.ts +25 -22
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/support-incident.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/support-incident.js +694 -198
- package/node_modules/@oscharko-dev/keiko-activity-log/package.json +3 -3
- package/node_modules/@oscharko-dev/keiko-cli/dist/cli-control-state.d.ts +8 -0
- package/node_modules/@oscharko-dev/keiko-cli/dist/cli-control-state.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-cli/dist/cli-control-state.js +25 -1
- package/node_modules/@oscharko-dev/keiko-cli/dist/investigate.js +1 -1
- package/node_modules/@oscharko-dev/keiko-cli/dist/process-activity-log.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-cli/dist/process-activity-log.js +3 -1
- package/node_modules/@oscharko-dev/keiko-cli/dist/repair.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-cli/dist/repair.js +1 -0
- package/node_modules/@oscharko-dev/keiko-cli/dist/runner.js +1 -1
- package/node_modules/@oscharko-dev/keiko-cli/dist/state-paths.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-cli/dist/state-paths.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-cli/dist/state-paths.js +19 -8
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-export.d.ts +16 -113
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-export.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-export.js +71 -358
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-incident.d.ts +1 -21
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-incident.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-incident.js +14 -112
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-query-cli.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-query-cli.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-query-cli.js +6 -18
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-query-evidence.d.ts +10 -0
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-query-evidence.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-query-evidence.js +2 -0
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-report-cli.d.ts +23 -0
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-report-cli.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-report-cli.js +521 -0
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-report-evidence.d.ts +647 -0
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-report-evidence.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-report-evidence.js +338 -0
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-selective-export.d.ts +3 -5
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-selective-export.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-cli/dist/support-selective-export.js +6 -42
- package/node_modules/@oscharko-dev/keiko-cli/dist/support.d.ts +0 -18
- package/node_modules/@oscharko-dev/keiko-cli/dist/support.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-cli/dist/support.js +118 -1276
- package/node_modules/@oscharko-dev/keiko-cli/package.json +15 -15
- package/node_modules/@oscharko-dev/keiko-connectors/dist/version.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-connectors/dist/version.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-connectors/dist/version.js +1 -1
- package/node_modules/@oscharko-dev/keiko-connectors/package.json +3 -3
- package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-failure-class-contracts.d.ts +302 -102
- package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-failure-class-contracts.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-failure-class-contracts.js +476 -95
- package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-label-policy.d.ts +4 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-label-policy.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-label-policy.js +123 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-operations.generated.d.ts +29497 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-operations.generated.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-operations.generated.js +32895 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-registry.generated.d.ts +8326 -32178
- package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-registry.generated.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/activity-log-registry.generated.js +3617 -29833
- package/node_modules/@oscharko-dev/keiko-contracts/dist/bff-wire.d.ts +139 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/bff-wire.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/bff-wire.js +40 -15
- package/node_modules/@oscharko-dev/keiko-contracts/dist/citation-markers.d.ts +49 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/citation-markers.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/citation-markers.js +380 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/client-defect-signature.d.ts +12 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/client-defect-signature.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/client-defect-signature.js +63 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/coding-repository-search.d.ts +24 -5
- package/node_modules/@oscharko-dev/keiko-contracts/dist/coding-repository-search.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/coding-repository-search.js +16 -5
- package/node_modules/@oscharko-dev/keiko-contracts/dist/coding-workbench.d.ts +2 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/coding-workbench.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/connected-context.d.ts +12 -6
- package/node_modules/@oscharko-dev/keiko-contracts/dist/connected-context.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/connected-context.js +171 -100
- package/node_modules/@oscharko-dev/keiko-contracts/dist/connected-search-abstention.d.ts +7 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/connected-search-abstention.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/connected-search-abstention.js +14 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/context-engineering-compaction-validation.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/context-engineering-compaction-validation.js +4 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/context-engineering-validation.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/context-engineering-validation.js +8 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/context-engineering.d.ts +15 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/context-engineering.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/context-engineering.js +20 -6
- package/node_modules/@oscharko-dev/keiko-contracts/dist/diagnostics.d.ts +116 -5
- package/node_modules/@oscharko-dev/keiko-contracts/dist/diagnostics.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/diagnostics.js +487 -9
- package/node_modules/@oscharko-dev/keiko-contracts/dist/editor-agent.d.ts +17 -12
- package/node_modules/@oscharko-dev/keiko-contracts/dist/editor-agent.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/editor-agent.js +76 -36
- package/node_modules/@oscharko-dev/keiko-contracts/dist/editor-m7.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/editor-m7.js +0 -2
- package/node_modules/@oscharko-dev/keiko-contracts/dist/evidence.d.ts +4 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/evidence.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/gateway.d.ts +35 -6
- package/node_modules/@oscharko-dev/keiko-contracts/dist/gateway.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/gateway.js +50 -8
- package/node_modules/@oscharko-dev/keiko-contracts/dist/git-repository.d.ts +4 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/git-repository.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/git-repository.js +13 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/grounded-assessment.d.ts +27 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/grounded-assessment.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/grounded-assessment.js +85 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/index.d.ts +4 -4
- package/node_modules/@oscharko-dev/keiko-contracts/dist/index.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/no-evidence-answer.d.ts +15 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/no-evidence-answer.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/no-evidence-answer.js +359 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/observability.d.ts +26 -2
- package/node_modules/@oscharko-dev/keiko-contracts/dist/observability.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/observability.js +109 -6
- package/node_modules/@oscharko-dev/keiko-contracts/dist/store-fingerprint.d.ts +5 -6
- package/node_modules/@oscharko-dev/keiko-contracts/dist/store-fingerprint.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/store-fingerprint.js +16 -16
- package/node_modules/@oscharko-dev/keiko-contracts/dist/support-incident.d.ts +33 -17
- package/node_modules/@oscharko-dev/keiko-contracts/dist/support-incident.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/support-incident.js +230 -26
- package/node_modules/@oscharko-dev/keiko-contracts/dist/support-report-json.d.ts +13 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/support-report-json.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/support-report-json.js +206 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/support-report-policy.d.ts +6 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/support-report-policy.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/support-report-policy.js +11 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/support-report-producer.d.ts +26 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/support-report-producer.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/support-report-producer.js +107 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/support-report.d.ts +118 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/support-report.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/support-report.js +63 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/version.d.ts +6 -2
- package/node_modules/@oscharko-dev/keiko-contracts/dist/version.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/version.js +71 -2
- package/node_modules/@oscharko-dev/keiko-contracts/dist/workspace-contract-primitives.d.ts +2 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/workspace-contract-primitives.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/dist/workspace-contract-primitives.js +2 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/workspace.d.ts +1 -0
- package/node_modules/@oscharko-dev/keiko-contracts/dist/workspace.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-contracts/package.json +17 -1
- package/node_modules/@oscharko-dev/keiko-evaluations/package.json +9 -9
- package/node_modules/@oscharko-dev/keiko-evidence/dist/compaction-evidence.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-evidence/dist/compaction-evidence.js +3 -0
- package/node_modules/@oscharko-dev/keiko-evidence/dist/connected-context-evidence.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-evidence/dist/connected-context-evidence.js +7 -4
- package/node_modules/@oscharko-dev/keiko-evidence/dist/context-assembly-redaction.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-evidence/dist/context-assembly-redaction.js +1 -0
- package/node_modules/@oscharko-dev/keiko-evidence/dist/version.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-evidence/dist/version.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-evidence/dist/version.js +1 -1
- package/node_modules/@oscharko-dev/keiko-evidence/package.json +4 -4
- package/node_modules/@oscharko-dev/keiko-git/dist/version.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-git/dist/version.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-git/dist/version.js +1 -1
- package/node_modules/@oscharko-dev/keiko-git/package.json +1 -1
- package/node_modules/@oscharko-dev/keiko-harness/dist/version.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-harness/dist/version.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-harness/dist/version.js +1 -1
- package/node_modules/@oscharko-dev/keiko-harness/package.json +7 -7
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/conversation/citation-attacher.d.ts +1 -0
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/conversation/citation-attacher.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/conversation/citation-attacher.js +49 -38
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/conversation/grounded-answer-runner.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/conversation/grounded-answer-runner.js +61 -25
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/conversation/types.d.ts +14 -0
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/conversation/types.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/index.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/index.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/index.js +1 -1
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/indexing/embedding-activity-log.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/indexing/embedding-activity-log.js +1 -0
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/indexing/orchestrator-activity-log.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/indexing/orchestrator-activity-log.js +6 -0
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/store-content-encryption.d.ts +0 -2
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/store-content-encryption.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/store-content-encryption.js +0 -11
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/store.d.ts +0 -11
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/store.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/store.js +9 -78
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/version.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/version.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-local-knowledge/dist/version.js +1 -1
- package/node_modules/@oscharko-dev/keiko-local-knowledge/package.json +5 -5
- package/node_modules/@oscharko-dev/keiko-memory-capture/dist/version.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-capture/dist/version.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-capture/dist/version.js +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-capture/package.json +3 -3
- package/node_modules/@oscharko-dev/keiko-memory-consolidation/dist/consolidate.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-consolidation/dist/consolidate.js +3 -0
- package/node_modules/@oscharko-dev/keiko-memory-consolidation/dist/version.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-consolidation/dist/version.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-consolidation/dist/version.js +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-consolidation/package.json +3 -3
- package/node_modules/@oscharko-dev/keiko-memory-governance/dist/version.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-governance/dist/version.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-governance/dist/version.js +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-governance/package.json +3 -3
- package/node_modules/@oscharko-dev/keiko-memory-retrieval/dist/version.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-retrieval/dist/version.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-retrieval/dist/version.js +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-retrieval/package.json +3 -3
- package/node_modules/@oscharko-dev/keiko-memory-vault/dist/cipher.d.ts +0 -12
- package/node_modules/@oscharko-dev/keiko-memory-vault/dist/cipher.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-vault/dist/cipher.js +0 -32
- package/node_modules/@oscharko-dev/keiko-memory-vault/dist/db.d.ts +2 -11
- package/node_modules/@oscharko-dev/keiko-memory-vault/dist/db.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-vault/dist/db.js +10 -144
- package/node_modules/@oscharko-dev/keiko-memory-vault/dist/index.d.ts +1 -2
- package/node_modules/@oscharko-dev/keiko-memory-vault/dist/index.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-vault/dist/index.js +7 -14
- package/node_modules/@oscharko-dev/keiko-memory-vault/dist/paths.d.ts +3 -2
- package/node_modules/@oscharko-dev/keiko-memory-vault/dist/paths.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-vault/dist/paths.js +17 -48
- package/node_modules/@oscharko-dev/keiko-memory-vault/dist/vault-log.d.ts +2 -1
- package/node_modules/@oscharko-dev/keiko-memory-vault/dist/vault-log.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-vault/dist/vault.js +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-vault/dist/version.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-vault/dist/version.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-vault/dist/version.js +1 -1
- package/node_modules/@oscharko-dev/keiko-memory-vault/package.json +3 -3
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/capabilities.d.ts +9 -0
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/capabilities.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/capabilities.js +24 -10
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/config.d.ts +1 -0
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/config.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/config.js +100 -1
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/gateway.d.ts +24 -0
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/gateway.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/gateway.js +104 -34
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/index.d.ts +3 -3
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/index.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/index.js +2 -2
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/model-selection.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/model-selection.js +33 -5
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/openai-adapter.d.ts +6 -0
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/openai-adapter.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/openai-adapter.js +115 -19
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/openai-embedding-adapter.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/openai-embedding-adapter.js +3 -0
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/prDescription/generate.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/prDescription/generate.js +4 -1
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/prompt-admission.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/prompt-admission.js +5 -2
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/readiness-probe.d.ts +17 -0
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/readiness-probe.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/readiness-probe.js +48 -0
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/resilience.d.ts +27 -2
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/resilience.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/resilience.js +300 -65
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/types.d.ts +10 -0
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/types.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/version.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/version.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-model-gateway/dist/version.js +1 -1
- package/node_modules/@oscharko-dev/keiko-model-gateway/package.json +4 -4
- package/node_modules/@oscharko-dev/keiko-quality-intelligence/package.json +3 -3
- package/node_modules/@oscharko-dev/keiko-sandbox/dist/backends.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-sandbox/dist/backends.js +14 -3
- package/node_modules/@oscharko-dev/keiko-sandbox/dist/index.d.ts +1 -0
- package/node_modules/@oscharko-dev/keiko-sandbox/dist/index.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-sandbox/dist/index.js +1 -0
- package/node_modules/@oscharko-dev/keiko-sandbox/dist/local-docker-endpoint.d.ts +16 -0
- package/node_modules/@oscharko-dev/keiko-sandbox/dist/local-docker-endpoint.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-sandbox/dist/local-docker-endpoint.js +128 -0
- package/node_modules/@oscharko-dev/keiko-sandbox/dist/plan.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-sandbox/dist/plan.js +25 -4
- package/node_modules/@oscharko-dev/keiko-sandbox/dist/types.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-sandbox/package.json +2 -2
- package/node_modules/@oscharko-dev/keiko-sdk/package.json +9 -9
- package/node_modules/@oscharko-dev/keiko-security/dist/errors/gateway.d.ts +8 -2
- package/node_modules/@oscharko-dev/keiko-security/dist/errors/gateway.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-security/dist/errors/gateway.js +15 -5
- package/node_modules/@oscharko-dev/keiko-security/dist/fs-hardening.d.ts +85 -1
- package/node_modules/@oscharko-dev/keiko-security/dist/fs-hardening.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-security/dist/fs-hardening.js +128 -3
- package/node_modules/@oscharko-dev/keiko-security/dist/redaction.d.ts +3 -1
- package/node_modules/@oscharko-dev/keiko-security/dist/redaction.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-security/dist/redaction.js +49 -14
- package/node_modules/@oscharko-dev/keiko-security/dist/version.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-security/dist/version.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-security/dist/version.js +1 -1
- package/node_modules/@oscharko-dev/keiko-security/package.json +2 -2
- package/node_modules/@oscharko-dev/keiko-server/dist/bounded-concurrency.d.ts +10 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/bounded-concurrency.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/bounded-concurrency.js +84 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/bounded-request-body.d.ts +13 -3
- package/node_modules/@oscharko-dev/keiko-server/dist/bounded-request-body.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/bounded-request-body.js +14 -25
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-activity.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-activity.js +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-compaction-resurfacing.d.ts +2 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-compaction-resurfacing.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-compaction-resurfacing.js +28 -7
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-compaction-thresholds.d.ts +5 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-compaction-thresholds.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-compaction-thresholds.js +8 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-context-breakdown.d.ts +25 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-context-breakdown.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-context-breakdown.js +111 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-context-log.d.ts +3 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-context-log.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-context-log.js +101 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-context-status.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-context-status.js +235 -33
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-continuity-log.d.ts +3 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-continuity-log.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-continuity-log.js +9 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-grounding.d.ts +4 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-grounding.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-grounding.js +7 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-handlers.d.ts +2 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-handlers.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-handlers.js +159 -79
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-history-snapshot.d.ts +27 -2
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-history-snapshot.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-history-snapshot.js +48 -7
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-prompt-budget.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-prompt-budget.js +3 -2
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-prompt-compaction.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-prompt-compaction.js +4 -2
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-scope-update-log.d.ts +3 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-scope-update-log.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-scope-update-log.js +51 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-stream-handlers.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/chat-stream-handlers.js +54 -21
- package/node_modules/@oscharko-dev/keiko-server/dist/client-diagnostics-routes.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/client-diagnostics-routes.js +523 -12
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-app-session/appSessionReadAuthority.d.ts +8 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-app-session/appSessionReadAuthority.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-app-session/appSessionReadAuthority.js +112 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-app-session/codingAppSessionRoutes.d.ts +4 -4
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-app-session/codingAppSessionRoutes.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-app-session/codingAppSessionRoutes.js +31 -17
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-app-session/sessionChannel.d.ts +6 -4
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-app-session/sessionChannel.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-app-session/sessionChannel.js +10 -10
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-app-session/sessionCookie.d.ts +9 -2
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-app-session/sessionCookie.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-app-session/sessionCookie.js +13 -3
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-app-session/sessionRegistry.d.ts +10 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-app-session/sessionRegistry.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-app-session/sessionRegistry.js +59 -5
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-context/githubIssueReaderAuthorization.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-context/githubIssueReaderAuthorization.js +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingHistoryRoutes.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingHistoryRoutes.js +8 -6
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRepositorySearchHandler.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingRepositorySearchHandler.js +85 -2
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingToolFacadePorts.d.ts +5 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/codingToolFacadePorts.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeLaunchProfile.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeLaunchProfile.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/opencodeLaunchProfile.js +6 -4
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionManagedWorktreeTools.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionManagedWorktreeTools.js +7 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-runtime/productionWorkspaceHeadReader.js +23 -3
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-sidecar-gateway.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-sidecar-gateway.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/coding-sidecar-gateway.js +31 -4
- package/node_modules/@oscharko-dev/keiko-server/dist/deps.d.ts +23 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/deps.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/deps.js +51 -4
- package/node_modules/@oscharko-dev/keiko-server/dist/diagnostics-log.d.ts +15 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/diagnostics-log.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/diagnostics-log.js +102 -6
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/agentAuthorityRegistry.d.ts +1 -3
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/agentAuthorityRegistry.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/agentAuthorityRegistry.js +5 -94
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/agentProducerRoute.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/agentProducerRoute.js +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/agentRoutes.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/agentRoutes.js +50 -57
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/agentSessionRegistry.d.ts +4 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/agentSessionRegistry.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/agentSessionRegistry.js +81 -10
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/bufferSafetyEvidence.d.ts +3 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/bufferSafetyEvidence.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/bufferSafetyEvidence.js +35 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/verificationExecution.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/verificationExecution.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/verificationExecution.js +29 -8
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/verificationRunner.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/verificationRunner.js +4 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/watch/workspaceWatchEvidence.d.ts +4 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/watch/workspaceWatchEvidence.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/watch/workspaceWatchEvidence.js +75 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/watch/workspaceWatchRoutes.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/watch/workspaceWatchRoutes.js +5 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/watch/workspaceWatchService.d.ts +3 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/watch/workspaceWatchService.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/editor/watch/workspaceWatchService.js +230 -34
- package/node_modules/@oscharko-dev/keiko-server/dist/files-deny.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/files-deny.js +3 -2
- package/node_modules/@oscharko-dev/keiko-server/dist/files.d.ts +2 -25
- package/node_modules/@oscharko-dev/keiko-server/dist/files.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/files.js +76 -35
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-context-window.d.ts +56 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-context-window.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-context-window.js +432 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-discovery-log.d.ts +15 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-discovery-log.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-discovery-log.js +59 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-instance-cache.d.ts +4 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-instance-cache.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-instance-cache.js +16 -5
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-readiness.d.ts +11 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-readiness.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-readiness.js +103 -37
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-reranker-probe.d.ts +16 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-reranker-probe.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-reranker-probe.js +30 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-setup.d.ts +24 -3
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-setup.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-setup.js +920 -150
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-spend-budget.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-spend-budget.js +6 -3
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-tool-calling-probe.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-tool-calling-probe.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gateway-tool-calling-probe.js +5 -3
- package/node_modules/@oscharko-dev/keiko-server/dist/gitChangeRoutes.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gitChangeRoutes.js +30 -11
- package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/ciObservationService.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/ciObservationService.js +17 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/commitDraftQuality.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/commitDraftQuality.js +5 -2
- package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/commitRoutes.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/commitRoutes.js +4 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/journeyObservationService.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/journeyObservationService.js +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/journeyRoutes.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/journeyRoutes.js +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/prDescriptionProjection.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/prDescriptionProjection.js +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/verifiedCommitService.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gitDelivery/verifiedCommitService.js +7 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/gitRepositoryRoutes.d.ts +5 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gitRepositoryRoutes.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gitRepositoryRoutes.js +68 -10
- package/node_modules/@oscharko-dev/keiko-server/dist/gitRoutes.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/gitRoutes.js +57 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-answer.d.ts +2 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-answer.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-answer.js +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-citation-log.d.ts +39 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-citation-log.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-citation-log.js +196 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-context-diagnostics.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-context-diagnostics.js +25 -11
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-context-pack-reranker.d.ts +2 -2
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-context-pack-reranker.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-context-pack-reranker.js +35 -3
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-conversation-continuity.d.ts +9 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-conversation-continuity.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-conversation-continuity.js +74 -21
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-directory-iteration.d.ts +8 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-directory-iteration.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-directory-iteration.js +60 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-document-evidence.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-document-evidence.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-document-evidence.js +2 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-entailment-stage.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-entailment-stage.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-entailment-stage.js +61 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-evidence-selection.d.ts +11 -2
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-evidence-selection.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-evidence-selection.js +78 -52
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-faithfulness-eval.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-faithfulness-eval.js +33 -4
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-faithfulness.d.ts +37 -6
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-faithfulness.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-faithfulness.js +444 -101
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-metadata-retention.d.ts +34 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-metadata-retention.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-metadata-retention.js +123 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-multi-source-budget.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-multi-source-budget.js +6 -6
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-orchestrator.d.ts +24 -3
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-orchestrator.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-orchestrator.js +2338 -629
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-overview-fallback.d.ts +3 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-overview-fallback.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-overview-fallback.js +81 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-pack-validation.d.ts +22 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-pack-validation.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-pack-validation.js +87 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-prompt-context.d.ts +19 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-prompt-context.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-prompt-context.js +33 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-prompt.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-prompt.js +11 -3
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-qa-hybrid.d.ts +17 -2
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-qa-hybrid.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-qa-hybrid.js +349 -162
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-qa-multi-source.d.ts +14 -3
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-qa-multi-source.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-qa-multi-source.js +241 -87
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-qa.d.ts +26 -4
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-qa.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-qa.js +384 -105
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-repo-semantic-search.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-repo-semantic-search.js +16 -14
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-rerank-facade.d.ts +2 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-rerank-facade.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-rerank-facade.js +36 -2
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-retrieval-eval.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-retrieval-eval.js +4 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-scope-context.d.ts +32 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-scope-context.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-scope-context.js +75 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-symbol-diagnostics.d.ts +4 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-symbol-diagnostics.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-symbol-diagnostics.js +109 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-symbol-trace.d.ts +3 -3
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-symbol-trace.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/grounded-symbol-trace.js +2 -2
- package/node_modules/@oscharko-dev/keiko-server/dist/index.d.ts +1 -2
- package/node_modules/@oscharko-dev/keiko-server/dist/index.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/index.js +8 -13
- package/node_modules/@oscharko-dev/keiko-server/dist/knowledge-prompt-window.d.ts +44 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/knowledge-prompt-window.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/knowledge-prompt-window.js +136 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/local-knowledge-grounded-qa.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/local-knowledge-grounded-qa.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/local-knowledge-grounded-qa.js +231 -65
- package/node_modules/@oscharko-dev/keiko-server/dist/local-knowledge-handlers.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/local-knowledge-handlers.js +19 -4
- package/node_modules/@oscharko-dev/keiko-server/dist/memory-consolidation-handlers.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/memory-consolidation-handlers.js +11 -9
- package/node_modules/@oscharko-dev/keiko-server/dist/memory-conv-handlers.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/memory-conv-handlers.js +11 -9
- package/node_modules/@oscharko-dev/keiko-server/dist/memory-handlers.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/memory-handlers.js +43 -32
- package/node_modules/@oscharko-dev/keiko-server/dist/observability/route-template.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/observability/route-template.js +2 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/figma/figmaSnapshotBuilder.js +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/figma/index.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/figma/index.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/figma/index.js +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/handoffRoutes.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/handoffRoutes.js +2 -2
- package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/modelPolicyRoutes.d.ts +2 -2
- package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/modelPolicyRoutes.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/modelPolicyRoutes.js +36 -14
- package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/runRoutes.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/runRoutes.js +4 -2
- package/node_modules/@oscharko-dev/keiko-server/dist/routes.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/routes.js +8 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/store/chat-grounding-scope-identity.d.ts +8 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/store/chat-grounding-scope-identity.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/store/chat-grounding-scope-identity.js +21 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/store/chats.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/store/chats.js +19 -3
- package/node_modules/@oscharko-dev/keiko-server/dist/store/db.d.ts +0 -13
- package/node_modules/@oscharko-dev/keiko-server/dist/store/db.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/store/db.js +26 -129
- package/node_modules/@oscharko-dev/keiko-server/dist/store/index.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/store/index.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/store/index.js +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/store/paths.d.ts +2 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/store/paths.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/store/paths.js +26 -42
- package/node_modules/@oscharko-dev/keiko-server/dist/store/schema.js +2 -2
- package/node_modules/@oscharko-dev/keiko-server/dist/store-handlers.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/store-handlers.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/store-handlers.js +102 -13
- package/node_modules/@oscharko-dev/keiko-server/dist/support-report-download.d.ts +13 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/support-report-download.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/support-report-download.js +239 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/support-report-evidence.d.ts +19 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/support-report-evidence.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/support-report-evidence.js +347 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/support-report-job.d.ts +31 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/support-report-job.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/support-report-job.js +169 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/support-report-routes.d.ts +4 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/support-report-routes.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/support-report-routes.js +152 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/support-report-worker.d.ts +2 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/support-report-worker.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/support-report-worker.js +43 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/task-workspace/local-checkout.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/task-workspace/local-checkout.js +37 -4
- package/node_modules/@oscharko-dev/keiko-server/dist/tool-catalog/catalogToolDispatch.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/tool-catalog/catalogToolDispatch.js +8 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/tool-catalog/catalogToolSettlement.d.ts +1 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/tool-catalog/catalogToolSettlement.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/tool-catalog/catalogToolSettlement.js +3 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/update-preflight-registry.d.ts +1 -2
- package/node_modules/@oscharko-dev/keiko-server/dist/update-preflight-registry.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/update-preflight-registry.js +3 -35
- package/node_modules/@oscharko-dev/keiko-server/dist/voice-speech-text.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/voice-speech-text.js +4 -0
- package/node_modules/@oscharko-dev/keiko-server/dist/workspace-root-denial-log.d.ts +4 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/workspace-root-denial-log.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/workspace-root-denial-log.js +76 -3
- package/node_modules/@oscharko-dev/keiko-server/dist/workspace-state-handlers.d.ts +3 -2
- package/node_modules/@oscharko-dev/keiko-server/dist/workspace-state-handlers.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/workspace-state-handlers.js +3 -100
- package/node_modules/@oscharko-dev/keiko-server/package.json +23 -23
- package/node_modules/@oscharko-dev/keiko-tool-catalog/dist/opencode.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-tool-catalog/dist/opencode.js +3 -1
- package/node_modules/@oscharko-dev/keiko-tool-catalog/package.json +3 -3
- package/node_modules/@oscharko-dev/keiko-tools/dist/exec.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-tools/dist/exec.js +36 -5
- package/node_modules/@oscharko-dev/keiko-tools/dist/version.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-tools/dist/version.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-tools/dist/version.js +1 -1
- package/node_modules/@oscharko-dev/keiko-tools/package.json +7 -7
- package/node_modules/@oscharko-dev/keiko-verification/dist/orchestrator.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-verification/dist/orchestrator.js +3 -1
- package/node_modules/@oscharko-dev/keiko-verification/package.json +5 -5
- package/node_modules/@oscharko-dev/keiko-workflows/dist/contextpack/assemble.d.ts +10 -1
- package/node_modules/@oscharko-dev/keiko-workflows/dist/contextpack/assemble.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workflows/dist/contextpack/assemble.js +327 -45
- package/node_modules/@oscharko-dev/keiko-workflows/dist/contextpack/compaction.js +1 -1
- package/node_modules/@oscharko-dev/keiko-workflows/dist/contextpack/index.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-workflows/dist/contextpack/index.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workflows/dist/contextpack/index.js +1 -1
- package/node_modules/@oscharko-dev/keiko-workflows/dist/planner/anchors.d.ts +4 -0
- package/node_modules/@oscharko-dev/keiko-workflows/dist/planner/anchors.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workflows/dist/planner/anchors.js +83 -32
- package/node_modules/@oscharko-dev/keiko-workflows/dist/planner/governor.js +1 -1
- package/node_modules/@oscharko-dev/keiko-workflows/dist/planner/index.d.ts +2 -2
- package/node_modules/@oscharko-dev/keiko-workflows/dist/planner/index.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workflows/dist/planner/index.js +1 -1
- package/node_modules/@oscharko-dev/keiko-workflows/dist/planner/intent.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workflows/dist/planner/intent.js +40 -3
- package/node_modules/@oscharko-dev/keiko-workflows/dist/planner/plan.d.ts +14 -1
- package/node_modules/@oscharko-dev/keiko-workflows/dist/planner/plan.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workflows/dist/planner/plan.js +209 -68
- package/node_modules/@oscharko-dev/keiko-workflows/dist/ranking/filter.d.ts +2 -0
- package/node_modules/@oscharko-dev/keiko-workflows/dist/ranking/filter.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workflows/dist/ranking/filter.js +8 -2
- package/node_modules/@oscharko-dev/keiko-workflows/dist/ranking/rank.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workflows/dist/ranking/rank.js +7 -60
- package/node_modules/@oscharko-dev/keiko-workflows/package.json +10 -10
- package/node_modules/@oscharko-dev/keiko-workspace/dist/_memfs.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/_memfs.js +7 -0
- package/node_modules/@oscharko-dev/keiko-workspace/dist/binaryDetect.d.ts +5 -2
- package/node_modules/@oscharko-dev/keiko-workspace/dist/binaryDetect.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/binaryDetect.js +159 -38
- package/node_modules/@oscharko-dev/keiko-workspace/dist/codeIntelligence.js +2 -2
- package/node_modules/@oscharko-dev/keiko-workspace/dist/codeIntelligenceSurface.d.ts +2 -0
- package/node_modules/@oscharko-dev/keiko-workspace/dist/codeIntelligenceSurface.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/codeIntelligenceSurface.js +2 -0
- package/node_modules/@oscharko-dev/keiko-workspace/dist/codingRepositorySearch.d.ts +5 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/codingRepositorySearch.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/codingRepositorySearch.js +140 -57
- package/node_modules/@oscharko-dev/keiko-workspace/dist/codingRepositorySearchResult.d.ts +1 -4
- package/node_modules/@oscharko-dev/keiko-workspace/dist/codingRepositorySearchResult.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/codingRepositorySearchResult.js +0 -15
- package/node_modules/@oscharko-dev/keiko-workspace/dist/discovery.d.ts +14 -0
- package/node_modules/@oscharko-dev/keiko-workspace/dist/discovery.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/discovery.js +235 -10
- package/node_modules/@oscharko-dev/keiko-workspace/dist/fs.d.ts +2 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/fs.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/fs.js +48 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/ignore.js +2 -2
- package/node_modules/@oscharko-dev/keiko-workspace/dist/importGraphEdges.js +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/index.d.ts +3 -2
- package/node_modules/@oscharko-dev/keiko-workspace/dist/index.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/index.js +3 -2
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearch.d.ts +31 -3
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearch.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearch.js +459 -137
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchEntries.d.ts +8 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchEntries.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchEntries.js +29 -24
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchExcerptWindow.d.ts +16 -0
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchExcerptWindow.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchExcerptWindow.js +189 -0
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchLineSelection.d.ts +3 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchLineSelection.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchLineSelection.js +45 -18
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchMatchers.d.ts +5 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchMatchers.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchMatchers.js +89 -30
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchPolicy.d.ts +21 -2
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchPolicy.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchPolicy.js +29 -5
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchRetention.d.ts +15 -0
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchRetention.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchRetention.js +70 -0
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchScan.d.ts +14 -2
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchScan.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchScan.js +178 -45
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchSemantic.d.ts +14 -2
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchSemantic.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchSemantic.js +63 -5
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchSourceInspection.d.ts +3 -0
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchSourceInspection.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchSourceInspection.js +37 -0
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchStream.d.ts +30 -0
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchStream.d.ts.map +1 -0
- package/node_modules/@oscharko-dev/keiko-workspace/dist/repoSearchStream.js +466 -0
- package/node_modules/@oscharko-dev/keiko-workspace/dist/structuralAdapterRequestContext.d.ts +6 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/structuralAdapterRequestContext.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/structuralAdapterRequestContext.js +32 -6
- package/node_modules/@oscharko-dev/keiko-workspace/dist/structuralAdapters.js +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/structuralExecution.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/structuralExecution.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/structuralExecution.js +60 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/testSourcePairing.js +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/testing.d.ts +2 -0
- package/node_modules/@oscharko-dev/keiko-workspace/dist/testing.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/testing.js +4 -0
- package/node_modules/@oscharko-dev/keiko-workspace/dist/version.d.ts +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/version.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/version.js +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/workspaceIndex.d.ts +2 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/workspaceIndex.d.ts.map +1 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/workspaceIndex.js +8 -1
- package/node_modules/@oscharko-dev/keiko-workspace/package.json +3 -3
- package/package.json +32 -31
- package/release-impact.catalog.json +111 -0
- package/scripts/lib/local-state-audit.mjs +26 -11
- package/vendor/oscharko-dev-keiko-activity-log-1.2.0.tgz +0 -0
- package/vendor/oscharko-dev-keiko-cli-1.2.0.tgz +0 -0
- package/vendor/{oscharko-dev-keiko-connectors-1.1.13.tgz → oscharko-dev-keiko-connectors-1.2.0.tgz} +0 -0
- package/vendor/oscharko-dev-keiko-contracts-1.2.0.tgz +0 -0
- package/vendor/{oscharko-dev-keiko-evaluations-1.1.13.tgz → oscharko-dev-keiko-evaluations-1.2.0.tgz} +0 -0
- package/vendor/oscharko-dev-keiko-evidence-1.2.0.tgz +0 -0
- package/vendor/{oscharko-dev-keiko-git-1.1.13.tgz → oscharko-dev-keiko-git-1.2.0.tgz} +0 -0
- package/vendor/{oscharko-dev-keiko-harness-1.1.13.tgz → oscharko-dev-keiko-harness-1.2.0.tgz} +0 -0
- package/vendor/oscharko-dev-keiko-local-knowledge-1.2.0.tgz +0 -0
- package/vendor/oscharko-dev-keiko-memory-capture-1.2.0.tgz +0 -0
- package/vendor/oscharko-dev-keiko-memory-consolidation-1.2.0.tgz +0 -0
- package/vendor/{oscharko-dev-keiko-memory-governance-1.1.13.tgz → oscharko-dev-keiko-memory-governance-1.2.0.tgz} +0 -0
- package/vendor/oscharko-dev-keiko-memory-retrieval-1.2.0.tgz +0 -0
- package/vendor/oscharko-dev-keiko-memory-vault-1.2.0.tgz +0 -0
- package/vendor/oscharko-dev-keiko-model-gateway-1.2.0.tgz +0 -0
- package/vendor/{oscharko-dev-keiko-quality-intelligence-1.1.13.tgz → oscharko-dev-keiko-quality-intelligence-1.2.0.tgz} +0 -0
- package/vendor/oscharko-dev-keiko-sandbox-1.2.0.tgz +0 -0
- package/vendor/{oscharko-dev-keiko-sdk-1.1.13.tgz → oscharko-dev-keiko-sdk-1.2.0.tgz} +0 -0
- package/vendor/oscharko-dev-keiko-security-1.2.0.tgz +0 -0
- package/vendor/oscharko-dev-keiko-server-1.2.0.tgz +0 -0
- package/vendor/oscharko-dev-keiko-tool-catalog-1.2.0.tgz +0 -0
- package/vendor/oscharko-dev-keiko-tools-1.2.0.tgz +0 -0
- package/vendor/oscharko-dev-keiko-verification-1.2.0.tgz +0 -0
- package/vendor/oscharko-dev-keiko-workflows-1.2.0.tgz +0 -0
- package/vendor/oscharko-dev-keiko-workspace-1.2.0.tgz +0 -0
- package/dist/ui/static/_next/static/chunks/000t9p2ysi3dv.css +0 -1
- package/dist/ui/static/_next/static/chunks/00dd_gyzi9unw.js +0 -1
- package/dist/ui/static/_next/static/chunks/00n029ow-5_tt.js +0 -3
- package/dist/ui/static/_next/static/chunks/01n8x8_z3012u.js +0 -1
- package/dist/ui/static/_next/static/chunks/04y8gqfjksqzo.js +0 -1
- package/dist/ui/static/_next/static/chunks/0cksy9u2ysiuy.js +0 -1
- package/dist/ui/static/_next/static/chunks/0elflgy2cg1jb.js +0 -1
- package/dist/ui/static/_next/static/chunks/0gia_iwqox3xm.js +0 -1
- package/dist/ui/static/_next/static/chunks/0k931k8qwqyft.js +0 -1
- package/dist/ui/static/_next/static/chunks/0kmepj4rmkj19.js +0 -1
- package/dist/ui/static/_next/static/chunks/0l46-80gche_i.js +0 -1
- package/dist/ui/static/_next/static/chunks/0ojvvjnsf38bk.js +0 -1
- package/dist/ui/static/_next/static/chunks/0p2ekj8g4s6t2.js +0 -1
- package/dist/ui/static/_next/static/chunks/0qt-w4yzb50ov.js +0 -1
- package/dist/ui/static/_next/static/chunks/0tl_05c5ux5ut.js +0 -1
- package/dist/ui/static/_next/static/chunks/0v9jkxfma7fks.js +0 -1
- package/dist/ui/static/_next/static/chunks/0y68jeskhcm2k.js +0 -1
- package/dist/ui/static/_next/static/chunks/0z5be09yla9lp.js +0 -1
- package/dist/ui/static/_next/static/chunks/117xhn896fsmt.js +0 -1
- package/dist/ui/static/_next/static/chunks/13q3e5wnz6lps.css +0 -1
- package/dist/ui/static/_next/static/chunks/14rs31u4u36yy.js +0 -1
- package/dist/ui/static/_next/static/chunks/159szpr5ffygs.js +0 -1
- package/dist/ui/static/_next/static/chunks/15orau2hhjb1f.js +0 -1
- package/dist/ui/static/_next/static/chunks/1b7ig6f2t71i_.js +0 -1
- package/dist/ui/static/_next/static/chunks/1bdojlx9hv0c5.js +0 -1
- package/dist/ui/static/_next/static/chunks/1be0-x1mk56wu.js +0 -1
- package/dist/ui/static/_next/static/chunks/1d7xigpwq-xq8.js +0 -1
- package/dist/ui/static/_next/static/chunks/1dwc7p2rl-hs6.js +0 -1
- package/dist/ui/static/_next/static/chunks/1hk335vrug1rc.js +0 -1
- package/dist/ui/static/_next/static/chunks/1hucqkor7zgbn.js +0 -1
- package/dist/ui/static/_next/static/chunks/1j6nqp8yrqyhu.js +0 -1
- package/dist/ui/static/_next/static/chunks/1kxhf3ld28pzk.js +0 -1
- package/dist/ui/static/_next/static/chunks/1logclobi6726.js +0 -1
- package/dist/ui/static/_next/static/chunks/1lrj3d157kay1.js +0 -5
- package/dist/ui/static/_next/static/chunks/1nie2fvj8iyvq.js +0 -1
- package/dist/ui/static/_next/static/chunks/1o3z4r4xrlbda.js +0 -1
- package/dist/ui/static/_next/static/chunks/1pnysuel-a2r1.js +0 -1
- package/dist/ui/static/_next/static/chunks/1szpnddxqmzhy.js +0 -1
- package/dist/ui/static/_next/static/chunks/1tkt9f0xnc4fe.js +0 -1
- package/dist/ui/static/_next/static/chunks/1u_s3uvh9p4j7.js +0 -1
- package/dist/ui/static/_next/static/chunks/1uetvnnpa5z22.js +0 -1
- package/dist/ui/static/_next/static/chunks/1uigiy7xdzirs.js +0 -1
- package/dist/ui/static/_next/static/chunks/1uulmf99vtuyt.js +0 -1
- package/dist/ui/static/_next/static/chunks/1wa9m6c88mg3p.js +0 -1
- package/dist/ui/static/_next/static/chunks/1xzxhtenb7_sx.css +0 -1
- package/dist/ui/static/_next/static/chunks/202kx3p8axlmr.js +0 -1
- package/dist/ui/static/_next/static/chunks/20b456jf1ggzu.css +0 -1
- package/dist/ui/static/_next/static/chunks/2384n1pce2w1h.js +0 -1
- package/dist/ui/static/_next/static/chunks/252wybdcea74g.js +0 -1
- package/dist/ui/static/_next/static/chunks/271r_v0nh0vy-.js +0 -1
- package/dist/ui/static/_next/static/chunks/2_o61-akoq549.js +0 -1
- package/dist/ui/static/_next/static/chunks/2_u63ddjyhbpm.js +0 -3
- package/dist/ui/static/_next/static/chunks/2b78j2josay3e.js +0 -1
- package/dist/ui/static/_next/static/chunks/2cw7v8t4jg669.js +0 -1
- package/dist/ui/static/_next/static/chunks/2gqs8fif3137x.js +0 -3
- package/dist/ui/static/_next/static/chunks/2iehfums033xv.css +0 -3
- package/dist/ui/static/_next/static/chunks/2j16o4ghz4iqx.js +0 -1
- package/dist/ui/static/_next/static/chunks/2oxvgl3qb19wf.js +0 -1
- package/dist/ui/static/_next/static/chunks/2s5wt9bf-ox40.js +0 -1
- package/dist/ui/static/_next/static/chunks/2s9-91g2jic6u.js +0 -1
- package/dist/ui/static/_next/static/chunks/2tmor5n3xss6c.js +0 -3
- package/dist/ui/static/_next/static/chunks/2wd7di0z2l6il.js +0 -1
- package/dist/ui/static/_next/static/chunks/2ymm_n9gbcdcw.js +0 -1
- package/dist/ui/static/_next/static/chunks/2ywqac8g8us1n.css +0 -1
- package/dist/ui/static/_next/static/chunks/3-ys11qyww0y6.js +0 -1
- package/dist/ui/static/_next/static/chunks/30botqyyk9ugo.js +0 -1
- package/dist/ui/static/_next/static/chunks/30p9b535cwzhr.js +0 -1
- package/dist/ui/static/_next/static/chunks/31mnda46lo2b0.js +0 -1
- package/dist/ui/static/_next/static/chunks/338jl640mvtkg.js +0 -1
- package/dist/ui/static/_next/static/chunks/351uy__m9eafa.js +0 -1
- package/dist/ui/static/_next/static/chunks/3_cgafsc6hy1_.js +0 -1
- package/dist/ui/static/_next/static/chunks/3_exo95bp9tt2.js +0 -1
- package/dist/ui/static/_next/static/chunks/3aqtjd-a1ygis.js +0 -1
- package/dist/ui/static/_next/static/chunks/3bl12pe7lsanc.js +0 -1
- package/dist/ui/static/_next/static/chunks/3buu6m28ig2oz.js +0 -1
- package/dist/ui/static/_next/static/chunks/3hft62celuigp.js +0 -1
- package/dist/ui/static/_next/static/chunks/3ibevys2o09xx.js +0 -1
- package/dist/ui/static/_next/static/chunks/3im1pldojqzmu.js +0 -1
- package/dist/ui/static/_next/static/chunks/3iptbrztxckih.js +0 -1
- package/dist/ui/static/_next/static/chunks/3iv5llh4xg-7v.js +0 -1
- package/dist/ui/static/_next/static/chunks/3jtbes4v4ouyw.js +0 -1
- package/dist/ui/static/_next/static/chunks/3lq5zd1qvhcfw.js +0 -1
- package/dist/ui/static/_next/static/chunks/3m_idsf90zq5u.js +0 -1
- package/dist/ui/static/_next/static/chunks/3mes_qld9wgti.js +0 -1
- package/dist/ui/static/_next/static/chunks/3n4gsbv-im5ia.js +0 -1
- package/dist/ui/static/_next/static/chunks/3timx0h4kcna0.js +0 -1
- package/dist/ui/static/_next/static/chunks/3u-4amh4iusi1.js +0 -1
- package/dist/ui/static/_next/static/chunks/3uacpjje41xz5.js +0 -1
- package/dist/ui/static/_next/static/chunks/3uovpxgynmdkk.js +0 -1
- package/dist/ui/static/_next/static/chunks/3wcuc7e2bz4-l.js +0 -1
- package/dist/ui/static/_next/static/chunks/3xaa0t5drdxz3.js +0 -1
- package/dist/ui/static/_next/static/chunks/3yqrxwndy9_f3.js +0 -1
- package/dist/ui/static/_next/static/chunks/40g2_9ovqiuiu.js +0 -1
- package/dist/ui/static/_next/static/chunks/40ol4dc9uptck.js +0 -10
- package/dist/ui/static/_next/static/chunks/413lmui4la1xe.js +0 -1
- package/dist/ui/static/_next/static/chunks/41ca6l5ikqt65.js +0 -1
- package/dist/ui/static/_next/static/chunks/44jv6p8ly-u3e.js +0 -1
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-selective-export.d.ts +0 -29
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-selective-export.d.ts.map +0 -1
- package/node_modules/@oscharko-dev/keiko-activity-log/dist/reader/support-selective-export.js +0 -30
- package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/figma/figmaConcurrency.d.ts +0 -8
- package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/figma/figmaConcurrency.d.ts.map +0 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/qualityIntelligence/figma/figmaConcurrency.js +0 -34
- package/node_modules/@oscharko-dev/keiko-server/dist/store-fingerprints.d.ts +0 -29
- package/node_modules/@oscharko-dev/keiko-server/dist/store-fingerprints.d.ts.map +0 -1
- package/node_modules/@oscharko-dev/keiko-server/dist/store-fingerprints.js +0 -135
- package/node_modules/@oscharko-dev/keiko-workspace/dist/codingRepositorySearchInventory.d.ts +0 -7
- package/node_modules/@oscharko-dev/keiko-workspace/dist/codingRepositorySearchInventory.d.ts.map +0 -1
- package/node_modules/@oscharko-dev/keiko-workspace/dist/codingRepositorySearchInventory.js +0 -24
- package/vendor/oscharko-dev-keiko-activity-log-1.1.13.tgz +0 -0
- package/vendor/oscharko-dev-keiko-cli-1.1.13.tgz +0 -0
- package/vendor/oscharko-dev-keiko-contracts-1.1.13.tgz +0 -0
- package/vendor/oscharko-dev-keiko-evidence-1.1.13.tgz +0 -0
- package/vendor/oscharko-dev-keiko-local-knowledge-1.1.13.tgz +0 -0
- package/vendor/oscharko-dev-keiko-memory-capture-1.1.13.tgz +0 -0
- package/vendor/oscharko-dev-keiko-memory-consolidation-1.1.13.tgz +0 -0
- package/vendor/oscharko-dev-keiko-memory-retrieval-1.1.13.tgz +0 -0
- package/vendor/oscharko-dev-keiko-memory-vault-1.1.13.tgz +0 -0
- package/vendor/oscharko-dev-keiko-model-gateway-1.1.13.tgz +0 -0
- package/vendor/oscharko-dev-keiko-sandbox-1.1.13.tgz +0 -0
- package/vendor/oscharko-dev-keiko-security-1.1.13.tgz +0 -0
- package/vendor/oscharko-dev-keiko-server-1.1.13.tgz +0 -0
- package/vendor/oscharko-dev-keiko-tool-catalog-1.1.13.tgz +0 -0
- package/vendor/oscharko-dev-keiko-tools-1.1.13.tgz +0 -0
- package/vendor/oscharko-dev-keiko-verification-1.1.13.tgz +0 -0
- package/vendor/oscharko-dev-keiko-workflows-1.1.13.tgz +0 -0
- package/vendor/oscharko-dev-keiko-workspace-1.1.13.tgz +0 -0
- /package/dist/ui/static/_next/static/{-GseUdaJoAYnEgt-Dl41f → LNCY1B2FJBOe2AHFXpzB-}/_buildManifest.js +0 -0
- /package/dist/ui/static/_next/static/{-GseUdaJoAYnEgt-Dl41f → LNCY1B2FJBOe2AHFXpzB-}/_clientMiddlewareManifest.js +0 -0
- /package/dist/ui/static/_next/static/{-GseUdaJoAYnEgt-Dl41f → LNCY1B2FJBOe2AHFXpzB-}/_ssgManifest.js +0 -0
|
@@ -1,17 +1,19 @@
|
|
|
1
|
-
import { logAliasIntersection } from "./gateway-discovery-log.js";
|
|
1
|
+
import { logAliasIntersection, logRerankerSetupResolution, } from "./gateway-discovery-log.js";
|
|
2
2
|
import { gatewaySpendBudgetForEnv, reserveGatewaySpendForAttempt } from "./gateway-spend-budget.js";
|
|
3
3
|
// First-run gateway setup for non-technical UI users. The browser provides a base URL, API token,
|
|
4
4
|
// and optionally a Figma PAT; the loopback BFF builds the local provider config, performs a real
|
|
5
5
|
// chat-completions smoke call, stores the resulting config on disk with private permissions, and
|
|
6
6
|
// updates the in-memory runtime config without exposing credentials back to the browser.
|
|
7
7
|
import { randomUUID } from "node:crypto";
|
|
8
|
+
import { causeChain, keikoStackFrames } from "@oscharko-dev/keiko-activity-log";
|
|
9
|
+
import { createRequestCancellation } from "./request-cancellation.js";
|
|
8
10
|
import { existsSync, readFileSync } from "node:fs";
|
|
9
11
|
import { resolveEvidenceDir } from "@oscharko-dev/keiko-evidence";
|
|
10
12
|
import { apiKeyHeaderValue, ConfigInvalidError, DEFAULT_API_KEY_HEADER_NAME, ERROR_CODES, Gateway, GATEWAY_CONFIG_SCHEMA_VERSION, createDefaultChatCapability, createDefaultEmbeddingCapability, findConfiguredCapability, GatewayError, MODEL_REASONING_EFFORTS, isLikelyEmbeddingModelId, isVoiceCapability, isCompleteRealtimeVoiceCapability, listConfiguredCapabilities, loadConfigFromFile, modelSupportsRealtimeVoice, modelSupportsSpeechInput, modelSupportsSpeechOutput, normalizeApiKeyHeaderName, parseGatewayConfig, requestOpenAIEmbedding, selectRealtimeVoiceModel, selectSpeechOutputModel, selectSpeechToTextModel, toSafeObject, validateBaseUrl, PROVIDER_ENDPOINT_STYLES, REALTIME_AUTH_MODES, toolCallingConfigurationFingerprint, VOICE_PROVIDER_LOCALITIES,
|
|
11
13
|
// KEIKO-0572: shared circuitBreaker defaults; hoisted into this import block instead of the
|
|
12
14
|
// separate `import { DEFAULT_CIRCUIT_BREAKER_CONFIG } from ...` line Sonar S3863 flagged.
|
|
13
15
|
DEFAULT_CIRCUIT_BREAKER_CONFIG, } from "@oscharko-dev/keiko-model-gateway";
|
|
14
|
-
import { boundedUnsupportedReason, isChatCompatibleDeclaredMode, modelKindForDeclaredMode, } from "@oscharko-dev/keiko-contracts/runtime/gateway";
|
|
16
|
+
import { boundedUnsupportedReason, isChatCompatibleDeclaredMode, isLikelyRerankModelId, modelKindForDeclaredMode, } from "@oscharko-dev/keiko-contracts/runtime/gateway";
|
|
15
17
|
import { GATEWAY_SETUP_AUDIT_SCHEMA_VERSION, validateGatewaySetupAuditRecord, } from "@oscharko-dev/keiko-contracts/runtime/gateway-setup-audit";
|
|
16
18
|
import { activityLogEvent, defineActivityLogOperation, } from "@oscharko-dev/keiko-contracts/runtime/observability";
|
|
17
19
|
import { classifyOutboundHost, gatewayFetch, readJsonCapped, } from "@oscharko-dev/keiko-model-gateway/internal/http";
|
|
@@ -27,6 +29,7 @@ import { buildQiJudgePreflightRequest, tryParseJudgeVerdict, } from "./qualityIn
|
|
|
27
29
|
import { persistSealedGatewayConfig } from "./credentialPersistence.js";
|
|
28
30
|
import { bindSecurityLogCorrelation } from "@oscharko-dev/keiko-security";
|
|
29
31
|
import { probeGatewayToolCalling, transientGatewayStatus } from "./gateway-tool-calling-probe.js";
|
|
32
|
+
import { requestRerankerProbe, rerankerProbePassed } from "./gateway-reranker-probe.js";
|
|
30
33
|
const MODEL_REASONING_EFFORT_SET = new Set(MODEL_REASONING_EFFORTS);
|
|
31
34
|
function isModelReasoningEffort(value) {
|
|
32
35
|
return MODEL_REASONING_EFFORT_SET.has(value);
|
|
@@ -49,6 +52,8 @@ const MISTRAL_TOOL_CALLING_LIMITATION = "Tool calling is disabled by default for
|
|
|
49
52
|
// exact value instead of restating it (Issue #144 precedent — see `MAX_DISCOVERED_MODELS`).
|
|
50
53
|
export const DISCOVERED_MODEL_SMOKE_TIMEOUT_MS = 120_000;
|
|
51
54
|
const DEPLOYMENT_SMOKE_TIMEOUT_MS = 30_000;
|
|
55
|
+
const DISCOVERY_TIMEOUT_MS = 30_000;
|
|
56
|
+
const DISCOVERY_FALLBACK_RESERVE_MS = 5_000;
|
|
52
57
|
// The whole discovery smoke ROUND's own patience budget — distinct from the per-candidate ceiling
|
|
53
58
|
// above. Past this deadline no further candidate probe is even started: the remaining candidates
|
|
54
59
|
// are retained unverified without being called, so a large discovery batch of temporarily-transient
|
|
@@ -109,6 +114,97 @@ const GATEWAY_VOICE_SETUP_OPERATION = defineActivityLogOperation({
|
|
|
109
114
|
proofIds: ["gateway.voice.setup.resolved.line"],
|
|
110
115
|
releaseImpact: "minor",
|
|
111
116
|
});
|
|
117
|
+
const DISCOVERY_ROUTE_OUTCOME_FIELD = {
|
|
118
|
+
type: "string",
|
|
119
|
+
dataClass: "closed-enum",
|
|
120
|
+
required: true,
|
|
121
|
+
values: [
|
|
122
|
+
"not-attempted",
|
|
123
|
+
"available",
|
|
124
|
+
"timeout",
|
|
125
|
+
"http-error",
|
|
126
|
+
"unusable",
|
|
127
|
+
"transport-error",
|
|
128
|
+
"cancelled",
|
|
129
|
+
"failed",
|
|
130
|
+
],
|
|
131
|
+
};
|
|
132
|
+
function createSetupDiscoveryTrace() {
|
|
133
|
+
return {
|
|
134
|
+
discoverySource: "custom",
|
|
135
|
+
modelInfoOutcome: "not-attempted",
|
|
136
|
+
modelGroupInfoOutcome: "not-attempted",
|
|
137
|
+
modelListOutcome: "not-attempted",
|
|
138
|
+
};
|
|
139
|
+
}
|
|
140
|
+
const GATEWAY_SETUP_METADATA_OPERATION = defineActivityLogOperation({
|
|
141
|
+
contractKind: "activity-log-operation",
|
|
142
|
+
schemaVersion: 1,
|
|
143
|
+
op: "gateway.setup.metadata.resolved",
|
|
144
|
+
category: "gateway",
|
|
145
|
+
owner: "keiko-server",
|
|
146
|
+
emitter: "gateway-setup.logSetupMetadataOutcome",
|
|
147
|
+
fields: {
|
|
148
|
+
outcome: {
|
|
149
|
+
type: "string",
|
|
150
|
+
dataClass: "closed-enum",
|
|
151
|
+
required: true,
|
|
152
|
+
values: ["available", "unavailable", "cancelled", "failed"],
|
|
153
|
+
},
|
|
154
|
+
discoverySource: {
|
|
155
|
+
type: "string",
|
|
156
|
+
dataClass: "closed-enum",
|
|
157
|
+
required: true,
|
|
158
|
+
values: ["custom", "model-info", "model-group-info", "model-list"],
|
|
159
|
+
},
|
|
160
|
+
modelInfoOutcome: DISCOVERY_ROUTE_OUTCOME_FIELD,
|
|
161
|
+
modelGroupInfoOutcome: DISCOVERY_ROUTE_OUTCOME_FIELD,
|
|
162
|
+
modelListOutcome: DISCOVERY_ROUTE_OUTCOME_FIELD,
|
|
163
|
+
elapsedMs: { type: "integer", dataClass: "duration", required: true },
|
|
164
|
+
selectedModelCount: { type: "integer", dataClass: "count", required: false },
|
|
165
|
+
metadataEnrichedModelCount: { type: "integer", dataClass: "count", required: false },
|
|
166
|
+
roleMismatchModelCount: { type: "integer", dataClass: "count", required: false },
|
|
167
|
+
notDiscoveredModelCount: { type: "integer", dataClass: "count", required: false },
|
|
168
|
+
httpStatus: { type: "integer", dataClass: "count", required: false },
|
|
169
|
+
frames: {
|
|
170
|
+
type: "string-array",
|
|
171
|
+
dataClass: "safe-platform-class",
|
|
172
|
+
required: false,
|
|
173
|
+
maxItems: 8,
|
|
174
|
+
maxLength: 512,
|
|
175
|
+
},
|
|
176
|
+
causeChain: {
|
|
177
|
+
type: "string-array",
|
|
178
|
+
dataClass: "error-kind",
|
|
179
|
+
required: false,
|
|
180
|
+
maxItems: 5,
|
|
181
|
+
maxLength: 128,
|
|
182
|
+
},
|
|
183
|
+
completeness: { type: "string", dataClass: "completeness-state", required: true },
|
|
184
|
+
loss: { type: "string", dataClass: "loss-state", required: true },
|
|
185
|
+
},
|
|
186
|
+
causal: "correlation",
|
|
187
|
+
lifecycle: "state",
|
|
188
|
+
analyzerProjection: "timeline",
|
|
189
|
+
failureClasses: ["gateway-setup-metadata"],
|
|
190
|
+
proofIds: ["gateway.setup.metadata.resolved.line"],
|
|
191
|
+
releaseImpact: "patch",
|
|
192
|
+
});
|
|
193
|
+
function logSetupMetadataOutcome(input, trace, startedAt, correlationId) {
|
|
194
|
+
const failure = input.outcome === "available" ? undefined : input.failure;
|
|
195
|
+
processServerLogSink().write(activityLogEvent(GATEWAY_SETUP_METADATA_OPERATION, {
|
|
196
|
+
correlationId: correlationIdOrUnknown(correlationId),
|
|
197
|
+
...(failure === undefined ? {} : { errorKind: failure.errorKind }),
|
|
198
|
+
}, {
|
|
199
|
+
outcome: input.outcome,
|
|
200
|
+
...trace,
|
|
201
|
+
elapsedMs: Math.max(0, Date.now() - startedAt),
|
|
202
|
+
completeness: "complete",
|
|
203
|
+
loss: "none",
|
|
204
|
+
...input.selectionCounts,
|
|
205
|
+
...failure?.evidence,
|
|
206
|
+
}));
|
|
207
|
+
}
|
|
112
208
|
const FIGMA_CREDENTIAL_SMOKE_TIMEOUT_MS = 15_000;
|
|
113
209
|
const FIGMA_CREDENTIAL_SMOKE_RESPONSE_BYTES = 64_000;
|
|
114
210
|
const SETUP_SMOKE_CONCURRENCY = 4;
|
|
@@ -379,6 +475,9 @@ function discoveredCapabilityFields(discovered) {
|
|
|
379
475
|
// Keiko's forced tool call. Keep it out of toolCalling: only the live probe can enable tools.
|
|
380
476
|
return {
|
|
381
477
|
...(discovered?.contextWindow === undefined ? {} : { contextWindow: discovered.contextWindow }),
|
|
478
|
+
...(discovered?.maxInputTokens === undefined
|
|
479
|
+
? {}
|
|
480
|
+
: { maxInputTokens: discovered.maxInputTokens }),
|
|
382
481
|
...(discovered?.maxOutputTokens === undefined
|
|
383
482
|
? {}
|
|
384
483
|
: { maxOutputTokens: discovered.maxOutputTokens }),
|
|
@@ -403,6 +502,16 @@ function workflowCapabilityFields(modelId, baseCapability, existing, workflowEli
|
|
|
403
502
|
preferredUseCases: codingUseCases(existing ?? baseCapability),
|
|
404
503
|
};
|
|
405
504
|
}
|
|
505
|
+
function declaresContextWindow(discovered) {
|
|
506
|
+
return discovered?.contextWindow !== undefined && discovered.contextWindowUndeclared !== true;
|
|
507
|
+
}
|
|
508
|
+
// Only declared context geometry replaces a stored optional input ceiling; a degraded list preserves it.
|
|
509
|
+
function refreshedSetupCapability(existing, discovered) {
|
|
510
|
+
if (existing === undefined || !declaresContextWindow(discovered))
|
|
511
|
+
return existing;
|
|
512
|
+
const { maxInputTokens, ...retained } = existing;
|
|
513
|
+
return retained;
|
|
514
|
+
}
|
|
406
515
|
function createDefaultSetupCapability(modelId, baseUrl, embeddingModelIds, options) {
|
|
407
516
|
const baseCapability = embeddingModelIds?.includes(modelId) === true
|
|
408
517
|
? createDefaultEmbeddingCapability(modelId)
|
|
@@ -421,9 +530,9 @@ function createDefaultSetupCapability(modelId, baseUrl, embeddingModelIds, optio
|
|
|
421
530
|
// fields (contextWindow, maxOutputTokens) belong to the wrong kind — a chat capability with an
|
|
422
531
|
// embedding's contextWindow: 0 fails config-parse under KEIKO-0520. Treat existing as absent
|
|
423
532
|
// when its kind no longer matches so the flow restarts from baseCapability's defaults.
|
|
424
|
-
const existing = rawExisting?.kind === baseCapability.kind ? rawExisting : undefined;
|
|
425
533
|
const discovered = options.modelMetadata?.[modelId];
|
|
426
|
-
const
|
|
534
|
+
const existing = refreshedSetupCapability(rawExisting?.kind === baseCapability.kind ? rawExisting : undefined, discovered);
|
|
535
|
+
const capability = withContextWindowProvenance(existing, discovered, {
|
|
427
536
|
...baseCapability,
|
|
428
537
|
// The endpoint-move restriction is PRESERVE semantics: a fresh replacement deliberately
|
|
429
538
|
// treats stored capabilities as absent, like every stored list on this route (review
|
|
@@ -436,9 +545,28 @@ function createDefaultSetupCapability(modelId, baseUrl, embeddingModelIds, optio
|
|
|
436
545
|
id: modelId,
|
|
437
546
|
kind: baseCapability.kind,
|
|
438
547
|
...workflowCapabilityFields(modelId, baseCapability, existing, options.workflowEligibleModelIds),
|
|
439
|
-
};
|
|
548
|
+
});
|
|
440
549
|
return capability;
|
|
441
550
|
}
|
|
551
|
+
/** The capability without its window provenance flags (assumed / provider-reported). */
|
|
552
|
+
export function withoutAssumedContextWindow(capability) {
|
|
553
|
+
const { contextWindowAssumed, contextWindowReported, ...measured } = capability;
|
|
554
|
+
return contextWindowAssumed === true || contextWindowReported === true ? measured : capability;
|
|
555
|
+
}
|
|
556
|
+
// A window is assumed only while nobody has stated it: a discovered declaration ends the
|
|
557
|
+
// assumption, a stored capability keeps its own provenance (a probed or provider-reported window
|
|
558
|
+
// survives a rediscovery that declares nothing), and a brand-new chat model starts assumed.
|
|
559
|
+
function withContextWindowProvenance(existing, discovered, capability) {
|
|
560
|
+
const measured = withoutAssumedContextWindow(capability);
|
|
561
|
+
if (capability.kind !== "chat" || declaresContextWindow(discovered))
|
|
562
|
+
return measured;
|
|
563
|
+
if (existing === undefined || existing.contextWindowAssumed === true) {
|
|
564
|
+
return { ...measured, contextWindowAssumed: true };
|
|
565
|
+
}
|
|
566
|
+
return existing.contextWindowReported === true
|
|
567
|
+
? { ...measured, contextWindowReported: true }
|
|
568
|
+
: measured;
|
|
569
|
+
}
|
|
442
570
|
// The generic endpoint protocol persists VERBATIM — absent fields stay absent so the runtime
|
|
443
571
|
// default layering is unchanged (#3042).
|
|
444
572
|
function genericEndpointProtocolRaw(options) {
|
|
@@ -593,9 +721,21 @@ function reasoningEffortsFromDiscoveryRecords(records) {
|
|
|
593
721
|
? [...new Set(stringListFieldFromRecords(records, fields).filter(isModelReasoningEffort))]
|
|
594
722
|
: undefined;
|
|
595
723
|
}
|
|
724
|
+
// Explicit total-window declarations are distinct from LiteLLM's prompt-input ceiling.
|
|
725
|
+
// All declarations of the same constraint intersect; replicas cannot widen a smaller bound.
|
|
726
|
+
const DECLARED_CONTEXT_WINDOW_FIELDS = [
|
|
727
|
+
"max_model_len",
|
|
728
|
+
"context_length",
|
|
729
|
+
"context_window",
|
|
730
|
+
];
|
|
731
|
+
function declaredContextWindow(records) {
|
|
732
|
+
return (numberFieldFromRecords(records, DECLARED_CONTEXT_WINDOW_FIELDS) ??
|
|
733
|
+
numberFieldFromRecords(records, ["max_input_tokens"]));
|
|
734
|
+
}
|
|
596
735
|
function metadataFromDiscoveryItem(item) {
|
|
597
736
|
const records = discoveryRecords(item);
|
|
598
|
-
const contextWindow =
|
|
737
|
+
const contextWindow = declaredContextWindow(records);
|
|
738
|
+
const maxInputTokens = numberFieldFromRecords(records, ["max_input_tokens"]);
|
|
599
739
|
const maxOutputTokens = numberFieldFromRecords(records, ["max_output_tokens", "max_tokens"]);
|
|
600
740
|
const toolCalling = optionalBooleanFieldFromRecords(records, [
|
|
601
741
|
"supports_function_calling",
|
|
@@ -609,6 +749,7 @@ function metadataFromDiscoveryItem(item) {
|
|
|
609
749
|
const chatModeDeclared = declaresChatCompatibleMode(mode);
|
|
610
750
|
return {
|
|
611
751
|
...(contextWindow === undefined ? {} : { contextWindow }),
|
|
752
|
+
...(maxInputTokens === undefined ? {} : { maxInputTokens }),
|
|
612
753
|
...(maxOutputTokens === undefined ? {} : { maxOutputTokens }),
|
|
613
754
|
...(toolCalling === undefined ? {} : { toolCalling }),
|
|
614
755
|
...(reasoningEfforts === undefined ? {} : { reasoningEfforts }),
|
|
@@ -787,6 +928,15 @@ export function rawConfigFromCurrent(config, figmaAccessToken, timeoutMs) {
|
|
|
787
928
|
...(config.grounding === undefined ? {} : { grounding: config.grounding }),
|
|
788
929
|
...(config.reranker === undefined ? {} : { reranker: config.reranker }),
|
|
789
930
|
...(figmaAccessToken === undefined ? {} : { figma: { accessToken: figmaAccessToken } }),
|
|
931
|
+
...operatorPolicyBlocks(config),
|
|
932
|
+
};
|
|
933
|
+
}
|
|
934
|
+
// Operator-declared blocks no setup step produces: they survive every rebuild verbatim, so a
|
|
935
|
+
// capability update never drops the grounded-answer policy or the PR branding (PR #3678).
|
|
936
|
+
function operatorPolicyBlocks(config) {
|
|
937
|
+
return {
|
|
938
|
+
...(config?.groundedAnswers === undefined ? {} : { groundedAnswers: config.groundedAnswers }),
|
|
939
|
+
...(config?.branding === undefined ? {} : { branding: config.branding }),
|
|
790
940
|
};
|
|
791
941
|
}
|
|
792
942
|
function rawCapabilityIsVoice(value) {
|
|
@@ -955,11 +1105,40 @@ export function isExplicitlyNonChatModel(item) {
|
|
|
955
1105
|
function isUnsupportedEntry(entry) {
|
|
956
1106
|
return entry.kind === "unsupported" && entry.reason !== undefined;
|
|
957
1107
|
}
|
|
1108
|
+
// A rerank engine is recognised and REPORTED here, never configured as chat or embedding. Setup
|
|
1109
|
+
// wires it as the retrieval reranker afterwards, and only when a live probe answers — the entry
|
|
1110
|
+
// stays in the unsupported list until then, and after it whenever the operator already owns one.
|
|
1111
|
+
function rerankDiscoveryModel(id, metadata, declared) {
|
|
1112
|
+
return {
|
|
1113
|
+
id,
|
|
1114
|
+
kind: "unsupported",
|
|
1115
|
+
...(declared ? { declaredNonChat: true } : {}),
|
|
1116
|
+
supportsImageInput: false,
|
|
1117
|
+
metadata,
|
|
1118
|
+
reason: "rerank",
|
|
1119
|
+
};
|
|
1120
|
+
}
|
|
958
1121
|
// Classification WITHOUT a declaration: the id heuristic is all a `/models`-only gateway gives us.
|
|
1122
|
+
// A name that says "reranker" is decided FIRST — "bge-reranker-v2-m3" carries the "bge" embedding
|
|
1123
|
+
// family prefix and must never be claimed as an embedding model. `capabilities.chat_completion ===
|
|
1124
|
+
// false` states what the model is NOT, which is not a role: an embedding model legitimately carries
|
|
1125
|
+
// it, so the id heuristic still decides and cannot fall through to "chat".
|
|
959
1126
|
function classifyUndeclaredDiscoveryItem(item, id, metadata) {
|
|
1127
|
+
if (isLikelyRerankModelId(id))
|
|
1128
|
+
return rerankDiscoveryModel(id, metadata, false);
|
|
960
1129
|
if (isLikelyEmbeddingModelId(id)) {
|
|
961
1130
|
return { id, kind: "embedding", supportsImageInput: false, metadata };
|
|
962
1131
|
}
|
|
1132
|
+
if (isExplicitlyNonChatModel(item)) {
|
|
1133
|
+
return {
|
|
1134
|
+
id,
|
|
1135
|
+
kind: "unsupported",
|
|
1136
|
+
supportsImageInput: false,
|
|
1137
|
+
metadata,
|
|
1138
|
+
reason: "not-chat-capable",
|
|
1139
|
+
declaredNonChat: true,
|
|
1140
|
+
};
|
|
1141
|
+
}
|
|
963
1142
|
return {
|
|
964
1143
|
id,
|
|
965
1144
|
kind: "chat",
|
|
@@ -982,52 +1161,38 @@ function classifyDiscoveryItem(item) {
|
|
|
982
1161
|
}
|
|
983
1162
|
const metadata = metadataFromDiscoveryItem(item);
|
|
984
1163
|
const declaredMode = modelModeFromDiscoveryItem(item);
|
|
985
|
-
if (declaredMode
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
989
|
-
}
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
declaredNonChat: true,
|
|
1000
|
-
supportsImageInput: false,
|
|
1001
|
-
metadata,
|
|
1002
|
-
reason,
|
|
1003
|
-
};
|
|
1004
|
-
}
|
|
1005
|
-
if (role === "embedding") {
|
|
1006
|
-
return { id, kind: "embedding", supportsImageInput: false, metadata };
|
|
1007
|
-
}
|
|
1164
|
+
if (declaredMode === undefined)
|
|
1165
|
+
return classifyUndeclaredDiscoveryItem(item, id, metadata);
|
|
1166
|
+
const voiceRole = voiceRoleForDeclaredMode(declaredMode);
|
|
1167
|
+
if (voiceRole !== undefined) {
|
|
1168
|
+
return { id, kind: "voice", voiceRole, supportsImageInput: false, metadata };
|
|
1169
|
+
}
|
|
1170
|
+
const role = modelKindForDeclaredMode(declaredMode);
|
|
1171
|
+
if (role === "rerank")
|
|
1172
|
+
return rerankDiscoveryModel(id, metadata, true);
|
|
1173
|
+
if (role === "unsupported") {
|
|
1174
|
+
// The reason is drawn from a CLOSED vocabulary. A declared mode is gateway-controlled text of
|
|
1175
|
+
// unbounded shape; echoing it verbatim would put foreign strings into the diagnostic channel
|
|
1176
|
+
// and the setup response, which the redaction rules forbid.
|
|
1177
|
+
const reason = boundedUnsupportedReason(declaredMode);
|
|
1008
1178
|
return {
|
|
1009
1179
|
id,
|
|
1010
|
-
kind: "
|
|
1011
|
-
|
|
1180
|
+
kind: "unsupported",
|
|
1181
|
+
declaredNonChat: true,
|
|
1182
|
+
supportsImageInput: false,
|
|
1012
1183
|
metadata,
|
|
1184
|
+
reason,
|
|
1013
1185
|
};
|
|
1014
1186
|
}
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
// exactly as before — it just cannot fall through to "chat".
|
|
1018
|
-
if (isExplicitlyNonChatModel(item)) {
|
|
1019
|
-
return isLikelyEmbeddingModelId(id)
|
|
1020
|
-
? { id, kind: "embedding", supportsImageInput: false, metadata }
|
|
1021
|
-
: {
|
|
1022
|
-
id,
|
|
1023
|
-
kind: "unsupported",
|
|
1024
|
-
supportsImageInput: false,
|
|
1025
|
-
metadata,
|
|
1026
|
-
reason: "not-chat-capable",
|
|
1027
|
-
declaredNonChat: true,
|
|
1028
|
-
};
|
|
1187
|
+
if (role === "embedding") {
|
|
1188
|
+
return { id, kind: "embedding", declaredRole: true, supportsImageInput: false, metadata };
|
|
1029
1189
|
}
|
|
1030
|
-
return
|
|
1190
|
+
return {
|
|
1191
|
+
id,
|
|
1192
|
+
kind: "chat",
|
|
1193
|
+
supportsImageInput: supportsImageInputFromDiscoveryItem(item, id),
|
|
1194
|
+
metadata,
|
|
1195
|
+
};
|
|
1031
1196
|
}
|
|
1032
1197
|
function voiceRoleForDeclaredMode(mode) {
|
|
1033
1198
|
if (mode === "audio_transcription")
|
|
@@ -1102,38 +1267,55 @@ function mergeDiscoveryDeployment(existing, incoming) {
|
|
|
1102
1267
|
return incoming;
|
|
1103
1268
|
if (existing.deploymentConflict === true)
|
|
1104
1269
|
return existing;
|
|
1105
|
-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
};
|
|
1112
|
-
}
|
|
1270
|
+
// Load-balanced replicas of one declared non-chat role (two `mode: "rerank"` entries of one
|
|
1271
|
+
// alias) are one engine; only an alias that MIXES roles is a conflict.
|
|
1272
|
+
if (isSameRoleUnsupportedReplica(existing, incoming))
|
|
1273
|
+
return mergedReplica(existing, incoming);
|
|
1274
|
+
if (hasDeclaredNonChatDeployment(existing, incoming))
|
|
1275
|
+
return conflictingDeployment(existing);
|
|
1113
1276
|
if (existing.kind === "unsupported")
|
|
1114
1277
|
return incoming;
|
|
1115
1278
|
if (incoming.kind === "unsupported")
|
|
1116
1279
|
return existing;
|
|
1117
1280
|
if (existing.kind !== incoming.kind || existing.voiceRole !== incoming.voiceRole) {
|
|
1118
|
-
return
|
|
1119
|
-
...existing,
|
|
1120
|
-
kind: "unsupported",
|
|
1121
|
-
deploymentConflict: true,
|
|
1122
|
-
reason: "not-chat-capable",
|
|
1123
|
-
};
|
|
1281
|
+
return conflictingDeployment(existing);
|
|
1124
1282
|
}
|
|
1283
|
+
return mergedReplica(existing, incoming);
|
|
1284
|
+
}
|
|
1285
|
+
function isSameRoleUnsupportedReplica(existing, incoming) {
|
|
1286
|
+
return (existing.kind === "unsupported" &&
|
|
1287
|
+
incoming.kind === "unsupported" &&
|
|
1288
|
+
existing.reason === incoming.reason);
|
|
1289
|
+
}
|
|
1290
|
+
function mergedReplica(existing, incoming) {
|
|
1125
1291
|
return {
|
|
1126
1292
|
...existing,
|
|
1293
|
+
...(existing.declaredNonChat === true || incoming.declaredNonChat === true
|
|
1294
|
+
? { declaredNonChat: true }
|
|
1295
|
+
: {}),
|
|
1296
|
+
// One declared replica is a declaration for the alias, whichever the gateway listed first.
|
|
1297
|
+
...(existing.declaredRole === true || incoming.declaredRole === true
|
|
1298
|
+
? { declaredRole: true }
|
|
1299
|
+
: {}),
|
|
1127
1300
|
supportsImageInput: existing.supportsImageInput && incoming.supportsImageInput,
|
|
1128
1301
|
metadata: intersectDeploymentMetadata(existing.metadata, incoming.metadata),
|
|
1129
1302
|
};
|
|
1130
1303
|
}
|
|
1304
|
+
function conflictingDeployment(existing) {
|
|
1305
|
+
return {
|
|
1306
|
+
...existing,
|
|
1307
|
+
kind: "unsupported",
|
|
1308
|
+
deploymentConflict: true,
|
|
1309
|
+
reason: "not-chat-capable",
|
|
1310
|
+
};
|
|
1311
|
+
}
|
|
1131
1312
|
function hasDeclaredNonChatDeployment(left, right) {
|
|
1132
1313
|
return left.declaredNonChat === true || right.declaredNonChat === true;
|
|
1133
1314
|
}
|
|
1134
1315
|
function intersectDeploymentMetadata(left, right) {
|
|
1135
1316
|
return {
|
|
1136
1317
|
...intersectContextWindow(left, right),
|
|
1318
|
+
...intersectInputLimit(left, right),
|
|
1137
1319
|
...commonTokenCounter(left, right),
|
|
1138
1320
|
maxOutputTokens: Math.min(left.maxOutputTokens ?? 0, right.maxOutputTokens ?? 0),
|
|
1139
1321
|
toolCalling: left.toolCalling === true && right.toolCalling === true,
|
|
@@ -1143,6 +1325,10 @@ function intersectDeploymentMetadata(left, right) {
|
|
|
1143
1325
|
: {}),
|
|
1144
1326
|
};
|
|
1145
1327
|
}
|
|
1328
|
+
function intersectInputLimit(left, right) {
|
|
1329
|
+
const limits = [left.maxInputTokens, right.maxInputTokens].filter((limit) => limit !== undefined);
|
|
1330
|
+
return limits.length === 0 ? {} : { maxInputTokens: Math.min(...limits) };
|
|
1331
|
+
}
|
|
1146
1332
|
function intersectContextWindow(left, right) {
|
|
1147
1333
|
if (left.contextWindow === undefined && right.contextWindow === undefined)
|
|
1148
1334
|
return {};
|
|
@@ -1161,9 +1347,7 @@ function discoveredModelLists(usable, boundedVoice, unsupported, wasTruncated) {
|
|
|
1161
1347
|
return {
|
|
1162
1348
|
modelIds: usable.map((entry) => entry.id),
|
|
1163
1349
|
chatModelIds: usable.filter((entry) => entry.kind === "chat").map((entry) => entry.id),
|
|
1164
|
-
embeddingModelIds: usable
|
|
1165
|
-
.filter((entry) => entry.kind === "embedding")
|
|
1166
|
-
.map((entry) => entry.id),
|
|
1350
|
+
embeddingModelIds: declaredThenIdOrder(usable.filter((entry) => entry.kind === "embedding")),
|
|
1167
1351
|
voiceSpeechInputModelIds: boundedVoice
|
|
1168
1352
|
.filter((entry) => entry.voiceRole === "speech-input")
|
|
1169
1353
|
.map((entry) => entry.id),
|
|
@@ -1176,7 +1360,7 @@ function discoveredModelLists(usable, boundedVoice, unsupported, wasTruncated) {
|
|
|
1176
1360
|
imageInputModelIds: usable
|
|
1177
1361
|
.filter((entry) => entry.kind === "chat" && entry.supportsImageInput)
|
|
1178
1362
|
.map((entry) => entry.id),
|
|
1179
|
-
modelMetadata: Object.fromEntries(usable.map((entry) => [entry.id, entry
|
|
1363
|
+
modelMetadata: Object.fromEntries(usable.map((entry) => [entry.id, discoveredMetadata(entry)])),
|
|
1180
1364
|
...(unsupported.length > 0
|
|
1181
1365
|
? {
|
|
1182
1366
|
unsupportedModels: unsupported.map((entry) => ({
|
|
@@ -1185,9 +1369,35 @@ function discoveredModelLists(usable, boundedVoice, unsupported, wasTruncated) {
|
|
|
1185
1369
|
})),
|
|
1186
1370
|
}
|
|
1187
1371
|
: {}),
|
|
1372
|
+
...rerankCandidateList(unsupported),
|
|
1188
1373
|
...(wasTruncated ? { truncated: true } : {}),
|
|
1189
1374
|
};
|
|
1190
1375
|
}
|
|
1376
|
+
// A replica set in which one deployment declared no window merges to the conservative fallback;
|
|
1377
|
+
// the metadata says so, so setup keeps that window assumed instead of treating 4,096 as declared.
|
|
1378
|
+
function discoveredMetadata(entry) {
|
|
1379
|
+
return entry.undeclaredContext === true && entry.metadata.contextWindow !== undefined
|
|
1380
|
+
? { ...entry.metadata, contextWindowUndeclared: true }
|
|
1381
|
+
: entry.metadata;
|
|
1382
|
+
}
|
|
1383
|
+
// Declared before name-inferred, then by id. Two lanes are ORDERED, not merely listed — the rerank
|
|
1384
|
+
// candidates (setup probes only the first few) and the embedding candidates (the first one becomes
|
|
1385
|
+
// the default new Knowledge Pods bind) — and neither may depend on how the gateway happens to list
|
|
1386
|
+
// its models: a restart that lists them in another order must not change what is probed or bound.
|
|
1387
|
+
// A role the gateway stated in a `mode` outranks one Keiko only inferred from the id.
|
|
1388
|
+
function declaredThenIdOrder(entries) {
|
|
1389
|
+
const declared = (entry) => Number(entry.declaredNonChat === true || entry.declaredRole === true);
|
|
1390
|
+
return [...entries]
|
|
1391
|
+
.sort((left, right) => declared(right) - declared(left) || left.id.localeCompare(right.id, "en"))
|
|
1392
|
+
.map((entry) => entry.id);
|
|
1393
|
+
}
|
|
1394
|
+
// The rerank engines among the recognised-but-unconfigured models. They are partitioned out of the
|
|
1395
|
+
// same pre-cap entry list as every other role, so a gateway listing dozens of chat aliases ahead of
|
|
1396
|
+
// its reranker cannot push the reranker out of reach.
|
|
1397
|
+
function rerankCandidateList(unsupported) {
|
|
1398
|
+
const rerankModelIds = declaredThenIdOrder(unsupported.filter((entry) => entry.reason === "rerank"));
|
|
1399
|
+
return rerankModelIds.length === 0 ? {} : { rerankModelIds };
|
|
1400
|
+
}
|
|
1191
1401
|
function assertDiscoveryYieldedUsableModels(usable, unsupported) {
|
|
1192
1402
|
if (usable.length > 0)
|
|
1193
1403
|
return;
|
|
@@ -1216,18 +1426,11 @@ export function normalizeDiscoveryPayload(payload) {
|
|
|
1216
1426
|
export function normalizeDiscoveryPayloadForSetup(payload) {
|
|
1217
1427
|
return parseModelDiscovery(payload);
|
|
1218
1428
|
}
|
|
1219
|
-
async function fetchDiscoveryJson(url, apiKey, apiKeyHeaderName, egress) {
|
|
1220
|
-
|
|
1221
|
-
|
|
1222
|
-
headers: apiKeyHeaders(apiKey, apiKeyHeaderName),
|
|
1223
|
-
signal: AbortSignal.timeout(30_000),
|
|
1224
|
-
...(egress !== undefined ? { egress } : {}),
|
|
1225
|
-
});
|
|
1429
|
+
async function fetchDiscoveryJson(url, apiKey, apiKeyHeaderName, egress, signal = AbortSignal.timeout(DISCOVERY_TIMEOUT_MS)) {
|
|
1430
|
+
signal.throwIfAborted();
|
|
1431
|
+
const response = await fetchDiscoveryResponse(url, apiKey, apiKeyHeaderName, egress, signal);
|
|
1226
1432
|
if (!response.ok) {
|
|
1227
|
-
|
|
1228
|
-
// property; carrying it only inside the message left a 401/403 discovery — a wrong or
|
|
1229
|
-
// model-restricted proxy key — as the generic body-free 502 (LiteLLM production audit).
|
|
1230
|
-
throw Object.assign(new Error(`model discovery returned HTTP ${String(response.status)}`), {
|
|
1433
|
+
throw Object.assign(new Error("model discovery returned an error status"), {
|
|
1231
1434
|
httpStatus: response.status,
|
|
1232
1435
|
});
|
|
1233
1436
|
}
|
|
@@ -1235,7 +1438,24 @@ async function fetchDiscoveryJson(url, apiKey, apiKeyHeaderName, egress) {
|
|
|
1235
1438
|
return await readJsonCapped(response);
|
|
1236
1439
|
}
|
|
1237
1440
|
catch {
|
|
1238
|
-
|
|
1441
|
+
signal.throwIfAborted();
|
|
1442
|
+
throw discoveryTerminal("model discovery response was not readable JSON", "DISCOVERY_INVALID_RESPONSE");
|
|
1443
|
+
}
|
|
1444
|
+
}
|
|
1445
|
+
async function fetchDiscoveryResponse(url, apiKey, apiKeyHeaderName, egress, signal) {
|
|
1446
|
+
try {
|
|
1447
|
+
return await gatewayFetch(url, {
|
|
1448
|
+
method: "GET",
|
|
1449
|
+
headers: apiKeyHeaders(apiKey, apiKeyHeaderName),
|
|
1450
|
+
signal,
|
|
1451
|
+
...(egress !== undefined ? { egress } : {}),
|
|
1452
|
+
});
|
|
1453
|
+
}
|
|
1454
|
+
catch (cause) {
|
|
1455
|
+
signal.throwIfAborted();
|
|
1456
|
+
if (cause instanceof TypeError)
|
|
1457
|
+
throw new Error("Model metadata transport was unavailable.", { cause });
|
|
1458
|
+
throw cause;
|
|
1239
1459
|
}
|
|
1240
1460
|
}
|
|
1241
1461
|
// `/model/info` is a LiteLLM management route. Plenty of healthy deployments refuse it — an
|
|
@@ -1252,10 +1472,14 @@ function modelInfoAnswerIsUnusable(cause) {
|
|
|
1252
1472
|
return (cause?.discoveryCode ===
|
|
1253
1473
|
"DISCOVERY_ALL_ENTRIES_UNSUPPORTED");
|
|
1254
1474
|
}
|
|
1255
|
-
async function discoverLiteLlmModelInfo(baseUrl, apiKey, apiKeyHeaderName, egress, correlationId) {
|
|
1256
|
-
|
|
1475
|
+
async function discoverLiteLlmModelInfo(baseUrl, apiKey, apiKeyHeaderName, egress, correlationId, { signal, deadlineAt, trace, }) {
|
|
1476
|
+
const endpoints = modelInfoEndpointCandidates(baseUrl);
|
|
1477
|
+
for (const [index, endpoint] of endpoints.entries()) {
|
|
1478
|
+
trace.discoverySource = index === 0 ? "model-info" : "model-group-info";
|
|
1479
|
+
const outcomeKey = index === 0 ? "modelInfoOutcome" : "modelGroupInfoOutcome";
|
|
1257
1480
|
try {
|
|
1258
|
-
const discovered = parseModelDiscovery(await fetchDiscoveryJson(endpoint, apiKey, apiKeyHeaderName, egress), correlationId);
|
|
1481
|
+
const discovered = parseModelDiscovery(await fetchDiscoveryJson(endpoint, apiKey, apiKeyHeaderName, egress, discoveryManagementSignal(signal, deadlineAt, endpoints.length - index)), correlationId);
|
|
1482
|
+
trace[outcomeKey] = "available";
|
|
1259
1483
|
return {
|
|
1260
1484
|
...discovered,
|
|
1261
1485
|
modelMetadata: Object.fromEntries(discovered.modelIds.map((id) => [
|
|
@@ -1265,18 +1489,47 @@ async function discoverLiteLlmModelInfo(baseUrl, apiKey, apiKeyHeaderName, egres
|
|
|
1265
1489
|
};
|
|
1266
1490
|
}
|
|
1267
1491
|
catch (cause) {
|
|
1492
|
+
trace[outcomeKey] = discoveryRouteOutcome(cause, signal);
|
|
1493
|
+
signal.throwIfAborted();
|
|
1494
|
+
if (discoveryProgrammingFailure(cause))
|
|
1495
|
+
throw cause;
|
|
1268
1496
|
if (modelInfoAnswerIsUnusable(cause) && cause instanceof Error)
|
|
1269
1497
|
throw cause;
|
|
1270
1498
|
}
|
|
1271
1499
|
}
|
|
1272
1500
|
return undefined;
|
|
1273
1501
|
}
|
|
1274
|
-
|
|
1275
|
-
|
|
1502
|
+
// Let the primary management route use the shared budget while retaining a short fallback window.
|
|
1503
|
+
function discoveryManagementSignal(signal, deadlineAt, routesLeft) {
|
|
1504
|
+
signal.throwIfAborted();
|
|
1505
|
+
const remaining = Math.max(1, deadlineAt - Date.now());
|
|
1506
|
+
return AbortSignal.any([
|
|
1507
|
+
signal,
|
|
1508
|
+
AbortSignal.timeout(Math.max(1, remaining - routesLeft * DISCOVERY_FALLBACK_RESERVE_MS)),
|
|
1509
|
+
]);
|
|
1510
|
+
}
|
|
1511
|
+
async function defaultGatewayModelDiscovery(baseUrl, apiKey, requestedApiKeyHeaderName, egress, correlationId, trace, callerSignal) {
|
|
1512
|
+
const apiKeyHeaderName = requestedApiKeyHeaderName ?? DEFAULT_API_KEY_HEADER_NAME;
|
|
1513
|
+
// One existing discovery budget covers the management fallbacks and model list together.
|
|
1514
|
+
const deadlineAt = Date.now() + DISCOVERY_TIMEOUT_MS;
|
|
1515
|
+
const signal = AbortSignal.any([
|
|
1516
|
+
AbortSignal.timeout(DISCOVERY_TIMEOUT_MS),
|
|
1517
|
+
...(callerSignal === undefined ? [] : [callerSignal]),
|
|
1518
|
+
]);
|
|
1519
|
+
const litellmModels = await discoverLiteLlmModelInfo(baseUrl, apiKey, apiKeyHeaderName, egress, correlationId, { signal, deadlineAt, trace });
|
|
1276
1520
|
if (litellmModels !== undefined) {
|
|
1277
1521
|
return litellmModels;
|
|
1278
1522
|
}
|
|
1279
|
-
|
|
1523
|
+
trace.discoverySource = "model-list";
|
|
1524
|
+
try {
|
|
1525
|
+
const discovered = parseModelDiscovery(await fetchDiscoveryJson(modelsEndpoint(baseUrl), apiKey, apiKeyHeaderName, egress, signal), correlationId);
|
|
1526
|
+
trace.modelListOutcome = "available";
|
|
1527
|
+
return discovered;
|
|
1528
|
+
}
|
|
1529
|
+
catch (cause) {
|
|
1530
|
+
trace.modelListOutcome = discoveryRouteOutcome(cause, signal);
|
|
1531
|
+
throw cause;
|
|
1532
|
+
}
|
|
1280
1533
|
}
|
|
1281
1534
|
function deploymentNameValues(value) {
|
|
1282
1535
|
if (typeof value === "string") {
|
|
@@ -1470,9 +1723,10 @@ function mostSevereProbeFailure(failures) {
|
|
|
1470
1723
|
}
|
|
1471
1724
|
return worst;
|
|
1472
1725
|
}
|
|
1473
|
-
async function runBoundedWorkers(items, concurrency, process) {
|
|
1726
|
+
async function runBoundedWorkers(items, concurrency, process, signal) {
|
|
1474
1727
|
let next = 0;
|
|
1475
1728
|
async function worker() {
|
|
1729
|
+
signal?.throwIfAborted();
|
|
1476
1730
|
const index = next;
|
|
1477
1731
|
next += 1;
|
|
1478
1732
|
if (index >= items.length)
|
|
@@ -1487,21 +1741,23 @@ async function runBoundedWorkers(items, concurrency, process) {
|
|
|
1487
1741
|
const workerCount = Math.max(1, Math.min(concurrency, items.length));
|
|
1488
1742
|
await Promise.all(Array.from({ length: workerCount }, () => worker()));
|
|
1489
1743
|
}
|
|
1490
|
-
async function passingCandidates(candidates, probe, concurrency, failures) {
|
|
1744
|
+
async function passingCandidates(candidates, probe, concurrency, failures, signal) {
|
|
1491
1745
|
const tested = new Array(candidates.length).fill(undefined);
|
|
1492
1746
|
async function worker(modelId, index) {
|
|
1493
1747
|
try {
|
|
1494
1748
|
await probe(modelId);
|
|
1749
|
+
signal?.throwIfAborted();
|
|
1495
1750
|
tested[index] = modelId;
|
|
1496
1751
|
}
|
|
1497
1752
|
catch (error) {
|
|
1753
|
+
signal?.throwIfAborted();
|
|
1498
1754
|
// Probe rejection is the documented signal that this candidate is not
|
|
1499
1755
|
// chat-callable. We drop it silently so healthy peers still surface — capturing only
|
|
1500
1756
|
// the classification code/status as evidence for the all-rejected aggregate.
|
|
1501
1757
|
failures?.push({ code: setupErrorCode(error), httpStatus: setupHttpStatus(error) });
|
|
1502
1758
|
}
|
|
1503
1759
|
}
|
|
1504
|
-
await runBoundedWorkers(candidates, concurrency, worker);
|
|
1760
|
+
await runBoundedWorkers(candidates, concurrency, worker, signal);
|
|
1505
1761
|
return tested.filter((modelId) => modelId !== undefined);
|
|
1506
1762
|
}
|
|
1507
1763
|
// The aggregate keeps the exact historic message; additionally it carries the most severe
|
|
@@ -1592,7 +1848,7 @@ function recordChatSmokeFailure(modelId, error, deps, correlationId, accumulator
|
|
|
1592
1848
|
// rules over an injected `probe`/`now`, and exercising them through the full HTTP-mocked
|
|
1593
1849
|
// `handleGatewaySetup` route would need either a real multi-minute wait or an intrusive global
|
|
1594
1850
|
// `AbortSignal.timeout`/clock stub for every scenario (PR #3602 review).
|
|
1595
|
-
export async function admitChatSmokeCandidates(candidates, probe, concurrency, deps, correlationId, now = Date.now) {
|
|
1851
|
+
export async function admitChatSmokeCandidates(candidates, probe, concurrency, deps, correlationId, now = Date.now, signal) {
|
|
1596
1852
|
const tested = new Array(candidates.length).fill(undefined);
|
|
1597
1853
|
const accumulators = {
|
|
1598
1854
|
unverifiedKept: [],
|
|
@@ -1609,12 +1865,14 @@ export async function admitChatSmokeCandidates(candidates, probe, concurrency, d
|
|
|
1609
1865
|
}
|
|
1610
1866
|
try {
|
|
1611
1867
|
await probe(modelId);
|
|
1868
|
+
signal?.throwIfAborted();
|
|
1612
1869
|
tested[index] = modelId;
|
|
1613
1870
|
}
|
|
1614
1871
|
catch (error) {
|
|
1872
|
+
signal?.throwIfAborted();
|
|
1615
1873
|
recordChatSmokeFailure(modelId, error, deps, correlationId, accumulators);
|
|
1616
1874
|
}
|
|
1617
|
-
});
|
|
1875
|
+
}, signal);
|
|
1618
1876
|
return {
|
|
1619
1877
|
tested: tested.filter((modelId) => modelId !== undefined),
|
|
1620
1878
|
...accumulators,
|
|
@@ -1623,19 +1881,20 @@ export async function admitChatSmokeCandidates(candidates, probe, concurrency, d
|
|
|
1623
1881
|
// The response-format and tool-calling verification rounds, run only over VERIFIED candidates
|
|
1624
1882
|
// (`chatSmoke.tested`) — extracted so `defaultGatewaySetupTester` stays under the repository's
|
|
1625
1883
|
// per-function line ceiling (AGENTS.md §6).
|
|
1626
|
-
async function verifyTestedChatCandidates(gateway, config, testedModelIds, correlationId, deps) {
|
|
1884
|
+
async function verifyTestedChatCandidates(gateway, config, testedModelIds, correlationId, deps, signal) {
|
|
1627
1885
|
const responseFormatModelIds = await passingCandidates(testedModelIds, async (modelId) => {
|
|
1628
1886
|
const response = await gateway.chat({
|
|
1629
1887
|
...buildQiJudgePreflightRequest(modelId),
|
|
1630
1888
|
logContext: { correlationId },
|
|
1889
|
+
cancellationSignal: candidateSmokeCancellationSignal(config, modelId, signal),
|
|
1631
1890
|
});
|
|
1632
1891
|
if (tryParseJudgeVerdict(response.content) === null) {
|
|
1633
1892
|
throw new Error("response format unsupported");
|
|
1634
1893
|
}
|
|
1635
|
-
}, SETUP_SMOKE_CONCURRENCY);
|
|
1894
|
+
}, SETUP_SMOKE_CONCURRENCY, undefined, signal);
|
|
1636
1895
|
// Both probe rounds independently use the endpoint-wide concurrency budget. Keep them
|
|
1637
1896
|
// sequential so setup never doubles the operator-approved in-flight request ceiling.
|
|
1638
|
-
const toolCallingObservations = await setupToolCallingObservations(config, testedModelIds, correlationId, deps);
|
|
1897
|
+
const toolCallingObservations = await setupToolCallingObservations(config, testedModelIds, correlationId, deps, signal);
|
|
1639
1898
|
return { responseFormatModelIds, toolCallingObservations };
|
|
1640
1899
|
}
|
|
1641
1900
|
// The deadline that actually bounds ONE candidate's smoke call (PR #3602 review): `Gateway.chat()`
|
|
@@ -1646,8 +1905,9 @@ async function verifyTestedChatCandidates(gateway, config, testedModelIds, corre
|
|
|
1646
1905
|
// `DEPLOYMENT_SMOKE_TIMEOUT_MS` for a manually entered deployment) rather than a hardcoded literal,
|
|
1647
1906
|
// so both smoke paths stay bounded at the timeout each already advertises; the discovery constant
|
|
1648
1907
|
// is only the defensive fallback for a candidate somehow missing its own provider entry.
|
|
1649
|
-
function candidateSmokeCancellationSignal(config, modelId) {
|
|
1650
|
-
|
|
1908
|
+
function candidateSmokeCancellationSignal(config, modelId, signal) {
|
|
1909
|
+
const deadline = AbortSignal.timeout(candidateSmokeDeadlineMs(config, modelId));
|
|
1910
|
+
return signal === undefined ? deadline : AbortSignal.any([deadline, signal]);
|
|
1651
1911
|
}
|
|
1652
1912
|
// Never below the discovery smoke floor: a manually entered deployment keeps its shorter configured
|
|
1653
1913
|
// timeout for later calls, but a setup probe that gave up at 30 s on a gateway that answers in 45 s
|
|
@@ -1659,7 +1919,7 @@ export function candidateSmokeDeadlineMs(config, modelId) {
|
|
|
1659
1919
|
// Extracted so `defaultGatewaySetupTester` stays under the repository's per-function line ceiling
|
|
1660
1920
|
// (AGENTS.md §6) — the probe itself is the one line that matters: a fixed "reply OK" chat call,
|
|
1661
1921
|
// bounded by this candidate's own smoke deadline.
|
|
1662
|
-
function chatSmokeProbe(gateway, config, correlationId) {
|
|
1922
|
+
function chatSmokeProbe(gateway, config, correlationId, signal) {
|
|
1663
1923
|
return async (modelId) => {
|
|
1664
1924
|
await gateway.chat({
|
|
1665
1925
|
modelId,
|
|
@@ -1668,11 +1928,11 @@ function chatSmokeProbe(gateway, config, correlationId) {
|
|
|
1668
1928
|
{ role: "user", content: "Reply with exactly: OK" },
|
|
1669
1929
|
],
|
|
1670
1930
|
logContext: { correlationId },
|
|
1671
|
-
cancellationSignal: candidateSmokeCancellationSignal(config, modelId),
|
|
1931
|
+
cancellationSignal: candidateSmokeCancellationSignal(config, modelId, signal),
|
|
1672
1932
|
});
|
|
1673
1933
|
};
|
|
1674
1934
|
}
|
|
1675
|
-
async function defaultGatewaySetupTester(config, candidateModelIds, correlationId, deps) {
|
|
1935
|
+
async function defaultGatewaySetupTester(config, candidateModelIds, correlationId, deps, signal) {
|
|
1676
1936
|
// Wired to the process activity log: first-run setup is where an operator's endpoint is wrong
|
|
1677
1937
|
// in a way no UI message can name (a proxy that blocks CONNECT, a provider that answers 404 for
|
|
1678
1938
|
// every model). Without the sink the smoke loop's retries and rejections are invisible.
|
|
@@ -1680,7 +1940,7 @@ async function defaultGatewaySetupTester(config, candidateModelIds, correlationI
|
|
|
1680
1940
|
log: processServerLogSink(),
|
|
1681
1941
|
spendBudget: gatewaySpendBudgetForEnv(deps.env),
|
|
1682
1942
|
});
|
|
1683
|
-
const chatSmoke = await admitChatSmokeCandidates(candidateModelIds, chatSmokeProbe(gateway, config, correlationId), SETUP_SMOKE_CONCURRENCY, deps, correlationId);
|
|
1943
|
+
const chatSmoke = await admitChatSmokeCandidates(candidateModelIds, chatSmokeProbe(gateway, config, correlationId, signal), SETUP_SMOKE_CONCURRENCY, deps, correlationId, Date.now, signal);
|
|
1684
1944
|
// Nothing was verified: the historic "no discovered model accepted the chat-completions smoke
|
|
1685
1945
|
// test" case, thrown exactly as `smokeTestCandidates` always did — even when some candidates were
|
|
1686
1946
|
// merely kept unverified rather than dropped, because `verifyAndSaveGatewaySetup`'s multi-base-URL
|
|
@@ -1692,7 +1952,7 @@ async function defaultGatewaySetupTester(config, candidateModelIds, correlationI
|
|
|
1692
1952
|
throw allProbesFailedError(chatSmoke.allFailures);
|
|
1693
1953
|
}
|
|
1694
1954
|
const testedModelIds = chatSmoke.tested;
|
|
1695
|
-
const { responseFormatModelIds, toolCallingObservations } = await verifyTestedChatCandidates(gateway, config, testedModelIds, correlationId, deps);
|
|
1955
|
+
const { responseFormatModelIds, toolCallingObservations } = await verifyTestedChatCandidates(gateway, config, testedModelIds, correlationId, deps, signal);
|
|
1696
1956
|
return {
|
|
1697
1957
|
testedModelIds,
|
|
1698
1958
|
responseFormatModelIds,
|
|
@@ -1720,7 +1980,7 @@ function unverifiedKeptToolCallingObservations(config, unverifiedKept, correlati
|
|
|
1720
1980
|
return { modelId, status: "unverified", checkedAt };
|
|
1721
1981
|
});
|
|
1722
1982
|
}
|
|
1723
|
-
async function setupToolCallingObservations(config, testedModelIds, correlationId, deps) {
|
|
1983
|
+
async function setupToolCallingObservations(config, testedModelIds, correlationId, deps, signal) {
|
|
1724
1984
|
const checkedAt = new Date().toISOString();
|
|
1725
1985
|
const observations = new Array(testedModelIds.length);
|
|
1726
1986
|
await runBoundedWorkers(testedModelIds, SETUP_SMOKE_CONCURRENCY, async (modelId, index) => {
|
|
@@ -1730,20 +1990,22 @@ async function setupToolCallingObservations(config, testedModelIds, correlationI
|
|
|
1730
1990
|
const probeStatus = provider === undefined
|
|
1731
1991
|
? "unverified"
|
|
1732
1992
|
: await probeGatewayToolCalling(config, provider, undefined, (error) => {
|
|
1993
|
+
signal?.throwIfAborted();
|
|
1733
1994
|
reportSetupVerificationFailure(deps, error, correlationId, "gateway.setup.tool-calling-probe");
|
|
1734
1995
|
}, {
|
|
1735
1996
|
env: deps.env,
|
|
1736
1997
|
capability: findConfiguredCapability(config, modelId),
|
|
1737
1998
|
correlationId: correlationId ?? UNKNOWN_CORRELATION_ID,
|
|
1738
|
-
});
|
|
1999
|
+
}, signal);
|
|
1739
2000
|
// A `transient` probe answer (408/429/5xx-except-501, `transientGatewayStatus`) proves
|
|
1740
2001
|
// nothing about the model either way and must never be stored or logged as a verdict: the
|
|
1741
2002
|
// closed status vocabulary here and on the `gateway.tool-calling.verification` activity-log
|
|
1742
2003
|
// line stays exactly "verified" | "unsupported" | "unverified" (PR #3602 review).
|
|
2004
|
+
signal?.throwIfAborted();
|
|
1743
2005
|
const status = probeStatus === "transient" ? "unverified" : probeStatus;
|
|
1744
2006
|
observations[index] = { modelId, status, checkedAt };
|
|
1745
2007
|
logToolCallingVerification(config, modelId, status, correlationId ?? UNKNOWN_CORRELATION_ID);
|
|
1746
|
-
});
|
|
2008
|
+
}, signal);
|
|
1747
2009
|
return observations;
|
|
1748
2010
|
}
|
|
1749
2011
|
// Field incident (LiteLLM customer, 2026-08): chat models were smoke-tested, embedding models were
|
|
@@ -1756,7 +2018,8 @@ const EMBEDDING_PROBE_INPUT = "Keiko embedding setup probe";
|
|
|
1756
2018
|
// One embedding request against the model, using the SAME endpoint protocol the provider will
|
|
1757
2019
|
// persist with — an Azure deployment path must not be probed at the OpenAI-compatible URL, or the
|
|
1758
2020
|
// probe measures a 404 that production would never see.
|
|
1759
|
-
async function embedOnceForProbe(config, provider, modelId, env, correlationId) {
|
|
2021
|
+
async function embedOnceForProbe(config, provider, modelId, env, correlationId, signal) {
|
|
2022
|
+
signal?.throwIfAborted();
|
|
1760
2023
|
const reservation = reserveGatewaySpendForAttempt(env, findConfiguredCapability(config, modelId), {
|
|
1761
2024
|
modelId,
|
|
1762
2025
|
messages: [{ role: "user", content: "Gateway embedding setup probe." }],
|
|
@@ -1775,6 +2038,7 @@ async function embedOnceForProbe(config, provider, modelId, env, correlationId)
|
|
|
1775
2038
|
modelId,
|
|
1776
2039
|
input: EMBEDDING_PROBE_INPUT,
|
|
1777
2040
|
timeoutMs: provider.timeoutMs,
|
|
2041
|
+
...(signal === undefined ? {} : { signal }),
|
|
1778
2042
|
// The probe exists because an embedding model used to be persisted on a classification alone.
|
|
1779
2043
|
// The sink is what turns a rejected probe into a line naming the status and the error kind,
|
|
1780
2044
|
// rather than a model that silently fails to make the candidate list.
|
|
@@ -1796,15 +2060,16 @@ const RETRYABLE_PROBE_KINDS = new Set([
|
|
|
1796
2060
|
// An immediate retry against a gateway that just answered 429 answers 429 again, so it would burn a
|
|
1797
2061
|
// request and change nothing. One short pause, matching the chat lane's backoff base.
|
|
1798
2062
|
const EMBEDDING_PROBE_RETRY_DELAY_MS = 500;
|
|
1799
|
-
export async function defaultGatewayEmbeddingProbe(config, candidateModelIds, env, correlationId) {
|
|
2063
|
+
export async function defaultGatewayEmbeddingProbe(config, candidateModelIds, env, correlationId, signal) {
|
|
1800
2064
|
return passingCandidates(candidateModelIds, async (modelId) => {
|
|
1801
2065
|
const provider = config.providers.find((entry) => entry.modelId === modelId);
|
|
1802
2066
|
if (provider === undefined)
|
|
1803
2067
|
throw new Error("embedding candidate has no provider entry");
|
|
1804
|
-
let outcome = await embedOnceForProbe(config, provider, modelId, env, correlationId);
|
|
2068
|
+
let outcome = await embedOnceForProbe(config, provider, modelId, env, correlationId, signal);
|
|
2069
|
+
signal?.throwIfAborted();
|
|
1805
2070
|
if (!outcome.ok && RETRYABLE_PROBE_KINDS.has(outcome.kind)) {
|
|
1806
|
-
await new Promise((resolve) => setTimeout(resolve, EMBEDDING_PROBE_RETRY_DELAY_MS));
|
|
1807
|
-
outcome = await embedOnceForProbe(config, provider, modelId, env, correlationId);
|
|
2071
|
+
await awaitSetupOperation(new Promise((resolve) => setTimeout(resolve, EMBEDDING_PROBE_RETRY_DELAY_MS)), signal);
|
|
2072
|
+
outcome = await embedOnceForProbe(config, provider, modelId, env, correlationId, signal);
|
|
1808
2073
|
}
|
|
1809
2074
|
// The per-model verdict is what the operator acts on, and it travels in
|
|
1810
2075
|
// droppedEmbeddingModelIds / unverifiedEmbeddingModelIds. passingCandidates drops the
|
|
@@ -1812,23 +2077,66 @@ export async function defaultGatewayEmbeddingProbe(config, candidateModelIds, en
|
|
|
1812
2077
|
if (!outcome.ok || outcome.value.vector.length === 0) {
|
|
1813
2078
|
throw new Error("embedding probe returned no usable vector");
|
|
1814
2079
|
}
|
|
1815
|
-
}, SETUP_SMOKE_CONCURRENCY);
|
|
2080
|
+
}, SETUP_SMOKE_CONCURRENCY, undefined, signal);
|
|
1816
2081
|
}
|
|
1817
|
-
function gatewayEmbeddingProbe(deps, correlationId) {
|
|
2082
|
+
function gatewayEmbeddingProbe(deps, correlationId, signal) {
|
|
1818
2083
|
const override = deps.gatewayEmbeddingProbe;
|
|
1819
2084
|
if (override !== undefined)
|
|
1820
2085
|
return override;
|
|
1821
|
-
return (config, candidateModelIds) => defaultGatewayEmbeddingProbe(config, candidateModelIds, deps.env, correlationId ?? UNKNOWN_CORRELATION_ID);
|
|
2086
|
+
return (config, candidateModelIds) => defaultGatewayEmbeddingProbe(config, candidateModelIds, deps.env, correlationId ?? UNKNOWN_CORRELATION_ID, signal);
|
|
2087
|
+
}
|
|
2088
|
+
// A rerank probe answers two short documents; a healthy engine takes a moment, an unreachable one
|
|
2089
|
+
// must not hold the setup response for the adapter's multi-minute retrieval floor. The caller
|
|
2090
|
+
// signal is what bounds it (the adapter takes the SHORTER of its own deadline and the signal).
|
|
2091
|
+
const RERANKER_SETUP_PROBE_DEADLINE_MS = 30_000;
|
|
2092
|
+
// ...and one setup request has ONE budget for all of them. Per-probe deadlines alone stack: a
|
|
2093
|
+
// gateway listing several rerank aliases behind an unreachable route held the response for
|
|
2094
|
+
// 3 x 30 s per candidate URL, and the candidate-URL loop repeats the whole sequence. The budget
|
|
2095
|
+
// starts at the first probe of the request and is shared by every engine and every candidate URL.
|
|
2096
|
+
const RERANKER_SETUP_TOTAL_BUDGET_MS = 45_000;
|
|
2097
|
+
// The reranker block's own default when the request states no provider timeout (the config parser
|
|
2098
|
+
// applies the same value to a stored block that omits it).
|
|
2099
|
+
const DEFAULT_RERANKER_TIMEOUT_MS = 120_000;
|
|
2100
|
+
// The same two-document probe gateway readiness runs, over the request's own dependencies: the
|
|
2101
|
+
// egress policy, spend guard and activity-log line all apply to a discovered engine exactly as
|
|
2102
|
+
// they do to a configured one. Any failure — a refused request, a wrong ranking, a thrown
|
|
2103
|
+
// transport error, an exhausted request budget — is "not admitted", never a failed setup.
|
|
2104
|
+
function gatewayRerankerProbe(deps, correlationId, signal) {
|
|
2105
|
+
let budgetEndsAt;
|
|
2106
|
+
return async (config) => {
|
|
2107
|
+
signal?.throwIfAborted();
|
|
2108
|
+
budgetEndsAt ??= Date.now() + RERANKER_SETUP_TOTAL_BUDGET_MS;
|
|
2109
|
+
const remainingMs = budgetEndsAt - Date.now();
|
|
2110
|
+
if (remainingMs <= 0)
|
|
2111
|
+
return false;
|
|
2112
|
+
try {
|
|
2113
|
+
const selection = await requestRerankerProbe({
|
|
2114
|
+
deps,
|
|
2115
|
+
config,
|
|
2116
|
+
correlationId: correlationId ?? UNKNOWN_CORRELATION_ID,
|
|
2117
|
+
signal: AbortSignal.any([
|
|
2118
|
+
AbortSignal.timeout(Math.min(RERANKER_SETUP_PROBE_DEADLINE_MS, remainingMs)),
|
|
2119
|
+
...(signal === undefined ? [] : [signal]),
|
|
2120
|
+
]),
|
|
2121
|
+
});
|
|
2122
|
+
return rerankerProbePassed(selection);
|
|
2123
|
+
}
|
|
2124
|
+
catch (error) {
|
|
2125
|
+
signal?.throwIfAborted();
|
|
2126
|
+
reportSetupVerificationFailure(deps, error, correlationId, "gateway.setup.reranker-probe");
|
|
2127
|
+
return false;
|
|
2128
|
+
}
|
|
2129
|
+
};
|
|
1822
2130
|
}
|
|
1823
2131
|
// The seam type (UiHandlerDeps["gatewaySetupTester"]) is a fixed 2-arg shape shared by every
|
|
1824
2132
|
// test override, so the request-scoped correlation id is closed over here rather than added as a
|
|
1825
2133
|
// 3rd seam parameter — the override contract stays untouched while the real tester still stamps
|
|
1826
2134
|
// GatewayCallRequest.logContext (ADR-0173 D5).
|
|
1827
|
-
function gatewaySetupTester(deps, correlationId) {
|
|
2135
|
+
function gatewaySetupTester(deps, correlationId, signal) {
|
|
1828
2136
|
const override = deps.gatewaySetupTester;
|
|
1829
2137
|
if (override !== undefined)
|
|
1830
2138
|
return override;
|
|
1831
|
-
return (config, candidateModelIds) => defaultGatewaySetupTester(config, candidateModelIds, correlationId, deps);
|
|
2139
|
+
return (config, candidateModelIds) => defaultGatewaySetupTester(config, candidateModelIds, correlationId, deps, signal);
|
|
1832
2140
|
}
|
|
1833
2141
|
const FIGMA_ME_ENDPOINT = "https://api.figma.com/v1/me";
|
|
1834
2142
|
function figmaReason(body) {
|
|
@@ -3322,41 +3630,249 @@ function normalizeDiscoveryResult(result) {
|
|
|
3322
3630
|
...(result.unsupportedModels !== undefined
|
|
3323
3631
|
? { unsupportedModels: result.unsupportedModels }
|
|
3324
3632
|
: {}),
|
|
3633
|
+
...(result.rerankModelIds !== undefined ? { rerankModelIds: result.rerankModelIds } : {}),
|
|
3325
3634
|
};
|
|
3326
3635
|
}
|
|
3327
3636
|
return normalizeLegacyDiscoveryResult(result);
|
|
3328
3637
|
}
|
|
3329
|
-
function candidateModelsFromDeploymentNames(deploymentNames,
|
|
3638
|
+
function candidateModelsFromDeploymentNames(deploymentNames, roles) {
|
|
3330
3639
|
// Stored kinds win over the name heuristic: a preserve-mode rebuild must not chat-probe a
|
|
3331
3640
|
// verified embedding or OCR deployment out of the config (review findings on #3031). Stored
|
|
3332
3641
|
// OCR and dedicated-endpoint embedding providers leave the candidate set entirely — they are
|
|
3333
3642
|
// restored verbatim afterwards.
|
|
3334
|
-
const restoredSet = new Set(restoredVerbatimModelIds);
|
|
3643
|
+
const restoredSet = new Set(roles.restoredVerbatimModelIds);
|
|
3335
3644
|
const candidateNames = deploymentNames.filter((modelId) => !restoredSet.has(modelId));
|
|
3336
|
-
const storedEmbeddingSet = new Set(storedEmbeddingModelIds);
|
|
3337
|
-
const
|
|
3645
|
+
const storedEmbeddingSet = new Set(roles.storedEmbeddingModelIds);
|
|
3646
|
+
const submittedEmbeddingSet = new Set(roles.submittedEmbeddingModelIds);
|
|
3647
|
+
// A STORED embedding id that names a rerank engine is not an asserted role: field incident
|
|
3648
|
+
// (LiteLLM customer, 2026-08) — a declared `rerank` endpoint was filed as the gateway's embedding
|
|
3649
|
+
// model, and treating every stored id as asserted kept it there through every later save. It is
|
|
3650
|
+
// re-classified as a rerank candidate (probed, and wired only when nobody owns a reranker). A
|
|
3651
|
+
// client-submitted embedding id stays an explicit assertion.
|
|
3652
|
+
const rerankModelIds = candidateNames.filter((modelId) => storedEmbeddingSet.has(modelId) &&
|
|
3653
|
+
!submittedEmbeddingSet.has(modelId) &&
|
|
3654
|
+
isLikelyRerankModelId(modelId));
|
|
3655
|
+
const rerankSet = new Set(rerankModelIds);
|
|
3656
|
+
const modelIds = candidateNames.filter((modelId) => !rerankSet.has(modelId));
|
|
3657
|
+
const embeddingModelIds = modelIds.filter((modelId) => storedEmbeddingSet.has(modelId) ||
|
|
3658
|
+
submittedEmbeddingSet.has(modelId) ||
|
|
3659
|
+
isLikelyEmbeddingModelId(modelId));
|
|
3338
3660
|
const embeddingSet = new Set(embeddingModelIds);
|
|
3339
3661
|
return {
|
|
3340
|
-
modelIds
|
|
3341
|
-
chatModelIds:
|
|
3662
|
+
modelIds,
|
|
3663
|
+
chatModelIds: modelIds.filter((modelId) => !embeddingSet.has(modelId)),
|
|
3342
3664
|
embeddingModelIds,
|
|
3343
3665
|
imageInputModelIds: [],
|
|
3344
3666
|
modelMetadata: {},
|
|
3667
|
+
...(rerankModelIds.length === 0
|
|
3668
|
+
? {}
|
|
3669
|
+
: {
|
|
3670
|
+
rerankModelIds,
|
|
3671
|
+
unsupportedModels: rerankModelIds.map((id) => ({ id, reason: "rerank" })),
|
|
3672
|
+
}),
|
|
3673
|
+
};
|
|
3674
|
+
}
|
|
3675
|
+
// The embedding a previous configuration led with stays first: the default new Knowledge Pods bind
|
|
3676
|
+
// is the first embedding provider, and a re-discovery — a key rotation, a gateway that now lists
|
|
3677
|
+
// another engine ahead of it — must not rebind them silently. Everything new follows in discovery's
|
|
3678
|
+
// own order (declared before name-inferred, then by id).
|
|
3679
|
+
function withStoredEmbeddingOrder(discovered, stored) {
|
|
3680
|
+
const present = new Set(discovered.embeddingModelIds);
|
|
3681
|
+
const kept = currentEmbeddingModelIds(stored).filter((modelId) => present.has(modelId));
|
|
3682
|
+
if (kept.length === 0)
|
|
3683
|
+
return discovered;
|
|
3684
|
+
const keptSet = new Set(kept);
|
|
3685
|
+
return {
|
|
3686
|
+
...discovered,
|
|
3687
|
+
embeddingModelIds: [
|
|
3688
|
+
...kept,
|
|
3689
|
+
...discovered.embeddingModelIds.filter((modelId) => !keptSet.has(modelId)),
|
|
3690
|
+
],
|
|
3345
3691
|
};
|
|
3346
3692
|
}
|
|
3347
3693
|
async function candidateModelIdsForSetup(input, validationConfig) {
|
|
3348
3694
|
if (input.deploymentNames.length > 0) {
|
|
3349
|
-
|
|
3350
|
-
|
|
3351
|
-
|
|
3352
|
-
|
|
3353
|
-
|
|
3354
|
-
|
|
3355
|
-
|
|
3695
|
+
const selected = candidateModelsFromDeploymentNames(input.deploymentNames, {
|
|
3696
|
+
storedEmbeddingModelIds: input.storedEmbeddingModelIds,
|
|
3697
|
+
submittedEmbeddingModelIds: input.submittedEmbeddingModelIds,
|
|
3698
|
+
restoredVerbatimModelIds: [
|
|
3699
|
+
...input.storedOcrModelIds,
|
|
3700
|
+
...input.storedDedicatedEmbeddingModelIds,
|
|
3701
|
+
// Voice ids leave the candidate set too, but applyVoiceProviders restores them — they
|
|
3702
|
+
// must not join the verbatim-restore list below.
|
|
3703
|
+
...input.storedVoiceModelIds,
|
|
3704
|
+
],
|
|
3705
|
+
});
|
|
3706
|
+
return enrichSelectedDeploymentMetadata(input, validationConfig, selected);
|
|
3707
|
+
}
|
|
3708
|
+
return withStoredEmbeddingOrder(await discoverSetupModels(input, validationConfig), input.stored);
|
|
3709
|
+
}
|
|
3710
|
+
async function awaitSetupOperation(operation, signal) {
|
|
3711
|
+
if (signal === undefined)
|
|
3712
|
+
return operation;
|
|
3713
|
+
signal.throwIfAborted();
|
|
3714
|
+
let onAbort;
|
|
3715
|
+
const aborted = new Promise((_resolve, reject) => {
|
|
3716
|
+
onAbort = () => {
|
|
3717
|
+
reject(new DOMException("Gateway setup cancelled.", "AbortError"));
|
|
3718
|
+
};
|
|
3719
|
+
signal.addEventListener("abort", onAbort, { once: true });
|
|
3720
|
+
});
|
|
3721
|
+
try {
|
|
3722
|
+
return await Promise.race([operation, aborted]);
|
|
3723
|
+
}
|
|
3724
|
+
finally {
|
|
3725
|
+
if (onAbort !== undefined)
|
|
3726
|
+
signal.removeEventListener("abort", onAbort);
|
|
3356
3727
|
}
|
|
3357
|
-
return normalizeDiscoveryResult(await input.discovery(input.baseUrl, input.apiKey, input.apiKeyHeaderName, validationConfig.egress, input.correlationId));
|
|
3358
3728
|
}
|
|
3359
|
-
function
|
|
3729
|
+
function discoveryProgrammingFailure(cause) {
|
|
3730
|
+
return (cause instanceof TypeError || cause instanceof ReferenceError || cause instanceof RangeError);
|
|
3731
|
+
}
|
|
3732
|
+
function discoveryHttpStatus(cause) {
|
|
3733
|
+
const value = cause !== null && typeof cause === "object" && "httpStatus" in cause
|
|
3734
|
+
? cause.httpStatus
|
|
3735
|
+
: undefined;
|
|
3736
|
+
return typeof value === "number" && Number.isSafeInteger(value) && value >= 100 && value <= 599
|
|
3737
|
+
? value
|
|
3738
|
+
: undefined;
|
|
3739
|
+
}
|
|
3740
|
+
function discoveryTimedOut(cause) {
|
|
3741
|
+
return ((cause instanceof Error && cause.name === "TimeoutError") ||
|
|
3742
|
+
(cause instanceof GatewayError && cause.code === ERROR_CODES.TIMEOUT));
|
|
3743
|
+
}
|
|
3744
|
+
function discoveryAnswerIsUnusable(cause) {
|
|
3745
|
+
if (cause === null || typeof cause !== "object" || !("discoveryCode" in cause))
|
|
3746
|
+
return false;
|
|
3747
|
+
return (cause.discoveryCode === "DISCOVERY_EMPTY" ||
|
|
3748
|
+
cause.discoveryCode === "DISCOVERY_ALL_ENTRIES_UNSUPPORTED" ||
|
|
3749
|
+
cause.discoveryCode === "DISCOVERY_INVALID_RESPONSE");
|
|
3750
|
+
}
|
|
3751
|
+
function discoveryRouteOutcome(cause, signal) {
|
|
3752
|
+
if (discoveryTimedOut(cause))
|
|
3753
|
+
return "timeout";
|
|
3754
|
+
if (signal.aborted)
|
|
3755
|
+
return "cancelled";
|
|
3756
|
+
if (discoveryHttpStatus(cause) !== undefined)
|
|
3757
|
+
return "http-error";
|
|
3758
|
+
if (discoveryAnswerIsUnusable(cause))
|
|
3759
|
+
return "unusable";
|
|
3760
|
+
return discoveryProgrammingFailure(cause) ? "failed" : "transport-error";
|
|
3761
|
+
}
|
|
3762
|
+
function discoveryFailureKind(cause, status) {
|
|
3763
|
+
if (discoveryAnswerIsUnusable(cause))
|
|
3764
|
+
return "validation-failed";
|
|
3765
|
+
if (status === 401 || status === 403)
|
|
3766
|
+
return "permission-denied";
|
|
3767
|
+
if (status === 429)
|
|
3768
|
+
return "rate-limited";
|
|
3769
|
+
if (discoveryTimedOut(cause))
|
|
3770
|
+
return "timeout";
|
|
3771
|
+
return discoveryProgrammingFailure(cause) ? "internal" : "unavailable";
|
|
3772
|
+
}
|
|
3773
|
+
function discoveryFailureDetail(cause, cancelled) {
|
|
3774
|
+
const httpStatus = discoveryHttpStatus(cause);
|
|
3775
|
+
return {
|
|
3776
|
+
errorKind: cancelled ? "cancelled" : discoveryFailureKind(cause, httpStatus),
|
|
3777
|
+
evidence: {
|
|
3778
|
+
...(httpStatus === undefined ? {} : { httpStatus }),
|
|
3779
|
+
frames: keikoStackFrames(cause),
|
|
3780
|
+
causeChain: causeChain(cause),
|
|
3781
|
+
},
|
|
3782
|
+
};
|
|
3783
|
+
}
|
|
3784
|
+
function metadataFailureOutcome(cause, signal) {
|
|
3785
|
+
if (signal?.aborted === true)
|
|
3786
|
+
return "cancelled";
|
|
3787
|
+
return discoveryProgrammingFailure(cause) ? "failed" : "unavailable";
|
|
3788
|
+
}
|
|
3789
|
+
async function discoverSetupModels(input, validationConfig, selected) {
|
|
3790
|
+
const startedAt = Date.now();
|
|
3791
|
+
const trace = createSetupDiscoveryTrace();
|
|
3792
|
+
const selectedModelCount = selectedModelCountOf(selected);
|
|
3793
|
+
try {
|
|
3794
|
+
input.signal?.throwIfAborted();
|
|
3795
|
+
const result = await awaitSetupOperation(input.discovery(input.baseUrl, input.apiKey, input.apiKeyHeaderName, validationConfig.egress, input.correlationId, trace), input.signal);
|
|
3796
|
+
input.signal?.throwIfAborted();
|
|
3797
|
+
const normalized = normalizeDiscoveryResult(result);
|
|
3798
|
+
logSetupMetadataOutcome({
|
|
3799
|
+
outcome: "available",
|
|
3800
|
+
...(selected === undefined
|
|
3801
|
+
? {}
|
|
3802
|
+
: { selectionCounts: selectedMetadataCounts(selected, normalized) }),
|
|
3803
|
+
}, trace, startedAt, input.correlationId);
|
|
3804
|
+
return normalized;
|
|
3805
|
+
}
|
|
3806
|
+
catch (cause) {
|
|
3807
|
+
const outcome = metadataFailureOutcome(cause, input.signal);
|
|
3808
|
+
logSetupMetadataOutcome({
|
|
3809
|
+
outcome,
|
|
3810
|
+
...(selectedModelCount === undefined ? {} : { selectionCounts: { selectedModelCount } }),
|
|
3811
|
+
failure: discoveryFailureDetail(cause, outcome === "cancelled"),
|
|
3812
|
+
}, trace, startedAt, input.correlationId);
|
|
3813
|
+
throw cause;
|
|
3814
|
+
}
|
|
3815
|
+
}
|
|
3816
|
+
function selectedDeploymentMetadata(selected, discovered) {
|
|
3817
|
+
const chat = new Set(discovered.chatModelIds);
|
|
3818
|
+
const embedding = new Set(discovered.embeddingModelIds);
|
|
3819
|
+
const compatible = [
|
|
3820
|
+
...selected.chatModelIds.filter((id) => chat.has(id)),
|
|
3821
|
+
...selected.embeddingModelIds.filter((id) => embedding.has(id)),
|
|
3822
|
+
];
|
|
3823
|
+
return Object.fromEntries(compatible.flatMap((id) => {
|
|
3824
|
+
const metadata = discovered.modelMetadata[id];
|
|
3825
|
+
return metadata === undefined ? [] : [[id, metadata]];
|
|
3826
|
+
}));
|
|
3827
|
+
}
|
|
3828
|
+
function selectedModelCountOf(selected) {
|
|
3829
|
+
return selected === undefined
|
|
3830
|
+
? undefined
|
|
3831
|
+
: selected.chatModelIds.length + selected.embeddingModelIds.length;
|
|
3832
|
+
}
|
|
3833
|
+
function selectedMetadataCounts(selected, discovered) {
|
|
3834
|
+
const allDiscovered = new Set(discovered.modelIds);
|
|
3835
|
+
let metadataEnrichedModelCount = 0;
|
|
3836
|
+
let roleMismatchModelCount = 0;
|
|
3837
|
+
let notDiscoveredModelCount = 0;
|
|
3838
|
+
const groups = [
|
|
3839
|
+
[selected.chatModelIds, discovered.chatModelIds],
|
|
3840
|
+
[selected.embeddingModelIds, discovered.embeddingModelIds],
|
|
3841
|
+
];
|
|
3842
|
+
for (const [selectedIds, discoveredIds] of groups) {
|
|
3843
|
+
const compatible = new Set(discoveredIds);
|
|
3844
|
+
for (const id of selectedIds) {
|
|
3845
|
+
if (!allDiscovered.has(id))
|
|
3846
|
+
notDiscoveredModelCount++;
|
|
3847
|
+
else if (!compatible.has(id))
|
|
3848
|
+
roleMismatchModelCount++;
|
|
3849
|
+
else if (Object.keys(discovered.modelMetadata[id] ?? {}).length > 0)
|
|
3850
|
+
metadataEnrichedModelCount++;
|
|
3851
|
+
}
|
|
3852
|
+
}
|
|
3853
|
+
return {
|
|
3854
|
+
selectedModelCount: selectedModelCountOf(selected),
|
|
3855
|
+
metadataEnrichedModelCount,
|
|
3856
|
+
roleMismatchModelCount,
|
|
3857
|
+
notDiscoveredModelCount,
|
|
3858
|
+
};
|
|
3859
|
+
}
|
|
3860
|
+
async function enrichSelectedDeploymentMetadata(input, validationConfig, selected) {
|
|
3861
|
+
try {
|
|
3862
|
+
const discovered = await discoverSetupModels(input, validationConfig, selected);
|
|
3863
|
+
reportDiscoveryTruncation(input.diagnostics, input.correlationId, discovered);
|
|
3864
|
+
return { ...selected, modelMetadata: selectedDeploymentMetadata(selected, discovered) };
|
|
3865
|
+
}
|
|
3866
|
+
catch (cause) {
|
|
3867
|
+
input.signal?.throwIfAborted();
|
|
3868
|
+
if (discoveryProgrammingFailure(cause))
|
|
3869
|
+
throw cause;
|
|
3870
|
+
// Explicit deployments remain usable on gateways without a discovery endpoint. Their
|
|
3871
|
+
// existing smoke probes validate credentials and callable roles; discovery cannot add ids.
|
|
3872
|
+
return selected;
|
|
3873
|
+
}
|
|
3874
|
+
}
|
|
3875
|
+
function finalRawConfigForSetup(input, testedModelIds, embeddingModelIds, imageInputModelIds, responseFormatModelIds, modelMetadata, admittedModels) {
|
|
3360
3876
|
const configuredModelIds = mergeChatAndEmbeddingModelIds(testedModelIds, embeddingModelIds);
|
|
3361
3877
|
const rawConfig = buildRawConfig(input.baseUrl, input.apiKey, configuredModelIds, {
|
|
3362
3878
|
preserveExisting: input.preserveExisting,
|
|
@@ -3378,16 +3894,17 @@ function finalRawConfigForSetup(input, testedModelIds, embeddingModelIds, imageI
|
|
|
3378
3894
|
// configuration — a reranker or egress topology must not vanish because an unrelated
|
|
3379
3895
|
// capability was updated (review finding on #3031).
|
|
3380
3896
|
...(input.current?.grounding === undefined ? {} : { grounding: input.current.grounding }),
|
|
3381
|
-
...(
|
|
3897
|
+
...rerankerBlockForSetup(admittedModels),
|
|
3382
3898
|
...(input.current?.egress === undefined ? {} : { egress: input.current.egress }),
|
|
3383
3899
|
...(input.figmaAccessToken === undefined
|
|
3384
3900
|
? {}
|
|
3385
3901
|
: { figma: { accessToken: input.figmaAccessToken } }),
|
|
3902
|
+
...operatorPolicyBlocks(input.current),
|
|
3386
3903
|
};
|
|
3387
3904
|
// Verbatim restoration reads the DURABLE stored view: restored values are what the FILE
|
|
3388
3905
|
// holds, so a transient per-model env override neither hides a sharing relationship nor gets
|
|
3389
3906
|
// baked into the rebuilt persisted config (review finding on #3037).
|
|
3390
|
-
const voiceProviders = discoveredVoiceProvidersForSetup(input,
|
|
3907
|
+
const voiceProviders = discoveredVoiceProvidersForSetup(input, admittedModels);
|
|
3391
3908
|
return applyStoredDedicatedProviders(applyVoiceProviders(rawConfigWithOptionalBlocks, voiceProviders), input.stored, [...input.storedOcrModelIds, ...input.storedDedicatedEmbeddingModelIds], {
|
|
3392
3909
|
baseUrl: input.baseUrl,
|
|
3393
3910
|
apiKey: input.apiKey,
|
|
@@ -3396,6 +3913,15 @@ function finalRawConfigForSetup(input, testedModelIds, embeddingModelIds, imageI
|
|
|
3396
3913
|
apiVersion: input.apiVersion,
|
|
3397
3914
|
});
|
|
3398
3915
|
}
|
|
3916
|
+
// The rebuild's reranker block is whatever `admitRerankerCandidates` decided: the reranker an
|
|
3917
|
+
// operator (or an earlier setup) owns — rebased onto the setup connection when it rode the gateway,
|
|
3918
|
+
// and verified there first when that connection moved to a new endpoint — or, only when nobody owns
|
|
3919
|
+
// one, a discovered engine that passed its live probe. The plaintext key here is sealed into the
|
|
3920
|
+
// credential vault by the same persistence step that seals every provider key; it never reaches the
|
|
3921
|
+
// file or the response.
|
|
3922
|
+
function rerankerBlockForSetup(admittedModels) {
|
|
3923
|
+
return admittedModels.reranker === undefined ? {} : { reranker: admittedModels.reranker };
|
|
3924
|
+
}
|
|
3399
3925
|
function discoveredVoiceProvidersForSetup(input, discovered) {
|
|
3400
3926
|
const configured = input.voiceProviders.length > 0
|
|
3401
3927
|
? input.voiceProviders
|
|
@@ -3702,6 +4228,113 @@ async function admitEmbeddingCandidates(input, probeConfig, candidates) {
|
|
|
3702
4228
|
droppedUnverified: failed.filter((id) => !asserted.has(id)),
|
|
3703
4229
|
};
|
|
3704
4230
|
}
|
|
4231
|
+
// A discovered rerank engine becomes the retrieval reranker only when nobody owns one and a live
|
|
4232
|
+
// two-document probe answers — the same gate embedding candidates pass. A model the gateway DECLARED
|
|
4233
|
+
// as `rerank` is still verified: a declaration says what the model is, not that its route works.
|
|
4234
|
+
// Probing is bounded (a handful of candidates, sequentially, in discovery's declared-first order,
|
|
4235
|
+
// inside one request-wide time budget) so a gateway that lists many rerank aliases cannot stretch
|
|
4236
|
+
// setup, and the first engine that ranks wins.
|
|
4237
|
+
const MAX_RERANKER_PROBES = 3;
|
|
4238
|
+
// Stored or current: either view means an operator (or an earlier setup) already chose a reranker,
|
|
4239
|
+
// and a discovered engine must never displace that choice. The runtime view wins; a reranker only
|
|
4240
|
+
// the durable file names still survives the rewrite.
|
|
4241
|
+
function ownedReranker(input) {
|
|
4242
|
+
return input.current?.reranker ?? input.stored?.reranker;
|
|
4243
|
+
}
|
|
4244
|
+
// A reranker that rode the stored gateway connection (same endpoint AND credential — exactly what a
|
|
4245
|
+
// discovered one does) follows a credential rotation or endpoint move like every other provider
|
|
4246
|
+
// that shared it: left behind, it would keep sending a dead token and silently degrade retrieval.
|
|
4247
|
+
// One with its own endpoint or credential keeps both — the freshly verified connection details
|
|
4248
|
+
// never travel to a connection they were not tested against.
|
|
4249
|
+
function rebasedReranker(input, reranker) {
|
|
4250
|
+
if (!sharesStoredGatewayConnection(reranker, storedPrimaryGatewayProvider(input.stored))) {
|
|
4251
|
+
return reranker;
|
|
4252
|
+
}
|
|
4253
|
+
return {
|
|
4254
|
+
...reranker,
|
|
4255
|
+
baseUrl: input.baseUrl,
|
|
4256
|
+
apiKey: input.apiKey,
|
|
4257
|
+
apiKeyHeaderName: input.apiKeyHeaderName,
|
|
4258
|
+
};
|
|
4259
|
+
}
|
|
4260
|
+
// The reranker block a discovered engine persists: the verified setup connection, nothing else.
|
|
4261
|
+
function discoveredRerankerBlockFor(input, modelId) {
|
|
4262
|
+
return {
|
|
4263
|
+
modelId,
|
|
4264
|
+
baseUrl: input.baseUrl,
|
|
4265
|
+
apiKey: input.apiKey,
|
|
4266
|
+
apiKeyHeaderName: input.apiKeyHeaderName,
|
|
4267
|
+
timeoutMs: input.timeoutMs ?? DEFAULT_RERANKER_TIMEOUT_MS,
|
|
4268
|
+
};
|
|
4269
|
+
}
|
|
4270
|
+
// The config a reranker is probed under: its own block on the verified setup connection, and the
|
|
4271
|
+
// egress policy the request validated under unless the block states its own.
|
|
4272
|
+
function withProbeEgress(input, reranker) {
|
|
4273
|
+
return reranker.egress === undefined && input.egress !== undefined
|
|
4274
|
+
? { ...reranker, egress: input.egress }
|
|
4275
|
+
: reranker;
|
|
4276
|
+
}
|
|
4277
|
+
function probeRerankerOn(input, validationConfig, reranker) {
|
|
4278
|
+
return input.rerankerProbe({ ...validationConfig, reranker: withProbeEgress(input, reranker) });
|
|
4279
|
+
}
|
|
4280
|
+
async function admitRerankerCandidates(input, validationConfig, candidates) {
|
|
4281
|
+
const owned = ownedReranker(input);
|
|
4282
|
+
if (owned === undefined)
|
|
4283
|
+
return admitDiscoveredRerankers(input, validationConfig, candidates, 0);
|
|
4284
|
+
const carried = rebasedReranker(input, owned);
|
|
4285
|
+
const candidateCount = candidates.length;
|
|
4286
|
+
if (sameBaseUrlIdentity(owned.baseUrl, carried.baseUrl)) {
|
|
4287
|
+
// Its own connection, or the gateway's endpoint unchanged (a credential rotation): nothing new
|
|
4288
|
+
// to verify — the model is hosted where it always was.
|
|
4289
|
+
return {
|
|
4290
|
+
reranker: carried,
|
|
4291
|
+
...(candidateCount === 0
|
|
4292
|
+
? {}
|
|
4293
|
+
: { resolution: { outcome: "kept-existing", candidateCount, probedCount: 0 } }),
|
|
4294
|
+
};
|
|
4295
|
+
}
|
|
4296
|
+
// It rode the gateway to a NEW endpoint. Nothing says that gateway hosts this model, so it is
|
|
4297
|
+
// verified there before it is repointed; when it does not answer it is no longer owned, and
|
|
4298
|
+
// discovery on the new gateway decides.
|
|
4299
|
+
if (await probeRerankerOn(input, validationConfig, carried)) {
|
|
4300
|
+
return {
|
|
4301
|
+
reranker: carried,
|
|
4302
|
+
resolution: { outcome: "kept-existing", candidateCount, probedCount: 1 },
|
|
4303
|
+
};
|
|
4304
|
+
}
|
|
4305
|
+
return admitDiscoveredRerankers(input, validationConfig, candidates, 1);
|
|
4306
|
+
}
|
|
4307
|
+
async function admitDiscoveredRerankers(input, validationConfig, candidates, alreadyProbed) {
|
|
4308
|
+
const candidateCount = candidates.length;
|
|
4309
|
+
if (candidateCount === 0 && alreadyProbed === 0)
|
|
4310
|
+
return {};
|
|
4311
|
+
let probedCount = alreadyProbed;
|
|
4312
|
+
for (const modelId of candidates.slice(0, MAX_RERANKER_PROBES)) {
|
|
4313
|
+
probedCount += 1;
|
|
4314
|
+
const block = discoveredRerankerBlockFor(input, modelId);
|
|
4315
|
+
if (await probeRerankerOn(input, validationConfig, block)) {
|
|
4316
|
+
return {
|
|
4317
|
+
reranker: block,
|
|
4318
|
+
admittedModelId: modelId,
|
|
4319
|
+
resolution: { outcome: "wired", wiredModelId: modelId, candidateCount, probedCount },
|
|
4320
|
+
};
|
|
4321
|
+
}
|
|
4322
|
+
}
|
|
4323
|
+
return { resolution: { outcome: "probe-failed", candidateCount, probedCount } };
|
|
4324
|
+
}
|
|
4325
|
+
// The admitted view of the candidates: the reranker decision travels with it, and the engine that
|
|
4326
|
+
// passed its probe leaves the "unsupported" report — the operator sees what Keiko did NOT configure.
|
|
4327
|
+
function withRerankerAdmission(candidateModels, admission) {
|
|
4328
|
+
const { admittedModelId } = admission;
|
|
4329
|
+
const { unsupportedModels, rerankModelIds: _candidates, ...admitted } = candidateModels;
|
|
4330
|
+
const stillUnsupported = (unsupportedModels ?? []).filter((entry) => entry.id !== admittedModelId);
|
|
4331
|
+
return {
|
|
4332
|
+
...admitted,
|
|
4333
|
+
...(admission.reranker === undefined ? {} : { reranker: admission.reranker }),
|
|
4334
|
+
...(admission.resolution === undefined ? {} : { rerankerResolution: admission.resolution }),
|
|
4335
|
+
...(stillUnsupported.length === 0 ? {} : { unsupportedModels: stillUnsupported }),
|
|
4336
|
+
};
|
|
4337
|
+
}
|
|
3705
4338
|
// Body-free counterpart to reportDiscoveryTruncation: counts and reason codes only, never a model
|
|
3706
4339
|
// id or an endpoint. Ids belong in the setup RESPONSE, which the operator sees; the diagnostic
|
|
3707
4340
|
// channel stays free of gateway inventory.
|
|
@@ -3778,7 +4411,7 @@ async function admitChatCandidatesOrDefer(input, candidateModels, admittedModels
|
|
|
3778
4411
|
catch (error) {
|
|
3779
4412
|
if (!temporaryGatewaySetupFailure(error))
|
|
3780
4413
|
throw error;
|
|
3781
|
-
throw new DeferredTemporaryChatAdmission(error, () => verifiedSetupFromChatAdmission(input,
|
|
4414
|
+
throw new DeferredTemporaryChatAdmission(error, () => verifiedSetupFromChatAdmission(input, admittedModels, candidateConfig, embeddingAdmission, temporaryChatAdmission(input, candidateModels, candidateConfig)));
|
|
3782
4415
|
}
|
|
3783
4416
|
}
|
|
3784
4417
|
async function verifySetupCandidate(input) {
|
|
@@ -3788,38 +4421,41 @@ async function verifySetupCandidate(input) {
|
|
|
3788
4421
|
reportLoopbackTargetAccepted(input.diagnostics, input.correlationId, input.baseUrl);
|
|
3789
4422
|
const validationConfig = validationConfigForSetup(input);
|
|
3790
4423
|
const candidateModels = await candidateModelIdsForSetup(input, validationConfig);
|
|
4424
|
+
input.signal?.throwIfAborted();
|
|
3791
4425
|
reportDiscoveryTruncation(input.diagnostics, input.correlationId, candidateModels);
|
|
3792
4426
|
const smokeTimeoutMs = input.deploymentNames.length > 0
|
|
3793
4427
|
? DEPLOYMENT_SMOKE_TIMEOUT_MS
|
|
3794
4428
|
: DISCOVERED_MODEL_SMOKE_TIMEOUT_MS;
|
|
3795
4429
|
const candidateConfig = probeConfigForModels(input, candidateModels.chatModelIds, smokeTimeoutMs);
|
|
3796
4430
|
const embeddingAdmission = await admitEmbeddingCandidates(input, embeddingProbeConfigFor(input, candidateModels, smokeTimeoutMs, candidateConfig), candidateModels.embeddingModelIds);
|
|
3797
|
-
|
|
3798
|
-
|
|
3799
|
-
|
|
3800
|
-
};
|
|
4431
|
+
input.signal?.throwIfAborted();
|
|
4432
|
+
const rerankerAdmission = await admitRerankerCandidates(input, validationConfig, candidateModels.rerankModelIds ?? []);
|
|
4433
|
+
const admittedModels = withRerankerAdmission({ ...candidateModels, embeddingModelIds: embeddingAdmission.admitted }, rerankerAdmission);
|
|
3801
4434
|
// Emitted BEFORE the chat smoke test: the tester throws on an all-rejected gateway, and the
|
|
3802
4435
|
// record of what discovery refused is most valuable for exactly that failed attempt.
|
|
3803
|
-
reportUnusableDiscoveredModels(input.diagnostics, input.correlationId,
|
|
4436
|
+
reportUnusableDiscoveredModels(input.diagnostics, input.correlationId, admittedModels.unsupportedModels ?? [], embeddingAdmission);
|
|
4437
|
+
input.signal?.throwIfAborted();
|
|
3804
4438
|
const chatAdmission = await admitChatCandidatesOrDefer(input, candidateModels, admittedModels, candidateConfig, embeddingAdmission);
|
|
3805
4439
|
reportChatSmokeAdmission(input.diagnostics, input.correlationId, chatAdmission);
|
|
3806
|
-
return verifiedSetupFromChatAdmission(input,
|
|
4440
|
+
return verifiedSetupFromChatAdmission(input, admittedModels, candidateConfig, embeddingAdmission, chatAdmission);
|
|
3807
4441
|
}
|
|
3808
|
-
function verifiedSetupFromChatAdmission(input,
|
|
4442
|
+
function verifiedSetupFromChatAdmission(input, admittedModels, candidateConfig, embeddingAdmission, chatAdmission) {
|
|
3809
4443
|
const { testResult } = chatAdmission;
|
|
3810
|
-
|
|
4444
|
+
if (input.imageInputModelIdsProvided) {
|
|
4445
|
+
assertImageInputModelsWereTested(input.imageInputModelIds, chatAdmission.configuredModelIds);
|
|
4446
|
+
}
|
|
3811
4447
|
const rawConfigWithOptionalBlocks = finalRawConfigForTestedSetup(input, testResult, admittedModels, chatAdmission.configuredModelIds);
|
|
3812
4448
|
const parsedConfig = parsedSetupConfigWithToolCallingProvenance(input, rawConfigWithOptionalBlocks, candidateConfig, testResult.toolCallingObservations ?? []);
|
|
3813
|
-
return verifiedSetupResult(parsedConfig.rawConfig, parsedConfig.config, testResult,
|
|
4449
|
+
return verifiedSetupResult(parsedConfig.rawConfig, parsedConfig.config, testResult, admittedModels, embeddingAdmission, chatAdmission);
|
|
3814
4450
|
}
|
|
3815
|
-
function verifiedSetupResult(rawConfig, config, testResult,
|
|
4451
|
+
function verifiedSetupResult(rawConfig, config, testResult, admittedModels, embeddingAdmission, chatAdmission) {
|
|
3816
4452
|
return {
|
|
3817
4453
|
rawConfig,
|
|
3818
4454
|
config,
|
|
3819
4455
|
testedModelIds: testResult.testedModelIds,
|
|
3820
|
-
skippedModelIds: skippedModelIdsForSetup(
|
|
3821
|
-
...(
|
|
3822
|
-
? { unsupportedModels:
|
|
4456
|
+
skippedModelIds: skippedModelIdsForSetup(admittedModels.modelIds, chatAdmission.configuredModelIds, embeddingAdmission.admitted),
|
|
4457
|
+
...(admittedModels.unsupportedModels !== undefined
|
|
4458
|
+
? { unsupportedModels: admittedModels.unsupportedModels }
|
|
3823
4459
|
: {}),
|
|
3824
4460
|
...(embeddingAdmission.retainedUnverified.length > 0
|
|
3825
4461
|
? { unverifiedEmbeddingModelIds: embeddingAdmission.retainedUnverified }
|
|
@@ -3833,6 +4469,9 @@ function verifiedSetupResult(rawConfig, config, testResult, candidateModels, emb
|
|
|
3833
4469
|
...(chatAdmission.droppedModelIds.length > 0
|
|
3834
4470
|
? { droppedChatModelIds: chatAdmission.droppedModelIds }
|
|
3835
4471
|
: {}),
|
|
4472
|
+
...(admittedModels.rerankerResolution !== undefined
|
|
4473
|
+
? { rerankerResolution: admittedModels.rerankerResolution }
|
|
4474
|
+
: {}),
|
|
3836
4475
|
};
|
|
3837
4476
|
}
|
|
3838
4477
|
// KEIKO-0497 (#2901): configuring the gateway points the product at an outbound endpoint and can
|
|
@@ -3879,7 +4518,7 @@ function recordGatewaySetupAudit(deps, request, config, outcome) {
|
|
|
3879
4518
|
// by both diagnostics below, so a minted UUID here would key the persisted audit evidence and
|
|
3880
4519
|
// its failure diagnostics to a different identity than the loopback/discovery diagnostics this
|
|
3881
4520
|
// same request emits under UNKNOWN_CORRELATION_ID — one request, two correlation identities,
|
|
3882
|
-
// unjoinable in a support
|
|
4521
|
+
// unjoinable in a support report. (The randomUUID below is an evidence-store KEY, not a
|
|
3883
4522
|
// correlation id, and is correct.)
|
|
3884
4523
|
correlationId: request.correlationId ?? UNKNOWN_CORRELATION_ID,
|
|
3885
4524
|
targetClass: gatewaySetupTargetClass(request.baseUrl),
|
|
@@ -4130,6 +4769,26 @@ function gatewayUnavailableResult() {
|
|
|
4130
4769
|
body: errorBody("GATEWAY_SETUP_UNAVAILABLE", "Gateway setup is unavailable."),
|
|
4131
4770
|
};
|
|
4132
4771
|
}
|
|
4772
|
+
// One resolution per committed setup request. A probe that failed leaves reranking off with nothing
|
|
4773
|
+
// else on screen, so besides the (warn-level) resolution line it leaves one body-free diagnostic:
|
|
4774
|
+
// a fixed code, never a model id, an endpoint or a credential — the engine is named in the setup
|
|
4775
|
+
// response the operator reads.
|
|
4776
|
+
function reportRerankerResolution(deps, resolution, correlationId) {
|
|
4777
|
+
if (resolution === undefined)
|
|
4778
|
+
return;
|
|
4779
|
+
logRerankerSetupResolution(resolution, correlationId);
|
|
4780
|
+
if (resolution.outcome !== "probe-failed")
|
|
4781
|
+
return;
|
|
4782
|
+
emitServerDiagnostic(deps.diagnostics, {
|
|
4783
|
+
correlationId: correlationId ?? UNKNOWN_CORRELATION_ID,
|
|
4784
|
+
timestamp: new Date().toISOString(),
|
|
4785
|
+
operation: "POST /api/gateway/setup",
|
|
4786
|
+
source: "gateway.setup.reranker-probe",
|
|
4787
|
+
errorClass: "GatewayRerankerProbeFailed",
|
|
4788
|
+
message: "Provider verification failed without exposing upstream response details.",
|
|
4789
|
+
code: "GATEWAY_RERANKER_PROBE_FAILED",
|
|
4790
|
+
});
|
|
4791
|
+
}
|
|
4133
4792
|
function finalizeVerifiedCandidate(verified, current, deps, gatewayConfig, request) {
|
|
4134
4793
|
persistGatewayConfig(withDiskGatewayEgress(verified.rawConfig, gatewayConfig.storagePath, deps, current === undefined, request.correlationId), gatewayConfig.storagePath, deps, request.correlationId);
|
|
4135
4794
|
gatewayConfig.set(verified.config, true, request.correlationId);
|
|
@@ -4137,6 +4796,7 @@ function finalizeVerifiedCandidate(verified, current, deps, gatewayConfig, reque
|
|
|
4137
4796
|
gatewayConfig.recordVerifiedCapability(modelId, { conversationReady: true }, new Date().toISOString(), gatewayConfig.generation());
|
|
4138
4797
|
}
|
|
4139
4798
|
logVoiceSetupResolution(verified.config, request.correlationId);
|
|
4799
|
+
reportRerankerResolution(deps, verified.rerankerResolution, request.correlationId);
|
|
4140
4800
|
recordGatewaySetupAudit(deps, request, verified.config, "candidate-accepted");
|
|
4141
4801
|
return setupSuccessResult(verified.config, verified.testedModelIds, verified.skippedModelIds, {
|
|
4142
4802
|
...(verified.unsupportedModels !== undefined
|
|
@@ -4157,8 +4817,11 @@ function finalizeVerifiedCandidate(verified, current, deps, gatewayConfig, reque
|
|
|
4157
4817
|
});
|
|
4158
4818
|
}
|
|
4159
4819
|
async function trySetupCandidate(baseUrl, request, deps, gatewayConfig, seams, current) {
|
|
4820
|
+
request.signal?.throwIfAborted();
|
|
4160
4821
|
const verified = await verifySetupCandidate({
|
|
4822
|
+
...(request.signal === undefined ? {} : { signal: request.signal }),
|
|
4161
4823
|
embeddingProbe: seams.embeddingProbe,
|
|
4824
|
+
rerankerProbe: seams.rerankerProbe,
|
|
4162
4825
|
preserveExisting: request.preserveExisting,
|
|
4163
4826
|
baseUrl,
|
|
4164
4827
|
apiKey: request.apiKey,
|
|
@@ -4188,6 +4851,7 @@ async function trySetupCandidate(baseUrl, request, deps, gatewayConfig, seams, c
|
|
|
4188
4851
|
diagnostics: deps.diagnostics,
|
|
4189
4852
|
correlationId: request.correlationId,
|
|
4190
4853
|
});
|
|
4854
|
+
request.signal?.throwIfAborted();
|
|
4191
4855
|
const workflowEligibilityError = validateWorkflowEligibleModelIds(request, verified.config);
|
|
4192
4856
|
if (workflowEligibilityError !== undefined)
|
|
4193
4857
|
return workflowEligibilityError;
|
|
@@ -4421,6 +5085,7 @@ async function verifyAndSaveExistingConfigUpdate(request, current, deps, gateway
|
|
|
4421
5085
|
if (figmaFailure !== undefined) {
|
|
4422
5086
|
return figmaFailure;
|
|
4423
5087
|
}
|
|
5088
|
+
request.signal?.throwIfAborted();
|
|
4424
5089
|
return saveExistingConfigUpdate(request, current, deps, gatewayConfig);
|
|
4425
5090
|
}
|
|
4426
5091
|
function shouldRequireDeploymentNames(request, baseUrlCandidates, env) {
|
|
@@ -4438,9 +5103,11 @@ function shouldRequireDeploymentNames(request, baseUrlCandidates, env) {
|
|
|
4438
5103
|
}
|
|
4439
5104
|
async function verifyAndSaveGatewaySetup(request, current, deps, gatewayConfig) {
|
|
4440
5105
|
const seams = {
|
|
4441
|
-
tester: gatewaySetupTester(deps, request.correlationId),
|
|
4442
|
-
embeddingProbe: gatewayEmbeddingProbe(deps, request.correlationId),
|
|
4443
|
-
|
|
5106
|
+
tester: gatewaySetupTester(deps, request.correlationId, request.signal),
|
|
5107
|
+
embeddingProbe: gatewayEmbeddingProbe(deps, request.correlationId, request.signal),
|
|
5108
|
+
rerankerProbe: gatewayRerankerProbe(deps, request.correlationId, request.signal),
|
|
5109
|
+
discovery: deps.gatewayModelDiscovery ??
|
|
5110
|
+
((...args) => defaultGatewayModelDiscovery(...args, request.signal)),
|
|
4444
5111
|
};
|
|
4445
5112
|
const figmaFailure = await verifySubmittedFigmaCredential(request, deps);
|
|
4446
5113
|
if (figmaFailure !== undefined) {
|
|
@@ -4475,6 +5142,8 @@ async function attemptSetupCandidates(baseUrlCandidates, request, deps, gatewayC
|
|
|
4475
5142
|
return { failures, result };
|
|
4476
5143
|
}
|
|
4477
5144
|
catch (error) {
|
|
5145
|
+
if (request.signal?.aborted === true)
|
|
5146
|
+
return { failures: [...failures, { baseUrl, error }] };
|
|
4478
5147
|
reportSetupVerificationFailure(deps, originalSetupVerificationError(error), request.correlationId, "gateway.setup.provider-verify");
|
|
4479
5148
|
failures.push({
|
|
4480
5149
|
baseUrl,
|
|
@@ -4483,11 +5152,15 @@ async function attemptSetupCandidates(baseUrlCandidates, request, deps, gatewayC
|
|
|
4483
5152
|
? { resumeTemporaryAdmission: error.resume }
|
|
4484
5153
|
: {}),
|
|
4485
5154
|
});
|
|
5155
|
+
if (discoveryProgrammingFailure(error))
|
|
5156
|
+
return { failures };
|
|
4486
5157
|
}
|
|
4487
5158
|
}
|
|
4488
5159
|
return { failures };
|
|
4489
5160
|
}
|
|
4490
5161
|
function temporaryAdmissionOrFailure(failures, request, deps, gatewayConfig, current) {
|
|
5162
|
+
if (request.signal?.aborted === true)
|
|
5163
|
+
return setupFailureResult(candidateFailureMessages(failures), request.correlationId);
|
|
4491
5164
|
const temporary = failures.find((failure) => temporaryGatewaySetupFailure(failure.error) && failure.resumeTemporaryAdmission !== undefined);
|
|
4492
5165
|
const resume = temporary?.resumeTemporaryAdmission;
|
|
4493
5166
|
if (resume !== undefined &&
|
|
@@ -4524,10 +5197,17 @@ export async function handleGatewaySetup(ctx, deps) {
|
|
|
4524
5197
|
if ("status" in request) {
|
|
4525
5198
|
return request;
|
|
4526
5199
|
}
|
|
4527
|
-
|
|
4528
|
-
|
|
5200
|
+
const cancellation = createRequestCancellation(ctx, "Gateway setup client disconnected.");
|
|
5201
|
+
const cancellableRequest = { ...request, signal: cancellation.signal };
|
|
5202
|
+
try {
|
|
5203
|
+
if (!request.verifyGateway && current !== undefined) {
|
|
5204
|
+
return await verifyAndSaveExistingConfigUpdate(cancellableRequest, current, deps, gatewayConfig);
|
|
5205
|
+
}
|
|
5206
|
+
return await verifyAndSaveGatewaySetup(cancellableRequest, current, deps, gatewayConfig);
|
|
5207
|
+
}
|
|
5208
|
+
finally {
|
|
5209
|
+
cancellation.dispose();
|
|
4529
5210
|
}
|
|
4530
|
-
return verifyAndSaveGatewaySetup(request, current, deps, gatewayConfig);
|
|
4531
5211
|
}
|
|
4532
5212
|
const VERIFIED_CAPABILITY_FIELDS = new Set([
|
|
4533
5213
|
"streaming",
|
|
@@ -4605,7 +5285,10 @@ function replaceModelCapability(config, modelId, fields, checkedAt = new Date().
|
|
|
4605
5285
|
const replacement = {
|
|
4606
5286
|
...current,
|
|
4607
5287
|
...fields,
|
|
4608
|
-
// The long-context probe proves a lower bound, so it may raise a stored window, never shrink
|
|
5288
|
+
// The long-context probe proves a lower bound, so it may raise a stored window, never shrink
|
|
5289
|
+
// it. It does not end an assumed or provider-reported window: only the provider's own
|
|
5290
|
+
// statement does (gateway-context-window.ts), so conversations keep planning the assumption and
|
|
5291
|
+
// the window probe keeps running, while the Coding Workbench reads the proven floor.
|
|
4609
5292
|
...(fields.contextWindow === undefined
|
|
4610
5293
|
? {}
|
|
4611
5294
|
: { contextWindow: Math.max(current.contextWindow, fields.contextWindow) }),
|
|
@@ -4780,13 +5463,94 @@ export function reconcileGatewayContextWindowReadiness(deps, report, observedGen
|
|
|
4780
5463
|
if (reconciliation === undefined)
|
|
4781
5464
|
return;
|
|
4782
5465
|
const stored = findConfiguredCapability(reconciliation.current, report.modelId);
|
|
4783
|
-
if (stored?.kind !== "chat"
|
|
5466
|
+
if (stored?.kind !== "chat")
|
|
5467
|
+
return;
|
|
5468
|
+
if (stored.contextWindowAssumed !== true && stored.contextWindow >= verified)
|
|
4784
5469
|
return;
|
|
4785
5470
|
const updated = replaceModelCapability(reconciliation.current, report.modelId, { contextWindow: verified }, report.checkedAt);
|
|
4786
5471
|
if (updated === undefined)
|
|
4787
5472
|
return;
|
|
4788
5473
|
persistVerifiedCapabilityUpdate(reconciliation.gatewayConfig, deps, report.modelId, reconciliation.gatewayConfig.generation(), updated, false, correlationId);
|
|
4789
5474
|
}
|
|
5475
|
+
// A window the operator declared is the operator's cap: the provider may lower it (the deployment
|
|
5476
|
+
// cannot take more than it says) but never raise it. An assumed window and one a provider already
|
|
5477
|
+
// reported are learned values and follow the provider in either direction.
|
|
5478
|
+
function providerStatementLeavesWindow(stored, tokens) {
|
|
5479
|
+
if (stored.contextWindowAssumed === true)
|
|
5480
|
+
return false;
|
|
5481
|
+
if (stored.contextWindow === tokens)
|
|
5482
|
+
return true;
|
|
5483
|
+
return stored.contextWindowReported !== true && tokens > stored.contextWindow;
|
|
5484
|
+
}
|
|
5485
|
+
/**
|
|
5486
|
+
* Adopts the total context window a provider stated itself — in its overflow answer or in answer to
|
|
5487
|
+
* the startup context-window probe. Unlike the long-context probe's lower bound this is the
|
|
5488
|
+
* deployment's exact limit, so it ends an assumed window and replaces a learned one in either
|
|
5489
|
+
* direction; a declared window is only ever lowered. It is applied as a refinement: the
|
|
5490
|
+
* configuration generation stays, so a turn already admitted (the one whose overflow reported the
|
|
5491
|
+
* window) can re-plan and retry, while every later lookup plans the model with the real window. The
|
|
5492
|
+
* refinement is applied before the durable write, so an unwritable configuration file never keeps
|
|
5493
|
+
* the window unlearned: the write failure is reported as a diagnostic and the window applies in
|
|
5494
|
+
* memory until the next restart.
|
|
5495
|
+
*/
|
|
5496
|
+
export function persistAdoptedContextWindow(deps, modelId, contextWindowTokens, correlationId) {
|
|
5497
|
+
const reconciliation = currentToolCallingReconciliation(deps, undefined);
|
|
5498
|
+
if (reconciliation === undefined)
|
|
5499
|
+
return { state: "unconfigured" };
|
|
5500
|
+
const stored = findConfiguredCapability(reconciliation.current, modelId);
|
|
5501
|
+
if (stored?.kind !== "chat")
|
|
5502
|
+
return { state: "not-chat" };
|
|
5503
|
+
if (providerStatementLeavesWindow(stored, contextWindowTokens))
|
|
5504
|
+
return { state: "unchanged" };
|
|
5505
|
+
const updated = replaceCapabilityContextWindow(reconciliation.current, stored, contextWindowTokens);
|
|
5506
|
+
applyContextWindowRefinement(reconciliation.gatewayConfig, deps, modelId, updated, correlationId);
|
|
5507
|
+
return {
|
|
5508
|
+
state: "adopted",
|
|
5509
|
+
previousContextWindow: stored.contextWindow,
|
|
5510
|
+
wasAssumed: stored.contextWindowAssumed === true,
|
|
5511
|
+
};
|
|
5512
|
+
}
|
|
5513
|
+
function applyContextWindowRefinement(gatewayConfig, deps, modelId, updated, correlationId) {
|
|
5514
|
+
try {
|
|
5515
|
+
if (gatewayConfig.refine === undefined) {
|
|
5516
|
+
// Applies in memory even when the durable write fails, then rethrows the write failure.
|
|
5517
|
+
persistVerifiedCapabilityUpdate(gatewayConfig, deps, modelId, gatewayConfig.generation(), updated, false, correlationId);
|
|
5518
|
+
return;
|
|
5519
|
+
}
|
|
5520
|
+
gatewayConfig.refine(updated, correlationId);
|
|
5521
|
+
const raw = rawConfigForVerifiedCapabilityUpdate(updated, gatewayConfig.storagePath, deps);
|
|
5522
|
+
persistGatewayConfig(raw, gatewayConfig.storagePath, deps, correlationId);
|
|
5523
|
+
}
|
|
5524
|
+
catch (error) {
|
|
5525
|
+
emitServerDiagnostic(deps.diagnostics, serverDiagnosticFromError({
|
|
5526
|
+
correlationId,
|
|
5527
|
+
operation: "gateway.context-window",
|
|
5528
|
+
source: "gateway-setup.adopted-context-window",
|
|
5529
|
+
error,
|
|
5530
|
+
summary: "The verified gateway context window could not be persisted.",
|
|
5531
|
+
redact: (message) => String(deps.redactor(message)),
|
|
5532
|
+
}));
|
|
5533
|
+
}
|
|
5534
|
+
}
|
|
5535
|
+
// A declared window the provider lowered stays declared: the lowered value is the operator's cap
|
|
5536
|
+
// from now on, so a later statement can lower it further but never raise it past the ceiling the
|
|
5537
|
+
// operator set — not in this process and not after a restart (PR #3678 review, P1). Only an assumed
|
|
5538
|
+
// or already learned window becomes a reported one that follows the provider either way.
|
|
5539
|
+
function replaceCapabilityContextWindow(config, stored, contextWindow) {
|
|
5540
|
+
const declared = stored.contextWindowAssumed !== true && stored.contextWindowReported !== true;
|
|
5541
|
+
const replacement = {
|
|
5542
|
+
...withoutAssumedContextWindow(stored),
|
|
5543
|
+
contextWindow,
|
|
5544
|
+
...(declared ? {} : { contextWindowReported: true }),
|
|
5545
|
+
};
|
|
5546
|
+
const capabilities = [...(config.capabilities ?? [])];
|
|
5547
|
+
const index = capabilities.findIndex((capability) => capability.id === stored.id);
|
|
5548
|
+
if (index === -1)
|
|
5549
|
+
capabilities.push(replacement);
|
|
5550
|
+
else
|
|
5551
|
+
capabilities[index] = replacement;
|
|
5552
|
+
return { ...config, capabilities };
|
|
5553
|
+
}
|
|
4790
5554
|
function currentToolCallingReconciliation(deps, observedGeneration) {
|
|
4791
5555
|
const gatewayConfig = deps.gatewayConfig;
|
|
4792
5556
|
const current = gatewayConfig?.current();
|
|
@@ -4870,6 +5634,7 @@ function modelTokenCounterMetadata(options, modelId) {
|
|
|
4870
5634
|
function logDiscoveryMerge(merged, correlationId) {
|
|
4871
5635
|
logAliasIntersection({
|
|
4872
5636
|
alias: merged.id,
|
|
5637
|
+
role: discoveryRoleOf(merged),
|
|
4873
5638
|
contextWindow: merged.metadata.contextWindow ?? 0,
|
|
4874
5639
|
undeclaredLimit: merged.undeclaredContext === true,
|
|
4875
5640
|
deploymentCount: merged.deploymentCount ?? 1,
|
|
@@ -4879,6 +5644,11 @@ function logDiscoveryMerge(merged, correlationId) {
|
|
|
4879
5644
|
reasoningOptionCount: merged.metadata.reasoningEfforts?.length ?? 0,
|
|
4880
5645
|
}, correlationId);
|
|
4881
5646
|
}
|
|
5647
|
+
// The rerank engines travel as `unsupported` entries with the reason "rerank" until setup admits one,
|
|
5648
|
+
// but their role is "rerank": that is what an operator reading the log needs to see.
|
|
5649
|
+
function discoveryRoleOf(merged) {
|
|
5650
|
+
return merged.kind === "unsupported" && merged.reason === "rerank" ? "rerank" : merged.kind;
|
|
5651
|
+
}
|
|
4882
5652
|
function discoveryMergeState(merged) {
|
|
4883
5653
|
if (merged.deploymentConflict === true)
|
|
4884
5654
|
return "conflicting";
|