@mcp-use/inspector 0.24.2 → 0.24.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cdn/inspector.js +1649 -1649
- package/dist/client/components/ui/SandboxedIframe.d.ts.map +1 -1
- package/dist/client/index.js +34 -32
- package/dist/web/assets/{1c-BvhFLIxH.js → 1c-DWQP1mub.js} +1 -1
- package/dist/web/assets/{abnf-CX8OJqYN.js → abnf-B4m9DfW6.js} +1 -1
- package/dist/web/assets/{accesslog-DcgKZXrS.js → accesslog-hR0kFBAG.js} +1 -1
- package/dist/web/assets/{actionscript-CItnilsG.js → actionscript-Cp7uPlm2.js} +1 -1
- package/dist/web/assets/{ada-jhrFP_kG.js → ada-CR0g3XbW.js} +1 -1
- package/dist/web/assets/{angelscript-VAnEYDkE.js → angelscript-D_C_ttkM.js} +1 -1
- package/dist/web/assets/{apache-Bvpn5SVi.js → apache-BKAIxKqg.js} +1 -1
- package/dist/web/assets/{applescript-CJW-xKGY.js → applescript-BD1URYdA.js} +1 -1
- package/dist/web/assets/{arcade-DOpc8o0T.js → arcade-6QKc3A3K.js} +1 -1
- package/dist/web/assets/{arduino-gi6qvS9d.js → arduino-C5un47Hz.js} +1 -1
- package/dist/web/assets/{armasm-q6MkkUkb.js → armasm-BvMb3akz.js} +1 -1
- package/dist/web/assets/{asciidoc-dqeP70O7.js → asciidoc-BDpPy-YS.js} +1 -1
- package/dist/web/assets/{aspectj-pTI1lMoV.js → aspectj-C7CzdgE6.js} +1 -1
- package/dist/web/assets/{autohotkey-56nVTWRr.js → autohotkey-D7vg-g40.js} +1 -1
- package/dist/web/assets/{autoit-CeD--Ts3.js → autoit-CKAMTJPh.js} +1 -1
- package/dist/web/assets/{avrasm-AXSUKL73.js → avrasm-BRpxMiYU.js} +1 -1
- package/dist/web/assets/{awk-rtNNAadV.js → awk-040OBrGk.js} +1 -1
- package/dist/web/assets/{axapta-5CT0vHQJ.js → axapta-De6eA0hN.js} +1 -1
- package/dist/web/assets/{bash-BQ-JKmsJ.js → bash-BCfguAb3.js} +1 -1
- package/dist/web/assets/{basic-BeuEF9yi.js → basic-mvsNiNyT.js} +1 -1
- package/dist/web/assets/{bnf-CBLE-WBe.js → bnf-BOa_p0TC.js} +1 -1
- package/dist/web/assets/{brainfuck-D2gmEg74.js → brainfuck-DOWex2Q6.js} +1 -1
- package/dist/web/assets/{c-B8cZ_Jcv.js → c-BlnRkrx9.js} +1 -1
- package/dist/web/assets/{c-like-BUQset2J.js → c-like-Bb-uR29b.js} +1 -1
- package/dist/web/assets/{cal-BfmxNhZ4.js → cal-utigBNMh.js} +1 -1
- package/dist/web/assets/{capnproto-ci7Oy_3w.js → capnproto-Dlo2AOh-.js} +1 -1
- package/dist/web/assets/{ceylon-CR7mkBjT.js → ceylon-6bOUIIzW.js} +1 -1
- package/dist/web/assets/{clean-DDX6TchJ.js → clean-B_BLnZ47.js} +1 -1
- package/dist/web/assets/{client-S57RS52Z-D8i-S3XX.js → client-AB7PHV6E-8__RED_q.js} +4 -4
- package/dist/web/assets/{clojure-BI_RGTAe.js → clojure-CpRuXaIY.js} +1 -1
- package/dist/web/assets/{clojure-repl-DSE_x4C2.js → clojure-repl-DfhlcYzS.js} +1 -1
- package/dist/web/assets/{cmake-DO4jOBdV.js → cmake-Di3Tdm-b.js} +1 -1
- package/dist/web/assets/{coffeescript-Dd0Lp6GU.js → coffeescript-1A5CLhg9.js} +1 -1
- package/dist/web/assets/{coq-BVtIgdCz.js → coq-COY-wJJb.js} +1 -1
- package/dist/web/assets/{core-DLviWPP3.js → core-spBc5hpn.js} +1 -1
- package/dist/web/assets/{cos-BSiT-IT0.js → cos-DGYwvIaD.js} +1 -1
- package/dist/web/assets/{cpp-DQ17j1lu.js → cpp-CJzjHzKr.js} +1 -1
- package/dist/web/assets/{crmsh-BG-_i7Az.js → crmsh-D2Ny6Rg1.js} +1 -1
- package/dist/web/assets/{crystal-CwybcU_c.js → crystal-KwE8xYAd.js} +1 -1
- package/dist/web/assets/{csharp-C5EW5MWq.js → csharp-8dHfl8hC.js} +1 -1
- package/dist/web/assets/{csp-B4avFpGl.js → csp-CorDAKtZ.js} +1 -1
- package/dist/web/assets/{css-XwnDlpLG.js → css-kY1UfsP6.js} +1 -1
- package/dist/web/assets/{d-BVPgG_Aw.js → d-DLzik6S1.js} +1 -1
- package/dist/web/assets/{dart-CuzkdMfW.js → dart-DsClekPq.js} +1 -1
- package/dist/web/assets/{delphi-CUWyVIpe.js → delphi-cbm44tTh.js} +1 -1
- package/dist/web/assets/{diff-D3sSlrXe.js → diff-DXsxp2ij.js} +1 -1
- package/dist/web/assets/{display-A5IEINAP-GZCoUyvv.js → display-A5IEINAP-BUlGvd6Q.js} +2 -2
- package/dist/web/assets/{django-D17_zMlX.js → django-CyiFgRFK.js} +1 -1
- package/dist/web/assets/{dns-C1XxIveT.js → dns-DqVVp3Mw.js} +1 -1
- package/dist/web/assets/{dockerfile-CaGNlKQa.js → dockerfile-C3_NP38E.js} +1 -1
- package/dist/web/assets/{dos-CGH0X7Qf.js → dos-DNA6kcVG.js} +1 -1
- package/dist/web/assets/{dsconfig-DTVqhcqx.js → dsconfig-Cm5gOfMQ.js} +1 -1
- package/dist/web/assets/{dts-BQco_sjz.js → dts-Dxzj1Gl8.js} +1 -1
- package/dist/web/assets/{dust-BqGWXklz.js → dust-Db4IOXjd.js} +1 -1
- package/dist/web/assets/{ebnf-BqCwsW4k.js → ebnf-BbHZFiLn.js} +1 -1
- package/dist/web/assets/{elixir-WtC_BfcU.js → elixir-DqC_iHl6.js} +1 -1
- package/dist/web/assets/{elm-D7xIR2_2.js → elm-BqmcB6ra.js} +1 -1
- package/dist/web/assets/{embeddings-DD3kbxNt.js → embeddings-VSFMeWkW.js} +1 -1
- package/dist/web/assets/{erb-DjXRvkR1.js → erb-BQlRwOBV.js} +1 -1
- package/dist/web/assets/{erlang-3Dswo9Kb.js → erlang-BE_UGfR8.js} +1 -1
- package/dist/web/assets/{erlang-repl-DSxDJl2O.js → erlang-repl-Cz4fhEkS.js} +1 -1
- package/dist/web/assets/{excel-BomM7FtM.js → excel-BE4UVJCI.js} +1 -1
- package/dist/web/assets/{fix-Dk-kBHCz.js → fix-BFJZi0ZF.js} +1 -1
- package/dist/web/assets/{flix-AdO4r9fm.js → flix-CyeQFyrI.js} +1 -1
- package/dist/web/assets/{fortran-BiFgPRXr.js → fortran-BCOvhjJM.js} +1 -1
- package/dist/web/assets/{fsharp-CrGX07bo.js → fsharp-DR6jYTGn.js} +1 -1
- package/dist/web/assets/{gams-t-W8hkrr.js → gams-CGAR2g-Z.js} +1 -1
- package/dist/web/assets/{gauss-aVHF9YQ0.js → gauss-k3dDkPe5.js} +1 -1
- package/dist/web/assets/{gcode-Dirh21Jx.js → gcode-B6-frFb0.js} +1 -1
- package/dist/web/assets/{gherkin-Doinw4Bw.js → gherkin-BUuDsS9n.js} +1 -1
- package/dist/web/assets/{glsl-BVAd7fQZ.js → glsl-BYhoCZKT.js} +1 -1
- package/dist/web/assets/{gml-D3k6P4wF.js → gml-DYkKS3qA.js} +1 -1
- package/dist/web/assets/{go-RoXLUpPR.js → go-74QphXEb.js} +1 -1
- package/dist/web/assets/{golo-BC3q2vpX.js → golo-DBWqrZGX.js} +1 -1
- package/dist/web/assets/{gradle-DVbLpAp9.js → gradle-C7daK8_y.js} +1 -1
- package/dist/web/assets/{groovy-BlpSZ8yL.js → groovy-Bi5ue30i.js} +1 -1
- package/dist/web/assets/{haml-CzCcmI1O.js → haml-BXi-JezI.js} +1 -1
- package/dist/web/assets/{handlebars-Bw-pBlQu.js → handlebars-LAlnt_hk.js} +1 -1
- package/dist/web/assets/{haskell-DhIYpyey.js → haskell-D4WJNqrQ.js} +1 -1
- package/dist/web/assets/{haxe-CYh7KB7k.js → haxe-mWf61HUO.js} +1 -1
- package/dist/web/assets/{hsp-r1aLXMhs.js → hsp-Dojie6Gw.js} +1 -1
- package/dist/web/assets/{htmlbars-HUpfURpP.js → htmlbars-jJ14_7NK.js} +1 -1
- package/dist/web/assets/{http-BGFs537-.js → http-Cc4lCqW4.js} +1 -1
- package/dist/web/assets/{hy-Dhjbxgrk.js → hy-8KcZEbbZ.js} +1 -1
- package/dist/web/assets/{index-DhbVcA9F.js → index-BGGQsG8S.js} +1 -1
- package/dist/web/assets/{index-BaQ4JmMg.js → index-CCwFSwLA.js} +1 -1
- package/dist/web/assets/{index-i9rlZ7RP.js → index-CYJeDEI4.js} +1 -1
- package/dist/web/assets/{index-BniVLnRq.js → index-DJq3Cwo_.js} +1 -1
- package/dist/web/assets/{index-DdfO8wbV.js → index-OJkqFRtn.js} +1 -1
- package/dist/web/assets/{index-BQDf_2QT.js → index-PReApu5D.js} +9 -9
- package/dist/web/assets/{index-D6ksAhcX.js → index-zSJ0teU7.js} +1 -1
- package/dist/web/assets/{inform7-B5avNAGg.js → inform7-BVVLwY0Y.js} +1 -1
- package/dist/web/assets/{ini-5Yf7OApE.js → ini-DxVdMXTA.js} +1 -1
- package/dist/web/assets/{irpf90-9P8GaAT8.js → irpf90-CK5Ve43F.js} +1 -1
- package/dist/web/assets/{isbl-DBvY8d_e.js → isbl-CWdaifmf.js} +1 -1
- package/dist/web/assets/{java-BYAicyox.js → java-Deynp6dV.js} +1 -1
- package/dist/web/assets/{javascript-BsZ6ruUt.js → javascript-D-1JqFUr.js} +1 -1
- package/dist/web/assets/{jboss-cli-BEvNpqj4.js → jboss-cli-B9zhbwC0.js} +1 -1
- package/dist/web/assets/{json-YkjXrxXX.js → json-YMxXFyeh.js} +1 -1
- package/dist/web/assets/{julia-CIaQJLVA.js → julia-DWnUVcmD.js} +1 -1
- package/dist/web/assets/{julia-repl-neu8z3rS.js → julia-repl-DSX4rcLC.js} +1 -1
- package/dist/web/assets/{kotlin-B_3Gv_Wa.js → kotlin-BLBQXIGX.js} +1 -1
- package/dist/web/assets/{langfuse-U2OEF7K7-BS7yds-5.js → langfuse-U2OEF7K7-dQHZ0LiE.js} +3 -3
- package/dist/web/assets/{lasso-BcxCyLbb.js → lasso-CtlT6rls.js} +1 -1
- package/dist/web/assets/{latex-DBLSyLoB.js → latex-Cg4YnNMk.js} +1 -1
- package/dist/web/assets/{ldif-zLAu6Yaq.js → ldif-CzNJ0sb4.js} +1 -1
- package/dist/web/assets/{leaf-C8g3QwRa.js → leaf-_Bypq4lt.js} +1 -1
- package/dist/web/assets/{less-BiZdkKrA.js → less-BRX4OsEl.js} +1 -1
- package/dist/web/assets/{lisp-SZa_n4Ha.js → lisp-C_Q8MZOv.js} +1 -1
- package/dist/web/assets/{livecodeserver-DbqsVDXq.js → livecodeserver-B7R1o_x9.js} +1 -1
- package/dist/web/assets/{livescript-CKn9aHzH.js → livescript-By3nKPsA.js} +1 -1
- package/dist/web/assets/{llms-iELWWhGP.js → llms-Dji6qLbK.js} +1 -1
- package/dist/web/assets/{llvm-B2i8wLJj.js → llvm-D-UB_VdD.js} +1 -1
- package/dist/web/assets/{lsl-Cm2mEXVA.js → lsl-BhRYOBfc.js} +1 -1
- package/dist/web/assets/{lua-BEDlAaf-.js → lua-C4n77O33.js} +1 -1
- package/dist/web/assets/{makefile-CjFs_qe4.js → makefile-BNclwAhc.js} +1 -1
- package/dist/web/assets/{markdown-isjfrR4I.js → markdown-B_lHon9I.js} +1 -1
- package/dist/web/assets/{mathematica-_UeFOFBA.js → mathematica-BVYsM_A5.js} +1 -1
- package/dist/web/assets/{matlab-Bn6pdsuY.js → matlab-cYcEv3Wk.js} +1 -1
- package/dist/web/assets/{maxima-CzA538N9.js → maxima-DzwwwHqp.js} +1 -1
- package/dist/web/assets/{mel-BkIKTvwA.js → mel-D3qm56Y8.js} +1 -1
- package/dist/web/assets/{mercury-BW46IsU1.js → mercury-CFun94mM.js} +1 -1
- package/dist/web/assets/{mipsasm-xk8xikSW.js → mipsasm-3suvCdfN.js} +1 -1
- package/dist/web/assets/{mizar-CydR6mll.js → mizar-Bmm4Raqy.js} +1 -1
- package/dist/web/assets/{mojolicious-DPEf75yc.js → mojolicious-DRfaKPr8.js} +1 -1
- package/dist/web/assets/{monkey-C3GGTuc2.js → monkey-CdKa5phJ.js} +1 -1
- package/dist/web/assets/{moonscript-BWCm7GA4.js → moonscript-DjTY6jVw.js} +1 -1
- package/dist/web/assets/{n1ql-KUcEBJ5e.js → n1ql-D7N67xB1.js} +1 -1
- package/dist/web/assets/{nginx-B5n_99-T.js → nginx-0H1btrKU.js} +1 -1
- package/dist/web/assets/{nim-Cj2kL1F7.js → nim-D8xmWLX8.js} +1 -1
- package/dist/web/assets/{nix-DU3svOEi.js → nix-DhxXkFWS.js} +1 -1
- package/dist/web/assets/{node-repl-CVjFZCg8.js → node-repl-4fQyEV1h.js} +1 -1
- package/dist/web/assets/{nsis-ec6JIFaq.js → nsis-Bym7lcyY.js} +1 -1
- package/dist/web/assets/{objectivec-35jFh8_n.js → objectivec-Bae6P5vI.js} +1 -1
- package/dist/web/assets/{ocaml-DSvpPQQA.js → ocaml-BXQl_rW-.js} +1 -1
- package/dist/web/assets/{openscad-BtR0N549.js → openscad-Crs0A6z8.js} +1 -1
- package/dist/web/assets/{oxygene-DHhgzdSe.js → oxygene-GrMP1tSV.js} +1 -1
- package/dist/web/assets/{parser3-DBNAvQ81.js → parser3-DAaJCr4F.js} +1 -1
- package/dist/web/assets/{perl-aQ2z2IY0.js → perl-Bdu82Ke9.js} +1 -1
- package/dist/web/assets/{pf-NcRyIsiR.js → pf-BWAdT5hr.js} +1 -1
- package/dist/web/assets/{pgsql-C6IelojA.js → pgsql-BiAI36Tl.js} +1 -1
- package/dist/web/assets/{php-DXFb1z3E.js → php-DJJs2Qa7.js} +1 -1
- package/dist/web/assets/{php-template-noIzpFwi.js → php-template-5NUSFJjr.js} +1 -1
- package/dist/web/assets/{plaintext-CuMZI4wJ.js → plaintext-Cdy1uQ2h.js} +1 -1
- package/dist/web/assets/{pony-DKNUP03S.js → pony-BCtjd2SF.js} +1 -1
- package/dist/web/assets/{powershell-DK5QFD1P.js → powershell-D1lq3PTM.js} +1 -1
- package/dist/web/assets/{processing-Bd0YwPX-.js → processing-DaYRWplr.js} +1 -1
- package/dist/web/assets/{profile-BUJvtaZj.js → profile-DvQtt2O9.js} +1 -1
- package/dist/web/assets/{prolog-C8MmbuJy.js → prolog-DEkCKvGB.js} +1 -1
- package/dist/web/assets/{properties-BQiZSAsl.js → properties-B3LbXDXT.js} +1 -1
- package/dist/web/assets/{protobuf-BIM_UAt8.js → protobuf-C5rCr5vP.js} +1 -1
- package/dist/web/assets/{puppet-BuXb1lDA.js → puppet-CvxuSTBF.js} +1 -1
- package/dist/web/assets/{purebasic-BI2OGD7g.js → purebasic-DRKNl9vw.js} +1 -1
- package/dist/web/assets/{python-MrZFTqbt.js → python-BGj4l9-1.js} +1 -1
- package/dist/web/assets/{python-repl-BgSuB0OR.js → python-repl-a_mGDUz9.js} +1 -1
- package/dist/web/assets/{q-CHprrWyV.js → q-DYR5XrsH.js} +1 -1
- package/dist/web/assets/{qml-BnHfbLpq.js → qml-BYrig_lw.js} +1 -1
- package/dist/web/assets/{r-BaO6b_Bk.js → r-Cvry9LOJ.js} +1 -1
- package/dist/web/assets/{reasonml-DSmR8Ung.js → reasonml-DbRKnt_5.js} +1 -1
- package/dist/web/assets/{rib-Dm3ubKSd.js → rib-CEt4BFqx.js} +1 -1
- package/dist/web/assets/{roboconf-BLDc3VXQ.js → roboconf-H_d48ndW.js} +1 -1
- package/dist/web/assets/{routeros-BE3GmAwJ.js → routeros-Bc6nYTKY.js} +1 -1
- package/dist/web/assets/{rsl-BJNhDId6.js → rsl-COgBxi_Y.js} +1 -1
- package/dist/web/assets/{ruby-CQ10tkxO.js → ruby-B7Vd9nzp.js} +1 -1
- package/dist/web/assets/{ruleslanguage-DFnSuCn9.js → ruleslanguage-B_5WDFET.js} +1 -1
- package/dist/web/assets/{rust-wEY88oU7.js → rust-D4tCHsbQ.js} +1 -1
- package/dist/web/assets/{sas-gbrzG7lJ.js → sas-CY57IJZC.js} +1 -1
- package/dist/web/assets/{scala-CumsYZ1V.js → scala-C9Pbgj8I.js} +1 -1
- package/dist/web/assets/{scheme-DO8wf0St.js → scheme-BFBa25WW.js} +1 -1
- package/dist/web/assets/{scilab-BeQqjCZH.js → scilab-DK-pGu_5.js} +1 -1
- package/dist/web/assets/{scss-Bndud_G4.js → scss-BIOnER2K.js} +1 -1
- package/dist/web/assets/{shell-Ui33dEFX.js → shell-DQE7INyJ.js} +1 -1
- package/dist/web/assets/{smali-MAEUsdX_.js → smali-DpSW5EXH.js} +1 -1
- package/dist/web/assets/{smalltalk-hIj_nQ9T.js → smalltalk-CrDxUPM9.js} +1 -1
- package/dist/web/assets/{sml-CDrYQEBb.js → sml-B2aS7St-.js} +1 -1
- package/dist/web/assets/{sqf-BfLxcAGD.js → sqf-B78BRwov.js} +1 -1
- package/dist/web/assets/{sql-DANvBdmv.js → sql-Eqyy9FEh.js} +1 -1
- package/dist/web/assets/{sql_more-C0QRwHnL.js → sql_more-dSCbUr-A.js} +1 -1
- package/dist/web/assets/{stan-Cj8NJPGd.js → stan-PfHp2ZCj.js} +1 -1
- package/dist/web/assets/{stata-DHZ8Glmp.js → stata-CvOAKACJ.js} +1 -1
- package/dist/web/assets/{stdio-XAHYUHLM-Ci3DPFXU.js → stdio-J7J2D5YS-BCl13o02.js} +1 -1
- package/dist/web/assets/{step21-DYbMWMLq.js → step21-BF8so2_c.js} +1 -1
- package/dist/web/assets/{stylus-HTTDZjuT.js → stylus-CILAC3i4.js} +1 -1
- package/dist/web/assets/{subunit-VIqybOs4.js → subunit-BHyXupFz.js} +1 -1
- package/dist/web/assets/{swift-BR9ynvuv.js → swift-CDCOX3ON.js} +1 -1
- package/dist/web/assets/{taggerscript-BBIZMwyL.js → taggerscript-BldoyP1w.js} +1 -1
- package/dist/web/assets/{tap-DgYlHFwQ.js → tap-CF6UNBEG.js} +1 -1
- package/dist/web/assets/{tcl-BOVb5he3.js → tcl-nSy7CV5q.js} +1 -1
- package/dist/web/assets/{thrift-DnYrJP2I.js → thrift-D6SUf4ef.js} +1 -1
- package/dist/web/assets/{tp-CKMrYpFB.js → tp-B38xDURl.js} +1 -1
- package/dist/web/assets/{twig-C8yRQ_si.js → twig-O_UP3VrO.js} +1 -1
- package/dist/web/assets/{typescript-Bp8GRFbQ.js → typescript-BuJSAUtK.js} +1 -1
- package/dist/web/assets/{vala-Bv7tX-YP.js → vala-D9z2K-QI.js} +1 -1
- package/dist/web/assets/{vbnet-B-xyxnsY.js → vbnet-zONfI18P.js} +1 -1
- package/dist/web/assets/{vbscript-DCSS0QgU.js → vbscript-D6POmMCx.js} +1 -1
- package/dist/web/assets/{vbscript-html-DkK5mhXa.js → vbscript-html-Bxmac_EM.js} +1 -1
- package/dist/web/assets/{verilog-CaWRJI65.js → verilog-C6exP91c.js} +1 -1
- package/dist/web/assets/{vhdl-UJHisrmd.js → vhdl-CrisA7BU.js} +1 -1
- package/dist/web/assets/{vim-CTdBAd8A.js → vim-BpYmjRBH.js} +1 -1
- package/dist/web/assets/{x86asm-DipJ34Qb.js → x86asm-DS7pwGxH.js} +1 -1
- package/dist/web/assets/{xl-DfcCv_5D.js → xl-DgBcEonr.js} +1 -1
- package/dist/web/assets/{xml-Ds8sXZ7Q.js → xml-CDTtZ_A7.js} +1 -1
- package/dist/web/assets/{xquery-BofP9fWJ.js → xquery-0jSyorGq.js} +1 -1
- package/dist/web/assets/{yaml-CsOQPuOU.js → yaml-wH3dgKUW.js} +1 -1
- package/dist/web/assets/{zephir-CU7UAhpm.js → zephir-BiKgn5d9.js} +1 -1
- package/dist/web/index.html +2 -2
- package/package.json +2 -2
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{X as Zs,be as Za,bf as x,bg as Ja,ad as Ha,ac as Va,Q as Me,bh as Xa,a1 as R,b as et,aw as Ga,aJ as Ya,a2 as Qa,Z as Js,$ as Hs,U as Ce,l as bt,bi as ei,W as vn,bj as rs,bk as ti,bl as ni,bm as si,a0 as as,bn as is,bo as ri,y as ai,V as sn,G as ii,b2 as Z,b8 as xn,ba as te,bc as Vs,bb as W,b3 as Mt,b9 as Q,bp as oi,p as ui,A as li,a as ci}from"./index-
|
|
1
|
+
import{X as Zs,be as Za,bf as x,bg as Ja,ad as Ha,ac as Va,Q as Me,bh as Xa,a1 as R,b as et,aw as Ga,aJ as Ya,a2 as Qa,Z as Js,$ as Hs,U as Ce,l as bt,bi as ei,W as vn,bj as rs,bk as ti,bl as ni,bm as si,a0 as as,bn as is,bo as ri,y as ai,V as sn,G as ii,b2 as Z,b8 as xn,ba as te,bc as Vs,bb as W,b3 as Mt,b9 as Q,bp as oi,p as ui,A as li,a as ci}from"./index-PReApu5D.js";import{c as pi,j as di,h as hi,f as Xs,S as os,J as us,R as ls,k as fi}from"./index-BGGQsG8S.js";import{J as cs,c as mi,p as Gs,m as lt,B as gi}from"./llms-Dji6qLbK.js";import{c as rn,E as _i}from"./embeddings-VSFMeWkW.js";import{T as yi,t as zt,D as wi}from"./index-CCwFSwLA.js";function tt(e,t){return e.lc_error_code=t,e.message=`${e.message}
|
|
2
2
|
|
|
3
3
|
Troubleshooting URL: https://docs.langchain.com/oss/javascript/langchain/errors/${t}/
|
|
4
4
|
`,e}function O(e,t,n,s,r){if(typeof t=="function"?e!==t||!0:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return t.set(e,n),n}function p(e,t,n,s){if(n==="a"&&!s)throw new TypeError("Private accessor was defined without a getter");if(typeof t=="function"?e!==t||!s:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return n==="m"?s:n==="a"?s.call(e):s?s.value:t.get(e)}let Ys=function(){const{crypto:e}=globalThis;if(e?.randomUUID)return Ys=e.randomUUID.bind(e),e.randomUUID();const t=new Uint8Array(1),n=e?()=>e.getRandomValues(t)[0]:()=>Math.random()*255&255;return"10000000-1000-4000-8000-100000000000".replace(/[018]/g,s=>(+s^n()&15>>+s/4).toString(16))};function an(e){return typeof e=="object"&&e!==null&&("name"in e&&e.name==="AbortError"||"message"in e&&String(e.message).includes("FetchRequestCanceledException"))}const on=e=>{if(e instanceof Error)return e;if(typeof e=="object"&&e!==null){try{if(Object.prototype.toString.call(e)==="[object Error]"){const t=new Error(e.message,e.cause?{cause:e.cause}:{});return e.stack&&(t.stack=e.stack),e.cause&&!t.cause&&(t.cause=e.cause),e.name&&(t.name=e.name),t}}catch{}try{return new Error(JSON.stringify(e))}catch{}}return new Error(e)};class A extends Error{}class q extends A{constructor(t,n,s,r){super(`${q.makeMessage(t,n,s)}`),this.status=t,this.headers=r,this.requestID=r?.get("x-request-id"),this.error=n;const a=n;this.code=a?.code,this.param=a?.param,this.type=a?.type}static makeMessage(t,n,s){const r=n?.message?typeof n.message=="string"?n.message:JSON.stringify(n.message):n?JSON.stringify(n):s;return t&&r?`${t} ${r}`:t?`${t} status code (no body)`:r||"(no status code or body)"}static generate(t,n,s,r){if(!t||!r)return new Ut({message:s,cause:on(n)});const a=n?.error;return t===400?new Qs(t,a,s,r):t===401?new er(t,a,s,r):t===403?new tr(t,a,s,r):t===404?new nr(t,a,s,r):t===409?new sr(t,a,s,r):t===422?new rr(t,a,s,r):t===429?new ar(t,a,s,r):t>=500?new ir(t,a,s,r):new q(t,a,s,r)}}class ee extends q{constructor({message:t}={}){super(void 0,void 0,t||"Request was aborted.",void 0)}}class Ut extends q{constructor({message:t,cause:n}){super(void 0,void 0,t||"Connection error.",void 0),n&&(this.cause=n)}}class Lt extends Ut{constructor({message:t}={}){super({message:t??"Request timed out."})}}class Qs extends q{}class er extends q{}class tr extends q{}class nr extends q{}class sr extends q{}class rr extends q{}class ar extends q{}class ir extends q{}class or extends A{constructor(){super("Could not parse response content as the length limit was reached")}}class ur extends A{constructor(){super("Could not parse response content as the request was rejected by the content filter")}}class ze extends Error{constructor(t){super(t)}}const bi=/^[a-z][a-z0-9+.-]*:/i,Ai=e=>bi.test(e);let V=e=>(V=Array.isArray,V(e)),ps=V;function lr(e){return typeof e!="object"?{}:e??{}}function Ii(e){if(!e)return!0;for(const t in e)return!1;return!0}function Oi(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function ct(e){return e!=null&&typeof e=="object"&&!Array.isArray(e)}const vi=(e,t)=>{if(typeof t!="number"||!Number.isInteger(t))throw new A(`${e} must be an integer`);if(t<0)throw new A(`${e} must be a positive integer`);return t},xi=e=>{try{return JSON.parse(e)}catch{return}},Ve=e=>new Promise(t=>setTimeout(t,e)),ve="6.17.0",ki=()=>typeof window<"u"&&typeof window.document<"u"&&typeof navigator<"u";function Ti(){return typeof Deno<"u"&&Deno.build!=null?"deno":typeof EdgeRuntime<"u"?"edge":Object.prototype.toString.call(typeof globalThis.process<"u"?globalThis.process:0)==="[object process]"?"node":"unknown"}const Ci=()=>{const e=Ti();if(e==="deno")return{"X-Stainless-Lang":"js","X-Stainless-Package-Version":ve,"X-Stainless-OS":hs(Deno.build.os),"X-Stainless-Arch":ds(Deno.build.arch),"X-Stainless-Runtime":"deno","X-Stainless-Runtime-Version":typeof Deno.version=="string"?Deno.version:Deno.version?.deno??"unknown"};if(typeof EdgeRuntime<"u")return{"X-Stainless-Lang":"js","X-Stainless-Package-Version":ve,"X-Stainless-OS":"Unknown","X-Stainless-Arch":`other:${EdgeRuntime}`,"X-Stainless-Runtime":"edge","X-Stainless-Runtime-Version":globalThis.process.version};if(e==="node")return{"X-Stainless-Lang":"js","X-Stainless-Package-Version":ve,"X-Stainless-OS":hs(globalThis.process.platform??"unknown"),"X-Stainless-Arch":ds(globalThis.process.arch??"unknown"),"X-Stainless-Runtime":"node","X-Stainless-Runtime-Version":globalThis.process.version??"unknown"};const t=Si();return t?{"X-Stainless-Lang":"js","X-Stainless-Package-Version":ve,"X-Stainless-OS":"Unknown","X-Stainless-Arch":"unknown","X-Stainless-Runtime":`browser:${t.browser}`,"X-Stainless-Runtime-Version":t.version}:{"X-Stainless-Lang":"js","X-Stainless-Package-Version":ve,"X-Stainless-OS":"Unknown","X-Stainless-Arch":"unknown","X-Stainless-Runtime":"unknown","X-Stainless-Runtime-Version":"unknown"}};function Si(){if(typeof navigator>"u"||!navigator)return null;const e=[{key:"edge",pattern:/Edge(?:\W+(\d+)\.(\d+)(?:\.(\d+))?)?/},{key:"ie",pattern:/MSIE(?:\W+(\d+)\.(\d+)(?:\.(\d+))?)?/},{key:"ie",pattern:/Trident(?:.*rv\:(\d+)\.(\d+)(?:\.(\d+))?)?/},{key:"chrome",pattern:/Chrome(?:\W+(\d+)\.(\d+)(?:\.(\d+))?)?/},{key:"firefox",pattern:/Firefox(?:\W+(\d+)\.(\d+)(?:\.(\d+))?)?/},{key:"safari",pattern:/(?:Version\W+(\d+)\.(\d+)(?:\.(\d+))?)?(?:\W+Mobile\S*)?\W+Safari/}];for(const{key:t,pattern:n}of e){const s=n.exec(navigator.userAgent);if(s){const r=s[1]||0,a=s[2]||0,i=s[3]||0;return{browser:t,version:`${r}.${a}.${i}`}}}return null}const ds=e=>e==="x32"?"x32":e==="x86_64"||e==="x64"?"x64":e==="arm"?"arm":e==="aarch64"||e==="arm64"?"arm64":e?`other:${e}`:"unknown",hs=e=>(e=e.toLowerCase(),e.includes("ios")?"iOS":e==="android"?"Android":e==="darwin"?"MacOS":e==="win32"?"Windows":e==="freebsd"?"FreeBSD":e==="openbsd"?"OpenBSD":e==="linux"?"Linux":e?`Other:${e}`:"Unknown");let fs;const Pi=()=>fs??(fs=Ci());function Ri(){if(typeof fetch<"u")return fetch;throw new Error("`fetch` is not defined as a global; Either pass `fetch` to the client, `new OpenAI({ fetch })` or polyfill the global, `globalThis.fetch = fetch`")}function cr(...e){const t=globalThis.ReadableStream;if(typeof t>"u")throw new Error("`ReadableStream` is not defined as a global; You will need to polyfill it, `globalThis.ReadableStream = ReadableStream`");return new t(...e)}function pr(e){let t=Symbol.asyncIterator in e?e[Symbol.asyncIterator]():e[Symbol.iterator]();return cr({start(){},async pull(n){const{done:s,value:r}=await t.next();s?n.close():n.enqueue(r)},async cancel(){await t.return?.()}})}function dr(e){if(e[Symbol.asyncIterator])return e;const t=e.getReader();return{async next(){try{const n=await t.read();return n?.done&&t.releaseLock(),n}catch(n){throw t.releaseLock(),n}},async return(){const n=t.cancel();return t.releaseLock(),await n,{done:!0,value:void 0}},[Symbol.asyncIterator](){return this}}}async function Ei(e){if(e===null||typeof e!="object")return;if(e[Symbol.asyncIterator]){await e[Symbol.asyncIterator]().return?.();return}const t=e.getReader(),n=t.cancel();t.releaseLock(),await n}const $i=({headers:e,body:t})=>({bodyHeaders:{"content-type":"application/json"},body:JSON.stringify(t)}),hr="RFC3986",fr=e=>String(e),ms={RFC1738:e=>String(e).replace(/%20/g,"+"),RFC3986:fr},Ni="RFC1738";let un=(e,t)=>(un=Object.hasOwn??Function.prototype.call.bind(Object.prototype.hasOwnProperty),un(e,t));const ae=(()=>{const e=[];for(let t=0;t<256;++t)e.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return e})(),Vt=1024,Mi=(e,t,n,s,r)=>{if(e.length===0)return e;let a=e;if(typeof e=="symbol"?a=Symbol.prototype.toString.call(e):typeof e!="string"&&(a=String(e)),n==="iso-8859-1")return escape(a).replace(/%u[0-9a-f]{4}/gi,function(o){return"%26%23"+parseInt(o.slice(2),16)+"%3B"});let i="";for(let o=0;o<a.length;o+=Vt){const l=a.length>=Vt?a.slice(o,o+Vt):a,u=[];for(let m=0;m<l.length;++m){let d=l.charCodeAt(m);if(d===45||d===46||d===95||d===126||d>=48&&d<=57||d>=65&&d<=90||d>=97&&d<=122||r===Ni&&(d===40||d===41)){u[u.length]=l.charAt(m);continue}if(d<128){u[u.length]=ae[d];continue}if(d<2048){u[u.length]=ae[192|d>>6]+ae[128|d&63];continue}if(d<55296||d>=57344){u[u.length]=ae[224|d>>12]+ae[128|d>>6&63]+ae[128|d&63];continue}m+=1,d=65536+((d&1023)<<10|l.charCodeAt(m)&1023),u[u.length]=ae[240|d>>18]+ae[128|d>>12&63]+ae[128|d>>6&63]+ae[128|d&63]}i+=u.join("")}return i};function zi(e){return!e||typeof e!="object"?!1:!!(e.constructor&&e.constructor.isBuffer&&e.constructor.isBuffer(e))}function gs(e,t){if(V(e)){const n=[];for(let s=0;s<e.length;s+=1)n.push(t(e[s]));return n}return t(e)}const mr={brackets(e){return String(e)+"[]"},comma:"comma",indices(e,t){return String(e)+"["+t+"]"},repeat(e){return String(e)}},gr=function(e,t){Array.prototype.push.apply(e,V(t)?t:[t])};let _s;const U={addQueryPrefix:!1,allowDots:!1,allowEmptyArrays:!1,arrayFormat:"indices",charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encodeDotInKeys:!1,encoder:Mi,encodeValuesOnly:!1,format:hr,formatter:fr,indices:!1,serializeDate(e){return(_s??(_s=Function.prototype.call.bind(Date.prototype.toISOString)))(e)},skipNulls:!1,strictNullHandling:!1};function Ui(e){return typeof e=="string"||typeof e=="number"||typeof e=="boolean"||typeof e=="symbol"||typeof e=="bigint"}const Xt={};function _r(e,t,n,s,r,a,i,o,l,u,m,d,f,c,w,b,C,h){let g=e,k=h,S=0,J=!1;for(;(k=k.get(Xt))!==void 0&&!J;){const $=k.get(e);if(S+=1,typeof $<"u"){if($===S)throw new RangeError("Cyclic object value");J=!0}typeof k.get(Xt)>"u"&&(S=0)}if(typeof u=="function"?g=u(t,g):g instanceof Date?g=f?.(g):n==="comma"&&V(g)&&(g=gs(g,function($){return $ instanceof Date?f?.($):$})),g===null){if(a)return l&&!b?l(t,U.encoder,C,"key",c):t;g=""}if(Ui(g)||zi(g)){if(l){const $=b?t:l(t,U.encoder,C,"key",c);return[w?.($)+"="+w?.(l(g,U.encoder,C,"value",c))]}return[w?.(t)+"="+w?.(String(g))]}const L=[];if(typeof g>"u")return L;let E;if(n==="comma"&&V(g))b&&l&&(g=gs(g,l)),E=[{value:g.length>0?g.join(",")||null:void 0}];else if(V(u))E=u;else{const $=Object.keys(g);E=m?$.sort(m):$}const B=o?String(t).replace(/\./g,"%2E"):String(t),D=s&&V(g)&&g.length===1?B+"[]":B;if(r&&V(g)&&g.length===0)return D+"[]";for(let $=0;$<E.length;++$){const M=E[$],ns=typeof M=="object"&&typeof M.value<"u"?M.value:g[M];if(i&&ns===null)continue;const Ht=d&&o?M.replace(/\./g,"%2E"):M,Wa=V(g)?typeof n=="function"?n(D,Ht):D:D+(d?"."+Ht:"["+Ht+"]");h.set(e,S);const ss=new WeakMap;ss.set(Xt,h),gr(L,_r(ns,Wa,n,s,r,a,i,o,n==="comma"&&b&&V(g)?null:l,u,m,d,f,c,w,b,C,ss))}return L}function Li(e=U){if(typeof e.allowEmptyArrays<"u"&&typeof e.allowEmptyArrays!="boolean")throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");if(typeof e.encodeDotInKeys<"u"&&typeof e.encodeDotInKeys!="boolean")throw new TypeError("`encodeDotInKeys` option can only be `true` or `false`, when provided");if(e.encoder!==null&&typeof e.encoder<"u"&&typeof e.encoder!="function")throw new TypeError("Encoder has to be a function.");const t=e.charset||U.charset;if(typeof e.charset<"u"&&e.charset!=="utf-8"&&e.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");let n=hr;if(typeof e.format<"u"){if(!un(ms,e.format))throw new TypeError("Unknown format option provided.");n=e.format}const s=ms[n];let r=U.filter;(typeof e.filter=="function"||V(e.filter))&&(r=e.filter);let a;if(e.arrayFormat&&e.arrayFormat in mr?a=e.arrayFormat:"indices"in e?a=e.indices?"indices":"repeat":a=U.arrayFormat,"commaRoundTrip"in e&&typeof e.commaRoundTrip!="boolean")throw new TypeError("`commaRoundTrip` must be a boolean, or absent");const i=typeof e.allowDots>"u"?e.encodeDotInKeys?!0:U.allowDots:!!e.allowDots;return{addQueryPrefix:typeof e.addQueryPrefix=="boolean"?e.addQueryPrefix:U.addQueryPrefix,allowDots:i,allowEmptyArrays:typeof e.allowEmptyArrays=="boolean"?!!e.allowEmptyArrays:U.allowEmptyArrays,arrayFormat:a,charset:t,charsetSentinel:typeof e.charsetSentinel=="boolean"?e.charsetSentinel:U.charsetSentinel,commaRoundTrip:!!e.commaRoundTrip,delimiter:typeof e.delimiter>"u"?U.delimiter:e.delimiter,encode:typeof e.encode=="boolean"?e.encode:U.encode,encodeDotInKeys:typeof e.encodeDotInKeys=="boolean"?e.encodeDotInKeys:U.encodeDotInKeys,encoder:typeof e.encoder=="function"?e.encoder:U.encoder,encodeValuesOnly:typeof e.encodeValuesOnly=="boolean"?e.encodeValuesOnly:U.encodeValuesOnly,filter:r,format:n,formatter:s,serializeDate:typeof e.serializeDate=="function"?e.serializeDate:U.serializeDate,skipNulls:typeof e.skipNulls=="boolean"?e.skipNulls:U.skipNulls,sort:typeof e.sort=="function"?e.sort:null,strictNullHandling:typeof e.strictNullHandling=="boolean"?e.strictNullHandling:U.strictNullHandling}}function Di(e,t={}){let n=e;const s=Li(t);let r,a;typeof s.filter=="function"?(a=s.filter,n=a("",n)):V(s.filter)&&(a=s.filter,r=a);const i=[];if(typeof n!="object"||n===null)return"";const o=mr[s.arrayFormat],l=o==="comma"&&s.commaRoundTrip;r||(r=Object.keys(n)),s.sort&&r.sort(s.sort);const u=new WeakMap;for(let f=0;f<r.length;++f){const c=r[f];s.skipNulls&&n[c]===null||gr(i,_r(n[c],c,o,l,s.allowEmptyArrays,s.strictNullHandling,s.skipNulls,s.encodeDotInKeys,s.encode?s.encoder:null,s.filter,s.sort,s.allowDots,s.serializeDate,s.format,s.formatter,s.encodeValuesOnly,s.charset,u))}const m=i.join(s.delimiter);let d=s.addQueryPrefix===!0?"?":"";return s.charsetSentinel&&(s.charset==="iso-8859-1"?d+="utf8=%26%2310003%3B&":d+="utf8=%E2%9C%93&"),m.length>0?d+m:""}function ji(e){let t=0;for(const r of e)t+=r.length;const n=new Uint8Array(t);let s=0;for(const r of e)n.set(r,s),s+=r.length;return n}let ys;function kn(e){let t;return(ys??(t=new globalThis.TextEncoder,ys=t.encode.bind(t)))(e)}let ws;function bs(e){let t;return(ws??(t=new globalThis.TextDecoder,ws=t.decode.bind(t)))(e)}var X,G;class Dt{constructor(){X.set(this,void 0),G.set(this,void 0),O(this,X,new Uint8Array),O(this,G,null)}decode(t){if(t==null)return[];const n=t instanceof ArrayBuffer?new Uint8Array(t):typeof t=="string"?kn(t):t;O(this,X,ji([p(this,X,"f"),n]));const s=[];let r;for(;(r=Bi(p(this,X,"f"),p(this,G,"f")))!=null;){if(r.carriage&&p(this,G,"f")==null){O(this,G,r.index);continue}if(p(this,G,"f")!=null&&(r.index!==p(this,G,"f")+1||r.carriage)){s.push(bs(p(this,X,"f").subarray(0,p(this,G,"f")-1))),O(this,X,p(this,X,"f").subarray(p(this,G,"f"))),O(this,G,null);continue}const a=p(this,G,"f")!==null?r.preceding-1:r.preceding,i=bs(p(this,X,"f").subarray(0,a));s.push(i),O(this,X,p(this,X,"f").subarray(r.index)),O(this,G,null)}return s}flush(){return p(this,X,"f").length?this.decode(`
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as a}from"./index-
|
|
1
|
+
import{r as a}from"./index-PReApu5D.js";import{r as s}from"./inform7-CKh91FfW.js";function c(t,f){for(var o=0;o<f.length;o++){const r=f[o];if(typeof r!="string"&&!Array.isArray(r)){for(const e in r)if(e!=="default"&&!(e in t)){const n=Object.getOwnPropertyDescriptor(r,e);n&&Object.defineProperty(t,e,n.get?n:{enumerable:!0,get:()=>r[e]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var i=s();const m=a(i),l=c({__proto__:null,default:m},[i]);export{l as i};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as f}from"./index-
|
|
1
|
+
import{r as f}from"./index-PReApu5D.js";import{r as s}from"./ini-CUN5Fz6a.js";function c(t,n){for(var o=0;o<n.length;o++){const e=n[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const i=Object.getOwnPropertyDescriptor(e,r);i&&Object.defineProperty(t,r,i.get?i:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var a=s();const p=f(a),g=c({__proto__:null,default:p},[a]);export{g as i};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as p}from"./index-
|
|
1
|
+
import{r as p}from"./index-PReApu5D.js";import{r as a}from"./irpf90-BGwK5upn.js";function s(t,i){for(var o=0;o<i.length;o++){const r=i[o];if(typeof r!="string"&&!Array.isArray(r)){for(const e in r)if(e!=="default"&&!(e in t)){const f=Object.getOwnPropertyDescriptor(r,e);f&&Object.defineProperty(t,e,f.get?f:{enumerable:!0,get:()=>r[e]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var n=a();const c=p(n),g=s({__proto__:null,default:c},[n]);export{g as i};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as a}from"./index-
|
|
1
|
+
import{r as a}from"./index-PReApu5D.js";import{r as f}from"./isbl-BW2-1xqY.js";function l(t,i){for(var o=0;o<i.length;o++){const e=i[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const s=Object.getOwnPropertyDescriptor(e,r);s&&Object.defineProperty(t,r,s.get?s:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var n=f();const c=a(n),b=l({__proto__:null,default:c},[n]);export{b as i};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as s}from"./index-
|
|
1
|
+
import{r as s}from"./index-PReApu5D.js";import{r as i}from"./java-BopHZ59q.js";function c(t,n){for(var o=0;o<n.length;o++){const e=n[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const a=Object.getOwnPropertyDescriptor(e,r);a&&Object.defineProperty(t,r,a.get?a:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var f=i();const p=s(f),g=c({__proto__:null,default:p},[f]);export{g as j};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as c}from"./index-
|
|
1
|
+
import{r as c}from"./index-PReApu5D.js";import{r as n}from"./javascript-Bcajz3YC.js";function p(t,s){for(var o=0;o<s.length;o++){const r=s[o];if(typeof r!="string"&&!Array.isArray(r)){for(const e in r)if(e!=="default"&&!(e in t)){const a=Object.getOwnPropertyDescriptor(r,e);a&&Object.defineProperty(t,e,a.get?a:{enumerable:!0,get:()=>r[e]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var i=n();const f=c(i),g=p({__proto__:null,default:f},[i]);export{g as j};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as a}from"./index-
|
|
1
|
+
import{r as a}from"./index-PReApu5D.js";import{r as f}from"./jboss-cli-7Bb2wtKY.js";function l(t,i){for(var o=0;o<i.length;o++){const e=i[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const s=Object.getOwnPropertyDescriptor(e,r);s&&Object.defineProperty(t,r,s.get?s:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var n=f();const c=a(n),b=l({__proto__:null,default:c},[n]);export{b as j};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as f}from"./index-
|
|
1
|
+
import{r as f}from"./index-PReApu5D.js";import{r as i}from"./json-_cGKMkqV.js";function c(t,s){for(var o=0;o<s.length;o++){const e=s[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const n=Object.getOwnPropertyDescriptor(e,r);n&&Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var a=i();const p=f(a),g=c({__proto__:null,default:p},[a]);export{g as j};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as f}from"./index-
|
|
1
|
+
import{r as f}from"./index-PReApu5D.js";import{r as s}from"./julia-CflsGA1_.js";function u(t,i){for(var o=0;o<i.length;o++){const e=i[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const a=Object.getOwnPropertyDescriptor(e,r);a&&Object.defineProperty(t,r,a.get?a:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var n=s();const l=f(n),g=u({__proto__:null,default:l},[n]);export{g as j};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as n}from"./index-
|
|
1
|
+
import{r as n}from"./index-PReApu5D.js";import{r as p}from"./julia-repl-DTkCRO_Z.js";function f(t,l){for(var o=0;o<l.length;o++){const e=l[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const a=Object.getOwnPropertyDescriptor(e,r);a&&Object.defineProperty(t,r,a.get?a:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var i=p();const s=n(i),g=f({__proto__:null,default:s},[i]);export{g as j};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as f}from"./index-
|
|
1
|
+
import{r as f}from"./index-PReApu5D.js";import{r as s}from"./kotlin-DSmpQSGN.js";function l(r,i){for(var o=0;o<i.length;o++){const e=i[o];if(typeof e!="string"&&!Array.isArray(e)){for(const t in e)if(t!=="default"&&!(t in r)){const n=Object.getOwnPropertyDescriptor(e,t);n&&Object.defineProperty(r,t,n.get?n:{enumerable:!0,get:()=>e[t]})}}}return Object.freeze(Object.defineProperty(r,Symbol.toStringTag,{value:"Module"}))}var a=s();const c=f(a),g=l({__proto__:null,default:c},[a]);export{g as k};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/client-
|
|
2
|
-
import{bq as $c,br as eo,bs as jc,u as Qt,J as y,t as R,bt as Hr,b7 as Gr,bu as ve,b4 as Lc,bp as Dc,b9 as kn,b2 as re,bb as Fc,b3 as Uc,bv as Vc,aQ as Re,e as mn,bw as Bc,bx as En,A as We,by as Ss,n as X,aC as hn,aA as se,U as P,ab as ae,j as zc,C as Wc,bz as Hc,z as Do,aY as Ii,bA as oe,aE as xn,bB as _n,X as Pi,S as Ue,bC as to,Q as Me,V as Cs,W as en,aJ as yr,bD as Gc,bE as Kc,bF as Jc,bG as qc,bH as Yc,bI as Xc,bJ as Zc,bK as Qc,bL as eu,bM as tu,bN as nu,bO as ru,bP as su,bQ as ou,bR as iu,bS as au,bT as lu,bU as cu,bV as uu,bW as hu,a1 as du,bX as fu,bY as pu,bZ as mu,p as vn,m as $e,a2 as it,aN as tn,b_ as gu,Y as yu,aZ as Fo,aO as wu,b$ as Uo,c0 as Vo,c1 as wr,c2 as bt,b5 as no,ax as Ts,aw as ks,az as bu,ad as _u,as as ro,ay as so,an as te,av as nt,o as K,c3 as Le,c4 as Oi,b as oo,l as j,c5 as vu,c6 as Su,c7 as Cu,ac as Ni,at as Tu,x as ku,aR as Eu,T as xu,c8 as Dn,c9 as De,s as ie,ca as Ri,cb as nn,cc as Mn,cd as Mu,ce as Ke,cf as _t,cg as z,au as Au,f as io,aB as Iu,a as Pu,ch as $i,ci as Fn,cj as gt,ck as Ou,bl as Nu,bj as Ru,bi as $u,cl as ju,F as ji,cm as Xn,cn as Bo,bg as Zn,O as Lu,co as Du,I as zo,cp as Fu,cq as Uu,cr as Vu,N as Bu,cs as zu,ct as Wu,cu as Wo}from"./index-BQDf_2QT.js";import{h as Un,s as Li,g as Di,d as Hu,l as Gu,m as Ku,I as Ju,C as qu,n as Yu,t as Xu,o as Zu,p as Qu,q as eh,r as th,u as nh,v as rh,w as sh,x as oh,y as ih,z as ah,R as lh,A as Ho,e as ch}from"./index-DhbVcA9F.js";import{E as Fi,a as uh,e as hh}from"./embeddings-DD3kbxNt.js";import{L as Ui,o as dh,l as fh}from"./llms-iELWWhGP.js";import{S as jr,a as ph,t as Vi,T as mh,D as gh,b as Qn}from"./index-BaQ4JmMg.js";var Kr,Wn,Jr=0,qr=0;function yh(t,e,n){var r=0,s=e||new Array(16);t=t||{};var o=t.node,i=t.clockseq;if(t._v6||(o||(o=Kr),i==null&&(i=Wn)),o==null||i==null){var a=t.random||(t.rng||$c)();o==null&&(o=[a[0],a[1],a[2],a[3],a[4],a[5]],!Kr&&!t._v6&&(o[0]|=1,Kr=o)),i==null&&(i=(a[6]<<8|a[7])&16383,Wn===void 0&&!t._v6&&(Wn=i))}var l=t.msecs!==void 0?t.msecs:Date.now(),c=t.nsecs!==void 0?t.nsecs:qr+1,u=l-Jr+(c-qr)/1e4;if(u<0&&t.clockseq===void 0&&(i=i+1&16383),(u<0||l>Jr)&&t.nsecs===void 0&&(c=0),c>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");Jr=l,qr=c,Wn=i,l+=122192928e5;var d=((l&268435455)*1e4+c)%4294967296;s[r++]=d>>>24&255,s[r++]=d>>>16&255,s[r++]=d>>>8&255,s[r++]=d&255;var h=l/4294967296*1e4&268435455;s[r++]=h>>>8&255,s[r++]=h&255,s[r++]=h>>>24&15|16,s[r++]=h>>>16&255,s[r++]=i>>>8|128,s[r++]=i&255;for(var f=0;f<6;++f)s[r+f]=o[f];return e||eo(s)}function wh(t){var e=typeof t=="string"?jc(t):t,n=bh(e);return typeof t=="string"?eo(n):n}function bh(t,e=!1){return Uint8Array.of((t[6]&15)<<4|t[7]>>4&15,(t[7]&15)<<4|(t[4]&240)>>4,(t[4]&15)<<4|(t[5]&240)>>4,(t[5]&15)<<4|(t[0]&240)>>4,(t[0]&15)<<4|(t[1]&240)>>4,(t[1]&15)<<4|(t[2]&240)>>4,96|t[2]&15,t[3],t[8],t[9],t[10],t[11],t[12],t[13],t[14],t[15])}function Go(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(s){return Object.getOwnPropertyDescriptor(t,s).enumerable})),n.push.apply(n,r)}return n}function Ko(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Go(Object(n),!0).forEach(function(r){_h(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Go(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function _h(t,e,n){return(e=vh(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function vh(t){var e=Sh(t,"string");return typeof e=="symbol"?e:e+""}function Sh(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Ch(t={},e,n=0){var r=yh(Ko(Ko({},t),{},{_v6:!0}),new Uint8Array(16));return r=wh(r),eo(r)}var Jo={};function Q(t){if(typeof process<"u"&&Jo)return Jo[t]}R(Q,"getEnvVar");var Th=Q("MCP_USE_LANGFUSE")?.toLowerCase()==="false",rn={handler:null,client:null,initPromise:null};async function ao(t,e,n,r){try{const s=await Qt(()=>import("langfuse-langchain"),[]).catch(()=>null);if(!s){y.debug("Langfuse package not installed - tracing disabled. Install with: npm install @langfuse/langchain");return}const{CallbackHandler:o}=s,u=class u extends o{agentId;metadata;metadataProvider;tagsProvider;verbose;constructor(h,f,m,p,C){super(h),this.agentId=f,this.metadata=m,this.metadataProvider=p,this.tagsProvider=C,this.verbose=h?.verbose??!1}async handleChainStart(h,f,m,p,C,T,k,_){y.debug("Langfuse: Chain start intercepted");const g=this.getCustomTags(),v=this.getMetadata(),M=[...C||[],...g],w={...T||{},...v};return this.verbose&&(y.debug(`Langfuse: Chain start with custom tags: ${JSON.stringify(M)}`),y.debug(`Langfuse: Chain start with metadata: ${JSON.stringify(w)}`)),super.handleChainStart(h,f,m,p,M,w,k,_)}getCustomTags(){const h=[],f=this.getEnvironmentTag();if(f&&h.push(`env:${f}`),this.agentId&&h.push(`agent_id:${this.agentId}`),this.tagsProvider){const m=this.tagsProvider();m&&m.length>0&&h.push(...m)}return h}getMetadata(){const h={},f=this.getEnvironmentTag();if(f&&(h.env=f),this.agentId&&(h.agent_id=this.agentId),this.metadata&&Object.assign(h,this.metadata),this.metadataProvider){const m=this.metadataProvider();m&&Object.assign(h,m)}return h}getEnvironmentTag(){const h=Q("MCP_USE_AGENT_ENV");if(!h)return"unknown";const f=h.toLowerCase();return f==="local"||f==="development"?"local":f==="production"||f==="prod"?"production":f==="staging"||f==="stage"?"staging":f==="hosted"||f==="cloud"?"hosted":f.replace(/[^a-z0-9_-]/g,"_")}async handleLLMStart(...h){return y.debug("Langfuse: LLM start intercepted"),this.verbose&&y.debug(`Langfuse: LLM start args: ${JSON.stringify(h)}`),super.handleLLMStart(...h)}async handleToolStart(...h){return y.debug("Langfuse: Tool start intercepted"),this.verbose&&y.debug(`Langfuse: Tool start args: ${JSON.stringify(h)}`),super.handleToolStart(...h)}async handleRetrieverStart(...h){return y.debug("Langfuse: Retriever start intercepted"),this.verbose&&y.debug(`Langfuse: Retriever start args: ${JSON.stringify(h)}`),super.handleRetrieverStart(...h)}async handleAgentAction(...h){return y.debug("Langfuse: Agent action intercepted"),this.verbose&&y.debug(`Langfuse: Agent action args: ${JSON.stringify(h)}`),super.handleAgentAction(...h)}async handleAgentEnd(...h){return y.debug("Langfuse: Agent end intercepted"),this.verbose&&y.debug(`Langfuse: Agent end args: ${JSON.stringify(h)}`),super.handleAgentEnd(...h)}};R(u,"LoggingCallbackHandler");let i=u;const a=e||(n?n():{}),l=r?r():[],c={publicKey:Q("LANGFUSE_PUBLIC_KEY"),secretKey:Q("LANGFUSE_SECRET_KEY"),baseUrl:Q("LANGFUSE_HOST")||Q("LANGFUSE_BASEURL")||"https://cloud.langfuse.com",flushAt:Number.parseInt(Q("LANGFUSE_FLUSH_AT")||"15"),flushInterval:Number.parseInt(Q("LANGFUSE_FLUSH_INTERVAL")||"10000"),release:Q("LANGFUSE_RELEASE"),requestTimeout:Number.parseInt(Q("LANGFUSE_REQUEST_TIMEOUT")||"10000"),enabled:Q("LANGFUSE_ENABLED")!=="false",traceName:a.trace_name||Q("LANGFUSE_TRACE_NAME")||"mcp-use-agent",sessionId:a.session_id||void 0,userId:a.user_id||void 0,tags:l.length>0?l:void 0,metadata:a||void 0};y.debug("Langfuse handler config:",JSON.stringify({traceName:c.traceName,sessionId:c.sessionId,userId:c.userId,tags:c.tags},null,2)),rn.handler=new i(c,t,e,n,r),y.debug("Langfuse observability initialized successfully with logging enabled");try{const d=await Qt(()=>import("langfuse"),[]).catch(()=>null);if(d){const{Langfuse:h}=d;rn.client=new h({publicKey:Q("LANGFUSE_PUBLIC_KEY"),secretKey:Q("LANGFUSE_SECRET_KEY"),baseUrl:Q("LANGFUSE_HOST")||"https://cloud.langfuse.com"}),y.debug("Langfuse client initialized")}}catch(d){y.debug(`Langfuse client initialization failed: ${d}`)}}catch(s){y.debug(`Langfuse initialization error: ${s}`)}}R(ao,"initializeLangfuse");Th?y.debug("Langfuse tracing disabled via MCP_USE_LANGFUSE environment variable"):!Q("LANGFUSE_PUBLIC_KEY")||!Q("LANGFUSE_SECRET_KEY")?y.debug("Langfuse API keys not found - tracing disabled. Set LANGFUSE_PUBLIC_KEY and LANGFUSE_SECRET_KEY to enable"):rn.initPromise=ao();var kh=R(()=>rn.handler,"langfuseHandler"),Eh=R(()=>rn.client,"langfuseClient"),xh=R(()=>rn.initPromise,"langfuseInitPromise"),Ut,Mh=(Ut=class{static convert(e){return this.parseSchema(e)}static matchesCondition(e,n){if(!n.properties)return!0;if(typeof e!="object"||e===null||Array.isArray(e))return!1;const r=e;for(const[s,o]of Object.entries(n.properties)){if(!(s in r)){if("const"in o)return!1;continue}const i=r[s];if("const"in o&&i!==o.const||"minimum"in o&&typeof i=="number"&&i<o.minimum||"maximum"in o&&typeof i=="number"&&i>o.maximum)return!1}return!0}static validateConditionalSchema(e,n,r){this.validateRequiredProperties(e,n,r),this.validatePropertyPatterns(e,n,r),this.validateNestedConditions(e,n,r)}static validateRequiredProperties(e,n,r){if(n.required){if(typeof e!="object"||e===null){for(const s of n.required)r.addIssue({code:Hr.custom,message:`Required property '${s}' is missing`,path:[s]});return}for(const s of n.required)s in e||r.addIssue({code:Hr.custom,message:`Required property '${s}' is missing`,path:[s]})}}static validatePropertyPatterns(e,n,r){if(!n.properties||typeof e!="object"||e===null||Array.isArray(e))return;const s=e;for(const[o,i]of Object.entries(n.properties)){if(!(o in s))continue;const a=s[o];i.pattern&&typeof a=="string"&&(new RegExp(i.pattern).test(a)||r.addIssue({code:Hr.custom,message:`String '${a}' does not match pattern '${i.pattern}'`,path:[o]}))}}static validateNestedConditions(e,n,r){if(!n.if||!n.then)return;this.matchesCondition(e,n.if)?this.validateConditionalSchema(e,n.then,r):n.else&&this.validateConditionalSchema(e,n.else,r)}static parseSchema(e){let n;return Array.isArray(e.type)?n=this.handleTypeArray(e):e.oneOf||e.anyOf||e.allOf?n=this.parseCombinator(e):e.if&&e.then?n=this.parseObject(e):e.properties&&(!e.type||e.type==="object")?n=this.parseObject(e):n=this.handleSingleType(e),e.description&&typeof n.describe=="function"&&(n=n.describe(e.description)),n}static handleTypeArray(e){if(!Array.isArray(e.type))throw new Error("Expected schema.type to be an array");return e.type.includes("null")?this.handleNullableType(e):this.createUnionFromTypes(e.type,e)}static handleNullableType(e){if(!Array.isArray(e.type))throw new Error("Expected schema.type to be an array");const n={...e};return n.type=e.type.filter(s=>s!=="null"),n.type.length===1?this.handleSingleType({...e,type:n.type[0]}).nullable():this.parseSchema(n).nullable()}static createUnionFromTypes(e,n){const r=e.map(s=>{const o={...n,type:s};return this.parseSchema(o)});return Gr(r)}static handleSingleType(e){if(e.type===void 0)return e.oneOf||e.anyOf||e.allOf?this.parseCombinator(e):e.properties?this.parseObject(e):ve();switch(e.type){case"string":return this.parseString(e);case"number":case"integer":return this.parseNumberSchema(e);case"boolean":return Lc();case"array":return this.parseArray(e);case"object":return this.parseObject(e);default:throw new Error("Unsupported schema type")}}static parseNumberSchema(e){const n=Fc();let r=n;return r=this.applyNumberBounds(n,e),r=this.applyNumberMultipleOf(n,e),r=this.applyNumberEnum(n,e),r=this.applyIntegerConstraint(n,e),r}static applyNumberBounds(e,n){let r=e;return n.minimum!==void 0&&(r=n.exclusiveMinimum?r.gt(n.minimum):r.gte(n.minimum)),n.maximum!==void 0&&(r=n.exclusiveMaximum?r.lt(n.maximum):r.lte(n.maximum)),r}static applyNumberMultipleOf(e,n){return n.multipleOf===void 0?e:e.refine(r=>r%n.multipleOf===0,{message:`Number must be a multiple of ${n.multipleOf}`})}static applyNumberEnum(e,n){if(!n.enum)return e;const r=n.enum.filter(s=>typeof s=="number");return r.length===0?e:e.refine(s=>r.includes(s),{message:`Number must be one of: ${r.join(", ")}`})}static applyIntegerConstraint(e,n){return n.type!=="integer"?e:e.refine(r=>Number.isInteger(r),{message:"Number must be an integer"})}static parseString(e){const n=kn();let r=n;return e.format?this.applyStringFormat(n,e):(r=this.applyStringPattern(n,e),r=this.applyStringLength(n,e),r=this.applyStringEnum(n,e),r)}static applyStringFormat(e,n){if(!n.format)return e;switch(n.format){case"email":return e.email();case"date-time":return e.datetime();case"uri":return e.url();case"uuid":return e.uuid();case"date":return e.date();default:return e}}static applyStringPattern(e,n){if(!n.pattern)return e;const r=new RegExp(n.pattern);return e.regex(r,{message:`String must match pattern: ${n.pattern}`})}static applyStringLength(e,n){const r=e;return n.minLength!==void 0&&(e=e.min(n.minLength)),n.maxLength!==void 0&&(e=e.max(n.maxLength)),r}static applyStringEnum(e,n){return n.enum?e.refine(r=>n.enum?.includes(r),{message:`Value must be one of: ${n.enum?.join(", ")}`}):e}static parseArray(e){if(Array.isArray(e.items)){const o=e.items.map(i=>this.parseSchema(i));return Gr(o)}const n=e.items?this.parseSchema(e.items):ve(),r=Uc(n);let s=r;return s=this.applyArrayConstraints(r,e),s}static applyArrayConstraints(e,n){return n.minItems!==void 0&&(e=e.min(n.minItems)),n.maxItems!==void 0&&(e=e.max(n.maxItems)),n.uniqueItems?e.refine(r=>new Set(r).size===r.length,{message:"Array items must be unique"}):e}static parseObject(e){if(e.if&&e.then)return this.parseConditional(e);if(!e.properties&&e.additionalProperties&&typeof e.additionalProperties=="object"){const r=this.parseSchema(e.additionalProperties);return Dc(kn(),r)}const n={};return this.processObjectProperties(e,n),this.processAdditionalProperties(e,re(n))}static processObjectProperties(e,n){const r=new Set(e.required||[]);if(e.properties)for(const[s,o]of Object.entries(e.properties)){const i=this.parseSchema(o);n[s]=r.has(s)?i:i.optional()}}static processAdditionalProperties(e,n){if(e.additionalProperties===!0)return n.passthrough();if(e.additionalProperties&&typeof e.additionalProperties=="object"){const r=this.parseSchema(e.additionalProperties);return n.catchall(r)}else return n.strict()}static parseConditional(e){const n=this.createBaseObjectSchema(e),r=e.if,s=e.then,o=e.else;return n.superRefine((i,a)=>{const l=this.applyDefaultValues(i,e);this.matchesCondition(l,r)?this.validateConditionalSchema(l,s,a):o&&this.validateConditionalSchema(l,o,a)})}static createBaseObjectSchema(e){const n={},r=new Set(e.required||[]);for(const[o,i]of Object.entries(e.properties||{})){const a=this.parseSchema(i);n[o]=r.has(o)?a:a.optional()}const s=re(n);return this.processAdditionalProperties(e,s)}static applyDefaultValues(e,n){if(typeof e!="object"||e===null||Array.isArray(e))return e;const s={...e};if(!n.properties)return s;for(const[o,i]of Object.entries(n.properties))!(o in s)&&"default"in i&&(s[o]=i.default);return s}static parseCombinator(e){if(e.oneOf)return this.parseOneOf(e.oneOf);if(e.anyOf)return this.parseAnyOf(e.anyOf);if(e.allOf)return this.parseAllOf(e.allOf);throw new Error("Unsupported schema type")}static parseOneOf(e){return this.createUnionFromSchemas(e)}static parseAnyOf(e){return this.createUnionFromSchemas(e)}static createUnionFromSchemas(e){if(e.length===0)return ve();if(e.length===1)return this.parseSchema(e[0]);const n=[];for(const r of e)r.type==="null"?n.push(Vc()):n.push(this.parseSchema(r));return n.length>=2?Gr(n):n.length===1?n[0]:ve()}static parseAllOf(e){if(e.length===0)return ve();if(e.length===1)return this.parseSchema(e[0]);const n=e.reduce((r,s)=>this.mergeSchemas(r,s));return this.parseSchema(n)}static mergeSchemas(e,n){const r={...e,...n};if(e.properties&&n.properties){const s={...e.properties,...n.properties};r.properties=s}if(e.required&&n.required){const s=[...new Set([...e.required,...n.required])];r.required=s}return r}},R(Ut,"JSONSchemaToZod"),Ut),Ah=Object.defineProperty,Bi=(t,e)=>{for(var n in e)Ah(t,n,{get:e[n],enumerable:!0})},Ih={};Bi(Ih,{ConfigurableModel:()=>Es,MODEL_PROVIDER_CONFIG:()=>Lr,_inferModelProvider:()=>Hi,getChatModelByClassName:()=>Wi,initChatModel:()=>lt});const Lr={openai:{package:"@langchain/openai",className:"ChatOpenAI"},anthropic:{package:"@langchain/anthropic",className:"ChatAnthropic"},azure_openai:{package:"@langchain/openai",className:"AzureChatOpenAI"},cohere:{package:"@langchain/cohere",className:"ChatCohere"},"google-vertexai":{package:"@langchain/google-vertexai",className:"ChatVertexAI"},"google-vertexai-web":{package:"@langchain/google-vertexai-web",className:"ChatVertexAI"},"google-genai":{package:"@langchain/google-genai",className:"ChatGoogleGenerativeAI"},ollama:{package:"@langchain/ollama",className:"ChatOllama"},mistralai:{package:"@langchain/mistralai",className:"ChatMistralAI"},mistral:{package:"@langchain/mistralai",className:"ChatMistralAI"},groq:{package:"@langchain/groq",className:"ChatGroq"},cerebras:{package:"@langchain/cerebras",className:"ChatCerebras"},bedrock:{package:"@langchain/aws",className:"ChatBedrockConverse"},deepseek:{package:"@langchain/deepseek",className:"ChatDeepSeek"},xai:{package:"@langchain/xai",className:"ChatXAI"},fireworks:{package:"@langchain/community/chat_models/fireworks",className:"ChatFireworks",hasCircularDependency:!0},together:{package:"@langchain/community/chat_models/togetherai",className:"ChatTogetherAI",hasCircularDependency:!0},perplexity:{package:"@langchain/community/chat_models/perplexity",className:"ChatPerplexity",hasCircularDependency:!0}},zi=Object.keys(Lr);async function Wi(t){const e=Object.entries(Lr).find(([,r])=>r.className===t);if(!e)return;const[,n]=e;try{return(await import(n.package))[n.className]}catch(r){const s=r;if("code"in s&&s.code?.toString().includes("ERR_MODULE_NOT_FOUND")&&"message"in s&&typeof s.message=="string"){const i=(s.message.startsWith("Error: ")?s.message.slice(7):s.message).split("Cannot find package '")[1].split("'")[0];throw new Error(`Unable to import ${i}. Please install with \`npm install ${i}\` or \`pnpm install ${i}\``)}throw r}}async function Ph(t,e,n={}){const r=e||Hi(t);if(!r)throw new Error(`Unable to infer model provider for { model: ${t} }, please specify modelProvider directly.`);const s=Lr[r];if(!s){const l=zi.join(", ");throw new Error(`Unsupported { modelProvider: ${r} }.
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/client-AB7PHV6E-8__RED_q.js","assets/index-PReApu5D.js","assets/index-_8WeQxwg.css","assets/display-A5IEINAP-BUlGvd6Q.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{bq as $c,br as eo,bs as jc,u as Qt,J as y,t as R,bt as Hr,b7 as Gr,bu as ve,b4 as Lc,bp as Dc,b9 as kn,b2 as re,bb as Fc,b3 as Uc,bv as Vc,aQ as Re,e as mn,bw as Bc,bx as En,A as We,by as Ss,n as X,aC as hn,aA as se,U as P,ab as ae,j as zc,C as Wc,bz as Hc,z as Do,aY as Ii,bA as oe,aE as xn,bB as _n,X as Pi,S as Ue,bC as to,Q as Me,V as Cs,W as en,aJ as yr,bD as Gc,bE as Kc,bF as Jc,bG as qc,bH as Yc,bI as Xc,bJ as Zc,bK as Qc,bL as eu,bM as tu,bN as nu,bO as ru,bP as su,bQ as ou,bR as iu,bS as au,bT as lu,bU as cu,bV as uu,bW as hu,a1 as du,bX as fu,bY as pu,bZ as mu,p as vn,m as $e,a2 as it,aN as tn,b_ as gu,Y as yu,aZ as Fo,aO as wu,b$ as Uo,c0 as Vo,c1 as wr,c2 as bt,b5 as no,ax as Ts,aw as ks,az as bu,ad as _u,as as ro,ay as so,an as te,av as nt,o as K,c3 as Le,c4 as Oi,b as oo,l as j,c5 as vu,c6 as Su,c7 as Cu,ac as Ni,at as Tu,x as ku,aR as Eu,T as xu,c8 as Dn,c9 as De,s as ie,ca as Ri,cb as nn,cc as Mn,cd as Mu,ce as Ke,cf as _t,cg as z,au as Au,f as io,aB as Iu,a as Pu,ch as $i,ci as Fn,cj as gt,ck as Ou,bl as Nu,bj as Ru,bi as $u,cl as ju,F as ji,cm as Xn,cn as Bo,bg as Zn,O as Lu,co as Du,I as zo,cp as Fu,cq as Uu,cr as Vu,N as Bu,cs as zu,ct as Wu,cu as Wo}from"./index-PReApu5D.js";import{h as Un,s as Li,g as Di,d as Hu,l as Gu,m as Ku,I as Ju,C as qu,n as Yu,t as Xu,o as Zu,p as Qu,q as eh,r as th,u as nh,v as rh,w as sh,x as oh,y as ih,z as ah,R as lh,A as Ho,e as ch}from"./index-BGGQsG8S.js";import{E as Fi,a as uh,e as hh}from"./embeddings-VSFMeWkW.js";import{L as Ui,o as dh,l as fh}from"./llms-Dji6qLbK.js";import{S as jr,a as ph,t as Vi,T as mh,D as gh,b as Qn}from"./index-CCwFSwLA.js";var Kr,Wn,Jr=0,qr=0;function yh(t,e,n){var r=0,s=e||new Array(16);t=t||{};var o=t.node,i=t.clockseq;if(t._v6||(o||(o=Kr),i==null&&(i=Wn)),o==null||i==null){var a=t.random||(t.rng||$c)();o==null&&(o=[a[0],a[1],a[2],a[3],a[4],a[5]],!Kr&&!t._v6&&(o[0]|=1,Kr=o)),i==null&&(i=(a[6]<<8|a[7])&16383,Wn===void 0&&!t._v6&&(Wn=i))}var l=t.msecs!==void 0?t.msecs:Date.now(),c=t.nsecs!==void 0?t.nsecs:qr+1,u=l-Jr+(c-qr)/1e4;if(u<0&&t.clockseq===void 0&&(i=i+1&16383),(u<0||l>Jr)&&t.nsecs===void 0&&(c=0),c>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");Jr=l,qr=c,Wn=i,l+=122192928e5;var d=((l&268435455)*1e4+c)%4294967296;s[r++]=d>>>24&255,s[r++]=d>>>16&255,s[r++]=d>>>8&255,s[r++]=d&255;var h=l/4294967296*1e4&268435455;s[r++]=h>>>8&255,s[r++]=h&255,s[r++]=h>>>24&15|16,s[r++]=h>>>16&255,s[r++]=i>>>8|128,s[r++]=i&255;for(var f=0;f<6;++f)s[r+f]=o[f];return e||eo(s)}function wh(t){var e=typeof t=="string"?jc(t):t,n=bh(e);return typeof t=="string"?eo(n):n}function bh(t,e=!1){return Uint8Array.of((t[6]&15)<<4|t[7]>>4&15,(t[7]&15)<<4|(t[4]&240)>>4,(t[4]&15)<<4|(t[5]&240)>>4,(t[5]&15)<<4|(t[0]&240)>>4,(t[0]&15)<<4|(t[1]&240)>>4,(t[1]&15)<<4|(t[2]&240)>>4,96|t[2]&15,t[3],t[8],t[9],t[10],t[11],t[12],t[13],t[14],t[15])}function Go(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(s){return Object.getOwnPropertyDescriptor(t,s).enumerable})),n.push.apply(n,r)}return n}function Ko(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Go(Object(n),!0).forEach(function(r){_h(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Go(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function _h(t,e,n){return(e=vh(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function vh(t){var e=Sh(t,"string");return typeof e=="symbol"?e:e+""}function Sh(t,e){if(typeof t!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Ch(t={},e,n=0){var r=yh(Ko(Ko({},t),{},{_v6:!0}),new Uint8Array(16));return r=wh(r),eo(r)}var Jo={};function Q(t){if(typeof process<"u"&&Jo)return Jo[t]}R(Q,"getEnvVar");var Th=Q("MCP_USE_LANGFUSE")?.toLowerCase()==="false",rn={handler:null,client:null,initPromise:null};async function ao(t,e,n,r){try{const s=await Qt(()=>import("langfuse-langchain"),[]).catch(()=>null);if(!s){y.debug("Langfuse package not installed - tracing disabled. Install with: npm install @langfuse/langchain");return}const{CallbackHandler:o}=s,u=class u extends o{agentId;metadata;metadataProvider;tagsProvider;verbose;constructor(h,f,m,p,C){super(h),this.agentId=f,this.metadata=m,this.metadataProvider=p,this.tagsProvider=C,this.verbose=h?.verbose??!1}async handleChainStart(h,f,m,p,C,T,k,_){y.debug("Langfuse: Chain start intercepted");const g=this.getCustomTags(),v=this.getMetadata(),M=[...C||[],...g],w={...T||{},...v};return this.verbose&&(y.debug(`Langfuse: Chain start with custom tags: ${JSON.stringify(M)}`),y.debug(`Langfuse: Chain start with metadata: ${JSON.stringify(w)}`)),super.handleChainStart(h,f,m,p,M,w,k,_)}getCustomTags(){const h=[],f=this.getEnvironmentTag();if(f&&h.push(`env:${f}`),this.agentId&&h.push(`agent_id:${this.agentId}`),this.tagsProvider){const m=this.tagsProvider();m&&m.length>0&&h.push(...m)}return h}getMetadata(){const h={},f=this.getEnvironmentTag();if(f&&(h.env=f),this.agentId&&(h.agent_id=this.agentId),this.metadata&&Object.assign(h,this.metadata),this.metadataProvider){const m=this.metadataProvider();m&&Object.assign(h,m)}return h}getEnvironmentTag(){const h=Q("MCP_USE_AGENT_ENV");if(!h)return"unknown";const f=h.toLowerCase();return f==="local"||f==="development"?"local":f==="production"||f==="prod"?"production":f==="staging"||f==="stage"?"staging":f==="hosted"||f==="cloud"?"hosted":f.replace(/[^a-z0-9_-]/g,"_")}async handleLLMStart(...h){return y.debug("Langfuse: LLM start intercepted"),this.verbose&&y.debug(`Langfuse: LLM start args: ${JSON.stringify(h)}`),super.handleLLMStart(...h)}async handleToolStart(...h){return y.debug("Langfuse: Tool start intercepted"),this.verbose&&y.debug(`Langfuse: Tool start args: ${JSON.stringify(h)}`),super.handleToolStart(...h)}async handleRetrieverStart(...h){return y.debug("Langfuse: Retriever start intercepted"),this.verbose&&y.debug(`Langfuse: Retriever start args: ${JSON.stringify(h)}`),super.handleRetrieverStart(...h)}async handleAgentAction(...h){return y.debug("Langfuse: Agent action intercepted"),this.verbose&&y.debug(`Langfuse: Agent action args: ${JSON.stringify(h)}`),super.handleAgentAction(...h)}async handleAgentEnd(...h){return y.debug("Langfuse: Agent end intercepted"),this.verbose&&y.debug(`Langfuse: Agent end args: ${JSON.stringify(h)}`),super.handleAgentEnd(...h)}};R(u,"LoggingCallbackHandler");let i=u;const a=e||(n?n():{}),l=r?r():[],c={publicKey:Q("LANGFUSE_PUBLIC_KEY"),secretKey:Q("LANGFUSE_SECRET_KEY"),baseUrl:Q("LANGFUSE_HOST")||Q("LANGFUSE_BASEURL")||"https://cloud.langfuse.com",flushAt:Number.parseInt(Q("LANGFUSE_FLUSH_AT")||"15"),flushInterval:Number.parseInt(Q("LANGFUSE_FLUSH_INTERVAL")||"10000"),release:Q("LANGFUSE_RELEASE"),requestTimeout:Number.parseInt(Q("LANGFUSE_REQUEST_TIMEOUT")||"10000"),enabled:Q("LANGFUSE_ENABLED")!=="false",traceName:a.trace_name||Q("LANGFUSE_TRACE_NAME")||"mcp-use-agent",sessionId:a.session_id||void 0,userId:a.user_id||void 0,tags:l.length>0?l:void 0,metadata:a||void 0};y.debug("Langfuse handler config:",JSON.stringify({traceName:c.traceName,sessionId:c.sessionId,userId:c.userId,tags:c.tags},null,2)),rn.handler=new i(c,t,e,n,r),y.debug("Langfuse observability initialized successfully with logging enabled");try{const d=await Qt(()=>import("langfuse"),[]).catch(()=>null);if(d){const{Langfuse:h}=d;rn.client=new h({publicKey:Q("LANGFUSE_PUBLIC_KEY"),secretKey:Q("LANGFUSE_SECRET_KEY"),baseUrl:Q("LANGFUSE_HOST")||"https://cloud.langfuse.com"}),y.debug("Langfuse client initialized")}}catch(d){y.debug(`Langfuse client initialization failed: ${d}`)}}catch(s){y.debug(`Langfuse initialization error: ${s}`)}}R(ao,"initializeLangfuse");Th?y.debug("Langfuse tracing disabled via MCP_USE_LANGFUSE environment variable"):!Q("LANGFUSE_PUBLIC_KEY")||!Q("LANGFUSE_SECRET_KEY")?y.debug("Langfuse API keys not found - tracing disabled. Set LANGFUSE_PUBLIC_KEY and LANGFUSE_SECRET_KEY to enable"):rn.initPromise=ao();var kh=R(()=>rn.handler,"langfuseHandler"),Eh=R(()=>rn.client,"langfuseClient"),xh=R(()=>rn.initPromise,"langfuseInitPromise"),Ut,Mh=(Ut=class{static convert(e){return this.parseSchema(e)}static matchesCondition(e,n){if(!n.properties)return!0;if(typeof e!="object"||e===null||Array.isArray(e))return!1;const r=e;for(const[s,o]of Object.entries(n.properties)){if(!(s in r)){if("const"in o)return!1;continue}const i=r[s];if("const"in o&&i!==o.const||"minimum"in o&&typeof i=="number"&&i<o.minimum||"maximum"in o&&typeof i=="number"&&i>o.maximum)return!1}return!0}static validateConditionalSchema(e,n,r){this.validateRequiredProperties(e,n,r),this.validatePropertyPatterns(e,n,r),this.validateNestedConditions(e,n,r)}static validateRequiredProperties(e,n,r){if(n.required){if(typeof e!="object"||e===null){for(const s of n.required)r.addIssue({code:Hr.custom,message:`Required property '${s}' is missing`,path:[s]});return}for(const s of n.required)s in e||r.addIssue({code:Hr.custom,message:`Required property '${s}' is missing`,path:[s]})}}static validatePropertyPatterns(e,n,r){if(!n.properties||typeof e!="object"||e===null||Array.isArray(e))return;const s=e;for(const[o,i]of Object.entries(n.properties)){if(!(o in s))continue;const a=s[o];i.pattern&&typeof a=="string"&&(new RegExp(i.pattern).test(a)||r.addIssue({code:Hr.custom,message:`String '${a}' does not match pattern '${i.pattern}'`,path:[o]}))}}static validateNestedConditions(e,n,r){if(!n.if||!n.then)return;this.matchesCondition(e,n.if)?this.validateConditionalSchema(e,n.then,r):n.else&&this.validateConditionalSchema(e,n.else,r)}static parseSchema(e){let n;return Array.isArray(e.type)?n=this.handleTypeArray(e):e.oneOf||e.anyOf||e.allOf?n=this.parseCombinator(e):e.if&&e.then?n=this.parseObject(e):e.properties&&(!e.type||e.type==="object")?n=this.parseObject(e):n=this.handleSingleType(e),e.description&&typeof n.describe=="function"&&(n=n.describe(e.description)),n}static handleTypeArray(e){if(!Array.isArray(e.type))throw new Error("Expected schema.type to be an array");return e.type.includes("null")?this.handleNullableType(e):this.createUnionFromTypes(e.type,e)}static handleNullableType(e){if(!Array.isArray(e.type))throw new Error("Expected schema.type to be an array");const n={...e};return n.type=e.type.filter(s=>s!=="null"),n.type.length===1?this.handleSingleType({...e,type:n.type[0]}).nullable():this.parseSchema(n).nullable()}static createUnionFromTypes(e,n){const r=e.map(s=>{const o={...n,type:s};return this.parseSchema(o)});return Gr(r)}static handleSingleType(e){if(e.type===void 0)return e.oneOf||e.anyOf||e.allOf?this.parseCombinator(e):e.properties?this.parseObject(e):ve();switch(e.type){case"string":return this.parseString(e);case"number":case"integer":return this.parseNumberSchema(e);case"boolean":return Lc();case"array":return this.parseArray(e);case"object":return this.parseObject(e);default:throw new Error("Unsupported schema type")}}static parseNumberSchema(e){const n=Fc();let r=n;return r=this.applyNumberBounds(n,e),r=this.applyNumberMultipleOf(n,e),r=this.applyNumberEnum(n,e),r=this.applyIntegerConstraint(n,e),r}static applyNumberBounds(e,n){let r=e;return n.minimum!==void 0&&(r=n.exclusiveMinimum?r.gt(n.minimum):r.gte(n.minimum)),n.maximum!==void 0&&(r=n.exclusiveMaximum?r.lt(n.maximum):r.lte(n.maximum)),r}static applyNumberMultipleOf(e,n){return n.multipleOf===void 0?e:e.refine(r=>r%n.multipleOf===0,{message:`Number must be a multiple of ${n.multipleOf}`})}static applyNumberEnum(e,n){if(!n.enum)return e;const r=n.enum.filter(s=>typeof s=="number");return r.length===0?e:e.refine(s=>r.includes(s),{message:`Number must be one of: ${r.join(", ")}`})}static applyIntegerConstraint(e,n){return n.type!=="integer"?e:e.refine(r=>Number.isInteger(r),{message:"Number must be an integer"})}static parseString(e){const n=kn();let r=n;return e.format?this.applyStringFormat(n,e):(r=this.applyStringPattern(n,e),r=this.applyStringLength(n,e),r=this.applyStringEnum(n,e),r)}static applyStringFormat(e,n){if(!n.format)return e;switch(n.format){case"email":return e.email();case"date-time":return e.datetime();case"uri":return e.url();case"uuid":return e.uuid();case"date":return e.date();default:return e}}static applyStringPattern(e,n){if(!n.pattern)return e;const r=new RegExp(n.pattern);return e.regex(r,{message:`String must match pattern: ${n.pattern}`})}static applyStringLength(e,n){const r=e;return n.minLength!==void 0&&(e=e.min(n.minLength)),n.maxLength!==void 0&&(e=e.max(n.maxLength)),r}static applyStringEnum(e,n){return n.enum?e.refine(r=>n.enum?.includes(r),{message:`Value must be one of: ${n.enum?.join(", ")}`}):e}static parseArray(e){if(Array.isArray(e.items)){const o=e.items.map(i=>this.parseSchema(i));return Gr(o)}const n=e.items?this.parseSchema(e.items):ve(),r=Uc(n);let s=r;return s=this.applyArrayConstraints(r,e),s}static applyArrayConstraints(e,n){return n.minItems!==void 0&&(e=e.min(n.minItems)),n.maxItems!==void 0&&(e=e.max(n.maxItems)),n.uniqueItems?e.refine(r=>new Set(r).size===r.length,{message:"Array items must be unique"}):e}static parseObject(e){if(e.if&&e.then)return this.parseConditional(e);if(!e.properties&&e.additionalProperties&&typeof e.additionalProperties=="object"){const r=this.parseSchema(e.additionalProperties);return Dc(kn(),r)}const n={};return this.processObjectProperties(e,n),this.processAdditionalProperties(e,re(n))}static processObjectProperties(e,n){const r=new Set(e.required||[]);if(e.properties)for(const[s,o]of Object.entries(e.properties)){const i=this.parseSchema(o);n[s]=r.has(s)?i:i.optional()}}static processAdditionalProperties(e,n){if(e.additionalProperties===!0)return n.passthrough();if(e.additionalProperties&&typeof e.additionalProperties=="object"){const r=this.parseSchema(e.additionalProperties);return n.catchall(r)}else return n.strict()}static parseConditional(e){const n=this.createBaseObjectSchema(e),r=e.if,s=e.then,o=e.else;return n.superRefine((i,a)=>{const l=this.applyDefaultValues(i,e);this.matchesCondition(l,r)?this.validateConditionalSchema(l,s,a):o&&this.validateConditionalSchema(l,o,a)})}static createBaseObjectSchema(e){const n={},r=new Set(e.required||[]);for(const[o,i]of Object.entries(e.properties||{})){const a=this.parseSchema(i);n[o]=r.has(o)?a:a.optional()}const s=re(n);return this.processAdditionalProperties(e,s)}static applyDefaultValues(e,n){if(typeof e!="object"||e===null||Array.isArray(e))return e;const s={...e};if(!n.properties)return s;for(const[o,i]of Object.entries(n.properties))!(o in s)&&"default"in i&&(s[o]=i.default);return s}static parseCombinator(e){if(e.oneOf)return this.parseOneOf(e.oneOf);if(e.anyOf)return this.parseAnyOf(e.anyOf);if(e.allOf)return this.parseAllOf(e.allOf);throw new Error("Unsupported schema type")}static parseOneOf(e){return this.createUnionFromSchemas(e)}static parseAnyOf(e){return this.createUnionFromSchemas(e)}static createUnionFromSchemas(e){if(e.length===0)return ve();if(e.length===1)return this.parseSchema(e[0]);const n=[];for(const r of e)r.type==="null"?n.push(Vc()):n.push(this.parseSchema(r));return n.length>=2?Gr(n):n.length===1?n[0]:ve()}static parseAllOf(e){if(e.length===0)return ve();if(e.length===1)return this.parseSchema(e[0]);const n=e.reduce((r,s)=>this.mergeSchemas(r,s));return this.parseSchema(n)}static mergeSchemas(e,n){const r={...e,...n};if(e.properties&&n.properties){const s={...e.properties,...n.properties};r.properties=s}if(e.required&&n.required){const s=[...new Set([...e.required,...n.required])];r.required=s}return r}},R(Ut,"JSONSchemaToZod"),Ut),Ah=Object.defineProperty,Bi=(t,e)=>{for(var n in e)Ah(t,n,{get:e[n],enumerable:!0})},Ih={};Bi(Ih,{ConfigurableModel:()=>Es,MODEL_PROVIDER_CONFIG:()=>Lr,_inferModelProvider:()=>Hi,getChatModelByClassName:()=>Wi,initChatModel:()=>lt});const Lr={openai:{package:"@langchain/openai",className:"ChatOpenAI"},anthropic:{package:"@langchain/anthropic",className:"ChatAnthropic"},azure_openai:{package:"@langchain/openai",className:"AzureChatOpenAI"},cohere:{package:"@langchain/cohere",className:"ChatCohere"},"google-vertexai":{package:"@langchain/google-vertexai",className:"ChatVertexAI"},"google-vertexai-web":{package:"@langchain/google-vertexai-web",className:"ChatVertexAI"},"google-genai":{package:"@langchain/google-genai",className:"ChatGoogleGenerativeAI"},ollama:{package:"@langchain/ollama",className:"ChatOllama"},mistralai:{package:"@langchain/mistralai",className:"ChatMistralAI"},mistral:{package:"@langchain/mistralai",className:"ChatMistralAI"},groq:{package:"@langchain/groq",className:"ChatGroq"},cerebras:{package:"@langchain/cerebras",className:"ChatCerebras"},bedrock:{package:"@langchain/aws",className:"ChatBedrockConverse"},deepseek:{package:"@langchain/deepseek",className:"ChatDeepSeek"},xai:{package:"@langchain/xai",className:"ChatXAI"},fireworks:{package:"@langchain/community/chat_models/fireworks",className:"ChatFireworks",hasCircularDependency:!0},together:{package:"@langchain/community/chat_models/togetherai",className:"ChatTogetherAI",hasCircularDependency:!0},perplexity:{package:"@langchain/community/chat_models/perplexity",className:"ChatPerplexity",hasCircularDependency:!0}},zi=Object.keys(Lr);async function Wi(t){const e=Object.entries(Lr).find(([,r])=>r.className===t);if(!e)return;const[,n]=e;try{return(await import(n.package))[n.className]}catch(r){const s=r;if("code"in s&&s.code?.toString().includes("ERR_MODULE_NOT_FOUND")&&"message"in s&&typeof s.message=="string"){const i=(s.message.startsWith("Error: ")?s.message.slice(7):s.message).split("Cannot find package '")[1].split("'")[0];throw new Error(`Unable to import ${i}. Please install with \`npm install ${i}\` or \`pnpm install ${i}\``)}throw r}}async function Ph(t,e,n={}){const r=e||Hi(t);if(!r)throw new Error(`Unable to infer model provider for { model: ${t} }, please specify modelProvider directly.`);const s=Lr[r];if(!s){const l=zi.join(", ");throw new Error(`Unsupported { modelProvider: ${r} }.
|
|
3
3
|
|
|
4
4
|
Supported model providers are: ${l}`)}const{modelProvider:o,...i}=n,a=await Wi(s.className);return new a({model:t,...i})}function Hi(t){return t.startsWith("gpt-3")||t.startsWith("gpt-4")||t.startsWith("gpt-5")||t.startsWith("o1")||t.startsWith("o3")||t.startsWith("o4")?"openai":t.startsWith("claude")?"anthropic":t.startsWith("command")?"cohere":t.startsWith("accounts/fireworks")?"fireworks":t.startsWith("gemini")?"google-vertexai":t.startsWith("amazon.")?"bedrock":t.startsWith("mistral")?"mistralai":t.startsWith("sonar")||t.startsWith("pplx")?"perplexity":void 0}var Es=class er extends Un{_llmType(){return"chat_model"}lc_namespace=["langchain","chat_models"];_defaultConfig={};_configurableFields="any";_configPrefix;_queuedMethodOperations={};_modelInstanceCache=new Map;_profile;constructor(e){super(e),this._defaultConfig=e.defaultConfig??{},e.configurableFields==="any"?this._configurableFields="any":this._configurableFields=e.configurableFields??["model","modelProvider"],e.configPrefix?this._configPrefix=e.configPrefix.endsWith("_")?e.configPrefix:`${e.configPrefix}_`:this._configPrefix="",this._queuedMethodOperations=e.queuedMethodOperations??this._queuedMethodOperations,this._profile=e.profile??void 0}async _getModelInstance(e){const n=this._getCacheKey(e),r=this._modelInstanceCache.get(n);if(r)return r;const s={...this._defaultConfig,...this._modelParams(e)};let o=await Ph(s.model,s.modelProvider,s);for(const[i,a]of Object.entries(this._queuedMethodOperations))i in o&&typeof o[i]=="function"&&(o=await o[i](...a));return this._modelInstanceCache.set(n,o),o}async _generate(e,n,r){return(await this._getModelInstance(n))._generate(e,n??{},r)}bindTools(e,n){const r={...this._queuedMethodOperations};return r.bindTools=[e,n],new er({defaultConfig:this._defaultConfig,configurableFields:this._configurableFields,configPrefix:this._configPrefix,queuedMethodOperations:r})}withStructuredOutput=(e,...n)=>{const r={...this._queuedMethodOperations};return r.withStructuredOutput=[e,...n],new er({defaultConfig:this._defaultConfig,configurableFields:this._configurableFields,configPrefix:this._configPrefix,queuedMethodOperations:r})};_modelParams(e){const n=e?.configurable??{};let r={};for(const[s,o]of Object.entries(n))if(s.startsWith(this._configPrefix)){const i=this._removePrefix(s,this._configPrefix);r[i]=o}return this._configurableFields!=="any"&&(r=Object.fromEntries(Object.entries(r).filter(([s])=>this._configurableFields.includes(s)))),r}_removePrefix(e,n){return e.startsWith(n)?e.slice(n.length):e}withConfig(e){const n={...e||{}},r=this._modelParams(n),s=Object.fromEntries(Object.entries(n).filter(([i])=>i!=="configurable"));s.configurable=Object.fromEntries(Object.entries(n.configurable||{}).filter(([i])=>this._configPrefix&&!Object.keys(r).includes(this._removePrefix(i,this._configPrefix))));const o=new er({defaultConfig:{...this._defaultConfig,...r},configurableFields:Array.isArray(this._configurableFields)?[...this._configurableFields]:this._configurableFields,configPrefix:this._configPrefix,queuedMethodOperations:this._queuedMethodOperations});return new Re({config:n,bound:o})}async invoke(e,n){const r=await this._getModelInstance(n),s=mn(n);return r.invoke(e,s)}async stream(e,n){const r=await this._getModelInstance(n),s=new Bc({generator:await r.stream(e,n),config:n});return await s.setup,En.fromAsyncGenerator(s)}async batch(e,n,r){return super.batch(e,n,r)}async*transform(e,n){const r=await this._getModelInstance(n),s=mn(n);yield*r.transform(e,s)}async*streamLog(e,n,r){const s=await this._getModelInstance(n),o=mn(n);yield*s.streamLog(e,o,{...r,_schemaFormat:"original",includeNames:r?.includeNames,includeTypes:r?.includeTypes,includeTags:r?.includeTags,excludeNames:r?.excludeNames,excludeTypes:r?.excludeTypes,excludeTags:r?.excludeTags})}streamEvents(e,n,r){const s=this;async function*o(){const i=await s._getModelInstance(n),a=mn(n),l=i.streamEvents(e,a,r);for await(const c of l)yield c}return En.fromAsyncGenerator(o())}get profile(){if(this._profile)return this._profile;const e=this._getCacheKey({});return this._modelInstanceCache.get(e)?.profile??{}}_getCacheKey(e){let n=e??{};if(n.configurable){const{configurable:r}=n,s={};for(const[o,i]of Object.entries(r))o.startsWith("__pregel_")||(s[o]=i);n={...n,configurable:s}}return JSON.stringify(n)}};async function lt(t,e){let{configurableFields:n,configPrefix:r,modelProvider:s,profile:o,...i}={configPrefix:"",...e??{}};if(s===void 0&&t?.includes(":")){const[u,...d]=t.split(":"),h=d.length===0?[u]:[u,d.join(":")];zi.includes(h[0])&&([s,t]=h)}let a=Array.isArray(n)?[...n]:n;!t&&a===void 0&&(a=["model","modelProvider"]),r&&a===void 0&&console.warn(`{ configPrefix: ${r} } has been set but no fields are configurable. Set { configurableFields: [...] } to specify the model params that are configurable.`);const l={...i};let c;return a===void 0?c=new Es({defaultConfig:{...l,model:t,modelProvider:s},configPrefix:r,profile:o}):(t&&(l.model=t),s&&(l.modelProvider=s),c=new Es({defaultConfig:l,configPrefix:r,configurableFields:a,profile:o})),await c._getModelInstance(),c}class Oh{constructor(){this.store=void 0}getStore(){return this.store}run(e,n,...r){this.store=e;try{return n(...r)}finally{this.store=void 0}}exit(e,...n){const r=this.store;this.store=void 0;try{return e(...n)}finally{this.store=r}}enterWith(e){this.store=e}disable(){this.store=void 0}}function Nh(){We.initializeGlobalInstance(new Oh)}var ct=class extends Error{lc_error_code;constructor(t,e){let n=t??"";e?.lc_error_code&&(n=`${n}
|
|
5
5
|
|
|
@@ -383,7 +383,7 @@ Here are the tools *currently* available to you (this list includes server manag
|
|
|
383
383
|
• Missing or invalid MCP server configurations
|
|
384
384
|
• Network connectivity issues with MCP servers
|
|
385
385
|
• Missing environment variables or credentials
|
|
386
|
-
Raw error: ${p}`)}return c?this.parseStructuredResponse(p,c):typeof p=="object"&&p!==null&&"result"in p?p.result:typeof p=="string"?p:String(p)}catch(u){throw u instanceof Error?u.name==="AbortError"?(y.error(`❌ Remote execution timed out: ${u}`),new Error("Remote agent execution timed out. The server may be overloaded or the query is taking too long to process. Try again or use a simpler query.")):(y.error(`❌ Remote execution error: ${u}`),new Error(`Remote agent execution failed: ${u.message}`)):(y.error(`❌ Remote execution error: ${u}`),new Error(`Remote agent execution failed: ${String(u)}`))}}async*stream(e,n,r,s,o){return await this.run(e,n,r,s,o)}async close(){y.info("🔌 Remote agent client closed")}},R(Xt,"RemoteAgent"),Xt),Ln={openai:{package:"@langchain/openai",className:"ChatOpenAI",envVars:["OPENAI_API_KEY"],defaultModel:"gpt-4o"},anthropic:{package:"@langchain/anthropic",className:"ChatAnthropic",envVars:["ANTHROPIC_API_KEY"],defaultModel:"claude-3-5-sonnet-20241022"},google:{package:"@langchain/google-genai",className:"ChatGoogleGenerativeAI",envVars:["GOOGLE_API_KEY","GOOGLE_GENERATIVE_AI_API_KEY"],defaultModel:"gemini-pro"},groq:{package:"@langchain/groq",className:"ChatGroq",envVars:["GROQ_API_KEY"],defaultModel:"llama-3.1-70b-versatile"}};function Wr(t){const e=t.split("/");if(e.length!==2)throw new Error(`Invalid LLM string format. Expected 'provider/model', got '${t}'. Examples: 'openai/gpt-4', 'anthropic/claude-3-5-sonnet-20241022', 'google/gemini-pro', 'groq/llama-3.1-70b-versatile'`);const[n,r]=e;if(!n||!r)throw new Error(`Invalid LLM string format. Both provider and model must be non-empty. Got '${t}'`);const s=n.toLowerCase();if(!(s in Ln)){const o=Object.keys(Ln).join(", ");throw new Error(`Unsupported LLM provider '${n}'. Supported providers: ${o}`)}return{provider:s,model:r}}R(Wr,"parseLLMString");function Ac(t,e){if(e?.apiKey)return e.apiKey;const n=Ln[t];if(typeof process<"u"&&Zs)for(const s of n.envVars){const o=Zs[s];if(o)return y.debug(`Using API key from environment variable ${s} for provider ${t}`),o}const r=n.envVars.join(" or ");throw new Error(`API key not found for provider '${t}'. Set ${r} environment variable or pass apiKey in llmConfig. Example: new MCPAgent({ llm: '${t}/model', llmConfig: { apiKey: 'your-key' } })`)}R(Ac,"getAPIKey");async function jo(t,e){y.info(`Creating LLM from string: ${t}`);const{provider:n,model:r}=Wr(t),s=Ln[n],o=Ac(n,e);let i;try{y.debug(`Importing package ${s.package}...`),i=await import(s.package)}catch(c){throw c?.code==="MODULE_NOT_FOUND"||c?.message?.includes("Cannot find module")||c?.message?.includes("Cannot find package")?new Error(`Package '${s.package}' is not installed. Install it with: npm install ${s.package} or yarn add ${s.package}`):new Error(`Failed to import ${s.package}: ${c?.message||c}`)}const a=i[s.className];if(!a)throw new Error(`Could not find ${s.className} in package ${s.package}. This might be a version compatibility issue.`);const l={model:r,apiKey:o,...e};e?.apiKey&&(delete l.apiKey,l.apiKey=o),(n==="anthropic"||n==="google"||n==="openai"||n==="groq")&&(l.model=r);try{const c=new a(l);return y.info(`Successfully created ${n} LLM with model ${r}`),c}catch(c){throw new Error(`Failed to instantiate ${s.className} with model '${r}': ${c?.message||c}`)}}R(jo,"createLLMFromString");function Ic(t){try{return Wr(t),!0}catch{return!1}}R(Ic,"isValidLLMString");function Pc(){return Object.keys(Ln)}R(Pc,"getSupportedProviders");function gr(t,e,n,r,s,o){if(typeof t=="object"&&t!==null){const i=t;return{query:i.prompt,maxSteps:i.maxSteps,manageConnector:i.manageConnector,externalHistory:i.externalHistory,outputSchema:i.schema,signal:i.signal}}return{query:t,maxSteps:e,manageConnector:n,externalHistory:r,outputSchema:s,signal:o}}R(gr,"normalizeRunOptions");var Zt,My=(Zt=class{static getPackageVersion(){return ji()}llm;client;connectors;maxSteps;autoInitialize;memoryEnabled;disallowedTools;additionalTools;toolsUsedNames=[];exposeResourcesAsTools=!0;exposePromptsAsTools=!0;useServerManager;verbose;observe;systemPrompt;systemPromptTemplateOverride;additionalInstructions;_initialized=!1;conversationHistory=[];_agentExecutor=null;sessions={};systemMessage=null;_tools=[];adapter;serverManager=null;telemetry;modelProvider;modelName;observabilityManager;callbacks=[];metadata={};tags=[];isRemote=!1;remoteAgent=null;isSimplifiedMode=!1;llmString;llmConfig;mcpServersConfig;clientOwnedByAgent=!1;constructor(e){if(e.agentId){this.isRemote=!0,this.remoteAgent=new Mc({agentId:e.agentId,apiKey:e.apiKey,baseUrl:e.baseUrl}),this.maxSteps=e.maxSteps??5,this.memoryEnabled=e.memoryEnabled??!0,this.autoInitialize=e.autoInitialize??!1,this.verbose=e.verbose??!1,this.observe=e.observe??!0,this.connectors=[],this.disallowedTools=[],this.additionalTools=[],this.useServerManager=!1,this.adapter=new Pt,this.telemetry=Xn.getInstance(),this.modelProvider="remote",this.modelName="remote-agent",this.observabilityManager=new Qs({customCallbacks:e.callbacks,agentId:e.agentId}),this.callbacks=[];return}if(!e.llm)throw new Error("llm is required for local execution. For remote execution, provide agentId instead.");if(typeof e.llm=="string"){if(this.isSimplifiedMode=!0,this.llmString=e.llm,this.llmConfig=e.llmConfig,this.mcpServersConfig=e.mcpServers,!this.mcpServersConfig||Object.keys(this.mcpServersConfig).length===0)throw new Error("Simplified mode requires 'mcpServers' configuration. Provide an object with server configurations, e.g., { filesystem: { command: 'npx', args: [...] } }");this.llm=void 0,this.client=void 0,this.clientOwnedByAgent=!0,this.connectors=[],y.info(`🎯 Simplified mode enabled: LLM will be created from '${this.llmString}'`)}else if(this.isSimplifiedMode=!1,this.llm=e.llm,this.client=e.client,this.connectors=e.connectors??[],this.clientOwnedByAgent=!1,!this.client&&this.connectors.length===0)throw new Error("Explicit mode requires either 'client' or at least one 'connector'. Alternatively, use simplified mode with 'llm' as a string and 'mcpServers' config.");if(this.maxSteps=e.maxSteps??5,this.autoInitialize=e.autoInitialize??!1,this.memoryEnabled=e.memoryEnabled??!0,this.systemPrompt=e.systemPrompt??null,this.systemPromptTemplateOverride=e.systemPromptTemplate??null,this.additionalInstructions=e.additionalInstructions??null,this.disallowedTools=e.disallowedTools??[],this.additionalTools=e.additionalTools??[],this.toolsUsedNames=e.toolsUsedNames??[],this.exposeResourcesAsTools=e.exposeResourcesAsTools??!0,this.exposePromptsAsTools=e.exposePromptsAsTools??!0,this.useServerManager=e.useServerManager??!1,this.verbose=e.verbose??!1,this.observe=e.observe??!0,this.isSimplifiedMode)this.adapter=e.adapter??new Pt(this.disallowedTools),this.telemetry=Xn.getInstance(),this.modelProvider="unknown",this.modelName="unknown";else{if(this.useServerManager){if(!this.client)throw new Error("'client' must be provided when 'useServerManager' is true.");this.adapter=e.adapter??new Pt(this.disallowedTools),this.serverManager=e.serverManagerFactory?.(this.client)??new Mi(this.client,this.adapter)}else this.adapter=e.adapter??new Pt(this.disallowedTools);if(this.telemetry=Xn.getInstance(),this.llm){const[r,s]=Bo(this.llm);this.modelProvider=r,this.modelName=s}else this.modelProvider="unknown",this.modelName="unknown"}this.observabilityManager=new Qs({customCallbacks:e.callbacks,verbose:this.verbose,observe:this.observe,agentId:e.agentId,metadataProvider:R(()=>this.getMetadata(),"metadataProvider"),tagsProvider:R(()=>this.getTags(),"tagsProvider")}),Object.defineProperty(this,"agentExecutor",{get:R(()=>this._agentExecutor,"get"),configurable:!0}),Object.defineProperty(this,"tools",{get:R(()=>this._tools,"get"),configurable:!0}),Object.defineProperty(this,"initialized",{get:R(()=>this._initialized,"get"),configurable:!0})}async initialize(){if(this.isRemote){this._initialized=!0;return}if(y.info("🚀 Initializing MCP agent and connecting to services..."),this.isSimplifiedMode){if(y.info("🎯 Simplified mode: Creating client and LLM from configuration..."),this.mcpServersConfig){y.info(`Creating MCPClient with ${Object.keys(this.mcpServersConfig).length} server(s)...`);const{MCPClient:r}=await Qt(async()=>{const{MCPClient:s}=await import("./client-S57RS52Z-D8i-S3XX.js").then(o=>o.c);return{MCPClient:s}},__vite__mapDeps([0,1,2]));this.client=new r({mcpServers:this.mcpServersConfig}),y.info("✅ MCPClient created successfully")}if(this.llmString){y.info(`Creating LLM from string: ${this.llmString}...`);try{this.llm=await jo(this.llmString,this.llmConfig),y.info("✅ LLM created successfully");const[r,s]=Bo(this.llm);this.modelProvider=r,this.modelName=s}catch(r){throw new Error(`Failed to create LLM from string '${this.llmString}': ${r?.message||r}`)}}if(this.useServerManager){if(!this.client)throw new Error("'client' must be available when 'useServerManager' is true.");this.serverManager=new Mi(this.client,this.adapter)}}this.callbacks=await this.observabilityManager.getCallbacks();const e=await this.observabilityManager.getHandlerNames();if(e.length>0&&y.info(`📊 Observability enabled with: ${e.join(", ")}`),this.useServerManager&&this.serverManager){await this.serverManager.initialize();const r=this.serverManager.tools;this._tools=r,this._tools.push(...this.additionalTools),y.info(`🔧 Server manager mode active with ${r.length} management tools`),await this.createSystemMessageFromTools(this._tools)}else{if(this.client){if(this.sessions=this.client.getAllActiveSessions(),y.info(`🔌 Found ${Object.keys(this.sessions).length} existing sessions`),Object.keys(this.sessions).filter(s=>s!=="code_mode").length===0&&(y.info("🔄 No active sessions found, creating new ones..."),this.sessions=await this.client.createAllSessions(),y.info(`✅ Created ${Object.keys(this.sessions).length} new sessions`)),this.client.codeMode){const s=this.sessions.code_mode;if(s)this._tools=await this.adapter.createToolsFromConnectors([s.connector]),y.info(`🛠️ Created ${this._tools.length} code mode tools`);else throw new Error("Code mode enabled but code_mode session not found")}else{const s=Object.values(this.sessions).map(l=>l.connector),o=await this.adapter.createToolsFromConnectors(s),i=this.exposeResourcesAsTools?await this.adapter.createResourcesFromConnectors(s):[],a=this.exposePromptsAsTools?await this.adapter.createPromptsFromConnectors(s):[];this._tools=[...o,...i,...a],y.info(`🛠️ Created ${this._tools.length} LangChain items from client: ${o.length} tools, ${i.length} resources, ${a.length} prompts`)}this._tools.push(...this.additionalTools)}else{y.info(`🔗 Connecting to ${this.connectors.length} direct connectors...`);for(const i of this.connectors)i.isClientConnected||await i.connect();const r=await this.adapter.createToolsFromConnectors(this.connectors),s=await this.adapter.createResourcesFromConnectors(this.connectors),o=await this.adapter.createPromptsFromConnectors(this.connectors);this._tools=[...r,...s,...o],this._tools.push(...this.additionalTools),y.info(`🛠️ Created ${this._tools.length} LangChain items from connectors: ${r.length} tools, ${s.length} resources, ${o.length} prompts`)}y.info(`🧰 Found ${this._tools.length} tools across all connectors`),await this.createSystemMessageFromTools(this._tools)}this._agentExecutor=this.createAgent(),this._initialized=!0;const n=this.getMCPServerInfo();Object.keys(n).length>0&&(this.setMetadata(n),y.debug(`MCP server info added to metadata: ${JSON.stringify(n)}`)),y.info("✨ Agent initialization complete")}async createSystemMessageFromTools(e){const n=this.systemPromptTemplateOverride??Ty;this.systemMessage=Ec(e,n,ky,this.useServerManager,this.disallowedTools,this.systemPrompt??void 0,this.additionalInstructions??void 0),this.memoryEnabled&&(this.conversationHistory=[this.systemMessage,...this.conversationHistory.filter(r=>!(r instanceof oe))])}createAgent(){if(!this.llm)throw new Error("LLM is required to create agent");const e=this.systemMessage?.content??"You are a helpful assistant.",n=this._tools.map(o=>o.name);y.info(`🧠 Agent ready with tools: ${n.join(", ")}`);const r=[bc({runLimit:this.maxSteps})],s=Ql({model:this.llm,tools:this._tools,systemPrompt:e,middleware:r});return y.debug(`Created agent with max_steps=${this.maxSteps} (via ModelCallLimitMiddleware) and ${this.callbacks.length} callbacks`),s}getConversationHistory(){return[...this.conversationHistory]}clearConversationHistory(){this.conversationHistory=this.memoryEnabled&&this.systemMessage?[this.systemMessage]:[]}addToHistory(e){this.memoryEnabled&&this.conversationHistory.push(e)}getSystemMessage(){return this.systemMessage}setSystemMessage(e){this.systemMessage=new oe(e),this.memoryEnabled&&(this.conversationHistory=this.conversationHistory.filter(n=>!(n instanceof oe)),this.conversationHistory.unshift(this.systemMessage)),this._initialized&&this._tools.length&&(this._agentExecutor=this.createAgent(),y.debug("Agent recreated with new system message"))}setDisallowedTools(e){this.disallowedTools=e,this.adapter=new Pt(this.disallowedTools),this._initialized&&y.debug("Agent already initialized. Changes will take effect on next initialization.")}getDisallowedTools(){return this.disallowedTools}setMetadata(e){const n=this.sanitizeMetadata(e);this.metadata={...this.metadata,...n},y.debug(`Metadata set: ${JSON.stringify(this.metadata)}`)}getMetadata(){return{...this.metadata}}setTags(e){const n=this.sanitizeTags(e);this.tags=[...new Set([...this.tags,...n])],y.debug(`Tags set: ${JSON.stringify(this.tags)}`)}getTags(){return[...this.tags]}sanitizeMetadata(e){const n={};for(const[r,s]of Object.entries(e)){if(typeof r!="string"||r.length===0){y.warn(`Invalid metadata key: ${r}. Skipping.`);continue}const o=r.replace(/[^\w-]/g,"_");if(s==null)n[o]=s;else if(typeof s=="string"||typeof s=="number"||typeof s=="boolean")n[o]=s;else if(Array.isArray(s)){const i=s.filter(a=>typeof a=="string"||typeof a=="number"||typeof a=="boolean");i.length>0&&(n[o]=i)}else if(typeof s=="object")try{const i=JSON.stringify(s);i.length>1e3?(y.warn(`Metadata value for key '${o}' is too large. Truncating.`),n[o]=`${i.substring(0,1e3)}...`):n[o]=s}catch(i){y.warn(`Failed to serialize metadata value for key '${o}': ${i}. Skipping.`)}else y.warn(`Unsupported metadata value type for key '${o}': ${typeof s}. Skipping.`)}return n}sanitizeTags(e){return e.filter(n=>typeof n=="string"&&n.length>0).map(n=>n.replace(/[^\w:-]/g,"_")).filter(n=>n.length<=50)}getMCPServerInfo(){const e={};try{if(this.client){const n=this.client.getServerNames();e.mcp_servers_count=n.length,e.mcp_server_names=n;const r={};for(const s of n)try{const o=this.client.getServerConfig(s);if(o){let i="unknown";o.command?i="command":o.url?i="http":o.ws_url&&(i="websocket"),r[s]={type:i,has_args:!!o.args,has_env:!!o.env,has_headers:!!o.headers,url:o.url||null,command:o.command||null}}}catch(o){y.warn(`Failed to get config for server '${s}': ${o}`),r[s]={type:"error",error:"config_unavailable"}}e.mcp_server_configs=r}else this.connectors&&this.connectors.length>0&&(e.mcp_servers_count=this.connectors.length,e.mcp_server_names=this.connectors.map(n=>n.publicIdentifier),e.mcp_server_types=this.connectors.map(n=>n.constructor.name))}catch(n){y.warn(`Failed to collect MCP server info: ${n}`),e.error="collection_failed"}return e}_normalizeOutput(e){try{if(typeof e=="string")return e;if(e&&typeof e=="object"&&"content"in e)return this._normalizeOutput(e.content);if(Array.isArray(e)){const n=[];for(const r of e)if(typeof r=="object"&&r!==null)"text"in r&&typeof r.text=="string"?n.push(r.text):"content"in r?n.push(this._normalizeOutput(r.content)):n.push(String(r));else{const s=r&&typeof r=="object"&&"text"in r?r.text:null;if(typeof s=="string")n.push(s);else{const o=r&&typeof r=="object"&&"content"in r?r.content:r;n.push(this._normalizeOutput(o))}}return n.join("")}return String(e)}catch{return String(e)}}_isAIMessageLike(e){if(e instanceof P)return!0;if(typeof e!="object"||e===null)return!1;const n=e;if(typeof n.getType=="function")try{const r=n.getType();if(r==="ai"||r==="assistant")return!0}catch{}if(typeof n._getType=="function")try{const r=n._getType();if(r==="ai"||r==="assistant")return!0}catch{}return"type"in n?n.type==="ai"||n.type==="assistant":"role"in n?n.role==="ai"||n.role==="assistant":!1}_messageHasToolCalls(e){return typeof e=="object"&&e!==null&&"tool_calls"in e&&Array.isArray(e.tool_calls)?e.tool_calls.length>0:!1}_isHumanMessageLike(e){if(e instanceof se)return!0;if(typeof e!="object"||e===null)return!1;const n=e;if(typeof n.getType=="function")try{const r=n.getType();if(r==="human"||r==="user")return!0}catch{}return"type"in n&&(n.type==="human"||n.type==="user")||"role"in n&&(n.role==="human"||n.role==="user")}_isToolMessageLike(e){if(e instanceof j)return!0;if(typeof e!="object"||e===null)return!1;const n=e;if(typeof n.getType=="function")try{if(n.getType()==="tool")return!0}catch{}return"type"in n&&n.type==="tool"}_getMessageContent(e){if(e instanceof P||e&&typeof e=="object"&&"content"in e)return e.content}async _consumeAndReturn(e){for(;;){const{done:n,value:r}=await e.next();if(n)return r}}async run(e,n,r,s,o,i){const{query:a,maxSteps:l,manageConnector:c,externalHistory:u,outputSchema:d,signal:h}=gr(e,n,r,s,o,i);if(this.isRemote&&this.remoteAgent)return this.remoteAgent.run(a,l,c,u,d);const f=this.stream(a,l,c,u,d,h);return this._consumeAndReturn(f)}async*stream(e,n,r=!0,s,o,i){const{query:a,maxSteps:l,manageConnector:c,externalHistory:u,outputSchema:d,signal:h}=gr(e,n,r,s,o,i);if(this.isRemote&&this.remoteAgent)return await this.remoteAgent.run(a,l,c,u,d);let f=!1;const m=Date.now();let p=!1,C=null,T=0;try{if(c&&!this._initialized?(await this.initialize(),f=!0):!this._initialized&&this.autoInitialize&&(await this.initialize(),f=!0),!this._agentExecutor)throw new Error("MCP agent failed to initialize");if(this.useServerManager&&this.serverManager){const b=this.serverManager.tools,E=new Set(b.map(x=>x.name)),S=new Set(this._tools.map(x=>x.name));(E.size!==S.size||[...E].some(x=>!S.has(x)))&&(y.info(`🔄 Tools changed before execution, updating agent. New tools: ${[...E].join(", ")}`),this._tools=b,this._tools.push(...this.additionalTools),await this.createSystemMessageFromTools(this._tools),this._agentExecutor=this.createAgent())}const k=u??this.conversationHistory,_=[];for(const b of k)(this._isHumanMessageLike(b)||this._isAIMessageLike(b)||this._isToolMessageLike(b))&&_.push(b);const g=a.length>50?`${a.slice(0,50).replace(/\n/g," ")}...`:a.replace(/\n/g," ");y.info(`💬 Received query: '${g}'`),y.info("🏁 Starting agent execution");const v=3;let M=0;const w=[..._,new se(a)];for(;M<=v;){const b={messages:w};let E=!1;const S=await this._agentExecutor.stream(b,{streamMode:"updates",callbacks:this.callbacks,metadata:this.getMetadata(),tags:this.getTags(),runName:this.metadata.trace_name||"mcp-use-agent",recursionLimit:this.maxSteps*3,...this.metadata.session_id&&{sessionId:this.metadata.session_id},...h&&{signal:h}});for await(const x of S){if(h?.aborted)break;for(const[I,O]of Object.entries(x))if(y.debug(`📦 Node '${I}' output: ${JSON.stringify(O)}`),O&&typeof O=="object"&&"messages"in O){let F=O.messages;Array.isArray(F)||(F=[F]);for(const ce of F)w.includes(ce)||w.push(ce);for(const ce of F){if("tool_calls"in ce&&Array.isArray(ce.tool_calls)&&ce.tool_calls.length>0)for(const Ie of ce.tool_calls){const we=Ie.name||"unknown",ht=Ie.args||{};this.toolsUsedNames.push(we),T++;let Je=JSON.stringify(ht);Je.length>100&&(Je=`${Je.slice(0,97)}...`),y.info(`🔧 Tool call: ${we} with input: ${Je}`),yield{action:{tool:we,toolInput:ht,log:`Calling tool ${we}`},observation:""}}if(this._isToolMessageLike(ce)){const Ie=ce.content;let we=String(Ie);if(we.length>100&&(we=`${we.slice(0,97)}...`),we=we.replace(/\n/g," "),y.info(`📄 Tool result: ${we}`),this.useServerManager&&this.serverManager){const ht=this.serverManager.tools,Je=new Set(ht.map(fn=>fn.name)),Lo=new Set(this._tools.map(fn=>fn.name));if(Je.size!==Lo.size||[...Je].some(fn=>!Lo.has(fn))){y.info(`🔄 Tools changed during execution. New tools: ${[...Je].join(", ")}`),this._tools=ht,this._tools.push(...this.additionalTools),await this.createSystemMessageFromTools(this._tools),this._agentExecutor=this.createAgent(),E=!0,M++,y.info(`🔃 Restarting execution with updated tools (restart ${M}/${v})`);break}}}this._isAIMessageLike(ce)&&!this._messageHasToolCalls(ce)&&(C=this._normalizeOutput(this._getMessageContent(ce)),y.info("✅ Agent finished with output"))}if(E)break}if(E)break}if(!E)break;if(M>v){y.warn(`⚠️ Max restarts (${v}) reached. Continuing with current tools.`);break}}if(this.memoryEnabled){const b=w.slice(_.length);for(const E of b)this.addToHistory(E)}if(d&&C)try{y.info("🔧 Attempting structured output...");const b=await this._attemptStructuredOutput(C,this.llm,d);return this.memoryEnabled&&this.addToHistory(new P(`Structured result: ${JSON.stringify(b)}`)),y.info("✅ Structured output successful"),p=!0,b}catch(b){throw y.error(`❌ Structured output failed: ${b}`),new Error(`Failed to generate structured output: ${b instanceof Error?b.message:String(b)}`)}return y.info(`🎉 Agent execution complete in ${((Date.now()-m)/1e3).toFixed(2)} seconds`),p=!0,C||"No output generated"}catch(k){throw y.error(`❌ Error running query: ${k}`),f&&c&&(y.info("🧹 Cleaning up resources after error"),await this.close()),k}finally{const k=Date.now()-m;let _=0;this.client?_=Object.keys(this.client.getAllActiveSessions()).length:this.connectors&&(_=this.connectors.length);const g=this.memoryEnabled?this.conversationHistory.length:0,v=this._tools||[];await this.telemetry.trackAgentExecution({executionMethod:"stream",query:a,success:p,modelProvider:this.modelProvider,modelName:this.modelName,serverCount:_,serverIdentifiers:this.connectors.map(M=>M.publicIdentifier),totalToolsAvailable:v.length,toolsAvailableNames:v.map(M=>M.name),maxStepsConfigured:this.maxSteps,memoryEnabled:this.memoryEnabled,useServerManager:this.useServerManager,maxStepsUsed:l??null,manageConnector:c??!0,externalHistoryUsed:u!==void 0,stepsTaken:T,toolsUsedCount:this.toolsUsedNames.length,toolsUsedNames:this.toolsUsedNames,response:C||"",executionTimeMs:k,errorType:p?null:"execution_error",conversationHistoryLength:g}),c&&!this.client&&f&&(y.info("🧹 Closing agent after stream completion"),await this.close())}}async flush(){this.isRemote&&this.remoteAgent||(y.debug("Flushing observability traces..."),await this.observabilityManager.flush())}async close(){if(this.isRemote&&this.remoteAgent){await this.remoteAgent.close();return}y.info("🔌 Closing MCPAgent resources…"),await this.observabilityManager.shutdown();try{if(this._agentExecutor=null,this._tools=[],this.client)this.clientOwnedByAgent?(y.info("🔄 Closing internally-created client (simplified mode) and cleaning up resources"),await this.client.close(),this.sessions={},this.client=void 0):(y.info("🔄 Closing client and cleaning up resources"),await this.client.close(),this.sessions={});else for(const e of this.connectors)y.info("🔄 Disconnecting connector"),await e.disconnect();this.isSimplifiedMode&&this.llm&&(y.debug("🔄 Clearing LLM reference (simplified mode)"),this.llm=void 0),"connectorToolMap"in this.adapter&&(this.adapter=new Pt)}finally{this._initialized=!1,y.info("👋 Agent closed successfully")}}async*prettyStreamEvents(e,n,r=!0,s,o){const{prettyStreamEvents:i}=await Qt(async()=>{const{prettyStreamEvents:l}=await import("./display-A5IEINAP-GZCoUyvv.js");return{prettyStreamEvents:l}},__vite__mapDeps([3,1,2])),a="";for await(const l of i(this.streamEvents(e,n,r,s,o)))yield;return a}async*streamEvents(e,n,r=!0,s,o,i){const a=gr(e,n,r,s,o,i);let{query:l}=a;const{maxSteps:c,manageConnector:u,externalHistory:d,outputSchema:h,signal:f}=a;let m=!1;const p=Date.now();let C=!1,T=0,k=0,_="";h&&(l=this._enhanceQueryWithSchema(l,h));try{u&&!this._initialized?(await this.initialize(),m=!0):!this._initialized&&this.autoInitialize&&(await this.initialize(),m=!0);const g=this._agentExecutor;if(!g)throw new Error("MCP agent failed to initialize");this.maxSteps=c??this.maxSteps;const v=typeof l=="string"&&l.length>50?`${l.slice(0,50).replace(/\n/g," ")}...`:typeof l=="string"?l.replace(/\n/g," "):String(l);y.info(`💬 Received query for streamEvents: '${v}'`),this.memoryEnabled&&(y.info(`🔄 Adding user message to history: ${v}`),this.addToHistory(new se({content:l})));const M=d??this.conversationHistory,w=[];for(const S of M)this._isHumanMessageLike(S)||this._isAIMessageLike(S)||this._isToolMessageLike(S)?w.push(S):y.info(`⚠️ Skipped message of type: ${S.constructor?.name||typeof S}`);const b=[...w,new se(l)];y.info("callbacks",this.callbacks);const E=g.streamEvents({messages:b},{streamMode:"messages",version:"v2",callbacks:this.callbacks,metadata:this.getMetadata(),tags:this.getTags(),runName:this.metadata.trace_name||"mcp-use-agent",recursionLimit:this.maxSteps*3,...this.metadata.session_id&&{sessionId:this.metadata.session_id},...f&&{signal:f}});for await(const S of E){if(f?.aborted)break;if(T++,!(!S||typeof S!="object")){if(S.event==="on_chat_model_stream"&&S.data?.chunk?.content&&(k+=S.data.chunk.content.length),S.event==="on_chat_model_stream"&&S.data?.chunk){const x=S.data.chunk;if(x.content){_||(_="");const I=this._normalizeOutput(x.content);_+=I,y.debug(`📝 Accumulated response length: ${_.length}`)}}if(yield S,S.event==="on_chain_end"&&S.data?.output&&!_){const x=S.data.output;Array.isArray(x)&&x.length>0&&x[0]?.text?_=x[0].text:typeof x=="string"?_=x:x&&typeof x=="object"&&"output"in x&&(_=x.output)}}}if(h&&_){y.info("🔧 Attempting structured output conversion...");try{let S=!1,x=null,I=null;this._attemptStructuredOutput(_,this.llm,h).then(F=>(S=!0,x=F,F)).catch(F=>{throw S=!0,I=F,F});let O=0;for(;!S;)await new Promise(F=>setTimeout(F,2e3)),S||(O++,yield{event:"on_structured_output_progress",data:{message:`Converting to structured output... (${O*2}s)`,elapsed:O*2}});if(I)throw I;x&&(yield{event:"on_structured_output",data:{output:x}},this.memoryEnabled&&this.addToHistory(new P(`Structured result: ${JSON.stringify(x)}`)),y.info("✅ Structured output successful"))}catch(S){y.warn(`⚠️ Structured output failed: ${S}`),yield{event:"on_structured_output_error",data:{error:S instanceof Error?S.message:String(S)}}}}else this.memoryEnabled&&_&&this.addToHistory(new P(_));console.log(`
|
|
386
|
+
Raw error: ${p}`)}return c?this.parseStructuredResponse(p,c):typeof p=="object"&&p!==null&&"result"in p?p.result:typeof p=="string"?p:String(p)}catch(u){throw u instanceof Error?u.name==="AbortError"?(y.error(`❌ Remote execution timed out: ${u}`),new Error("Remote agent execution timed out. The server may be overloaded or the query is taking too long to process. Try again or use a simpler query.")):(y.error(`❌ Remote execution error: ${u}`),new Error(`Remote agent execution failed: ${u.message}`)):(y.error(`❌ Remote execution error: ${u}`),new Error(`Remote agent execution failed: ${String(u)}`))}}async*stream(e,n,r,s,o){return await this.run(e,n,r,s,o)}async close(){y.info("🔌 Remote agent client closed")}},R(Xt,"RemoteAgent"),Xt),Ln={openai:{package:"@langchain/openai",className:"ChatOpenAI",envVars:["OPENAI_API_KEY"],defaultModel:"gpt-4o"},anthropic:{package:"@langchain/anthropic",className:"ChatAnthropic",envVars:["ANTHROPIC_API_KEY"],defaultModel:"claude-3-5-sonnet-20241022"},google:{package:"@langchain/google-genai",className:"ChatGoogleGenerativeAI",envVars:["GOOGLE_API_KEY","GOOGLE_GENERATIVE_AI_API_KEY"],defaultModel:"gemini-pro"},groq:{package:"@langchain/groq",className:"ChatGroq",envVars:["GROQ_API_KEY"],defaultModel:"llama-3.1-70b-versatile"}};function Wr(t){const e=t.split("/");if(e.length!==2)throw new Error(`Invalid LLM string format. Expected 'provider/model', got '${t}'. Examples: 'openai/gpt-4', 'anthropic/claude-3-5-sonnet-20241022', 'google/gemini-pro', 'groq/llama-3.1-70b-versatile'`);const[n,r]=e;if(!n||!r)throw new Error(`Invalid LLM string format. Both provider and model must be non-empty. Got '${t}'`);const s=n.toLowerCase();if(!(s in Ln)){const o=Object.keys(Ln).join(", ");throw new Error(`Unsupported LLM provider '${n}'. Supported providers: ${o}`)}return{provider:s,model:r}}R(Wr,"parseLLMString");function Ac(t,e){if(e?.apiKey)return e.apiKey;const n=Ln[t];if(typeof process<"u"&&Zs)for(const s of n.envVars){const o=Zs[s];if(o)return y.debug(`Using API key from environment variable ${s} for provider ${t}`),o}const r=n.envVars.join(" or ");throw new Error(`API key not found for provider '${t}'. Set ${r} environment variable or pass apiKey in llmConfig. Example: new MCPAgent({ llm: '${t}/model', llmConfig: { apiKey: 'your-key' } })`)}R(Ac,"getAPIKey");async function jo(t,e){y.info(`Creating LLM from string: ${t}`);const{provider:n,model:r}=Wr(t),s=Ln[n],o=Ac(n,e);let i;try{y.debug(`Importing package ${s.package}...`),i=await import(s.package)}catch(c){throw c?.code==="MODULE_NOT_FOUND"||c?.message?.includes("Cannot find module")||c?.message?.includes("Cannot find package")?new Error(`Package '${s.package}' is not installed. Install it with: npm install ${s.package} or yarn add ${s.package}`):new Error(`Failed to import ${s.package}: ${c?.message||c}`)}const a=i[s.className];if(!a)throw new Error(`Could not find ${s.className} in package ${s.package}. This might be a version compatibility issue.`);const l={model:r,apiKey:o,...e};e?.apiKey&&(delete l.apiKey,l.apiKey=o),(n==="anthropic"||n==="google"||n==="openai"||n==="groq")&&(l.model=r);try{const c=new a(l);return y.info(`Successfully created ${n} LLM with model ${r}`),c}catch(c){throw new Error(`Failed to instantiate ${s.className} with model '${r}': ${c?.message||c}`)}}R(jo,"createLLMFromString");function Ic(t){try{return Wr(t),!0}catch{return!1}}R(Ic,"isValidLLMString");function Pc(){return Object.keys(Ln)}R(Pc,"getSupportedProviders");function gr(t,e,n,r,s,o){if(typeof t=="object"&&t!==null){const i=t;return{query:i.prompt,maxSteps:i.maxSteps,manageConnector:i.manageConnector,externalHistory:i.externalHistory,outputSchema:i.schema,signal:i.signal}}return{query:t,maxSteps:e,manageConnector:n,externalHistory:r,outputSchema:s,signal:o}}R(gr,"normalizeRunOptions");var Zt,My=(Zt=class{static getPackageVersion(){return ji()}llm;client;connectors;maxSteps;autoInitialize;memoryEnabled;disallowedTools;additionalTools;toolsUsedNames=[];exposeResourcesAsTools=!0;exposePromptsAsTools=!0;useServerManager;verbose;observe;systemPrompt;systemPromptTemplateOverride;additionalInstructions;_initialized=!1;conversationHistory=[];_agentExecutor=null;sessions={};systemMessage=null;_tools=[];adapter;serverManager=null;telemetry;modelProvider;modelName;observabilityManager;callbacks=[];metadata={};tags=[];isRemote=!1;remoteAgent=null;isSimplifiedMode=!1;llmString;llmConfig;mcpServersConfig;clientOwnedByAgent=!1;constructor(e){if(e.agentId){this.isRemote=!0,this.remoteAgent=new Mc({agentId:e.agentId,apiKey:e.apiKey,baseUrl:e.baseUrl}),this.maxSteps=e.maxSteps??5,this.memoryEnabled=e.memoryEnabled??!0,this.autoInitialize=e.autoInitialize??!1,this.verbose=e.verbose??!1,this.observe=e.observe??!0,this.connectors=[],this.disallowedTools=[],this.additionalTools=[],this.useServerManager=!1,this.adapter=new Pt,this.telemetry=Xn.getInstance(),this.modelProvider="remote",this.modelName="remote-agent",this.observabilityManager=new Qs({customCallbacks:e.callbacks,agentId:e.agentId}),this.callbacks=[];return}if(!e.llm)throw new Error("llm is required for local execution. For remote execution, provide agentId instead.");if(typeof e.llm=="string"){if(this.isSimplifiedMode=!0,this.llmString=e.llm,this.llmConfig=e.llmConfig,this.mcpServersConfig=e.mcpServers,!this.mcpServersConfig||Object.keys(this.mcpServersConfig).length===0)throw new Error("Simplified mode requires 'mcpServers' configuration. Provide an object with server configurations, e.g., { filesystem: { command: 'npx', args: [...] } }");this.llm=void 0,this.client=void 0,this.clientOwnedByAgent=!0,this.connectors=[],y.info(`🎯 Simplified mode enabled: LLM will be created from '${this.llmString}'`)}else if(this.isSimplifiedMode=!1,this.llm=e.llm,this.client=e.client,this.connectors=e.connectors??[],this.clientOwnedByAgent=!1,!this.client&&this.connectors.length===0)throw new Error("Explicit mode requires either 'client' or at least one 'connector'. Alternatively, use simplified mode with 'llm' as a string and 'mcpServers' config.");if(this.maxSteps=e.maxSteps??5,this.autoInitialize=e.autoInitialize??!1,this.memoryEnabled=e.memoryEnabled??!0,this.systemPrompt=e.systemPrompt??null,this.systemPromptTemplateOverride=e.systemPromptTemplate??null,this.additionalInstructions=e.additionalInstructions??null,this.disallowedTools=e.disallowedTools??[],this.additionalTools=e.additionalTools??[],this.toolsUsedNames=e.toolsUsedNames??[],this.exposeResourcesAsTools=e.exposeResourcesAsTools??!0,this.exposePromptsAsTools=e.exposePromptsAsTools??!0,this.useServerManager=e.useServerManager??!1,this.verbose=e.verbose??!1,this.observe=e.observe??!0,this.isSimplifiedMode)this.adapter=e.adapter??new Pt(this.disallowedTools),this.telemetry=Xn.getInstance(),this.modelProvider="unknown",this.modelName="unknown";else{if(this.useServerManager){if(!this.client)throw new Error("'client' must be provided when 'useServerManager' is true.");this.adapter=e.adapter??new Pt(this.disallowedTools),this.serverManager=e.serverManagerFactory?.(this.client)??new Mi(this.client,this.adapter)}else this.adapter=e.adapter??new Pt(this.disallowedTools);if(this.telemetry=Xn.getInstance(),this.llm){const[r,s]=Bo(this.llm);this.modelProvider=r,this.modelName=s}else this.modelProvider="unknown",this.modelName="unknown"}this.observabilityManager=new Qs({customCallbacks:e.callbacks,verbose:this.verbose,observe:this.observe,agentId:e.agentId,metadataProvider:R(()=>this.getMetadata(),"metadataProvider"),tagsProvider:R(()=>this.getTags(),"tagsProvider")}),Object.defineProperty(this,"agentExecutor",{get:R(()=>this._agentExecutor,"get"),configurable:!0}),Object.defineProperty(this,"tools",{get:R(()=>this._tools,"get"),configurable:!0}),Object.defineProperty(this,"initialized",{get:R(()=>this._initialized,"get"),configurable:!0})}async initialize(){if(this.isRemote){this._initialized=!0;return}if(y.info("🚀 Initializing MCP agent and connecting to services..."),this.isSimplifiedMode){if(y.info("🎯 Simplified mode: Creating client and LLM from configuration..."),this.mcpServersConfig){y.info(`Creating MCPClient with ${Object.keys(this.mcpServersConfig).length} server(s)...`);const{MCPClient:r}=await Qt(async()=>{const{MCPClient:s}=await import("./client-AB7PHV6E-8__RED_q.js").then(o=>o.c);return{MCPClient:s}},__vite__mapDeps([0,1,2]));this.client=new r({mcpServers:this.mcpServersConfig}),y.info("✅ MCPClient created successfully")}if(this.llmString){y.info(`Creating LLM from string: ${this.llmString}...`);try{this.llm=await jo(this.llmString,this.llmConfig),y.info("✅ LLM created successfully");const[r,s]=Bo(this.llm);this.modelProvider=r,this.modelName=s}catch(r){throw new Error(`Failed to create LLM from string '${this.llmString}': ${r?.message||r}`)}}if(this.useServerManager){if(!this.client)throw new Error("'client' must be available when 'useServerManager' is true.");this.serverManager=new Mi(this.client,this.adapter)}}this.callbacks=await this.observabilityManager.getCallbacks();const e=await this.observabilityManager.getHandlerNames();if(e.length>0&&y.info(`📊 Observability enabled with: ${e.join(", ")}`),this.useServerManager&&this.serverManager){await this.serverManager.initialize();const r=this.serverManager.tools;this._tools=r,this._tools.push(...this.additionalTools),y.info(`🔧 Server manager mode active with ${r.length} management tools`),await this.createSystemMessageFromTools(this._tools)}else{if(this.client){if(this.sessions=this.client.getAllActiveSessions(),y.info(`🔌 Found ${Object.keys(this.sessions).length} existing sessions`),Object.keys(this.sessions).filter(s=>s!=="code_mode").length===0&&(y.info("🔄 No active sessions found, creating new ones..."),this.sessions=await this.client.createAllSessions(),y.info(`✅ Created ${Object.keys(this.sessions).length} new sessions`)),this.client.codeMode){const s=this.sessions.code_mode;if(s)this._tools=await this.adapter.createToolsFromConnectors([s.connector]),y.info(`🛠️ Created ${this._tools.length} code mode tools`);else throw new Error("Code mode enabled but code_mode session not found")}else{const s=Object.values(this.sessions).map(l=>l.connector),o=await this.adapter.createToolsFromConnectors(s),i=this.exposeResourcesAsTools?await this.adapter.createResourcesFromConnectors(s):[],a=this.exposePromptsAsTools?await this.adapter.createPromptsFromConnectors(s):[];this._tools=[...o,...i,...a],y.info(`🛠️ Created ${this._tools.length} LangChain items from client: ${o.length} tools, ${i.length} resources, ${a.length} prompts`)}this._tools.push(...this.additionalTools)}else{y.info(`🔗 Connecting to ${this.connectors.length} direct connectors...`);for(const i of this.connectors)i.isClientConnected||await i.connect();const r=await this.adapter.createToolsFromConnectors(this.connectors),s=await this.adapter.createResourcesFromConnectors(this.connectors),o=await this.adapter.createPromptsFromConnectors(this.connectors);this._tools=[...r,...s,...o],this._tools.push(...this.additionalTools),y.info(`🛠️ Created ${this._tools.length} LangChain items from connectors: ${r.length} tools, ${s.length} resources, ${o.length} prompts`)}y.info(`🧰 Found ${this._tools.length} tools across all connectors`),await this.createSystemMessageFromTools(this._tools)}this._agentExecutor=this.createAgent(),this._initialized=!0;const n=this.getMCPServerInfo();Object.keys(n).length>0&&(this.setMetadata(n),y.debug(`MCP server info added to metadata: ${JSON.stringify(n)}`)),y.info("✨ Agent initialization complete")}async createSystemMessageFromTools(e){const n=this.systemPromptTemplateOverride??Ty;this.systemMessage=Ec(e,n,ky,this.useServerManager,this.disallowedTools,this.systemPrompt??void 0,this.additionalInstructions??void 0),this.memoryEnabled&&(this.conversationHistory=[this.systemMessage,...this.conversationHistory.filter(r=>!(r instanceof oe))])}createAgent(){if(!this.llm)throw new Error("LLM is required to create agent");const e=this.systemMessage?.content??"You are a helpful assistant.",n=this._tools.map(o=>o.name);y.info(`🧠 Agent ready with tools: ${n.join(", ")}`);const r=[bc({runLimit:this.maxSteps})],s=Ql({model:this.llm,tools:this._tools,systemPrompt:e,middleware:r});return y.debug(`Created agent with max_steps=${this.maxSteps} (via ModelCallLimitMiddleware) and ${this.callbacks.length} callbacks`),s}getConversationHistory(){return[...this.conversationHistory]}clearConversationHistory(){this.conversationHistory=this.memoryEnabled&&this.systemMessage?[this.systemMessage]:[]}addToHistory(e){this.memoryEnabled&&this.conversationHistory.push(e)}getSystemMessage(){return this.systemMessage}setSystemMessage(e){this.systemMessage=new oe(e),this.memoryEnabled&&(this.conversationHistory=this.conversationHistory.filter(n=>!(n instanceof oe)),this.conversationHistory.unshift(this.systemMessage)),this._initialized&&this._tools.length&&(this._agentExecutor=this.createAgent(),y.debug("Agent recreated with new system message"))}setDisallowedTools(e){this.disallowedTools=e,this.adapter=new Pt(this.disallowedTools),this._initialized&&y.debug("Agent already initialized. Changes will take effect on next initialization.")}getDisallowedTools(){return this.disallowedTools}setMetadata(e){const n=this.sanitizeMetadata(e);this.metadata={...this.metadata,...n},y.debug(`Metadata set: ${JSON.stringify(this.metadata)}`)}getMetadata(){return{...this.metadata}}setTags(e){const n=this.sanitizeTags(e);this.tags=[...new Set([...this.tags,...n])],y.debug(`Tags set: ${JSON.stringify(this.tags)}`)}getTags(){return[...this.tags]}sanitizeMetadata(e){const n={};for(const[r,s]of Object.entries(e)){if(typeof r!="string"||r.length===0){y.warn(`Invalid metadata key: ${r}. Skipping.`);continue}const o=r.replace(/[^\w-]/g,"_");if(s==null)n[o]=s;else if(typeof s=="string"||typeof s=="number"||typeof s=="boolean")n[o]=s;else if(Array.isArray(s)){const i=s.filter(a=>typeof a=="string"||typeof a=="number"||typeof a=="boolean");i.length>0&&(n[o]=i)}else if(typeof s=="object")try{const i=JSON.stringify(s);i.length>1e3?(y.warn(`Metadata value for key '${o}' is too large. Truncating.`),n[o]=`${i.substring(0,1e3)}...`):n[o]=s}catch(i){y.warn(`Failed to serialize metadata value for key '${o}': ${i}. Skipping.`)}else y.warn(`Unsupported metadata value type for key '${o}': ${typeof s}. Skipping.`)}return n}sanitizeTags(e){return e.filter(n=>typeof n=="string"&&n.length>0).map(n=>n.replace(/[^\w:-]/g,"_")).filter(n=>n.length<=50)}getMCPServerInfo(){const e={};try{if(this.client){const n=this.client.getServerNames();e.mcp_servers_count=n.length,e.mcp_server_names=n;const r={};for(const s of n)try{const o=this.client.getServerConfig(s);if(o){let i="unknown";o.command?i="command":o.url?i="http":o.ws_url&&(i="websocket"),r[s]={type:i,has_args:!!o.args,has_env:!!o.env,has_headers:!!o.headers,url:o.url||null,command:o.command||null}}}catch(o){y.warn(`Failed to get config for server '${s}': ${o}`),r[s]={type:"error",error:"config_unavailable"}}e.mcp_server_configs=r}else this.connectors&&this.connectors.length>0&&(e.mcp_servers_count=this.connectors.length,e.mcp_server_names=this.connectors.map(n=>n.publicIdentifier),e.mcp_server_types=this.connectors.map(n=>n.constructor.name))}catch(n){y.warn(`Failed to collect MCP server info: ${n}`),e.error="collection_failed"}return e}_normalizeOutput(e){try{if(typeof e=="string")return e;if(e&&typeof e=="object"&&"content"in e)return this._normalizeOutput(e.content);if(Array.isArray(e)){const n=[];for(const r of e)if(typeof r=="object"&&r!==null)"text"in r&&typeof r.text=="string"?n.push(r.text):"content"in r?n.push(this._normalizeOutput(r.content)):n.push(String(r));else{const s=r&&typeof r=="object"&&"text"in r?r.text:null;if(typeof s=="string")n.push(s);else{const o=r&&typeof r=="object"&&"content"in r?r.content:r;n.push(this._normalizeOutput(o))}}return n.join("")}return String(e)}catch{return String(e)}}_isAIMessageLike(e){if(e instanceof P)return!0;if(typeof e!="object"||e===null)return!1;const n=e;if(typeof n.getType=="function")try{const r=n.getType();if(r==="ai"||r==="assistant")return!0}catch{}if(typeof n._getType=="function")try{const r=n._getType();if(r==="ai"||r==="assistant")return!0}catch{}return"type"in n?n.type==="ai"||n.type==="assistant":"role"in n?n.role==="ai"||n.role==="assistant":!1}_messageHasToolCalls(e){return typeof e=="object"&&e!==null&&"tool_calls"in e&&Array.isArray(e.tool_calls)?e.tool_calls.length>0:!1}_isHumanMessageLike(e){if(e instanceof se)return!0;if(typeof e!="object"||e===null)return!1;const n=e;if(typeof n.getType=="function")try{const r=n.getType();if(r==="human"||r==="user")return!0}catch{}return"type"in n&&(n.type==="human"||n.type==="user")||"role"in n&&(n.role==="human"||n.role==="user")}_isToolMessageLike(e){if(e instanceof j)return!0;if(typeof e!="object"||e===null)return!1;const n=e;if(typeof n.getType=="function")try{if(n.getType()==="tool")return!0}catch{}return"type"in n&&n.type==="tool"}_getMessageContent(e){if(e instanceof P||e&&typeof e=="object"&&"content"in e)return e.content}async _consumeAndReturn(e){for(;;){const{done:n,value:r}=await e.next();if(n)return r}}async run(e,n,r,s,o,i){const{query:a,maxSteps:l,manageConnector:c,externalHistory:u,outputSchema:d,signal:h}=gr(e,n,r,s,o,i);if(this.isRemote&&this.remoteAgent)return this.remoteAgent.run(a,l,c,u,d);const f=this.stream(a,l,c,u,d,h);return this._consumeAndReturn(f)}async*stream(e,n,r=!0,s,o,i){const{query:a,maxSteps:l,manageConnector:c,externalHistory:u,outputSchema:d,signal:h}=gr(e,n,r,s,o,i);if(this.isRemote&&this.remoteAgent)return await this.remoteAgent.run(a,l,c,u,d);let f=!1;const m=Date.now();let p=!1,C=null,T=0;try{if(c&&!this._initialized?(await this.initialize(),f=!0):!this._initialized&&this.autoInitialize&&(await this.initialize(),f=!0),!this._agentExecutor)throw new Error("MCP agent failed to initialize");if(this.useServerManager&&this.serverManager){const b=this.serverManager.tools,E=new Set(b.map(x=>x.name)),S=new Set(this._tools.map(x=>x.name));(E.size!==S.size||[...E].some(x=>!S.has(x)))&&(y.info(`🔄 Tools changed before execution, updating agent. New tools: ${[...E].join(", ")}`),this._tools=b,this._tools.push(...this.additionalTools),await this.createSystemMessageFromTools(this._tools),this._agentExecutor=this.createAgent())}const k=u??this.conversationHistory,_=[];for(const b of k)(this._isHumanMessageLike(b)||this._isAIMessageLike(b)||this._isToolMessageLike(b))&&_.push(b);const g=a.length>50?`${a.slice(0,50).replace(/\n/g," ")}...`:a.replace(/\n/g," ");y.info(`💬 Received query: '${g}'`),y.info("🏁 Starting agent execution");const v=3;let M=0;const w=[..._,new se(a)];for(;M<=v;){const b={messages:w};let E=!1;const S=await this._agentExecutor.stream(b,{streamMode:"updates",callbacks:this.callbacks,metadata:this.getMetadata(),tags:this.getTags(),runName:this.metadata.trace_name||"mcp-use-agent",recursionLimit:this.maxSteps*3,...this.metadata.session_id&&{sessionId:this.metadata.session_id},...h&&{signal:h}});for await(const x of S){if(h?.aborted)break;for(const[I,O]of Object.entries(x))if(y.debug(`📦 Node '${I}' output: ${JSON.stringify(O)}`),O&&typeof O=="object"&&"messages"in O){let F=O.messages;Array.isArray(F)||(F=[F]);for(const ce of F)w.includes(ce)||w.push(ce);for(const ce of F){if("tool_calls"in ce&&Array.isArray(ce.tool_calls)&&ce.tool_calls.length>0)for(const Ie of ce.tool_calls){const we=Ie.name||"unknown",ht=Ie.args||{};this.toolsUsedNames.push(we),T++;let Je=JSON.stringify(ht);Je.length>100&&(Je=`${Je.slice(0,97)}...`),y.info(`🔧 Tool call: ${we} with input: ${Je}`),yield{action:{tool:we,toolInput:ht,log:`Calling tool ${we}`},observation:""}}if(this._isToolMessageLike(ce)){const Ie=ce.content;let we=String(Ie);if(we.length>100&&(we=`${we.slice(0,97)}...`),we=we.replace(/\n/g," "),y.info(`📄 Tool result: ${we}`),this.useServerManager&&this.serverManager){const ht=this.serverManager.tools,Je=new Set(ht.map(fn=>fn.name)),Lo=new Set(this._tools.map(fn=>fn.name));if(Je.size!==Lo.size||[...Je].some(fn=>!Lo.has(fn))){y.info(`🔄 Tools changed during execution. New tools: ${[...Je].join(", ")}`),this._tools=ht,this._tools.push(...this.additionalTools),await this.createSystemMessageFromTools(this._tools),this._agentExecutor=this.createAgent(),E=!0,M++,y.info(`🔃 Restarting execution with updated tools (restart ${M}/${v})`);break}}}this._isAIMessageLike(ce)&&!this._messageHasToolCalls(ce)&&(C=this._normalizeOutput(this._getMessageContent(ce)),y.info("✅ Agent finished with output"))}if(E)break}if(E)break}if(!E)break;if(M>v){y.warn(`⚠️ Max restarts (${v}) reached. Continuing with current tools.`);break}}if(this.memoryEnabled){const b=w.slice(_.length);for(const E of b)this.addToHistory(E)}if(d&&C)try{y.info("🔧 Attempting structured output...");const b=await this._attemptStructuredOutput(C,this.llm,d);return this.memoryEnabled&&this.addToHistory(new P(`Structured result: ${JSON.stringify(b)}`)),y.info("✅ Structured output successful"),p=!0,b}catch(b){throw y.error(`❌ Structured output failed: ${b}`),new Error(`Failed to generate structured output: ${b instanceof Error?b.message:String(b)}`)}return y.info(`🎉 Agent execution complete in ${((Date.now()-m)/1e3).toFixed(2)} seconds`),p=!0,C||"No output generated"}catch(k){throw y.error(`❌ Error running query: ${k}`),f&&c&&(y.info("🧹 Cleaning up resources after error"),await this.close()),k}finally{const k=Date.now()-m;let _=0;this.client?_=Object.keys(this.client.getAllActiveSessions()).length:this.connectors&&(_=this.connectors.length);const g=this.memoryEnabled?this.conversationHistory.length:0,v=this._tools||[];await this.telemetry.trackAgentExecution({executionMethod:"stream",query:a,success:p,modelProvider:this.modelProvider,modelName:this.modelName,serverCount:_,serverIdentifiers:this.connectors.map(M=>M.publicIdentifier),totalToolsAvailable:v.length,toolsAvailableNames:v.map(M=>M.name),maxStepsConfigured:this.maxSteps,memoryEnabled:this.memoryEnabled,useServerManager:this.useServerManager,maxStepsUsed:l??null,manageConnector:c??!0,externalHistoryUsed:u!==void 0,stepsTaken:T,toolsUsedCount:this.toolsUsedNames.length,toolsUsedNames:this.toolsUsedNames,response:C||"",executionTimeMs:k,errorType:p?null:"execution_error",conversationHistoryLength:g}),c&&!this.client&&f&&(y.info("🧹 Closing agent after stream completion"),await this.close())}}async flush(){this.isRemote&&this.remoteAgent||(y.debug("Flushing observability traces..."),await this.observabilityManager.flush())}async close(){if(this.isRemote&&this.remoteAgent){await this.remoteAgent.close();return}y.info("🔌 Closing MCPAgent resources…"),await this.observabilityManager.shutdown();try{if(this._agentExecutor=null,this._tools=[],this.client)this.clientOwnedByAgent?(y.info("🔄 Closing internally-created client (simplified mode) and cleaning up resources"),await this.client.close(),this.sessions={},this.client=void 0):(y.info("🔄 Closing client and cleaning up resources"),await this.client.close(),this.sessions={});else for(const e of this.connectors)y.info("🔄 Disconnecting connector"),await e.disconnect();this.isSimplifiedMode&&this.llm&&(y.debug("🔄 Clearing LLM reference (simplified mode)"),this.llm=void 0),"connectorToolMap"in this.adapter&&(this.adapter=new Pt)}finally{this._initialized=!1,y.info("👋 Agent closed successfully")}}async*prettyStreamEvents(e,n,r=!0,s,o){const{prettyStreamEvents:i}=await Qt(async()=>{const{prettyStreamEvents:l}=await import("./display-A5IEINAP-BUlGvd6Q.js");return{prettyStreamEvents:l}},__vite__mapDeps([3,1,2])),a="";for await(const l of i(this.streamEvents(e,n,r,s,o)))yield;return a}async*streamEvents(e,n,r=!0,s,o,i){const a=gr(e,n,r,s,o,i);let{query:l}=a;const{maxSteps:c,manageConnector:u,externalHistory:d,outputSchema:h,signal:f}=a;let m=!1;const p=Date.now();let C=!1,T=0,k=0,_="";h&&(l=this._enhanceQueryWithSchema(l,h));try{u&&!this._initialized?(await this.initialize(),m=!0):!this._initialized&&this.autoInitialize&&(await this.initialize(),m=!0);const g=this._agentExecutor;if(!g)throw new Error("MCP agent failed to initialize");this.maxSteps=c??this.maxSteps;const v=typeof l=="string"&&l.length>50?`${l.slice(0,50).replace(/\n/g," ")}...`:typeof l=="string"?l.replace(/\n/g," "):String(l);y.info(`💬 Received query for streamEvents: '${v}'`),this.memoryEnabled&&(y.info(`🔄 Adding user message to history: ${v}`),this.addToHistory(new se({content:l})));const M=d??this.conversationHistory,w=[];for(const S of M)this._isHumanMessageLike(S)||this._isAIMessageLike(S)||this._isToolMessageLike(S)?w.push(S):y.info(`⚠️ Skipped message of type: ${S.constructor?.name||typeof S}`);const b=[...w,new se(l)];y.info("callbacks",this.callbacks);const E=g.streamEvents({messages:b},{streamMode:"messages",version:"v2",callbacks:this.callbacks,metadata:this.getMetadata(),tags:this.getTags(),runName:this.metadata.trace_name||"mcp-use-agent",recursionLimit:this.maxSteps*3,...this.metadata.session_id&&{sessionId:this.metadata.session_id},...f&&{signal:f}});for await(const S of E){if(f?.aborted)break;if(T++,!(!S||typeof S!="object")){if(S.event==="on_chat_model_stream"&&S.data?.chunk?.content&&(k+=S.data.chunk.content.length),S.event==="on_chat_model_stream"&&S.data?.chunk){const x=S.data.chunk;if(x.content){_||(_="");const I=this._normalizeOutput(x.content);_+=I,y.debug(`📝 Accumulated response length: ${_.length}`)}}if(yield S,S.event==="on_chain_end"&&S.data?.output&&!_){const x=S.data.output;Array.isArray(x)&&x.length>0&&x[0]?.text?_=x[0].text:typeof x=="string"?_=x:x&&typeof x=="object"&&"output"in x&&(_=x.output)}}}if(h&&_){y.info("🔧 Attempting structured output conversion...");try{let S=!1,x=null,I=null;this._attemptStructuredOutput(_,this.llm,h).then(F=>(S=!0,x=F,F)).catch(F=>{throw S=!0,I=F,F});let O=0;for(;!S;)await new Promise(F=>setTimeout(F,2e3)),S||(O++,yield{event:"on_structured_output_progress",data:{message:`Converting to structured output... (${O*2}s)`,elapsed:O*2}});if(I)throw I;x&&(yield{event:"on_structured_output",data:{output:x}},this.memoryEnabled&&this.addToHistory(new P(`Structured result: ${JSON.stringify(x)}`)),y.info("✅ Structured output successful"))}catch(S){y.warn(`⚠️ Structured output failed: ${S}`),yield{event:"on_structured_output_error",data:{error:S instanceof Error?S.message:String(S)}}}}else this.memoryEnabled&&_&&this.addToHistory(new P(_));console.log(`
|
|
387
387
|
|
|
388
388
|
`),y.info(`🎉 StreamEvents complete - ${T} events emitted`),C=!0}catch(g){throw y.error(`❌ Error during streamEvents: ${g}`),m&&u&&(y.info("🧹 Cleaning up resources after initialization error in streamEvents"),await this.close()),g}finally{const g=Date.now()-p;let v=0;this.client?v=Object.keys(this.client.getAllActiveSessions()).length:this.connectors&&(v=this.connectors.length);const M=this.memoryEnabled?this.conversationHistory.length:0;await this.telemetry.trackAgentExecution({executionMethod:"streamEvents",query:l,success:C,modelProvider:this.modelProvider,modelName:this.modelName,serverCount:v,serverIdentifiers:this.connectors.map(w=>w.publicIdentifier),totalToolsAvailable:this._tools.length,toolsAvailableNames:this._tools.map(w=>w.name),maxStepsConfigured:this.maxSteps,memoryEnabled:this.memoryEnabled,useServerManager:this.useServerManager,maxStepsUsed:c??null,manageConnector:u??!0,externalHistoryUsed:d!==void 0,response:`[STREAMED RESPONSE - ${k} chars]`,executionTimeMs:g,errorType:C?null:"streaming_error",conversationHistoryLength:M}),u&&!this.client&&m&&(y.info("🧹 Closing agent after streamEvents completion"),await this.close())}}async _attemptStructuredOutput(e,n,r){y.info(`🔄 Attempting structured output with schema: ${JSON.stringify(r,null,2)}`),y.info(`🔄 Raw result: ${JSON.stringify(e,null,2)}`);let s=null,o="";if(y.debug(`🔄 Structured output requested, schema: ${JSON.stringify(Zn(r),null,2)}`),n&&"withStructuredOutput"in n&&typeof n.withStructuredOutput=="function")s=n.withStructuredOutput(r);else if(n)s=n;else throw new Error("LLM is required for structured output");const i=Zn(r),{$schema:a,additionalProperties:l,...c}=i;o=JSON.stringify(c,null,2),y.info(`🔄 Schema description: ${o}`);let u="";typeof e=="string"?u=e:e&&typeof e=="object"&&(u=JSON.stringify(e)),y.info("rawResult",e),u||(u=JSON.stringify(e));const d=3;let h="";for(let f=1;f<=d;f++){y.info(`🔄 Structured output attempt ${f}/${d}`);let m=`
|
|
389
389
|
Please format the following information according to the EXACT schema specified below.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as f}from"./index-
|
|
1
|
+
import{r as f}from"./index-PReApu5D.js";import{r as l}from"./lasso-BciudTQ1.js";function i(t,a){for(var o=0;o<a.length;o++){const e=a[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const s=Object.getOwnPropertyDescriptor(e,r);s&&Object.defineProperty(t,r,s.get?s:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var n=l();const c=f(n),g=i({__proto__:null,default:c},[n]);export{g as l};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as s}from"./index-
|
|
1
|
+
import{r as s}from"./index-PReApu5D.js";import{r as l}from"./latex-CHdb8PhR.js";function i(r,n){for(var o=0;o<n.length;o++){const e=n[o];if(typeof e!="string"&&!Array.isArray(e)){for(const t in e)if(t!=="default"&&!(t in r)){const a=Object.getOwnPropertyDescriptor(e,t);a&&Object.defineProperty(r,t,a.get?a:{enumerable:!0,get:()=>e[t]})}}}return Object.freeze(Object.defineProperty(r,Symbol.toStringTag,{value:"Module"}))}var f=l();const c=s(f),g=i({__proto__:null,default:c},[f]);export{g as l};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as a}from"./index-
|
|
1
|
+
import{r as a}from"./index-PReApu5D.js";import{r as s}from"./ldif-jBEfafs_.js";function l(t,i){for(var o=0;o<i.length;o++){const e=i[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const f=Object.getOwnPropertyDescriptor(e,r);f&&Object.defineProperty(t,r,f.get?f:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var n=s();const c=a(n),d=l({__proto__:null,default:c},[n]);export{d as l};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as s}from"./index-
|
|
1
|
+
import{r as s}from"./index-PReApu5D.js";import{r as l}from"./leaf-CQphRTnn.js";function i(t,f){for(var o=0;o<f.length;o++){const e=f[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const a=Object.getOwnPropertyDescriptor(e,r);a&&Object.defineProperty(t,r,a.get?a:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var n=l();const c=s(n),g=i({__proto__:null,default:c},[n]);export{g as l};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as f}from"./index-
|
|
1
|
+
import{r as f}from"./index-PReApu5D.js";import{r as l}from"./less-D0Ccux41.js";function i(t,n){for(var o=0;o<n.length;o++){const e=n[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const s=Object.getOwnPropertyDescriptor(e,r);s&&Object.defineProperty(t,r,s.get?s:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var a=l();const c=f(a),g=i({__proto__:null,default:c},[a]);export{g as l};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as p}from"./index-
|
|
1
|
+
import{r as p}from"./index-PReApu5D.js";import{r as a}from"./lisp-DfrNO5te.js";function f(t,i){for(var o=0;o<i.length;o++){const e=i[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const s=Object.getOwnPropertyDescriptor(e,r);s&&Object.defineProperty(t,r,s.get?s:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var n=a();const l=p(n),g=f({__proto__:null,default:l},[n]);export{g as l};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as n}from"./index-
|
|
1
|
+
import{r as n}from"./index-PReApu5D.js";import{r as a}from"./livecodeserver-WU_wnUq8.js";function f(t,i){for(var o=0;o<i.length;o++){const e=i[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const s=Object.getOwnPropertyDescriptor(e,r);s&&Object.defineProperty(t,r,s.get?s:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var c=a();const l=n(c),v=f({__proto__:null,default:l},[c]);export{v as l};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as n}from"./index-
|
|
1
|
+
import{r as n}from"./index-PReApu5D.js";import{r as p}from"./livescript-oQhn4lAX.js";function a(t,s){for(var o=0;o<s.length;o++){const e=s[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const i=Object.getOwnPropertyDescriptor(e,r);i&&Object.defineProperty(t,r,i.get?i:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var c=p();const f=n(c),g=a({__proto__:null,default:f},[c]);export{g as l};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{x as O,y as M,z as R,n as b,C as L,G as N,B as x,D as J,R as P}from"./index-
|
|
1
|
+
import{x as O,y as M,z as R,n as b,C as L,G as N,B as x,D as J,R as P}from"./index-PReApu5D.js";import{O as k,d as E,e as T}from"./index-BGGQsG8S.js";function C(n,e){if(n.function===void 0)return;let t;if(e?.partial)try{t=R(n.function.arguments??"{}")}catch{return}else try{t=JSON.parse(n.function.arguments)}catch(r){throw new k([`Function "${n.function.name}" arguments:`,"",n.function.arguments,"","are not valid JSON.",`Error: ${r.message}`].join(`
|
|
2
2
|
`))}const s={name:n.function.name,args:t,type:"tool_call"};return e?.returnId&&(s.id=n.id),s}function z(n){if(n.id===void 0)throw new Error('All OpenAI tool calls must have an "id" field.');return{id:n.id,type:"function",function:{name:n.name,arguments:JSON.stringify(n.args)}}}function A(n,e){return{name:n.function?.name,args:n.function?.arguments,id:n.id,error:e,type:"invalid_tool_call"}}var S=class extends E{static lc_name(){return"JsonOutputToolsParser"}returnId=!1;lc_namespace=["langchain","output_parsers","openai_tools"];lc_serializable=!0;constructor(n){super(n),this.returnId=n?.returnId??this.returnId}_diff(){throw new Error("Not supported.")}async parse(){throw new Error("Not implemented.")}async parseResult(n){return await this.parsePartialResult(n,!1)}async parsePartialResult(n,e=!0){const t=n[0].message;let s;if(M(t)&&t.tool_calls?.length?s=t.tool_calls.map(a=>{const{id:l,...u}=a;return this.returnId?{id:l,...u}:u}):t.additional_kwargs.tool_calls!==void 0&&(s=JSON.parse(JSON.stringify(t.additional_kwargs.tool_calls)).map(l=>C(l,{returnId:this.returnId,partial:e}))),!s)return[];const r=[];for(const a of s)if(a!==void 0){const l={type:a.name,args:a.args,id:a.id};r.push(l)}return r}},B=class extends S{static lc_name(){return"JsonOutputKeyToolsParser"}lc_namespace=["langchain","output_parsers","openai_tools"];lc_serializable=!0;returnId=!1;keyName;returnSingle=!1;zodSchema;constructor(n){super(n),this.keyName=n.keyName,this.returnSingle=n.returnSingle??this.returnSingle,this.zodSchema=n.zodSchema}async _validateResult(n){if(this.zodSchema===void 0)return n;const e=await O(this.zodSchema,n);if(e.success)return e.data;throw new k(`Failed to parse. Text: "${JSON.stringify(n,null,2)}". Error: ${JSON.stringify(e.error?.issues)}`,JSON.stringify(n,null,2))}async parsePartialResult(n){const t=(await super.parsePartialResult(n)).filter(r=>r.type===this.keyName);let s=t;if(t.length)return this.returnId||(s=t.map(r=>r.args)),this.returnSingle?s[0]:s}async parseResult(n){const t=(await super.parsePartialResult(n,!1)).filter(a=>a.type===this.keyName);let s=t;return t.length?(this.returnId||(s=t.map(a=>a.args)),this.returnSingle?this._validateResult(s[0]):await Promise.all(s.map(a=>this._validateResult(a)))):void 0}},F={};b(F,{JsonOutputKeyToolsParser:()=>B,JsonOutputToolsParser:()=>S,convertLangChainToolCallToOpenAI:()=>z,makeInvalidToolCall:()=>A,parseToolCall:()=>C});var K={};b(K,{BaseLLM:()=>I,LLM:()=>U});var I=class f extends T{lc_namespace=["langchain","llms",this._llmType()];async invoke(e,t){const s=f._convertInputToPromptValue(e);return(await this.generatePrompt([s],t,t?.callbacks)).generations[0][0].text}async*_streamResponseChunks(e,t,s){throw new Error("Not implemented.")}_separateRunnableConfigFromCallOptionsCompat(e){const[t,s]=super._separateRunnableConfigFromCallOptions(e);return s.signal=t.signal,[t,s]}async*_streamIterator(e,t){if(this._streamResponseChunks===f.prototype._streamResponseChunks)yield this.invoke(e,t);else{const s=f._convertInputToPromptValue(e),[r,a]=this._separateRunnableConfigFromCallOptionsCompat(t),l=await L.configure(r.callbacks,this.callbacks,r.tags,this.tags,r.metadata,this.metadata,{verbose:this.verbose}),u={options:a,invocation_params:this?.invocationParams(a),batch_size:1},h=await l?.handleLLMStart(this.toJSON(),[s.toString()],r.runId,void 0,u,void 0,void 0,r.runName);let o=new N({text:""});try{for await(const i of this._streamResponseChunks(s.toString(),a,h?.[0]))o?o=o.concat(i):o=i,typeof i.text=="string"&&(yield i.text)}catch(i){throw await Promise.all((h??[]).map(d=>d?.handleLLMError(i))),i}await Promise.all((h??[]).map(i=>i?.handleLLMEnd({generations:[[o]]})))}}async generatePrompt(e,t,s){const r=e.map(a=>a.toString());return this.generate(r,t,s)}invocationParams(e){return{}}_flattenLLMResult(e){const t=[];for(let s=0;s<e.generations.length;s+=1){const r=e.generations[s];if(s===0)t.push({generations:[r],llmOutput:e.llmOutput});else{const a=e.llmOutput?{...e.llmOutput,tokenUsage:{}}:void 0;t.push({generations:[r],llmOutput:a})}}return t}async _generateUncached(e,t,s,r){let a;if(r!==void 0&&r.length===e.length)a=r;else{const o=await L.configure(s.callbacks,this.callbacks,s.tags,this.tags,s.metadata,this.metadata,{verbose:this.verbose}),i={options:t,invocation_params:this?.invocationParams(t),batch_size:e.length};a=await o?.handleLLMStart(this.toJSON(),e,s.runId,void 0,i,void 0,void 0,s?.runName)}const l=!!a?.[0].handlers.find(x);let u;if(l&&e.length===1&&this._streamResponseChunks!==f.prototype._streamResponseChunks)try{const o=await this._streamResponseChunks(e[0],t,a?.[0]);let i;for await(const d of o)i===void 0?i=d:i=J(i,d);if(i===void 0)throw new Error("Received empty response from chat model call.");u={generations:[[i]],llmOutput:{}},await a?.[0].handleLLMEnd(u)}catch(o){throw await a?.[0].handleLLMError(o),o}else{try{u=await this._generate(e,t,a?.[0])}catch(i){throw await Promise.all((a??[]).map(d=>d?.handleLLMError(i))),i}const o=this._flattenLLMResult(u);await Promise.all((a??[]).map((i,d)=>i?.handleLLMEnd(o[d])))}const h=a?.map(o=>o.runId)||void 0;return Object.defineProperty(u,P,{value:h?{runIds:h}:void 0,configurable:!0}),u}async _generateCached({prompts:e,cache:t,llmStringKey:s,parsedOptions:r,handledOptions:a,runId:l}){const u=await L.configure(a.callbacks,this.callbacks,a.tags,this.tags,a.metadata,this.metadata,{verbose:this.verbose}),h={options:r,invocation_params:this?.invocationParams(r),batch_size:e.length},o=await u?.handleLLMStart(this.toJSON(),e,l,void 0,h,void 0,void 0,a?.runName),i=[],v=(await Promise.allSettled(e.map(async(c,m)=>{const _=await t.lookup(c,s);return _==null&&i.push(m),_}))).map((c,m)=>({result:c,runManager:o?.[m]})).filter(({result:c})=>c.status==="fulfilled"&&c.value!=null||c.status==="rejected"),p=[];await Promise.all(v.map(async({result:c,runManager:m},_)=>{if(c.status==="fulfilled"){const y=c.value;return p[_]=y.map(w=>(w.generationInfo={...w.generationInfo,tokenUsage:{}},w)),y.length&&await m?.handleLLMNewToken(y[0].text),m?.handleLLMEnd({generations:[y]},void 0,void 0,void 0,{cached:!0})}else return await m?.handleLLMError(c.reason,void 0,void 0,void 0,{cached:!0}),Promise.reject(c.reason)}));const g={generations:p,missingPromptIndices:i,startedRunManagers:o};return Object.defineProperty(g,P,{value:o?{runIds:o?.map(c=>c.runId)}:void 0,configurable:!0}),g}async generate(e,t,s){if(!Array.isArray(e))throw new Error("Argument 'prompts' is expected to be a string[]");let r;Array.isArray(t)?r={stop:t}:r=t;const[a,l]=this._separateRunnableConfigFromCallOptionsCompat(r);if(a.callbacks=a.callbacks??s,!this.cache)return this._generateUncached(e,l,a);const{cache:u}=this,h=this._getSerializedCacheKeyParametersForCall(l),{generations:o,missingPromptIndices:i,startedRunManagers:d}=await this._generateCached({prompts:e,cache:u,llmStringKey:h,parsedOptions:l,handledOptions:a,runId:a.runId});let v={};if(i.length>0){const p=await this._generateUncached(i.map(g=>e[g]),l,a,d!==void 0?i.map(g=>d?.[g]):void 0);await Promise.all(p.generations.map(async(g,c)=>{const m=i[c];return o[m]=g,u.update(e[m],h,g)})),v=p.llmOutput??{}}return{generations:o,llmOutput:v}}_identifyingParams(){return{}}_modelType(){return"base_llm"}},U=class extends I{async _generate(n,e,t){return{generations:await Promise.all(n.map((r,a)=>this._call(r,{...e,promptIndex:a},t).then(l=>[{text:l}])))}}};export{I as B,B as J,U as L,z as c,K as l,A as m,F as o,C as p};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as f}from"./index-
|
|
1
|
+
import{r as f}from"./index-PReApu5D.js";import{r as s}from"./llvm-Ctq8Ea1M.js";function i(t,n){for(var o=0;o<n.length;o++){const e=n[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const l=Object.getOwnPropertyDescriptor(e,r);l&&Object.defineProperty(t,r,l.get?l:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var a=s();const c=f(a),u=i({__proto__:null,default:c},[a]);export{u as l};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as a}from"./index-
|
|
1
|
+
import{r as a}from"./index-PReApu5D.js";import{r as f}from"./lsl-CZ-92Osz.js";function i(t,l){for(var o=0;o<l.length;o++){const e=l[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const s=Object.getOwnPropertyDescriptor(e,r);s&&Object.defineProperty(t,r,s.get?s:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var n=f();const c=a(n),g=i({__proto__:null,default:c},[n]);export{g as l};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as s}from"./index-
|
|
1
|
+
import{r as s}from"./index-PReApu5D.js";import{r as u}from"./lua-CtuzIFQ2.js";function l(t,n){for(var o=0;o<n.length;o++){const e=n[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const a=Object.getOwnPropertyDescriptor(e,r);a&&Object.defineProperty(t,r,a.get?a:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var f=u();const i=s(f),g=l({__proto__:null,default:i},[f]);export{g as l};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as n}from"./index-
|
|
1
|
+
import{r as n}from"./index-PReApu5D.js";import{r as s}from"./makefile-CUBjRDBz.js";function l(t,f){for(var o=0;o<f.length;o++){const e=f[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const a=Object.getOwnPropertyDescriptor(e,r);a&&Object.defineProperty(t,r,a.get?a:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var i=s();const c=n(i),u=l({__proto__:null,default:c},[i]);export{u as m};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as s}from"./index-
|
|
1
|
+
import{r as s}from"./index-PReApu5D.js";import{r as i}from"./markdown-Bnpjmjdr.js";function c(t,a){for(var o=0;o<a.length;o++){const r=a[o];if(typeof r!="string"&&!Array.isArray(r)){for(const e in r)if(e!=="default"&&!(e in t)){const n=Object.getOwnPropertyDescriptor(r,e);n&&Object.defineProperty(t,e,n.get?n:{enumerable:!0,get:()=>r[e]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var f=i();const m=s(f),d=c({__proto__:null,default:m},[f]);export{d as m};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as m}from"./index-
|
|
1
|
+
import{r as m}from"./index-PReApu5D.js";import{r as n}from"./mathematica-DMjmGOFL.js";function f(r,i){for(var a=0;a<i.length;a++){const e=i[a];if(typeof e!="string"&&!Array.isArray(e)){for(const t in e)if(t!=="default"&&!(t in r)){const o=Object.getOwnPropertyDescriptor(e,t);o&&Object.defineProperty(r,t,o.get?o:{enumerable:!0,get:()=>e[t]})}}}return Object.freeze(Object.defineProperty(r,Symbol.toStringTag,{value:"Module"}))}var c=n();const s=m(c),l=f({__proto__:null,default:s},[c]);export{l as m};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as s}from"./index-
|
|
1
|
+
import{r as s}from"./index-PReApu5D.js";import{r as l}from"./matlab-bMP2hmJA.js";function i(r,n){for(var o=0;o<n.length;o++){const e=n[o];if(typeof e!="string"&&!Array.isArray(e)){for(const t in e)if(t!=="default"&&!(t in r)){const a=Object.getOwnPropertyDescriptor(e,t);a&&Object.defineProperty(r,t,a.get?a:{enumerable:!0,get:()=>e[t]})}}}return Object.freeze(Object.defineProperty(r,Symbol.toStringTag,{value:"Module"}))}var f=l();const c=s(f),u=i({__proto__:null,default:c},[f]);export{u as m};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as n}from"./index-
|
|
1
|
+
import{r as n}from"./index-PReApu5D.js";import{r as f}from"./maxima-CiGgQtRy.js";function s(t,i){for(var o=0;o<i.length;o++){const e=i[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const a=Object.getOwnPropertyDescriptor(e,r);a&&Object.defineProperty(t,r,a.get?a:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var m=f();const c=n(m),l=s({__proto__:null,default:c},[m]);export{l as m};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as s}from"./index-
|
|
1
|
+
import{r as s}from"./index-PReApu5D.js";import{r as l}from"./mel-BKEdQ-Ac.js";function i(t,a){for(var o=0;o<a.length;o++){const e=a[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const n=Object.getOwnPropertyDescriptor(e,r);n&&Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var f=l();const c=s(f),u=i({__proto__:null,default:c},[f]);export{u as m};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as f}from"./index-
|
|
1
|
+
import{r as f}from"./index-PReApu5D.js";import{r as s}from"./mercury-Cg7tRNfI.js";function u(t,n){for(var o=0;o<n.length;o++){const r=n[o];if(typeof r!="string"&&!Array.isArray(r)){for(const e in r)if(e!=="default"&&!(e in t)){const c=Object.getOwnPropertyDescriptor(r,e);c&&Object.defineProperty(t,e,c.get?c:{enumerable:!0,get:()=>r[e]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var a=s();const i=f(a),y=u({__proto__:null,default:i},[a]);export{y as m};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as m}from"./index-
|
|
1
|
+
import{r as m}from"./index-PReApu5D.js";import{r as n}from"./mipsasm-CNyeTk3S.js";function p(t,a){for(var o=0;o<a.length;o++){const e=a[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const s=Object.getOwnPropertyDescriptor(e,r);s&&Object.defineProperty(t,r,s.get?s:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var i=n();const f=m(i),l=p({__proto__:null,default:f},[i]);export{l as m};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as f}from"./index-
|
|
1
|
+
import{r as f}from"./index-PReApu5D.js";import{r as s}from"./mizar-BICf15Zj.js";function c(t,i){for(var o=0;o<i.length;o++){const r=i[o];if(typeof r!="string"&&!Array.isArray(r)){for(const e in r)if(e!=="default"&&!(e in t)){const a=Object.getOwnPropertyDescriptor(r,e);a&&Object.defineProperty(t,e,a.get?a:{enumerable:!0,get:()=>r[e]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var n=s();const m=f(n),l=c({__proto__:null,default:m},[n]);export{l as m};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as n}from"./index-
|
|
1
|
+
import{r as n}from"./index-PReApu5D.js";import{r as a}from"./mojolicious-DiD_1YV0.js";function f(r,s){for(var t=0;t<s.length;t++){const e=s[t];if(typeof e!="string"&&!Array.isArray(e)){for(const o in e)if(o!=="default"&&!(o in r)){const i=Object.getOwnPropertyDescriptor(e,o);i&&Object.defineProperty(r,o,i.get?i:{enumerable:!0,get:()=>e[o]})}}}return Object.freeze(Object.defineProperty(r,Symbol.toStringTag,{value:"Module"}))}var c=a();const u=n(c),p=f({__proto__:null,default:u},[c]);export{p as m};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as s}from"./index-
|
|
1
|
+
import{r as s}from"./index-PReApu5D.js";import{r as i}from"./monkey-D6kono4g.js";function c(t,a){for(var o=0;o<a.length;o++){const e=a[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const n=Object.getOwnPropertyDescriptor(e,r);n&&Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var f=i();const m=s(f),y=c({__proto__:null,default:m},[f]);export{y as m};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as c}from"./index-
|
|
1
|
+
import{r as c}from"./index-PReApu5D.js";import{r as p}from"./moonscript-Ba-Tqbk8.js";function a(t,s){for(var o=0;o<s.length;o++){const r=s[o];if(typeof r!="string"&&!Array.isArray(r)){for(const e in r)if(e!=="default"&&!(e in t)){const n=Object.getOwnPropertyDescriptor(r,e);n&&Object.defineProperty(t,e,n.get?n:{enumerable:!0,get:()=>r[e]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var i=p();const f=c(i),l=a({__proto__:null,default:f},[i]);export{l as m};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as s}from"./index-
|
|
1
|
+
import{r as s}from"./index-PReApu5D.js";import{r as l}from"./n1ql-AxtiJSd2.js";function i(t,a){for(var o=0;o<a.length;o++){const e=a[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const n=Object.getOwnPropertyDescriptor(e,r);n&&Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var f=l();const c=s(f),g=i({__proto__:null,default:c},[f]);export{g as n};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as f}from"./index-
|
|
1
|
+
import{r as f}from"./index-PReApu5D.js";import{r as s}from"./nginx-DwELR1Kc.js";function g(t,i){for(var o=0;o<i.length;o++){const e=i[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const n=Object.getOwnPropertyDescriptor(e,r);n&&Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var a=s();const c=f(a),l=g({__proto__:null,default:c},[a]);export{l as n};
|