@xopcai/xopc 0.0.474 → 0.0.476
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/browser-ext/manifest.json +1 -1
- package/dist/extensions/telegram/xopc.extension.json +1 -1
- package/dist/gateway/server/chunks.bin +1103 -1067
- package/dist/gateway/server/chunks.json +1 -1
- package/dist/gateway/server/schema.sql +13 -0
- package/dist/gateway/server/upgrades/281_session_agent_reactions.sql +13 -0
- package/dist/gateway/static/root/assets/{activity-store-nD2NH0C7.js → activity-store-BK11iD5x.js} +1 -1
- package/dist/gateway/static/root/assets/{agent-avatar-dicebear-D0JEEj2L.js → agent-avatar-dicebear-DZlgZHm9.js} +1 -1
- package/dist/gateway/static/root/assets/{agent-avatar-display-BxHA8hEW.js → agent-avatar-display-BDHjRaTK.js} +2 -2
- package/dist/gateway/static/root/assets/{agent-defaults-settings-panel-C7O0Aaq3.js → agent-defaults-settings-panel-Bicuh10_.js} +1 -1
- package/dist/gateway/static/root/assets/{agent-plugin-dialog--H7-gWL7.js → agent-plugin-dialog-hRZYhcLp.js} +1 -1
- package/dist/gateway/static/root/assets/{agents-CIcUUuaE.js → agents-C2DH8M4z.js} +3 -3
- package/dist/gateway/static/root/assets/{agents-admin-api-DyeFg0yq.js → agents-admin-api-_mp_Ew1u.js} +1 -1
- package/dist/gateway/static/root/assets/{api-DAWXH9Wf.js → api-D0r-2gWQ.js} +1 -1
- package/dist/gateway/static/root/assets/{api-LSz0L9gc.js → api-oA0NOKLI.js} +1 -1
- package/dist/gateway/static/root/assets/{app-management-settings-panel-CjXfqaEA.js → app-management-settings-panel-BrO0gY6b.js} +1 -1
- package/dist/gateway/static/root/assets/{appearance-settings-0Zl5M7iV.js → appearance-settings-h82Or0g-.js} +1 -1
- package/dist/gateway/static/root/assets/{apps-page-DDVJnHlm.js → apps-page-B9Ho8S53.js} +1 -1
- package/dist/gateway/static/root/assets/{archive-plugin-CMqJbzQ-.js → archive-plugin-Co_oRPj1.js} +1 -1
- package/dist/gateway/static/root/assets/{automation-api-DHGtNfOT.js → automation-api-CxLFngqe.js} +1 -1
- package/dist/gateway/static/root/assets/{automation-result-state-DUBlVnPg.js → automation-result-state-CjiuyW-C.js} +1 -1
- package/dist/gateway/static/root/assets/{automation-run-list-CuWKRWy0.js → automation-run-list-CLjSIujK.js} +1 -1
- package/dist/gateway/static/root/assets/{automation-task-card-Y4vC_7qq.js → automation-task-card-BS-RT312.js} +1 -1
- package/dist/gateway/static/root/assets/{automations-page-DBQyHgFW.js → automations-page-BL6ASYrU.js} +1 -1
- package/dist/gateway/static/root/assets/{automations-workspace-DRCt4lq0.js → automations-workspace-BFk-AF43.js} +2 -2
- package/dist/gateway/static/root/assets/{binary-plugins-CMKEp-IB.js → binary-plugins-5GVlyrXg.js} +1 -1
- package/dist/gateway/static/root/assets/{block-editor-CQwjLxA9.js → block-editor-Dtz8JtrO.js} +1 -1
- package/dist/gateway/static/root/assets/{browser-settings-page-BA0i0h3v.js → browser-settings-page-CDUHHu0n.js} +1 -1
- package/dist/gateway/static/root/assets/capabilities-Clwtvm7F.js +1 -0
- package/dist/gateway/static/root/assets/{capabilities--EoyYsa8.js → capabilities-DFRrPT_I.js} +1 -1
- package/dist/gateway/static/root/assets/{capabilities-page-B5Ja0Knr.js → capabilities-page-D9EpUcuB.js} +2 -2
- package/dist/gateway/static/root/assets/{capabilities-settings-panel-C5WmcgqD.js → capabilities-settings-panel-ComYXaP1.js} +2 -2
- package/dist/gateway/static/root/assets/{channels-BQPomrMC.js → channels-Aa2Iun4r.js} +1 -1
- package/dist/gateway/static/root/assets/{chat-agents-api-DI0TksSO.js → chat-agents-api-B-47bqbd.js} +1 -1
- package/dist/gateway/static/root/assets/{chat-chart-block-CNm3uFNf.js → chat-chart-block-DA2S21y2.js} +1 -1
- package/dist/gateway/static/root/assets/chat-page-BbahuZ59.js +72 -0
- package/dist/gateway/static/root/assets/{chat-terminal-dock-D1DkoN9Y.js → chat-terminal-dock-BALrP7_l.js} +1 -1
- package/dist/gateway/static/root/assets/{chunk-KS7C4IRE-CiwuuyV8.js → chunk-KS7C4IRE-BPb7KheU.js} +2 -2
- package/dist/gateway/static/root/assets/{command-palette-api-DZt3IZKz.js → command-palette-api-BbSsGD48.js} +1 -1
- package/dist/gateway/static/root/assets/{composer-model-config-control-_doimXGR.js → composer-model-config-control-BFC8jNyK.js} +1 -1
- package/dist/gateway/static/root/assets/{composer-notifications-BE40dFxM.js → composer-notifications-Drbl5lKS.js} +1 -1
- package/dist/gateway/static/root/assets/{composer-payload-handoff-DMWTIrnl.js → composer-payload-handoff-DKLokix8.js} +1 -1
- package/dist/gateway/static/root/assets/{computer-settings-page-DJiToD0s.js → computer-settings-page-CVWaJ3L8.js} +1 -1
- package/dist/gateway/static/root/assets/{connected-providers-grid-CYWTW8cv.js → connected-providers-grid-NZP4qb6S.js} +1 -1
- package/dist/gateway/static/root/assets/{connection-usage-guide-QgwPzjZb.js → connection-usage-guide-BNoFtMol.js} +1 -1
- package/dist/gateway/static/root/assets/{connector-service-page-DkQsU_yu.js → connector-service-page-CzrdJ4JY.js} +1 -1
- package/dist/gateway/static/root/assets/{connectors-api-Bqac6cVg.js → connectors-api-KA6rkOJX.js} +1 -1
- package/dist/gateway/static/root/assets/{connectors-page-DSCQw53B.js → connectors-page-BUqNvStL.js} +1 -1
- package/dist/gateway/static/root/assets/{date-picker-B0J_jDfr.js → date-picker-DgTDENzF.js} +1 -1
- package/dist/gateway/static/root/assets/{date-time-picker-Zr3u7nL1.js → date-time-picker-Gw4oSOk9.js} +1 -1
- package/dist/gateway/static/root/assets/{dependency-picker-CLD0xbpi.js → dependency-picker-BJDpQtKY.js} +1 -1
- package/dist/gateway/static/root/assets/{desktop-pet-CfQHdCjf.js → desktop-pet-BbIPYbvc.js} +1 -1
- package/dist/gateway/static/root/assets/{desktop-pet-settings-wlYidCpI.js → desktop-pet-settings-Cqzplufb.js} +1 -1
- package/dist/gateway/static/root/assets/{dev-view-store-DM2X7oYZ.js → dev-view-store-CXE5-Egp.js} +1 -1
- package/dist/gateway/static/root/assets/{device-pairing-wizard-DIjBN08k.js → device-pairing-wizard-DXFZiWMi.js} +1 -1
- package/dist/gateway/static/root/assets/{directory-picker-path-field-BJj6gT1z.js → directory-picker-path-field-DVFEzTAJ.js} +1 -1
- package/dist/gateway/static/root/assets/{extension-authoritative-grants-DC9q_s91.js → extension-authoritative-grants-DAfeCx4B.js} +1 -1
- package/dist/gateway/static/root/assets/{extension-debug-page-DBLJqOJ2.js → extension-debug-page-gW4GEEcj.js} +1 -1
- package/dist/gateway/static/root/assets/{extension-iframe-host-DCdjl257.js → extension-iframe-host-DOPywUKI.js} +1 -1
- package/dist/gateway/static/root/assets/{extension-marketplace-api-BEulqVpr.js → extension-marketplace-api-Bo_chffY.js} +1 -1
- package/dist/gateway/static/root/assets/{extension-message-router-DhEyQZWI.js → extension-message-router-TTAx3dPv.js} +1 -1
- package/dist/gateway/static/root/assets/{extension-page-BpY2ZrxI.js → extension-page-Iq7vFC-g.js} +1 -1
- package/dist/gateway/static/root/assets/{extension-provider-YdavG8wv.js → extension-provider-BNnLkq95.js} +1 -1
- package/dist/gateway/static/root/assets/{extension-settings-page-BKvG-hJa.js → extension-settings-page-C0oLjaz6.js} +1 -1
- package/dist/gateway/static/root/assets/{file-preview-surface-D71-xhLL.js → file-preview-surface-BSrIpn5C.js} +1 -1
- package/dist/gateway/static/root/assets/files-GdwDamkp.js +1 -0
- package/dist/gateway/static/root/assets/{gateway-config-swr-C-cx4ObA.js → gateway-config-swr-2VOPSLSq.js} +1 -1
- package/dist/gateway/static/root/assets/{gateway-realtime-Dh23j5Jx.js → gateway-realtime-CfceJ5WX.js} +1 -1
- package/dist/gateway/static/root/assets/gateway-realtime-store-Ca42Wsk6.js +1 -0
- package/dist/gateway/static/root/assets/{gateway-restart-F1q8XY7Y.js → gateway-restart-Dsg95Dwt.js} +1 -1
- package/dist/gateway/static/root/assets/{gateway-settings-WQ42gfHY.js → gateway-settings-CMgry8RK.js} +1 -1
- package/dist/gateway/static/root/assets/{gateway-startup-retry-Dx1dmgnX.js → gateway-startup-retry-D0i7dt51.js} +1 -1
- package/dist/gateway/static/root/assets/{global-defaults-api-C_Sn41rn.js → global-defaults-api-u-ado9kz.js} +1 -1
- package/dist/gateway/static/root/assets/{home-page-A3VCyEO8.js → home-page-pT-lEQsu.js} +4 -4
- package/dist/gateway/static/root/assets/{image-generation-api-CvRiMNIJ.js → image-generation-api-DDHOD0Nx.js} +1 -1
- package/dist/gateway/static/root/assets/{imports-page-DJ2wJ2QG.js → imports-page-BxRXNvQx.js} +1 -1
- package/dist/gateway/static/root/assets/index-BtHMU5k4.css +1 -0
- package/dist/gateway/static/root/assets/index-DdEh8KeB.js +11 -0
- package/dist/gateway/static/root/assets/{install-connector-dialog-CyHz1Nys.js → install-connector-dialog-Rox2_5eU.js} +1 -1
- package/dist/gateway/static/root/assets/{keyboard-shortcuts-settings-Byb_rqj4.js → keyboard-shortcuts-settings-D7xlV7xT.js} +1 -1
- package/dist/gateway/static/root/assets/{local-app-workbench-page-D58zzTUZ.js → local-app-workbench-page-ReBczGac.js} +1 -1
- package/dist/gateway/static/root/assets/{local-apps-page-L6ODN66C.js → local-apps-page-Ct07GT0V.js} +1 -1
- package/dist/gateway/static/root/assets/{local-session-drafts-UN3vioSr.js → local-session-drafts-8PozABVy.js} +1 -1
- package/dist/gateway/static/root/assets/{locale-store-CnHhWsDP.js → locale-store-B4o4aDCg.js} +1 -1
- package/dist/gateway/static/root/assets/{logs-page-2rOEUxHs.js → logs-page-CtEv5J4C.js} +1 -1
- package/dist/gateway/static/root/assets/{management-api-CSkXaCjk.js → management-api-BBLUlEXt.js} +1 -1
- package/dist/gateway/static/root/assets/{management-settings-B1Enr-fL.js → management-settings-BjvQ4WiZ.js} +1 -1
- package/dist/gateway/static/root/assets/{markdown-view-CWhAtI1O.js → markdown-view-C7kqotD-.js} +1 -1
- package/dist/gateway/static/root/assets/mcp-conversation-setup-page-DfbMmlmC.js +1 -0
- package/dist/gateway/static/root/assets/{media-plugins-DVrn3x6D.js → media-plugins-B5XMcW5S.js} +1 -1
- package/dist/gateway/static/root/assets/{messages-CZCXd6Pj.js → messages-hlOsXkQ7.js} +2 -2
- package/dist/gateway/static/root/assets/{model-selector-D-9SUwg2.js → model-selector-BP-t33vd.js} +1 -1
- package/dist/gateway/static/root/assets/{models-hub-cache-qgre89p2.js → models-hub-cache-B0z5Ptmt.js} +1 -1
- package/dist/gateway/static/root/assets/{new-chat-navigation-DXYDldT_.js → new-chat-navigation-BA1IB3hy.js} +1 -1
- package/dist/gateway/static/root/assets/{note-detail-panel-4Pd0mAhL.js → note-detail-panel-DAhIT6xP.js} +3 -3
- package/dist/gateway/static/root/assets/note-image-lightbox-DrVGs1eQ.js +1 -0
- package/dist/gateway/static/root/assets/{notes-api-_jYkMe8e.js → notes-api-B3Kc4909.js} +1 -1
- package/dist/gateway/static/root/assets/notes-page-zAJJ2OiQ.js +8 -0
- package/dist/gateway/static/root/assets/{oauth-api-CaWkle-J.js → oauth-api-CW1XhW42.js} +1 -1
- package/dist/gateway/static/root/assets/{oauth-provider-connect-DTsztbWi.js → oauth-provider-connect-3QGibJMl.js} +1 -1
- package/dist/gateway/static/root/assets/{page-context-capture-button-CYMb3IZu.js → page-context-capture-button-Bd__UBi9.js} +1 -1
- package/dist/gateway/static/root/assets/{page-context-draft-D441lgCD.js → page-context-draft-DpDsGHtl.js} +1 -1
- package/dist/gateway/static/root/assets/{page-header-store-7jhoVGK_.js → page-header-store-D_2QZ6Ps.js} +1 -1
- package/dist/gateway/static/root/assets/page-tabs-DoYMKhVO.js +1 -0
- package/dist/gateway/static/root/assets/{personal-avatar-CAATciod.js → personal-avatar-D5VUVQGE.js} +1 -1
- package/dist/gateway/static/root/assets/{personal-page-DCcipmsB.js → personal-page-DHik8uj6.js} +1 -1
- package/dist/gateway/static/root/assets/{personal-profile-settings-CZhQ4fwt.js → personal-profile-settings-Cd2xUVbw.js} +1 -1
- package/dist/gateway/static/root/assets/{personal-settings-panel-CMaFnp1G.js → personal-settings-panel-CHRra9hc.js} +1 -1
- package/dist/gateway/static/root/assets/{phone-dependencies-card-BlFgKeRz.js → phone-dependencies-card-CREmmRxI.js} +1 -1
- package/dist/gateway/static/root/assets/{phone-model-connection-DF_E69Sv.js → phone-model-connection-BDzr9jXL.js} +1 -1
- package/dist/gateway/static/root/assets/{phone-model-picker-D3O3vql4.js → phone-model-picker-DSQF-RxW.js} +1 -1
- package/dist/gateway/static/root/assets/{phone-settings-page-d2OEqR-2.js → phone-settings-page-gP5kr3VO.js} +1 -1
- package/dist/gateway/static/root/assets/{phone-workspace-store-BrXIdz55.js → phone-workspace-store-B0mF8oMk.js} +1 -1
- package/dist/gateway/static/root/assets/{plugin-details-dialog-tpugwKl1.js → plugin-details-dialog-43jCnG5n.js} +1 -1
- package/dist/gateway/static/root/assets/{preference-select-fields-DXMfKUtD.js → preference-select-fields-VqtR_pOy.js} +1 -1
- package/dist/gateway/static/root/assets/{preview-runtime-Bd9e2ent.js → preview-runtime-MJUo7XlD.js} +3 -3
- package/dist/gateway/static/root/assets/{product-automation-feedback-DmdIebRg.js → product-automation-feedback-D43XiQq6.js} +1 -1
- package/dist/gateway/static/root/assets/{product-open-page-DnPJLzt7.js → product-open-page-CQMoDCO1.js} +1 -1
- package/dist/gateway/static/root/assets/{product-preview-content-hChoKYQM.js → product-preview-content-CkQebfi-.js} +1 -1
- package/dist/gateway/static/root/assets/{product-preview-modal-CwAjfaEd.js → product-preview-modal-DToUA1EF.js} +2 -2
- package/dist/gateway/static/root/assets/{project-detail-page-BYZdStns.js → project-detail-page-BBF8eVJa.js} +2 -2
- package/dist/gateway/static/root/assets/{project-understanding-CeZ3CW6E.js → project-understanding-BScfv1pD.js} +1 -1
- package/dist/gateway/static/root/assets/{projects-page-BpARg2mt.js → projects-page-BCMWrLGf.js} +1 -1
- package/dist/gateway/static/root/assets/{providers-api-DjHMmSNk.js → providers-api-BIA2IARN.js} +1 -1
- package/dist/gateway/static/root/assets/{recording-upload-CxcMaBPr.js → recording-upload-Yy9r6kHe.js} +1 -1
- package/dist/gateway/static/root/assets/{registry-api-x3kjVVzC.js → registry-api-CmLu4MA9.js} +1 -1
- package/dist/gateway/static/root/assets/{remote-access-hub-Cuyfg5gz.js → remote-access-hub-BeG8Bgy0.js} +1 -1
- package/dist/gateway/static/root/assets/{resource-unavailable-ClTyW1KO.js → resource-unavailable-Dccp_uis.js} +1 -1
- package/dist/gateway/static/root/assets/{right-workspace-store-BgVMF75g.js → right-workspace-store-CFf15f36.js} +1 -1
- package/dist/gateway/static/root/assets/{route-preload-BPMOD0qt.js → route-preload-Bl10PwKS.js} +2 -2
- package/dist/gateway/static/root/assets/{routine-panel-DqCzH4o9.js → routine-panel-BjqenuXU.js} +2 -2
- package/dist/gateway/static/root/assets/{runtime-tools-api-ZKJq8Y1c.js → runtime-tools-api-CFvov9Uy.js} +1 -1
- package/dist/gateway/static/root/assets/{runtime-tools-settings-panel-CSVS-0w1.js → runtime-tools-settings-panel-C7sHr-Lm.js} +1 -1
- package/dist/gateway/static/root/assets/{service-recommendation-list-Jbg55MsH.js → service-recommendation-list-Bz9QWUZc.js} +1 -1
- package/dist/gateway/static/root/assets/{session-api-JAcSuzXh.js → session-api-7-TPnKv0.js} +1 -1
- package/dist/gateway/static/root/assets/{session-manager-CvC5uo-A.js → session-manager-fvJusKsK.js} +2 -2
- package/dist/gateway/static/root/assets/{sessions-page-itpuSflW.js → sessions-page-DS-OExY1.js} +1 -1
- package/dist/gateway/static/root/assets/settings-advanced-gate-DHfrm0Zj.js +1 -0
- package/dist/gateway/static/root/assets/{settings-advanced-section-C-Rq-g2w.js → settings-advanced-section-BsqgVQL3.js} +1 -1
- package/dist/gateway/static/root/assets/{settings-mode-store-DWWvnHvd.js → settings-mode-store-BtwrUOdQ.js} +1 -1
- package/dist/gateway/static/root/assets/{settings-page-DppkfISC.js → settings-page-B_8kxJQW.js} +1 -1
- package/dist/gateway/static/root/assets/{settings-page-header-BnBbewrE.js → settings-page-header-DKgbD0Bc.js} +1 -1
- package/dist/gateway/static/root/assets/{settings-page-layout-DgRq0a-W.js → settings-page-layout-BE3vLWp_.js} +1 -1
- package/dist/gateway/static/root/assets/{setup-interaction-page-_UOcgWMs.js → setup-interaction-page-DLpGv0yp.js} +1 -1
- package/dist/gateway/static/root/assets/{setup-status-panel-fXdj1EOR.js → setup-status-panel-BMaFUPnt.js} +1 -1
- package/dist/gateway/static/root/assets/{share-link-dialog-BUzVn5kX.js → share-link-dialog-3RNzFIH3.js} +1 -1
- package/dist/gateway/static/root/assets/{share-preview-page-CIdxsC9i.js → share-preview-page-C49EIXte.js} +1 -1
- package/dist/gateway/static/root/assets/{shares-api-DNlL_AwP.js → shares-api-B532SLIU.js} +1 -1
- package/dist/gateway/static/root/assets/{shares-settings-R2H0pdNK.js → shares-settings-C_ITdQqP.js} +1 -1
- package/dist/gateway/static/root/assets/{skill-api-D3iuvyp7.js → skill-api-x-ENFv-9.js} +1 -1
- package/dist/gateway/static/root/assets/{skill-list-api-K8n_AYMV.js → skill-list-api-CqmglPCz.js} +1 -1
- package/dist/gateway/static/root/assets/{skill-reload-api-BqxHK3K0.js → skill-reload-api-YeoxO91w.js} +1 -1
- package/dist/gateway/static/root/assets/{skills-page-BHciTWaw.js → skills-page-B30SsJL6.js} +1 -1
- package/dist/gateway/static/root/assets/space-page-DmvjU1jc.js +2 -0
- package/dist/gateway/static/root/assets/{system-settings-panel-BPyQzKf8.js → system-settings-panel-KXLPpyOW.js} +1 -1
- package/dist/gateway/static/root/assets/{task-detail-page-By5vozgo.js → task-detail-page-DHYm_bsg.js} +3 -3
- package/dist/gateway/static/root/assets/{task-header-title-lUJ0ls3u.js → task-header-title-Buwr7WTV.js} +1 -1
- package/dist/gateway/static/root/assets/{task-result-evidence-CWpAUoNq.js → task-result-evidence-DpV1mZJA.js} +1 -1
- package/dist/gateway/static/root/assets/{terminal-panel-store-D24y7GIK.js → terminal-panel-store-Ch8lOYIq.js} +1 -1
- package/dist/gateway/static/root/assets/{theme-store-VVHRSdNZ.js → theme-store-C7t81hG7.js} +1 -1
- package/dist/gateway/static/root/assets/{tracing-settings-page-D3tu_G8X.js → tracing-settings-page-CcyPoojp.js} +1 -1
- package/dist/gateway/static/root/assets/{tunnel-api-DwTTVUxp.js → tunnel-api-D713CJ9R.js} +1 -1
- package/dist/gateway/static/root/assets/{understanding-activity-store-BOIGCSnz.js → understanding-activity-store-mSawFpIz.js} +1 -1
- package/dist/gateway/static/root/assets/{understanding-refresh-store-mKqdZVjW.js → understanding-refresh-store-4M0xrc88.js} +1 -1
- package/dist/gateway/static/root/assets/{usage-page-B4MqbLKR.js → usage-page-DN1TcxWS.js} +1 -1
- package/dist/gateway/static/root/assets/{use-autosave-BcgfZd3f.js → use-autosave-BkVX6SyB.js} +1 -1
- package/dist/gateway/static/root/assets/{use-composer-attachments-Ca1eE6iV.js → use-composer-attachments-4FKbf6PB.js} +1 -1
- package/dist/gateway/static/root/assets/{use-file-preview-expanded-BwB7VH_A.js → use-file-preview-expanded-CRBn6UTd.js} +1 -1
- package/dist/gateway/static/root/assets/use-generated-media-CEJ5BBxX.js +1 -0
- package/dist/gateway/static/root/assets/{use-personal-profile-BDLuMaWC.js → use-personal-profile-DdjQjf9I.js} +1 -1
- package/dist/gateway/static/root/assets/{use-personal-work-Dfbs6S75.js → use-personal-work-srLCZOam.js} +1 -1
- package/dist/gateway/static/root/assets/{use-realtime-voice-BrM12ktL.js → use-realtime-voice-tyo85cre.js} +1 -1
- package/dist/gateway/static/root/assets/{use-workspace-tree-AL4BVZhS.js → use-workspace-tree-VwHdfiR8.js} +1 -1
- package/dist/gateway/static/root/assets/{user-model-page-CqTB0BIf.js → user-model-page-D-F5GO3T.js} +2 -2
- package/dist/gateway/static/root/assets/{voice-api-key-field-BbVCvQrE.js → voice-api-key-field-gWJ6bx-H.js} +1 -1
- package/dist/gateway/static/root/assets/{voice-config-api-vtmTs-mq.js → voice-config-api-B1RtxiRq.js} +1 -1
- package/dist/gateway/static/root/assets/{voice-input-shortcut-events-BhmaEWvI.js → voice-input-shortcut-events-C-8Ts1gq.js} +1 -1
- package/dist/gateway/static/root/assets/{voice-player-store-IVeW1g9y.js → voice-player-store-DyuAAbk0.js} +1 -1
- package/dist/gateway/static/root/assets/{voice-settings-JJfxv-lj.js → voice-settings-DOajN2ay.js} +1 -1
- package/dist/gateway/static/root/assets/{work-discovery-overlay-Bl2qHC88.js → work-discovery-overlay-CTLp1-tu.js} +1 -1
- package/dist/gateway/static/root/assets/{work-discovery-page-ChvUHm0f.js → work-discovery-page-B-UzFKIr.js} +1 -1
- package/dist/gateway/static/root/assets/{working-directory-picker-modal-BxeoaS6d.js → working-directory-picker-modal-DvVtUxHW.js} +1 -1
- package/dist/gateway/static/root/assets/{workspace-api-D_dxOn8W.js → workspace-api-CIfedJeG.js} +2 -2
- package/dist/gateway/static/root/assets/workspace-editor-agent-store-Bh4FYwVq.js +1 -0
- package/dist/gateway/static/root/assets/{workspace-file-preview-dialog-D0GxWvAv.js → workspace-file-preview-dialog-Xi5feqPq.js} +1 -1
- package/dist/gateway/static/root/assets/{workspace-open-location-menu-CCJISdeq.js → workspace-open-location-menu-sbOva_RI.js} +1 -1
- package/dist/gateway/static/root/assets/{workspace-preview-store-DKZ6gVL4.js → workspace-preview-store-DYd8E5bV.js} +1 -1
- package/dist/gateway/static/root/assets/{xopc-cloud-account-card-Cxt6wEom.js → xopc-cloud-account-card-BYuMOGaK.js} +1 -1
- package/dist/gateway/static/root/index.html +96 -96
- package/dist/package.js +1 -1
- package/dist/packages/gateway-contract/src/files.js +17 -3
- package/dist/packages/gateway-contract/src/home.js +1 -0
- package/dist/src/agent/agent-manager.d.ts +1 -0
- package/dist/src/agent/agent-manager.js +2 -1
- package/dist/src/agent/commands/command-registry.d.ts +1 -1
- package/dist/src/agent/commands/command-registry.js +10 -1
- package/dist/src/agent/embedded/index.js +1 -1
- package/dist/src/agent/embedded/run-for-session.js +1 -1
- package/dist/src/agent/embedded/run-turn.js +3 -2
- package/dist/src/agent/embedded/runs.d.ts +3 -0
- package/dist/src/agent/embedded/runs.js +20 -2
- package/dist/src/agent/embedded/tool-search-extension.js +2 -0
- package/dist/src/agent/embedded/xopc-tools-bridge.js +1 -1
- package/dist/src/agent/external-tools/discovery.js +1 -1
- package/dist/src/agent/external-tools/endpoint-provider.js +1 -1
- package/dist/src/agent/mcp/continuation-guard.js +1 -1
- package/dist/src/agent/mcp/conversation-setup.d.ts +221 -4
- package/dist/src/agent/mcp/conversation-setup.js +66 -27
- package/dist/src/agent/mcp/discovery.d.ts +5 -0
- package/dist/src/agent/mcp/discovery.js +47 -6
- package/dist/src/agent/prompt/conversational-configuration-guide.js +3 -2
- package/dist/src/agent/prompt/sections/tooling.js +1 -1
- package/dist/src/agent/service.js +1 -0
- package/dist/src/agent/service.types.d.ts +1 -0
- package/dist/src/agent/tool-manuals/browser.d.ts +1 -1
- package/dist/src/agent/tool-manuals/browser.js +3 -1
- package/dist/src/agent/tool-manuals/xopc-configuration.d.ts +2 -2
- package/dist/src/agent/tool-manuals/xopc-configuration.js +10 -9
- package/dist/src/agent/tools/browser/tool/browser-use-tool.js +1 -1
- package/dist/src/agent/tools/capability-catalog-tool.d.ts +10 -0
- package/dist/src/agent/tools/capability-catalog-tool.js +63 -0
- package/dist/src/agent/tools/exec-command.d.ts +1 -0
- package/dist/src/agent/tools/exec-command.js +11 -5
- package/dist/src/agent/tools/factory.d.ts +1 -0
- package/dist/src/agent/tools/factory.js +32 -1
- package/dist/src/agent/tools/language-diagnostics.js +4 -1
- package/dist/src/agent/tools/managed-job-tool.js +3 -2
- package/dist/src/agent/tools/mcp-setup-tool.js +2 -2
- package/dist/src/agent/tools/phone-use-tool.js +1 -1
- package/dist/src/agent/tools/xopc-use-tool.d.ts +2 -0
- package/dist/src/agent/tools/xopc-use-tool.js +5 -3
- package/dist/src/agent-config/schema.d.ts +3 -0
- package/dist/src/agent-config/schema.js +1 -0
- package/dist/src/automations/api/routes.js +17 -5
- package/dist/src/automations/capabilities/write.js +32 -4
- package/dist/src/automations/configuration-conversation.d.ts +7 -0
- package/dist/src/automations/configuration-conversation.js +13 -5
- package/dist/src/capabilities/capability-catalog.d.ts +47 -0
- package/dist/src/capabilities/capability-catalog.js +162 -0
- package/dist/src/capabilities/runtime/product.js +1 -1
- package/dist/src/capabilities/store-connector.d.ts +1 -0
- package/dist/src/capabilities/store-connector.js +6 -3
- package/dist/src/chat-commands/builtins/config.js +1 -1
- package/dist/src/chat-commands/context.js +1 -1
- package/dist/src/cli/commands/agent.js +1 -1
- package/dist/src/cli/commands/doctor/checks/channel-plugins.js +1 -1
- package/dist/src/cli/commands/doctor/checks/database-schema.js +5 -5
- package/dist/src/cli/commands/extension-dev.js +1 -1
- package/dist/src/cli/commands/extension-marketplace.js +1 -1
- package/dist/src/cli/commands/extension.js +1 -1
- package/dist/src/cli/commands/onboard/channels/registry.js +1 -1
- package/dist/src/cli/commands/platform.js +2 -2
- package/dist/src/cli/commands/skills.js +1 -1
- package/dist/src/cli/extension-cli-register.js +1 -1
- package/dist/src/cli/utils/session.js +1 -1
- package/dist/src/config/index.js +1 -1
- package/dist/src/config/schema.d.ts +2 -0
- package/dist/src/config/schema.js +6 -3
- package/dist/src/extensions/index.js +2 -2
- package/dist/src/extensions/loader.js +1 -1
- package/dist/src/extensions/update.js +1 -1
- package/dist/src/files/file-service.js +1 -0
- package/dist/src/files/file-versions.d.ts +15 -0
- package/dist/src/files/file-versions.js +87 -0
- package/dist/src/gateway/agent-reactions/reaction.d.ts +27 -0
- package/dist/src/gateway/agent-reactions/reaction.js +186 -0
- package/dist/src/gateway/hono/routes/auth-registry-extensions.js +1 -1
- package/dist/src/gateway/hono/routes/capabilities.js +27 -0
- package/dist/src/gateway/hono/routes/connectors.js +1 -1
- package/dist/src/gateway/hono/routes/files.js +39 -0
- package/dist/src/gateway/hono/routes/home.js +1 -1
- package/dist/src/gateway/hono/routes/mobile-capability-actions.d.ts +4 -0
- package/dist/src/gateway/hono/routes/mobile-capability-actions.js +290 -0
- package/dist/src/gateway/hono/routes/music-generation.js +1 -0
- package/dist/src/gateway/hono/routes/personal-agent.js +23 -43
- package/dist/src/gateway/hono/routes/sessions.js +41 -2
- package/dist/src/gateway/security/gateway-principal.d.ts +1 -0
- package/dist/src/gateway/security/gateway-principal.js +9 -1
- package/dist/src/gateway/security/gateway-scopes.js +3 -0
- package/dist/src/gateway/service/agent-runner.d.ts +2 -0
- package/dist/src/gateway/service/agent-runner.js +5 -1
- package/dist/src/gateway/service/config-coordinator.d.ts +1 -0
- package/dist/src/gateway/service/config-coordinator.js +1 -1
- package/dist/src/gateway/service/run-gateway-agent.d.ts +3 -0
- package/dist/src/gateway/service/run-gateway-agent.js +43 -1
- package/dist/src/gateway/service/task-conversation-query-service.d.ts +4 -0
- package/dist/src/gateway/service.js +20 -11
- package/dist/src/home-intelligence/host.js +5 -5
- package/dist/src/personal-agent/repository.d.ts +1 -0
- package/dist/src/personal-agent/repository.js +1 -0
- package/dist/src/personal-agent/schedules.d.ts +9 -1
- package/dist/src/personal-agent/schedules.js +32 -1
- package/dist/src/personal-agent/service.d.ts +2 -2
- package/dist/src/personal-agent/service.js +6 -3
- package/dist/src/projects/index.js +1 -1
- package/dist/src/providers/model-call.js +1 -0
- package/dist/src/realtime/runtime.js +1 -0
- package/dist/src/session/client-history.d.ts +1 -0
- package/dist/src/session/client-history.js +2 -0
- package/dist/src/session/types.d.ts +4 -0
- package/dist/src/storage/sqlite/agent-reaction-repository.d.ts +15 -0
- package/dist/src/storage/sqlite/agent-reaction-repository.js +73 -0
- package/dist/src/storage/sqlite/row-mappers.js +1 -1
- package/dist/src/storage/sqlite/schema.d.ts +2 -2
- package/dist/src/storage/sqlite/schema.js +7 -7
- package/dist/src/storage/sqlite/schema.sql +13 -0
- package/dist/src/storage/sqlite/upgrades/281_session_agent_reactions.sql +13 -0
- package/dist/src/tasks/home-query-service.js +1 -0
- package/dist/src/tui/backends/embedded-backend.js +5 -4
- package/dist/src/tui/extension-host/load-extensions.js +1 -1
- package/dist/src/tui/tui-commands.js +1 -1
- package/dist/src/tui/tui-management.js +1 -1
- package/dist/src/tui/tui.js +1 -1
- package/dist/src/usage/recorder.js +6 -2
- package/dist/src/usage/types.d.ts +1 -0
- package/package.json +1 -1
- package/dist/gateway/static/root/assets/capabilities-DG-WesBp.js +0 -1
- package/dist/gateway/static/root/assets/chat-page-DO060oe9.js +0 -72
- package/dist/gateway/static/root/assets/files-BNL4kkSB.js +0 -1
- package/dist/gateway/static/root/assets/gateway-realtime-store-D_ZITqDi.js +0 -1
- package/dist/gateway/static/root/assets/index-Ca939klV.js +0 -11
- package/dist/gateway/static/root/assets/index-DrWdNdP4.css +0 -1
- package/dist/gateway/static/root/assets/mcp-conversation-setup-page-lOOFtIXe.js +0 -1
- package/dist/gateway/static/root/assets/note-image-lightbox-C1w4X0T6.js +0 -1
- package/dist/gateway/static/root/assets/notes-page-strWZLkP.js +0 -8
- package/dist/gateway/static/root/assets/page-tabs-oeTY7z3_.js +0 -1
- package/dist/gateway/static/root/assets/settings-advanced-gate-BEDT8_0u.js +0 -1
- package/dist/gateway/static/root/assets/space-api-C302hvkG.js +0 -1
- package/dist/gateway/static/root/assets/space-page-sfc82o9O.js +0 -2
- package/dist/gateway/static/root/assets/workspace-editor-agent-store-D5wq8Kme.js +0 -1
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { init_transaction, runSqliteWriteTransaction } from "../../../storage/sqlite/transaction.js";
|
|
2
|
-
import { getDevice } from "../../../storage/sqlite/device-access-repository.js";
|
|
3
2
|
import { init_voice, voiceCallPreferencesPatchSchema } from "../../../../packages/realtime-protocol/src/voice.js";
|
|
4
3
|
import { getPersonalRequest, init_request_repository, listPersonalRequests } from "../../../personal-agent/request-repository.js";
|
|
5
4
|
import { getPersonalAgent } from "../../../personal-agent/repository.js";
|
|
@@ -8,12 +7,12 @@ import { AutomationScheduleSchema } from "../../../automations/domain/validation
|
|
|
8
7
|
import { getAutomation } from "../../../automations/storage/automation-repository.js";
|
|
9
8
|
import "../../../automations/storage/index.js";
|
|
10
9
|
import { listDeliverables } from "../../../tasks/task-deliverables.js";
|
|
10
|
+
import { isPersonalSchedule, personalScheduleInput } from "../../../personal-agent/schedules.js";
|
|
11
11
|
import { cancelPersonalRequest, personalRequestSnapshot, publishPersonalRequest } from "../../../personal-agent/request-service.js";
|
|
12
12
|
import { writeAgentAvatarFromBase64 } from "../../agents-admin.js";
|
|
13
13
|
import { legacyNaturalModel } from "../../../voice/realtime/omniRoute.js";
|
|
14
|
-
import {
|
|
14
|
+
import { getPersonalOwnerId } from "../../security/gateway-principal.js";
|
|
15
15
|
import { PersonalOnboardingDraftSchema, PersonalOnboardingStepSchema, finishPersonalWelcome, getPersonalOnboarding, savePersonalOnboarding } from "../../../personal-agent/onboarding.js";
|
|
16
|
-
import { isPersonalSchedule } from "../../../personal-agent/schedules.js";
|
|
17
16
|
import { PersonalAppearanceSchema, createOrResumePersonalAgent, ensurePersonalConversationVisibility, listPersonalModels, patchPersonalProfile, refreshPersonalDelegationGuidance } from "../../../personal-agent/service.js";
|
|
18
17
|
import { markPersonalRead, personalUnreadSnapshot } from "../../../personal-agent/unread.js";
|
|
19
18
|
import { registerProactivityRoutes } from "../../../personal-agent/proactivity/routes.js";
|
|
@@ -50,6 +49,7 @@ const OnboardingSchema = z.object({
|
|
|
50
49
|
}).strict();
|
|
51
50
|
const ProfileSchema = z.object({
|
|
52
51
|
voiceCallPreferences: voiceCallPreferencesPatchSchema.optional(),
|
|
52
|
+
messageReactionsEnabled: z.boolean().optional(),
|
|
53
53
|
revision: z.number().int().positive(),
|
|
54
54
|
displayName: z.string().trim().min(1).max(60),
|
|
55
55
|
appearance: PersonalAppearanceSchema,
|
|
@@ -75,13 +75,11 @@ const PersonalSchedulePatchSchema = PersonalScheduleSchema.partial().extend({
|
|
|
75
75
|
expectedRevision: z.number().int().nonnegative()
|
|
76
76
|
}).refine((value) => Object.keys(value).length > 1);
|
|
77
77
|
function registerPersonalAgentRoutes(authenticated, deps) {
|
|
78
|
-
const
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
if (principal.kind !== "device" || !principal.deviceId) return null;
|
|
82
|
-
const platform = getDevice(principal.deviceId)?.platform;
|
|
83
|
-
return platform === "harmonyos" || platform === "ios" || platform === "android" ? "local-owner" : null;
|
|
78
|
+
const profilePayload = (record) => record && {
|
|
79
|
+
...record,
|
|
80
|
+
messageReactionsAvailable: deps.service.currentConfig?.experimental?.personalAgentMessageReactions === true
|
|
84
81
|
};
|
|
82
|
+
const owner = getPersonalOwnerId;
|
|
85
83
|
registerProactivityRoutes(authenticated, deps, owner);
|
|
86
84
|
authenticated.get("/api/personal-agent/schedules", async (c) => {
|
|
87
85
|
const ownerId = owner(c);
|
|
@@ -112,40 +110,18 @@ function registerPersonalAgentRoutes(authenticated, deps) {
|
|
|
112
110
|
error: "Personal Agent is unavailable"
|
|
113
111
|
}, 409);
|
|
114
112
|
const parsed = PersonalScheduleSchema.safeParse(await c.req.json().catch(() => null));
|
|
115
|
-
if (!parsed.success) return c.json({
|
|
113
|
+
if (!parsed.success || !parsed.data.schedule) return c.json({
|
|
116
114
|
ok: false,
|
|
117
115
|
error: "Invalid Personal schedule"
|
|
118
116
|
}, 400);
|
|
119
117
|
const { name, instruction, locale, schedule } = parsed.data;
|
|
120
118
|
try {
|
|
121
|
-
const automation = await deps.service.automationServiceInstance.create({
|
|
119
|
+
const automation = await deps.service.automationServiceInstance.create(personalScheduleInput(profile, {
|
|
122
120
|
name,
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
action: {
|
|
128
|
-
kind: "personal_task",
|
|
129
|
-
agentId: profile.agentId,
|
|
130
|
-
conversationId: profile.conversationId,
|
|
131
|
-
instruction,
|
|
132
|
-
locale
|
|
133
|
-
},
|
|
134
|
-
management: {
|
|
135
|
-
owner: "personal-agent",
|
|
136
|
-
editable: ["enabled", "trigger"],
|
|
137
|
-
runnable: true,
|
|
138
|
-
deletable: true
|
|
139
|
-
},
|
|
140
|
-
conversationMode: "new_session",
|
|
141
|
-
delivery: {
|
|
142
|
-
notificationPolicy: "attention",
|
|
143
|
-
destinations: [{
|
|
144
|
-
key: "gateway_event",
|
|
145
|
-
kind: "gateway_event"
|
|
146
|
-
}]
|
|
147
|
-
}
|
|
148
|
-
});
|
|
121
|
+
instruction,
|
|
122
|
+
locale,
|
|
123
|
+
schedule
|
|
124
|
+
}));
|
|
149
125
|
return c.json({
|
|
150
126
|
ok: true,
|
|
151
127
|
payload: automation
|
|
@@ -283,7 +259,7 @@ function registerPersonalAgentRoutes(authenticated, deps) {
|
|
|
283
259
|
ensurePersonalConversationVisibility(ownerId);
|
|
284
260
|
return c.json({
|
|
285
261
|
ok: true,
|
|
286
|
-
payload: getPersonalAgent(ownerId)
|
|
262
|
+
payload: profilePayload(getPersonalAgent(ownerId))
|
|
287
263
|
});
|
|
288
264
|
});
|
|
289
265
|
authenticated.get("/api/personal-agent/unread", (c) => {
|
|
@@ -540,7 +516,7 @@ function registerPersonalAgentRoutes(authenticated, deps) {
|
|
|
540
516
|
} : void 0);
|
|
541
517
|
return c.json({
|
|
542
518
|
ok: true,
|
|
543
|
-
payload: record
|
|
519
|
+
payload: profilePayload(record)
|
|
544
520
|
});
|
|
545
521
|
} catch (error) {
|
|
546
522
|
return c.json({
|
|
@@ -560,13 +536,13 @@ function registerPersonalAgentRoutes(authenticated, deps) {
|
|
|
560
536
|
ok: false,
|
|
561
537
|
error: "Invalid profile"
|
|
562
538
|
}, 400);
|
|
563
|
-
const { revision, displayName, appearance, voicePreference, voiceCallPreferences } = parsed.data;
|
|
539
|
+
const { revision, displayName, appearance, voicePreference, voiceCallPreferences, messageReactionsEnabled } = parsed.data;
|
|
564
540
|
const naturalModel = voiceCallPreferences?.naturalModel;
|
|
565
541
|
if (naturalModel && naturalModel !== "boson/higgs-realtime" && naturalModel !== legacyNaturalModel(deps.service.currentConfig) && naturalModel !== getPersonalAgent(ownerId)?.voiceCallPreferences.naturalModel) return c.json({
|
|
566
542
|
ok: false,
|
|
567
543
|
error: "Selected natural voice model is unavailable"
|
|
568
544
|
}, 400);
|
|
569
|
-
if (voicePreference) {
|
|
545
|
+
if (voicePreference && JSON.stringify(voicePreference) !== JSON.stringify(getPersonalAgent(ownerId)?.voicePreference)) {
|
|
570
546
|
const { resolveStreamingTts } = await import("../../../voice/realtime/runtime.js");
|
|
571
547
|
const route = resolveStreamingTts(deps.service.currentConfig);
|
|
572
548
|
if (!route?.provider.plugin.listVoices || route.route.provider !== voicePreference.provider || route.route.model !== voicePreference.model) return c.json({
|
|
@@ -582,10 +558,14 @@ function registerPersonalAgentRoutes(authenticated, deps) {
|
|
|
582
558
|
error: "Selected voice is unavailable"
|
|
583
559
|
}, 400);
|
|
584
560
|
}
|
|
585
|
-
const updated = await patchPersonalProfile(deps.service, ownerId, revision, displayName, appearance, voicePreference, voiceCallPreferences);
|
|
561
|
+
const updated = await patchPersonalProfile(deps.service, ownerId, revision, displayName, appearance, voicePreference, voiceCallPreferences, messageReactionsEnabled);
|
|
562
|
+
if (updated && messageReactionsEnabled !== void 0) deps.service.realtime.broker.publish("sessions", "session.agent-reaction.preference", {
|
|
563
|
+
conversationId: updated.conversationId,
|
|
564
|
+
enabled: messageReactionsEnabled
|
|
565
|
+
});
|
|
586
566
|
return updated ? c.json({
|
|
587
567
|
ok: true,
|
|
588
|
-
payload: updated
|
|
568
|
+
payload: profilePayload(updated)
|
|
589
569
|
}) : c.json({
|
|
590
570
|
ok: false,
|
|
591
571
|
error: "Profile changed or personal Agent is unavailable"
|
|
@@ -4,11 +4,12 @@ import { init_src } from "../../../../packages/gateway-contract/src/index.js";
|
|
|
4
4
|
import "../../../session/types.js";
|
|
5
5
|
import { SidebarLayoutConflictError, getSidebarLayout, replaceSidebarLayout, sortBySidebarLayout } from "../../../storage/sqlite/sidebar-layout-repository.js";
|
|
6
6
|
import { summarizeAiUsageByConversations } from "../../../storage/sqlite/ai-usage-repository.js";
|
|
7
|
-
import { isPersonalConversation } from "../../../personal-agent/repository.js";
|
|
7
|
+
import { getPersonalAgentByConversation, isPersonalConversation } from "../../../personal-agent/repository.js";
|
|
8
8
|
import { messagesToClientHistory } from "../../../session/client-history.js";
|
|
9
9
|
import { SessionEnvironmentService } from "../../../execution-environments/session-environment-service.js";
|
|
10
10
|
import { evictEmbeddedSessionRunner } from "../../../agent/embedded/session-runner.js";
|
|
11
11
|
import { deleteMediaUrisNoLongerReferenced } from "../../../media/session-references.js";
|
|
12
|
+
import { DEFAULT_AGENT_REACTION, readAgentReactions } from "../../../storage/sqlite/agent-reaction-repository.js";
|
|
12
13
|
import { getGatewayPrincipal } from "../../security/gateway-principal.js";
|
|
13
14
|
import { createGatewayRouteLogger, logRouteError } from "../lib/route-logger.js";
|
|
14
15
|
import { patchChatModelConfig } from "./chat-model-config.js";
|
|
@@ -454,6 +455,38 @@ function registerSessionsRoutes(authenticated, deps) {
|
|
|
454
455
|
compact
|
|
455
456
|
});
|
|
456
457
|
if (!result) return c.json({ error: "Session not found" }, 404);
|
|
458
|
+
const actor = getPersonalAgentByConversation(key);
|
|
459
|
+
const transcriptId = result.session.transcriptId;
|
|
460
|
+
if (actor && transcriptId) {
|
|
461
|
+
const available = service.currentConfig?.experimental?.personalAgentMessageReactions === true;
|
|
462
|
+
result.session.agentReactions = {
|
|
463
|
+
available,
|
|
464
|
+
enabled: available && actor.messageReactionsEnabled
|
|
465
|
+
};
|
|
466
|
+
if (result.session.agentReactions.enabled) {
|
|
467
|
+
const messages = result.session.messages;
|
|
468
|
+
const entries = messages.flatMap((row) => row.role === "user" && row.transcriptEntryId ? [row.transcriptEntryId] : []);
|
|
469
|
+
const reactions = new Map(readAgentReactions(key, transcriptId, entries, actor.displayName).map((reaction) => [reaction.entryId, reaction]));
|
|
470
|
+
const activeRunId = service.getActiveWebchatRunId(key);
|
|
471
|
+
for (const row of messages) {
|
|
472
|
+
const entryId = row.transcriptEntryId;
|
|
473
|
+
if (row.role !== "user" || !entryId) continue;
|
|
474
|
+
const saved = reactions.get(entryId);
|
|
475
|
+
if (saved) row.agentReaction = saved;
|
|
476
|
+
else if (!activeRunId || row.turnId !== activeRunId || row.metadata?.steered) row.agentReaction = {
|
|
477
|
+
conversationId: key,
|
|
478
|
+
transcriptId,
|
|
479
|
+
clientMessageId: row.metadata?.clientMessageId ?? entryId,
|
|
480
|
+
entryId,
|
|
481
|
+
actorAgentId: actor.agentId,
|
|
482
|
+
actorName: actor.displayName,
|
|
483
|
+
runId: row.turnId ?? entryId,
|
|
484
|
+
emoji: DEFAULT_AGENT_REACTION,
|
|
485
|
+
createdAtMs: row.timestamp ?? 0
|
|
486
|
+
};
|
|
487
|
+
}
|
|
488
|
+
}
|
|
489
|
+
}
|
|
457
490
|
const revision = result.pagination.revision;
|
|
458
491
|
if (typeof revision === "number") {
|
|
459
492
|
const contentHash = createHash("sha256").update(JSON.stringify(result)).digest("base64url");
|
|
@@ -723,7 +756,13 @@ function registerSessionsRoutes(authenticated, deps) {
|
|
|
723
756
|
if (typeof body.name === "string") patch.name = body.name;
|
|
724
757
|
if (Array.isArray(body.tags)) patch.tags = body.tags;
|
|
725
758
|
if (typeof body.replaceTags === "boolean") patch.replaceTags = body.replaceTags;
|
|
726
|
-
if (body.customData !== void 0 && typeof body.customData === "object" && body.customData !== null)
|
|
759
|
+
if (body.customData !== void 0 && typeof body.customData === "object" && body.customData !== null) {
|
|
760
|
+
if (Object.hasOwn(body.customData, "automationSetup")) return c.json({
|
|
761
|
+
ok: false,
|
|
762
|
+
error: "Automation configuration metadata is managed by the gateway"
|
|
763
|
+
}, 400);
|
|
764
|
+
patch.customData = body.customData;
|
|
765
|
+
}
|
|
727
766
|
let requestedProjectId;
|
|
728
767
|
if ("projectId" in body) {
|
|
729
768
|
requestedProjectId = typeof body.projectId === "string" && body.projectId.trim() ? body.projectId.trim() : null;
|
|
@@ -10,3 +10,4 @@ export type GatewayPrincipal = {
|
|
|
10
10
|
};
|
|
11
11
|
export declare function setGatewayPrincipal(c: Context, principal: GatewayPrincipal): void;
|
|
12
12
|
export declare function getGatewayPrincipal(c: Context): GatewayPrincipal;
|
|
13
|
+
export declare function getPersonalOwnerId(c: Context): string | null;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { getDevice } from "../../storage/sqlite/device-access-repository.js";
|
|
1
2
|
//#region src/gateway/security/gateway-principal.ts
|
|
2
3
|
const PRINCIPAL_CONTEXT_KEY = "gatewayPrincipal";
|
|
3
4
|
function setGatewayPrincipal(c, principal) {
|
|
@@ -8,5 +9,12 @@ function getGatewayPrincipal(c) {
|
|
|
8
9
|
if (!principal) throw new Error("Gateway principal is unavailable");
|
|
9
10
|
return principal;
|
|
10
11
|
}
|
|
12
|
+
function getPersonalOwnerId(c) {
|
|
13
|
+
const principal = getGatewayPrincipal(c);
|
|
14
|
+
if (principal.kind === "owner") return "local-owner";
|
|
15
|
+
if (principal.kind !== "device" || !principal.deviceId) return null;
|
|
16
|
+
const platform = getDevice(principal.deviceId)?.platform;
|
|
17
|
+
return platform === "harmonyos" || platform === "ios" || platform === "android" ? "local-owner" : null;
|
|
18
|
+
}
|
|
11
19
|
//#endregion
|
|
12
|
-
export { getGatewayPrincipal, setGatewayPrincipal };
|
|
20
|
+
export { getGatewayPrincipal, getPersonalOwnerId, setGatewayPrincipal };
|
|
@@ -58,6 +58,9 @@ function requiredGatewayScope(method, path) {
|
|
|
58
58
|
if (path.startsWith("/api/automations") || path.startsWith("/api/automation-runs")) return methodScope(method, "automations.read", "automations.write");
|
|
59
59
|
if (path === "/api/voice/selection" || path === "/api/voice/catalog/refresh" || path === "/api/voice/boson" || path === "/api/voice/boson/reveal-api-key") return "voice.configure";
|
|
60
60
|
if (path.startsWith("/api/voice") || path.startsWith("/api/media") || path.startsWith("/api/clarifications")) return "sessions.write";
|
|
61
|
+
if (method === "GET" && path === "/api/capabilities/mobile-catalog") return "agents.read";
|
|
62
|
+
if (method === "GET" && /^\/api\/capabilities\/mobile-actions\/(?:skills|(?:agent|plugin)\/[^/]+)$/.test(path)) return "agents.read";
|
|
63
|
+
if (method === "POST" && /^\/api\/capabilities\/mobile-actions\/(?:skills|mcp(?:\/[^/]+)?|(?:agent|plugin)\/[^/]+)$/.test(path)) return "sessions.write";
|
|
61
64
|
if (method === "GET" && path === "/api/chat/skills") return "agents.read";
|
|
62
65
|
if (path.startsWith("/api/commands") || path.startsWith("/api/skills")) return methodScope(method, "agents.read", "gateway.admin");
|
|
63
66
|
if (path === "/api/user-model/refresh" || path.startsWith("/api/user-model/refresh/")) return "gateway.admin";
|
|
@@ -16,6 +16,7 @@ import type { UserTurnAttachment, UserTurnInput } from '../user-turn-input.js';
|
|
|
16
16
|
import type { AgentSourceContext, TurnContextRef } from '../../agent/source-context/types.js';
|
|
17
17
|
import { SessionInputCoordinator, type ReplaceLatestTurnInput, type SubmitSessionInput } from './session-input-coordinator.js';
|
|
18
18
|
export interface GatewayAgentRunnerOptions {
|
|
19
|
+
canReact?: (endpointId: string) => boolean;
|
|
19
20
|
canResumeDeviceInteraction?: (conversationId: string, checkpoint: import('@xopcai/gateway-contract').DeviceInteractionCheckpoint) => boolean;
|
|
20
21
|
afterConnectionResume?: (input: import('../../storage/sqlite/session-input-repository.js').SessionInput, status: string) => Promise<void>;
|
|
21
22
|
validateConnectionResume?: (input: import('../../storage/sqlite/session-input-repository.js').SessionInput) => Promise<boolean>;
|
|
@@ -47,6 +48,7 @@ export declare class GatewayAgentRunner {
|
|
|
47
48
|
private readonly externalClarificationResponses;
|
|
48
49
|
readonly inputs: SessionInputCoordinator;
|
|
49
50
|
readonly nextTurnSuggestions: NextTurnSuggestionService;
|
|
51
|
+
private readonly reactions;
|
|
50
52
|
private readonly unsubscribeConnectionWait;
|
|
51
53
|
constructor(opts: GatewayAgentRunnerOptions);
|
|
52
54
|
/** True when a webchat agent run is currently in-flight for `conversationId`. */
|
|
@@ -20,6 +20,7 @@ import { completePhoneAssistanceFromUser, preparePhoneContinuation } from "../..
|
|
|
20
20
|
import { describeActiveExecution } from "./active-execution.js";
|
|
21
21
|
import { runGatewayAgent } from "./run-gateway-agent.js";
|
|
22
22
|
import { NextTurnSuggestionService } from "../next-turn-suggestions/service.js";
|
|
23
|
+
import { AgentReactionService } from "../agent-reactions/reaction.js";
|
|
23
24
|
import { fitSourceContextsToBudget } from "../../agent/source-context/budget.js";
|
|
24
25
|
import { SessionInputCoordinator } from "./session-input-coordinator.js";
|
|
25
26
|
import crypto from "node:crypto";
|
|
@@ -50,6 +51,7 @@ var GatewayAgentRunner = class {
|
|
|
50
51
|
externalClarificationResponses = /* @__PURE__ */ new Map();
|
|
51
52
|
inputs;
|
|
52
53
|
nextTurnSuggestions;
|
|
54
|
+
reactions = new AgentReactionService();
|
|
53
55
|
unsubscribeConnectionWait;
|
|
54
56
|
constructor(opts) {
|
|
55
57
|
this.opts = opts;
|
|
@@ -230,7 +232,9 @@ var GatewayAgentRunner = class {
|
|
|
230
232
|
sessionIndex: this.opts.sessionIndex,
|
|
231
233
|
emit: this.opts.emit,
|
|
232
234
|
publishRealtime: this.opts.publishRealtime,
|
|
233
|
-
completeRealtimeTopic: this.opts.completeRealtimeTopic
|
|
235
|
+
completeRealtimeTopic: this.opts.completeRealtimeTopic,
|
|
236
|
+
reactions: this.reactions,
|
|
237
|
+
canReact: this.opts.canReact
|
|
234
238
|
}, message, channel, chatId, origin, attachments, thinking, cancellation ? {
|
|
235
239
|
...runOptions,
|
|
236
240
|
signal: runOptions?.signal ? AbortSignal.any([runOptions.signal, cancellation.signal]) : cancellation.signal
|
|
@@ -4,8 +4,8 @@ import { getModelRegistry } from "../../providers/model-registry.js";
|
|
|
4
4
|
import { init_providers } from "../../providers/index.js";
|
|
5
5
|
import { configureTracing } from "../../observability/runtime.js";
|
|
6
6
|
import { reloadImageGenerationProviders } from "../../agent/image/generation/provider-registry.js";
|
|
7
|
-
import { evictAllEmbeddedSessionRunners } from "../../agent/embedded/session-runner.js";
|
|
8
7
|
import { loadConfig, saveConfig } from "../../config/loader.js";
|
|
8
|
+
import { evictAllEmbeddedSessionRunners } from "../../agent/embedded/session-runner.js";
|
|
9
9
|
import { ConfigHotReloader } from "../../config/reload.js";
|
|
10
10
|
import "../../config/index.js";
|
|
11
11
|
import { computeExtensionActivationPatch } from "../../extensions/bundled-extension-activation.js";
|
|
@@ -7,6 +7,7 @@ import type { ChatStreamEvent } from '../chat-stream/protocol.js';
|
|
|
7
7
|
import type { UserTurnAttachment } from '../user-turn-input.js';
|
|
8
8
|
import type { AgentSourceContext } from '../../agent/source-context/types.js';
|
|
9
9
|
import { type ActiveExecution } from './active-execution.js';
|
|
10
|
+
import type { AgentReactionService } from '../agent-reactions/reaction.js';
|
|
10
11
|
export type RunGatewayAgentYield = ChatStreamEvent;
|
|
11
12
|
export type RunGatewayAgentOptions = {
|
|
12
13
|
inputReceivedAtMs?: number;
|
|
@@ -31,6 +32,8 @@ export type RunGatewayAgentDeps = {
|
|
|
31
32
|
emit: (type: string, payload: unknown) => void;
|
|
32
33
|
publishRealtime: (topic: string, event: string, data: unknown) => void;
|
|
33
34
|
completeRealtimeTopic: (topic: string) => void;
|
|
35
|
+
reactions?: AgentReactionService;
|
|
36
|
+
canReact?: (endpointId: string) => boolean;
|
|
34
37
|
};
|
|
35
38
|
/**
|
|
36
39
|
* @param runOptions.signal — When set (e.g. client disconnect), aborts in-flight generation and persists partial output.
|
|
@@ -43,6 +43,9 @@ async function* runGatewayAgent(deps, message, channel, chatId, origin, attachme
|
|
|
43
43
|
const runStartedMonotonic = performance.now();
|
|
44
44
|
const inputReceivedAtMs = runOptions?.inputReceivedAtMs ?? runStartedAtMs;
|
|
45
45
|
let firstTextSeen = false;
|
|
46
|
+
let reactionWindow;
|
|
47
|
+
let reactionPending = false;
|
|
48
|
+
let publishReactionFallback;
|
|
46
49
|
const cappedAttachments = attachments && attachments.length > 10 ? attachments.slice(0, 10) : attachments;
|
|
47
50
|
if (attachments && cappedAttachments && attachments.length > cappedAttachments.length) log.debug({
|
|
48
51
|
dropped: attachments.length - cappedAttachments.length,
|
|
@@ -140,7 +143,10 @@ async function* runGatewayAgent(deps, message, channel, chatId, origin, attachme
|
|
|
140
143
|
};
|
|
141
144
|
const emitAndYield = function* (events) {
|
|
142
145
|
for (const event of events) {
|
|
143
|
-
|
|
146
|
+
const firstText = !firstTextSeen && event.type === "assistant_delta" && Boolean(event.payload.delta.trim());
|
|
147
|
+
const reactionClosed = firstText || event.type === "clarify_request" || event.type === "review" || event.type === "error" || event.type === "run_end";
|
|
148
|
+
if (reactionClosed) reactionWindow?.abort();
|
|
149
|
+
if (firstText) {
|
|
144
150
|
firstTextSeen = true;
|
|
145
151
|
const latencyMs = performance.now() - runStartedMonotonic;
|
|
146
152
|
const queueMs = Math.max(0, runStartedAtMs - inputReceivedAtMs);
|
|
@@ -164,6 +170,7 @@ async function* runGatewayAgent(deps, message, channel, chatId, origin, attachme
|
|
|
164
170
|
}
|
|
165
171
|
if (taskRun) captureTaskEvent(event);
|
|
166
172
|
if (channel === "webchat") publishRealtime(runTopic, event.type, event);
|
|
173
|
+
if (reactionClosed || event.type === "user_message" && !reactionPending) publishReactionFallback?.();
|
|
167
174
|
yield event;
|
|
168
175
|
}
|
|
169
176
|
};
|
|
@@ -196,6 +203,38 @@ async function* runGatewayAgent(deps, message, channel, chatId, origin, attachme
|
|
|
196
203
|
runId,
|
|
197
204
|
...runOptions?.inputIdentity
|
|
198
205
|
});
|
|
206
|
+
const identity = runOptions?.inputIdentity;
|
|
207
|
+
const reactions = deps.reactions;
|
|
208
|
+
if (personalTurn && reactions && webchatTranscriptId && !runOptions?.presentation && !runOptions?.taskRunId && identity && origin.type === "endpoint" && deps.config.experimental?.personalAgentMessageReactions) {
|
|
209
|
+
const target = {
|
|
210
|
+
...identity,
|
|
211
|
+
conversationId,
|
|
212
|
+
runId,
|
|
213
|
+
transcriptId: webchatTranscriptId,
|
|
214
|
+
actorAgentId: webchatMetadata.agentId
|
|
215
|
+
};
|
|
216
|
+
const publish = (reaction) => {
|
|
217
|
+
publishReactionFallback = void 0;
|
|
218
|
+
publishRealtime("sessions", "session.agent-reaction", reaction);
|
|
219
|
+
};
|
|
220
|
+
publishReactionFallback = () => reactions.publishFallback(target, publish);
|
|
221
|
+
const endpointId = origin.endpointId;
|
|
222
|
+
if (deps.canReact?.(endpointId)) {
|
|
223
|
+
reactionWindow = new AbortController();
|
|
224
|
+
reactionPending = true;
|
|
225
|
+
reactions.consider({
|
|
226
|
+
target,
|
|
227
|
+
text: message,
|
|
228
|
+
started: runStartedMonotonic,
|
|
229
|
+
signal: AbortSignal.any([mergedSignal, reactionWindow.signal]),
|
|
230
|
+
eligible: () => deps.canReact?.(endpointId) === true,
|
|
231
|
+
publish
|
|
232
|
+
}).catch(() => {}).finally(() => {
|
|
233
|
+
reactionPending = false;
|
|
234
|
+
publishReactionFallback?.();
|
|
235
|
+
});
|
|
236
|
+
}
|
|
237
|
+
}
|
|
199
238
|
}
|
|
200
239
|
let streamError;
|
|
201
240
|
let embeddedAborted = false;
|
|
@@ -277,6 +316,8 @@ async function* runGatewayAgent(deps, message, channel, chatId, origin, attachme
|
|
|
277
316
|
summary: streamError
|
|
278
317
|
};
|
|
279
318
|
} finally {
|
|
319
|
+
reactionWindow?.abort();
|
|
320
|
+
publishReactionFallback?.();
|
|
280
321
|
if (mergedSignal.aborted) {
|
|
281
322
|
terminalStatus = "cancelled";
|
|
282
323
|
taskRunStatus = "cancelled";
|
|
@@ -393,6 +434,7 @@ async function* runGatewayAgent(deps, message, channel, chatId, origin, attachme
|
|
|
393
434
|
}
|
|
394
435
|
throw error;
|
|
395
436
|
} finally {
|
|
437
|
+
reactionWindow?.abort();
|
|
396
438
|
if (personalTurn) recordPersonalPerformance({
|
|
397
439
|
phase: "turn_complete",
|
|
398
440
|
conversationId: streamConversationId,
|
|
@@ -14,6 +14,10 @@ export declare class TaskConversationQueryService {
|
|
|
14
14
|
}): Promise<{
|
|
15
15
|
session: {
|
|
16
16
|
messages: import("../../session/types.js").Message[];
|
|
17
|
+
agentReactions?: {
|
|
18
|
+
available: boolean;
|
|
19
|
+
enabled: boolean;
|
|
20
|
+
};
|
|
17
21
|
transcriptSummary?: import("../../session/types.js").SessionTranscriptSummary;
|
|
18
22
|
transcriptRows?: import("../../session/session-context-for-llm.js").TranscriptStoredRow[];
|
|
19
23
|
key: string;
|
|
@@ -52,11 +52,11 @@ import { NotesService } from "../notes/service.js";
|
|
|
52
52
|
import { setPairingBroadcastSink } from "../channels/pairing/pairing-events.js";
|
|
53
53
|
import { weixinPrivateIdentity } from "../agent/mcp/weixin-setup-scope.js";
|
|
54
54
|
import { AutomationService } from "../automations/service/automation-service.js";
|
|
55
|
-
import { ProjectService } from "../projects/project-service.js";
|
|
56
|
-
import { resolveProjectAgentId } from "../projects/project-agent.js";
|
|
57
55
|
import { buildResultAgentContext } from "../agent/source-context/result-context.js";
|
|
58
56
|
import { buildTaskAgentContext } from "../agent/source-context/task-context.js";
|
|
59
57
|
import { buildUserAssertionAgentContext } from "../agent/source-context/user-assertion-context.js";
|
|
58
|
+
import { ProjectService } from "../projects/project-service.js";
|
|
59
|
+
import { resolveProjectAgentId } from "../projects/project-agent.js";
|
|
60
60
|
import "../projects/index.js";
|
|
61
61
|
import { assertTaskHandoffAccess, getTaskHandoff } from "../tasks/task-handoff.js";
|
|
62
62
|
import { TaskApplicationService } from "../tasks/task-application-service.js";
|
|
@@ -70,16 +70,16 @@ import { runMemoryMaintenance } from "../memory-maintenance/service.js";
|
|
|
70
70
|
import "../memory-maintenance/index.js";
|
|
71
71
|
import { RealtimeExtensionBrowserProvider } from "../browser/providers/realtime-extension.js";
|
|
72
72
|
import { drainPersonalResultReads } from "../personal-agent/result-read-continuations.js";
|
|
73
|
-
import { drainEmbeddedSessionRunnerShutdowns, evictAllEmbeddedSessionRunners } from "../agent/embedded/session-runner.js";
|
|
74
73
|
import { areExtensionsGloballyDisabled } from "../extensions/discover-extensions.js";
|
|
74
|
+
import { buildExtensionMetadataSnapshot } from "../extensions/extension-metadata-snapshot.js";
|
|
75
|
+
import { buildChannelCatalogForConfig, buildChannelCatalogFromSnapshot } from "../channels/catalog/channel-catalog-service.js";
|
|
76
|
+
import { loadConfig, saveConfig } from "../config/loader.js";
|
|
77
|
+
import { drainEmbeddedSessionRunnerShutdowns, evictAllEmbeddedSessionRunners } from "../agent/embedded/session-runner.js";
|
|
75
78
|
import { collectMediaUrisFromMessages, deleteMediaUris } from "../media/session-references.js";
|
|
76
79
|
import { SessionIndex } from "../session/manager.js";
|
|
77
80
|
import "../session/index.js";
|
|
78
81
|
import { ExtensionLoader } from "../extensions/loader.js";
|
|
79
|
-
import { buildExtensionMetadataSnapshot } from "../extensions/extension-metadata-snapshot.js";
|
|
80
82
|
import "../extensions/index.js";
|
|
81
|
-
import { buildChannelCatalogForConfig, buildChannelCatalogFromSnapshot } from "../channels/catalog/channel-catalog-service.js";
|
|
82
|
-
import { loadConfig, saveConfig } from "../config/loader.js";
|
|
83
83
|
import { MessageBus, MessageBusShutdownError } from "../infra/bus/queue.js";
|
|
84
84
|
import "../infra/bus/index.js";
|
|
85
85
|
import { publishVoiceChatMessage } from "../voice/realtime/chat-publication.js";
|
|
@@ -105,10 +105,6 @@ import { DiscussionSealer } from "../discussions/sealer.js";
|
|
|
105
105
|
import "../discussions/index.js";
|
|
106
106
|
import { EndpointToolRuntime } from "../endpoint-tools/runtime.js";
|
|
107
107
|
import "../endpoint-tools/index.js";
|
|
108
|
-
import { HomeCapabilityPreflightService } from "../home-intelligence/capability-preflight.js";
|
|
109
|
-
import { HomeAdviceGenerator } from "../home-intelligence/generator.js";
|
|
110
|
-
import { HomeIntelligenceHost } from "../home-intelligence/host.js";
|
|
111
|
-
import { HomeSnapshotBuilder } from "../home-intelligence/snapshot.js";
|
|
112
108
|
import { assertGatewayAuthConfigured, extractToken, resolveGatewayAuth, validateToken } from "./auth.js";
|
|
113
109
|
import { prepareAutomationAgentSession } from "./automation-agent-session.js";
|
|
114
110
|
import { deliverAutomationCompletion } from "./automation-completion-delivery.js";
|
|
@@ -178,6 +174,10 @@ import { TaskMainUpdateDecisionService } from "../tasks/task-main-update-decisio
|
|
|
178
174
|
import { selectTaskMainUpdateAttempt, submitAndConfirmTaskMainUpdate } from "../tasks/task-main-update-input.js";
|
|
179
175
|
import { checkAppContextAccess, prepareAppContext } from "./service/app-context-access.js";
|
|
180
176
|
import { applyAutomaticVoiceLanguage, inferProductLanguageFromEnvironment, initializeVoiceDefaults } from "../voice/language-profile.js";
|
|
177
|
+
import { HomeAdviceGenerator } from "../home-intelligence/generator.js";
|
|
178
|
+
import { HomeIntelligenceHost } from "../home-intelligence/host.js";
|
|
179
|
+
import { HomeSnapshotBuilder } from "../home-intelligence/snapshot.js";
|
|
180
|
+
import { HomeCapabilityPreflightService } from "../home-intelligence/capability-preflight.js";
|
|
181
181
|
import crypto from "node:crypto";
|
|
182
182
|
//#region src/gateway/service.ts
|
|
183
183
|
init_session_repository();
|
|
@@ -365,7 +365,7 @@ var GatewayService = class {
|
|
|
365
365
|
type: "system",
|
|
366
366
|
source: "internal"
|
|
367
367
|
},
|
|
368
|
-
content: `MCP configuration is saved. This is the automatic continuation, not the setup turn. Use tool_search with the exact query mcp__${goal.serverId.replace(/-/g, "_")} to discover this server’s native tools, then complete the original user objective. A natural-language tool search may miss the service; retry with this exact namespace before reporting unavailable tools.
|
|
368
|
+
content: `MCP configuration is saved. This is the automatic continuation, not the setup turn. Use tool_search with the exact query mcp__${goal.serverId.replace(/-/g, "_")} to discover this server’s native tools, then complete the original user objective. A natural-language tool search may miss the service; retry with this exact namespace before reporting unavailable tools. For a connection-only request, briefly report the verified connection and its capabilities without reading account data or running business tools. For a task request, finish the original task and report the verified result. A connection check is not a business result. Do not repeat configuration, request secrets, or treat this status as extra write permission. Setup data: ${JSON.stringify({
|
|
369
369
|
serverId: goal.serverId,
|
|
370
370
|
originalObjective: goal.purpose,
|
|
371
371
|
objective: goal.objective
|
|
@@ -617,6 +617,11 @@ var GatewayService = class {
|
|
|
617
617
|
});
|
|
618
618
|
this.chatPreviews = new ChatPreviewService({ localApps: this.localApps });
|
|
619
619
|
this.agentRunner = new GatewayAgentRunner({
|
|
620
|
+
canReact: (endpointId) => {
|
|
621
|
+
if (!this.config.experimental.personalAgentMessageReactions) return false;
|
|
622
|
+
const endpoint = this.endpointTools.registry.get(endpointId);
|
|
623
|
+
return endpoint?.kind === "mobile" && endpoint.platform === "harmonyos" && endpoint.availability === "foreground";
|
|
624
|
+
},
|
|
620
625
|
canResumeDeviceInteraction: (conversationId, checkpoint) => this.endpointTools.canResumeDeviceInteraction(conversationId, checkpoint),
|
|
621
626
|
afterConnectionResume: (input, status) => this.mcpSetup.completeContinuation(input, status === "ok" ? this.agentService.getLastAssistantPlainText(input.conversationId) : "连接已保存,但后续读取未完成。请在原微信私聊查看状态或重试;尚未验证业务结果。"),
|
|
622
627
|
continueConnection: (wait, idempotencyKey) => this.connectionRecovery.continueObjective(wait, idempotencyKey),
|
|
@@ -797,6 +802,10 @@ var GatewayService = class {
|
|
|
797
802
|
getAutomationService: () => this.automationService,
|
|
798
803
|
getBrowserSetupService: () => this.browserSetup,
|
|
799
804
|
getMcpSetupService: () => this.mcpSetup,
|
|
805
|
+
getCapabilityChannelState: () => ({
|
|
806
|
+
channelSnapshot: this.extensionLoader?.getManifestSnapshot(),
|
|
807
|
+
runningChannels: new Set(this.getRunningChannelIds())
|
|
808
|
+
}),
|
|
800
809
|
getPhoneSetupService: () => this.phoneSetup,
|
|
801
810
|
canConfigureEndpoint: (endpointId) => this.realtime.canConfigureEndpoint(endpointId),
|
|
802
811
|
emitBrowserEvent: (type, payload) => this.emit(type, payload),
|
|
@@ -7,14 +7,14 @@ import { TaskRepository, init_task_repository } from "../tasks/task-repository.j
|
|
|
7
7
|
import { appendTranscriptEntry } from "../storage/sqlite/transcript-repository.js";
|
|
8
8
|
import { createConversation, init_conversation_repository } from "../storage/sqlite/conversation-repository.js";
|
|
9
9
|
import { TaskApplicationService } from "../tasks/task-application-service.js";
|
|
10
|
-
import { homePatternKey } from "./strategy.js";
|
|
11
|
-
import { HomeIntelligenceRepository } from "./repository.js";
|
|
12
|
-
import { HomeOpportunityApplicationService } from "./application-service.js";
|
|
13
|
-
import { HomeAdvicePolicy } from "./policy.js";
|
|
14
10
|
import { HomeObservation, ObservationConflictError } from "./observation.js";
|
|
15
11
|
import { HomeFollowUps } from "./follow-ups.js";
|
|
16
|
-
import { HomeAdviceBudgetExceededError, isHomeProseLocalized } from "./generator.js";
|
|
17
12
|
import { observationStarters } from "./observation-starters.js";
|
|
13
|
+
import { HomeAdviceBudgetExceededError, isHomeProseLocalized } from "./generator.js";
|
|
14
|
+
import { homePatternKey } from "./strategy.js";
|
|
15
|
+
import { HomeAdvicePolicy } from "./policy.js";
|
|
16
|
+
import { HomeIntelligenceRepository } from "./repository.js";
|
|
17
|
+
import { HomeOpportunityApplicationService } from "./application-service.js";
|
|
18
18
|
import { buildHomeOpportunityNotification } from "./notification.js";
|
|
19
19
|
import { ObservationRoutines } from "./routines.js";
|
|
20
20
|
import { createHash } from "node:crypto";
|
|
@@ -41,6 +41,7 @@ function toRecord(ownerId, agent, session) {
|
|
|
41
41
|
appearance: appearanceFrom(agent),
|
|
42
42
|
voicePreference: agent.profile?.voicePreference ?? null,
|
|
43
43
|
voiceCallPreferences: agent.profile?.voiceCallPreferences ?? { openingGreetingEnabled: true },
|
|
44
|
+
messageReactionsEnabled: agent.profile?.messageReactionsEnabled !== false,
|
|
44
45
|
revision: agent.revision,
|
|
45
46
|
errorMessage: agent.provisioningError ?? null
|
|
46
47
|
};
|
|
@@ -1,7 +1,15 @@
|
|
|
1
|
-
import type { Automation, AutomationAction } from '../automations/domain/types.js';
|
|
1
|
+
import type { Automation, AutomationAction, AutomationNotificationPolicy, AutomationSchedule } from '../automations/domain/types.js';
|
|
2
|
+
import type { CreateAutomationInput } from '../automations/domain/validation.js';
|
|
3
|
+
import { type PersonalAgentRecord } from './repository.js';
|
|
2
4
|
type PersonalTaskAction = Extract<AutomationAction, {
|
|
3
5
|
kind: 'personal_task';
|
|
4
6
|
}>;
|
|
7
|
+
export declare function personalScheduleInput(profile: Pick<PersonalAgentRecord, 'agentId' | 'conversationId'>, input: Pick<CreateAutomationInput, 'id' | 'name' | 'description' | 'enabled'> & {
|
|
8
|
+
instruction: string;
|
|
9
|
+
locale: PersonalTaskAction['locale'];
|
|
10
|
+
schedule: AutomationSchedule;
|
|
11
|
+
notificationPolicy?: AutomationNotificationPolicy;
|
|
12
|
+
}): CreateAutomationInput;
|
|
5
13
|
export declare function isPersonalSchedule(automation: Automation | null, conversationId: string, agentId: string): automation is Automation & {
|
|
6
14
|
action: PersonalTaskAction;
|
|
7
15
|
};
|
|
@@ -4,6 +4,37 @@ import { getPersonalAgent } from "./repository.js";
|
|
|
4
4
|
import { TaskApplicationService } from "../tasks/task-application-service.js";
|
|
5
5
|
//#region src/personal-agent/schedules.ts
|
|
6
6
|
init_src();
|
|
7
|
+
function personalScheduleInput(profile, input) {
|
|
8
|
+
const { instruction, locale, schedule, notificationPolicy = "attention", ...fields } = input;
|
|
9
|
+
return {
|
|
10
|
+
...fields,
|
|
11
|
+
trigger: {
|
|
12
|
+
kind: "schedule",
|
|
13
|
+
schedule
|
|
14
|
+
},
|
|
15
|
+
action: {
|
|
16
|
+
kind: "personal_task",
|
|
17
|
+
agentId: profile.agentId,
|
|
18
|
+
conversationId: profile.conversationId,
|
|
19
|
+
instruction,
|
|
20
|
+
locale
|
|
21
|
+
},
|
|
22
|
+
management: {
|
|
23
|
+
owner: "personal-agent",
|
|
24
|
+
editable: ["enabled", "trigger"],
|
|
25
|
+
runnable: true,
|
|
26
|
+
deletable: true
|
|
27
|
+
},
|
|
28
|
+
conversationMode: "new_session",
|
|
29
|
+
delivery: {
|
|
30
|
+
notificationPolicy,
|
|
31
|
+
destinations: [{
|
|
32
|
+
key: "gateway_event",
|
|
33
|
+
kind: "gateway_event"
|
|
34
|
+
}]
|
|
35
|
+
}
|
|
36
|
+
};
|
|
37
|
+
}
|
|
7
38
|
function isPersonalSchedule(automation, conversationId, agentId) {
|
|
8
39
|
return automation?.action.kind === "personal_task" && automation.action.conversationId === conversationId && automation.action.agentId === agentId;
|
|
9
40
|
}
|
|
@@ -41,4 +72,4 @@ function startScheduledPersonalTask(title, action, runId) {
|
|
|
41
72
|
return result.model.task.id;
|
|
42
73
|
}
|
|
43
74
|
//#endregion
|
|
44
|
-
export { isPersonalSchedule, startScheduledPersonalTask };
|
|
75
|
+
export { isPersonalSchedule, personalScheduleInput, startScheduledPersonalTask };
|
|
@@ -34,9 +34,9 @@ export declare function patchPersonalProfile(service: PersonalAgentHost, ownerId
|
|
|
34
34
|
provider: string;
|
|
35
35
|
model: string;
|
|
36
36
|
voice: string;
|
|
37
|
-
} | null, voiceCallPreferences?: VoiceCallPreferencesPatch): Promise<PersonalAgentRecord | null>;
|
|
37
|
+
} | null, voiceCallPreferences?: VoiceCallPreferencesPatch, messageReactionsEnabled?: boolean): Promise<PersonalAgentRecord | null>;
|
|
38
38
|
export declare function updatePersonalProfileRecord(ownerId: string, revision: number, displayName: string, appearance: PersonalAppearance, voicePreference?: {
|
|
39
39
|
provider: string;
|
|
40
40
|
model: string;
|
|
41
41
|
voice: string;
|
|
42
|
-
} | null, voiceCallPreferences?: VoiceCallPreferencesPatch): Promise<PersonalAgentRecord | null>;
|
|
42
|
+
} | null, voiceCallPreferences?: VoiceCallPreferencesPatch, messageReactionsEnabled?: boolean): Promise<PersonalAgentRecord | null>;
|