@xopcai/xopc 0.0.178 → 0.0.180
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/static/root/assets/{activity-store-BzGX__8I.js → activity-store-DFKtQDgE.js} +1 -1
- package/dist/gateway/static/root/assets/{agent-avatar-dicebear-BzxntcaZ.js → agent-avatar-dicebear-CcTvB_4W.js} +1 -1
- package/dist/gateway/static/root/assets/agents-DgGj9bu6.js +2 -0
- package/dist/gateway/static/root/assets/{api-hi6f2Xtp.js → api-CUClAvuL.js} +1 -1
- package/dist/gateway/static/root/assets/{app-management-settings-panel-fTY1F7ac.js → app-management-settings-panel-Ib-cWKHM.js} +1 -1
- package/dist/gateway/static/root/assets/{appearance-settings-BZ-IxQfB.js → appearance-settings-CRSN8WuA.js} +1 -1
- package/dist/gateway/static/root/assets/apps-page-B5xahuT-.js +1 -0
- package/dist/gateway/static/root/assets/{archive-plugin-ZSLLG8wB.js → archive-plugin-BBF9zspN.js} +1 -1
- package/dist/gateway/static/root/assets/{attachment-load-D4YktqIF.js → attachment-load-D3QQfA7w.js} +1 -1
- package/dist/gateway/static/root/assets/automations-page-BUYrvMmD.js +6 -0
- package/dist/gateway/static/root/assets/{binary-plugins-BIkPxfxj.js → binary-plugins-D78XOjJ3.js} +1 -1
- package/dist/gateway/static/root/assets/{block-editor-Q3v_YQom.js → block-editor-D_VVXlYX.js} +46 -46
- package/dist/gateway/static/root/assets/browser-settings-page-Cjw07q9h.js +8 -0
- package/dist/gateway/static/root/assets/{browser-workflow-inputs-M5lTEW1I.js → browser-workflow-inputs-_gu08MA4.js} +1 -1
- package/dist/gateway/static/root/assets/{browser-workflows-page-B3T1KYk4.js → browser-workflows-page-58DBMXgG.js} +2 -2
- package/dist/gateway/static/root/assets/capabilities-settings-panel-D_dfVxHY.js +7 -0
- package/dist/gateway/static/root/assets/{capability-presets-api-DE09c0VB.js → capability-presets-api-DhCn9rPv.js} +1 -1
- package/dist/gateway/static/root/assets/capability-presets-settings-panel-LWWIYUT7.js +1 -0
- package/dist/gateway/static/root/assets/{channel-recipient-api-CFR5FBfS.js → channel-recipient-api-DYtoNV5A.js} +1 -1
- package/dist/gateway/static/root/assets/channels-settings-Cyj5OunL.js +1 -0
- package/dist/gateway/static/root/assets/channels-status-swr-TEFnV0IG.js +1 -0
- package/dist/gateway/static/root/assets/{connector-logo-B1mD-3pM.js → connector-logo-CxIXnifA.js} +1 -1
- package/dist/gateway/static/root/assets/connectors-page-0TobCpBB.js +2 -0
- package/dist/gateway/static/root/assets/desktop-pet-CwVSLL6N.js +1 -0
- package/dist/gateway/static/root/assets/desktop-pet-settings-BOIp4q0Z.js +1 -0
- package/dist/gateway/static/root/assets/{directory-picker-path-field-BYQJ2XUS.js → directory-picker-path-field-C8_lsW6S.js} +1 -1
- package/dist/gateway/static/root/assets/{dreaming-settings-BXcb8fwx.js → dreaming-settings-Da9FeWQl.js} +3 -3
- package/dist/gateway/static/root/assets/{extension-debug-page-O1Xu1r4Q.js → extension-debug-page-CMNnSJP6.js} +1 -1
- package/dist/gateway/static/root/assets/{extension-page-C2Jraq8l.js → extension-page-t0pJqLvM.js} +1 -1
- package/dist/gateway/static/root/assets/{extension-settings-page-DcXQDTpG.js → extension-settings-page-aiR-tKnW.js} +1 -1
- package/dist/gateway/static/root/assets/{gateway-config-api-DmPIZrvg.js → gateway-config-api-CkyQBD6r.js} +1 -1
- package/dist/gateway/static/root/assets/gateway-settings-BIZfAgfB.js +1 -0
- package/dist/gateway/static/root/assets/{gateway-startup-retry-BZEkOdPm.js → gateway-startup-retry-CSU7UvzG.js} +1 -1
- package/dist/gateway/static/root/assets/goals-settings-Dx9uTyWF.js +1 -0
- package/dist/gateway/static/root/assets/{heartbeat-settings-BtKu2NWT.js → heartbeat-settings-Cnr5ORXL.js} +1 -1
- package/dist/gateway/static/root/assets/{image-generation-api-05Gg8wsU.js → image-generation-api-BR6Kb77X.js} +1 -1
- package/dist/gateway/static/root/assets/index-B0Tdge_q.css +1 -0
- package/dist/gateway/static/root/assets/index-BA56bQ68.js +224 -0
- package/dist/gateway/static/root/assets/{keyboard-shortcuts-settings-CfmDR9Sc.js → keyboard-shortcuts-settings-D76uYKeQ.js} +1 -1
- package/dist/gateway/static/root/assets/local-app-workbench-page-DSUNtLHg.js +2 -0
- package/dist/gateway/static/root/assets/{local-apps-page-Df8BW1A_.js → local-apps-page-BsLnojTh.js} +1 -1
- package/dist/gateway/static/root/assets/{locale-store-CTwSy7yW.js → locale-store-BNC8HUCI.js} +1 -1
- package/dist/gateway/static/root/assets/logs-page-yI8kpQtO.js +7 -0
- package/dist/gateway/static/root/assets/{markdown-split-B3FvKbaP.js → markdown-split-D6smTQWD.js} +1 -1
- package/dist/gateway/static/root/assets/{media-plugins-DsjrvvB6.js → media-plugins-D1TmMF0A.js} +1 -1
- package/dist/gateway/static/root/assets/messages-H_iJjnEM.js +3 -0
- package/dist/gateway/static/root/assets/{notes-page-tuzIwy3c.js → notes-page-Vt-diFf0.js} +1 -1
- package/dist/gateway/static/root/assets/notes-workbench-BD297EZt.js +4 -0
- package/dist/gateway/static/root/assets/outcome-detail-page-C5i_ZR9a.js +1 -0
- package/dist/gateway/static/root/assets/{page-tabs-ke9s4nYi.js → page-tabs-BnSzIjH0.js} +1 -1
- package/dist/gateway/static/root/assets/{preview-open-alternatives-Cp1eI4S9.js → preview-open-alternatives-CF12Eqi4.js} +1 -1
- package/dist/gateway/static/root/assets/product-delivery-BVG-eWQO.js +1 -0
- package/dist/gateway/static/root/assets/{product-open-page-dXQCMAtH.js → product-open-page-Du0TE_CU.js} +1 -1
- package/dist/gateway/static/root/assets/project-detail-page-D1HGz7Dy.js +1 -0
- package/dist/gateway/static/root/assets/projects-page-CqP2TnW-.js +1 -0
- package/dist/gateway/static/root/assets/remote-access-hub-BXdVJLS3.js +1 -0
- package/dist/gateway/static/root/assets/{save-bar-controls-Bl30zjHc.js → save-bar-controls-B53UNtDM.js} +1 -1
- package/dist/gateway/static/root/assets/{schedule-field-DqhmXQKo.js → schedule-field-C3dIMN5q.js} +1 -1
- package/dist/gateway/static/root/assets/{schema-form-DkUCy6vf.js → schema-form-BKvpxqof.js} +1 -1
- package/dist/gateway/static/root/assets/{schemas-DgQq6Z5S.js → schemas-C6onAggk.js} +2 -2
- package/dist/gateway/static/root/assets/sessions-page-CPAwDdl5.js +1 -0
- package/dist/gateway/static/root/assets/settings-advanced-gate-C-jGsoft.js +1 -0
- package/dist/gateway/static/root/assets/{settings-form-section-C6ZbNpdy.js → settings-form-section-kt6GIS32.js} +1 -1
- package/dist/gateway/static/root/assets/{settings-loading-skeleton-Bk58_cr7.js → settings-loading-skeleton-85eUPcKz.js} +1 -1
- package/dist/gateway/static/root/assets/{settings-page-k8iE_NdX.js → settings-page-Di5x6Xrc.js} +1 -1
- package/dist/gateway/static/root/assets/{settings-page-layout-DgFSya2e.js → settings-page-layout-CkkCee_x.js} +1 -1
- package/dist/gateway/static/root/assets/{setup-status-panel-B_KDlyZA.js → setup-status-panel-uxEE6gAB.js} +1 -1
- package/dist/gateway/static/root/assets/{share-preview-page-CV7nL_J9.js → share-preview-page-BtLEstaI.js} +1 -1
- package/dist/gateway/static/root/assets/shares-settings-2mcsMWgn.js +1 -0
- package/dist/gateway/static/root/assets/skill-reload-api-ocDwsrEt.js +1 -0
- package/dist/gateway/static/root/assets/skills-page-9_jfsFU5.js +2 -0
- package/dist/gateway/static/root/assets/{skills-page.utils-kahBIHg0.js → skills-page.utils-C2SHvq8V.js} +1 -1
- package/dist/gateway/static/root/assets/{system-settings-panel-JV3-MG5F.js → system-settings-panel-CIJ66cUy.js} +1 -1
- package/dist/gateway/static/root/assets/{theme-store-DFLyzoLO.js → theme-store-ClDa_Bci.js} +1 -1
- package/dist/gateway/static/root/assets/time-picker-D0zAsHOo.js +1 -0
- package/dist/gateway/static/root/assets/{typed-models-lib-60Aqo-UJ.js → typed-models-lib-GsmwmB40.js} +1 -1
- package/dist/gateway/static/root/assets/{use-channel-catalog-CnTkHDnw.js → use-channel-catalog-BQz3K7xj.js} +1 -1
- package/dist/gateway/static/root/assets/user-context-page-Bn4BLg4W.js +1 -0
- package/dist/gateway/static/root/assets/{voice-api-key-field-CNa8qUgS.js → voice-api-key-field-Blaxsbb3.js} +1 -1
- package/dist/gateway/static/root/assets/work-copy-Cwyan9Sn.js +1 -0
- package/dist/gateway/static/root/assets/work-discovery-page-iJ9RBSpu.js +1 -0
- package/dist/gateway/static/root/assets/work-item-detail-page-CqTH7PQX.js +1 -0
- package/dist/gateway/static/root/assets/work-page-H3m99ccS.js +3 -0
- package/dist/gateway/static/root/assets/{workflow-run-setup-panel-yV_x595t.js → workflow-run-setup-panel-CTG4RpRE.js} +2 -2
- package/dist/gateway/static/root/assets/workflows-page-BxZSKMfv.js +11 -0
- package/dist/gateway/static/root/index.html +9 -10
- package/dist/package.js +1 -1
- package/dist/packages/gateway-contract/src/outcomes.js +137 -0
- package/dist/packages/gateway-contract/src/product-delivery.js +1 -0
- package/dist/packages/gateway-contract/src/work-intake.js +85 -0
- package/dist/src/activity/service.d.ts +1 -0
- package/dist/src/activity/service.js +4 -1
- package/dist/src/agent/agent-manager.d.ts +4 -1
- package/dist/src/agent/agent-manager.js +21 -7
- package/dist/src/agent/bootstrap/filter-bootstrap-files.js +1 -1
- package/dist/src/agent/code-intelligence/binary.js +1 -1
- package/dist/src/agent/context/execution-scope.d.ts +1 -1
- package/dist/src/agent/context/execution-scope.js +6 -4
- package/dist/src/agent/embedded/model-runtime.js +1 -1
- package/dist/src/agent/embedded/run-for-session.d.ts +2 -0
- package/dist/src/agent/embedded/run-for-session.js +3 -1
- package/dist/src/agent/goals/post-turn.js +7 -6
- package/dist/src/agent/image/tool-model-config.js +1 -1
- package/dist/src/agent/inbound/turn-dispatcher.d.ts +6 -1
- package/dist/src/agent/inbound/turn-dispatcher.js +5 -2
- package/dist/src/agent/ipc/inbox.js +1 -1
- package/dist/src/agent/lifecycle/timeout-wrapper.d.ts +2 -0
- package/dist/src/agent/lifecycle/timeout-wrapper.js +39 -9
- package/dist/src/agent/mcp/bundle-mcp-materialize.js +2 -2
- package/dist/src/agent/mcp/bundle-mcp-runtime.js +6 -1
- package/dist/src/agent/mcp/bundle-mcp-types.d.ts +1 -1
- package/dist/src/agent/mcp/mcp-stdio-transport.js +1 -1
- package/dist/src/agent/mcp/mcp-transport-config.d.ts +2 -0
- package/dist/src/agent/mcp/mcp-transport-config.js +10 -3
- package/dist/src/agent/mcp/mcp-transport.d.ts +1 -0
- package/dist/src/agent/mcp/mcp-transport.js +5 -2
- package/dist/src/agent/memory/dreaming/config.js +1 -1
- package/dist/src/agent/memory/user-context-coordinator.d.ts +1 -0
- package/dist/src/agent/memory/user-context-coordinator.js +17 -1
- package/dist/src/agent/orchestration/run-agent-turn-with-timeout.d.ts +1 -1
- package/dist/src/agent/orchestration/run-agent-turn-with-timeout.js +6 -2
- package/dist/src/agent/outcomes/{task-evaluation.d.ts → execution-evaluation.d.ts} +3 -3
- package/dist/src/agent/outcomes/{task-evaluation.js → execution-evaluation.js} +5 -5
- package/dist/src/agent/outcomes/execution-verifier.d.ts +29 -0
- package/dist/src/agent/outcomes/{task-verifier.js → execution-verifier.js} +4 -4
- package/dist/src/agent/service/direct-turn-helpers.d.ts +1 -0
- package/dist/src/agent/service/direct-turn-helpers.js +1 -0
- package/dist/src/agent/service/process-direct-one-shot.d.ts +3 -0
- package/dist/src/agent/service/process-direct-one-shot.js +4 -1
- package/dist/src/agent/service/process-direct-streaming.js +3 -1
- package/dist/src/agent/service.d.ts +1 -0
- package/dist/src/agent/service.js +5 -2
- package/dist/src/agent/session/session-inspector.js +1 -1
- package/dist/src/agent/skills/config.js +6 -0
- package/dist/src/agent/skills/filesystem-watcher.d.ts +4 -0
- package/dist/src/agent/skills/filesystem-watcher.js +16 -7
- package/dist/src/agent/skills/hub-lock.js +1 -1
- package/dist/src/agent/skills/index.d.ts +10 -7
- package/dist/src/agent/skills/index.js +56 -47
- package/dist/src/agent/skills/skill-manage-ops.js +1 -1
- package/dist/src/agent/skills/skill-manager.d.ts +5 -2
- package/dist/src/agent/skills/skill-manager.js +10 -5
- package/dist/src/agent/skills/skill-sources.d.ts +18 -0
- package/dist/src/agent/skills/skill-sources.js +143 -0
- package/dist/src/agent/skills/types.d.ts +25 -2
- package/dist/src/agent/tools/delegate-tool.js +2 -1
- package/dist/src/agent/tools/executor.d.ts +2 -0
- package/dist/src/agent/tools/executor.js +18 -11
- package/dist/src/agent/tools/factory.js +18 -1
- package/dist/src/agent/tools/goal-tool.js +5 -3
- package/dist/src/agent/tools/index.d.ts +1 -0
- package/dist/src/agent/tools/index.js +2 -1
- package/dist/src/agent/tools/managed-job-tool.d.ts +2 -0
- package/dist/src/agent/tools/managed-job-tool.js +160 -0
- package/dist/src/agent/tools/todo-tool.d.ts +5 -0
- package/dist/src/agent/tools/todo-tool.js +16 -4
- package/dist/src/agent/tools/update-plan-tool.d.ts +1 -0
- package/dist/src/agent/tools/update-plan-tool.js +6 -0
- package/dist/src/agent/workspace-runtime/registry.d.ts +3 -0
- package/dist/src/agent/workspace-runtime/registry.js +3 -1
- package/dist/src/agent-runtime/index.js +1 -1
- package/dist/src/agent-runtime/runtime-profile.js +1 -1
- package/dist/src/auth/credentials.d.ts +9 -1
- package/dist/src/auth/credentials.js +112 -56
- package/dist/src/auth/model-credential-store.js +7 -22
- package/dist/src/auth/oauth-provider-lock.d.ts +5 -0
- package/dist/src/auth/oauth-provider-lock.js +91 -0
- package/dist/src/auth/profiles/store.js +1 -1
- package/dist/src/auth/sync-provider-auth.js +2 -2
- package/dist/src/automations/domain/defaults.d.ts +8 -1
- package/dist/src/automations/domain/defaults.js +9 -2
- package/dist/src/automations/domain/index.js +2 -2
- package/dist/src/automations/domain/types.d.ts +33 -7
- package/dist/src/automations/domain/validation.d.ts +8 -0
- package/dist/src/automations/domain/validation.js +2 -0
- package/dist/src/automations/draft/automation-draft-validator.d.ts +2 -1
- package/dist/src/automations/index.js +2 -2
- package/dist/src/automations/service/action-executor.d.ts +2 -2
- package/dist/src/automations/service/action-executor.js +144 -34
- package/dist/src/automations/service/automation-service.d.ts +4 -0
- package/dist/src/automations/service/automation-service.js +197 -18
- package/dist/src/automations/storage/automation-run-repository.d.ts +1 -0
- package/dist/src/automations/storage/automation-run-repository.js +37 -7
- package/dist/src/automations/storage/index.js +2 -2
- package/dist/src/browser/providers/browser-ext-install.js +1 -1
- package/dist/src/browser/providers/cloakbrowser.js +2 -2
- package/dist/src/channels/attachments/voice-stt-webchat.d.ts +0 -3
- package/dist/src/channels/attachments/voice-stt-webchat.js +1 -24
- package/dist/src/chat-commands/builtins/goal.js +5 -4
- package/dist/src/cli/commands/agents.js +1 -1
- package/dist/src/cli/commands/doctor/checks/database-schema.js +1 -1
- package/dist/src/cli/commands/doctor/checks/provider-auth.js +1 -1
- package/dist/src/cli/commands/goal.js +6 -5
- package/dist/src/cli/commands/models.js +1 -1
- package/dist/src/cli/commands/tunnel.js +3 -3
- package/dist/src/cli/utils/oauth-login.js +1 -7
- package/dist/src/config/agent-profile.js +1 -1
- package/dist/src/config/index.js +4 -4
- package/dist/src/config/loader.js +1 -1
- package/dist/src/config/models-json.js +1 -1
- package/dist/src/config/schema.d.ts +3 -0
- package/dist/src/config/schema.js +2 -1
- package/dist/src/connectors/learning-coordinator.js +7 -1
- package/dist/src/connectors/source-change-publisher.d.ts +17 -0
- package/dist/src/connectors/source-change-publisher.js +148 -0
- package/dist/src/discussions/analyzer.d.ts +35 -0
- package/dist/src/discussions/analyzer.js +127 -0
- package/dist/src/discussions/index.d.ts +7 -0
- package/dist/src/discussions/index.js +7 -0
- package/dist/src/discussions/live-worker.d.ts +33 -0
- package/dist/src/discussions/live-worker.js +148 -0
- package/dist/src/discussions/pipeline.d.ts +33 -0
- package/dist/src/discussions/pipeline.js +205 -0
- package/dist/src/discussions/project-inference.d.ts +13 -0
- package/dist/src/discussions/project-inference.js +19 -0
- package/dist/src/discussions/repository.d.ts +29 -0
- package/dist/src/discussions/repository.js +255 -0
- package/dist/src/discussions/service.d.ts +51 -0
- package/dist/src/discussions/service.js +335 -0
- package/dist/src/discussions/transcript.d.ts +3 -0
- package/dist/src/discussions/transcript.js +15 -0
- package/dist/src/discussions/types.d.ts +116 -0
- package/dist/src/discussions/types.js +10 -0
- package/dist/src/discussions/worker.d.ts +18 -0
- package/dist/src/discussions/worker.js +74 -0
- package/dist/src/extensions/activation-context.js +2 -1
- package/dist/src/extensions/lockfile.js +1 -1
- package/dist/src/extensions/sdk/testing.js +1 -1
- package/dist/src/gateway/agents-admin.js +3 -3
- package/dist/src/gateway/chat-stream/mapper.js +53 -3
- package/dist/src/gateway/chat-stream/protocol.d.ts +17 -1
- package/dist/src/gateway/file-path-classifier.js +1 -1
- package/dist/src/gateway/hono/app.js +8 -3
- package/dist/src/gateway/hono/lib/config-payload.js +2 -2
- package/dist/src/gateway/hono/middleware/auth.js +2 -2
- package/dist/src/gateway/hono/middleware/logger.js +1 -1
- package/dist/src/gateway/hono/middleware/strict-rate-limit.js +1 -1
- package/dist/src/gateway/hono/oauth-async.js +1 -7
- package/dist/src/gateway/hono/oauth.js +1 -7
- package/dist/src/gateway/hono/routes/agents.js +1 -1
- package/dist/src/gateway/hono/routes/config-patch/misc.js +2 -2
- package/dist/src/gateway/hono/routes/connectors.js +79 -0
- package/dist/src/gateway/hono/routes/discussions.d.ts +3 -0
- package/dist/src/gateway/hono/routes/discussions.js +177 -0
- package/dist/src/gateway/hono/routes/execution-receipts.d.ts +3 -0
- package/dist/src/gateway/hono/routes/execution-receipts.js +163 -0
- package/dist/src/gateway/hono/routes/exposure.js +1 -1
- package/dist/src/gateway/hono/routes/goals.js +3 -288
- package/dist/src/gateway/hono/routes/home.d.ts +2 -102
- package/dist/src/gateway/hono/routes/home.js +8 -424
- package/dist/src/gateway/hono/routes/index.js +6 -2
- package/dist/src/gateway/hono/routes/memory.js +7 -7
- package/dist/src/gateway/hono/routes/models.js +1 -1
- package/dist/src/gateway/hono/routes/notes.js +30 -0
- package/dist/src/gateway/hono/routes/projects.js +8 -152
- package/dist/src/gateway/hono/routes/shares.js +1 -1
- package/dist/src/gateway/hono/routes/status.js +2 -2
- package/dist/src/gateway/hono/routes/tunnel.js +3 -3
- package/dist/src/gateway/hono/routes/voice.js +1 -1
- package/dist/src/gateway/hono/routes/work.d.ts +3 -0
- package/dist/src/gateway/hono/routes/work.js +207 -0
- package/dist/src/gateway/hono/routes/you.js +13 -15
- package/dist/src/gateway/index.js +2 -2
- package/dist/src/gateway/runtime-config.js +2 -2
- package/dist/src/gateway/security/audit.js +2 -2
- package/dist/src/gateway/security/index.js +1 -1
- package/dist/src/gateway/service/config-coordinator.js +2 -2
- package/dist/src/gateway/service/run-gateway-agent.js +46 -51
- package/dist/src/gateway/service.d.ts +8 -1
- package/dist/src/gateway/service.js +142 -15
- package/dist/src/goals/goal-queue-store.d.ts +1 -0
- package/dist/src/goals/goal-queue-store.js +5 -1
- package/dist/src/goals/goal-queue-types.d.ts +11 -1
- package/dist/src/goals/goal-runner.js +10 -6
- package/dist/src/goals/goal-service.d.ts +2 -15
- package/dist/src/goals/goal-service.js +9 -42
- package/dist/src/goals/goal-store.d.ts +1 -18
- package/dist/src/goals/goal-store.js +25 -231
- package/dist/src/goals/goal-workflow-judge.js +1 -1
- package/dist/src/goals/index.d.ts +0 -4
- package/dist/src/goals/index.js +1 -3
- package/dist/src/goals/types.d.ts +4 -66
- package/dist/src/notes/agent-context.js +1 -1
- package/dist/src/notes/service.d.ts +1 -0
- package/dist/src/notes/service.js +10 -1
- package/dist/src/notes/types.d.ts +1 -0
- package/dist/src/proactive/events/product-event-bridge.d.ts +7 -0
- package/dist/src/proactive/events/product-event-bridge.js +84 -0
- package/dist/src/proactive/execution/context.d.ts +27 -11
- package/dist/src/proactive/execution/context.js +259 -25
- package/dist/src/proactive/execution/repository.js +18 -5
- package/dist/src/proactive/execution/types.d.ts +7 -1
- package/dist/src/proactive/execution/worker.js +7 -6
- package/dist/src/proactive/inbox/repository.js +8 -2
- package/dist/src/proactive/index.d.ts +4 -2
- package/dist/src/proactive/index.js +5 -3
- package/dist/src/proactive/temporal/worker.d.ts +16 -0
- package/dist/src/proactive/temporal/worker.js +110 -0
- package/dist/src/projects/project-loop.js +3 -3
- package/dist/src/providers/auth-runtime/oauth.js +12 -0
- package/dist/src/providers/auth-runtime/resolve-auth.js +1 -1
- package/dist/src/providers/index.js +2 -2
- package/dist/src/providers/model-registry.js +1 -1
- package/dist/src/providers/register-runtime-providers.js +1 -1
- package/dist/src/share/share-zip.js +1 -1
- package/dist/src/share/site-proxy.js +1 -1
- package/dist/src/storage/sqlite/activity-repository.d.ts +1 -0
- package/dist/src/storage/sqlite/activity-repository.js +4 -1
- package/dist/src/storage/sqlite/connector-sync-policy-repository.d.ts +20 -0
- package/dist/src/storage/sqlite/connector-sync-policy-repository.js +50 -0
- package/dist/src/storage/sqlite/execution-receipt-repository.d.ts +146 -0
- package/dist/src/storage/sqlite/execution-receipt-repository.js +235 -0
- package/dist/src/storage/sqlite/index.d.ts +4 -2
- package/dist/src/storage/sqlite/index.js +6 -4
- package/dist/src/storage/sqlite/knowledge-repository.d.ts +3 -0
- package/dist/src/storage/sqlite/knowledge-repository.js +9 -1
- package/dist/src/storage/sqlite/memory-records-repository.js +1 -1
- package/dist/src/storage/sqlite/migrations/075_connector_sync_policies.sql +13 -0
- package/dist/src/storage/sqlite/migrations/076_meeting_preparation_scenario.sql +29 -0
- package/dist/src/storage/sqlite/migrations/077_proactive_insight_fingerprints.sql +4 -0
- package/dist/src/storage/sqlite/migrations/078_discussion_captures.sql +64 -0
- package/dist/src/storage/sqlite/migrations/079_discussion_follow_up_scenario.sql +29 -0
- package/dist/src/storage/sqlite/migrations/080_task_outcome_context.sql +15 -0
- package/dist/src/storage/sqlite/migrations/081_project_monitoring_policies.sql +10 -0
- package/dist/src/storage/sqlite/migrations/082_one_click_live_discussions.sql +100 -0
- package/dist/src/storage/sqlite/migrations/083_session_task_plans.sql +9 -0
- package/dist/src/storage/sqlite/migrations/084_work_intake_lifecycle.sql +26 -0
- package/dist/src/storage/sqlite/migrations/085_task_outcome_projection.sql +19 -0
- package/dist/src/storage/sqlite/migrations/086_outcome_aggregates.sql +168 -0
- package/dist/src/storage/sqlite/migrations/087_context_snapshots.sql +21 -0
- package/dist/src/storage/sqlite/migrations/088_automation_execution_deadlines.sql +5 -0
- package/dist/src/storage/sqlite/migrations/089_automation_run_leases.sql +8 -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/notes-repository.js +9 -0
- package/dist/src/storage/sqlite/schema.js +1 -1
- package/dist/src/storage/sqlite/schema.sql +89 -44
- package/dist/src/storage/sqlite/session-repository.js +1 -1
- package/dist/src/storage/sqlite/session-task-plan-repository.d.ts +20 -0
- package/dist/src/storage/sqlite/session-task-plan-repository.js +77 -0
- package/dist/src/tui/backends/embedded-backend.d.ts +2 -0
- package/dist/src/tui/backends/embedded-backend.js +12 -8
- package/dist/src/tui/tui-backend.d.ts +2 -0
- package/dist/src/tui/tui-oauth-login.js +1 -7
- package/dist/src/tui/tui-picker-overlay.js +1 -0
- package/dist/src/tui/tui-picker-services.d.ts +1 -0
- package/dist/src/tui/tui-skills-autocomplete.d.ts +6 -2
- package/dist/src/tui/tui-skills-autocomplete.js +10 -6
- package/dist/src/tui/tui-startup-resources.d.ts +3 -1
- package/dist/src/tui/tui-startup-resources.js +4 -3
- package/dist/src/tui/tui.js +4 -1
- package/dist/src/tunnel/frpc-binary.js +1 -1
- package/dist/src/tunnel/frpc-extract.js +1 -1
- package/dist/src/tunnel/index.js +2 -2
- package/dist/src/user-context/context-compiler.d.ts +31 -0
- package/dist/src/user-context/context-compiler.js +51 -0
- package/dist/src/voice/local/model-files.js +1 -1
- package/dist/src/voice/stt/config.d.ts +4 -0
- package/dist/src/voice/stt/config.js +26 -0
- package/dist/src/voice/stt/index.d.ts +1 -0
- package/dist/src/voice/stt/index.js +2 -1
- package/dist/src/voice/stt/list-providers.js +1 -1
- package/dist/src/work/attention-governor.d.ts +20 -0
- package/dist/src/work/attention-governor.js +46 -0
- package/dist/src/work/execution-context.d.ts +16 -0
- package/dist/src/work/execution-context.js +66 -0
- package/dist/src/work/home-query-service.d.ts +147 -0
- package/dist/src/work/home-query-service.js +389 -0
- package/dist/src/work/index.d.ts +14 -0
- package/dist/src/work/index.js +15 -0
- package/dist/src/work/outcome-contract-definition.d.ts +8 -0
- package/dist/src/work/outcome-contract-definition.js +15 -0
- package/dist/src/work/outcome-execution-service.d.ts +27 -0
- package/dist/src/work/outcome-execution-service.js +60 -0
- package/dist/src/work/outcome-projection-service.d.ts +7 -0
- package/dist/src/work/outcome-projection-service.js +51 -0
- package/dist/src/work/outcome-receipt-service.d.ts +13 -0
- package/dist/src/work/outcome-receipt-service.js +55 -0
- package/dist/src/work/outcome-repository.d.ts +50 -0
- package/dist/src/work/outcome-repository.js +112 -0
- package/dist/src/work/outcome-run-coordinator.d.ts +25 -0
- package/dist/src/work/outcome-run-coordinator.js +117 -0
- package/dist/src/work/project-monitoring-service.d.ts +21 -0
- package/dist/src/work/project-monitoring-service.js +76 -0
- package/dist/src/work/project-operating-view-service.d.ts +10 -0
- package/dist/src/work/project-operating-view-service.js +46 -0
- package/dist/src/work/work-intake-repository.d.ts +49 -0
- package/dist/src/work/work-intake-repository.js +97 -0
- package/dist/src/work/work-intake-service.d.ts +26 -0
- package/dist/src/work/work-intake-service.js +171 -0
- package/dist/src/work/work-value-metrics-service.d.ts +4 -0
- package/dist/src/work/work-value-metrics-service.js +88 -0
- package/dist/src/work-items/work-item-service.d.ts +0 -2
- package/dist/src/work-items/work-item-service.js +0 -28
- package/dist/src/workflows/service/workflow-run-service.js +2 -2
- package/dist/src/workflows/service/workflow-run-service.types.d.ts +3 -1
- package/dist/src/workflows/service/workflow-session-bridge.js +2 -2
- package/package.json +1 -1
- package/dist/gateway/static/root/assets/agents-DC9F12Kw.js +0 -2
- package/dist/gateway/static/root/assets/apps-page-5bKr05Fa.js +0 -1
- package/dist/gateway/static/root/assets/automation-suggestion-card-B7mxFRtf.js +0 -1
- package/dist/gateway/static/root/assets/automations-page-Dg6dmt5g.js +0 -6
- package/dist/gateway/static/root/assets/browser-settings-page-BHoo6Rpq.js +0 -8
- package/dist/gateway/static/root/assets/capabilities-settings-panel-BlsqN8Fu.js +0 -7
- package/dist/gateway/static/root/assets/capability-presets-settings-panel-DJeT8_B4.js +0 -1
- package/dist/gateway/static/root/assets/channels-settings-C4VVjYEm.js +0 -1
- package/dist/gateway/static/root/assets/channels-status-swr-vdf8kB16.js +0 -1
- package/dist/gateway/static/root/assets/circle-alert-BEjgurr2.js +0 -1
- package/dist/gateway/static/root/assets/connectors-page-DNcrDThX.js +0 -2
- package/dist/gateway/static/root/assets/desktop-pet-B1urphOZ.js +0 -1
- package/dist/gateway/static/root/assets/desktop-pet-settings-DTL6J3EP.js +0 -1
- package/dist/gateway/static/root/assets/gateway-settings-DmObBx9b.js +0 -1
- package/dist/gateway/static/root/assets/goal-create-dialog-BRhmmBe9.js +0 -1
- package/dist/gateway/static/root/assets/goal-detail-page-C1k7_s_O.js +0 -4
- package/dist/gateway/static/root/assets/goals-config-api-Fwu1wjEP.js +0 -1
- package/dist/gateway/static/root/assets/goals-page-hOu9uA3q.js +0 -2
- package/dist/gateway/static/root/assets/goals-settings-DY-JjvHz.js +0 -1
- package/dist/gateway/static/root/assets/index-C0CGebQ1.js +0 -212
- package/dist/gateway/static/root/assets/index-eqq25gvV.css +0 -1
- package/dist/gateway/static/root/assets/local-app-workbench-page-EjsNT7nJ.js +0 -2
- package/dist/gateway/static/root/assets/logs-page-Dswjlraa.js +0 -7
- package/dist/gateway/static/root/assets/messages-DP6tPKk-.js +0 -3
- package/dist/gateway/static/root/assets/notes-workbench-DSh3-hMY.js +0 -4
- package/dist/gateway/static/root/assets/product-delivery-BTRT9kCS.js +0 -1
- package/dist/gateway/static/root/assets/project-detail-page-D0QPRHR_.js +0 -1
- package/dist/gateway/static/root/assets/projects-page-CI5Vz62F.js +0 -1
- package/dist/gateway/static/root/assets/remote-access-hub-S1jpzBS5.js +0 -1
- package/dist/gateway/static/root/assets/sessions-page-CTm66k7h.js +0 -1
- package/dist/gateway/static/root/assets/settings-advanced-gate-CU52AUVD.js +0 -1
- package/dist/gateway/static/root/assets/shares-settings-DK6XK95e.js +0 -1
- package/dist/gateway/static/root/assets/skill-reload-api-Bvv_u4ii.js +0 -1
- package/dist/gateway/static/root/assets/skills-page-BGHvVbay.js +0 -2
- package/dist/gateway/static/root/assets/time-picker-XwpxdZFr.js +0 -1
- package/dist/gateway/static/root/assets/user-context-page-DBCMk-Vn.js +0 -1
- package/dist/gateway/static/root/assets/work-discovery-page-C1UIdsCl.js +0 -1
- package/dist/gateway/static/root/assets/work-item-detail-page-DEAQepB8.js +0 -1
- package/dist/gateway/static/root/assets/work-page-D5qYmCTq.js +0 -3
- package/dist/gateway/static/root/assets/workflows-page-yrK17ZZ5.js +0 -11
- package/dist/src/agent/outcomes/task-verifier.d.ts +0 -29
- package/dist/src/gateway/hono/routes/task-outcomes.d.ts +0 -3
- package/dist/src/gateway/hono/routes/task-outcomes.js +0 -109
- package/dist/src/goals/goal-contract-draft.d.ts +0 -15
- package/dist/src/goals/goal-contract-draft.js +0 -112
- package/dist/src/goals/goal-evidence-review.d.ts +0 -15
- package/dist/src/goals/goal-evidence-review.js +0 -89
- package/dist/src/storage/sqlite/task-outcome-repository.d.ts +0 -90
- package/dist/src/storage/sqlite/task-outcome-repository.js +0 -138
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
export declare const DISCUSSION_STATUSES: readonly ["recording", "finalizing", "completed", "failed", "cancelled"];
|
|
2
|
+
export type DiscussionStatus = typeof DISCUSSION_STATUSES[number];
|
|
3
|
+
export type DiscussionProcessingStage = 'original_upload' | 'final_transcription' | 'analysis' | 'note_write';
|
|
4
|
+
export type DiscussionSource = 'web' | 'electron';
|
|
5
|
+
export type DiscussionProjectInferenceSource = 'context' | 'exact_name' | 'model';
|
|
6
|
+
export interface DiscussionActionItem {
|
|
7
|
+
id: string;
|
|
8
|
+
title: string;
|
|
9
|
+
owner?: string;
|
|
10
|
+
dueDate?: string;
|
|
11
|
+
}
|
|
12
|
+
export interface DiscussionAnalysis {
|
|
13
|
+
title: string;
|
|
14
|
+
summary: string;
|
|
15
|
+
keyPoints: string[];
|
|
16
|
+
decisions: string[];
|
|
17
|
+
actionItems: DiscussionActionItem[];
|
|
18
|
+
risks: string[];
|
|
19
|
+
openQuestions: string[];
|
|
20
|
+
projectCandidateId?: string;
|
|
21
|
+
projectConfidence?: number;
|
|
22
|
+
projectAlternativeConfidence?: number;
|
|
23
|
+
}
|
|
24
|
+
export interface DiscussionCapture {
|
|
25
|
+
id: string;
|
|
26
|
+
clientRequestId: string;
|
|
27
|
+
noteId: string;
|
|
28
|
+
projectId?: string;
|
|
29
|
+
audioAttachmentId?: string;
|
|
30
|
+
source: DiscussionSource;
|
|
31
|
+
status: DiscussionStatus;
|
|
32
|
+
processingStage?: DiscussionProcessingStage;
|
|
33
|
+
durationMs?: number;
|
|
34
|
+
expectedLastSequence?: number;
|
|
35
|
+
mimeType?: string;
|
|
36
|
+
audioSizeBytes?: number;
|
|
37
|
+
audioSha256?: string;
|
|
38
|
+
transcriptRaw?: string;
|
|
39
|
+
transcriptSha256?: string;
|
|
40
|
+
transcriptLanguage?: string;
|
|
41
|
+
sttProvider?: string;
|
|
42
|
+
analysis?: DiscussionAnalysis;
|
|
43
|
+
analysisInputHash?: string;
|
|
44
|
+
analyzerModelRef?: string;
|
|
45
|
+
generatedTitle?: string;
|
|
46
|
+
projectInferenceScore?: number;
|
|
47
|
+
projectInferenceSource?: DiscussionProjectInferenceSource;
|
|
48
|
+
finalizationRevision: number;
|
|
49
|
+
attemptCount: number;
|
|
50
|
+
nextAttemptAt?: number;
|
|
51
|
+
leaseOwner?: string;
|
|
52
|
+
leaseExpiresAt?: number;
|
|
53
|
+
lastErrorCode?: string;
|
|
54
|
+
lastErrorMessage?: string;
|
|
55
|
+
recordingStartedAt: number;
|
|
56
|
+
recordingFinishedAt?: number;
|
|
57
|
+
createdAt: number;
|
|
58
|
+
updatedAt: number;
|
|
59
|
+
completedAt?: number;
|
|
60
|
+
audioDeletedAt?: number;
|
|
61
|
+
}
|
|
62
|
+
export interface DiscussionTranscriptSegment {
|
|
63
|
+
discussionId: string;
|
|
64
|
+
sequence: number;
|
|
65
|
+
audioSha256: string;
|
|
66
|
+
startedAtMs: number;
|
|
67
|
+
endedAtMs: number;
|
|
68
|
+
status: 'uploaded' | 'transcribing' | 'completed' | 'failed';
|
|
69
|
+
transcript?: string;
|
|
70
|
+
provider?: string;
|
|
71
|
+
attemptCount: number;
|
|
72
|
+
nextAttemptAt?: number;
|
|
73
|
+
leaseOwner?: string;
|
|
74
|
+
leaseExpiresAt?: number;
|
|
75
|
+
lastError?: string;
|
|
76
|
+
createdAt: number;
|
|
77
|
+
updatedAt: number;
|
|
78
|
+
}
|
|
79
|
+
export interface DiscussionTranscript {
|
|
80
|
+
discussionId: string;
|
|
81
|
+
segments: DiscussionTranscriptSegment[];
|
|
82
|
+
text: string;
|
|
83
|
+
}
|
|
84
|
+
export interface DiscussionCaptureSettings {
|
|
85
|
+
consentPolicyVersion: number;
|
|
86
|
+
consentAcknowledgedAt?: number;
|
|
87
|
+
}
|
|
88
|
+
export interface CreateDiscussionInput {
|
|
89
|
+
clientRequestId: string;
|
|
90
|
+
contextProjectId?: string;
|
|
91
|
+
consentPolicyVersion: number;
|
|
92
|
+
source: DiscussionSource;
|
|
93
|
+
}
|
|
94
|
+
export interface ListDiscussionsQuery {
|
|
95
|
+
status?: DiscussionStatus | 'active';
|
|
96
|
+
projectId?: string;
|
|
97
|
+
limit?: number;
|
|
98
|
+
offset?: number;
|
|
99
|
+
}
|
|
100
|
+
export interface DiscussionListResult {
|
|
101
|
+
items: DiscussionCapture[];
|
|
102
|
+
total: number;
|
|
103
|
+
limit: number;
|
|
104
|
+
offset: number;
|
|
105
|
+
hasMore: boolean;
|
|
106
|
+
}
|
|
107
|
+
export interface DiscussionMetrics {
|
|
108
|
+
total: number;
|
|
109
|
+
byStatus: Record<DiscussionStatus, number>;
|
|
110
|
+
averageTimeToFirstTranscriptMs: number | null;
|
|
111
|
+
averageTimeToCompleteMs: number | null;
|
|
112
|
+
}
|
|
113
|
+
export interface DiscussionDetail {
|
|
114
|
+
discussion: DiscussionCapture;
|
|
115
|
+
note: import('../notes/types.js').Note;
|
|
116
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { DiscussionCapture } from './types.js';
|
|
2
|
+
export interface DiscussionWorkerProcessor {
|
|
3
|
+
process(capture: DiscussionCapture, owner: string, signal?: AbortSignal): Promise<DiscussionCapture>;
|
|
4
|
+
}
|
|
5
|
+
export declare class DiscussionWorker {
|
|
6
|
+
private readonly processor;
|
|
7
|
+
private readonly onUpdated?;
|
|
8
|
+
private readonly intervalMs;
|
|
9
|
+
private readonly owner;
|
|
10
|
+
private timer?;
|
|
11
|
+
private running;
|
|
12
|
+
private stoppedWaiters;
|
|
13
|
+
constructor(processor: DiscussionWorkerProcessor, onUpdated?: (capture: DiscussionCapture) => void, intervalMs?: number);
|
|
14
|
+
start(): void;
|
|
15
|
+
stop(): Promise<void>;
|
|
16
|
+
tick(): Promise<void>;
|
|
17
|
+
private failOrRetry;
|
|
18
|
+
}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
import { createLogger } from "../utils/logger/index.js";
|
|
2
|
+
import { init_logger } from "../utils/logger.js";
|
|
3
|
+
import { claimNextDiscussionCapture, getDiscussionCapture, updateDiscussionCapture } from "./repository.js";
|
|
4
|
+
import { randomUUID } from "node:crypto";
|
|
5
|
+
//#region src/discussions/worker.ts
|
|
6
|
+
init_logger();
|
|
7
|
+
const log = createLogger("DiscussionWorker");
|
|
8
|
+
const MAX_ATTEMPTS = 3;
|
|
9
|
+
var DiscussionWorker = class {
|
|
10
|
+
owner = randomUUID();
|
|
11
|
+
timer;
|
|
12
|
+
running = false;
|
|
13
|
+
stoppedWaiters = [];
|
|
14
|
+
constructor(processor, onUpdated, intervalMs = 2e3) {
|
|
15
|
+
this.processor = processor;
|
|
16
|
+
this.onUpdated = onUpdated;
|
|
17
|
+
this.intervalMs = intervalMs;
|
|
18
|
+
}
|
|
19
|
+
start() {
|
|
20
|
+
if (this.timer) return;
|
|
21
|
+
this.timer = setInterval(() => void this.tick(), this.intervalMs);
|
|
22
|
+
this.timer.unref();
|
|
23
|
+
this.tick();
|
|
24
|
+
}
|
|
25
|
+
async stop() {
|
|
26
|
+
if (this.timer) clearInterval(this.timer);
|
|
27
|
+
this.timer = void 0;
|
|
28
|
+
if (!this.running) return;
|
|
29
|
+
await new Promise((resolve) => this.stoppedWaiters.push(resolve));
|
|
30
|
+
}
|
|
31
|
+
async tick() {
|
|
32
|
+
if (this.running) return;
|
|
33
|
+
this.running = true;
|
|
34
|
+
try {
|
|
35
|
+
const capture = claimNextDiscussionCapture(this.owner);
|
|
36
|
+
if (!capture) return;
|
|
37
|
+
this.onUpdated?.(capture);
|
|
38
|
+
try {
|
|
39
|
+
await this.processor.process(capture, this.owner);
|
|
40
|
+
} catch (error) {
|
|
41
|
+
this.failOrRetry(capture.id, error);
|
|
42
|
+
}
|
|
43
|
+
} finally {
|
|
44
|
+
this.running = false;
|
|
45
|
+
const waiters = this.stoppedWaiters.splice(0);
|
|
46
|
+
for (const resolve of waiters) resolve();
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
failOrRetry(id, error) {
|
|
50
|
+
const current = getDiscussionCapture(id);
|
|
51
|
+
if (!current || current.leaseOwner !== this.owner) return;
|
|
52
|
+
const failedStage = current.processingStage ?? "final_transcription";
|
|
53
|
+
const exhausted = current.attemptCount >= MAX_ATTEMPTS;
|
|
54
|
+
const errorMessage = error instanceof Error ? error.message : String(error);
|
|
55
|
+
const updated = updateDiscussionCapture(id, {
|
|
56
|
+
status: exhausted ? "failed" : "finalizing",
|
|
57
|
+
leaseOwner: void 0,
|
|
58
|
+
leaseExpiresAt: void 0,
|
|
59
|
+
nextAttemptAt: exhausted ? void 0 : Date.now() + 2 ** current.attemptCount * 1e3,
|
|
60
|
+
lastErrorCode: `${failedStage}_failed`,
|
|
61
|
+
lastErrorMessage: errorMessage.slice(0, 1e3)
|
|
62
|
+
}, [current.status]);
|
|
63
|
+
if (updated) this.onUpdated?.(updated);
|
|
64
|
+
log.warn({
|
|
65
|
+
err: error,
|
|
66
|
+
discussionId: id,
|
|
67
|
+
failedStage,
|
|
68
|
+
attemptCount: current.attemptCount,
|
|
69
|
+
exhausted
|
|
70
|
+
}, `Discussion ${failedStage} failed: ${errorMessage}`);
|
|
71
|
+
}
|
|
72
|
+
};
|
|
73
|
+
//#endregion
|
|
74
|
+
export { DiscussionWorker };
|
|
@@ -4,7 +4,8 @@ import { collectTtsProviderConfigEntries } from "../voice/tts/config-slice.js";
|
|
|
4
4
|
import { isProviderConfigured } from "../voice/tts/factory.js";
|
|
5
5
|
import { mergeTtsConfigFromAppConfig } from "../voice/tts/merge-config.js";
|
|
6
6
|
import { collectSttProviderConfigEntries } from "../voice/stt/config-slice.js";
|
|
7
|
-
import { mergeSttConfigFromAppConfig } from "../
|
|
7
|
+
import { mergeSttConfigFromAppConfig } from "../voice/stt/config.js";
|
|
8
|
+
import "../voice/stt/index.js";
|
|
8
9
|
import { isSttProviderConfigured } from "../voice/stt/list-providers.js";
|
|
9
10
|
//#region src/extensions/activation-context.ts
|
|
10
11
|
init_providers();
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { createLogger } from "../utils/logger/index.js";
|
|
2
2
|
import { init_logger } from "../utils/logger.js";
|
|
3
|
-
import { init_paths, resolveExtensionsDir, resolveExtensionsLockPath } from "../config/paths.js";
|
|
4
3
|
import { init_write_file_atomic, writeTextAtomic } from "../infra/write-file-atomic.js";
|
|
4
|
+
import { init_paths, resolveExtensionsDir, resolveExtensionsLockPath } from "../config/paths.js";
|
|
5
5
|
import { dirname, join } from "path";
|
|
6
6
|
import { existsSync } from "fs";
|
|
7
7
|
import { mkdir, readFile } from "fs/promises";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { TypedEventBus } from "../typed-event-bus.js";
|
|
2
|
-
import { serve } from "@hono/node-server";
|
|
3
2
|
import { EventEmitter, once } from "node:events";
|
|
3
|
+
import { serve } from "@hono/node-server";
|
|
4
4
|
import { Hono } from "hono";
|
|
5
5
|
//#region src/extensions/sdk/testing.ts
|
|
6
6
|
const noopLogger = {
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { init_agent_scope, listAgentEntries, normalizeAgentId, resolveAgentDir, resolveAgentProfileDir, resolveAgentWorkspaceDir, resolveDefaultAgentId, resolveUserPath, validateAgentIdForNewAgent } from "../agent/agent-scope.js";
|
|
2
1
|
import { resolveEffectiveAgentManifest } from "../agent-manifest/resolver.js";
|
|
3
|
-
import {
|
|
2
|
+
import { init_agent_scope, listAgentEntries, normalizeAgentId, resolveAgentDir, resolveAgentProfileDir, resolveAgentWorkspaceDir, resolveDefaultAgentId, resolveUserPath, validateAgentIdForNewAgent } from "../agent/agent-scope.js";
|
|
4
3
|
import { WORKSPACE_FILES, init_paths, resolveUserProfilePath } from "../config/paths.js";
|
|
4
|
+
import { resolveEffectiveAgentProfile } from "../config/agent-profile.js";
|
|
5
5
|
import { AGENT_PROFILE_MARKDOWN_SYSTEM_FILES, REQUIRED_AGENT_PROFILE_MARKDOWN_FILE_SET } from "../agent/context/workspace.js";
|
|
6
6
|
import { isPathUnderWorkspace, resolveWorkspaceSafePath } from "./workspace-editor-path.js";
|
|
7
|
+
import { seedAgentProfileMarkdownFiles } from "../agent/context/workspace-seed.js";
|
|
7
8
|
import { applyAgentConfig, findAgentEntryIndex, getAgentDeleteBlocker, pruneAgentConfig, removeAgentDirsFromDisk } from "../commands/agents.config.js";
|
|
8
9
|
import { resolveEffectiveTypedModels } from "../config/agent-typed-models.js";
|
|
9
10
|
import { GATEWAY_BUILTIN_TOOL_IDS } from "./agent-builtin-tools.js";
|
|
10
|
-
import { seedAgentProfileMarkdownFiles } from "../agent/context/workspace-seed.js";
|
|
11
11
|
import { dirname, join, resolve } from "node:path";
|
|
12
12
|
import { cp, mkdir, readFile, readdir, realpath, stat, unlink, writeFile } from "node:fs/promises";
|
|
13
13
|
//#region src/gateway/agents-admin.ts
|
|
@@ -1,5 +1,10 @@
|
|
|
1
1
|
import { createPetFeedback } from "./pet-feedback.js";
|
|
2
2
|
//#region src/gateway/chat-stream/mapper.ts
|
|
3
|
+
let lastTaskPlanRevision = 0;
|
|
4
|
+
function nextTaskPlanRevision() {
|
|
5
|
+
lastTaskPlanRevision = Math.max(Date.now(), lastTaskPlanRevision + 1);
|
|
6
|
+
return lastTaskPlanRevision;
|
|
7
|
+
}
|
|
3
8
|
var ChatStreamMapper = class {
|
|
4
9
|
assistantIndex = 0;
|
|
5
10
|
currentAssistantMessageId;
|
|
@@ -350,11 +355,37 @@ var ChatStreamMapper = class {
|
|
|
350
355
|
}));
|
|
351
356
|
}
|
|
352
357
|
}
|
|
353
|
-
if (toolName === "update_plan" && details) {
|
|
358
|
+
if (toolName === "update_plan" && details && !event.isError) {
|
|
354
359
|
const plan = extractTurnPlan(details);
|
|
355
|
-
if (plan)
|
|
360
|
+
if (plan) {
|
|
361
|
+
events.push(this.make("turn_plan", {
|
|
362
|
+
messageId,
|
|
363
|
+
...plan
|
|
364
|
+
}));
|
|
365
|
+
events.push(this.make("task_plan_updated", {
|
|
366
|
+
messageId,
|
|
367
|
+
planId: `${messageId}:update_plan`,
|
|
368
|
+
revision: nextTaskPlanRevision(),
|
|
369
|
+
source: "update_plan",
|
|
370
|
+
scope: "turn",
|
|
371
|
+
explanation: plan.explanation,
|
|
372
|
+
items: plan.plan.map((item, index) => ({
|
|
373
|
+
id: item.id ?? `step-${index + 1}`,
|
|
374
|
+
title: item.step,
|
|
375
|
+
status: item.status
|
|
376
|
+
}))
|
|
377
|
+
}));
|
|
378
|
+
}
|
|
379
|
+
}
|
|
380
|
+
if (toolName === "todo" && details && !event.isError) {
|
|
381
|
+
const items = extractTodoItems(details);
|
|
382
|
+
if (items) events.push(this.make("task_plan_updated", {
|
|
356
383
|
messageId,
|
|
357
|
-
|
|
384
|
+
planId: `${this.opts.sessionKey}:todo`,
|
|
385
|
+
revision: nextTaskPlanRevision(),
|
|
386
|
+
source: "todo",
|
|
387
|
+
scope: "session",
|
|
388
|
+
items
|
|
358
389
|
}));
|
|
359
390
|
}
|
|
360
391
|
return events;
|
|
@@ -462,10 +493,12 @@ function normalizeToolResult(value) {
|
|
|
462
493
|
function extractTurnPlan(details) {
|
|
463
494
|
const plan = (Array.isArray(details.plan) ? details.plan : []).map((item) => {
|
|
464
495
|
const rec = asRecord(item);
|
|
496
|
+
const id = typeof rec?.id === "string" && rec.id.trim() ? rec.id.trim() : void 0;
|
|
465
497
|
const step = typeof rec?.step === "string" ? rec.step.trim() : "";
|
|
466
498
|
const status = rec?.status;
|
|
467
499
|
if (!step || status !== "pending" && status !== "in_progress" && status !== "completed") return;
|
|
468
500
|
return {
|
|
501
|
+
...id ? { id } : {},
|
|
469
502
|
step,
|
|
470
503
|
status
|
|
471
504
|
};
|
|
@@ -476,5 +509,22 @@ function extractTurnPlan(details) {
|
|
|
476
509
|
plan
|
|
477
510
|
};
|
|
478
511
|
}
|
|
512
|
+
function extractTodoItems(details) {
|
|
513
|
+
if (!Array.isArray(details.items)) return void 0;
|
|
514
|
+
const items = [];
|
|
515
|
+
for (const item of details.items) {
|
|
516
|
+
const rec = asRecord(item);
|
|
517
|
+
const id = typeof rec?.id === "string" ? rec.id.trim() : "";
|
|
518
|
+
const title = typeof rec?.content === "string" ? rec.content.trim() : "";
|
|
519
|
+
const status = rec?.status;
|
|
520
|
+
if (!id || !title || status !== "pending" && status !== "in_progress" && status !== "completed" && status !== "cancelled") continue;
|
|
521
|
+
items.push({
|
|
522
|
+
id,
|
|
523
|
+
title,
|
|
524
|
+
status
|
|
525
|
+
});
|
|
526
|
+
}
|
|
527
|
+
return items;
|
|
528
|
+
}
|
|
479
529
|
//#endregion
|
|
480
530
|
export { ChatStreamMapper };
|
|
@@ -117,6 +117,22 @@ export type TurnPlanUpdatedEvent = ChatStreamEnvelope<'turn_plan', {
|
|
|
117
117
|
status: TurnPlanStatus;
|
|
118
118
|
}[];
|
|
119
119
|
}>;
|
|
120
|
+
export type TaskPlanSource = 'update_plan' | 'todo';
|
|
121
|
+
export type TaskPlanScope = 'turn' | 'session';
|
|
122
|
+
export type TaskPlanStatus = TurnPlanStatus | 'cancelled';
|
|
123
|
+
export type TaskPlanUpdatedEvent = ChatStreamEnvelope<'task_plan_updated', {
|
|
124
|
+
messageId: string;
|
|
125
|
+
planId: string;
|
|
126
|
+
revision: number;
|
|
127
|
+
source: TaskPlanSource;
|
|
128
|
+
scope: TaskPlanScope;
|
|
129
|
+
explanation?: string;
|
|
130
|
+
items: {
|
|
131
|
+
id: string;
|
|
132
|
+
title: string;
|
|
133
|
+
status: TaskPlanStatus;
|
|
134
|
+
}[];
|
|
135
|
+
}>;
|
|
120
136
|
export type TurnDiffEvent = ChatStreamEnvelope<'turn_diff', {
|
|
121
137
|
messageId: string;
|
|
122
138
|
files: string[];
|
|
@@ -209,4 +225,4 @@ export type StreamErrorEvent = ChatStreamEnvelope<'error', {
|
|
|
209
225
|
recoverable?: boolean;
|
|
210
226
|
petFeedback: PetFeedback;
|
|
211
227
|
}>;
|
|
212
|
-
export type ChatStreamEvent = RunStartEvent | UserMessageEvent | UserTranscriptEvent | AssistantMessageStartEvent | AssistantDeltaEvent | ThinkingDeltaEvent | ThinkingEndEvent | ToolStartEvent | ToolUpdateEvent | ToolEndEvent | CommandStartedEvent | CommandOutputDeltaEvent | CommandCompletedEvent | PatchAppliedEvent | TurnPlanUpdatedEvent | TurnDiffEvent | ReviewStartEvent | ReviewDeltaEvent | ReviewEndEvent | ReviewEvent | AssistantMessageEndEvent | ProgressEvent | CompactionEvent | TtsAudioEvent | ClarifyRequestEvent | MemoryConsentRequiredEvent | MemoryCapturedEvent | RunEndEvent | StreamErrorEvent;
|
|
228
|
+
export type ChatStreamEvent = RunStartEvent | UserMessageEvent | UserTranscriptEvent | AssistantMessageStartEvent | AssistantDeltaEvent | ThinkingDeltaEvent | ThinkingEndEvent | ToolStartEvent | ToolUpdateEvent | ToolEndEvent | CommandStartedEvent | CommandOutputDeltaEvent | CommandCompletedEvent | PatchAppliedEvent | TurnPlanUpdatedEvent | TaskPlanUpdatedEvent | TurnDiffEvent | ReviewStartEvent | ReviewDeltaEvent | ReviewEndEvent | ReviewEvent | AssistantMessageEndEvent | ProgressEvent | CompactionEvent | TtsAudioEvent | ClarifyRequestEvent | MemoryConsentRequiredEvent | MemoryCapturedEvent | RunEndEvent | StreamErrorEvent;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { init_paths_state, resolveStateDir } from "../config/paths-state.js";
|
|
2
2
|
import { init_agent_scope, resolveAgentProfileDir } from "../agent/agent-scope.js";
|
|
3
|
-
import { extractProfileAgentId } from "../config/agent-profile.js";
|
|
4
3
|
import { init_paths, resolveConfigPath, resolveSkillsDir } from "../config/paths.js";
|
|
4
|
+
import { extractProfileAgentId } from "../config/agent-profile.js";
|
|
5
5
|
import { isBareProfileMarkdownFileName, resolveProfileMarkdownPathIfBareName } from "../agent/tools/tool-paths.js";
|
|
6
6
|
import { isPathUnderWorkspace, resolveWorkspaceSafePath } from "./workspace-editor-path.js";
|
|
7
7
|
import { basename, isAbsolute, resolve } from "node:path";
|
|
@@ -4,10 +4,10 @@ import { resolveAllowedBrowserOrigins, resolveGatewayServiceListenPort } from ".
|
|
|
4
4
|
import { resolveGatewayEffectiveHost } from "../../config/gateway-bind.js";
|
|
5
5
|
import { loadTunnelState } from "../../tunnel/tunnel-state.js";
|
|
6
6
|
import { resolveReverseProxyPublicUrl } from "../public-url.js";
|
|
7
|
+
import "../../work-items/work-item-service.js";
|
|
8
|
+
import "../../work-items/index.js";
|
|
7
9
|
import { maxWebchatAgentRequestBodyBytes } from "../chat-limits.js";
|
|
8
10
|
import { isLoopbackIpAddress, isTrustedProxyAddress } from "../client-ip.js";
|
|
9
|
-
import { WORK_ITEM_ATTACHMENT_UPLOAD_BODY_MAX_BYTES } from "../../work-items/work-item-service.js";
|
|
10
|
-
import "../../work-items/index.js";
|
|
11
11
|
import { buildGatewayConsoleCspHeader } from "../security/csp.js";
|
|
12
12
|
import { checkBrowserOrigin } from "../security/origin-check.js";
|
|
13
13
|
import { auth } from "./middleware/auth.js";
|
|
@@ -155,6 +155,11 @@ function createHonoApp(config) {
|
|
|
155
155
|
if (/^\/api\/notes\/[^/]+\/media$/.test(path)) return true;
|
|
156
156
|
return path === "/api/notes" && contentType?.includes("multipart/form-data") === true;
|
|
157
157
|
};
|
|
158
|
+
const discussionUploadBodyMax = (path, method, contentType) => {
|
|
159
|
+
if (method !== "PUT" || contentType?.includes("multipart/form-data") !== true) return void 0;
|
|
160
|
+
if (/^\/api\/discussions\/[^/]+\/recording$/.test(path)) return NOTE_MEDIA_BODY_MAX;
|
|
161
|
+
if (/^\/api\/discussions\/[^/]+\/segments\/\d+$/.test(path)) return 2 * 1024 * 1024;
|
|
162
|
+
};
|
|
158
163
|
const isWorkItemAttachmentUploadRequest = (path, method, contentType) => {
|
|
159
164
|
if (method !== "POST" || contentType?.includes("multipart/form-data") !== true) return false;
|
|
160
165
|
return /^\/api\/work-items\/[^/]+\/attachments$/.test(path) || /^\/api\/projects\/[^/]+\/work-items$/.test(path);
|
|
@@ -174,7 +179,7 @@ function createHonoApp(config) {
|
|
|
174
179
|
}));
|
|
175
180
|
app.use("/api/*", async (c, next) => {
|
|
176
181
|
const contentType = c.req.header("content-type");
|
|
177
|
-
const maxSize = c.req.path === "/api/agent" ? WEBCHAT_AGENT_BODY_MAX : c.req.path === "/api/skills/upload" ? SKILL_UPLOAD_BODY_MAX : c.req.path === "/api/voice/transcribe" || c.req.path === "/api/voice/transcriptions" ? VOICE_TRANSCRIBE_BODY_MAX : isNoteMediaUploadRequest(c.req.path, c.req.method, contentType) ? NOTE_MEDIA_BODY_MAX : isWorkItemAttachmentUploadRequest(c.req.path, c.req.method, contentType) ?
|
|
182
|
+
const maxSize = c.req.path === "/api/agent" ? WEBCHAT_AGENT_BODY_MAX : c.req.path === "/api/skills/upload" ? SKILL_UPLOAD_BODY_MAX : c.req.path === "/api/voice/transcribe" || c.req.path === "/api/voice/transcriptions" ? VOICE_TRANSCRIBE_BODY_MAX : isNoteMediaUploadRequest(c.req.path, c.req.method, contentType) ? NOTE_MEDIA_BODY_MAX : discussionUploadBodyMax(c.req.path, c.req.method, contentType) ?? (isWorkItemAttachmentUploadRequest(c.req.path, c.req.method, contentType) ? 263192576 : DEFAULT_API_BODY_MAX);
|
|
178
183
|
const maxSizeMb = Math.ceil(maxSize / (1024 * 1024));
|
|
179
184
|
return bodyLimit({
|
|
180
185
|
maxSize,
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import { ContextCompactionPolicySchema, init_config } from "../../../user-context/config.js";
|
|
2
2
|
import { init_agent_scope, listAgentEntries, normalizeAgentId, resolveDefaultAgentId } from "../../../agent/agent-scope.js";
|
|
3
3
|
import { resolveModelsJsonPath } from "../../../config/paths.js";
|
|
4
|
-
import { buildChannelCatalogForConfig, buildChannelCatalogFromSnapshot, getChannelSetupStatus, init_channel_catalog_service } from "../../../channels/catalog/channel-catalog-service.js";
|
|
5
4
|
import { init_models_json, loadModelsJson } from "../../../config/models-json.js";
|
|
6
5
|
import { CredentialResolver, init_credentials } from "../../../auth/credentials.js";
|
|
6
|
+
import { buildChannelCatalogForConfig, buildChannelCatalogFromSnapshot, getChannelSetupStatus, init_channel_catalog_service } from "../../../channels/catalog/channel-catalog-service.js";
|
|
7
7
|
import { getProviderRegistry, init_plugin_registry } from "../../../providers/plugin-registry.js";
|
|
8
8
|
import { getAllProviders, init_providers, isProviderConfigured } from "../../../providers/index.js";
|
|
9
9
|
import { resolveShareConfig } from "../../../share/share-config.js";
|
|
10
|
+
import { maskTunnelSecretForWeb } from "../../../tunnel/env.js";
|
|
10
11
|
import { normalizeConfiguredMcpServers } from "../../../config/mcp-config-normalize.js";
|
|
11
12
|
import { resolveGoalsConfigForWeb, resolveSessionConfigForWeb, resolveUpdateConfigForWeb } from "../../../config/web-patch.js";
|
|
12
13
|
import { GENERIC_MASKED_SECRET, maskSecretLength } from "./mask-secret-length.js";
|
|
13
14
|
import { safeToolsWebForGet } from "../../config-tools-web.js";
|
|
14
|
-
import { maskTunnelSecretForWeb } from "../../../tunnel/env.js";
|
|
15
15
|
import { buildSafeProvidersConfigForWeb } from "./safe-providers-config.js";
|
|
16
16
|
import { maskSttConfigForWeb, maskTtsConfigForWeb } from "./safe-voice-config.js";
|
|
17
17
|
//#region src/gateway/hono/lib/config-payload.ts
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { logAuthEvent } from "../../../utils/logger/audit.js";
|
|
2
2
|
import { createLogger } from "../../../utils/logger/index.js";
|
|
3
3
|
import { init_logger } from "../../../utils/logger.js";
|
|
4
|
-
import { safeEqualSecret } from "../../security/secret-equal.js";
|
|
5
|
-
import { resolveClientIpFromRequest } from "../../client-ip.js";
|
|
6
4
|
import { authPolicyConfig, buckets, resolveAuthRateLimit } from "../../rate-limit/buckets.js";
|
|
7
5
|
import { getClientIpFromHeaders } from "../../security/loopback.js";
|
|
8
6
|
import { resolveAuthTracking } from "../../rate-limit/auth-policy.js";
|
|
9
7
|
import { isAuthRateLimitGloballyDisabled } from "../../rate-limit/env-flags.js";
|
|
10
8
|
import "../../rate-limit/index.js";
|
|
9
|
+
import { safeEqualSecret } from "../../security/secret-equal.js";
|
|
10
|
+
import { resolveClientIpFromRequest } from "../../client-ip.js";
|
|
11
11
|
import { authorizeTrustedProxy } from "../../trusted-proxy.js";
|
|
12
12
|
import { createMiddleware } from "hono/factory";
|
|
13
13
|
import { getConnInfo } from "@hono/node-server/conninfo";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { createLogger } from "../../../utils/logger/index.js";
|
|
2
2
|
import { init_logger } from "../../../utils/logger.js";
|
|
3
|
-
import { resolveClientIpFromRequest } from "../../client-ip.js";
|
|
4
3
|
import { getClientIpFromHeaders } from "../../security/loopback.js";
|
|
4
|
+
import { resolveClientIpFromRequest } from "../../client-ip.js";
|
|
5
5
|
import { createMiddleware } from "hono/factory";
|
|
6
6
|
import { getConnInfo } from "@hono/node-server/conninfo";
|
|
7
7
|
//#region src/gateway/hono/middleware/logger.ts
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { createLogger } from "../../../utils/logger/index.js";
|
|
2
2
|
import { init_logger } from "../../../utils/logger.js";
|
|
3
|
-
import { resolveClientIpFromRequest } from "../../client-ip.js";
|
|
4
3
|
import { buckets } from "../../rate-limit/buckets.js";
|
|
5
4
|
import { getClientIpFromHeaders } from "../../security/loopback.js";
|
|
6
5
|
import "../../rate-limit/index.js";
|
|
6
|
+
import { resolveClientIpFromRequest } from "../../client-ip.js";
|
|
7
7
|
import { createMiddleware } from "hono/factory";
|
|
8
8
|
import { getConnInfo } from "@hono/node-server/conninfo";
|
|
9
9
|
//#region src/gateway/hono/middleware/strict-rate-limit.ts
|
|
@@ -275,13 +275,7 @@ async function runOAuthFlow(session, oauthProvider, _service) {
|
|
|
275
275
|
try {
|
|
276
276
|
const credentials = await oauthProvider.login(callbacks);
|
|
277
277
|
setOAuthCredentialsToCache(session.provider, credentials);
|
|
278
|
-
await new CredentialResolver().
|
|
279
|
-
access: oauthProvider.getApiKey(credentials),
|
|
280
|
-
refresh: credentials.refresh,
|
|
281
|
-
expiresAt: credentials.expires,
|
|
282
|
-
scope: Array.isArray(credentials.scope) ? credentials.scope.filter((value) => typeof value === "string") : void 0,
|
|
283
|
-
createdAt: (/* @__PURE__ */ new Date()).toISOString()
|
|
284
|
-
});
|
|
278
|
+
await new CredentialResolver().saveOAuthCredentials(session.provider, credentials);
|
|
285
279
|
session.status = "completed";
|
|
286
280
|
session.credentials = credentials;
|
|
287
281
|
session.message = "OAuth login successful";
|
|
@@ -74,13 +74,7 @@ function createOAuthHandler(_service) {
|
|
|
74
74
|
}
|
|
75
75
|
});
|
|
76
76
|
setOAuthCredentialsToCache(provider, credentials);
|
|
77
|
-
await new CredentialResolver().
|
|
78
|
-
access: oauthProvider.getApiKey(credentials),
|
|
79
|
-
refresh: credentials.refresh,
|
|
80
|
-
expiresAt: credentials.expires,
|
|
81
|
-
scope: Array.isArray(credentials.scope) ? credentials.scope.filter((value) => typeof value === "string") : void 0,
|
|
82
|
-
createdAt: (/* @__PURE__ */ new Date()).toISOString()
|
|
83
|
-
});
|
|
77
|
+
await new CredentialResolver().saveOAuthCredentials(provider, credentials);
|
|
84
78
|
return c.json({
|
|
85
79
|
ok: true,
|
|
86
80
|
payload: {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { ToolPolicySetSchema, init_schema } from "../../../agent-manifest/schema.js";
|
|
2
2
|
import { AgentModelsSchema, init_schema as init_schema$1 } from "../../../config/schema.js";
|
|
3
3
|
import { init_agent_scope, normalizeAgentId } from "../../../agent/agent-scope.js";
|
|
4
|
-
import { getVoiceModelsConfig } from "../../../config/voice.js";
|
|
5
4
|
import { deleteAgentAvatarFile, finalizeCreateAgentDirs, getGatewayAgentEffectiveManifest, listAgentProfileFiles, listGatewayAgents, prepareCreateAgent, prepareDeleteAgent, prepareUpdateAgent, readAgentAvatarFile, readAgentProfileFile, readUserProfileFile, runAfterDeletePurge, writeAgentAvatarFromBase64, writeAgentProfileFile, writeUserProfileFile } from "../../agents-admin.js";
|
|
5
|
+
import { getVoiceModelsConfig } from "../../../config/voice.js";
|
|
6
6
|
//#region src/gateway/hono/routes/agents.ts
|
|
7
7
|
init_schema$1();
|
|
8
8
|
init_schema();
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { ContextCompactionPolicySchema, init_config } from "../../../../user-context/config.js";
|
|
2
2
|
import { BindingsConfigSchema, BrowserConfigSchema, McpConfigSchema, VoiceConfigSchema, init_schema } from "../../../../config/schema.js";
|
|
3
3
|
import { CredentialResolver, init_credentials } from "../../../../auth/credentials.js";
|
|
4
|
-
import { canonicalizeConfiguredMcpServer } from "../../../../config/mcp-config-normalize.js";
|
|
5
4
|
import { setTuiDefaultAgentConfig } from "../../../../commands/agents.config.js";
|
|
5
|
+
import { mergeTunnelConfigPatch } from "../../../../tunnel/tunnel-config.js";
|
|
6
|
+
import { canonicalizeConfiguredMcpServer } from "../../../../config/mcp-config-normalize.js";
|
|
6
7
|
import { mergeGatewaySkillsMarketplacePatch, mergeGoalsConfigPatch, mergeSessionConfigPatch, mergeUpdateConfigPatch } from "../../../../config/web-patch.js";
|
|
7
8
|
import { assertGatewayAuthConfigured, resolveGatewayAuth } from "../../../auth.js";
|
|
8
9
|
import { isMaskedSecretPatchValue } from "../../lib/mask-secret-length.js";
|
|
9
10
|
import { applyToolsWebPatch } from "../../../config-tools-web.js";
|
|
10
|
-
import { mergeTunnelConfigPatch } from "../../../../tunnel/tunnel-config.js";
|
|
11
11
|
import { assertGatewayRuntimeConfig } from "../../../runtime-config.js";
|
|
12
12
|
import { mergeSttConfigPatch, mergeTtsConfigPatch } from "../../lib/safe-voice-config.js";
|
|
13
13
|
import { PATCH_OK, patchError } from "./result.js";
|