@xopcai/xopc 0.0.246 → 0.0.248
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/src/update-offset-store.js +17 -54
- package/dist/extensions/telegram/xopc.extension.json +1 -1
- package/dist/extensions/weixin/src/auth/accounts.js +3 -5
- package/dist/extensions/weixin/src/monitor/monitor.js +3 -5
- package/dist/extensions/weixin/src/storage/sync-buf.d.ts +3 -6
- package/dist/extensions/weixin/src/storage/sync-buf.js +9 -22
- package/dist/gateway/static/root/assets/{activity-store-BlxqErph.js → activity-store-etpmyV7S.js} +1 -1
- package/dist/gateway/static/root/assets/{agent-avatar-dicebear-CJJzpYYS.js → agent-avatar-dicebear-BmKxSM1k.js} +1 -1
- package/dist/gateway/static/root/assets/agent-defaults-settings-panel-CUXApfcE.js +1 -0
- package/dist/gateway/static/root/assets/{agents-je3sRGmk.js → agents-DNq_GKuc.js} +1 -1
- package/dist/gateway/static/root/assets/{api-BbXzyQMj.js → api-B0-hLuZ1.js} +1 -1
- package/dist/gateway/static/root/assets/{app-management-settings-panel-Cnn3i00c.js → app-management-settings-panel-qfwAgyhQ.js} +1 -1
- package/dist/gateway/static/root/assets/{appearance-settings-BToQaw_v.js → appearance-settings-DqQVUpCC.js} +1 -1
- package/dist/gateway/static/root/assets/apps-page-dwIqYmXk.js +1 -0
- package/dist/gateway/static/root/assets/{archive-plugin-DD2SweEH.js → archive-plugin-BnMSgZvR.js} +1 -1
- package/dist/gateway/static/root/assets/{attachment-load-BFtcib5t.js → attachment-load-CejsQMev.js} +1 -1
- package/dist/gateway/static/root/assets/{automations-page-XS8wIl5o.js → automations-page-RC8EyoAf.js} +1 -1
- package/dist/gateway/static/root/assets/automations-workspace-SkdcSZ0i.js +6 -0
- package/dist/gateway/static/root/assets/{binary-plugins-Xs7pLHxR.js → binary-plugins-DGjppLSG.js} +1 -1
- package/dist/gateway/static/root/assets/{block-editor-BPdSzceB.js → block-editor-CWdP4bUc.js} +44 -44
- package/dist/gateway/static/root/assets/browser-settings-page-CKCa6TvG.js +8 -0
- package/dist/gateway/static/root/assets/{browser-workflow-inputs-BAAc151l.js → browser-workflow-inputs-BQ1Ilw_o.js} +1 -1
- package/dist/gateway/static/root/assets/{browser-workflows-page-DUPPvE30.js → browser-workflows-page-CJh4NyxT.js} +2 -2
- package/dist/gateway/static/root/assets/{capabilities-settings-panel-cl9kYilL.js → capabilities-settings-panel-DSp--zIZ.js} +5 -5
- package/dist/gateway/static/root/assets/channels-settings-CMd2dDrI.js +1 -0
- package/dist/gateway/static/root/assets/{channels-status-swr-CCBCtLDg.js → channels-status-swr-Ohhee4vm.js} +1 -1
- package/dist/gateway/static/root/assets/{chat-terminal-dock-DKW1M6aJ.js → chat-terminal-dock-BOtoKTK3.js} +2 -2
- package/dist/gateway/static/root/assets/connectors-page-udWs5Kdm.js +2 -0
- package/dist/gateway/static/root/assets/{cron-expression-Bijb0ZQu.js → cron-expression-DTj1V3Sw.js} +1 -1
- package/dist/gateway/static/root/assets/{date-picker-BZuHw-SY.js → date-picker-Yr6OCvGL.js} +1 -1
- package/dist/gateway/static/root/assets/{dependency-picker-BsBD2JFY.js → dependency-picker-DpN3XZg9.js} +1 -1
- package/dist/gateway/static/root/assets/{desktop-pet-Ceuw3QKb.js → desktop-pet-DbGzggPF.js} +1 -1
- package/dist/gateway/static/root/assets/{desktop-pet-settings-DctOXexM.js → desktop-pet-settings-DinCToZh.js} +1 -1
- package/dist/gateway/static/root/assets/{extension-debug-page-BNlMPATK.js → extension-debug-page-DgTtk4KC.js} +1 -1
- package/dist/gateway/static/root/assets/{extension-page-CK4Uvzge.js → extension-page-DtQeiP6f.js} +1 -1
- package/dist/gateway/static/root/assets/{extension-settings-page-CpnXXemw.js → extension-settings-page-DcguCgsH.js} +1 -1
- package/dist/gateway/static/root/assets/{gateway-config-api-C_mlpe-r.js → gateway-config-api-Br7lSf6H.js} +1 -1
- package/dist/gateway/static/root/assets/{gateway-config-swr-826dipyU.js → gateway-config-swr-DXuXtU1w.js} +1 -1
- package/dist/gateway/static/root/assets/{gateway-settings-DSSW17ed.js → gateway-settings-CdPoDMuj.js} +1 -1
- package/dist/gateway/static/root/assets/{gateway-startup-retry-DyvcAIMm.js → gateway-startup-retry-CzBzglzQ.js} +1 -1
- package/dist/gateway/static/root/assets/{heartbeat-settings-hbmIZTpg.js → heartbeat-settings-DHk1hawP.js} +1 -1
- package/dist/gateway/static/root/assets/home-page-YGipe_W6.js +1 -0
- package/dist/gateway/static/root/assets/{image-generation-api-D7cyfks6.js → image-generation-api-TIgsn04n.js} +1 -1
- package/dist/gateway/static/root/assets/{index-eZjksPvq.js → index-D5TQQpeb.js} +44 -44
- package/dist/gateway/static/root/assets/index-DReBaaTX.css +2 -0
- package/dist/gateway/static/root/assets/{keyboard-shortcuts-settings-BQrDwwgi.js → keyboard-shortcuts-settings-wsWuoa8p.js} +1 -1
- package/dist/gateway/static/root/assets/local-app-workbench-page-CpyvYyrb.js +2 -0
- package/dist/gateway/static/root/assets/{local-apps-page-D-YWD6LS.js → local-apps-page-CXrbrGo8.js} +1 -1
- package/dist/gateway/static/root/assets/local-context-graph-BjUf7fQ9.js +1 -0
- package/dist/gateway/static/root/assets/{locale-store-CBoCuIMx.js → locale-store-BJFLQY8O.js} +1 -1
- package/dist/gateway/static/root/assets/{logs-page-DvLc9l59.js → logs-page-CXKy6E_l.js} +2 -2
- package/dist/gateway/static/root/assets/{management-settings-DsULLUUv.js → management-settings-BdJZFR7U.js} +1 -1
- package/dist/gateway/static/root/assets/{markdown-split-CjqlP6IB.js → markdown-split-NK3ACVG2.js} +1 -1
- package/dist/gateway/static/root/assets/{markdown-view-BXsHghJd.js → markdown-view-DTF9v1gg.js} +1 -1
- package/dist/gateway/static/root/assets/{media-plugins-DQL029DU.js → media-plugins-F0jcUxyl.js} +1 -1
- package/dist/gateway/static/root/assets/messages-CHNYp8EQ.js +3 -0
- package/dist/gateway/static/root/assets/{mobile-pairing-wizard-gauprAae.js → mobile-pairing-wizard-3NKCniSp.js} +1 -1
- package/dist/gateway/static/root/assets/models-hub-cache-nCfkBN8M.js +1 -0
- package/dist/gateway/static/root/assets/{notes-page-AsEfLZt9.js → notes-page-DuqLahi6.js} +1 -1
- package/dist/gateway/static/root/assets/notes-workbench-C7j9EdQk.js +5 -0
- package/dist/gateway/static/root/assets/{oauth-api-BjSUDIgq.js → oauth-api-8lP_qJpq.js} +1 -1
- package/dist/gateway/static/root/assets/{product-open-page-CAJeUXeU.js → product-open-page-CxGGlWA8.js} +1 -1
- package/dist/gateway/static/root/assets/project-detail-page-CfebYVX0.js +1 -0
- package/dist/gateway/static/root/assets/projects-page-48GvzSVa.js +1 -0
- package/dist/gateway/static/root/assets/{registry-api-BhGKnvLP.js → registry-api-CIsNlSBi.js} +1 -1
- package/dist/gateway/static/root/assets/remote-access-hub-64xj_s2m.js +1 -0
- package/dist/gateway/static/root/assets/{runtime-tools-settings-panel-DH6EilMV.js → runtime-tools-settings-panel-YkjhiQfA.js} +2 -2
- package/dist/gateway/static/root/assets/{schema-form-DYHmEZeZ.js → schema-form-oFGf3G3s.js} +1 -1
- package/dist/gateway/static/root/assets/sessions-page-CcwcdRN8.js +1 -0
- package/dist/gateway/static/root/assets/settings-advanced-gate-BaN84CyW.js +1 -0
- package/dist/gateway/static/root/assets/{settings-page-BHwPd_M3.js → settings-page-C7VWs0IT.js} +1 -1
- package/dist/gateway/static/root/assets/setup-status-panel-DVVOCNbr.js +1 -0
- package/dist/gateway/static/root/assets/{share-preview-page-BjwrS03F.js → share-preview-page-t5oz18rh.js} +1 -1
- package/dist/gateway/static/root/assets/shares-settings-DUYbYLi7.js +1 -0
- package/dist/gateway/static/root/assets/skill-reload-api-BGyD0gB9.js +1 -0
- package/dist/gateway/static/root/assets/{skills-page-OHyK25op.js → skills-page-CjF8DTsN.js} +1 -1
- package/dist/gateway/static/root/assets/{skills-page.utils-DQx9ulmg.js → skills-page.utils-DEDTYs2W.js} +1 -1
- package/dist/gateway/static/root/assets/{system-settings-panel-wO7DWv4C.js → system-settings-panel-BSYuRgFI.js} +1 -1
- package/dist/gateway/static/root/assets/task-detail-page-YZYSTJH7.js +1 -0
- package/dist/gateway/static/root/assets/{theme-store-hybK3oC9.js → theme-store-O597U8q_.js} +1 -1
- package/dist/gateway/static/root/assets/{tunnel-api-CVC8BHZu.js → tunnel-api-FKUi9wDL.js} +1 -1
- package/dist/gateway/static/root/assets/{use-autosave-DMvRu2XZ.js → use-autosave-B5eUJ6Zq.js} +1 -1
- package/dist/gateway/static/root/assets/user-context-page-BCyiduKd.js +2 -0
- package/dist/gateway/static/root/assets/{voice-api-key-field-DuBK2NDG.js → voice-api-key-field-CMKSwz4C.js} +1 -1
- package/dist/gateway/static/root/assets/{voice-config-api-CBbiF1T3.js → voice-config-api-q7B6fOFB.js} +1 -1
- package/dist/gateway/static/root/assets/{work-discovery-overlay-B7VXWpDr.js → work-discovery-overlay-jhT2EzeH.js} +1 -1
- package/dist/gateway/static/root/assets/{workflow-run-setup-panel-BokVAsWN.js → workflow-run-setup-panel-DZmvLZjb.js} +2 -2
- package/dist/gateway/static/root/assets/workflows-page-DQC0TpMa.js +5 -0
- package/dist/gateway/static/root/index.html +12 -12
- package/dist/package.js +1 -1
- package/dist/src/agent/commands/command-registry.d.ts +1 -0
- package/dist/src/agent/commands/command-registry.js +12 -22
- package/dist/src/agent/ipc/inbox.d.ts +8 -31
- package/dist/src/agent/ipc/inbox.js +64 -133
- package/dist/src/agent/service/process-direct-one-shot.js +15 -10
- package/dist/src/agent/workflow/catalog.d.ts +1 -8
- package/dist/src/agent/workflow/catalog.js +44 -102
- package/dist/src/agent/workflow/index.d.ts +1 -1
- package/dist/src/agent/workflow/index.js +2 -2
- package/dist/src/automations/domain/types.d.ts +1 -0
- package/dist/src/automations/service/action-executor.js +2 -2
- package/dist/src/automations/service/automation-service.js +2 -2
- package/dist/src/channels/manager.d.ts +1 -1
- package/dist/src/channels/manager.js +2 -2
- package/dist/src/channels/outbound/persist-store.d.ts +2 -8
- package/dist/src/channels/outbound/persist-store.js +11 -38
- package/dist/src/channels/outbound-sender.d.ts +1 -1
- package/dist/src/channels/outbound-sender.js +2 -2
- package/dist/src/cli/commands/connectors.js +1 -1
- package/dist/src/cli/commands/doctor/checks/database-schema.js +1 -1
- package/dist/src/config/schema.js +2 -2
- package/dist/src/connectors/auth-provider-registry.js +1 -1
- package/dist/src/connectors/composio-triggers.d.ts +2 -2
- package/dist/src/connectors/composio-triggers.js +8 -15
- package/dist/src/connectors/connected-source-ingestion.js +1 -1
- package/dist/src/connectors/health.js +1 -1
- package/dist/src/gateway/automation-agent-session.js +3 -0
- package/dist/src/gateway/heartbeat/service.js +1 -1
- package/dist/src/gateway/hono/lib/extension-store.js +8 -25
- package/dist/src/gateway/hono/routes/capabilities.js +1 -1
- package/dist/src/gateway/hono/routes/connectors.js +3 -3
- package/dist/src/gateway/hono/routes/mcp.js +1 -1
- package/dist/src/gateway/hono/routes/projects.js +1 -1
- package/dist/src/gateway/hono/routes/you.js +20 -4
- package/dist/src/gateway/service.js +4 -5
- package/dist/src/heartbeat/index.js +1 -1
- package/dist/src/notes/index.d.ts +1 -1
- package/dist/src/notes/index.js +2 -2
- package/dist/src/notes/paths.d.ts +0 -3
- package/dist/src/notes/paths.js +1 -10
- package/dist/src/notes/service.d.ts +0 -1
- package/dist/src/notes/service.js +0 -3
- package/dist/src/notes/store.d.ts +0 -2
- package/dist/src/notes/store.js +33 -80
- package/dist/src/share/hosted-session-share.d.ts +1 -4
- package/dist/src/share/hosted-session-share.js +14 -47
- package/dist/src/share/share-auto.d.ts +1 -1
- package/dist/src/share/share-auto.js +2 -2
- package/dist/src/share/share-store.d.ts +2 -7
- package/dist/src/share/share-store.js +153 -195
- package/dist/src/share/share-types.d.ts +0 -4
- package/dist/src/share/site-share-store.d.ts +3 -8
- package/dist/src/share/site-share-store.js +94 -153
- package/dist/src/share/site-share-types.d.ts +0 -4
- package/dist/src/storage/sqlite/connection.d.ts +1 -2
- package/dist/src/storage/sqlite/connection.js +50 -47
- package/dist/src/storage/sqlite/durable-queue.d.ts +16 -0
- package/dist/src/storage/sqlite/durable-queue.js +52 -0
- package/dist/src/storage/sqlite/durable-state.d.ts +16 -0
- package/dist/src/storage/sqlite/durable-state.js +43 -0
- package/dist/src/storage/sqlite/migrations/146_understanding_focus_exclusions.sql +9 -0
- package/dist/src/storage/sqlite/migrations/147_durable_application_state.sql +39 -0
- package/dist/src/storage/sqlite/migrations/runner.d.ts +1 -1
- package/dist/src/storage/sqlite/migrations/runner.js +3 -3
- package/dist/src/storage/sqlite/migrations/runner.ts +1 -1
- package/dist/src/storage/sqlite/schema.js +1 -1
- package/dist/src/storage/sqlite/understanding-focus-exclusions.d.ts +2 -0
- package/dist/src/storage/sqlite/understanding-focus-exclusions.js +24 -0
- package/dist/src/tui/tui-scoped-models.js +9 -6
- package/dist/src/tui/tui-startup-resources.js +1 -1
- package/dist/src/voice/dashscope/streaming-tts-stream.js +49 -0
- package/dist/src/voice/realtime/agentEngine.js +63 -18
- package/dist/src/voice/realtime/conversationTurn.d.ts +20 -0
- package/dist/src/voice/realtime/conversationTurn.js +83 -0
- package/dist/src/voice/realtime/omniEngine.js +72 -18
- package/dist/src/workflows/authoring/workflow-draft-store.d.ts +1 -5
- package/dist/src/workflows/authoring/workflow-draft-store.js +23 -43
- package/dist/src/workflows/index.js +2 -2
- package/dist/src/workflows/store/event-store.d.ts +1 -2
- package/dist/src/workflows/store/event-store.js +19 -64
- package/dist/src/workflows/store/paths.d.ts +0 -2
- package/dist/src/workflows/store/paths.js +1 -7
- package/dist/src/workflows/store/run-store.d.ts +0 -1
- package/dist/src/workflows/store/run-store.js +1 -24
- package/package.json +3 -3
- package/dist/gateway/static/root/assets/agent-defaults-settings-panel-0dRjnL2s.js +0 -1
- package/dist/gateway/static/root/assets/apps-page-EpUZsl4h.js +0 -1
- package/dist/gateway/static/root/assets/automations-workspace-BGQdHrip.js +0 -6
- package/dist/gateway/static/root/assets/browser-settings-page-DJGcm7rH.js +0 -8
- package/dist/gateway/static/root/assets/channels-settings-BcIr-_GM.js +0 -1
- package/dist/gateway/static/root/assets/connectors-page-DNHqaZfX.js +0 -2
- package/dist/gateway/static/root/assets/home-page-CaVvW77l.js +0 -1
- package/dist/gateway/static/root/assets/index-Dbh5SXyV.css +0 -2
- package/dist/gateway/static/root/assets/local-app-workbench-page-D3K1XmOM.js +0 -2
- package/dist/gateway/static/root/assets/messages-BbdwoxVo.js +0 -3
- package/dist/gateway/static/root/assets/models-hub-cache-88f4fzYS.js +0 -1
- package/dist/gateway/static/root/assets/notes-workbench-CI30cDh3.js +0 -4
- package/dist/gateway/static/root/assets/project-detail-page-jO_4I5zN.js +0 -1
- package/dist/gateway/static/root/assets/projects-page-BrTGFME0.js +0 -1
- package/dist/gateway/static/root/assets/remote-access-hub-CH70D5SH.js +0 -1
- package/dist/gateway/static/root/assets/sessions-page-hbfUNtNs.js +0 -1
- package/dist/gateway/static/root/assets/settings-advanced-gate-Vg3_jua6.js +0 -1
- package/dist/gateway/static/root/assets/setup-status-panel-DkcpWSss.js +0 -1
- package/dist/gateway/static/root/assets/shares-settings-BL4DEt6p.js +0 -1
- package/dist/gateway/static/root/assets/skill-reload-api-CafhNktn.js +0 -1
- package/dist/gateway/static/root/assets/task-detail-page-anyomXsu.js +0 -1
- package/dist/gateway/static/root/assets/user-context-page-BBk9YdBn.js +0 -1
- package/dist/gateway/static/root/assets/workflows-page-RUTv0yvR.js +0 -5
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
<link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png?v=20260713-1" />
|
|
12
12
|
<link rel="manifest" href="/site.webmanifest?v=20260713-1" />
|
|
13
13
|
<title>XOPC — Keep what matters moving.</title>
|
|
14
|
-
<script type="module" crossorigin src="/assets/index-
|
|
14
|
+
<script type="module" crossorigin src="/assets/index-D5TQQpeb.js"></script>
|
|
15
15
|
<link rel="modulepreload" crossorigin href="/assets/rolldown-runtime-aKtaBQYM.js">
|
|
16
16
|
<link rel="modulepreload" crossorigin href="/assets/preload-helper-zJ_50EbN.js">
|
|
17
17
|
<link rel="modulepreload" crossorigin href="/assets/vendor-react-BOUWij0V.js">
|
|
@@ -25,13 +25,13 @@
|
|
|
25
25
|
<link rel="modulepreload" crossorigin href="/assets/download-Dk-ZjtO6.js">
|
|
26
26
|
<link rel="modulepreload" crossorigin href="/assets/plus-Q2yW6OE7.js">
|
|
27
27
|
<link rel="modulepreload" crossorigin href="/assets/x-B_N4OPjy.js">
|
|
28
|
-
<link rel="modulepreload" crossorigin href="/assets/messages-
|
|
29
|
-
<link rel="modulepreload" crossorigin href="/assets/locale-store-
|
|
28
|
+
<link rel="modulepreload" crossorigin href="/assets/messages-CHNYp8EQ.js">
|
|
29
|
+
<link rel="modulepreload" crossorigin href="/assets/locale-store-BJFLQY8O.js">
|
|
30
30
|
<link rel="modulepreload" crossorigin href="/assets/cn-JdwAhgNB.js">
|
|
31
31
|
<link rel="modulepreload" crossorigin href="/assets/schemas-BHS7bo06.js">
|
|
32
32
|
<link rel="modulepreload" crossorigin href="/assets/product-delivery-CV4pDOtG.js">
|
|
33
33
|
<link rel="modulepreload" crossorigin href="/assets/copy-to-clipboard-HOJ79TWv.js">
|
|
34
|
-
<link rel="modulepreload" crossorigin href="/assets/markdown-view-
|
|
34
|
+
<link rel="modulepreload" crossorigin href="/assets/markdown-view-DTF9v1gg.js">
|
|
35
35
|
<link rel="modulepreload" crossorigin href="/assets/dist-DLmwHyAh.js">
|
|
36
36
|
<link rel="modulepreload" crossorigin href="/assets/vendor-swr-BIWyz7Rc.js">
|
|
37
37
|
<link rel="modulepreload" crossorigin href="/assets/check-DUBLcKHA.js">
|
|
@@ -59,20 +59,20 @@
|
|
|
59
59
|
<link rel="modulepreload" crossorigin href="/assets/files-D6vf3S30.js">
|
|
60
60
|
<link rel="modulepreload" crossorigin href="/assets/tool-activity-R8V9l6nk.js">
|
|
61
61
|
<link rel="modulepreload" crossorigin href="/assets/button-CtTvuElV.js">
|
|
62
|
-
<link rel="modulepreload" crossorigin href="/assets/gateway-startup-retry-
|
|
63
|
-
<link rel="modulepreload" crossorigin href="/assets/registry-api-
|
|
62
|
+
<link rel="modulepreload" crossorigin href="/assets/gateway-startup-retry-CzBzglzQ.js">
|
|
63
|
+
<link rel="modulepreload" crossorigin href="/assets/registry-api-CIsNlSBi.js">
|
|
64
64
|
<link rel="modulepreload" crossorigin href="/assets/config-reload-event-Bjh2zoKp.js">
|
|
65
|
-
<link rel="modulepreload" crossorigin href="/assets/gateway-config-swr-
|
|
66
|
-
<link rel="modulepreload" crossorigin href="/assets/models-hub-cache-
|
|
65
|
+
<link rel="modulepreload" crossorigin href="/assets/gateway-config-swr-DXuXtU1w.js">
|
|
66
|
+
<link rel="modulepreload" crossorigin href="/assets/models-hub-cache-nCfkBN8M.js">
|
|
67
67
|
<link rel="modulepreload" crossorigin href="/assets/electron-env-DH5wF8X8.js">
|
|
68
|
-
<link rel="modulepreload" crossorigin href="/assets/oauth-api-
|
|
68
|
+
<link rel="modulepreload" crossorigin href="/assets/oauth-api-8lP_qJpq.js">
|
|
69
69
|
<link rel="modulepreload" crossorigin href="/assets/form-field-width-DJw_jULe.js">
|
|
70
70
|
<link rel="modulepreload" crossorigin href="/assets/interaction-BmQogeqz.js">
|
|
71
71
|
<link rel="modulepreload" crossorigin href="/assets/is-masked-secret-DOkL5b_X.js">
|
|
72
|
-
<link rel="modulepreload" crossorigin href="/assets/activity-store-
|
|
73
|
-
<link rel="modulepreload" crossorigin href="/assets/theme-store-
|
|
72
|
+
<link rel="modulepreload" crossorigin href="/assets/activity-store-etpmyV7S.js">
|
|
73
|
+
<link rel="modulepreload" crossorigin href="/assets/theme-store-O597U8q_.js">
|
|
74
74
|
<link rel="stylesheet" crossorigin href="/assets/markdown-view-Y68dCxuc.css">
|
|
75
|
-
<link rel="stylesheet" crossorigin href="/assets/index-
|
|
75
|
+
<link rel="stylesheet" crossorigin href="/assets/index-DReBaaTX.css">
|
|
76
76
|
</head>
|
|
77
77
|
<body>
|
|
78
78
|
<div id="root"></div>
|
package/dist/package.js
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import { resolveStateDir } from "../../config/paths-state.js";
|
|
2
2
|
import { resolveGlobalSingleton } from "../../utils/global-singleton.js";
|
|
3
3
|
import { init_paths } from "../../config/paths.js";
|
|
4
|
+
import { DurableState } from "../../storage/sqlite/durable-state.js";
|
|
4
5
|
import { isolatedCommand, removeCommandContainer } from "./command-isolation.js";
|
|
5
6
|
import { readWorkspaceRevision } from "../coding/workspace-revision.js";
|
|
6
7
|
import { join } from "node:path";
|
|
7
|
-
import { appendFileSync, mkdirSync,
|
|
8
|
+
import { appendFileSync, mkdirSync, rmSync, writeFileSync } from "node:fs";
|
|
8
9
|
import { spawn } from "node:child_process";
|
|
9
10
|
import { createHash, randomUUID } from "node:crypto";
|
|
10
11
|
//#region src/agent/commands/command-registry.ts
|
|
@@ -46,9 +47,10 @@ var CommandRegistry = class {
|
|
|
46
47
|
return join(this.root, createHash("sha256").update(owner).digest("hex"));
|
|
47
48
|
}
|
|
48
49
|
persist(owner, result) {
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
50
|
+
this.receipts(owner).set(result.id, result);
|
|
51
|
+
}
|
|
52
|
+
receipts(owner) {
|
|
53
|
+
return new DurableState("command-receipts", owner);
|
|
52
54
|
}
|
|
53
55
|
async start(input) {
|
|
54
56
|
input.signal?.throwIfAborted();
|
|
@@ -174,16 +176,15 @@ var CommandRegistry = class {
|
|
|
174
176
|
...current.result,
|
|
175
177
|
durationMs: Date.now() - current.result.createdAtMs
|
|
176
178
|
} : void 0;
|
|
177
|
-
|
|
178
|
-
const result =
|
|
179
|
+
{
|
|
180
|
+
const result = this.receipts(owner).get(id);
|
|
181
|
+
if (!result) return void 0;
|
|
179
182
|
if (result.status === "running") {
|
|
180
183
|
result.status = "interrupted";
|
|
181
184
|
result.stderr += "\nRuntime ownership was lost. Process/container state is unknown; inspect before restarting.";
|
|
182
185
|
this.persist(owner, result);
|
|
183
186
|
}
|
|
184
187
|
return result;
|
|
185
|
-
} catch {
|
|
186
|
-
return;
|
|
187
188
|
}
|
|
188
189
|
}
|
|
189
190
|
async wait(owner, id, waitMs = 3e4, signal) {
|
|
@@ -225,27 +226,16 @@ var CommandRegistry = class {
|
|
|
225
226
|
if (Date.now() - (this.prunedAt.get(owner) ?? 0) < 6e4) return;
|
|
226
227
|
this.prunedAt.set(owner, Date.now());
|
|
227
228
|
const directory = this.directory(owner);
|
|
228
|
-
const completed =
|
|
229
|
-
try {
|
|
230
|
-
const job = JSON.parse(readFileSync(join(directory, file), "utf8"));
|
|
231
|
-
return this.running.has(job.id) || job.status === "running" ? [] : [job];
|
|
232
|
-
} catch {
|
|
233
|
-
return [];
|
|
234
|
-
}
|
|
235
|
-
}).sort((a, b) => b.createdAtMs - a.createdAtMs);
|
|
229
|
+
const completed = this.receipts(owner).values().filter((job) => !this.running.has(job.id) && job.status !== "running").sort((a, b) => b.createdAtMs - a.createdAtMs);
|
|
236
230
|
for (const [index, job] of completed.entries()) {
|
|
237
231
|
if (index < 500 && Date.now() - job.createdAtMs < 10080 * 6e4) continue;
|
|
238
232
|
if (!/^[\da-f-]{36}$/.test(job.id)) continue;
|
|
239
|
-
|
|
233
|
+
this.receipts(owner).delete(job.id);
|
|
240
234
|
rmSync(join(directory, `${job.id}.log`), { force: true });
|
|
241
235
|
}
|
|
242
236
|
}
|
|
243
237
|
list(owner) {
|
|
244
|
-
|
|
245
|
-
return readdirSync(this.directory(owner)).filter((file) => file.endsWith(".json")).map((file) => this.get(owner, file.slice(0, -5))).filter((job) => !!job).sort((a, b) => b.createdAtMs - a.createdAtMs).slice(0, 50);
|
|
246
|
-
} catch {
|
|
247
|
-
return [];
|
|
248
|
-
}
|
|
238
|
+
return this.receipts(owner).entries().map(([id]) => this.get(owner, id)).filter((job) => !!job).sort((a, b) => b.createdAtMs - a.createdAtMs).slice(0, 50);
|
|
249
239
|
}
|
|
250
240
|
};
|
|
251
241
|
function commandRegistry() {
|
|
@@ -1,41 +1,18 @@
|
|
|
1
1
|
import type { Config } from '../../config/schema.js';
|
|
2
2
|
import type { AgentIPCMessage } from './types.js';
|
|
3
|
+
/** SQLite queue with acknowledgement after processing and renewable claims. */
|
|
3
4
|
export declare class AgentInbox {
|
|
4
|
-
private readonly
|
|
5
|
-
private
|
|
6
|
-
private
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
*/
|
|
11
|
-
static forAgent(config: Config, agentId: string): AgentInbox;
|
|
12
|
-
/**
|
|
13
|
-
* Enqueue a message
|
|
14
|
-
*/
|
|
5
|
+
private readonly queue;
|
|
6
|
+
private timer?;
|
|
7
|
+
private processing;
|
|
8
|
+
private stopped;
|
|
9
|
+
constructor(agentId: string);
|
|
10
|
+
static forAgent(_config: Config, agentId: string): AgentInbox;
|
|
15
11
|
enqueue(message: AgentIPCMessage): Promise<void>;
|
|
16
|
-
/**
|
|
17
|
-
* Dequeue the oldest pending message
|
|
18
|
-
*/
|
|
19
|
-
dequeue(): Promise<AgentIPCMessage | null>;
|
|
20
|
-
/**
|
|
21
|
-
* Peek at pending messages without removing them
|
|
22
|
-
*/
|
|
23
12
|
peek(limit?: number): Promise<AgentIPCMessage[]>;
|
|
24
|
-
/**
|
|
25
|
-
* Count pending messages
|
|
26
|
-
*/
|
|
27
13
|
count(): Promise<number>;
|
|
28
|
-
|
|
29
|
-
* Watch for new messages
|
|
30
|
-
*/
|
|
14
|
+
clearProcessed(olderThanMs?: number): Promise<number>;
|
|
31
15
|
watch(handler: (msg: AgentIPCMessage) => Promise<void>): Promise<() => void>;
|
|
32
|
-
/**
|
|
33
|
-
* Stop watching
|
|
34
|
-
*/
|
|
35
16
|
stopWatching(): void;
|
|
36
|
-
/**
|
|
37
|
-
* Clear all processed messages
|
|
38
|
-
*/
|
|
39
|
-
clearProcessed(olderThanMs?: number): Promise<number>;
|
|
40
17
|
private processPending;
|
|
41
18
|
}
|
|
@@ -1,158 +1,89 @@
|
|
|
1
1
|
import { createLogger } from "../../utils/logger/index.js";
|
|
2
2
|
import { init_logger } from "../../utils/logger.js";
|
|
3
|
-
import {
|
|
4
|
-
import { init_write_file_atomic, writeTextAtomic } from "../../infra/write-file-atomic.js";
|
|
5
|
-
import { join } from "path";
|
|
6
|
-
import { existsSync, watch } from "fs";
|
|
7
|
-
import { mkdir, readFile, readdir, rename } from "fs/promises";
|
|
3
|
+
import { DurableQueue } from "../../storage/sqlite/durable-queue.js";
|
|
8
4
|
//#region src/agent/ipc/inbox.ts
|
|
9
|
-
init_write_file_atomic();
|
|
10
5
|
init_logger();
|
|
11
|
-
init_paths();
|
|
12
6
|
const log = createLogger("AgentInbox");
|
|
7
|
+
const LEASE_MS = 3e4;
|
|
8
|
+
/** SQLite queue with acknowledgement after processing and renewable claims. */
|
|
13
9
|
var AgentInbox = class AgentInbox {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
this.
|
|
10
|
+
queue;
|
|
11
|
+
timer;
|
|
12
|
+
processing = false;
|
|
13
|
+
stopped = true;
|
|
14
|
+
constructor(agentId) {
|
|
15
|
+
this.queue = new DurableQueue("agent-ipc", agentId);
|
|
20
16
|
}
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
*/
|
|
24
|
-
static forAgent(config, agentId) {
|
|
25
|
-
return new AgentInbox(resolveAgentDir(config, agentId));
|
|
17
|
+
static forAgent(_config, agentId) {
|
|
18
|
+
return new AgentInbox(agentId);
|
|
26
19
|
}
|
|
27
|
-
/**
|
|
28
|
-
* Enqueue a message
|
|
29
|
-
*/
|
|
30
20
|
async enqueue(message) {
|
|
31
|
-
|
|
32
|
-
await writeTextAtomic(join(this.pendingDir, `${message.id}.json`), JSON.stringify(message, null, 2));
|
|
33
|
-
log.debug({
|
|
34
|
-
messageId: message.id,
|
|
35
|
-
to: message.to
|
|
36
|
-
}, "Enqueued message");
|
|
21
|
+
this.queue.enqueue(message.id, message);
|
|
37
22
|
}
|
|
38
|
-
/**
|
|
39
|
-
* Dequeue the oldest pending message
|
|
40
|
-
*/
|
|
41
|
-
async dequeue() {
|
|
42
|
-
await mkdir(this.pendingDir, { recursive: true });
|
|
43
|
-
await mkdir(this.processedDir, { recursive: true });
|
|
44
|
-
const files = await readdir(this.pendingDir).catch(() => []);
|
|
45
|
-
if (files.length === 0) return null;
|
|
46
|
-
const sorted = files.filter((f) => f.endsWith(".json")).sort();
|
|
47
|
-
if (sorted.length === 0) return null;
|
|
48
|
-
const fileName = sorted[0];
|
|
49
|
-
const filePath = join(this.pendingDir, fileName);
|
|
50
|
-
try {
|
|
51
|
-
const content = await readFile(filePath, "utf-8");
|
|
52
|
-
const message = JSON.parse(content);
|
|
53
|
-
await rename(filePath, join(this.processedDir, fileName));
|
|
54
|
-
log.debug({
|
|
55
|
-
messageId: message.id,
|
|
56
|
-
from: message.from
|
|
57
|
-
}, "Dequeued message");
|
|
58
|
-
return message;
|
|
59
|
-
} catch (error) {
|
|
60
|
-
log.warn({
|
|
61
|
-
fileName,
|
|
62
|
-
error
|
|
63
|
-
}, "Failed to dequeue message");
|
|
64
|
-
return null;
|
|
65
|
-
}
|
|
66
|
-
}
|
|
67
|
-
/**
|
|
68
|
-
* Peek at pending messages without removing them
|
|
69
|
-
*/
|
|
70
23
|
async peek(limit = 10) {
|
|
71
|
-
|
|
72
|
-
const jsonFiles = (await readdir(this.pendingDir).catch(() => [])).filter((f) => f.endsWith(".json")).sort();
|
|
73
|
-
const messages = [];
|
|
74
|
-
for (const fileName of jsonFiles.slice(0, limit)) try {
|
|
75
|
-
const content = await readFile(join(this.pendingDir, fileName), "utf-8");
|
|
76
|
-
const message = JSON.parse(content);
|
|
77
|
-
messages.push(message);
|
|
78
|
-
} catch (error) {
|
|
79
|
-
log.warn({
|
|
80
|
-
fileName,
|
|
81
|
-
error
|
|
82
|
-
}, "Failed to read message");
|
|
83
|
-
}
|
|
84
|
-
return messages;
|
|
24
|
+
return this.queue.pending(limit);
|
|
85
25
|
}
|
|
86
|
-
/**
|
|
87
|
-
* Count pending messages
|
|
88
|
-
*/
|
|
89
26
|
async count() {
|
|
90
|
-
|
|
91
|
-
|
|
27
|
+
return this.queue.pending().length;
|
|
28
|
+
}
|
|
29
|
+
async clearProcessed(olderThanMs) {
|
|
30
|
+
return this.queue.clearProcessed(olderThanMs);
|
|
92
31
|
}
|
|
93
|
-
/**
|
|
94
|
-
* Watch for new messages
|
|
95
|
-
*/
|
|
96
32
|
async watch(handler) {
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
33
|
+
this.stopWatching();
|
|
34
|
+
this.stopped = false;
|
|
35
|
+
const poll = () => this.processPending(handler).catch((err) => {
|
|
36
|
+
log.error({ err }, "IPC queue processing failed");
|
|
101
37
|
});
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
this.
|
|
105
|
-
|
|
38
|
+
await poll();
|
|
39
|
+
if (!this.stopped) {
|
|
40
|
+
this.timer = setInterval(() => {
|
|
41
|
+
poll();
|
|
42
|
+
}, 250);
|
|
43
|
+
this.timer.unref();
|
|
44
|
+
}
|
|
45
|
+
return () => this.stopWatching();
|
|
106
46
|
}
|
|
107
|
-
/**
|
|
108
|
-
* Stop watching
|
|
109
|
-
*/
|
|
110
47
|
stopWatching() {
|
|
111
|
-
this.
|
|
112
|
-
this.
|
|
48
|
+
this.stopped = true;
|
|
49
|
+
clearInterval(this.timer);
|
|
50
|
+
this.timer = void 0;
|
|
113
51
|
}
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
cleared++;
|
|
52
|
+
async processPending(handler) {
|
|
53
|
+
if (this.processing || this.stopped) return;
|
|
54
|
+
this.processing = true;
|
|
55
|
+
try {
|
|
56
|
+
while (!this.stopped) {
|
|
57
|
+
const claim = this.queue.claim(LEASE_MS);
|
|
58
|
+
if (!claim) break;
|
|
59
|
+
const renewal = setInterval(() => {
|
|
60
|
+
try {
|
|
61
|
+
this.queue.renew(claim.id, claim.token, LEASE_MS);
|
|
62
|
+
} catch (err) {
|
|
63
|
+
log.error({
|
|
64
|
+
err,
|
|
65
|
+
messageId: claim.id
|
|
66
|
+
}, "IPC lease renewal failed");
|
|
130
67
|
}
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
|
|
68
|
+
}, LEASE_MS / 3);
|
|
69
|
+
renewal.unref();
|
|
70
|
+
let succeeded = false;
|
|
71
|
+
try {
|
|
72
|
+
await handler(claim.payload);
|
|
73
|
+
succeeded = true;
|
|
74
|
+
} catch (err) {
|
|
75
|
+
log.error({
|
|
76
|
+
err,
|
|
77
|
+
messageId: claim.id
|
|
78
|
+
}, "IPC handler failed; message remains pending");
|
|
79
|
+
} finally {
|
|
80
|
+
clearInterval(renewal);
|
|
81
|
+
this.queue.finish(claim.id, claim.token, succeeded);
|
|
134
82
|
}
|
|
135
|
-
|
|
136
|
-
log.warn({
|
|
137
|
-
fileName,
|
|
138
|
-
error
|
|
139
|
-
}, "Failed to clear processed message");
|
|
140
|
-
}
|
|
141
|
-
}
|
|
142
|
-
return cleared;
|
|
143
|
-
}
|
|
144
|
-
async processPending(handler) {
|
|
145
|
-
while (true) {
|
|
146
|
-
const msg = await this.dequeue();
|
|
147
|
-
if (!msg) break;
|
|
148
|
-
try {
|
|
149
|
-
await handler(msg);
|
|
150
|
-
} catch (error) {
|
|
151
|
-
log.error({
|
|
152
|
-
messageId: msg.id,
|
|
153
|
-
error
|
|
154
|
-
}, "Error processing message");
|
|
83
|
+
if (!succeeded) break;
|
|
155
84
|
}
|
|
85
|
+
} finally {
|
|
86
|
+
this.processing = false;
|
|
156
87
|
}
|
|
157
88
|
}
|
|
158
89
|
};
|
|
@@ -31,15 +31,19 @@ async function runProcessDirect(deps, input) {
|
|
|
31
31
|
}, turnBody, { skipResetCommands: resetTriggeredAtInit });
|
|
32
32
|
if (slash.matched) {
|
|
33
33
|
const trimmed = slash.aggregatedText.trim();
|
|
34
|
-
if (trimmed)
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
34
|
+
if (trimmed) {
|
|
35
|
+
await deps.sessionStore.appendTranscriptMessage(input.sessionKey, {
|
|
36
|
+
role: "assistant",
|
|
37
|
+
content: isReviewOutput(slash.metadata?.review) ? [slash.metadata.review] : [{
|
|
38
|
+
type: "text",
|
|
39
|
+
text: trimmed
|
|
40
|
+
}],
|
|
41
|
+
timestamp: Date.now(),
|
|
42
|
+
...slash.metadata && Object.keys(slash.metadata).length > 0 ? { metadata: slash.metadata } : {}
|
|
43
|
+
});
|
|
44
|
+
if (input.origin.type === "system" && input.origin.source === "automation") await deps.sessionStore.updateMetadata(input.sessionKey, { hiddenFromSessionList: false });
|
|
45
|
+
deps.onTurnComplete?.(input.sessionKey, trimmed);
|
|
46
|
+
}
|
|
43
47
|
return slash.aggregatedText ?? "";
|
|
44
48
|
}
|
|
45
49
|
const skillTurn = deps.agentManager.prepareSkillTurn(input.sessionKey, turnBody);
|
|
@@ -70,7 +74,8 @@ async function runProcessDirect(deps, input) {
|
|
|
70
74
|
clearPendingTranscriptUserMessage(input.sessionKey, pendingUserMessage);
|
|
71
75
|
}
|
|
72
76
|
})();
|
|
73
|
-
|
|
77
|
+
deps.onTurnComplete?.(input.sessionKey, result.lastAssistantText);
|
|
78
|
+
if (!result.ok) throw new Error(result.errorMessage ?? "Agent turn failed");
|
|
74
79
|
return result.lastAssistantText ?? "";
|
|
75
80
|
} finally {
|
|
76
81
|
deps.endDirectRequestContext();
|
|
@@ -3,7 +3,6 @@ export type WorkflowSource = 'user' | 'builtin';
|
|
|
3
3
|
export interface CatalogEntry {
|
|
4
4
|
name: string;
|
|
5
5
|
source: WorkflowSource;
|
|
6
|
-
path: string | null;
|
|
7
6
|
description: string;
|
|
8
7
|
title: string;
|
|
9
8
|
version: string;
|
|
@@ -32,21 +31,16 @@ export interface WorkflowCatalog {
|
|
|
32
31
|
list(): CatalogEntry[];
|
|
33
32
|
load(name: string): WorkflowDefinition;
|
|
34
33
|
save(input: SaveWorkflowInput): {
|
|
35
|
-
path: string;
|
|
36
34
|
definition: WorkflowDefinition;
|
|
37
35
|
};
|
|
38
36
|
listRevisions(name: string): WorkflowRevisionSummary[];
|
|
39
37
|
loadRevision(name: string, revision: number): WorkflowDefinition;
|
|
40
38
|
restore(name: string, revision: number, expectedRevision: number): {
|
|
41
|
-
path: string;
|
|
42
39
|
definition: WorkflowDefinition;
|
|
43
40
|
};
|
|
44
41
|
remove(name: string): boolean;
|
|
45
|
-
userDir: string;
|
|
46
42
|
}
|
|
47
|
-
export declare function createWorkflowCatalog(
|
|
48
|
-
userDir?: string;
|
|
49
|
-
}): WorkflowCatalog;
|
|
43
|
+
export declare function createWorkflowCatalog(): WorkflowCatalog;
|
|
50
44
|
export declare class WorkflowRevisionConflictError extends Error {
|
|
51
45
|
readonly currentRevision: number;
|
|
52
46
|
constructor(currentRevision: number);
|
|
@@ -56,4 +50,3 @@ export declare class WorkflowNameConflictError extends Error {
|
|
|
56
50
|
readonly currentRevision: number;
|
|
57
51
|
constructor(workflowName: string, currentRevision: number);
|
|
58
52
|
}
|
|
59
|
-
export declare function defaultUserDir(): string;
|