@qwen-code/qwen-code 0.19.7-nightly.20260708.394c1a289 → 0.19.8
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/bundled/qc-helper/docs/features/channels/overview.md +6 -3
- package/bundled/qc-helper/docs/features/channels/plugins.md +1 -0
- package/bundled/qc-helper/docs/features/hooks.md +36 -34
- package/bundled/qc-helper/docs/features/memory.md +1 -1
- package/bundled/qc-helper/docs/qwen-serve.md +17 -10
- package/bundled/review/SKILL.md +6 -2
- package/chunks/{MaxSizedBox-XS37LWTD.js → MaxSizedBox-5DT2SD7B.js} +7 -7
- package/chunks/{StandaloneSessionPicker-LPALJTKN.js → StandaloneSessionPicker-EYRGH6PJ.js} +23 -21
- package/chunks/{acpAgent-4VE3FGJX.js → acpAgent-GRFTTRHW.js} +74 -69
- package/chunks/{agent-CCHERW6L.js → agent-H2DGKS77.js} +4 -4
- package/chunks/{agent-headless-55N6UBUU.js → agent-headless-KFMFIT6J.js} +4 -4
- package/chunks/{anthropicContentGenerator-AKYPSZIV.js → anthropicContentGenerator-CPF22MA7.js} +28 -1
- package/chunks/{bridge-U6HXOHE7.js → bridge-NA3ZQQKJ.js} +11 -10
- package/chunks/{ca-HCMB2I54.js → ca-MKD32FQL.js} +26 -1
- package/chunks/{channel-worker-supervisor-CRCVYQIE.js → channel-worker-supervisor-NZQUOEFJ.js} +3 -3
- package/chunks/{chunk-J43WPR6U.js → chunk-27BHARDE.js} +8 -8
- package/chunks/{chunk-KKWO4IX2.js → chunk-2EM7ECZD.js} +251 -71
- package/chunks/{chunk-E7HM76PR.js → chunk-3GNOQZDC.js} +1562 -1025
- package/chunks/{chunk-G7ZG7CA6.js → chunk-3UP777ZS.js} +8 -7
- package/chunks/{chunk-VEB3NYSO.js → chunk-5MBO76SL.js} +5 -0
- package/chunks/{chunk-N74BA4VP.js → chunk-6VK6FIMQ.js} +1 -1
- package/chunks/{chunk-2FHWCKWA.js → chunk-A5JOJ77H.js} +35 -14
- package/chunks/{chunk-PLGONYEL.js → chunk-AYNCLGTW.js} +5 -5
- package/chunks/{chunk-K34DD7FH.js → chunk-BOBOCR5H.js} +4 -3
- package/chunks/chunk-BOBRZZKD.js +468 -0
- package/chunks/{chunk-7I4MGFBN.js → chunk-BUZ6HGL4.js} +5 -5
- package/chunks/{chunk-FK77ILF5.js → chunk-BVYU3ZTI.js} +2 -2
- package/chunks/{chunk-TBAZMRW3.js → chunk-CD6USWHZ.js} +1 -1
- package/chunks/{chunk-PVXPDMGP.js → chunk-CHB5SLZZ.js} +2 -2
- package/chunks/{chunk-SJHAUELE.js → chunk-DCZWC4PF.js} +2 -2
- package/chunks/{chunk-YYU6H66M.js → chunk-DHOLNQLC.js} +11 -11
- package/chunks/{chunk-MOQOAH7N.js → chunk-DICGXFAI.js} +1 -1
- package/chunks/{chunk-KT3SI3CQ.js → chunk-DIWVZ3VM.js} +8 -8
- package/chunks/{chunk-2DYY5XUZ.js → chunk-E7EMCSUG.js} +1 -1
- package/chunks/{chunk-XQ2GVLNJ.js → chunk-EEN2TKST.js} +1 -1
- package/chunks/{chunk-DNV4FSN5.js → chunk-FBET5XZ2.js} +6 -4
- package/chunks/{chunk-GIY6JTTC.js → chunk-FQNC62B2.js} +4 -4
- package/chunks/{chunk-B34OV7K2.js → chunk-GGQQA4JW.js} +13 -0
- package/chunks/chunk-GLE2YUPU.js +34 -0
- package/chunks/{chunk-X265R5C6.js → chunk-GN3F6PIU.js} +1 -1
- package/chunks/{chunk-LC4SMGYY.js → chunk-GSHQYYIV.js} +45 -9
- package/chunks/{chunk-BGL43SJ3.js → chunk-HDOH3QYE.js} +1 -1
- package/chunks/{chunk-4AFOWB47.js → chunk-I6WGFJJ3.js} +63 -4
- package/chunks/{chunk-2NPS2UDH.js → chunk-IBY3Q3HG.js} +390 -9
- package/chunks/{chunk-AXTPFMRS.js → chunk-J7RCB6N5.js} +1 -1
- package/chunks/{chunk-QCSLZO6J.js → chunk-JCH35JB3.js} +1 -1
- package/chunks/{chunk-JYOWO2F7.js → chunk-JPALE3PA.js} +3 -3
- package/chunks/{chunk-5FL2K3ZB.js → chunk-JRQ7EVGE.js} +1 -1
- package/chunks/{chunk-BHRU4SDF.js → chunk-JZHIQJOE.js} +3 -3
- package/chunks/{chunk-FB2ULV4M.js → chunk-L46XKEGM.js} +14 -153
- package/chunks/{chunk-LKXDC3AW.js → chunk-L4AMBVQG.js} +9 -9
- package/chunks/{chunk-ME344634.js → chunk-LAXNEOBG.js} +1 -1
- package/chunks/{chunk-QHT5USLK.js → chunk-M7S4GK5Z.js} +66 -445
- package/chunks/{chunk-4RQIB5UZ.js → chunk-O2YT7VB4.js} +0 -34
- package/chunks/{chunk-TBLJNMI7.js → chunk-O33TBKDC.js} +10 -10
- package/chunks/chunk-O7FIRWJV.js +168 -0
- package/chunks/{chunk-4KJ2BPIT.js → chunk-OACJLMLD.js} +2 -38
- package/chunks/{chunk-CR5IU2RX.js → chunk-ON3JA3RU.js} +2 -2
- package/chunks/{chunk-VTCPREC7.js → chunk-OQXDAMKY.js} +3 -3
- package/chunks/{chunk-ELMPRVCB.js → chunk-P3XEEI3X.js} +1 -1
- package/chunks/{chunk-OU6FPTJZ.js → chunk-PMFULMLX.js} +296 -81
- package/chunks/{chunk-2YELHTUE.js → chunk-PUVCVELY.js} +1 -1
- package/chunks/{chunk-5OSSOBZC.js → chunk-RMLZAUWH.js} +4 -4
- package/chunks/{chunk-B6WUEODT.js → chunk-SQ2UATK7.js} +14 -8
- package/chunks/{chunk-TEYGKLIZ.js → chunk-TI3BWD4D.js} +1 -1
- package/chunks/{chunk-T2EJHSE3.js → chunk-TSPB77TG.js} +57 -35
- package/chunks/{chunk-L7IWK7JY.js → chunk-UX6OTBVD.js} +1 -1
- package/chunks/{chunk-XUSONNJ4.js → chunk-UXEW557D.js} +1 -1
- package/chunks/chunk-V35MD7KN.js +13 -0
- package/chunks/{chunk-B5FOCTEZ.js → chunk-VGGOPZUL.js} +6 -5
- package/chunks/{chunk-MYZWWRVW.js → chunk-WF4FAXDL.js} +2 -2
- package/chunks/{chunk-2SWMCXVR.js → chunk-WHJQ3JUS.js} +20 -8
- package/chunks/{chunk-VQJ64BIQ.js → chunk-WQTHLB5T.js} +3 -3
- package/chunks/chunk-XNXVCNAT.js +88 -0
- package/chunks/{chunk-TDGF35EN.js → chunk-XOHNA2S6.js} +1 -1
- package/chunks/{chunk-ZK5EI6NR.js → chunk-XYR5RUA5.js} +14 -5
- package/chunks/{chunk-YMWIKAEE.js → chunk-YDOXPLYL.js} +244 -47
- package/chunks/{chunk-UZCT5OLN.js → chunk-YHKAK72D.js} +11 -11
- package/chunks/{chunk-RFIL6REB.js → chunk-YKZIAK7C.js} +119 -29
- package/chunks/chunk-Z3I3QJK3.js +47 -0
- package/chunks/{chunk-3QDZDAJG.js → chunk-ZE6E424U.js} +1 -1
- package/chunks/chunk-ZL5HN75Q.js +61 -0
- package/chunks/{computer-use-4CTF6WS3.js → computer-use-WMY3UOBX.js} +4 -4
- package/chunks/{contextCommand-Z3XWQCY6.js → contextCommand-LXFZRP4L.js} +6 -6
- package/chunks/{daemon-F3I2RXP6.js → daemon-WPAENEBW.js} +48 -0
- package/chunks/{daemon-status-provider-6A4QCG6Q.js → daemon-status-provider-GJRXY5EN.js} +15 -13
- package/chunks/{de-PLLFDERI.js → de-ZFPPQVSF.js} +26 -1
- package/chunks/{dist-IMFFBMAT.js → dist-BEXOZXLQ.js} +1 -1
- package/chunks/{dist-OT7G2WNM.js → dist-E6UANPIM.js} +1 -1
- package/chunks/{dist-FQ5WRJPL.js → dist-H2AEJCZ5.js} +2 -2
- package/chunks/{dist-YTRKAVUB.js → dist-O2IRTRPP.js} +1 -1
- package/chunks/{dist-573HNSVO.js → dist-SCFLLYMK.js} +1 -1
- package/chunks/{dist-PKFTNUHO.js → dist-Z34QPAQW.js} +1 -1
- package/chunks/{earlyInputCapture-7O47HW62.js → earlyInputCapture-KNOYZ4MJ.js} +4 -4
- package/chunks/{edit-E32KWLF2.js → edit-OTYWAXGP.js} +5 -5
- package/chunks/{en-GA2RMXY5.js → en-N4EPZAQI.js} +26 -1
- package/chunks/{enter-worktree-ZKFFMHUD.js → enter-worktree-HNYBDVCX.js} +4 -4
- package/chunks/{enterPlanMode-HLDC6NGX.js → enterPlanMode-CJCNGT63.js} +4 -4
- package/chunks/environment-ATFTYMLZ.js +88 -0
- package/chunks/{errors-MTIDDXX7.js → errors-A54HAADA.js} +6 -6
- package/chunks/{exit-worktree-YHY72XA2.js → exit-worktree-DUUKOE3X.js} +4 -4
- package/chunks/{exitPlanMode-JNXKBZ2C.js → exitPlanMode-AMMSXOAJ.js} +4 -4
- package/chunks/{fast-path-DVAGBROV.js → fast-path-OV6NIP3K.js} +12 -3
- package/chunks/{fast-path-settings-RCRXH2JG.js → fast-path-settings-7RIFI3PK.js} +3 -2
- package/chunks/{fr-GWNQG4XH.js → fr-5WWMY53B.js} +26 -1
- package/chunks/{gemini-2TMHJVRC.js → gemini-NQ3WWBKB.js} +431 -135
- package/chunks/{geminiContentGenerator-WCH4GWD3.js → geminiContentGenerator-CDUNEJQE.js} +1 -1
- package/chunks/{glob-I6Y4AGKO.js → glob-ROV3YS4R.js} +4 -4
- package/chunks/{grep-3P2J3LU5.js → grep-NRITKDCD.js} +4 -4
- package/chunks/{handleAutoUpdate-4IVRMRG4.js → handleAutoUpdate-CEZJAARW.js} +6 -6
- package/chunks/{initializer-DVNCPVTC.js → initializer-BRFJKRRX.js} +11 -9
- package/chunks/{ja-2HOTA47X.js → ja-CUHZOLEJ.js} +26 -1
- package/chunks/{list-4D6QK2KZ.js → list-KVHF7O4X.js} +13 -11
- package/chunks/{loadedSettingsAdapter-GNGELH6Q.js → loadedSettingsAdapter-LL5PSFKX.js} +11 -9
- package/chunks/{ls-L654WOAT.js → ls-7MFU2QYW.js} +1 -1
- package/chunks/{lsp-M35KE54Y.js → lsp-XHDTPTGV.js} +2 -4
- package/chunks/{mcp-2IL72YJP.js → mcp-3GCXRTOQ.js} +11 -9
- package/chunks/{monitor-BLVCZAVX.js → monitor-FL2ZO33W.js} +4 -4
- package/chunks/{nonInteractiveCli-UD3V7UOO.js → nonInteractiveCli-PTQI3DV6.js} +44 -41
- package/chunks/{notebook-edit-5TVMWIWY.js → notebook-edit-6PULTHL5.js} +5 -5
- package/chunks/{openaiContentGenerator-5LJ5A7YY.js → openaiContentGenerator-YE42PKCY.js} +3 -3
- package/chunks/{pidfile-AN5JQJ2T.js → pidfile-NZYSCFRK.js} +4 -4
- package/chunks/{pt-2THT3YHA.js → pt-OLYN42DS.js} +26 -1
- package/chunks/{qwenContentGenerator-E2JSB4FJ.js → qwenContentGenerator-NX2E7PB7.js} +5 -5
- package/chunks/{read-file-N5DEFUDU.js → read-file-33XGP5HF.js} +2 -2
- package/chunks/{record-artifact-PP3LKHTS.js → record-artifact-SQ2OKRJW.js} +3 -3
- package/chunks/{ripGrep-BLJHTHKE.js → ripGrep-QWZLGTAN.js} +4 -4
- package/chunks/{ru-Z67YJHBG.js → ru-LDM3GWVQ.js} +26 -1
- package/chunks/{run-qwen-serve-4JDO64RN.js → run-qwen-serve-JK2DL7PI.js} +596 -143
- package/chunks/{scheduler-FQR4XA7J.js → scheduler-O4IGVZKK.js} +4 -4
- package/chunks/{send-message-OA6MV4EU.js → send-message-76GT3JMC.js} +1 -1
- package/chunks/{serve-ZOCFC7YM.js → serve-JTMIGANH.js} +13 -10
- package/chunks/{server-GEOYEPYT.js → server-SGNPKX2O.js} +667 -243
- package/chunks/{session-NJCONHGX.js → session-5BNM25EZ.js} +45 -42
- package/chunks/{settings-QBGGXANI.js → settings-3MI4XXP6.js} +20 -16
- package/chunks/{shell-2DVPSEKT.js → shell-YJKBE67T.js} +4 -4
- package/chunks/{skill-HIPXUHV7.js → skill-I22QK5XS.js} +2 -2
- package/chunks/{spawnChannel-3JYXY52G.js → spawnChannel-UNV6W4DU.js} +6 -6
- package/chunks/{src-NLEX4CUC.js → src-BBQSM46M.js} +8 -4
- package/chunks/{startInteractiveUI-TYGZIU27.js → startInteractiveUI-JII36UGN.js} +619 -288
- package/chunks/{task-create-RPFZNB4B.js → task-create-WCHTB435.js} +2 -2
- package/chunks/{task-update-5WUG5MVQ.js → task-update-XYWMHJGJ.js} +2 -2
- package/chunks/{team-create-MGX57SZJ.js → team-create-A7NUU5AQ.js} +4 -4
- package/chunks/{team-plan-approval-BO2N7J3E.js → team-plan-approval-TOQRJ2KI.js} +4 -4
- package/chunks/{theme-manager-WU7LOA64.js → theme-manager-WZ4RRMMB.js} +4 -4
- package/chunks/{tool-search-CLBKVEVK.js → tool-search-SZ4EFS2T.js} +3 -3
- package/chunks/total-session-admission-ULXJWXFV.js +72 -0
- package/chunks/{trustedFolders-GAQM2GHB.js → trustedFolders-LAZZPZ3D.js} +5 -5
- package/chunks/{updateCheck-RIK2YIQE.js → updateCheck-KONLM73X.js} +5 -5
- package/chunks/{validateNonInterActiveAuth-NS3GBIJZ.js → validateNonInterActiveAuth-MPKSRCXD.js} +41 -38
- package/chunks/{version-B3RSLP54.js → version-NO2XSNNP.js} +1 -1
- package/chunks/{workflow-7APPIGND.js → workflow-WO2H6NRI.js} +5 -5
- package/chunks/{workspace-providers-status-SC67GLMY.js → workspace-providers-status-3W7E7DFW.js} +14 -11
- package/chunks/workspace-registry-SXJZNN3O.js +74 -0
- package/chunks/{workspace-service-ZJHF22WA.js → workspace-service-CZRQZ4Q4.js} +17 -15
- package/chunks/{workspace-skills-status-NJEK6P6Y.js → workspace-skills-status-K7WFREPD.js} +12 -10
- package/chunks/{write-file-R6Z3VLRY.js → write-file-PX2Z7IBE.js} +5 -5
- package/chunks/{zh-7XVVRTDH.js → zh-J4F6QWQV.js} +26 -1
- package/chunks/{zh-TW-DPH554OG.js → zh-TW-XVDWOLSW.js} +26 -1
- package/cli.js +11 -11
- package/locales/ca.js +30 -0
- package/locales/de.js +30 -0
- package/locales/en.js +30 -0
- package/locales/fr.js +30 -0
- package/locales/ja.js +30 -0
- package/locales/pt.js +30 -0
- package/locales/ru.js +30 -0
- package/locales/zh-TW.js +30 -0
- package/locales/zh.js +30 -0
- package/node_modules/@qwen-code/audio-capture/package.json +1 -1
- package/node_modules/@qwen-code/audio-capture/prebuilds/darwin-arm64/@qwen-code+audio-capture.node +0 -0
- package/node_modules/@qwen-code/audio-capture/prebuilds/darwin-x64/@qwen-code+audio-capture.node +0 -0
- package/node_modules/@qwen-code/audio-capture/prebuilds/win32-x64/@qwen-code+audio-capture.node +0 -0
- package/package.json +3 -3
- package/web-shell/assets/{arc-C7hjaa7g.js → arc-BWyoJpY2.js} +1 -1
- package/web-shell/assets/{architectureDiagram-3BPJPVTR-pm9KtMZY.js → architectureDiagram-3BPJPVTR-BT0mGrz2.js} +1 -1
- package/web-shell/assets/{blockDiagram-GPEHLZMM-CApElKsU.js → blockDiagram-GPEHLZMM-BLgUWvyf.js} +1 -1
- package/web-shell/assets/{c4Diagram-AAUBKEIU-BeDe0-9N.js → c4Diagram-AAUBKEIU-DYx9M7oU.js} +1 -1
- package/web-shell/assets/channel-wmPUGHtg.js +1 -0
- package/web-shell/assets/{chunk-2J33WTMH-DJEkmLdl.js → chunk-2J33WTMH-CfMHWbuZ.js} +1 -1
- package/web-shell/assets/{chunk-4BX2VUAB-DXX8gdpe.js → chunk-4BX2VUAB-B1URoqEV.js} +1 -1
- package/web-shell/assets/{chunk-55IACEB6-DORmk1kQ.js → chunk-55IACEB6-DAIaM4QF.js} +1 -1
- package/web-shell/assets/{chunk-727SXJPM-DWmO4mCZ.js → chunk-727SXJPM-B2X34knw.js} +1 -1
- package/web-shell/assets/{chunk-AQP2D5EJ-C7LRaYw2.js → chunk-AQP2D5EJ-Cif-zLTQ.js} +1 -1
- package/web-shell/assets/{chunk-FMBD7UC4-CCdXgyC5.js → chunk-FMBD7UC4-H18WCXdY.js} +1 -1
- package/web-shell/assets/{chunk-ND2GUHAM-SyL_xvWc.js → chunk-ND2GUHAM-YFtetHi0.js} +1 -1
- package/web-shell/assets/{chunk-QZHKN3VN-BzOuCKxa.js → chunk-QZHKN3VN-By2hiH3r.js} +1 -1
- package/web-shell/assets/classDiagram-4FO5ZUOK-BA2ljEjW.js +1 -0
- package/web-shell/assets/classDiagram-v2-Q7XG4LA2-BA2ljEjW.js +1 -0
- package/web-shell/assets/{cose-bilkent-S5V4N54A-BMPWyDKc.js → cose-bilkent-S5V4N54A-VrcnnLZu.js} +1 -1
- package/web-shell/assets/{dagre-BM42HDAG-B_GnPWik.js → dagre-BM42HDAG-CGo-IaVV.js} +1 -1
- package/web-shell/assets/{diagram-2AECGRRQ-fJqMc3S_.js → diagram-2AECGRRQ-Dl4QjzIB.js} +1 -1
- package/web-shell/assets/{diagram-5GNKFQAL-ximV3O9D.js → diagram-5GNKFQAL-qMLmsO0u.js} +1 -1
- package/web-shell/assets/{diagram-KO2AKTUF-2vVyjzqw.js → diagram-KO2AKTUF-CHlmuxPI.js} +1 -1
- package/web-shell/assets/{diagram-LMA3HP47-Dckcx1sT.js → diagram-LMA3HP47-BUwU3GwT.js} +1 -1
- package/web-shell/assets/{diagram-OG6HWLK6-BAVv47ga.js → diagram-OG6HWLK6-HEhwPDUM.js} +1 -1
- package/web-shell/assets/{erDiagram-TEJ5UH35-Bn3nf5J0.js → erDiagram-TEJ5UH35-1n0llBmM.js} +1 -1
- package/web-shell/assets/{flowDiagram-I6XJVG4X-BIbGF9JT.js → flowDiagram-I6XJVG4X-BN74uMnt.js} +1 -1
- package/web-shell/assets/{ganttDiagram-6RSMTGT7-CDbhb3AH.js → ganttDiagram-6RSMTGT7-BoOq78i3.js} +1 -1
- package/web-shell/assets/{gitGraphDiagram-PVQCEYII-CbKG1a_w.js → gitGraphDiagram-PVQCEYII-CN8b00c8.js} +1 -1
- package/web-shell/assets/index-CNwoO1Cn.js +783 -0
- package/web-shell/assets/index-CWQ0z6kZ.css +5 -0
- package/web-shell/assets/{infoDiagram-5YYISTIA-DUFxTy8m.js → infoDiagram-5YYISTIA-CCurnIna.js} +1 -1
- package/web-shell/assets/{ishikawaDiagram-YF4QCWOH-D69hrBG8.js → ishikawaDiagram-YF4QCWOH-AwuRqdUP.js} +1 -1
- package/web-shell/assets/{journeyDiagram-JHISSGLW-DsvEw51Y.js → journeyDiagram-JHISSGLW-B7IICk-E.js} +1 -1
- package/web-shell/assets/{kanban-definition-UN3LZRKU-lFFjZEYd.js → kanban-definition-UN3LZRKU-BYF0OKhx.js} +1 -1
- package/web-shell/assets/{linear-Bo5bWzvo.js → linear-GWWguGfD.js} +1 -1
- package/web-shell/assets/{mermaid.core-C_HKMJx5.js → mermaid.core-JqtkxvCl.js} +5 -5
- package/web-shell/assets/{mindmap-definition-RKZ34NQL-DlV-NUTs.js → mindmap-definition-RKZ34NQL-B0MmHsZ6.js} +1 -1
- package/web-shell/assets/{pieDiagram-4H26LBE5-B2e6FH2a.js → pieDiagram-4H26LBE5-DhImUZLQ.js} +1 -1
- package/web-shell/assets/{quadrantDiagram-W4KKPZXB-D75kSk-b.js → quadrantDiagram-W4KKPZXB-DGeSC3DT.js} +1 -1
- package/web-shell/assets/{requirementDiagram-4Y6WPE33-CQ6xakhM.js → requirementDiagram-4Y6WPE33-DkspY6Re.js} +1 -1
- package/web-shell/assets/{sankeyDiagram-5OEKKPKP-J_XTKrcY.js → sankeyDiagram-5OEKKPKP-CaOofS2x.js} +1 -1
- package/web-shell/assets/{sequenceDiagram-3UESZ5HK-D7jTcBtf.js → sequenceDiagram-3UESZ5HK-DFQ_kFnN.js} +1 -1
- package/web-shell/assets/{stateDiagram-AJRCARHV-CrlM_OT3.js → stateDiagram-AJRCARHV-D3snw0Tz.js} +1 -1
- package/web-shell/assets/stateDiagram-v2-BHNVJYJU-BbSm_9d0.js +1 -0
- package/web-shell/assets/{timeline-definition-PNZ67QCA-5oZi76Ef.js → timeline-definition-PNZ67QCA-l4zH8nLM.js} +1 -1
- package/web-shell/assets/{vennDiagram-CIIHVFJN-DO5YptPK.js → vennDiagram-CIIHVFJN-BnRlA98M.js} +1 -1
- package/web-shell/assets/{wardley-L42UT6IY-4t1eJDvM.js → wardley-L42UT6IY-BS0xUdmd.js} +1 -1
- package/web-shell/assets/{wardleyDiagram-YWT4CUSO-DKZc661S.js → wardleyDiagram-YWT4CUSO-DKGBUWyQ.js} +1 -1
- package/web-shell/assets/{xychartDiagram-2RQKCTM6-su9hp08G.js → xychartDiagram-2RQKCTM6-DVb2HuOB.js} +1 -1
- package/web-shell/index.html +2 -2
- package/web-shell/assets/channel-BNf1dW-j.js +0 -1
- package/web-shell/assets/classDiagram-4FO5ZUOK-uOIGlzgi.js +0 -1
- package/web-shell/assets/classDiagram-v2-Q7XG4LA2-uOIGlzgi.js +0 -1
- package/web-shell/assets/index-CnE2ur2L.js +0 -779
- package/web-shell/assets/index-hSKXrlSE.css +0 -5
- package/web-shell/assets/stateDiagram-v2-BHNVJYJU-Bs4TK_84.js +0 -1
|
@@ -1,5 +1,21 @@
|
|
|
1
1
|
// Force strict mode and setup for ESM
|
|
2
2
|
"use strict";
|
|
3
|
+
import {
|
|
4
|
+
LOAD_REPLAY_BULK_MODE,
|
|
5
|
+
LOAD_REPLAY_META_KEY,
|
|
6
|
+
LOAD_REPLAY_MODE_META_KEY,
|
|
7
|
+
LOAD_REPLAY_VERSION,
|
|
8
|
+
MID_TURN_QUEUE_DRAIN_METHOD
|
|
9
|
+
} from "./chunk-AGHU5VRK.js";
|
|
10
|
+
import {
|
|
11
|
+
DEFAULT_RING_SIZE,
|
|
12
|
+
EVENT_SCHEMA_VERSION,
|
|
13
|
+
EventBus,
|
|
14
|
+
serializedBridgeEventByteLength
|
|
15
|
+
} from "./chunk-3UP777ZS.js";
|
|
16
|
+
import {
|
|
17
|
+
normalizeCompactedReplayMaxBytes
|
|
18
|
+
} from "./chunk-GLE2YUPU.js";
|
|
3
19
|
import {
|
|
4
20
|
MCP_RESTART_SERVER_DEADLINE_MS
|
|
5
21
|
} from "./chunk-P7M4GA57.js";
|
|
@@ -22,22 +38,10 @@ import {
|
|
|
22
38
|
SessionShellDisabledError,
|
|
23
39
|
WorkspaceMismatchError,
|
|
24
40
|
isNotCurrentlyGeneratingCancelError
|
|
25
|
-
} from "./chunk-
|
|
26
|
-
import {
|
|
27
|
-
LOAD_REPLAY_BULK_MODE,
|
|
28
|
-
LOAD_REPLAY_META_KEY,
|
|
29
|
-
LOAD_REPLAY_MODE_META_KEY,
|
|
30
|
-
LOAD_REPLAY_VERSION,
|
|
31
|
-
MID_TURN_QUEUE_DRAIN_METHOD
|
|
32
|
-
} from "./chunk-AGHU5VRK.js";
|
|
41
|
+
} from "./chunk-GGQQA4JW.js";
|
|
33
42
|
import {
|
|
34
43
|
canonicalizeWorkspace
|
|
35
44
|
} from "./chunk-ER3BKOLB.js";
|
|
36
|
-
import {
|
|
37
|
-
DEFAULT_RING_SIZE,
|
|
38
|
-
EVENT_SCHEMA_VERSION,
|
|
39
|
-
EventBus
|
|
40
|
-
} from "./chunk-G7ZG7CA6.js";
|
|
41
45
|
import {
|
|
42
46
|
ClientSideConnection,
|
|
43
47
|
PROTOCOL_VERSION,
|
|
@@ -45,7 +49,7 @@ import {
|
|
|
45
49
|
} from "./chunk-VRDMOSQS.js";
|
|
46
50
|
import {
|
|
47
51
|
defaultSpawnChannelFactory
|
|
48
|
-
} from "./chunk-
|
|
52
|
+
} from "./chunk-BOBOCR5H.js";
|
|
49
53
|
import {
|
|
50
54
|
BridgeChannelClosedError,
|
|
51
55
|
BridgeTimeoutError,
|
|
@@ -54,15 +58,15 @@ import {
|
|
|
54
58
|
STATUS_SCHEMA_VERSION,
|
|
55
59
|
createIdleWorkspaceExtensionsStatus,
|
|
56
60
|
createIdleWorkspaceHooksStatus
|
|
57
|
-
} from "./chunk-
|
|
61
|
+
} from "./chunk-LAXNEOBG.js";
|
|
58
62
|
import {
|
|
59
63
|
ShellExecutionService,
|
|
60
64
|
TrustGateError
|
|
61
|
-
} from "./chunk-
|
|
65
|
+
} from "./chunk-3GNOQZDC.js";
|
|
62
66
|
import {
|
|
63
67
|
DAEMON_TRACEPARENT_META_KEY,
|
|
64
68
|
DAEMON_TRACESTATE_META_KEY
|
|
65
|
-
} from "./chunk-
|
|
69
|
+
} from "./chunk-BUZ6HGL4.js";
|
|
66
70
|
import {
|
|
67
71
|
init_esbuild_shims
|
|
68
72
|
} from "./chunk-A4BMJM77.js";
|
|
@@ -79,6 +83,7 @@ import * as path3 from "node:path";
|
|
|
79
83
|
init_esbuild_shims();
|
|
80
84
|
var TURN_BOUNDARY_TYPES = /* @__PURE__ */ new Set(["turn_complete", "turn_error"]);
|
|
81
85
|
var TRANSIENT_TYPES = /* @__PURE__ */ new Set([
|
|
86
|
+
"history_truncated",
|
|
82
87
|
"slow_client_warning",
|
|
83
88
|
"client_evicted",
|
|
84
89
|
"replay_complete",
|
|
@@ -88,17 +93,28 @@ var LATEST_WINS_UPDATES = /* @__PURE__ */ new Set([
|
|
|
88
93
|
"available_commands_update",
|
|
89
94
|
"current_mode_update"
|
|
90
95
|
]);
|
|
96
|
+
var REPLAY_SEGMENT_COMPACT_THRESHOLD = 64;
|
|
91
97
|
var TurnBoundaryCompactionEngine = class {
|
|
92
98
|
static {
|
|
93
99
|
__name(this, "TurnBoundaryCompactionEngine");
|
|
94
100
|
}
|
|
95
|
-
|
|
101
|
+
maxReplayBytes;
|
|
102
|
+
onReplayWindowEviction;
|
|
103
|
+
replaySegments = [];
|
|
104
|
+
replaySegmentStart = 0;
|
|
105
|
+
replayBytes = 0;
|
|
96
106
|
liveJournal = [];
|
|
97
107
|
lastEventId = 0;
|
|
98
108
|
closed = false;
|
|
109
|
+
truncatedEvents = 0;
|
|
110
|
+
truncatedTurns = 0;
|
|
99
111
|
slots = [];
|
|
100
112
|
toolSlotIndex = /* @__PURE__ */ new Map();
|
|
101
113
|
textSlotIndex = /* @__PURE__ */ new Map();
|
|
114
|
+
constructor(opts = {}) {
|
|
115
|
+
this.maxReplayBytes = normalizeCompactedReplayMaxBytes(opts.maxReplayBytes);
|
|
116
|
+
this.onReplayWindowEviction = opts.onReplayWindowEviction;
|
|
117
|
+
}
|
|
102
118
|
ingest(event) {
|
|
103
119
|
if (this.closed) return;
|
|
104
120
|
if (event.id !== void 0) {
|
|
@@ -117,16 +133,39 @@ var TurnBoundaryCompactionEngine = class {
|
|
|
117
133
|
this.slots.push({ kind: "misc", event });
|
|
118
134
|
}
|
|
119
135
|
snapshot() {
|
|
136
|
+
const compactedTurns = this.flattenReplaySegments();
|
|
137
|
+
if (this.truncatedEvents > 0) {
|
|
138
|
+
compactedTurns.unshift(
|
|
139
|
+
this.makeHistoryTruncatedEvent(compactedTurns.length)
|
|
140
|
+
);
|
|
141
|
+
}
|
|
120
142
|
return {
|
|
121
|
-
compactedTurns
|
|
143
|
+
compactedTurns,
|
|
122
144
|
liveJournal: this.liveJournal.slice(),
|
|
123
145
|
lastEventId: this.lastEventId
|
|
124
146
|
};
|
|
125
147
|
}
|
|
126
148
|
seed(snapshot) {
|
|
127
149
|
if (this.closed) return;
|
|
128
|
-
this.
|
|
150
|
+
this.resetReplayWindow();
|
|
129
151
|
this.lastEventId = snapshot.lastEventId;
|
|
152
|
+
for (const event of snapshot.compactedTurns) {
|
|
153
|
+
if (TRANSIENT_TYPES.has(event.type)) continue;
|
|
154
|
+
this.addReplaySegment([event], 0);
|
|
155
|
+
}
|
|
156
|
+
this.liveJournal = [];
|
|
157
|
+
this.slots = [];
|
|
158
|
+
this.toolSlotIndex.clear();
|
|
159
|
+
this.textSlotIndex.clear();
|
|
160
|
+
}
|
|
161
|
+
seedReplayEvents(events) {
|
|
162
|
+
if (this.closed) return;
|
|
163
|
+
this.resetReplayWindow();
|
|
164
|
+
for (const event of events) {
|
|
165
|
+
this.recordLastEventId(event);
|
|
166
|
+
if (TRANSIENT_TYPES.has(event.type)) continue;
|
|
167
|
+
this.addReplaySegment([event], 0);
|
|
168
|
+
}
|
|
130
169
|
this.liveJournal = [];
|
|
131
170
|
this.slots = [];
|
|
132
171
|
this.toolSlotIndex.clear();
|
|
@@ -135,7 +174,7 @@ var TurnBoundaryCompactionEngine = class {
|
|
|
135
174
|
close() {
|
|
136
175
|
if (this.closed) return;
|
|
137
176
|
this.closed = true;
|
|
138
|
-
this.
|
|
177
|
+
this.resetReplayWindow();
|
|
139
178
|
this.liveJournal = [];
|
|
140
179
|
this.slots = [];
|
|
141
180
|
this.toolSlotIndex.clear();
|
|
@@ -272,12 +311,94 @@ var TurnBoundaryCompactionEngine = class {
|
|
|
272
311
|
}
|
|
273
312
|
}
|
|
274
313
|
compacted.push(boundaryEvent);
|
|
275
|
-
this.
|
|
314
|
+
this.addReplaySegment(compacted, 1);
|
|
276
315
|
this.liveJournal = [];
|
|
277
316
|
this.slots = [];
|
|
278
317
|
this.toolSlotIndex.clear();
|
|
279
318
|
this.textSlotIndex.clear();
|
|
280
319
|
}
|
|
320
|
+
recordLastEventId(event) {
|
|
321
|
+
if (event.id !== void 0) {
|
|
322
|
+
this.lastEventId = event.id;
|
|
323
|
+
}
|
|
324
|
+
}
|
|
325
|
+
addReplaySegment(events, turnCount) {
|
|
326
|
+
if (events.length === 0) return;
|
|
327
|
+
const bytes = events.reduce(
|
|
328
|
+
(sum, event) => sum + serializedBridgeEventByteLength(event),
|
|
329
|
+
0
|
|
330
|
+
);
|
|
331
|
+
this.replaySegments.push({ events: events.slice(), bytes, turnCount });
|
|
332
|
+
this.replayBytes += bytes;
|
|
333
|
+
this.enforceReplayWindow();
|
|
334
|
+
}
|
|
335
|
+
enforceReplayWindow() {
|
|
336
|
+
let droppedSegmentCount = 0;
|
|
337
|
+
let droppedBytes = 0;
|
|
338
|
+
let droppedEvents = 0;
|
|
339
|
+
let droppedTurns = 0;
|
|
340
|
+
while (this.replayBytes > this.maxReplayBytes && this.activeReplaySegmentCount() > 1) {
|
|
341
|
+
const dropped = this.replaySegments[this.replaySegmentStart];
|
|
342
|
+
this.replaySegmentStart += 1;
|
|
343
|
+
droppedSegmentCount += 1;
|
|
344
|
+
droppedBytes += dropped.bytes;
|
|
345
|
+
droppedEvents += dropped.events.length;
|
|
346
|
+
droppedTurns += dropped.turnCount;
|
|
347
|
+
this.replayBytes -= dropped.bytes;
|
|
348
|
+
this.truncatedEvents += dropped.events.length;
|
|
349
|
+
this.truncatedTurns += dropped.turnCount;
|
|
350
|
+
}
|
|
351
|
+
if (droppedSegmentCount > 0) {
|
|
352
|
+
this.compactReplaySegmentQueueIfNeeded();
|
|
353
|
+
this.notifyReplayWindowEviction({
|
|
354
|
+
droppedBytes,
|
|
355
|
+
droppedEvents,
|
|
356
|
+
droppedSegments: droppedSegmentCount,
|
|
357
|
+
droppedTurns,
|
|
358
|
+
maxBytes: this.maxReplayBytes,
|
|
359
|
+
retainedBytes: this.replayBytes,
|
|
360
|
+
retainedEvents: this.flattenReplaySegments().length
|
|
361
|
+
});
|
|
362
|
+
}
|
|
363
|
+
}
|
|
364
|
+
flattenReplaySegments() {
|
|
365
|
+
return this.replaySegments.slice(this.replaySegmentStart).flatMap((segment) => segment.events);
|
|
366
|
+
}
|
|
367
|
+
activeReplaySegmentCount() {
|
|
368
|
+
return this.replaySegments.length - this.replaySegmentStart;
|
|
369
|
+
}
|
|
370
|
+
compactReplaySegmentQueueIfNeeded() {
|
|
371
|
+
if (this.replaySegmentStart < REPLAY_SEGMENT_COMPACT_THRESHOLD) return;
|
|
372
|
+
this.replaySegments.splice(0, this.replaySegmentStart);
|
|
373
|
+
this.replaySegmentStart = 0;
|
|
374
|
+
}
|
|
375
|
+
notifyReplayWindowEviction(eviction) {
|
|
376
|
+
try {
|
|
377
|
+
this.onReplayWindowEviction?.(eviction);
|
|
378
|
+
} catch {
|
|
379
|
+
}
|
|
380
|
+
}
|
|
381
|
+
makeHistoryTruncatedEvent(retainedEvents) {
|
|
382
|
+
return {
|
|
383
|
+
v: EVENT_SCHEMA_VERSION,
|
|
384
|
+
type: "history_truncated",
|
|
385
|
+
data: {
|
|
386
|
+
reason: "replay_window_exceeded",
|
|
387
|
+
truncatedEvents: this.truncatedEvents,
|
|
388
|
+
retainedEvents,
|
|
389
|
+
maxBytes: this.maxReplayBytes,
|
|
390
|
+
...this.truncatedTurns > 0 ? { truncatedTurns: this.truncatedTurns } : {},
|
|
391
|
+
fullTranscriptAvailable: false
|
|
392
|
+
}
|
|
393
|
+
};
|
|
394
|
+
}
|
|
395
|
+
resetReplayWindow() {
|
|
396
|
+
this.replaySegments = [];
|
|
397
|
+
this.replaySegmentStart = 0;
|
|
398
|
+
this.replayBytes = 0;
|
|
399
|
+
this.truncatedEvents = 0;
|
|
400
|
+
this.truncatedTurns = 0;
|
|
401
|
+
}
|
|
281
402
|
};
|
|
282
403
|
function makeMergedSessionUpdateEvent(sessionUpdate, text, eventId, meta, envelopeMeta) {
|
|
283
404
|
return {
|
|
@@ -3276,6 +3397,18 @@ function isBridgeAutoMemoryTopic(value) {
|
|
|
3276
3397
|
return value === "user" || value === "feedback" || value === "project" || value === "reference";
|
|
3277
3398
|
}
|
|
3278
3399
|
__name(isBridgeAutoMemoryTopic, "isBridgeAutoMemoryTopic");
|
|
3400
|
+
function touchedScopesFromTopics(topics) {
|
|
3401
|
+
const scopes = /* @__PURE__ */ new Set();
|
|
3402
|
+
for (const topic of topics) {
|
|
3403
|
+
scopes.add(topic === "user" || topic === "feedback" ? "user" : "project");
|
|
3404
|
+
}
|
|
3405
|
+
return ["user", "project"].filter((scope) => scopes.has(scope));
|
|
3406
|
+
}
|
|
3407
|
+
__name(touchedScopesFromTopics, "touchedScopesFromTopics");
|
|
3408
|
+
function isBridgeMemoryScope(value) {
|
|
3409
|
+
return value === "user" || value === "project";
|
|
3410
|
+
}
|
|
3411
|
+
__name(isBridgeMemoryScope, "isBridgeMemoryScope");
|
|
3279
3412
|
function parseWorkspaceMemoryForgetMatch(value) {
|
|
3280
3413
|
if (value === null || typeof value !== "object" || Array.isArray(value)) {
|
|
3281
3414
|
return null;
|
|
@@ -3299,14 +3432,17 @@ function parseWorkspaceMemoryForgetResult(response) {
|
|
|
3299
3432
|
const summary = record["summary"];
|
|
3300
3433
|
const removedEntries = record["removedEntries"];
|
|
3301
3434
|
const touchedTopics = record["touchedTopics"];
|
|
3435
|
+
const touchedScopes = record["touchedScopes"];
|
|
3302
3436
|
const parsedRemovedEntries = Array.isArray(removedEntries) ? removedEntries.map(parseWorkspaceMemoryForgetMatch) : [];
|
|
3303
|
-
if (summary !== void 0 && typeof summary !== "string" || !Array.isArray(removedEntries) || parsedRemovedEntries.some((entry) => entry === null) || !Array.isArray(touchedTopics) || !touchedTopics.every(isBridgeAutoMemoryTopic)) {
|
|
3437
|
+
if (summary !== void 0 && typeof summary !== "string" || !Array.isArray(removedEntries) || parsedRemovedEntries.some((entry) => entry === null) || !Array.isArray(touchedTopics) || !touchedTopics.every(isBridgeAutoMemoryTopic) || touchedScopes !== void 0 && (!Array.isArray(touchedScopes) || !touchedScopes.every(isBridgeMemoryScope))) {
|
|
3304
3438
|
throw new Error("Malformed workspace memory forget response");
|
|
3305
3439
|
}
|
|
3440
|
+
const parsedTouchedTopics = touchedTopics;
|
|
3306
3441
|
return {
|
|
3307
3442
|
...summary === void 0 ? {} : { summary },
|
|
3308
3443
|
removedEntries: parsedRemovedEntries,
|
|
3309
|
-
touchedTopics
|
|
3444
|
+
touchedTopics: parsedTouchedTopics,
|
|
3445
|
+
touchedScopes: touchedScopes === void 0 ? touchedScopesFromTopics(parsedTouchedTopics) : touchedScopes
|
|
3310
3446
|
};
|
|
3311
3447
|
}
|
|
3312
3448
|
__name(parseWorkspaceMemoryForgetResult, "parseWorkspaceMemoryForgetResult");
|
|
@@ -3523,6 +3659,18 @@ function createAcpSessionBridge(opts) {
|
|
|
3523
3659
|
} else {
|
|
3524
3660
|
maxSessions = opts.maxSessions;
|
|
3525
3661
|
}
|
|
3662
|
+
const reserveFreshSession = /* @__PURE__ */ __name((context) => opts.freshSessionAdmission?.(context), "reserveFreshSession");
|
|
3663
|
+
const releaseFreshSessionReservation = /* @__PURE__ */ __name((reservation) => {
|
|
3664
|
+
if (!reservation) return;
|
|
3665
|
+
try {
|
|
3666
|
+
reservation.release();
|
|
3667
|
+
} catch (err) {
|
|
3668
|
+
opts.onDiagnosticLine?.(
|
|
3669
|
+
`qwen serve: fresh session admission release failed: ${err instanceof Error ? err.message : String(err)}`,
|
|
3670
|
+
"warn"
|
|
3671
|
+
);
|
|
3672
|
+
}
|
|
3673
|
+
}, "releaseFreshSessionReservation");
|
|
3526
3674
|
if (defaultSessionScope !== "single" && defaultSessionScope !== "thread") {
|
|
3527
3675
|
throw new TypeError(
|
|
3528
3676
|
`Invalid sessionScope: ${JSON.stringify(defaultSessionScope)}. Expected 'single' or 'thread'.`
|
|
@@ -3534,6 +3682,9 @@ function createAcpSessionBridge(opts) {
|
|
|
3534
3682
|
`Invalid eventRingSize: ${opts.eventRingSize}. Must be a positive integer in [1, ${MAX_EVENT_RING_SIZE}].`
|
|
3535
3683
|
);
|
|
3536
3684
|
}
|
|
3685
|
+
const compactedReplayMaxBytes = normalizeCompactedReplayMaxBytes(
|
|
3686
|
+
opts.compactedReplayMaxBytes
|
|
3687
|
+
);
|
|
3537
3688
|
const channelFactory = opts.channelFactory ?? defaultSpawnChannelFactory;
|
|
3538
3689
|
const childEnvOverrides = opts.childEnvOverrides ? Object.freeze({ ...opts.childEnvOverrides }) : Object.freeze({});
|
|
3539
3690
|
const initTimeoutMs = opts.initializeTimeoutMs ?? DEFAULT_INIT_TIMEOUT_MS;
|
|
@@ -3963,7 +4114,7 @@ function createAcpSessionBridge(opts) {
|
|
|
3963
4114
|
}
|
|
3964
4115
|
}
|
|
3965
4116
|
__name(ensureChannel, "ensureChannel");
|
|
3966
|
-
async function doSpawn(modelServiceId, effectiveScope, requestedClientId) {
|
|
4117
|
+
async function doSpawn(modelServiceId, effectiveScope, requestedClientId, onSessionRegistered) {
|
|
3967
4118
|
const ci = await ensureChannel();
|
|
3968
4119
|
ci.sessionSpawnsInFlight++;
|
|
3969
4120
|
let sessionRegistered = false;
|
|
@@ -4004,6 +4155,7 @@ function createAcpSessionBridge(opts) {
|
|
|
4004
4155
|
boundWorkspace
|
|
4005
4156
|
);
|
|
4006
4157
|
sessionRegistered = true;
|
|
4158
|
+
onSessionRegistered?.();
|
|
4007
4159
|
seedSnapshotCaches(entry, newSessionResp);
|
|
4008
4160
|
const clientId = registerClient(entry, requestedClientId);
|
|
4009
4161
|
if (effectiveScope === "single" && !defaultEntry) defaultEntry = entry;
|
|
@@ -4280,7 +4432,18 @@ function createAcpSessionBridge(opts) {
|
|
|
4280
4432
|
);
|
|
4281
4433
|
}
|
|
4282
4434
|
}, "broadcastWorkspaceEvent");
|
|
4283
|
-
const createSessionEventBus = /* @__PURE__ */ __name(() => new EventBus(
|
|
4435
|
+
const createSessionEventBus = /* @__PURE__ */ __name(() => new EventBus(
|
|
4436
|
+
eventRingSize,
|
|
4437
|
+
void 0,
|
|
4438
|
+
new TurnBoundaryCompactionEngine({
|
|
4439
|
+
maxReplayBytes: compactedReplayMaxBytes,
|
|
4440
|
+
onReplayWindowEviction: /* @__PURE__ */ __name((eviction) => {
|
|
4441
|
+
teeServeDebugLine(
|
|
4442
|
+
`replay window evicted ${JSON.stringify(eviction)}`
|
|
4443
|
+
);
|
|
4444
|
+
}, "onReplayWindowEviction")
|
|
4445
|
+
})
|
|
4446
|
+
), "createSessionEventBus");
|
|
4284
4447
|
const publishModelSwitched = /* @__PURE__ */ __name((entry, modelId, originatorClientId) => {
|
|
4285
4448
|
entry.currentModelId = modelId;
|
|
4286
4449
|
entry.modelPublishGeneration++;
|
|
@@ -4470,7 +4633,7 @@ function createAcpSessionBridge(opts) {
|
|
|
4470
4633
|
}
|
|
4471
4634
|
return { lastEventId: snapshot.lastEventId, ...replayStatus };
|
|
4472
4635
|
}, "replayFieldsFor");
|
|
4473
|
-
async function restoreSession(action, req) {
|
|
4636
|
+
async function restoreSession(action, req, options = {}) {
|
|
4474
4637
|
if (shuttingDown) {
|
|
4475
4638
|
throw new Error("AcpSessionBridge is shutting down");
|
|
4476
4639
|
}
|
|
@@ -4533,6 +4696,17 @@ function createAcpSessionBridge(opts) {
|
|
|
4533
4696
|
let registeredEntry;
|
|
4534
4697
|
let ci;
|
|
4535
4698
|
const coalesceState = { count: 0 };
|
|
4699
|
+
const admission = options.skipFreshSessionAdmission === true ? void 0 : reserveFreshSession({
|
|
4700
|
+
operation: action,
|
|
4701
|
+
workspaceCwd: workspaceKey,
|
|
4702
|
+
sessionId: req.sessionId
|
|
4703
|
+
});
|
|
4704
|
+
let admissionReleased = false;
|
|
4705
|
+
const releaseAdmissionOnce = /* @__PURE__ */ __name(() => {
|
|
4706
|
+
if (admissionReleased) return;
|
|
4707
|
+
admissionReleased = true;
|
|
4708
|
+
releaseFreshSessionReservation(admission);
|
|
4709
|
+
}, "releaseAdmissionOnce");
|
|
4536
4710
|
const promise = (async () => {
|
|
4537
4711
|
pendingRestoreEvents.set(req.sessionId, restoreEvents);
|
|
4538
4712
|
ci = await ensureChannel();
|
|
@@ -4638,6 +4812,7 @@ function createAcpSessionBridge(opts) {
|
|
|
4638
4812
|
restoreEvents,
|
|
4639
4813
|
{ drainEarlyEvents: replayUpdates.length === 0 }
|
|
4640
4814
|
);
|
|
4815
|
+
releaseAdmissionOnce();
|
|
4641
4816
|
entry.restoreState = state;
|
|
4642
4817
|
if (replayPartial === true) {
|
|
4643
4818
|
entry.restoreReplayPartial = true;
|
|
@@ -4664,6 +4839,7 @@ function createAcpSessionBridge(opts) {
|
|
|
4664
4839
|
...replayFieldsFor(entry, action)
|
|
4665
4840
|
};
|
|
4666
4841
|
})().finally(async () => {
|
|
4842
|
+
releaseAdmissionOnce();
|
|
4667
4843
|
ci?.pendingRestoreIds.delete(req.sessionId);
|
|
4668
4844
|
ci?.client.clearRestoreInFlight(req.sessionId);
|
|
4669
4845
|
pendingRestoreEvents.delete(req.sessionId);
|
|
@@ -4788,6 +4964,7 @@ function createAcpSessionBridge(opts) {
|
|
|
4788
4964
|
maxSessions: maxSessions === Infinity ? null : maxSessions,
|
|
4789
4965
|
maxPendingPromptsPerSession: maxPendingPromptsPerSession === Infinity ? null : maxPendingPromptsPerSession,
|
|
4790
4966
|
eventRingSize,
|
|
4967
|
+
compactedReplayMaxBytes,
|
|
4791
4968
|
channelIdleTimeoutMs: resolvedChannelIdleTimeoutMs(),
|
|
4792
4969
|
sessionIdleTimeoutMs
|
|
4793
4970
|
},
|
|
@@ -4917,12 +5094,28 @@ function createAcpSessionBridge(opts) {
|
|
|
4917
5094
|
if (byId.size + inFlightSpawns.size + inFlightRestores.size >= maxSessions) {
|
|
4918
5095
|
throw new SessionLimitExceededError(maxSessions);
|
|
4919
5096
|
}
|
|
4920
|
-
const
|
|
5097
|
+
const admission = reserveFreshSession({
|
|
5098
|
+
operation: "spawn",
|
|
5099
|
+
workspaceCwd: workspaceKey
|
|
5100
|
+
});
|
|
5101
|
+
let admissionReleased = false;
|
|
5102
|
+
const releaseAdmissionOnce = /* @__PURE__ */ __name(() => {
|
|
5103
|
+
if (admissionReleased) return;
|
|
5104
|
+
admissionReleased = true;
|
|
5105
|
+
releaseFreshSessionReservation(admission);
|
|
5106
|
+
}, "releaseAdmissionOnce");
|
|
5107
|
+
const promise = doSpawn(
|
|
5108
|
+
req.modelServiceId,
|
|
5109
|
+
effectiveScope,
|
|
5110
|
+
req.clientId,
|
|
5111
|
+
releaseAdmissionOnce
|
|
5112
|
+
);
|
|
4921
5113
|
const tracker = effectiveScope === "single" ? workspaceKey : `${workspaceKey}#${randomUUID2()}`;
|
|
4922
5114
|
inFlightSpawns.set(tracker, promise);
|
|
4923
5115
|
try {
|
|
4924
5116
|
return await promise;
|
|
4925
5117
|
} finally {
|
|
5118
|
+
releaseAdmissionOnce();
|
|
4926
5119
|
inFlightSpawns.delete(tracker);
|
|
4927
5120
|
}
|
|
4928
5121
|
},
|
|
@@ -5379,67 +5572,89 @@ function createAcpSessionBridge(opts) {
|
|
|
5379
5572
|
if (byId.size + inFlightSpawns.size + inFlightRestores.size >= maxSessions) {
|
|
5380
5573
|
throw new SessionLimitExceededError(maxSessions);
|
|
5381
5574
|
}
|
|
5382
|
-
const
|
|
5383
|
-
|
|
5384
|
-
|
|
5385
|
-
|
|
5386
|
-
|
|
5387
|
-
|
|
5388
|
-
|
|
5389
|
-
|
|
5390
|
-
|
|
5391
|
-
|
|
5392
|
-
|
|
5393
|
-
throw new Error(
|
|
5394
|
-
`branchSession: agent returned invalid response: ${JSON.stringify(result)}`
|
|
5395
|
-
);
|
|
5396
|
-
}
|
|
5397
|
-
const rawBranchName = result.displayName ?? result.title;
|
|
5398
|
-
const branchDisplayName = typeof rawBranchName === "string" ? rawBranchName : result.newSessionId.slice(0, 8);
|
|
5399
|
-
let restored;
|
|
5575
|
+
const admission = reserveFreshSession({
|
|
5576
|
+
operation: "branch",
|
|
5577
|
+
workspaceCwd: boundWorkspace,
|
|
5578
|
+
sourceSessionId: sessionId
|
|
5579
|
+
});
|
|
5580
|
+
let admissionReleased = false;
|
|
5581
|
+
const releaseAdmissionOnce = /* @__PURE__ */ __name(() => {
|
|
5582
|
+
if (admissionReleased) return;
|
|
5583
|
+
admissionReleased = true;
|
|
5584
|
+
releaseFreshSessionReservation(admission);
|
|
5585
|
+
}, "releaseAdmissionOnce");
|
|
5400
5586
|
try {
|
|
5401
|
-
|
|
5402
|
-
|
|
5403
|
-
|
|
5404
|
-
|
|
5405
|
-
|
|
5406
|
-
|
|
5407
|
-
|
|
5408
|
-
|
|
5587
|
+
const ci = await ensureChannel();
|
|
5588
|
+
const result = await withTimeout(
|
|
5589
|
+
ci.connection.extMethod(SERVE_CONTROL_EXT_METHODS.sessionBranch, {
|
|
5590
|
+
sessionId,
|
|
5591
|
+
cwd: boundWorkspace,
|
|
5592
|
+
name: req.name
|
|
5593
|
+
}),
|
|
5594
|
+
initTimeoutMs,
|
|
5595
|
+
"branchSession"
|
|
5409
5596
|
);
|
|
5597
|
+
if (!result || typeof result.newSessionId !== "string") {
|
|
5598
|
+
throw new Error(
|
|
5599
|
+
`branchSession: agent returned invalid response: ${JSON.stringify(result)}`
|
|
5600
|
+
);
|
|
5601
|
+
}
|
|
5602
|
+
const rawBranchName = result.displayName ?? result.title;
|
|
5603
|
+
const branchDisplayName = typeof rawBranchName === "string" ? rawBranchName : result.newSessionId.slice(0, 8);
|
|
5604
|
+
let restored;
|
|
5410
5605
|
try {
|
|
5411
|
-
await
|
|
5412
|
-
|
|
5413
|
-
{
|
|
5606
|
+
restored = await restoreSession(
|
|
5607
|
+
"load",
|
|
5608
|
+
{
|
|
5609
|
+
sessionId: result.newSessionId,
|
|
5610
|
+
workspaceCwd: boundWorkspace,
|
|
5611
|
+
clientId: context?.clientId
|
|
5612
|
+
},
|
|
5613
|
+
{
|
|
5614
|
+
skipFreshSessionAdmission: true
|
|
5615
|
+
}
|
|
5414
5616
|
);
|
|
5415
|
-
|
|
5617
|
+
releaseAdmissionOnce();
|
|
5618
|
+
} catch (restoreErr) {
|
|
5416
5619
|
writeStderrLine(
|
|
5417
|
-
`qwen serve: branchSession
|
|
5620
|
+
`qwen serve: branchSession load failed for ${result.newSessionId}, attempting cleanup...`
|
|
5418
5621
|
);
|
|
5622
|
+
try {
|
|
5623
|
+
await ci.connection.extMethod(
|
|
5624
|
+
SERVE_CONTROL_EXT_METHODS.sessionClose,
|
|
5625
|
+
{ sessionId: result.newSessionId, cwd: boundWorkspace }
|
|
5626
|
+
);
|
|
5627
|
+
} catch (cleanupErr) {
|
|
5628
|
+
writeStderrLine(
|
|
5629
|
+
`qwen serve: branchSession cleanup of ${result.newSessionId} failed: ${cleanupErr instanceof Error ? cleanupErr.message : cleanupErr}`
|
|
5630
|
+
);
|
|
5631
|
+
}
|
|
5632
|
+
throw restoreErr;
|
|
5419
5633
|
}
|
|
5420
|
-
|
|
5634
|
+
const newEntry = byId.get(result.newSessionId);
|
|
5635
|
+
if (newEntry) newEntry.displayName = branchDisplayName;
|
|
5636
|
+
const eventData = {
|
|
5637
|
+
sourceSessionId: sessionId,
|
|
5638
|
+
newSessionId: result.newSessionId,
|
|
5639
|
+
displayName: branchDisplayName
|
|
5640
|
+
};
|
|
5641
|
+
const branchEnvelope = {
|
|
5642
|
+
type: "session_branched",
|
|
5643
|
+
data: eventData,
|
|
5644
|
+
...originatorClientId ? { originatorClientId } : {}
|
|
5645
|
+
};
|
|
5646
|
+
newEntry?.events.publish(branchEnvelope);
|
|
5647
|
+
return {
|
|
5648
|
+
...restored,
|
|
5649
|
+
displayName: branchDisplayName,
|
|
5650
|
+
forkedFrom: {
|
|
5651
|
+
sessionId,
|
|
5652
|
+
displayName: entry.displayName ?? sessionId.slice(0, 8)
|
|
5653
|
+
}
|
|
5654
|
+
};
|
|
5655
|
+
} finally {
|
|
5656
|
+
releaseAdmissionOnce();
|
|
5421
5657
|
}
|
|
5422
|
-
const newEntry = byId.get(result.newSessionId);
|
|
5423
|
-
if (newEntry) newEntry.displayName = branchDisplayName;
|
|
5424
|
-
const eventData = {
|
|
5425
|
-
sourceSessionId: sessionId,
|
|
5426
|
-
newSessionId: result.newSessionId,
|
|
5427
|
-
displayName: branchDisplayName
|
|
5428
|
-
};
|
|
5429
|
-
const branchEnvelope = {
|
|
5430
|
-
type: "session_branched",
|
|
5431
|
-
data: eventData,
|
|
5432
|
-
...originatorClientId ? { originatorClientId } : {}
|
|
5433
|
-
};
|
|
5434
|
-
newEntry?.events.publish(branchEnvelope);
|
|
5435
|
-
return {
|
|
5436
|
-
...restored,
|
|
5437
|
-
displayName: branchDisplayName,
|
|
5438
|
-
forkedFrom: {
|
|
5439
|
-
sessionId,
|
|
5440
|
-
displayName: entry.displayName ?? sessionId.slice(0, 8)
|
|
5441
|
-
}
|
|
5442
|
-
};
|
|
5443
5658
|
});
|
|
5444
5659
|
entry.promptQueue = branchResult.then(
|
|
5445
5660
|
() => void 0,
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
import {
|
|
4
4
|
Colors,
|
|
5
5
|
RowMouseController
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-WF4FAXDL.js";
|
|
7
7
|
import {
|
|
8
8
|
theme
|
|
9
9
|
} from "./chunk-IFEWJXFS.js";
|
|
@@ -11,18 +11,18 @@ import {
|
|
|
11
11
|
Box_default,
|
|
12
12
|
Text,
|
|
13
13
|
require_jsx_runtime
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-P3XEEI3X.js";
|
|
15
15
|
import {
|
|
16
16
|
require_react
|
|
17
17
|
} from "./chunk-KYMBIKIW.js";
|
|
18
18
|
import {
|
|
19
19
|
t
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-O33TBKDC.js";
|
|
21
21
|
import {
|
|
22
22
|
readManyFiles,
|
|
23
23
|
shouldRunVisionBridge,
|
|
24
24
|
stripTerminalControlSequences
|
|
25
|
-
} from "./chunk-
|
|
25
|
+
} from "./chunk-3GNOQZDC.js";
|
|
26
26
|
import {
|
|
27
27
|
emptyMcpResourceText,
|
|
28
28
|
formatMcpResourceContents,
|
|
@@ -6,20 +6,23 @@ import {
|
|
|
6
6
|
parseAcpBaseModelId,
|
|
7
7
|
resolveCliGenerationConfig,
|
|
8
8
|
sanitizeProviderBaseUrl
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-DIWVZ3VM.js";
|
|
10
|
+
import {
|
|
11
|
+
snapshotProcessEnv
|
|
12
|
+
} from "./chunk-O7FIRWJV.js";
|
|
10
13
|
import {
|
|
11
14
|
loadSettings
|
|
12
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-M7S4GK5Z.js";
|
|
13
16
|
import {
|
|
14
17
|
STATUS_SCHEMA_VERSION
|
|
15
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-LAXNEOBG.js";
|
|
16
19
|
import {
|
|
17
20
|
ModelsConfig,
|
|
18
21
|
resolveProviderProtocol
|
|
19
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-3GNOQZDC.js";
|
|
20
23
|
import {
|
|
21
24
|
APPROVAL_MODES
|
|
22
|
-
} from "./chunk-
|
|
25
|
+
} from "./chunk-5MBO76SL.js";
|
|
23
26
|
import {
|
|
24
27
|
tokenLimit
|
|
25
28
|
} from "./chunk-HW4N45EE.js";
|
|
@@ -42,10 +45,13 @@ function createWorkspaceProvidersStatusProvider(options = {}) {
|
|
|
42
45
|
__name(createWorkspaceProvidersStatusProvider, "createWorkspaceProvidersStatusProvider");
|
|
43
46
|
function buildWorkspaceProvidersStatus(workspaceCwd, acpChannelLive, options) {
|
|
44
47
|
try {
|
|
45
|
-
const loaded = loadSettings(
|
|
48
|
+
const loaded = loadSettings(
|
|
49
|
+
workspaceCwd,
|
|
50
|
+
options.env ? { skipLoadEnvironment: true } : true
|
|
51
|
+
);
|
|
46
52
|
const settings = loaded.merged;
|
|
47
|
-
const env = options.env ??
|
|
48
|
-
const selectedAuthType = settings.security?.auth?.selectedType ?? getAuthTypeFromEnv();
|
|
53
|
+
const env = options.env ?? snapshotProcessEnv();
|
|
54
|
+
const selectedAuthType = settings.security?.auth?.selectedType ?? getAuthTypeFromEnv(env);
|
|
49
55
|
const argv = {
|
|
50
56
|
model: options.argv?.model,
|
|
51
57
|
openaiApiKey: options.argv?.openaiApiKey,
|