@xpert-ai/chatkit-ui 0.3.12 → 0.3.13
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/app/assets/{_baseUniq-IKp1Qtyx.js → _baseUniq-CvONysm3.js} +1 -1
- package/dist/app/assets/{abap-C7CFWD5V.js → abap-D0PmjeYp.js} +1 -1
- package/dist/app/assets/{abnf-DMBTOEVk.js → abnf-BOKaYw8z.js} +1 -1
- package/dist/app/assets/{actionscript-BcEvaXWq.js → actionscript-oedcs05j.js} +1 -1
- package/dist/app/assets/{ada-CjD42KJL.js → ada-DTslPS_X.js} +1 -1
- package/dist/app/assets/{agda-Bcj2WXF1.js → agda-DyIPFvgY.js} +1 -1
- package/dist/app/assets/{al-CMk7bc_L.js → al-JhNzL42i.js} +1 -1
- package/dist/app/assets/{antlr4-mV0cIoyX.js → antlr4-C-0Ut0bd.js} +1 -1
- package/dist/app/assets/{apacheconf-DN4T9Q-R.js → apacheconf-EFdrrvMh.js} +1 -1
- package/dist/app/assets/{apex-3WQ3SwvB.js → apex-BK1Yi3gT.js} +1 -1
- package/dist/app/assets/{apl-kyDsC9Hx.js → apl-CHOws7Yd.js} +1 -1
- package/dist/app/assets/{applescript-Bs98Sq0b.js → applescript-CaZLRm7r.js} +1 -1
- package/dist/app/assets/{aql-BAbWlxCN.js → aql-BjEOqP5L.js} +1 -1
- package/dist/app/assets/{arc-EIoofq4L.js → arc-BMasGuP9.js} +1 -1
- package/dist/app/assets/{architectureDiagram-Q4EWVU46-DtyblCvt.js → architectureDiagram-Q4EWVU46-B6eAqAul.js} +1 -1
- package/dist/app/assets/{arduino-DrkFmhPG.js → arduino-DR77CmPb.js} +1 -1
- package/dist/app/assets/{arff-COd-UaSA.js → arff-Cq42nzUN.js} +1 -1
- package/dist/app/assets/{asciidoc-D0TlSE1p.js → asciidoc-D8n9IYex.js} +1 -1
- package/dist/app/assets/{asm6502-DBgU992u.js → asm6502-B6bHtPuY.js} +1 -1
- package/dist/app/assets/{asmatmel-DoAdyDdX.js → asmatmel-CooszWWJ.js} +1 -1
- package/dist/app/assets/{aspnet-DbKj2Y0x.js → aspnet-CX0-h1MZ.js} +1 -1
- package/dist/app/assets/{autohotkey-BKpl02dF.js → autohotkey-CHtIhjCF.js} +1 -1
- package/dist/app/assets/{autoit-nvDMUiIR.js → autoit-DcksqFoK.js} +1 -1
- package/dist/app/assets/{avisynth-zdcS6mIk.js → avisynth-CtsFuCNj.js} +1 -1
- package/dist/app/assets/{avro-idl-Bz9IAA6X.js → avro-idl-BNfYi2Dh.js} +1 -1
- package/dist/app/assets/{bash-Bzch0sET.js → bash-3S4c0WHd.js} +1 -1
- package/dist/app/assets/{basic-u-yPBVQX.js → basic-_uhMDh0B.js} +1 -1
- package/dist/app/assets/{batch-Due3vTON.js → batch-C_-ETunx.js} +1 -1
- package/dist/app/assets/{bbcode-B7eqvAzk.js → bbcode-Ba0czJNb.js} +1 -1
- package/dist/app/assets/{bicep-BfgsVHBJ.js → bicep-By_QuI3J.js} +1 -1
- package/dist/app/assets/{birb-BSK9o8wp.js → birb-D5W_4t7e.js} +1 -1
- package/dist/app/assets/{bison-DzmILaWc.js → bison-Dtt2PWL_.js} +1 -1
- package/dist/app/assets/{blockDiagram-DXYQGD6D-4q0Z69yb.js → blockDiagram-DXYQGD6D-lg_Jl28M.js} +1 -1
- package/dist/app/assets/{bnf-CTxrvOa_.js → bnf-DQe8pZVg.js} +1 -1
- package/dist/app/assets/{brainfuck-B2x0y1yE.js → brainfuck-BIYXJ7sN.js} +1 -1
- package/dist/app/assets/{brightscript-B1YuuA1a.js → brightscript-BBCeseWd.js} +1 -1
- package/dist/app/assets/{bro-qJvkUxuW.js → bro-Dyt8VOvH.js} +1 -1
- package/dist/app/assets/{bsl-D717dB3Z.js → bsl-Cy-qTbmy.js} +1 -1
- package/dist/app/assets/{c-eAvYogDo.js → c-B9t9Sy6r.js} +1 -1
- package/dist/app/assets/{c4Diagram-AHTNJAMY-8Ls7e8MM.js → c4Diagram-AHTNJAMY-HamHya8d.js} +1 -1
- package/dist/app/assets/{cfscript-Po8jLzf2.js → cfscript-B7tkoim0.js} +1 -1
- package/dist/app/assets/{chaiscript-DQ0kVVD1.js → chaiscript-BXsoW5BE.js} +1 -1
- package/dist/app/assets/channel-BsY2pq9p.js +1 -0
- package/dist/app/assets/{chunk-4BX2VUAB-aVXDopSe.js → chunk-4BX2VUAB-bFSsv7Ln.js} +1 -1
- package/dist/app/assets/{chunk-4TB4RGXK-B4i0WSGT.js → chunk-4TB4RGXK-Cdsd7ZCo.js} +1 -1
- package/dist/app/assets/{chunk-55IACEB6-CDWG5f9m.js → chunk-55IACEB6-ZTsQ3wyw.js} +1 -1
- package/dist/app/assets/{chunk-EDXVE4YY-DhPmwrgR.js → chunk-EDXVE4YY-isVJYuaP.js} +1 -1
- package/dist/app/assets/{chunk-FMBD7UC4-Bst2lua5.js → chunk-FMBD7UC4-C63-DQH9.js} +1 -1
- package/dist/app/assets/{chunk-OYMX7WX6-B3OQzz_w.js → chunk-OYMX7WX6-BTttzFGm.js} +1 -1
- package/dist/app/assets/{chunk-QZHKN3VN-rnQWX_CM.js → chunk-QZHKN3VN-CDwAyIOt.js} +1 -1
- package/dist/app/assets/{chunk-YZCP3GAM-0SoL9M8l.js → chunk-YZCP3GAM-Bx3_k3Zo.js} +1 -1
- package/dist/app/assets/{cil-DWCFx6mz.js → cil-BLTa56Y5.js} +1 -1
- package/dist/app/assets/classDiagram-6PBFFD2Q-DpJB1PZu.js +1 -0
- package/dist/app/assets/classDiagram-v2-HSJHXN6E-DpJB1PZu.js +1 -0
- package/dist/app/assets/{clike-B6raVGdU.js → clike-BIDFl0fT.js} +1 -1
- package/dist/app/assets/{clojure-DKI51Ecz.js → clojure-Dpd5h1BA.js} +1 -1
- package/dist/app/assets/clone-CiMLCRAd.js +1 -0
- package/dist/app/assets/{cmake-CwwQf097.js → cmake-DjUqp9u8.js} +1 -1
- package/dist/app/assets/{cobol-BixlHzvP.js → cobol-Dgx17sMr.js} +1 -1
- package/dist/app/assets/{coffeescript-DzMKx8Wm.js → coffeescript-B9wL5-Va.js} +1 -1
- package/dist/app/assets/{concurnas-CeI1_l2A.js → concurnas-mF1tuHyA.js} +1 -1
- package/dist/app/assets/{coq-Rlyk5JPF.js → coq-RHagnzin.js} +1 -1
- package/dist/app/assets/{core-CKaxhIxn.js → core-DCCJ-C0q.js} +1 -1
- package/dist/app/assets/{cose-bilkent-S5V4N54A-BEbmBjkM.js → cose-bilkent-S5V4N54A-Cb0_atLY.js} +1 -1
- package/dist/app/assets/{cpp-D6N2YRS8.js → cpp-DTIt5dAl.js} +1 -1
- package/dist/app/assets/{crystal-Bp-ZOMp9.js → crystal-DVA5GCDX.js} +1 -1
- package/dist/app/assets/{csharp-73XQRtra.js → csharp-NOj19G2H.js} +1 -1
- package/dist/app/assets/{cshtml-_Kw38cMM.js → cshtml-CD3z7IxG.js} +1 -1
- package/dist/app/assets/{csp-CWKQ7qNy.js → csp-jVwEgPNj.js} +1 -1
- package/dist/app/assets/{css-CSf4crh0.js → css-aJF3Q48Q.js} +1 -1
- package/dist/app/assets/{css-extras-BPFlTbKM.js → css-extras-C-U4h-Z3.js} +1 -1
- package/dist/app/assets/{csv-NdIdVmit.js → csv-B3FtP7a3.js} +1 -1
- package/dist/app/assets/{cypher-DrG3lvrT.js → cypher-Jelt7i1F.js} +1 -1
- package/dist/app/assets/{d-Byk2LV83.js → d-ijfOZ2or.js} +1 -1
- package/dist/app/assets/{dagre-KV5264BT-DONbK4nc.js → dagre-KV5264BT-DF_s1Fnc.js} +1 -1
- package/dist/app/assets/{dart-DAvsdDA3.js → dart-CTYpy6Bc.js} +1 -1
- package/dist/app/assets/{dataweave-C5T6xtfv.js → dataweave-D1exHB4s.js} +1 -1
- package/dist/app/assets/{dax-DoH9pkog.js → dax-JqPdegf6.js} +1 -1
- package/dist/app/assets/{dhall-DJpQKYes.js → dhall-DLi-OuCE.js} +1 -1
- package/dist/app/assets/{diagram-5BDNPKRD-cVSMcLwH.js → diagram-5BDNPKRD-C7H0RboA.js} +1 -1
- package/dist/app/assets/{diagram-G4DWMVQ6-B5QE6o4T.js → diagram-G4DWMVQ6-CMdy8B-k.js} +1 -1
- package/dist/app/assets/{diagram-MMDJMWI5-DIWNtwBR.js → diagram-MMDJMWI5-Dkb4OujG.js} +1 -1
- package/dist/app/assets/{diagram-TYMM5635-rMAqc1qj.js → diagram-TYMM5635-C6nwxn_A.js} +1 -1
- package/dist/app/assets/{diff-DvrdG0n8.js → diff-BT54-KV8.js} +1 -1
- package/dist/app/assets/{django-DEQbld8i.js → django-RAer7vZH.js} +1 -1
- package/dist/app/assets/{dns-zone-file-BADAi43M.js → dns-zone-file-Ctz907jU.js} +1 -1
- package/dist/app/assets/{docker-BbNeQOxZ.js → docker-DQMF0Heg.js} +1 -1
- package/dist/app/assets/{dot-Bmy4l5j8.js → dot-DRM01oM7.js} +1 -1
- package/dist/app/assets/{ebnf-B0QE6nnN.js → ebnf-BoXaxGMy.js} +1 -1
- package/dist/app/assets/{editorconfig-Bg3JR5OT.js → editorconfig-COefETIr.js} +1 -1
- package/dist/app/assets/{eiffel-CYMSvYtO.js → eiffel-DtiXpw62.js} +1 -1
- package/dist/app/assets/{ejs-CP1oTchE.js → ejs-CPjGZkv_.js} +1 -1
- package/dist/app/assets/{elixir-Di3D46jy.js → elixir-DoBN8UeH.js} +1 -1
- package/dist/app/assets/{elm-DS1CidFy.js → elm-B62i2ybA.js} +1 -1
- package/dist/app/assets/{erDiagram-SMLLAGMA-DmA9X2aB.js → erDiagram-SMLLAGMA-B4OO8MsP.js} +1 -1
- package/dist/app/assets/{erb-MTRWz0CC.js → erb-C9ckQs5i.js} +1 -1
- package/dist/app/assets/{erlang-C0EhPwsW.js → erlang-DrTNnJnm.js} +1 -1
- package/dist/app/assets/{etlua-DrTwkJv_.js → etlua-B9YWlzUb.js} +1 -1
- package/dist/app/assets/{excel-formula-BUY1j-dw.js → excel-formula-C2YGQfQt.js} +1 -1
- package/dist/app/assets/{factor-BawUE8xG.js → factor-CQEBDNb2.js} +1 -1
- package/dist/app/assets/{false-BoDMLPv-.js → false-aj0fVJxM.js} +1 -1
- package/dist/app/assets/{firestore-security-rules-CWXxe34f.js → firestore-security-rules-CDG1Fy4c.js} +1 -1
- package/dist/app/assets/{flow-l-oHCDfx.js → flow-DpfOp8Q1.js} +1 -1
- package/dist/app/assets/{flowDiagram-DWJPFMVM-Bf7CgR6O.js → flowDiagram-DWJPFMVM-dKziAkNZ.js} +1 -1
- package/dist/app/assets/{fortran-DbfhBm3h.js → fortran-B6dEgcNp.js} +1 -1
- package/dist/app/assets/{fsharp-C_xG7_2F.js → fsharp-CKzEOQJi.js} +1 -1
- package/dist/app/assets/{ftl-BOmP6dqU.js → ftl-0jDsA_YP.js} +1 -1
- package/dist/app/assets/{ganttDiagram-T4ZO3ILL-Bg6Tdt0n.js → ganttDiagram-T4ZO3ILL-CxPsDkXF.js} +1 -1
- package/dist/app/assets/{gap-CHKm_uiw.js → gap-DDX0qjW3.js} +1 -1
- package/dist/app/assets/{gcode-vLqAglHa.js → gcode-BpIri7up.js} +1 -1
- package/dist/app/assets/{gdscript-vbRU5enn.js → gdscript-C04N9JVO.js} +1 -1
- package/dist/app/assets/{gedcom-D0cr82OU.js → gedcom-DvtepZde.js} +1 -1
- package/dist/app/assets/{gherkin-CdrJEioP.js → gherkin-BsAX23_T.js} +1 -1
- package/dist/app/assets/{git-BpYfHv6w.js → git-CJNx4Xo6.js} +1 -1
- package/dist/app/assets/{gitGraphDiagram-UUTBAWPF-DpeozhsT.js → gitGraphDiagram-UUTBAWPF-DiSvgj0u.js} +1 -1
- package/dist/app/assets/{glsl-C1mqMYtZ.js → glsl-D-54R-AO.js} +1 -1
- package/dist/app/assets/{gml-MmP8j1JT.js → gml-B0X-Mxkw.js} +1 -1
- package/dist/app/assets/{gn-vbr8Ezf8.js → gn-CWmpfEaG.js} +1 -1
- package/dist/app/assets/{go-D6TPbDdE.js → go-C_2hF6ro.js} +1 -1
- package/dist/app/assets/{go-module-DfKcZOwK.js → go-module-vMtGZodQ.js} +1 -1
- package/dist/app/assets/{graph-CUTA2u9Q.js → graph-Cq9YMAYz.js} +1 -1
- package/dist/app/assets/{graphql-mqzCl3PN.js → graphql-DrrIeY06.js} +1 -1
- package/dist/app/assets/{groovy-ClYqnFm5.js → groovy-BMn_67fe.js} +1 -1
- package/dist/app/assets/{haml-BxHbXcYR.js → haml-Ci-7VFqq.js} +1 -1
- package/dist/app/assets/{handlebars-v6nReoI-.js → handlebars-BJlC_vgB.js} +1 -1
- package/dist/app/assets/{haskell-DzKP2Bsc.js → haskell-Bfe0YQeZ.js} +1 -1
- package/dist/app/assets/{haxe-DevMcR_Z.js → haxe-BHjIvHwX.js} +1 -1
- package/dist/app/assets/{hcl-C5Bj9s3r.js → hcl-oPGkwxVh.js} +1 -1
- package/dist/app/assets/{hlsl-FNmun_i2.js → hlsl-KfasWwmv.js} +1 -1
- package/dist/app/assets/{hoon-Cn8qSAYQ.js → hoon-OBQG5VLk.js} +1 -1
- package/dist/app/assets/{hpkp-x-6CfFYy.js → hpkp-zyYCSn0s.js} +1 -1
- package/dist/app/assets/{hsts-DTMvA9jI.js → hsts-BMBBwqU0.js} +1 -1
- package/dist/app/assets/{http-repyLWTd.js → http-CCSDlbLo.js} +1 -1
- package/dist/app/assets/{ichigojam-DVrOBI5W.js → ichigojam-DdhQX3SK.js} +1 -1
- package/dist/app/assets/{icon-CFEy7hhK.js → icon-B7p5YPMg.js} +1 -1
- package/dist/app/assets/{icu-message-format-Bs8z8Pa8.js → icu-message-format-UOBEOoHS.js} +1 -1
- package/dist/app/assets/{idris-B4dKajLi.js → idris-CdhiOKCO.js} +1 -1
- package/dist/app/assets/{iecst-C8tB6F6o.js → iecst-DXPMKwX6.js} +1 -1
- package/dist/app/assets/{ignore-BSV7EeW4.js → ignore-BVa755Kc.js} +1 -1
- package/dist/app/assets/index-BEJfqOrB.js +754 -0
- package/dist/app/assets/index-CtZ-BBEn.css +1 -0
- package/dist/app/assets/{infoDiagram-42DDH7IO-C3qc42CB.js → infoDiagram-42DDH7IO-BB_Um6R6.js} +1 -1
- package/dist/app/assets/{inform7-DrAKK55g.js → inform7-mq-OIbmJ.js} +1 -1
- package/dist/app/assets/{ini-u8YQIiOq.js → ini-BXIIaxsj.js} +1 -1
- package/dist/app/assets/{io-BF3U_13f.js → io-CkhJ-e49.js} +1 -1
- package/dist/app/assets/{ishikawaDiagram-UXIWVN3A-DZFv5qUJ.js → ishikawaDiagram-UXIWVN3A-BNzRWQMS.js} +1 -1
- package/dist/app/assets/{j-CCimMXhx.js → j-C0CAN9XN.js} +1 -1
- package/dist/app/assets/{java-DO5fViyr.js → java-CgSYFksp.js} +1 -1
- package/dist/app/assets/{javadoc-DDpss0Lm.js → javadoc-BmBI86rZ.js} +1 -1
- package/dist/app/assets/{javadoclike-DU0tWt01.js → javadoclike-D4vqwJX5.js} +1 -1
- package/dist/app/assets/{javascript-DdjszwTa.js → javascript-CC8_K6vT.js} +1 -1
- package/dist/app/assets/{javastacktrace-6TqNjdk7.js → javastacktrace-B0T5_L5h.js} +1 -1
- package/dist/app/assets/{jexl-D8MtdYvR.js → jexl-BzBj2ekh.js} +1 -1
- package/dist/app/assets/{jolie-CocTJfsD.js → jolie-PcQu5Qal.js} +1 -1
- package/dist/app/assets/{journeyDiagram-VCZTEJTY-BJFWqXvt.js → journeyDiagram-VCZTEJTY-YbGxquTC.js} +1 -1
- package/dist/app/assets/{jq-BLep2RPL.js → jq-BIlSIJBC.js} +1 -1
- package/dist/app/assets/{js-extras-DQHOpmR6.js → js-extras-CrkjSQXw.js} +1 -1
- package/dist/app/assets/{js-templates-C8bgfiAI.js → js-templates-BdsRT61p.js} +1 -1
- package/dist/app/assets/{jsdoc-CTXb0QBN.js → jsdoc-BGPbyhWt.js} +1 -1
- package/dist/app/assets/{json-MXhid-40.js → json-C8O9rn_F.js} +1 -1
- package/dist/app/assets/{json5-BBNk0TrK.js → json5-DNnHL8bJ.js} +1 -1
- package/dist/app/assets/{jsonp-B8GEZBkI.js → jsonp-CBoW4Wzv.js} +1 -1
- package/dist/app/assets/{jsstacktrace-pvIKS4Zv.js → jsstacktrace-YRTCG2qE.js} +1 -1
- package/dist/app/assets/{jsx-BR_PTydE.js → jsx-Cvmg8Qc0.js} +1 -1
- package/dist/app/assets/{julia-Cm4xtp32.js → julia-C6GEw5Kx.js} +1 -1
- package/dist/app/assets/{kanban-definition-6JOO6SKY-BG9atDzG.js → kanban-definition-6JOO6SKY-Dlqu8obb.js} +1 -1
- package/dist/app/assets/{keepalived-DS091xJp.js → keepalived-D2mav9II.js} +1 -1
- package/dist/app/assets/{keyman-Cq3rg_OW.js → keyman-DDZgfq0u.js} +1 -1
- package/dist/app/assets/{kotlin-Dj8rHKDk.js → kotlin-CrYc_wtA.js} +1 -1
- package/dist/app/assets/{kumir-CnspAIaB.js → kumir-B_VS6AVj.js} +1 -1
- package/dist/app/assets/{kusto-B_M8_-iN.js → kusto-CP_9UovW.js} +1 -1
- package/dist/app/assets/{latex-h_1mu4rU.js → latex-QgAbXGsS.js} +1 -1
- package/dist/app/assets/{latte-DRruVMVR.js → latte-DUpGulNe.js} +1 -1
- package/dist/app/assets/{layout-C4Y-_UhZ.js → layout-BTwqxbTv.js} +1 -1
- package/dist/app/assets/{less-BkBKGybJ.js → less-BLrdBrWF.js} +1 -1
- package/dist/app/assets/{lilypond-tpptDbXf.js → lilypond-BDTzAMhd.js} +1 -1
- package/dist/app/assets/{linear-LRhlJwR0.js → linear-DkWSa105.js} +1 -1
- package/dist/app/assets/{liquid-BYEdjQlm.js → liquid-Dy291YjU.js} +1 -1
- package/dist/app/assets/{lisp-UYdnBUFJ.js → lisp-BfnyURQK.js} +1 -1
- package/dist/app/assets/{livescript-C9yax0KM.js → livescript-CDMj4WP6.js} +1 -1
- package/dist/app/assets/{llvm-2LUJOlxq.js → llvm-CQPEUNLB.js} +1 -1
- package/dist/app/assets/{log-DKjvz3ho.js → log-DS0VJgjd.js} +1 -1
- package/dist/app/assets/{lolcode-CLsVUU7R.js → lolcode-B2MbftYe.js} +1 -1
- package/dist/app/assets/{lua-G_BZKE8Q.js → lua-C-7j_5ne.js} +1 -1
- package/dist/app/assets/{magma-lCuEwSEu.js → magma-BBFpD5aY.js} +1 -1
- package/dist/app/assets/{makefile-CuurcFXN.js → makefile-CzEmFT7o.js} +1 -1
- package/dist/app/assets/{markdown-D8twlx64.js → markdown-BLlnxB-K.js} +1 -1
- package/dist/app/assets/{markup-CPx0l2_m.js → markup-D7eCVjbF.js} +1 -1
- package/dist/app/assets/{markup-templating-1SLH6Zrr.js → markup-templating-8Z6sScHe.js} +1 -1
- package/dist/app/assets/{matlab-DiXiMdVf.js → matlab-uhLBPgTB.js} +1 -1
- package/dist/app/assets/{maxscript-CR5B3kzO.js → maxscript-Bkndg0OF.js} +1 -1
- package/dist/app/assets/{mel-4XG8ApRx.js → mel-By4Q6ZsA.js} +1 -1
- package/dist/app/assets/{mermaid-Dg_Z96Py.js → mermaid-CbChcMmC.js} +1 -1
- package/dist/app/assets/{min-ZF6tgODw.js → min-5A3EmlAd.js} +1 -1
- package/dist/app/assets/{mindmap-definition-QFDTVHPH-XatWoYUC.js → mindmap-definition-QFDTVHPH-BzbhOcGv.js} +1 -1
- package/dist/app/assets/{mizar-D7LfXPjH.js → mizar-Boa07XhI.js} +1 -1
- package/dist/app/assets/{mongodb-BT27iI7P.js → mongodb-Dx1noqnV.js} +1 -1
- package/dist/app/assets/{monkey-CHo4ln4E.js → monkey-BeXPWhV3.js} +1 -1
- package/dist/app/assets/{moonscript-yAsABvFl.js → moonscript-1thH6xrI.js} +1 -1
- package/dist/app/assets/{n1ql-CVjJ8k0G.js → n1ql-BulKbT01.js} +1 -1
- package/dist/app/assets/{n4js-BpnXK7uO.js → n4js-BOzYMeOt.js} +1 -1
- package/dist/app/assets/{nand2tetris-hdl-DZIcttnF.js → nand2tetris-hdl-BIyeRQVK.js} +1 -1
- package/dist/app/assets/{naniscript-BjdWmpbq.js → naniscript-CAfgrASy.js} +1 -1
- package/dist/app/assets/{nasm-tTGUS43W.js → nasm-pf-h63vT.js} +1 -1
- package/dist/app/assets/{neon-Cm0NipU3.js → neon-x4Rgd4bZ.js} +1 -1
- package/dist/app/assets/{nevod-CAvas20G.js → nevod-Cdc3uw7C.js} +1 -1
- package/dist/app/assets/{nginx-BG78NxdZ.js → nginx-BTHrB1wh.js} +1 -1
- package/dist/app/assets/{nim-vMSiqOYt.js → nim-CM1DVIbF.js} +1 -1
- package/dist/app/assets/{nix-PeXWRdgp.js → nix-BPK2kQ5C.js} +1 -1
- package/dist/app/assets/{nsis-Bx4jjgkI.js → nsis-CRyjntvc.js} +1 -1
- package/dist/app/assets/{objectivec-Xc1Oxea3.js → objectivec-CDDtF0zH.js} +1 -1
- package/dist/app/assets/{ocaml-CETJbxfK.js → ocaml-DZcit9Vn.js} +1 -1
- package/dist/app/assets/{opencl-C8i9C44z.js → opencl-cc0R5DUM.js} +1 -1
- package/dist/app/assets/{openqasm-qSsT45fS.js → openqasm-c2pwesjj.js} +1 -1
- package/dist/app/assets/{oz-w99JsW87.js → oz-DyrsesLt.js} +1 -1
- package/dist/app/assets/{parigp-DvkJkH_x.js → parigp-7_V5KdI6.js} +1 -1
- package/dist/app/assets/{parser-B1HImE8Y.js → parser-D6eGtoRN.js} +1 -1
- package/dist/app/assets/{pascal-DQaovYcp.js → pascal-DzeBw5qN.js} +1 -1
- package/dist/app/assets/{pascaligo-DbdIyNdD.js → pascaligo-Dbb-AhC2.js} +1 -1
- package/dist/app/assets/{pcaxis-8ssDIrdH.js → pcaxis-idJM1h2x.js} +1 -1
- package/dist/app/assets/{peoplecode-BiV5Zxb2.js → peoplecode-BFxdNkx7.js} +1 -1
- package/dist/app/assets/{perl-CPu8mq3o.js → perl-DMMKXc6L.js} +1 -1
- package/dist/app/assets/{php-BDLnoxLe.js → php-GE2qlcWl.js} +1 -1
- package/dist/app/assets/{php-extras-BlCs6h78.js → php-extras-D0h3euWn.js} +1 -1
- package/dist/app/assets/{phpdoc-oTKbX7Rh.js → phpdoc-Aj9K_9VA.js} +1 -1
- package/dist/app/assets/{pieDiagram-DEJITSTG-CkgOwggS.js → pieDiagram-DEJITSTG-euy__LIt.js} +1 -1
- package/dist/app/assets/{plsql-BYXZUF33.js → plsql-a8FhcqVr.js} +1 -1
- package/dist/app/assets/{powerquery-VGGq_Y-K.js → powerquery-DN1sTZNS.js} +1 -1
- package/dist/app/assets/{powershell-RNtOnmCz.js → powershell-DMt014c-.js} +1 -1
- package/dist/app/assets/{processing-C83CF7Om.js → processing-DchAVn2G.js} +1 -1
- package/dist/app/assets/{prolog-MO4dJhtY.js → prolog-BYbcb0nT.js} +1 -1
- package/dist/app/assets/{promql-CzEJXg3T.js → promql-BfevPKN7.js} +1 -1
- package/dist/app/assets/{properties-BXiHyIGq.js → properties-DxkwWeRR.js} +1 -1
- package/dist/app/assets/{protobuf-DzIsCptu.js → protobuf-CChhTutV.js} +1 -1
- package/dist/app/assets/{psl-gO8eBzTG.js → psl-C2_pLcpA.js} +1 -1
- package/dist/app/assets/{pug-DROaMmxc.js → pug-B-sQ4OSc.js} +1 -1
- package/dist/app/assets/{puppet-CkdEKP68.js → puppet-vcyz-j7I.js} +1 -1
- package/dist/app/assets/{pure-B4T0aVQv.js → pure-C0W7EfBD.js} +1 -1
- package/dist/app/assets/{purebasic-DhErIpnU.js → purebasic-FcKgSuqo.js} +1 -1
- package/dist/app/assets/{purescript-BpSYig0_.js → purescript-C_ltNiXx.js} +1 -1
- package/dist/app/assets/{q-BP_ajmdt.js → q-CmN7H41m.js} +1 -1
- package/dist/app/assets/{qml-VWVXkJA9.js → qml-BBK77TJq.js} +1 -1
- package/dist/app/assets/{qore-CVNz07Jd.js → qore-BRjQrygC.js} +1 -1
- package/dist/app/assets/{qsharp-DYrITprs.js → qsharp-DUFroSj9.js} +1 -1
- package/dist/app/assets/{quadrantDiagram-34T5L4WZ-VnllqPYP.js → quadrantDiagram-34T5L4WZ-BGqai1hN.js} +1 -1
- package/dist/app/assets/{r-lkMqhKIi.js → r-BtLInYIq.js} +1 -1
- package/dist/app/assets/{racket-GNxLzSm4.js → racket-DSLIke9j.js} +1 -1
- package/dist/app/assets/{reason-pr_OxQol.js → reason-BN_bXQ-1.js} +1 -1
- package/dist/app/assets/{regex-DuA5bt82.js → regex-Fls3JQwM.js} +1 -1
- package/dist/app/assets/{rego-ChVBSuCN.js → rego-LWOfAlAR.js} +1 -1
- package/dist/app/assets/{renpy-B-T9UWLB.js → renpy-BnxGO9ok.js} +1 -1
- package/dist/app/assets/{requirementDiagram-MS252O5E-nOZVjPtN.js → requirementDiagram-MS252O5E-DTiW7nXX.js} +1 -1
- package/dist/app/assets/{rest-CG4X-WbZ.js → rest-Dzyy_awZ.js} +1 -1
- package/dist/app/assets/{rip-B6LzWfep.js → rip-BHRZITuS.js} +1 -1
- package/dist/app/assets/{roboconf-ySeTNbLp.js → roboconf-BB7SqKLx.js} +1 -1
- package/dist/app/assets/{robotframework-kIOhzxiU.js → robotframework-CbbiHJ_l.js} +1 -1
- package/dist/app/assets/{ruby-BM8sekCP.js → ruby-UNNH3SH_.js} +1 -1
- package/dist/app/assets/{rust-BOWARmu4.js → rust-fivntoob.js} +1 -1
- package/dist/app/assets/{sankeyDiagram-XADWPNL6-D5SMgLO7.js → sankeyDiagram-XADWPNL6-Cg_WnhP6.js} +1 -1
- package/dist/app/assets/{sas-C95QHnSk.js → sas-Bawf1d6-.js} +1 -1
- package/dist/app/assets/{sass-CcV7wTsX.js → sass-Q4vPpiny.js} +1 -1
- package/dist/app/assets/{scala-B-FlSrSn.js → scala-CtMDsbPt.js} +1 -1
- package/dist/app/assets/{scheme-DAA64CUS.js → scheme-DiND4h1E.js} +1 -1
- package/dist/app/assets/{scss-B383C8dD.js → scss-BpxRS9T1.js} +1 -1
- package/dist/app/assets/{sequenceDiagram-FGHM5R23-BAq3WCJj.js → sequenceDiagram-FGHM5R23-DLIccWX-.js} +1 -1
- package/dist/app/assets/{shell-session-65a-LoVJ.js → shell-session-DE5VxnzZ.js} +1 -1
- package/dist/app/assets/{smali-kRxBivzr.js → smali-D2y9x0Hn.js} +1 -1
- package/dist/app/assets/{smalltalk-BeQVL5pW.js → smalltalk-D90_h2xX.js} +1 -1
- package/dist/app/assets/{smarty-Ch5TbbQQ.js → smarty-Ci02BnOV.js} +1 -1
- package/dist/app/assets/{sml-BB_7RVyU.js → sml-qZ9IVAdA.js} +1 -1
- package/dist/app/assets/{solidity-D7wGcxQr.js → solidity-Ld1X52bE.js} +1 -1
- package/dist/app/assets/{solution-file-Db21ESd-.js → solution-file-I128_x79.js} +1 -1
- package/dist/app/assets/{soy-B0_l5rJw.js → soy-CL8SHdlV.js} +1 -1
- package/dist/app/assets/{sparql-JpwPPAJG.js → sparql-9UibhZzT.js} +1 -1
- package/dist/app/assets/{splunk-spl-_c2dI16C.js → splunk-spl-DmuQo_Z-.js} +1 -1
- package/dist/app/assets/{sqf-AGX-5SQA.js → sqf-DYapkK6k.js} +1 -1
- package/dist/app/assets/{sql-DQV539be.js → sql-0G77DN1e.js} +1 -1
- package/dist/app/assets/{squirrel-FmrsBrtP.js → squirrel-DDRb89LY.js} +1 -1
- package/dist/app/assets/{stan-DG1wBDVn.js → stan-BglK2xWh.js} +1 -1
- package/dist/app/assets/{stateDiagram-FHFEXIEX-CBG1b62a.js → stateDiagram-FHFEXIEX-VBMagnLo.js} +1 -1
- package/dist/app/assets/stateDiagram-v2-QKLJ7IA2-ceSH7UY2.js +1 -0
- package/dist/app/assets/{stylus-FxxnGpKJ.js → stylus-BzCzKORP.js} +1 -1
- package/dist/app/assets/{swift-OjEf0t2u.js → swift-DzGGhUfC.js} +1 -1
- package/dist/app/assets/{systemd-CXdOpEaM.js → systemd-CKRopl3u.js} +1 -1
- package/dist/app/assets/{t4-cs-BWNYdlda.js → t4-cs-CBX4HWWS.js} +1 -1
- package/dist/app/assets/{t4-templating-Biohaix7.js → t4-templating-T0C2gZZ5.js} +1 -1
- package/dist/app/assets/{t4-vb-DNFGD3d_.js → t4-vb-B3zSPzaZ.js} +1 -1
- package/dist/app/assets/{tap-Dg18e05M.js → tap-CAe8OF_b.js} +1 -1
- package/dist/app/assets/{tcl-Btqn2UMc.js → tcl-CGagKhb1.js} +1 -1
- package/dist/app/assets/{textile-BxdpzGb-.js → textile-CueycoY7.js} +1 -1
- package/dist/app/assets/{timeline-definition-GMOUNBTQ-BtjV1Syb.js → timeline-definition-GMOUNBTQ-BR8w0YIC.js} +1 -1
- package/dist/app/assets/{toml-D3WkKMhp.js → toml-D3xWlWq-.js} +1 -1
- package/dist/app/assets/{tremor-ix0_xPIS.js → tremor-Cpf7QHkZ.js} +1 -1
- package/dist/app/assets/{tt2-DYiEf69I.js → tt2-CAC91Rlw.js} +1 -1
- package/dist/app/assets/{turtle-D79kYTiV.js → turtle-QHsxVOjz.js} +1 -1
- package/dist/app/assets/{twig-C2lO0FQ6.js → twig-DFrh0LJU.js} +1 -1
- package/dist/app/assets/{typescript-BWbs3zZK.js → typescript-B9pE0jdB.js} +1 -1
- package/dist/app/assets/{typoscript-CXO8uHo_.js → typoscript-0mp-YLa-.js} +1 -1
- package/dist/app/assets/{unrealscript-B4IFw4Fc.js → unrealscript-ClO5RmCe.js} +1 -1
- package/dist/app/assets/{uorazor-Ow8B2gZE.js → uorazor-DOBr2GLb.js} +1 -1
- package/dist/app/assets/{uri-CjdCf_n6.js → uri-BfuI8rBD.js} +1 -1
- package/dist/app/assets/{v-Djh7PWAw.js → v-DnbjWteW.js} +1 -1
- package/dist/app/assets/{vala-hMKcKqAv.js → vala-DSpcVXUB.js} +1 -1
- package/dist/app/assets/{vbnet-CBKK7AZw.js → vbnet-BnOKOgHJ.js} +1 -1
- package/dist/app/assets/{velocity-DBPvifAA.js → velocity-lvbSLJ-r.js} +1 -1
- package/dist/app/assets/{vennDiagram-DHZGUBPP-D-sPxJCn.js → vennDiagram-DHZGUBPP-BiCE3euu.js} +1 -1
- package/dist/app/assets/{verilog-B06XleW6.js → verilog-DkYzNfBh.js} +1 -1
- package/dist/app/assets/{vhdl-z0adhEhq.js → vhdl-D_YywZA8.js} +1 -1
- package/dist/app/assets/{vim-DgXoWMAS.js → vim-pGXhp0rg.js} +1 -1
- package/dist/app/assets/{visual-basic-C17Ibazf.js → visual-basic-BhtyQkXP.js} +1 -1
- package/dist/app/assets/{wardley-RL74JXVD-DSMlPQeI.js → wardley-RL74JXVD-B2V57Q2E.js} +1 -1
- package/dist/app/assets/{wardleyDiagram-NUSXRM2D-DfRjSWRr.js → wardleyDiagram-NUSXRM2D-Cp8D-xvV.js} +1 -1
- package/dist/app/assets/{warpscript-BIetGxT8.js → warpscript-CoTVqDn1.js} +1 -1
- package/dist/app/assets/{wasm-DDD0BDOW.js → wasm-CMFJzAkq.js} +1 -1
- package/dist/app/assets/{web-idl-CIMai9Vx.js → web-idl-C-lZ_t1T.js} +1 -1
- package/dist/app/assets/{wiki-CVWHKZwQ.js → wiki-BOedWAnh.js} +1 -1
- package/dist/app/assets/{wolfram-BvGOmO4s.js → wolfram-CYOMd2Zo.js} +1 -1
- package/dist/app/assets/{wren-CbF6O884.js → wren-DupAeqRZ.js} +1 -1
- package/dist/app/assets/{xeora-B1ekyGx3.js → xeora-CbXv4PDs.js} +1 -1
- package/dist/app/assets/{xml-doc-B4Y4OcvH.js → xml-doc-B7Sbddxh.js} +1 -1
- package/dist/app/assets/{xojo-8yNuRPIu.js → xojo-D1qtWt5Q.js} +1 -1
- package/dist/app/assets/{xquery-18e5foCa.js → xquery-DoggQfJM.js} +1 -1
- package/dist/app/assets/{xychartDiagram-5P7HB3ND-CC5MceuR.js → xychartDiagram-5P7HB3ND-D1aj1N3W.js} +1 -1
- package/dist/app/assets/{yaml-CBHqwYPN.js → yaml-DQR4TEX3.js} +1 -1
- package/dist/app/assets/{yang-Cr3tggHy.js → yang-Cq-mC04g.js} +1 -1
- package/dist/app/assets/{zig-CAn9IEzi.js → zig-BFW3ALkQ.js} +1 -1
- package/dist/app/index.html +2 -2
- package/dist/index.cjs +836 -4
- package/dist/index.js +843 -4
- package/package.json +4 -4
- package/dist/app/assets/channel-776uJRzf.js +0 -1
- package/dist/app/assets/classDiagram-6PBFFD2Q-CuMmt2wK.js +0 -1
- package/dist/app/assets/classDiagram-v2-HSJHXN6E-CuMmt2wK.js +0 -1
- package/dist/app/assets/clone-BHKv9dxg.js +0 -1
- package/dist/app/assets/index-COsBUIAY.js +0 -754
- package/dist/app/assets/index-aAZDJmqe.css +0 -1
- package/dist/app/assets/stateDiagram-v2-QKLJ7IA2-Duz6pBEy.js +0 -1
package/dist/index.js
CHANGED
|
@@ -2,12 +2,18 @@
|
|
|
2
2
|
import * as React48 from "react";
|
|
3
3
|
import {
|
|
4
4
|
ArrowDown as ArrowDown2,
|
|
5
|
+
ChevronDown as ChevronDown5,
|
|
5
6
|
FileText as FileText5,
|
|
6
7
|
ImageIcon,
|
|
8
|
+
Loader2 as Loader28,
|
|
7
9
|
Minus,
|
|
10
|
+
Pause,
|
|
8
11
|
Pencil as Pencil4,
|
|
12
|
+
Play,
|
|
9
13
|
Quote,
|
|
10
14
|
Settings as Settings2,
|
|
15
|
+
Target as Target2,
|
|
16
|
+
Trash2 as Trash23,
|
|
11
17
|
X as X6
|
|
12
18
|
} from "lucide-react";
|
|
13
19
|
|
|
@@ -1052,6 +1058,117 @@ function resolveUsedContextSize(options) {
|
|
|
1052
1058
|
return normalizeContextUsageNumber(options.fallbackUsedTokens) ?? 0;
|
|
1053
1059
|
}
|
|
1054
1060
|
|
|
1061
|
+
// src/lib/thread-goals.ts
|
|
1062
|
+
function normalizeGoalObjective(value) {
|
|
1063
|
+
return value.trim();
|
|
1064
|
+
}
|
|
1065
|
+
function parseGoalCommand(args) {
|
|
1066
|
+
const text = args.trim();
|
|
1067
|
+
if (!text) {
|
|
1068
|
+
return { type: "show" };
|
|
1069
|
+
}
|
|
1070
|
+
const lower = text.toLowerCase();
|
|
1071
|
+
if (lower === "pause") {
|
|
1072
|
+
return { type: "pause" };
|
|
1073
|
+
}
|
|
1074
|
+
if (lower === "resume") {
|
|
1075
|
+
return { type: "resume" };
|
|
1076
|
+
}
|
|
1077
|
+
if (lower === "clear") {
|
|
1078
|
+
return { type: "clear" };
|
|
1079
|
+
}
|
|
1080
|
+
if (lower.startsWith("edit ")) {
|
|
1081
|
+
return {
|
|
1082
|
+
type: "edit",
|
|
1083
|
+
objective: normalizeGoalObjective(text.slice(5))
|
|
1084
|
+
};
|
|
1085
|
+
}
|
|
1086
|
+
return {
|
|
1087
|
+
type: "set",
|
|
1088
|
+
objective: normalizeGoalObjective(text)
|
|
1089
|
+
};
|
|
1090
|
+
}
|
|
1091
|
+
async function loadThreadGoal({
|
|
1092
|
+
goal,
|
|
1093
|
+
threadId,
|
|
1094
|
+
signal
|
|
1095
|
+
}) {
|
|
1096
|
+
return goal.getGoal({ threadId, signal });
|
|
1097
|
+
}
|
|
1098
|
+
async function executeThreadGoalCommand({
|
|
1099
|
+
goal,
|
|
1100
|
+
threadId,
|
|
1101
|
+
assistantId,
|
|
1102
|
+
command,
|
|
1103
|
+
runtimeCapabilities,
|
|
1104
|
+
signal
|
|
1105
|
+
}) {
|
|
1106
|
+
const normalizedThreadId = threadId?.trim() || null;
|
|
1107
|
+
if (command.type === "show") {
|
|
1108
|
+
if (!normalizedThreadId) {
|
|
1109
|
+
throw new Error("Thread is required to show the current goal.");
|
|
1110
|
+
}
|
|
1111
|
+
return {
|
|
1112
|
+
threadId: normalizedThreadId,
|
|
1113
|
+
goal: await goal.getGoal({ threadId: normalizedThreadId, signal })
|
|
1114
|
+
};
|
|
1115
|
+
}
|
|
1116
|
+
if (command.type === "clear") {
|
|
1117
|
+
if (!normalizedThreadId) {
|
|
1118
|
+
throw new Error("Thread is required to clear the current goal.");
|
|
1119
|
+
}
|
|
1120
|
+
return {
|
|
1121
|
+
threadId: normalizedThreadId,
|
|
1122
|
+
goal: await goal.clearGoal({ threadId: normalizedThreadId, signal })
|
|
1123
|
+
};
|
|
1124
|
+
}
|
|
1125
|
+
if (command.type === "pause" || command.type === "resume") {
|
|
1126
|
+
if (!normalizedThreadId) {
|
|
1127
|
+
throw new Error("Thread is required to update the current goal.");
|
|
1128
|
+
}
|
|
1129
|
+
return {
|
|
1130
|
+
threadId: normalizedThreadId,
|
|
1131
|
+
goal: await goal.updateGoal({
|
|
1132
|
+
threadId: normalizedThreadId,
|
|
1133
|
+
status: command.type === "pause" ? "paused" : "active",
|
|
1134
|
+
signal
|
|
1135
|
+
})
|
|
1136
|
+
};
|
|
1137
|
+
}
|
|
1138
|
+
const objective = command.objective.trim();
|
|
1139
|
+
if (!objective) {
|
|
1140
|
+
throw new Error("Goal objective is required.");
|
|
1141
|
+
}
|
|
1142
|
+
if (command.type === "edit") {
|
|
1143
|
+
if (!normalizedThreadId) {
|
|
1144
|
+
const result2 = await goal.setGoal({
|
|
1145
|
+
threadId: null,
|
|
1146
|
+
assistantId,
|
|
1147
|
+
objective,
|
|
1148
|
+
runtimeCapabilities,
|
|
1149
|
+
signal
|
|
1150
|
+
});
|
|
1151
|
+
return result2;
|
|
1152
|
+
}
|
|
1153
|
+
return {
|
|
1154
|
+
threadId: normalizedThreadId,
|
|
1155
|
+
goal: await goal.updateGoal({
|
|
1156
|
+
threadId: normalizedThreadId,
|
|
1157
|
+
objective,
|
|
1158
|
+
signal
|
|
1159
|
+
})
|
|
1160
|
+
};
|
|
1161
|
+
}
|
|
1162
|
+
const result = await goal.setGoal({
|
|
1163
|
+
threadId: normalizedThreadId,
|
|
1164
|
+
assistantId,
|
|
1165
|
+
objective,
|
|
1166
|
+
runtimeCapabilities,
|
|
1167
|
+
signal
|
|
1168
|
+
});
|
|
1169
|
+
return result;
|
|
1170
|
+
}
|
|
1171
|
+
|
|
1055
1172
|
// src/lib/follow-ups.ts
|
|
1056
1173
|
function getComposerFollowUpShortcutLabels(queueShortcutLabel) {
|
|
1057
1174
|
return {
|
|
@@ -1100,6 +1217,7 @@ import {
|
|
|
1100
1217
|
Search,
|
|
1101
1218
|
SlidersHorizontal,
|
|
1102
1219
|
Sparkles,
|
|
1220
|
+
Target,
|
|
1103
1221
|
X
|
|
1104
1222
|
} from "lucide-react";
|
|
1105
1223
|
|
|
@@ -1289,6 +1407,8 @@ var en_US_default = {
|
|
|
1289
1407
|
referencedContentOnly: "Referenced content",
|
|
1290
1408
|
youLabel: "You",
|
|
1291
1409
|
scrollToBottom: "Scroll to bottom",
|
|
1410
|
+
loadMoreMessages: "Load more",
|
|
1411
|
+
loadingMoreMessages: "Loading...",
|
|
1292
1412
|
retryUpload: "Retry upload",
|
|
1293
1413
|
dropFilesTitle: "Drop files to upload",
|
|
1294
1414
|
dropFilesHint: "They will be attached to your next message.",
|
|
@@ -1336,6 +1456,27 @@ var en_US_default = {
|
|
|
1336
1456
|
label: "Context window",
|
|
1337
1457
|
full: "{{usedPercent}}% used ({{remainingPercent}}% left)",
|
|
1338
1458
|
tokensUsed: "{{used}} / {{max}} tokens used"
|
|
1459
|
+
},
|
|
1460
|
+
goal: {
|
|
1461
|
+
label: "Goal",
|
|
1462
|
+
unavailable: "Goal controls are not available for this client.",
|
|
1463
|
+
startThreadRequired: "Start a conversation before changing the goal.",
|
|
1464
|
+
elapsed: "{{elapsed}} elapsed",
|
|
1465
|
+
edit: "Edit goal",
|
|
1466
|
+
pause: "Pause goal",
|
|
1467
|
+
resume: "Resume goal",
|
|
1468
|
+
clear: "Clear goal",
|
|
1469
|
+
hide: "Hide goal",
|
|
1470
|
+
expandObjective: "Show full goal",
|
|
1471
|
+
collapseObjective: "Hide full goal",
|
|
1472
|
+
status: {
|
|
1473
|
+
active: "active",
|
|
1474
|
+
paused: "paused",
|
|
1475
|
+
blocked: "blocked",
|
|
1476
|
+
usage_limited: "usage limited",
|
|
1477
|
+
budget_limited: "budget limited",
|
|
1478
|
+
complete: "complete"
|
|
1479
|
+
}
|
|
1339
1480
|
}
|
|
1340
1481
|
},
|
|
1341
1482
|
history: {
|
|
@@ -1646,6 +1787,8 @@ var zh_CN_default = {
|
|
|
1646
1787
|
referencedContentOnly: "\u5DF2\u5F15\u7528\u5185\u5BB9",
|
|
1647
1788
|
youLabel: "\u4F60",
|
|
1648
1789
|
scrollToBottom: "\u56DE\u5230\u5E95\u90E8",
|
|
1790
|
+
loadMoreMessages: "\u52A0\u8F7D\u66F4\u591A",
|
|
1791
|
+
loadingMoreMessages: "\u6B63\u5728\u52A0\u8F7D...",
|
|
1649
1792
|
retryUpload: "\u91CD\u65B0\u4E0A\u4F20",
|
|
1650
1793
|
dropFilesTitle: "\u677E\u624B\u4E0A\u4F20\u6587\u4EF6",
|
|
1651
1794
|
dropFilesHint: "\u6587\u4EF6\u4F1A\u9644\u52A0\u5230\u4F60\u7684\u4E0B\u4E00\u6761\u6D88\u606F\u3002",
|
|
@@ -1693,6 +1836,27 @@ var zh_CN_default = {
|
|
|
1693
1836
|
label: "\u4E0A\u4E0B\u6587\u7A97\u53E3",
|
|
1694
1837
|
full: "\u5DF2\u4F7F\u7528 {{usedPercent}}%\uFF08\u5269\u4F59 {{remainingPercent}}%\uFF09",
|
|
1695
1838
|
tokensUsed: "\u5DF2\u4F7F\u7528 {{used}} / {{max}} tokens"
|
|
1839
|
+
},
|
|
1840
|
+
goal: {
|
|
1841
|
+
label: "\u76EE\u6807",
|
|
1842
|
+
unavailable: "\u5F53\u524D\u5BA2\u6237\u7AEF\u4E0D\u652F\u6301\u76EE\u6807\u63A7\u5236\u3002",
|
|
1843
|
+
startThreadRequired: "\u8BF7\u5148\u5F00\u59CB\u4E00\u4E2A\u4F1A\u8BDD\u518D\u4FEE\u6539\u76EE\u6807\u3002",
|
|
1844
|
+
elapsed: "\u5DF2\u8FD0\u884C {{elapsed}}",
|
|
1845
|
+
edit: "\u7F16\u8F91\u76EE\u6807",
|
|
1846
|
+
pause: "\u6682\u505C\u76EE\u6807",
|
|
1847
|
+
resume: "\u6062\u590D\u76EE\u6807",
|
|
1848
|
+
clear: "\u6E05\u9664\u76EE\u6807",
|
|
1849
|
+
hide: "\u9690\u85CF\u76EE\u6807",
|
|
1850
|
+
expandObjective: "\u663E\u793A\u5B8C\u6574\u76EE\u6807",
|
|
1851
|
+
collapseObjective: "\u9690\u85CF\u5B8C\u6574\u76EE\u6807",
|
|
1852
|
+
status: {
|
|
1853
|
+
active: "\u8FD0\u884C\u4E2D",
|
|
1854
|
+
paused: "\u5DF2\u6682\u505C",
|
|
1855
|
+
blocked: "\u5DF2\u963B\u585E",
|
|
1856
|
+
usage_limited: "\u7528\u91CF\u53D7\u9650",
|
|
1857
|
+
budget_limited: "\u9884\u7B97\u8017\u5C3D",
|
|
1858
|
+
complete: "\u5DF2\u5B8C\u6210"
|
|
1859
|
+
}
|
|
1696
1860
|
}
|
|
1697
1861
|
},
|
|
1698
1862
|
history: {
|
|
@@ -2965,6 +3129,9 @@ function ComposerMenu({
|
|
|
2965
3129
|
selectedTool,
|
|
2966
3130
|
planModeEnabled = false,
|
|
2967
3131
|
onPlanModeChange,
|
|
3132
|
+
goalCommandAvailable = false,
|
|
3133
|
+
goalPanelOpen = false,
|
|
3134
|
+
onGoalPanelOpenChange,
|
|
2968
3135
|
runtimeCapabilities,
|
|
2969
3136
|
selectedRuntimeCapabilities,
|
|
2970
3137
|
onRuntimeCapabilityToggle,
|
|
@@ -2999,6 +3166,9 @@ function ComposerMenu({
|
|
|
2999
3166
|
const handlePlanModeToggle = () => {
|
|
3000
3167
|
onPlanModeChange?.(!planModeEnabled);
|
|
3001
3168
|
};
|
|
3169
|
+
const handleGoalCommandClick = () => {
|
|
3170
|
+
onGoalPanelOpenChange?.(!goalPanelOpen);
|
|
3171
|
+
};
|
|
3002
3172
|
const handleOpenChange = (nextOpen) => {
|
|
3003
3173
|
if (nextOpen) {
|
|
3004
3174
|
const boundary = triggerRef.current?.closest("[data-chatkit-root]") ?? void 0;
|
|
@@ -3296,6 +3466,45 @@ function ComposerMenu({
|
|
|
3296
3466
|
]
|
|
3297
3467
|
}
|
|
3298
3468
|
),
|
|
3469
|
+
goalCommandAvailable && /* @__PURE__ */ jsxs4(
|
|
3470
|
+
DropdownMenuItem,
|
|
3471
|
+
{
|
|
3472
|
+
role: "switch",
|
|
3473
|
+
"aria-checked": goalPanelOpen,
|
|
3474
|
+
onSelect: (event) => {
|
|
3475
|
+
event.preventDefault();
|
|
3476
|
+
handleGoalCommandClick();
|
|
3477
|
+
},
|
|
3478
|
+
className: cn(
|
|
3479
|
+
"gap-3 px-3 py-2",
|
|
3480
|
+
menuItemRoundedClass,
|
|
3481
|
+
goalPanelOpen && "bg-muted"
|
|
3482
|
+
),
|
|
3483
|
+
children: [
|
|
3484
|
+
/* @__PURE__ */ jsx11("span", { className: "flex h-6 w-6 items-center justify-center text-muted-foreground", children: /* @__PURE__ */ jsx11(Target, { size: 16 }) }),
|
|
3485
|
+
/* @__PURE__ */ jsx11("span", { className: "min-w-0 flex-1 text-left", children: t("chat.goal.label") }),
|
|
3486
|
+
/* @__PURE__ */ jsx11(
|
|
3487
|
+
"span",
|
|
3488
|
+
{
|
|
3489
|
+
className: cn(
|
|
3490
|
+
"relative inline-flex h-6 w-10 shrink-0 items-center rounded-full transition-colors",
|
|
3491
|
+
goalPanelOpen ? "bg-primary" : "bg-muted-foreground/20"
|
|
3492
|
+
),
|
|
3493
|
+
"aria-hidden": "true",
|
|
3494
|
+
children: /* @__PURE__ */ jsx11(
|
|
3495
|
+
"span",
|
|
3496
|
+
{
|
|
3497
|
+
className: cn(
|
|
3498
|
+
"inline-block h-5 w-5 rounded-full bg-background shadow-sm transition-transform",
|
|
3499
|
+
goalPanelOpen ? "translate-x-[18px]" : "translate-x-0.5"
|
|
3500
|
+
)
|
|
3501
|
+
}
|
|
3502
|
+
)
|
|
3503
|
+
}
|
|
3504
|
+
)
|
|
3505
|
+
]
|
|
3506
|
+
}
|
|
3507
|
+
),
|
|
3299
3508
|
hasRuntimeCapabilities && /* @__PURE__ */ jsxs4(Fragment, { children: [
|
|
3300
3509
|
/* @__PURE__ */ jsx11(DropdownMenuSeparator, {}),
|
|
3301
3510
|
skills.length > 0 && /* @__PURE__ */ jsxs4(
|
|
@@ -3400,6 +3609,40 @@ function ComposerMenu({
|
|
|
3400
3609
|
/* @__PURE__ */ jsx11("span", { children: t("composer.planModeActive") })
|
|
3401
3610
|
]
|
|
3402
3611
|
}
|
|
3612
|
+
),
|
|
3613
|
+
goalCommandAvailable && goalPanelOpen && /* @__PURE__ */ jsxs4(
|
|
3614
|
+
"button",
|
|
3615
|
+
{
|
|
3616
|
+
type: "button",
|
|
3617
|
+
"aria-label": t("chat.goal.hide"),
|
|
3618
|
+
disabled,
|
|
3619
|
+
onClick: () => onGoalPanelOpenChange?.(false),
|
|
3620
|
+
className: cn(
|
|
3621
|
+
"group inline-flex h-8 shrink-0 items-center gap-1.5 border border-primary/30 bg-primary/10 px-2 text-xs font-medium text-primary transition-all duration-200 hover:bg-primary/15",
|
|
3622
|
+
roundedClass
|
|
3623
|
+
),
|
|
3624
|
+
children: [
|
|
3625
|
+
/* @__PURE__ */ jsxs4("span", { className: "relative inline-flex h-4 w-4 items-center justify-center", children: [
|
|
3626
|
+
/* @__PURE__ */ jsx11(
|
|
3627
|
+
Target,
|
|
3628
|
+
{
|
|
3629
|
+
"data-slot": "goal-indicator-icon",
|
|
3630
|
+
size: 14,
|
|
3631
|
+
className: "absolute transition-all duration-150 group-hover:scale-75 group-hover:opacity-0"
|
|
3632
|
+
}
|
|
3633
|
+
),
|
|
3634
|
+
/* @__PURE__ */ jsx11(
|
|
3635
|
+
X,
|
|
3636
|
+
{
|
|
3637
|
+
"data-slot": "goal-remove-icon",
|
|
3638
|
+
size: 14,
|
|
3639
|
+
className: "absolute scale-75 opacity-0 transition-all duration-150 group-hover:scale-100 group-hover:opacity-100"
|
|
3640
|
+
}
|
|
3641
|
+
)
|
|
3642
|
+
] }),
|
|
3643
|
+
/* @__PURE__ */ jsx11("span", { children: t("chat.goal.label") })
|
|
3644
|
+
]
|
|
3645
|
+
}
|
|
3403
3646
|
)
|
|
3404
3647
|
] });
|
|
3405
3648
|
}
|
|
@@ -6766,6 +7009,9 @@ function parseSlashCommandInvocation(value) {
|
|
|
6766
7009
|
};
|
|
6767
7010
|
}
|
|
6768
7011
|
function shouldSubmitRawSlashInvocation(command) {
|
|
7012
|
+
if (command.name === "goal" && command.source === "runtime") {
|
|
7013
|
+
return false;
|
|
7014
|
+
}
|
|
6769
7015
|
return command.action.type === "insert_invocation";
|
|
6770
7016
|
}
|
|
6771
7017
|
function resolvePromptWorkflowText(value, language) {
|
|
@@ -6803,6 +7049,14 @@ function createSlashCommandExecutionEffect(command, args, language) {
|
|
|
6803
7049
|
...command.kind === "prompt_workflow" ? { kind: command.kind } : {},
|
|
6804
7050
|
...workflow ? { workflow } : {}
|
|
6805
7051
|
};
|
|
7052
|
+
if (command.name === "goal" && command.source === "runtime") {
|
|
7053
|
+
return {
|
|
7054
|
+
type: "goal",
|
|
7055
|
+
args: args.trim(),
|
|
7056
|
+
commandSource,
|
|
7057
|
+
runtimeCapabilities: getActionRuntimeCapabilities(action) ?? void 0
|
|
7058
|
+
};
|
|
7059
|
+
}
|
|
6806
7060
|
if (command.source === "builtin" && action.type === "client_action") {
|
|
6807
7061
|
if (command.name === "plan") {
|
|
6808
7062
|
if (args.trim()) {
|
|
@@ -7164,7 +7418,9 @@ function useSlashCommands({
|
|
|
7164
7418
|
setComposerText,
|
|
7165
7419
|
focusComposerAt,
|
|
7166
7420
|
setPlanModeEnabled,
|
|
7421
|
+
setGoalPanelOpen,
|
|
7167
7422
|
onPetCommand,
|
|
7423
|
+
onGoalCommand,
|
|
7168
7424
|
addRunRuntimeCapabilities,
|
|
7169
7425
|
setRunRuntimeCapabilities,
|
|
7170
7426
|
insertComposerCapabilityToken,
|
|
@@ -7356,6 +7612,17 @@ function useSlashCommands({
|
|
|
7356
7612
|
submitPrompt(effect);
|
|
7357
7613
|
return true;
|
|
7358
7614
|
}
|
|
7615
|
+
if (effect.type === "goal") {
|
|
7616
|
+
void onGoalCommand?.({
|
|
7617
|
+
args: effect.args,
|
|
7618
|
+
commandSource: effect.commandSource,
|
|
7619
|
+
runtimeCapabilities: effect.runtimeCapabilities
|
|
7620
|
+
});
|
|
7621
|
+
setComposerText("", 0);
|
|
7622
|
+
setPalette(null);
|
|
7623
|
+
focusComposerAt(0);
|
|
7624
|
+
return true;
|
|
7625
|
+
}
|
|
7359
7626
|
if (effect.type === "client_action") {
|
|
7360
7627
|
if (parentMessenger) {
|
|
7361
7628
|
void parentMessenger.sendCommand("onWidgetAction", {
|
|
@@ -7384,6 +7651,7 @@ function useSlashCommands({
|
|
|
7384
7651
|
i18n2.language,
|
|
7385
7652
|
parentMessenger,
|
|
7386
7653
|
onPetCommand,
|
|
7654
|
+
onGoalCommand,
|
|
7387
7655
|
selectCapabilityById,
|
|
7388
7656
|
setComposerText,
|
|
7389
7657
|
setPalette,
|
|
@@ -7409,12 +7677,23 @@ function useSlashCommands({
|
|
|
7409
7677
|
toggleCapabilityGroup(option.capabilityType);
|
|
7410
7678
|
return;
|
|
7411
7679
|
}
|
|
7680
|
+
if (option.command.name === "goal" && option.command.source === "runtime") {
|
|
7681
|
+
setGoalPanelOpen((open) => !open);
|
|
7682
|
+
setComposerText("", 0);
|
|
7683
|
+
setPalette(null);
|
|
7684
|
+
focusComposerAt(0);
|
|
7685
|
+
return;
|
|
7686
|
+
}
|
|
7412
7687
|
executeSlashCommand(option.command, "");
|
|
7413
7688
|
},
|
|
7414
7689
|
[
|
|
7415
7690
|
executeSlashCommand,
|
|
7691
|
+
focusComposerAt,
|
|
7416
7692
|
insertComposerCapabilityToken,
|
|
7417
7693
|
palette,
|
|
7694
|
+
setGoalPanelOpen,
|
|
7695
|
+
setComposerText,
|
|
7696
|
+
setPalette,
|
|
7418
7697
|
toggleCapabilityGroup
|
|
7419
7698
|
]
|
|
7420
7699
|
);
|
|
@@ -9929,7 +10208,7 @@ function SandboxShellToolCallCard({ data }) {
|
|
|
9929
10208
|
"div",
|
|
9930
10209
|
{
|
|
9931
10210
|
className: cn(
|
|
9932
|
-
"group/shell-copy relative min-h-0 flex-1",
|
|
10211
|
+
"group/shell-copy relative min-h-0 flex-1 overflow-auto",
|
|
9933
10212
|
SANDBOX_SHELL_SECTION_GAP_CLASS
|
|
9934
10213
|
),
|
|
9935
10214
|
children: [
|
|
@@ -9937,7 +10216,7 @@ function SandboxShellToolCallCard({ data }) {
|
|
|
9937
10216
|
"pre",
|
|
9938
10217
|
{
|
|
9939
10218
|
className: cn(
|
|
9940
|
-
"min-h-0
|
|
10219
|
+
"min-h-0 whitespace-pre pr-8 font-mono text-muted-foreground/85 in-data-[density=compact]:pr-6 in-data-[density=spacious]:pr-10",
|
|
9941
10220
|
SANDBOX_SHELL_TEXT_CLASS
|
|
9942
10221
|
),
|
|
9943
10222
|
"data-slot": "sandbox-shell-output",
|
|
@@ -13271,6 +13550,127 @@ async function persistConversationRuntimeCapabilities({
|
|
|
13271
13550
|
};
|
|
13272
13551
|
}
|
|
13273
13552
|
|
|
13553
|
+
// src/lib/xpert-thread-goal-adapter.ts
|
|
13554
|
+
var SDK_GOAL_METHOD_ERROR = "Current Xpert SDK client does not expose conversation goal methods. Provide options.goal to use a custom goal adapter.";
|
|
13555
|
+
function requireBoundGoalMethod(owner, method) {
|
|
13556
|
+
if (!owner || !method) {
|
|
13557
|
+
throw new Error(SDK_GOAL_METHOD_ERROR);
|
|
13558
|
+
}
|
|
13559
|
+
return method.bind(owner);
|
|
13560
|
+
}
|
|
13561
|
+
function supportsXpertThreadGoalAdapter(client) {
|
|
13562
|
+
const conversations = client.conversations;
|
|
13563
|
+
return Boolean(
|
|
13564
|
+
conversations?.search && conversations.create && conversations.getGoal && conversations.setGoal && conversations.updateGoal && conversations.clearGoal
|
|
13565
|
+
);
|
|
13566
|
+
}
|
|
13567
|
+
async function findConversation(client, threadId) {
|
|
13568
|
+
return findConversationByThreadIdWithRetry(
|
|
13569
|
+
client,
|
|
13570
|
+
threadId
|
|
13571
|
+
);
|
|
13572
|
+
}
|
|
13573
|
+
async function requireConversation(client, threadId) {
|
|
13574
|
+
const conversation = await findConversation(client, threadId);
|
|
13575
|
+
if (!conversation?.id) {
|
|
13576
|
+
throw new Error("Conversation not found for this thread.");
|
|
13577
|
+
}
|
|
13578
|
+
return conversation;
|
|
13579
|
+
}
|
|
13580
|
+
function createXpertThreadGoalAdapter(client) {
|
|
13581
|
+
return {
|
|
13582
|
+
async getGoal({ threadId, signal }) {
|
|
13583
|
+
const conversation = await findConversation(client, threadId);
|
|
13584
|
+
if (!conversation?.id) {
|
|
13585
|
+
return null;
|
|
13586
|
+
}
|
|
13587
|
+
const getGoal = requireBoundGoalMethod(
|
|
13588
|
+
client.conversations,
|
|
13589
|
+
client.conversations.getGoal
|
|
13590
|
+
);
|
|
13591
|
+
return getGoal(conversation.id, { signal });
|
|
13592
|
+
},
|
|
13593
|
+
async setGoal({
|
|
13594
|
+
threadId,
|
|
13595
|
+
assistantId,
|
|
13596
|
+
objective,
|
|
13597
|
+
runtimeCapabilities,
|
|
13598
|
+
signal
|
|
13599
|
+
}) {
|
|
13600
|
+
const normalizedObjective = objective.trim();
|
|
13601
|
+
if (!normalizedObjective) {
|
|
13602
|
+
throw new Error("Goal objective is required.");
|
|
13603
|
+
}
|
|
13604
|
+
const setGoal = requireBoundGoalMethod(
|
|
13605
|
+
client.conversations,
|
|
13606
|
+
client.conversations.setGoal
|
|
13607
|
+
);
|
|
13608
|
+
const normalizedThreadId = threadId?.trim() || null;
|
|
13609
|
+
if (normalizedThreadId) {
|
|
13610
|
+
const conversation2 = await requireConversation(
|
|
13611
|
+
client,
|
|
13612
|
+
normalizedThreadId
|
|
13613
|
+
);
|
|
13614
|
+
const goal2 = await setGoal(
|
|
13615
|
+
conversation2.id,
|
|
13616
|
+
{ objective: normalizedObjective },
|
|
13617
|
+
{ signal }
|
|
13618
|
+
);
|
|
13619
|
+
return { threadId: normalizedThreadId, goal: goal2 };
|
|
13620
|
+
}
|
|
13621
|
+
const createConversation = requireBoundGoalMethod(
|
|
13622
|
+
client.conversations,
|
|
13623
|
+
client.conversations?.create
|
|
13624
|
+
);
|
|
13625
|
+
const conversation = await createConversation({
|
|
13626
|
+
xpertId: assistantId,
|
|
13627
|
+
...runtimeCapabilities ? {
|
|
13628
|
+
options: {
|
|
13629
|
+
runtimeCapabilities
|
|
13630
|
+
}
|
|
13631
|
+
} : {}
|
|
13632
|
+
});
|
|
13633
|
+
const conversationId = conversation.id?.trim();
|
|
13634
|
+
if (!conversationId) {
|
|
13635
|
+
throw new Error("Created conversation is missing id.");
|
|
13636
|
+
}
|
|
13637
|
+
const createdThreadId = conversation.threadId?.trim();
|
|
13638
|
+
if (!createdThreadId) {
|
|
13639
|
+
throw new Error("Created conversation is missing threadId.");
|
|
13640
|
+
}
|
|
13641
|
+
const goal = await setGoal(
|
|
13642
|
+
conversationId,
|
|
13643
|
+
{ objective: normalizedObjective },
|
|
13644
|
+
{ signal }
|
|
13645
|
+
);
|
|
13646
|
+
return { threadId: createdThreadId, goal };
|
|
13647
|
+
},
|
|
13648
|
+
async updateGoal({ threadId, objective, status, signal }) {
|
|
13649
|
+
const conversation = await requireConversation(client, threadId);
|
|
13650
|
+
const updateGoal = requireBoundGoalMethod(
|
|
13651
|
+
client.conversations,
|
|
13652
|
+
client.conversations.updateGoal
|
|
13653
|
+
);
|
|
13654
|
+
return updateGoal(
|
|
13655
|
+
conversation.id,
|
|
13656
|
+
{
|
|
13657
|
+
...objective !== void 0 ? { objective } : {},
|
|
13658
|
+
...status ? { status } : {}
|
|
13659
|
+
},
|
|
13660
|
+
{ signal }
|
|
13661
|
+
);
|
|
13662
|
+
},
|
|
13663
|
+
async clearGoal({ threadId, signal }) {
|
|
13664
|
+
const conversation = await requireConversation(client, threadId);
|
|
13665
|
+
const clearGoal = requireBoundGoalMethod(
|
|
13666
|
+
client.conversations,
|
|
13667
|
+
client.conversations.clearGoal
|
|
13668
|
+
);
|
|
13669
|
+
return clearGoal(conversation.id, { signal });
|
|
13670
|
+
}
|
|
13671
|
+
};
|
|
13672
|
+
}
|
|
13673
|
+
|
|
13274
13674
|
// src/lib/composer-parts.ts
|
|
13275
13675
|
var COMPOSER_CAPABILITY_TOKEN_LENGTH = 1;
|
|
13276
13676
|
var COMPOSER_CAPABILITY_TOKEN = "\uFFFC";
|
|
@@ -13593,6 +13993,21 @@ import { Fragment as Fragment8, jsx as jsx53, jsxs as jsxs36 } from "react/jsx-r
|
|
|
13593
13993
|
var defaultApiUrl2 = import.meta.env.VITE_XPERTAI_API_URL;
|
|
13594
13994
|
var COMPOSER_INPUT_MAX_HEIGHT = 128;
|
|
13595
13995
|
var LONG_TEXT_REFERENCE_THRESHOLD = 5e3;
|
|
13996
|
+
var GOAL_RUN_INPUT = "Continue working toward the active goal.";
|
|
13997
|
+
function hasRuntimeGoalCommand(runtimeCapabilities) {
|
|
13998
|
+
return runtimeCapabilities?.commands?.some((command) => command.name === "goal") ?? false;
|
|
13999
|
+
}
|
|
14000
|
+
function isGoalAdapter(value) {
|
|
14001
|
+
return Boolean(value) && typeof value === "object" && typeof value.getGoal === "function" && typeof value.setGoal === "function" && typeof value.updateGoal === "function" && typeof value.clearGoal === "function";
|
|
14002
|
+
}
|
|
14003
|
+
function formatGoalElapsed(seconds) {
|
|
14004
|
+
if (seconds < 60) {
|
|
14005
|
+
return `${seconds}s`;
|
|
14006
|
+
}
|
|
14007
|
+
const minutes = Math.floor(seconds / 60);
|
|
14008
|
+
const remainingSeconds = seconds % 60;
|
|
14009
|
+
return remainingSeconds ? `${minutes}m ${remainingSeconds}s` : `${minutes}m`;
|
|
14010
|
+
}
|
|
13596
14011
|
function getSlashPaletteEmptyLabelKey(palette, runtimeCapabilitiesReady) {
|
|
13597
14012
|
if (!palette.capabilityTypes || palette.capabilityTypes.length !== 1) {
|
|
13598
14013
|
return "composer.capabilities.emptySearch";
|
|
@@ -13802,6 +14217,12 @@ function Chat({
|
|
|
13802
14217
|
const [historyError, setHistoryError] = React48.useState(null);
|
|
13803
14218
|
const [assistantName, setAssistantName] = React48.useState(null);
|
|
13804
14219
|
const [assistantAvatar, setAssistantAvatar] = React48.useState(null);
|
|
14220
|
+
const [threadGoal, setThreadGoal] = React48.useState(null);
|
|
14221
|
+
const [goalError, setGoalError] = React48.useState(null);
|
|
14222
|
+
const [isGoalLoading, setIsGoalLoading] = React48.useState(false);
|
|
14223
|
+
const [isGoalPanelOpen, setIsGoalPanelOpen] = React48.useState(false);
|
|
14224
|
+
const [isGoalObjectiveExpanded, setIsGoalObjectiveExpanded] = React48.useState(false);
|
|
14225
|
+
const [goalElapsedStartedAt, setGoalElapsedStartedAt] = React48.useState(null);
|
|
13805
14226
|
const LOADING_DOTS_MIN_DURATION = 800;
|
|
13806
14227
|
const STREAMING_STATUS_REFRESH_MS = 250;
|
|
13807
14228
|
const [showLoadingDots, setShowLoadingDots] = React48.useState(false);
|
|
@@ -13853,6 +14274,21 @@ function Chat({
|
|
|
13853
14274
|
}, STREAMING_STATUS_REFRESH_MS);
|
|
13854
14275
|
return () => window.clearInterval(timer);
|
|
13855
14276
|
}, [stream.isLoading]);
|
|
14277
|
+
React48.useEffect(() => {
|
|
14278
|
+
if (threadGoal?.status === "active" && stream.isLoading) {
|
|
14279
|
+
setGoalElapsedStartedAt(Date.now());
|
|
14280
|
+
return;
|
|
14281
|
+
}
|
|
14282
|
+
setGoalElapsedStartedAt(null);
|
|
14283
|
+
}, [
|
|
14284
|
+
stream.isLoading,
|
|
14285
|
+
threadGoal?.elapsedSeconds,
|
|
14286
|
+
threadGoal?.id,
|
|
14287
|
+
threadGoal?.status
|
|
14288
|
+
]);
|
|
14289
|
+
React48.useEffect(() => {
|
|
14290
|
+
setIsGoalObjectiveExpanded(false);
|
|
14291
|
+
}, [threadGoal?.id]);
|
|
13856
14292
|
const [composerParts, setComposerParts] = React48.useState([]);
|
|
13857
14293
|
const [renderedComposerParts, setRenderedComposerParts] = React48.useState([]);
|
|
13858
14294
|
const [composerDomVersion, setComposerDomVersion] = React48.useState(0);
|
|
@@ -13900,6 +14336,7 @@ function Chat({
|
|
|
13900
14336
|
const forceFollowRef = React48.useRef(false);
|
|
13901
14337
|
const previousMessageCountRef = React48.useRef(0);
|
|
13902
14338
|
const previousScrollTopRef = React48.useRef(0);
|
|
14339
|
+
const isPrependingHistoryMessagesRef = React48.useRef(false);
|
|
13903
14340
|
const autoScrollFrameRef = React48.useRef(null);
|
|
13904
14341
|
const isPointerDownRef = React48.useRef(false);
|
|
13905
14342
|
const lastTouchYRef = React48.useRef(null);
|
|
@@ -13958,13 +14395,20 @@ function Chat({
|
|
|
13958
14395
|
() => stream.messages ?? [],
|
|
13959
14396
|
[stream.messages]
|
|
13960
14397
|
);
|
|
14398
|
+
const historyMessagePagination = stream.historyMessagePagination;
|
|
14399
|
+
const isLoadingMoreMessages = Boolean(
|
|
14400
|
+
historyMessagePagination?.isLoadingMore
|
|
14401
|
+
);
|
|
14402
|
+
const canLoadMoreMessages = Boolean(historyMessagePagination?.hasMore);
|
|
13961
14403
|
const draft = React48.useMemo(
|
|
13962
14404
|
() => getComposerPlainText(composerParts),
|
|
13963
14405
|
[composerParts]
|
|
13964
14406
|
);
|
|
13965
14407
|
const trimmedDraft = draft.trim();
|
|
13966
14408
|
const hasReferences = references.length > 0;
|
|
13967
|
-
const
|
|
14409
|
+
const hasCompletedGoal = threadGoal?.status === "complete";
|
|
14410
|
+
const isGoalModeOpen = isGoalPanelOpen;
|
|
14411
|
+
const isComposerStacked = planModeEnabled || isGoalModeOpen || Boolean(selectedTool);
|
|
13968
14412
|
const isComposerInputEmpty = getComposerEditingLength(composerParts) === 0;
|
|
13969
14413
|
const composerInputRoundedClass = getComposerInputRoundedClass(theme.radius, {
|
|
13970
14414
|
isEmpty: isComposerInputEmpty,
|
|
@@ -13985,6 +14429,18 @@ function Chat({
|
|
|
13985
14429
|
() => getRuntimeCapabilityOptions(runtimeCapabilities),
|
|
13986
14430
|
[runtimeCapabilities]
|
|
13987
14431
|
);
|
|
14432
|
+
const goalCommandAvailable = hasRuntimeGoalCommand(runtimeCapabilities);
|
|
14433
|
+
const goalAdapter = React48.useMemo(
|
|
14434
|
+
() => {
|
|
14435
|
+
if (isGoalAdapter(options?.goal)) {
|
|
14436
|
+
return options.goal;
|
|
14437
|
+
}
|
|
14438
|
+
return supportsXpertThreadGoalAdapter(stream.client) ? createXpertThreadGoalAdapter(stream.client) : null;
|
|
14439
|
+
},
|
|
14440
|
+
[options?.goal, stream.client]
|
|
14441
|
+
);
|
|
14442
|
+
const showGoalStatus = goalCommandAvailable && !hasCompletedGoal && (Boolean(goalError) || threadGoal?.status === "active" && stream.isLoading);
|
|
14443
|
+
const displayedGoalElapsedSeconds = threadGoal ? (threadGoal.elapsedSeconds ?? 0) + (goalElapsedStartedAt ? Math.max(0, Math.floor((streamingNow - goalElapsedStartedAt) / 1e3)) : 0) : 0;
|
|
13988
14444
|
const effectiveSessionRuntimeCapabilities = React48.useMemo(
|
|
13989
14445
|
() => runtimeCapabilitiesReady && runtimeCapabilities ? mergeRuntimeCapabilitiesSelections(
|
|
13990
14446
|
runtimeCapabilities,
|
|
@@ -14322,6 +14778,10 @@ function Chat({
|
|
|
14322
14778
|
React48.useEffect(() => {
|
|
14323
14779
|
const messageCountChanged = messages.length !== previousMessageCountRef.current;
|
|
14324
14780
|
previousMessageCountRef.current = messages.length;
|
|
14781
|
+
if (isPrependingHistoryMessagesRef.current) {
|
|
14782
|
+
setHasUpdatesBelow(false);
|
|
14783
|
+
return;
|
|
14784
|
+
}
|
|
14325
14785
|
if (!shouldAutoScrollRef.current) {
|
|
14326
14786
|
if (messageCountChanged || stream.isLoading) {
|
|
14327
14787
|
setHasUpdatesBelow(true);
|
|
@@ -14534,6 +14994,49 @@ function Chat({
|
|
|
14534
14994
|
stream.client,
|
|
14535
14995
|
stream.threadId
|
|
14536
14996
|
]);
|
|
14997
|
+
React48.useEffect(() => {
|
|
14998
|
+
setThreadGoal(stream.threadGoal);
|
|
14999
|
+
}, [stream.threadGoal]);
|
|
15000
|
+
React48.useEffect(() => {
|
|
15001
|
+
const threadId = stream.threadId?.trim();
|
|
15002
|
+
if (!threadId || !goalCommandAvailable) {
|
|
15003
|
+
setThreadGoal(null);
|
|
15004
|
+
setGoalError(null);
|
|
15005
|
+
setIsGoalLoading(false);
|
|
15006
|
+
setIsGoalPanelOpen(false);
|
|
15007
|
+
return;
|
|
15008
|
+
}
|
|
15009
|
+
if (!goalAdapter) {
|
|
15010
|
+
setThreadGoal(null);
|
|
15011
|
+
setGoalError(null);
|
|
15012
|
+
setIsGoalLoading(false);
|
|
15013
|
+
setIsGoalPanelOpen(false);
|
|
15014
|
+
return;
|
|
15015
|
+
}
|
|
15016
|
+
const controller = new AbortController();
|
|
15017
|
+
setIsGoalLoading(true);
|
|
15018
|
+
setGoalError(null);
|
|
15019
|
+
void loadThreadGoal({
|
|
15020
|
+
goal: goalAdapter,
|
|
15021
|
+
threadId,
|
|
15022
|
+
signal: controller.signal
|
|
15023
|
+
}).then((goal) => {
|
|
15024
|
+
if (!controller.signal.aborted) {
|
|
15025
|
+
setThreadGoal(goal);
|
|
15026
|
+
}
|
|
15027
|
+
}).catch((error) => {
|
|
15028
|
+
if (controller.signal.aborted) {
|
|
15029
|
+
return;
|
|
15030
|
+
}
|
|
15031
|
+
setGoalError(error instanceof Error ? error.message : String(error));
|
|
15032
|
+
setThreadGoal(null);
|
|
15033
|
+
}).finally(() => {
|
|
15034
|
+
if (!controller.signal.aborted) {
|
|
15035
|
+
setIsGoalLoading(false);
|
|
15036
|
+
}
|
|
15037
|
+
});
|
|
15038
|
+
return () => controller.abort();
|
|
15039
|
+
}, [goalAdapter, goalCommandAvailable, stream.threadId]);
|
|
14537
15040
|
const uploadedFiles = attachmentState.uploadedFiles;
|
|
14538
15041
|
const handleSessionRuntimeCapabilityToggle = React48.useCallback(
|
|
14539
15042
|
(type, id, selected) => {
|
|
@@ -14745,6 +15248,124 @@ function Chat({
|
|
|
14745
15248
|
t
|
|
14746
15249
|
]
|
|
14747
15250
|
);
|
|
15251
|
+
const handleGoalCommand = React48.useCallback(
|
|
15252
|
+
async ({
|
|
15253
|
+
args,
|
|
15254
|
+
commandSource,
|
|
15255
|
+
runtimeCapabilities: commandRuntimeCapabilities,
|
|
15256
|
+
visibleInput
|
|
15257
|
+
}) => {
|
|
15258
|
+
const command = parseGoalCommand(args);
|
|
15259
|
+
const threadId = stream.threadId?.trim();
|
|
15260
|
+
setGoalError(null);
|
|
15261
|
+
if (!threadId) {
|
|
15262
|
+
if (command.type === "show") {
|
|
15263
|
+
setThreadGoal(null);
|
|
15264
|
+
setIsGoalLoading(false);
|
|
15265
|
+
return;
|
|
15266
|
+
}
|
|
15267
|
+
if (command.type !== "set" && command.type !== "edit") {
|
|
15268
|
+
setGoalError(t("chat.goal.startThreadRequired"));
|
|
15269
|
+
return;
|
|
15270
|
+
}
|
|
15271
|
+
}
|
|
15272
|
+
if (!goalAdapter) {
|
|
15273
|
+
setGoalError(t("chat.goal.unavailable"));
|
|
15274
|
+
return;
|
|
15275
|
+
}
|
|
15276
|
+
setIsGoalLoading(true);
|
|
15277
|
+
try {
|
|
15278
|
+
const result = await executeThreadGoalCommand({
|
|
15279
|
+
goal: goalAdapter,
|
|
15280
|
+
threadId,
|
|
15281
|
+
assistantId: stream.assistantId,
|
|
15282
|
+
command,
|
|
15283
|
+
runtimeCapabilities: commandRuntimeCapabilities
|
|
15284
|
+
});
|
|
15285
|
+
if (!threadId && result.threadId) {
|
|
15286
|
+
stream.reset(result.threadId, []);
|
|
15287
|
+
void refreshThreads();
|
|
15288
|
+
}
|
|
15289
|
+
const startsGoalRun = result.goal?.status === "active" && (command.type === "set" || command.type === "edit" || command.type === "resume");
|
|
15290
|
+
setThreadGoal(command.type === "clear" ? null : result.goal);
|
|
15291
|
+
if (command.type === "clear" || startsGoalRun) {
|
|
15292
|
+
setIsGoalPanelOpen(false);
|
|
15293
|
+
}
|
|
15294
|
+
if (startsGoalRun) {
|
|
15295
|
+
const goalRunThreadId = result.threadId ?? threadId;
|
|
15296
|
+
const runtimeCapabilitiesForGoalRun = runtimeCapabilities && runtimeCapabilitiesReady ? createRuntimeCapabilitiesForSubmit({
|
|
15297
|
+
capabilities: runtimeCapabilities,
|
|
15298
|
+
available: effectiveSessionRuntimeCapabilities,
|
|
15299
|
+
recommended: commandRuntimeCapabilities
|
|
15300
|
+
}) : commandRuntimeCapabilities ?? null;
|
|
15301
|
+
const inputPayload = {
|
|
15302
|
+
input: GOAL_RUN_INPUT,
|
|
15303
|
+
commandSource,
|
|
15304
|
+
goalRun: true,
|
|
15305
|
+
...runtimeCapabilitiesForGoalRun ? { runtimeCapabilities: runtimeCapabilitiesForGoalRun } : {}
|
|
15306
|
+
};
|
|
15307
|
+
const requestOptions = buildInjectedRequestOptions({
|
|
15308
|
+
defaults: options?.request,
|
|
15309
|
+
humanInput: inputPayload
|
|
15310
|
+
});
|
|
15311
|
+
const visibleGoalMessage = visibleInput ? {
|
|
15312
|
+
id: createMessageId(),
|
|
15313
|
+
type: "human",
|
|
15314
|
+
content: visibleInput,
|
|
15315
|
+
submittedInput: visibleInput
|
|
15316
|
+
} : null;
|
|
15317
|
+
void stream.submit(
|
|
15318
|
+
{
|
|
15319
|
+
input: inputPayload,
|
|
15320
|
+
...requestOptions.state ? { state: requestOptions.state } : {}
|
|
15321
|
+
},
|
|
15322
|
+
{
|
|
15323
|
+
...goalRunThreadId && !threadId ? {
|
|
15324
|
+
threadId: goalRunThreadId,
|
|
15325
|
+
joinExistingThread: true
|
|
15326
|
+
} : {},
|
|
15327
|
+
...requestOptions.context ? { context: requestOptions.context } : {},
|
|
15328
|
+
...requestOptions.config ? { config: requestOptions.config } : {},
|
|
15329
|
+
...visibleGoalMessage ? {
|
|
15330
|
+
preserveOptimisticMessages: true,
|
|
15331
|
+
optimisticValues: (prev) => {
|
|
15332
|
+
const prevMessages = prev?.messages ?? [];
|
|
15333
|
+
return {
|
|
15334
|
+
...prev,
|
|
15335
|
+
messages: [...prevMessages, visibleGoalMessage]
|
|
15336
|
+
};
|
|
15337
|
+
}
|
|
15338
|
+
} : {}
|
|
15339
|
+
}
|
|
15340
|
+
).catch((error) => {
|
|
15341
|
+
setGoalError(
|
|
15342
|
+
error instanceof Error ? error.message : String(error)
|
|
15343
|
+
);
|
|
15344
|
+
});
|
|
15345
|
+
}
|
|
15346
|
+
} catch (error) {
|
|
15347
|
+
setGoalError(error instanceof Error ? error.message : String(error));
|
|
15348
|
+
} finally {
|
|
15349
|
+
setIsGoalLoading(false);
|
|
15350
|
+
}
|
|
15351
|
+
},
|
|
15352
|
+
[
|
|
15353
|
+
effectiveSessionRuntimeCapabilities,
|
|
15354
|
+
goalAdapter,
|
|
15355
|
+
options?.request,
|
|
15356
|
+
refreshThreads,
|
|
15357
|
+
runtimeCapabilities,
|
|
15358
|
+
runtimeCapabilitiesReady,
|
|
15359
|
+
stream,
|
|
15360
|
+
t
|
|
15361
|
+
]
|
|
15362
|
+
);
|
|
15363
|
+
const handleGoalPanelOpenChange = React48.useCallback(
|
|
15364
|
+
(open) => {
|
|
15365
|
+
setIsGoalPanelOpen(open);
|
|
15366
|
+
},
|
|
15367
|
+
[]
|
|
15368
|
+
);
|
|
14748
15369
|
const addRunRuntimeCapabilities = React48.useCallback(
|
|
14749
15370
|
(selection) => {
|
|
14750
15371
|
setRunRuntimeCapabilities(
|
|
@@ -14807,7 +15428,9 @@ function Chat({
|
|
|
14807
15428
|
setComposerText,
|
|
14808
15429
|
focusComposerAt,
|
|
14809
15430
|
setPlanModeEnabled,
|
|
15431
|
+
setGoalPanelOpen: setIsGoalPanelOpen,
|
|
14810
15432
|
onPetCommand: handlePetCommand,
|
|
15433
|
+
onGoalCommand: handleGoalCommand,
|
|
14811
15434
|
addRunRuntimeCapabilities,
|
|
14812
15435
|
setRunRuntimeCapabilities,
|
|
14813
15436
|
insertComposerCapabilityToken,
|
|
@@ -14864,11 +15487,42 @@ function Chat({
|
|
|
14864
15487
|
container.scrollTop += optionRect.bottom - containerRect.bottom;
|
|
14865
15488
|
}
|
|
14866
15489
|
}, [runtimeCapabilityPalette, slashPaletteOptions.length]);
|
|
15490
|
+
const submitGoalModeDraft = React48.useCallback(() => {
|
|
15491
|
+
const objective = getComposerPlainText(composerPartsRef.current).trim();
|
|
15492
|
+
if (!isGoalModeOpen || !goalCommandAvailable || !objective) {
|
|
15493
|
+
return false;
|
|
15494
|
+
}
|
|
15495
|
+
setComposerText("", 0);
|
|
15496
|
+
setRuntimeCapabilityPalette(null);
|
|
15497
|
+
focusComposerAt(0);
|
|
15498
|
+
void handleGoalCommand({
|
|
15499
|
+
args: objective,
|
|
15500
|
+
commandSource: {
|
|
15501
|
+
type: "slash_command",
|
|
15502
|
+
name: "goal",
|
|
15503
|
+
source: "runtime",
|
|
15504
|
+
executionType: "insert_invocation"
|
|
15505
|
+
},
|
|
15506
|
+
runtimeCapabilities: runRuntimeCapabilities,
|
|
15507
|
+
visibleInput: objective
|
|
15508
|
+
});
|
|
15509
|
+
return true;
|
|
15510
|
+
}, [
|
|
15511
|
+
focusComposerAt,
|
|
15512
|
+
goalCommandAvailable,
|
|
15513
|
+
handleGoalCommand,
|
|
15514
|
+
isGoalModeOpen,
|
|
15515
|
+
runRuntimeCapabilities,
|
|
15516
|
+
setComposerText
|
|
15517
|
+
]);
|
|
14867
15518
|
const handleSubmit = (event) => {
|
|
14868
15519
|
event.preventDefault();
|
|
14869
15520
|
if (executeSlashCommandFromDraft()) {
|
|
14870
15521
|
return;
|
|
14871
15522
|
}
|
|
15523
|
+
if (submitGoalModeDraft()) {
|
|
15524
|
+
return;
|
|
15525
|
+
}
|
|
14872
15526
|
submitDraft();
|
|
14873
15527
|
};
|
|
14874
15528
|
const handleEditPendingFollowUp = React48.useCallback(
|
|
@@ -15033,6 +15687,9 @@ function Chat({
|
|
|
15033
15687
|
if (executeSlashCommandFromDraft()) {
|
|
15034
15688
|
return;
|
|
15035
15689
|
}
|
|
15690
|
+
if (submitGoalModeDraft()) {
|
|
15691
|
+
return;
|
|
15692
|
+
}
|
|
15036
15693
|
submitDraft(
|
|
15037
15694
|
getBusyComposerShortcutFollowUpMode(event.metaKey || event.ctrlKey)
|
|
15038
15695
|
);
|
|
@@ -15041,6 +15698,9 @@ function Chat({
|
|
|
15041
15698
|
if (executeSlashCommandFromDraft()) {
|
|
15042
15699
|
return;
|
|
15043
15700
|
}
|
|
15701
|
+
if (submitGoalModeDraft()) {
|
|
15702
|
+
return;
|
|
15703
|
+
}
|
|
15044
15704
|
submitDraft();
|
|
15045
15705
|
};
|
|
15046
15706
|
const handleComposerPaste = React48.useCallback(
|
|
@@ -15221,6 +15881,40 @@ function Chat({
|
|
|
15221
15881
|
},
|
|
15222
15882
|
[missingConfig, missingConfigShortMessage, stream, t]
|
|
15223
15883
|
);
|
|
15884
|
+
const handleLoadMoreMessages = React48.useCallback(async () => {
|
|
15885
|
+
if (!canLoadMoreMessages || isLoadingMoreMessages) {
|
|
15886
|
+
return;
|
|
15887
|
+
}
|
|
15888
|
+
const viewport = viewportRef.current;
|
|
15889
|
+
const previousScrollHeight = viewport?.scrollHeight ?? 0;
|
|
15890
|
+
const previousScrollTop = viewport?.scrollTop ?? 0;
|
|
15891
|
+
isPrependingHistoryMessagesRef.current = true;
|
|
15892
|
+
shouldAutoScrollRef.current = false;
|
|
15893
|
+
forceFollowRef.current = false;
|
|
15894
|
+
setHasUpdatesBelow(false);
|
|
15895
|
+
setHistoryError(null);
|
|
15896
|
+
const restoreScrollPosition = () => {
|
|
15897
|
+
requestAnimationFrame(() => {
|
|
15898
|
+
const nextViewport = viewportRef.current;
|
|
15899
|
+
if (nextViewport) {
|
|
15900
|
+
const nextScrollTop = nextViewport.scrollHeight - previousScrollHeight + previousScrollTop;
|
|
15901
|
+
nextViewport.scrollTop = Math.max(0, nextScrollTop);
|
|
15902
|
+
previousScrollTopRef.current = nextViewport.scrollTop;
|
|
15903
|
+
}
|
|
15904
|
+
isPrependingHistoryMessagesRef.current = false;
|
|
15905
|
+
});
|
|
15906
|
+
};
|
|
15907
|
+
try {
|
|
15908
|
+
await stream.loadMoreConversationMessages();
|
|
15909
|
+
restoreScrollPosition();
|
|
15910
|
+
} catch (err) {
|
|
15911
|
+
isPrependingHistoryMessagesRef.current = false;
|
|
15912
|
+
console.warn("Failed to load more thread messages", err);
|
|
15913
|
+
setHistoryError(
|
|
15914
|
+
err instanceof Error ? err.message : t("chat.errors.loadMessages")
|
|
15915
|
+
);
|
|
15916
|
+
}
|
|
15917
|
+
}, [canLoadMoreMessages, isLoadingMoreMessages, stream, t]);
|
|
15224
15918
|
const handleNewThread = async () => {
|
|
15225
15919
|
if (missingConfig || isHistoryLoading) return;
|
|
15226
15920
|
setHistoryError(null);
|
|
@@ -15450,13 +16144,29 @@ function Chat({
|
|
|
15450
16144
|
historyError && /* @__PURE__ */ jsx53("div", { className: "mb-4 rounded-lg border border-amber-200 bg-amber-50 px-3 py-2 text-sm text-amber-900", children: historyError }),
|
|
15451
16145
|
showMissingConfig && /* @__PURE__ */ jsx53("div", { className: "mb-4 rounded-lg border border-amber-200 bg-amber-50 px-3 py-2 text-sm text-amber-900", children: missingConfigDetailMessage }),
|
|
15452
16146
|
isHistoryLoading && /* @__PURE__ */ jsx53("div", { className: "mb-4 rounded-lg border border-muted px-3 py-2 text-sm text-muted-foreground", children: t("chat.loadingThread") }),
|
|
15453
|
-
messages.length === 0 ? /* @__PURE__ */ jsx53(
|
|
16147
|
+
messages.length === 0 && !canLoadMoreMessages ? /* @__PURE__ */ jsx53(
|
|
15454
16148
|
StartScreen,
|
|
15455
16149
|
{
|
|
15456
16150
|
startScreen,
|
|
15457
16151
|
onPromptClick: handlePromptClick
|
|
15458
16152
|
}
|
|
15459
16153
|
) : /* @__PURE__ */ jsxs36("div", { className: "space-y-4", children: [
|
|
16154
|
+
canLoadMoreMessages && /* @__PURE__ */ jsxs36("div", { className: "flex items-center gap-3 py-1", children: [
|
|
16155
|
+
/* @__PURE__ */ jsx53("div", { className: "h-px min-w-8 flex-1 bg-border" }),
|
|
16156
|
+
/* @__PURE__ */ jsx53(
|
|
16157
|
+
Button,
|
|
16158
|
+
{
|
|
16159
|
+
type: "button",
|
|
16160
|
+
variant: "ghost",
|
|
16161
|
+
size: "sm",
|
|
16162
|
+
onClick: handleLoadMoreMessages,
|
|
16163
|
+
disabled: isLoadingMoreMessages,
|
|
16164
|
+
className: "h-7 px-2 text-xs font-medium text-muted-foreground hover:text-foreground",
|
|
16165
|
+
children: isLoadingMoreMessages ? t("chat.loadingMoreMessages") : t("chat.loadMoreMessages")
|
|
16166
|
+
}
|
|
16167
|
+
),
|
|
16168
|
+
/* @__PURE__ */ jsx53("div", { className: "h-px min-w-8 flex-1 bg-border" })
|
|
16169
|
+
] }),
|
|
15460
16170
|
messages.map((message, index) => {
|
|
15461
16171
|
const messageType = String(message.type);
|
|
15462
16172
|
const isAssistantMessage = messageType === "assistant" || messageType === "ai";
|
|
@@ -15733,6 +16443,132 @@ function Chat({
|
|
|
15733
16443
|
`${option.type}:${option.id}`
|
|
15734
16444
|
))
|
|
15735
16445
|
] }),
|
|
16446
|
+
showGoalStatus && /* @__PURE__ */ jsxs36(
|
|
16447
|
+
"div",
|
|
16448
|
+
{
|
|
16449
|
+
className: cn(
|
|
16450
|
+
"mb-2 flex min-h-10 gap-2 rounded-md border border-border bg-background px-2.5 py-2 text-xs text-foreground shadow-sm",
|
|
16451
|
+
isGoalObjectiveExpanded ? "items-start" : "items-center"
|
|
16452
|
+
),
|
|
16453
|
+
children: [
|
|
16454
|
+
/* @__PURE__ */ jsx53(
|
|
16455
|
+
Target2,
|
|
16456
|
+
{
|
|
16457
|
+
className: cn(
|
|
16458
|
+
"size-4 shrink-0 text-muted-foreground",
|
|
16459
|
+
isGoalObjectiveExpanded && "mt-1"
|
|
16460
|
+
)
|
|
16461
|
+
}
|
|
16462
|
+
),
|
|
16463
|
+
/* @__PURE__ */ jsxs36("div", { className: "min-w-0 flex-1", children: [
|
|
16464
|
+
/* @__PURE__ */ jsxs36("div", { className: "flex min-w-0 items-center gap-2", children: [
|
|
16465
|
+
/* @__PURE__ */ jsx53("span", { className: "font-medium", children: t("chat.goal.label") }),
|
|
16466
|
+
threadGoal && /* @__PURE__ */ jsx53("span", { className: "shrink-0 rounded-md bg-muted px-1.5 py-0.5 text-[11px] text-muted-foreground", children: t(`chat.goal.status.${threadGoal.status}`) }),
|
|
16467
|
+
isGoalLoading && /* @__PURE__ */ jsx53(Loader28, { className: "size-3 animate-spin text-muted-foreground" })
|
|
16468
|
+
] }),
|
|
16469
|
+
/* @__PURE__ */ jsx53(
|
|
16470
|
+
"div",
|
|
16471
|
+
{
|
|
16472
|
+
className: cn(
|
|
16473
|
+
"mt-0.5 text-muted-foreground",
|
|
16474
|
+
threadGoal?.objective && !goalError && isGoalObjectiveExpanded ? "whitespace-pre-wrap break-words" : "truncate"
|
|
16475
|
+
),
|
|
16476
|
+
children: goalError || threadGoal?.objective
|
|
16477
|
+
}
|
|
16478
|
+
),
|
|
16479
|
+
threadGoal && /* @__PURE__ */ jsx53("div", { className: "mt-1 flex flex-wrap gap-x-3 gap-y-1 text-[11px] text-muted-foreground", children: /* @__PURE__ */ jsx53("span", { children: t("chat.goal.elapsed", {
|
|
16480
|
+
elapsed: formatGoalElapsed(displayedGoalElapsedSeconds)
|
|
16481
|
+
}) }) })
|
|
16482
|
+
] }),
|
|
16483
|
+
threadGoal && /* @__PURE__ */ jsxs36("div", { className: "flex shrink-0 items-center gap-1", children: [
|
|
16484
|
+
/* @__PURE__ */ jsxs36(Tooltip, { children: [
|
|
16485
|
+
/* @__PURE__ */ jsx53(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx53(
|
|
16486
|
+
Button,
|
|
16487
|
+
{
|
|
16488
|
+
type: "button",
|
|
16489
|
+
variant: "ghost",
|
|
16490
|
+
size: "icon-xs",
|
|
16491
|
+
disabled: isGoalLoading,
|
|
16492
|
+
onClick: () => {
|
|
16493
|
+
const prefix = "/goal edit ";
|
|
16494
|
+
setComposerText(`${prefix}${threadGoal.objective}`);
|
|
16495
|
+
},
|
|
16496
|
+
children: /* @__PURE__ */ jsx53(Pencil4, { className: "size-3" })
|
|
16497
|
+
}
|
|
16498
|
+
) }),
|
|
16499
|
+
/* @__PURE__ */ jsx53(TooltipContent, { children: t("chat.goal.edit") })
|
|
16500
|
+
] }),
|
|
16501
|
+
/* @__PURE__ */ jsxs36(Tooltip, { children: [
|
|
16502
|
+
/* @__PURE__ */ jsx53(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx53(
|
|
16503
|
+
Button,
|
|
16504
|
+
{
|
|
16505
|
+
type: "button",
|
|
16506
|
+
variant: "ghost",
|
|
16507
|
+
size: "icon-xs",
|
|
16508
|
+
disabled: isGoalLoading,
|
|
16509
|
+
onClick: () => void handleGoalCommand({
|
|
16510
|
+
args: threadGoal.status === "paused" ? "resume" : "pause",
|
|
16511
|
+
commandSource: {
|
|
16512
|
+
type: "slash_command",
|
|
16513
|
+
name: "goal",
|
|
16514
|
+
source: "runtime",
|
|
16515
|
+
executionType: "insert_invocation"
|
|
16516
|
+
}
|
|
16517
|
+
}),
|
|
16518
|
+
children: threadGoal.status === "paused" ? /* @__PURE__ */ jsx53(Play, { className: "size-3" }) : /* @__PURE__ */ jsx53(Pause, { className: "size-3" })
|
|
16519
|
+
}
|
|
16520
|
+
) }),
|
|
16521
|
+
/* @__PURE__ */ jsx53(TooltipContent, { children: threadGoal.status === "paused" ? t("chat.goal.resume") : t("chat.goal.pause") })
|
|
16522
|
+
] }),
|
|
16523
|
+
/* @__PURE__ */ jsxs36(Tooltip, { children: [
|
|
16524
|
+
/* @__PURE__ */ jsx53(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx53(
|
|
16525
|
+
Button,
|
|
16526
|
+
{
|
|
16527
|
+
type: "button",
|
|
16528
|
+
variant: "ghost",
|
|
16529
|
+
size: "icon-xs",
|
|
16530
|
+
disabled: isGoalLoading,
|
|
16531
|
+
onClick: () => void handleGoalCommand({
|
|
16532
|
+
args: "clear",
|
|
16533
|
+
commandSource: {
|
|
16534
|
+
type: "slash_command",
|
|
16535
|
+
name: "goal",
|
|
16536
|
+
source: "runtime",
|
|
16537
|
+
executionType: "insert_invocation"
|
|
16538
|
+
}
|
|
16539
|
+
}),
|
|
16540
|
+
children: /* @__PURE__ */ jsx53(Trash23, { className: "size-3" })
|
|
16541
|
+
}
|
|
16542
|
+
) }),
|
|
16543
|
+
/* @__PURE__ */ jsx53(TooltipContent, { children: t("chat.goal.clear") })
|
|
16544
|
+
] }),
|
|
16545
|
+
threadGoal.objective && !goalError && /* @__PURE__ */ jsxs36(Tooltip, { children: [
|
|
16546
|
+
/* @__PURE__ */ jsx53(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx53(
|
|
16547
|
+
Button,
|
|
16548
|
+
{
|
|
16549
|
+
type: "button",
|
|
16550
|
+
variant: "ghost",
|
|
16551
|
+
size: "icon-xs",
|
|
16552
|
+
"aria-expanded": isGoalObjectiveExpanded,
|
|
16553
|
+
"aria-label": isGoalObjectiveExpanded ? t("chat.goal.collapseObjective") : t("chat.goal.expandObjective"),
|
|
16554
|
+
onClick: () => setIsGoalObjectiveExpanded((expanded) => !expanded),
|
|
16555
|
+
children: /* @__PURE__ */ jsx53(
|
|
16556
|
+
ChevronDown5,
|
|
16557
|
+
{
|
|
16558
|
+
className: cn(
|
|
16559
|
+
"size-3 transition-transform",
|
|
16560
|
+
isGoalObjectiveExpanded && "rotate-180"
|
|
16561
|
+
)
|
|
16562
|
+
}
|
|
16563
|
+
)
|
|
16564
|
+
}
|
|
16565
|
+
) }),
|
|
16566
|
+
/* @__PURE__ */ jsx53(TooltipContent, { children: isGoalObjectiveExpanded ? t("chat.goal.collapseObjective") : t("chat.goal.expandObjective") })
|
|
16567
|
+
] })
|
|
16568
|
+
] })
|
|
16569
|
+
]
|
|
16570
|
+
}
|
|
16571
|
+
),
|
|
15736
16572
|
/* @__PURE__ */ jsx53(
|
|
15737
16573
|
PendingRuntimeServices,
|
|
15738
16574
|
{
|
|
@@ -15874,6 +16710,9 @@ function Chat({
|
|
|
15874
16710
|
selectedTool,
|
|
15875
16711
|
planModeEnabled,
|
|
15876
16712
|
onPlanModeChange: setPlanModeEnabled,
|
|
16713
|
+
goalCommandAvailable,
|
|
16714
|
+
goalPanelOpen: isGoalModeOpen,
|
|
16715
|
+
onGoalPanelOpenChange: handleGoalPanelOpenChange,
|
|
15877
16716
|
runtimeCapabilities: runtimeCapabilitiesReady ? runtimeCapabilities : null,
|
|
15878
16717
|
selectedRuntimeCapabilities: effectiveSessionRuntimeCapabilities,
|
|
15879
16718
|
onRuntimeCapabilityToggle: handleSessionRuntimeCapabilityToggle,
|