@xopcai/xopc 0.0.354 → 0.0.356
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/feishu/src/adapters/cli-login.js +3 -3
- package/dist/extensions/feishu/src/outbound/media-load.js +1 -1
- package/dist/extensions/telegram/src/inbound-processor.js +2 -2
- package/dist/extensions/telegram/src/outbound-sender.js +1 -1
- package/dist/extensions/telegram/src/plugin.js +2 -2
- package/dist/extensions/telegram/xopc.extension.json +1 -1
- package/dist/extensions/weixin/src/api/api.js +2 -2
- package/dist/extensions/weixin/src/auth/accounts.js +12 -12
- package/dist/extensions/weixin/src/messaging/debug-mode.js +5 -5
- package/dist/extensions/weixin/src/messaging/inbound.js +11 -11
- package/dist/gateway/static/root/assets/{activity-store-X7CG9pzB.js → activity-store-Bj0GuUUk.js} +1 -1
- package/dist/gateway/static/root/assets/{agent-avatar-dicebear-B8PS1eLP.js → agent-avatar-dicebear-i0dJX4Ag.js} +1 -1
- package/dist/gateway/static/root/assets/{agent-defaults-settings-panel-CLBSL9hl.js → agent-defaults-settings-panel-C-gsYOIi.js} +1 -1
- package/dist/gateway/static/root/assets/agent-plugin-dialog-D00xRE50.js +1 -0
- package/dist/gateway/static/root/assets/agents-Bg90PJpR.js +66 -0
- package/dist/gateway/static/root/assets/{agents-admin-api-Ck2x78jq.js → agents-admin-api-CYqmO7gb.js} +1 -1
- package/dist/gateway/static/root/assets/{app-management-settings-panel-COdQOmdT.js → app-management-settings-panel-LGezxe7p.js} +1 -1
- package/dist/gateway/static/root/assets/{appearance-settings-CDNjc2yy.js → appearance-settings-By7sj-tH.js} +1 -1
- package/dist/gateway/static/root/assets/{apps-page-C-kvpPj8.js → apps-page-DRX7wRpG.js} +1 -1
- package/dist/gateway/static/root/assets/{archive-plugin-QfOaQPL_.js → archive-plugin-BZHSbFiu.js} +1 -1
- package/dist/gateway/static/root/assets/{automations-page-87DN5nXX.js → automations-page-B5ZRVvra.js} +1 -1
- package/dist/gateway/static/root/assets/automations-workspace-CQmwjCm5.js +7 -0
- package/dist/gateway/static/root/assets/{binary-plugins-BF2lVwR9.js → binary-plugins-x2-RmzUs.js} +1 -1
- package/dist/gateway/static/root/assets/{block-editor-B04Kv5DU.js → block-editor-C8eM0IQi.js} +39 -39
- package/dist/gateway/static/root/assets/{browser-automation-inputs-FW3bYZ-z.js → browser-automation-inputs-uQ2AGFFU.js} +1 -1
- package/dist/gateway/static/root/assets/{browser-automations-page-Ck6Zb9aU.js → browser-automations-page-DonJaYJ7.js} +1 -1
- package/dist/gateway/static/root/assets/{browser-settings-page-DHlyYItE.js → browser-settings-page-Cku_iTDi.js} +2 -2
- package/dist/gateway/static/root/assets/{capabilities-CF4-mrIa.js → capabilities-Btku0cS3.js} +1 -1
- package/dist/gateway/static/root/assets/{capabilities-BCF_160Z.js → capabilities-Cl1RErL_.js} +1 -1
- package/dist/gateway/static/root/assets/capabilities-page-gUGN48Ob.js +2 -0
- package/dist/gateway/static/root/assets/capabilities-settings-panel-C3pM7xZ1.js +8 -0
- package/dist/gateway/static/root/assets/{capability-header-actions-PBPJJsp6.js → capability-header-actions-aXDBY-4S.js} +1 -1
- package/dist/gateway/static/root/assets/channels-BSbO91V4.js +1 -0
- package/dist/gateway/static/root/assets/{chat-terminal-dock-DTd7mWyE.js → chat-terminal-dock-Bn_O5W2o.js} +1 -1
- package/dist/gateway/static/root/assets/{computer-settings-page--9rh1mvu.js → computer-settings-page-CqzDwqcT.js} +1 -1
- package/dist/gateway/static/root/assets/{connector-service-page-v6Is0BOO.js → connector-service-page-BYq8YaSp.js} +1 -1
- package/dist/gateway/static/root/assets/connectors-page-CXVlZmoT.js +2 -0
- package/dist/gateway/static/root/assets/{date-picker-DTsMzjoZ.js → date-picker-dIJ4tP-C.js} +1 -1
- package/dist/gateway/static/root/assets/{dependency-picker-Y1QYCcLp.js → dependency-picker-ktHB4hRk.js} +1 -1
- package/dist/gateway/static/root/assets/{desktop-pet-D9dfZrOp.js → desktop-pet-BqXL3Ivw.js} +1 -1
- package/dist/gateway/static/root/assets/{desktop-pet-settings-BHVOHZUL.js → desktop-pet-settings-BspF0vWW.js} +1 -1
- package/dist/gateway/static/root/assets/device-pairing-wizard-CnADxQU1.js +1 -0
- package/dist/gateway/static/root/assets/{directory-picker-path-field-DeMo9KlE.js → directory-picker-path-field-CyR-4zZC.js} +1 -1
- package/dist/gateway/static/root/assets/dist-C3DSFZCi.js +1 -0
- package/dist/gateway/static/root/assets/{extension-debug-page-BrGWLJg9.js → extension-debug-page-DPc3vTw0.js} +1 -1
- package/dist/gateway/static/root/assets/{extension-page-AWrvy1Nb.js → extension-page-CWqtFuVa.js} +1 -1
- package/dist/gateway/static/root/assets/{extension-provider-CUpbXB2k.js → extension-provider-D-0AeFhE.js} +1 -1
- package/dist/gateway/static/root/assets/{extension-settings-page-C5KgmhYu.js → extension-settings-page-92wO2TEf.js} +1 -1
- package/dist/gateway/static/root/assets/{gateway-config-swr-B31I6Gbq.js → gateway-config-swr-Da3Oob_s.js} +1 -1
- package/dist/gateway/static/root/assets/{gateway-realtime-D6ffOiPe.js → gateway-realtime-BDh3i8n7.js} +1 -1
- package/dist/gateway/static/root/assets/gateway-realtime-store-B5Oq6VCQ.js +1 -0
- package/dist/gateway/static/root/assets/{gateway-settings-DC-lok0J.js → gateway-settings-CO_50TOx.js} +1 -1
- package/dist/gateway/static/root/assets/{gateway-startup-retry-DVol958v.js → gateway-startup-retry-BEj_bcbm.js} +1 -1
- package/dist/gateway/static/root/assets/home-page-Ba20kfpf.js +1 -0
- package/dist/gateway/static/root/assets/{image-generation-api-TVgJfz9r.js → image-generation-api-8jfU8AlD.js} +1 -1
- package/dist/gateway/static/root/assets/{imports-page-BKVKfVMA.js → imports-page-ciLLYJao.js} +1 -1
- package/dist/gateway/static/root/assets/index-DUgsBdV3.css +1 -0
- package/dist/gateway/static/root/assets/index-XgbDpmNc.js +106 -0
- package/dist/gateway/static/root/assets/{keyboard-shortcuts-settings-DiwE4gKU.js → keyboard-shortcuts-settings-7429mJN3.js} +1 -1
- package/dist/gateway/static/root/assets/{local-app-workbench-page-Dt3TC64L.js → local-app-workbench-page-CQyP9KBM.js} +1 -1
- package/dist/gateway/static/root/assets/{local-apps-page-DFPhWkxU.js → local-apps-page-Cht3NkYu.js} +1 -1
- package/dist/gateway/static/root/assets/{local-session-drafts-wiq_12oN.js → local-session-drafts-jOqfUlwj.js} +1 -1
- package/dist/gateway/static/root/assets/{locale-store-Y1aBayM_.js → locale-store-DodizOrj.js} +1 -1
- package/dist/gateway/static/root/assets/{logs-page-C4faHZHj.js → logs-page-Bye3bESN.js} +2 -2
- package/dist/gateway/static/root/assets/loopi-C09I2mNj.css +1 -0
- package/dist/gateway/static/root/assets/loopi-Djb8XU3l.js +1 -0
- package/dist/gateway/static/root/assets/{management-settings-pZLdvIiw.js → management-settings-BG2yeKtz.js} +1 -1
- package/dist/gateway/static/root/assets/{markdown-view-7tzqIp_G.js → markdown-view-Bb6ohqHz.js} +1 -1
- package/dist/gateway/static/root/assets/{media-plugins-cjgrKnne.js → media-plugins-DIhqKSK5.js} +1 -1
- package/dist/gateway/static/root/assets/messages-D8PmAUB-.js +3 -0
- package/dist/gateway/static/root/assets/models-hub-cache-CaYi043g.js +1 -0
- package/dist/gateway/static/root/assets/note-detail-panel-DA_6YKSN.js +5 -0
- package/dist/gateway/static/root/assets/{notes-api-J0yhflxC.js → notes-api-DYfvIxWh.js} +1 -1
- package/dist/gateway/static/root/assets/notes-page-kc3CMA5c.js +8 -0
- package/dist/gateway/static/root/assets/{oauth-api-CYe61zfD.js → oauth-api-gSu-iTk5.js} +1 -1
- package/dist/gateway/static/root/assets/{page-context-capture-button-CiBUm2Br.js → page-context-capture-button-r0vf-oBH.js} +1 -1
- package/dist/gateway/static/root/assets/personal-page-CmZzN99O.js +1 -0
- package/dist/gateway/static/root/assets/{popover-select-DcsFzD_i.js → popover-select-BNZZDJpO.js} +1 -1
- package/dist/gateway/static/root/assets/{product-open-page-B8_w6c3J.js → product-open-page-BdedC52J.js} +1 -1
- package/dist/gateway/static/root/assets/{project-detail-page-CDZdKiTz.js → project-detail-page-b23nMTcO.js} +1 -1
- package/dist/gateway/static/root/assets/{projects-page-BvahSrZi.js → projects-page-DCA7oEdB.js} +1 -1
- package/dist/gateway/static/root/assets/{registry-api-DqDOrPQ0.js → registry-api-D0eYNizR.js} +1 -1
- package/dist/gateway/static/root/assets/remote-access-hub-DeK3ATTQ.js +1 -0
- package/dist/gateway/static/root/assets/{runtime-tools-settings-panel-BnMS50vK.js → runtime-tools-settings-panel-BqD6oWU5.js} +1 -1
- package/dist/gateway/static/root/assets/{scenes-page-CDR1-q25.js → scenes-page-Ds6trhfL.js} +2 -2
- package/dist/gateway/static/root/assets/{schema-form-B4Xa8w8S.js → schema-form-D-cjcRAn.js} +1 -1
- package/dist/gateway/static/root/assets/{send-session-input-C7Nqy0sK.js → send-session-input-DstpmO44.js} +1 -1
- package/dist/gateway/static/root/assets/{session-api-CTN4qwiN.js → session-api-qy4gMa5t.js} +1 -1
- package/dist/gateway/static/root/assets/{session-manager-DsH1DZI_.js → session-manager-CFqOuGy-.js} +1 -1
- package/dist/gateway/static/root/assets/sessions-page-DltxWUQd.js +1 -0
- package/dist/gateway/static/root/assets/settings-advanced-gate-Bqg7glTa.js +1 -0
- package/dist/gateway/static/root/assets/{settings-page-CHZdpvkT.js → settings-page-BVfsQrWS.js} +1 -1
- package/dist/gateway/static/root/assets/{setup-status-panel-HESfALIF.js → setup-status-panel-DqkS3DKy.js} +1 -1
- package/dist/gateway/static/root/assets/{share-link-dialog-COlX10Dc.js → share-link-dialog-B3Io5mOY.js} +1 -1
- package/dist/gateway/static/root/assets/{share-preview-page-NtRLUieq.js → share-preview-page-BpZqXsgR.js} +1 -1
- package/dist/gateway/static/root/assets/{shares-api-DICV5EKH.js → shares-api-BNNaREyB.js} +1 -1
- package/dist/gateway/static/root/assets/shares-settings-CEaRXDeL.js +1 -0
- package/dist/gateway/static/root/assets/{skill-api-DYgcO7y0.js → skill-api-1Hp370EM.js} +1 -1
- package/dist/gateway/static/root/assets/{skill-reload-api-CWH3Fmx4.js → skill-reload-api-Dm6GgUYK.js} +1 -1
- package/dist/gateway/static/root/assets/skills-page-Cgze-HZy.js +2 -0
- package/dist/gateway/static/root/assets/{system-settings-panel-wXCBwYwE.js → system-settings-panel-CFSQ3Qjr.js} +1 -1
- package/dist/gateway/static/root/assets/task-detail-page-DEDh0FPJ.js +1 -0
- package/dist/gateway/static/root/assets/{theme-store-BKgBPLH4.js → theme-store-AXut7b8R.js} +1 -1
- package/dist/gateway/static/root/assets/{tunnel-api-C0t8y3Mi.js → tunnel-api-WcqOMVcQ.js} +1 -1
- package/dist/gateway/static/root/assets/{usage-page-A2DZAidl.js → usage-page-C6cnfavb.js} +1 -1
- package/dist/gateway/static/root/assets/{use-autosave-Cn6hqqyM.js → use-autosave-BT3l-ETP.js} +1 -1
- package/dist/gateway/static/root/assets/{use-composer-attachments-DL61XeSu.js → use-composer-attachments-zfL8zvRu.js} +1 -1
- package/dist/gateway/static/root/assets/{use-file-preview-expanded-Cl9mU32w.js → use-file-preview-expanded-C4bBXf4j.js} +2 -2
- package/dist/gateway/static/root/assets/user-model-page-C6_GMD0W.js +2 -0
- package/dist/gateway/static/root/assets/{voice-api-key-field-Bw05QB_V.js → voice-api-key-field-BF9hOZ_1.js} +1 -1
- package/dist/gateway/static/root/assets/voice-config-api-D8G4fALX.js +1 -0
- package/dist/gateway/static/root/assets/work-discovery-overlay-DVvqH1d-.js +1 -0
- package/dist/gateway/static/root/assets/{workflow-run-setup-panel-rM4U1FXc.js → workflow-run-setup-panel-MDkhjfGm.js} +2 -2
- package/dist/gateway/static/root/assets/{workflows-page-QKC34FzQ.js → workflows-page-Bhu13vVb.js} +3 -3
- package/dist/gateway/static/root/assets/{workspace-api-BbBT75Kg.js → workspace-api-C4q2GwGV.js} +2 -2
- package/dist/gateway/static/root/index.html +32 -30
- package/dist/package.js +1 -1
- package/dist/packages/realtime-protocol/src/voice-catalog.js +4 -1
- package/dist/src/agent/agent-manager.js +15 -15
- package/dist/src/agent/agent-scope.js +2 -2
- package/dist/src/agent/background-review/prompts.js +1 -1
- package/dist/src/agent/background-review/run-background-review.js +4 -4
- package/dist/src/agent/coding/repository-instructions.js +1 -1
- package/dist/src/agent/context/coordinator.js +2 -2
- package/dist/src/agent/context/execution-context.js +4 -4
- package/dist/src/agent/context/execution-scope.js +2 -2
- package/dist/src/agent/context/project-context.js +3 -3
- package/dist/src/agent/data-acquisition/service.js +1 -1
- package/dist/src/agent/embedded/index.js +2 -2
- package/dist/src/agent/embedded/model-runtime.js +1 -1
- package/dist/src/agent/embedded/run-for-session.d.ts +1 -0
- package/dist/src/agent/embedded/run-for-session.js +6 -5
- package/dist/src/agent/embedded/run-turn.js +24 -6
- package/dist/src/agent/embedded/session-tool-result-guard.js +3 -3
- package/dist/src/agent/embedded/tool-result-truncation.js +1 -1
- package/dist/src/agent/embedded/types.d.ts +1 -0
- package/dist/src/agent/external-tools/cliProvider.js +3 -3
- package/dist/src/agent/external-tools/composio-provider.js +3 -3
- package/dist/src/agent/external-tools/endpoint-provider.js +2 -2
- package/dist/src/agent/external-tools/gateway-tools.js +1 -1
- package/dist/src/agent/external-tools/mcp-provider.js +3 -3
- package/dist/src/agent/image/generation/openai-images-provider.js +1 -1
- package/dist/src/agent/image/generation/providers/dashscope.js +1 -1
- package/dist/src/agent/image/generation/providers/fal.js +1 -1
- package/dist/src/agent/image/generation/providers/google.js +1 -1
- package/dist/src/agent/image/generation/runtime.js +1 -1
- package/dist/src/agent/image/index.js +1 -1
- package/dist/src/agent/image/load-image-media.js +1 -1
- package/dist/src/agent/image/tool-model-config.js +2 -2
- package/dist/src/agent/inbound/attachment-pipeline.js +1 -1
- package/dist/src/agent/inbound/inbound-loop.js +2 -2
- package/dist/src/agent/index.js +1 -1
- package/dist/src/agent/mcp/bundle-mcp-config.js +1 -1
- package/dist/src/agent/mcp/bundle-mcp-gateway.js +1 -1
- package/dist/src/agent/mcp/bundle-mcp-runtime.js +2 -2
- package/dist/src/agent/mcp/index.js +2 -2
- package/dist/src/agent/mcp/mcp-stdio-transport.js +1 -1
- package/dist/src/agent/mcp/mcp-transport.js +1 -1
- package/dist/src/agent/mcp/oauth/mcp-oauth-manager.js +1 -1
- package/dist/src/agent/mcp/oauth/mcp-oauth-store.js +1 -1
- package/dist/src/agent/mcp/plugin-http-fetch.js +1 -1
- package/dist/src/agent/memory/context-recovery.js +1 -1
- package/dist/src/agent/memory/index.js +1 -1
- package/dist/src/agent/orchestration/agent-orchestrator.js +1 -1
- package/dist/src/agent/prompt/sections/messaging-runtime.js +2 -1
- package/dist/src/agent/prompt/service-prompt-builder.js +2 -2
- package/dist/src/agent/sandbox/exec-policy.js +1 -1
- package/dist/src/agent/service/direct-turn-helpers.d.ts +1 -0
- package/dist/src/agent/service/direct-turn-helpers.js +5 -4
- package/dist/src/agent/service/process-direct-one-shot.js +1 -1
- package/dist/src/agent/service/process-direct-streaming.js +6 -5
- package/dist/src/agent/service/webchat-tts.js +2 -2
- package/dist/src/agent/service.js +22 -22
- package/dist/src/agent/session/session-config-service.js +1 -1
- package/dist/src/agent/session/session-hydrator.js +1 -1
- package/dist/src/agent/session/session-inspector.js +1 -1
- package/dist/src/agent/skills/hub-lock.js +1 -1
- package/dist/src/agent/skills/index.js +1 -1
- package/dist/src/agent/skills/managed-store.js +1 -1
- package/dist/src/agent/skills/skill-manage-ops.js +1 -1
- package/dist/src/agent/source-context/index.js +2 -2
- package/dist/src/agent/tasks/task-judge-service.js +4 -4
- package/dist/src/agent/tools/create-share-tool.js +3 -3
- package/dist/src/agent/tools/dataBatch.js +1 -1
- package/dist/src/agent/tools/delegate-tool.js +3 -3
- package/dist/src/agent/tools/delegation-parent-policy.js +1 -1
- package/dist/src/agent/tools/executor.js +1 -1
- package/dist/src/agent/tools/factory.js +16 -16
- package/dist/src/agent/tools/fetch-text.js +1 -1
- package/dist/src/agent/tools/image-generate-tool.js +3 -3
- package/dist/src/agent/tools/index.js +6 -6
- package/dist/src/agent/tools/list-dir.js +1 -1
- package/dist/src/agent/tools/personal-preference-tool.d.ts +1 -1
- package/dist/src/agent/tools/personal-preference-tool.js +3 -2
- package/dist/src/agent/tools/personal-task-tool.d.ts +2 -1
- package/dist/src/agent/tools/personal-task-tool.js +27 -8
- package/dist/src/agent/tools/publish-artifacts.js +2 -2
- package/dist/src/agent/tools/read.js +2 -2
- package/dist/src/agent/tools/review-workspace.js +1 -1
- package/dist/src/agent/tools/send-media.js +2 -2
- package/dist/src/agent/tools/skills-tools.js +1 -1
- package/dist/src/agent/tools/tts-tool.js +1 -1
- package/dist/src/agent/tools/user-context-tool.js +1 -1
- package/dist/src/agent/tools/write.js +2 -2
- package/dist/src/agent/tools/xopc-use-tool.js +5 -5
- package/dist/src/agent/workflow/subagent-runner.js +1 -1
- package/dist/src/agent-catalog/capabilities.js +2 -2
- package/dist/src/agent-config/schema.d.ts +20 -1
- package/dist/src/agent-config/schema.js +7 -1
- package/dist/src/ai-assist/text-assist.js +1 -1
- package/dist/src/auth/credentials.js +2 -2
- package/dist/src/auth/oauth-provider-lock.js +1 -1
- package/dist/src/auth/profiles/store.js +1 -1
- package/dist/src/auth/sync-provider-auth.js +1 -1
- package/dist/src/automations/capabilities/drafts.js +1 -1
- package/dist/src/automations/domain/index.js +2 -2
- package/dist/src/automations/index.js +4 -4
- package/dist/src/automations/service/automation-service.js +2 -2
- package/dist/src/backup/archive.js +1 -1
- package/dist/src/bootstrap/application-state.js +1 -1
- package/dist/src/browser/native-messaging-host.js +1 -1
- package/dist/src/browser/providers/browser-ext-install.js +1 -1
- package/dist/src/capabilities/runtime/dispatcher.js +1 -1
- package/dist/src/capabilities/runtime/product.js +1 -1
- package/dist/src/channels/attachments/voice-stt-webchat.js +2 -2
- package/dist/src/channels/index.js +2 -2
- package/dist/src/channels/outbound-sender.js +1 -1
- package/dist/src/channels/pairing/allow-from-file.js +9 -9
- package/dist/src/channels/pairing/pairing-store.js +6 -6
- package/dist/src/chat-commands/agent-edit.js +1 -1
- package/dist/src/chat-commands/builtins/config.js +3 -3
- package/dist/src/chat-commands/builtins/review.js +1 -1
- package/dist/src/chat-commands/builtins/session.js +1 -1
- package/dist/src/chat-commands/builtins/thinking.js +1 -1
- package/dist/src/chat-commands/builtins/tts.js +1 -1
- package/dist/src/chat-commands/builtins/understanding.js +1 -1
- package/dist/src/chat-commands/builtins/workflow.js +2 -2
- package/dist/src/chat-commands/context.js +3 -3
- package/dist/src/chat-commands/index.js +3 -3
- package/dist/src/cli/commands/agent.js +7 -7
- package/dist/src/cli/commands/agents.js +1 -1
- package/dist/src/cli/commands/config.js +1 -1
- package/dist/src/cli/commands/connectors.js +1 -1
- package/dist/src/cli/commands/doctor/checks/channel-plugins.js +1 -1
- package/dist/src/cli/commands/doctor/checks/database-schema.js +1 -1
- package/dist/src/cli/commands/doctor/checks/gateway-health.js +1 -1
- package/dist/src/cli/commands/doctor/checks/provider-auth.js +2 -2
- package/dist/src/cli/commands/doctor/checks/tool-runtimes.js +1 -1
- package/dist/src/cli/commands/extension-agent-plugin.js +2 -2
- package/dist/src/cli/commands/extension-dev.js +1 -1
- package/dist/src/cli/commands/extension-marketplace.js +2 -2
- package/dist/src/cli/commands/extension.js +4 -4
- package/dist/src/cli/commands/gateway/shared.js +1 -1
- package/dist/src/cli/commands/gateway/token.js +1 -1
- package/dist/src/cli/commands/image.js +1 -1
- package/dist/src/cli/commands/init.js +1 -1
- package/dist/src/cli/commands/models.js +3 -3
- package/dist/src/cli/commands/onboard/channels/registry.js +1 -1
- package/dist/src/cli/commands/onboard/model.js +1 -1
- package/dist/src/cli/commands/onboard.js +1 -1
- package/dist/src/cli/commands/project.js +2 -2
- package/dist/src/cli/commands/runtime.js +1 -1
- package/dist/src/cli/commands/skills.js +2 -2
- package/dist/src/cli/commands/tunnel.js +4 -4
- package/dist/src/cli/extension-cli-register.js +5 -5
- package/dist/src/cli/utils/gateway-client.js +1 -1
- package/dist/src/cli/utils/init-workspace-core.js +2 -2
- package/dist/src/cli/utils/session.js +1 -1
- package/dist/src/computer/runtime.js +2 -2
- package/dist/src/config/index.js +8 -8
- package/dist/src/config/loader.js +2 -2
- package/dist/src/config/models-json.js +2 -2
- package/dist/src/config/schema.js +1 -1
- package/dist/src/connectors/cli/authorization.js +1 -1
- package/dist/src/connectors/cli/runtime.js +1 -1
- package/dist/src/connectors/composio-sessions.js +1 -1
- package/dist/src/connectors/composio.js +1 -1
- package/dist/src/connectors/connected-source-understanding.js +3 -3
- package/dist/src/connectors/connection-recovery-service.js +5 -5
- package/dist/src/connectors/health.js +1 -1
- package/dist/src/connectors/plugin-mcp-recovery.js +1 -1
- package/dist/src/discussions/live-worker.js +1 -1
- package/dist/src/discussions/recording.js +1 -1
- package/dist/src/discussions/sealer.js +1 -1
- package/dist/src/extensions/activation-context.js +3 -3
- package/dist/src/extensions/agent-plugins/validation.js +1 -1
- package/dist/src/extensions/api.js +4 -4
- package/dist/src/extensions/bundled-extension-activation.js +1 -1
- package/dist/src/extensions/index.js +3 -3
- package/dist/src/extensions/install.js +1 -1
- package/dist/src/extensions/loader.js +2 -2
- package/dist/src/extensions/lockfile.js +1 -1
- package/dist/src/extensions/sdk/index.js +1 -1
- package/dist/src/extensions/sdk/media.js +1 -1
- package/dist/src/extensions/update.js +1 -1
- package/dist/src/gateway/agents-admin.js +2 -2
- package/dist/src/gateway/device-routes.js +2 -2
- package/dist/src/gateway/file-path-classifier.js +2 -2
- package/dist/src/gateway/global-defaults-admin.js +1 -1
- package/dist/src/gateway/hono/app.js +3 -3
- package/dist/src/gateway/hono/lib/config-payload.js +4 -4
- package/dist/src/gateway/hono/routes/agents.js +1 -1
- package/dist/src/gateway/hono/routes/auth-registry-extensions.js +1 -1
- package/dist/src/gateway/hono/routes/browser.js +1 -1
- package/dist/src/gateway/hono/routes/commands-skills.js +4 -4
- package/dist/src/gateway/hono/routes/config-patch/gateway.js +1 -1
- package/dist/src/gateway/hono/routes/config-patch/misc.js +2 -2
- package/dist/src/gateway/hono/routes/home.js +1 -1
- package/dist/src/gateway/hono/routes/mcp.js +2 -2
- package/dist/src/gateway/hono/routes/media.js +1 -1
- package/dist/src/gateway/hono/routes/models.js +24 -6
- package/dist/src/gateway/hono/routes/notes.js +3 -3
- package/dist/src/gateway/hono/routes/personal-agent.js +135 -8
- package/dist/src/gateway/hono/routes/projects.js +4 -4
- package/dist/src/gateway/hono/routes/session-command-handler.js +1 -1
- package/dist/src/gateway/hono/routes/session-input-handler.js +4 -4
- package/dist/src/gateway/hono/routes/sessions.js +2 -2
- package/dist/src/gateway/hono/routes/shares.js +3 -3
- package/dist/src/gateway/hono/routes/side-chats.js +1 -1
- package/dist/src/gateway/hono/routes/site-shares.js +1 -1
- package/dist/src/gateway/hono/routes/tasks.js +2 -2
- package/dist/src/gateway/hono/routes/user-model-refresh.js +1 -1
- package/dist/src/gateway/hono/routes/user-model.js +5 -5
- package/dist/src/gateway/hono/routes/voice.js +33 -8
- package/dist/src/gateway/hono/routes/workflows.js +2 -2
- package/dist/src/gateway/image-generation-setup.js +3 -3
- package/dist/src/gateway/index.js +1 -1
- package/dist/src/gateway/lock.js +11 -11
- package/dist/src/gateway/media-access.js +1 -1
- package/dist/src/gateway/mobile-privacy.js +2 -2
- package/dist/src/gateway/ports.js +6 -6
- package/dist/src/gateway/run-loop.js +1 -1
- package/dist/src/gateway/scenes/mailContext.js +1 -1
- package/dist/src/gateway/scenes/slackThreadSource.js +1 -1
- package/dist/src/gateway/security/gateway-scopes.js +2 -0
- package/dist/src/gateway/server.js +1 -1
- package/dist/src/gateway/service/agent-runner.js +41 -0
- package/dist/src/gateway/service/config-coordinator.js +3 -3
- package/dist/src/gateway/service/run-gateway-agent.js +5 -4
- package/dist/src/gateway/service/session-command-service.js +2 -2
- package/dist/src/gateway/service/sessions-api.js +1 -1
- package/dist/src/gateway/service.js +49 -49
- package/dist/src/gateway/session-context-summary.js +2 -2
- package/dist/src/gateway/session-reset-service.js +1 -1
- package/dist/src/gateway/workspace-editor-path.js +2 -2
- package/dist/src/gateway/xopc-cloud-capability-setup.d.ts +11 -1
- package/dist/src/gateway/xopc-cloud-capability-setup.js +146 -10
- package/dist/src/gateway/xopc-cloud-onboarding.d.ts +3 -0
- package/dist/src/gateway/xopc-cloud-onboarding.js +27 -0
- package/dist/src/home-intelligence/generator.js +1 -1
- package/dist/src/home-intelligence/host.js +2 -2
- package/dist/src/infra/gateway-processes.js +2 -2
- package/dist/src/infra/path-env.js +3 -3
- package/dist/src/infra/update-global.js +10 -10
- package/dist/src/local-apps/service.js +2 -2
- package/dist/src/mcp/gateway-http-client.js +1 -1
- package/dist/src/media-understanding/openai-compatible-audio.js +1 -1
- package/dist/src/notes/agent-context.js +4 -4
- package/dist/src/notes/index.js +1 -1
- package/dist/src/notes/service.js +1 -1
- package/dist/src/notes/store.js +1 -1
- package/dist/src/personal-agent/onboarding.d.ts +27 -0
- package/dist/src/personal-agent/onboarding.js +48 -0
- package/dist/src/personal-agent/repository.d.ts +6 -1
- package/dist/src/personal-agent/repository.js +7 -2
- package/dist/src/personal-agent/service.d.ts +24 -6
- package/dist/src/personal-agent/service.js +38 -15
- package/dist/src/providers/auth-runtime/resolve-auth.js +1 -1
- package/dist/src/providers/index.js +2 -2
- package/dist/src/providers/model-catalog-persistence.js +2 -2
- package/dist/src/providers/model-reference-auditor.js +1 -1
- package/dist/src/providers/model-registry.js +1 -1
- package/dist/src/providers/register-runtime-providers.js +1 -1
- package/dist/src/remote-access/exposure-manager.js +1 -1
- package/dist/src/scenes/taskFollowUp/agentExecutor.js +4 -4
- package/dist/src/scenes/taskFollowUp/resources.js +1 -1
- package/dist/src/scenes/taskFollowUp/service.js +4 -4
- package/dist/src/session/index.js +2 -2
- package/dist/src/session/resolve-session.js +1 -1
- package/dist/src/session/session-title.js +1 -1
- package/dist/src/session/store.js +4 -4
- package/dist/src/session/thinking-resolve.js +1 -1
- package/dist/src/share/share-store.js +1 -1
- package/dist/src/share/share-thumbnail.js +1 -1
- package/dist/src/share/share-zip.js +1 -1
- package/dist/src/share/site-proxy.js +1 -1
- package/dist/src/share/site-share-store.js +1 -1
- package/dist/src/storage/sqlite/connection.js +9 -9
- package/dist/src/storage/sqlite/migrations/230_personal_agent_onboarding.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/schema.js +1 -1
- package/dist/src/tasks/capabilities/read.js +2 -2
- package/dist/src/tasks/capabilities/write.js +1 -1
- package/dist/src/tasks/execution-context.js +1 -1
- package/dist/src/tasks/home-query-service.js +3 -3
- package/dist/src/tasks/index.js +4 -4
- package/dist/src/tasks/task-application-service.js +3 -3
- package/dist/src/tasks/task-collaboration-delivery.js +1 -1
- package/dist/src/tasks/task-context-assembler.js +1 -1
- package/dist/src/tasks/task-handoff-service.js +1 -1
- package/dist/src/tasks/task-main-update-decision-service.js +1 -1
- package/dist/src/tasks/task-main-update-delivery.js +5 -2
- package/dist/src/tasks/task-origin-repository.d.ts +4 -1
- package/dist/src/tasks/task-origin-repository.js +3 -3
- package/dist/src/tasks/task-run-coordinator.d.ts +1 -0
- package/dist/src/tasks/task-run-coordinator.js +13 -7
- package/dist/src/tasks/task-run-dispatcher.d.ts +1 -1
- package/dist/src/tasks/task-run-dispatcher.js +6 -4
- package/dist/src/tui/backends/embedded-backend.js +12 -12
- package/dist/src/tui/backends/gateway-realtime-backend.js +1 -1
- package/dist/src/tui/extension-host/load-extensions.js +1 -1
- package/dist/src/tui/tui-command-formatters.js +1 -1
- package/dist/src/tui/tui-commands.js +8 -8
- package/dist/src/tui/tui-oauth-login.js +1 -1
- package/dist/src/tui/tui-picker-overlay.js +1 -1
- package/dist/src/tui/tui-skills-autocomplete.js +1 -1
- package/dist/src/tui/tui-startup-resources.js +4 -4
- package/dist/src/tui/tui.js +7 -7
- package/dist/src/tunnel/frpc-binary.js +1 -1
- package/dist/src/tunnel/gateway-lifecycle.js +1 -1
- package/dist/src/voice/language-profile.js +1 -1
- package/dist/src/voice/metadata/builtin.js +16 -39
- package/dist/src/voice/metadata/types.d.ts +2 -0
- package/dist/src/voice/platform-catalog.d.ts +3 -0
- package/dist/src/voice/realtime/memory-context.js +3 -3
- package/dist/src/voice/realtime/persona-context.js +1 -1
- package/dist/src/voice/realtime/runtime.js +19 -4
- package/dist/src/voice/stt/index.js +2 -2
- package/dist/src/voice/stt/preflight.js +1 -1
- package/dist/src/voice/stt/providers/alibaba-transcription.js +4 -4
- package/dist/src/voice/stt/providers/xopc-cloud-transcription.js +1 -1
- package/dist/src/voice/stt/transcribe-core.js +1 -1
- package/dist/src/voice/stt/types.js +1 -1
- package/dist/src/voice/tts/index.js +3 -3
- package/dist/src/voice/tts/merge-config.js +1 -1
- package/dist/src/voice/tts/payload.js +1 -1
- package/dist/src/voice/tts/providers/alibaba-speech.js +4 -16
- package/dist/src/voice/tts/providers/alibaba-voices.d.ts +3 -0
- package/dist/src/voice/tts/providers/alibaba-voices.js +197 -0
- package/dist/src/voice/tts/providers/xopc-cloud-speech.js +1 -1
- package/dist/src/voice/tts/speak-core.js +1 -1
- package/dist/src/voice/tts/speech-provider-types.d.ts +1 -0
- package/dist/src/voice/tts/types.js +1 -1
- package/dist/src/work-discovery/incremental-repository.js +1 -1
- package/dist/src/work-discovery/index.js +1 -1
- package/dist/src/work-discovery/service.js +5 -5
- package/dist/src/workflows/engine/workflow-engine.js +1 -1
- package/dist/src/workflows/service/workflow-run-service.js +8 -8
- package/dist/src/workflows/service/workflow-session-bridge.js +1 -1
- package/package.json +4 -4
- package/dist/gateway/static/root/assets/agent-plugin-dialog-BninweSg.js +0 -1
- package/dist/gateway/static/root/assets/agents-CcVLP_WP.js +0 -66
- package/dist/gateway/static/root/assets/automations-workspace-BdZ8NO8k.js +0 -7
- package/dist/gateway/static/root/assets/capabilities-page-C-6RLFNh.js +0 -2
- package/dist/gateway/static/root/assets/capabilities-settings-panel-CST_HBkR.js +0 -8
- package/dist/gateway/static/root/assets/channels-CM4sIvcP.js +0 -1
- package/dist/gateway/static/root/assets/connectors-page-CryQzmEZ.js +0 -2
- package/dist/gateway/static/root/assets/device-pairing-wizard-Cy5YDZ2b.js +0 -1
- package/dist/gateway/static/root/assets/dist-3h6cXXhT.js +0 -1
- package/dist/gateway/static/root/assets/gateway-realtime-store-DQuFWNjA.js +0 -1
- package/dist/gateway/static/root/assets/home-page-C29_VFAs.js +0 -1
- package/dist/gateway/static/root/assets/index-BJh5gU04.css +0 -1
- package/dist/gateway/static/root/assets/index-ByFXhQ-T.js +0 -107
- package/dist/gateway/static/root/assets/messages-DPw2X06D.js +0 -3
- package/dist/gateway/static/root/assets/models-hub-cache-HGrORbzR.js +0 -1
- package/dist/gateway/static/root/assets/note-detail-panel-BLnT1tYJ.js +0 -5
- package/dist/gateway/static/root/assets/notes-page-BawArJvP.js +0 -8
- package/dist/gateway/static/root/assets/personal-page-Cng583RH.js +0 -1
- package/dist/gateway/static/root/assets/remote-access-hub-CU_UdkuI.js +0 -1
- package/dist/gateway/static/root/assets/sessions-page-Ymyg98G-.js +0 -1
- package/dist/gateway/static/root/assets/settings-advanced-gate-wMZhxwTM.js +0 -1
- package/dist/gateway/static/root/assets/shares-settings-CXEBo5YL.js +0 -1
- package/dist/gateway/static/root/assets/skills-page-Dx5v64jU.js +0 -2
- package/dist/gateway/static/root/assets/task-detail-page-hoIyr7tp.js +0 -1
- package/dist/gateway/static/root/assets/user-model-page-C1jGTwjK.js +0 -2
- package/dist/gateway/static/root/assets/voice-config-api-BM75K3mR.js +0 -1
- package/dist/gateway/static/root/assets/work-discovery-overlay-xB0QpOFk.js +0 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { registerMediaUnderstandingProvider } from "./registry.js";
|
|
2
1
|
import { normalizeBaseUrl, postMultipartRequest } from "../media-shared/http/provider-http.js";
|
|
3
2
|
import "../media-shared/http/index.js";
|
|
3
|
+
import { registerMediaUnderstandingProvider } from "./registry.js";
|
|
4
4
|
import path from "node:path";
|
|
5
5
|
//#region src/media-understanding/openai-compatible-audio.ts
|
|
6
6
|
/**
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { getNoteAgentContextRecord, upsertNoteAgentContextRecord } from "../storage/sqlite/note-agent-context-repository.js";
|
|
2
2
|
import { init_sqlite } from "../storage/sqlite/index.js";
|
|
3
|
-
import { resolveImageModelConfigForTool } from "../agent/image/tool-model-config.js";
|
|
4
|
-
import { describeImagesWithFallback } from "../agent/image/understanding/runtime.js";
|
|
5
|
-
import { extractDocumentText } from "../document-understanding/extract.js";
|
|
6
|
-
import { transcribe } from "../voice/stt/transcribe-core.js";
|
|
7
3
|
import { isSTTAvailable } from "../voice/stt/availability.js";
|
|
4
|
+
import { transcribe } from "../voice/stt/transcribe-core.js";
|
|
8
5
|
import { mergeSttConfigFromAppConfig } from "../voice/stt/config.js";
|
|
9
6
|
import "../voice/stt/index.js";
|
|
7
|
+
import { extractDocumentText } from "../document-understanding/extract.js";
|
|
8
|
+
import { resolveImageModelConfigForTool } from "../agent/image/tool-model-config.js";
|
|
9
|
+
import { describeImagesWithFallback } from "../agent/image/understanding/runtime.js";
|
|
10
10
|
import { extname } from "node:path";
|
|
11
11
|
import { readFile } from "node:fs/promises";
|
|
12
12
|
//#region src/notes/agent-context.ts
|
package/dist/src/notes/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { buildNoteAgentContext, buildNoteAgentContextArtifact, getCachedNoteAgentContextArtifact } from "./agent-context.js";
|
|
2
1
|
import { resolveNoteMediaDir, resolveNotesDir } from "./paths.js";
|
|
2
|
+
import { buildNoteAgentContext, buildNoteAgentContextArtifact, getCachedNoteAgentContextArtifact } from "./agent-context.js";
|
|
3
3
|
import { NotesStore } from "./store.js";
|
|
4
4
|
import { NotesService } from "./service.js";
|
|
5
5
|
export { NotesService, NotesStore, buildNoteAgentContext, buildNoteAgentContextArtifact, getCachedNoteAgentContextArtifact, resolveNoteMediaDir, resolveNotesDir };
|
|
@@ -7,8 +7,8 @@ import { init_note_markdown, parseNoteMarkdown } from "./note-markdown.js";
|
|
|
7
7
|
import { init_notes_repository, listNoteProjectSummaries } from "../storage/sqlite/notes-repository.js";
|
|
8
8
|
import { changedFieldsFromPatch, emitActivity, previewText, systemActivityActor, systemActivitySource } from "../activity/emitter.js";
|
|
9
9
|
import { getDefaultModelSync, init_providers, resolveModel } from "../providers/index.js";
|
|
10
|
-
import { DomainOutboxDispatcher } from "../infra/domain-outbox-dispatcher.js";
|
|
11
10
|
import { completeWithResolvedCredentials } from "../providers/model-call.js";
|
|
11
|
+
import { DomainOutboxDispatcher } from "../infra/domain-outbox-dispatcher.js";
|
|
12
12
|
import { partitionAttachmentsByReference } from "./note-attachment-sync.js";
|
|
13
13
|
import { buildNoteAgentContextArtifact, getCachedNoteAgentContextArtifact } from "./agent-context.js";
|
|
14
14
|
import { revokeNoteShareRecords } from "../share/note-share-revocation.js";
|
package/dist/src/notes/store.js
CHANGED
|
@@ -7,8 +7,8 @@ import { buildNoteIndexMeta, init_note_index_meta } from "./note-index-meta.js";
|
|
|
7
7
|
import { deleteNoteRecord, getNoteRecord, listNoteRecords, upsertNoteRecord } from "../storage/sqlite/notes-repository.js";
|
|
8
8
|
import { deleteNoteAgentContextRecord } from "../storage/sqlite/note-agent-context-repository.js";
|
|
9
9
|
import { init_sqlite } from "../storage/sqlite/index.js";
|
|
10
|
-
import { canRemoveRevokedNoteShareArtifact } from "../share/note-share-revocation.js";
|
|
11
10
|
import { resolveNoteMediaDir } from "./paths.js";
|
|
11
|
+
import { canRemoveRevokedNoteShareArtifact } from "../share/note-share-revocation.js";
|
|
12
12
|
import { basename, join } from "node:path";
|
|
13
13
|
import { rmSync } from "node:fs";
|
|
14
14
|
import { randomUUID } from "node:crypto";
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const PersonalOnboardingStepSchema: z.ZodEnum<{
|
|
3
|
+
voice: "voice";
|
|
4
|
+
identity: "identity";
|
|
5
|
+
connections: "connections";
|
|
6
|
+
intro: "intro";
|
|
7
|
+
}>;
|
|
8
|
+
export declare const PersonalOnboardingDraftSchema: z.ZodObject<{
|
|
9
|
+
displayName: z.ZodDefault<z.ZodString>;
|
|
10
|
+
appearance: z.ZodDefault<z.ZodEnum<{
|
|
11
|
+
loopi: "loopi";
|
|
12
|
+
"loopi-curious": "loopi-curious";
|
|
13
|
+
"loopi-care": "loopi-care";
|
|
14
|
+
}>>;
|
|
15
|
+
voice: z.ZodDefault<z.ZodNullable<z.ZodString>>;
|
|
16
|
+
}, z.core.$strict>;
|
|
17
|
+
export type PersonalOnboardingDraft = z.infer<typeof PersonalOnboardingDraftSchema>;
|
|
18
|
+
export type PersonalOnboardingStep = z.infer<typeof PersonalOnboardingStepSchema>;
|
|
19
|
+
export declare function getPersonalOnboarding(ownerId: string): {
|
|
20
|
+
step: PersonalOnboardingStep;
|
|
21
|
+
draft: PersonalOnboardingDraft;
|
|
22
|
+
completed: boolean;
|
|
23
|
+
welcomeDone: boolean;
|
|
24
|
+
};
|
|
25
|
+
export declare function savePersonalOnboarding(ownerId: string, step: PersonalOnboardingStep, draft: PersonalOnboardingDraft): void;
|
|
26
|
+
export declare function completePersonalOnboarding(ownerId: string): void;
|
|
27
|
+
export declare function finishPersonalWelcome(ownerId: string): void;
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { getSqliteDatabase, init_transaction } from "../storage/sqlite/transaction.js";
|
|
2
|
+
import { z } from "zod";
|
|
3
|
+
//#region src/personal-agent/onboarding.ts
|
|
4
|
+
init_transaction();
|
|
5
|
+
const PersonalOnboardingStepSchema = z.enum([
|
|
6
|
+
"intro",
|
|
7
|
+
"identity",
|
|
8
|
+
"voice",
|
|
9
|
+
"connections"
|
|
10
|
+
]);
|
|
11
|
+
const PersonalOnboardingDraftSchema = z.object({
|
|
12
|
+
displayName: z.string().trim().min(1).max(60).default("Ada"),
|
|
13
|
+
appearance: z.enum([
|
|
14
|
+
"loopi",
|
|
15
|
+
"loopi-curious",
|
|
16
|
+
"loopi-care"
|
|
17
|
+
]).default("loopi"),
|
|
18
|
+
voice: z.string().trim().min(1).max(200).nullable().default(null)
|
|
19
|
+
}).strict();
|
|
20
|
+
function getPersonalOnboarding(ownerId) {
|
|
21
|
+
const row = getSqliteDatabase().prepare(`SELECT step, draft_json, completed_at, welcome_finished_at
|
|
22
|
+
FROM personal_agent_onboarding WHERE owner_id = ?`).get(ownerId);
|
|
23
|
+
return {
|
|
24
|
+
step: PersonalOnboardingStepSchema.safeParse(row?.step).data ?? "intro",
|
|
25
|
+
draft: PersonalOnboardingDraftSchema.parse(row ? JSON.parse(row.draft_json) : {}),
|
|
26
|
+
completed: row?.completed_at != null,
|
|
27
|
+
welcomeDone: row?.welcome_finished_at != null
|
|
28
|
+
};
|
|
29
|
+
}
|
|
30
|
+
function savePersonalOnboarding(ownerId, step, draft) {
|
|
31
|
+
getSqliteDatabase().prepare(`INSERT INTO personal_agent_onboarding
|
|
32
|
+
(owner_id, step, draft_json, completed_at, updated_at) VALUES (?, ?, ?, NULL, ?)
|
|
33
|
+
ON CONFLICT(owner_id) DO UPDATE SET step = excluded.step, draft_json = excluded.draft_json,
|
|
34
|
+
updated_at = excluded.updated_at WHERE completed_at IS NULL`).run(ownerId, step, JSON.stringify(draft), Date.now());
|
|
35
|
+
}
|
|
36
|
+
function completePersonalOnboarding(ownerId) {
|
|
37
|
+
const now = Date.now();
|
|
38
|
+
getSqliteDatabase().prepare(`INSERT INTO personal_agent_onboarding
|
|
39
|
+
(owner_id, step, draft_json, completed_at, updated_at) VALUES (?, 'connections', '{}', ?, ?)
|
|
40
|
+
ON CONFLICT(owner_id) DO UPDATE SET completed_at = COALESCE(completed_at, excluded.completed_at),
|
|
41
|
+
updated_at = excluded.updated_at`).run(ownerId, now, now);
|
|
42
|
+
}
|
|
43
|
+
function finishPersonalWelcome(ownerId) {
|
|
44
|
+
getSqliteDatabase().prepare(`UPDATE personal_agent_onboarding
|
|
45
|
+
SET welcome_finished_at = COALESCE(welcome_finished_at, ?), updated_at = ? WHERE owner_id = ?`).run(Date.now(), Date.now(), ownerId);
|
|
46
|
+
}
|
|
47
|
+
//#endregion
|
|
48
|
+
export { PersonalOnboardingDraftSchema, PersonalOnboardingStepSchema, completePersonalOnboarding, finishPersonalWelcome, getPersonalOnboarding, savePersonalOnboarding };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export type PersonalAgentState = 'provisioning' | 'ready' | 'error';
|
|
2
|
-
export type PersonalAppearance = '
|
|
2
|
+
export type PersonalAppearance = 'loopi' | 'loopi-curious' | 'loopi-care' | 'custom';
|
|
3
3
|
export interface PersonalAgentRecord {
|
|
4
4
|
ownerId: string;
|
|
5
5
|
agentId: string;
|
|
@@ -7,6 +7,11 @@ export interface PersonalAgentRecord {
|
|
|
7
7
|
state: PersonalAgentState;
|
|
8
8
|
displayName: string;
|
|
9
9
|
appearance: PersonalAppearance;
|
|
10
|
+
voicePreference: {
|
|
11
|
+
provider: string;
|
|
12
|
+
model: string;
|
|
13
|
+
voice: string;
|
|
14
|
+
} | null;
|
|
10
15
|
preferences: Record<string, unknown>;
|
|
11
16
|
revision: number;
|
|
12
17
|
errorMessage: string | null;
|
|
@@ -29,7 +29,11 @@ function personalSession(column, value) {
|
|
|
29
29
|
ORDER BY created_at LIMIT 1`).get(value) ?? null;
|
|
30
30
|
}
|
|
31
31
|
function appearanceFrom(agent) {
|
|
32
|
-
|
|
32
|
+
const avatar = agent.profile?.avatar;
|
|
33
|
+
if (avatar === "xopc:custom") return "custom";
|
|
34
|
+
if (avatar === "xopc:loopi:curious" || avatar === "xopc:loopi:listen" || !avatar && agent.profile?.emoji === "☁") return "loopi-curious";
|
|
35
|
+
if (avatar === "xopc:loopi:care" || !avatar && agent.profile?.emoji === "◕") return "loopi-care";
|
|
36
|
+
return "loopi";
|
|
33
37
|
}
|
|
34
38
|
function toRecord(ownerId, agent, session) {
|
|
35
39
|
const config = session ? getSessionConfig(session.conversation_id) : null;
|
|
@@ -39,8 +43,9 @@ function toRecord(ownerId, agent, session) {
|
|
|
39
43
|
agentId: agent.id,
|
|
40
44
|
conversationId: session?.conversation_id ?? personalConversationId(ownerId),
|
|
41
45
|
state: agent.provisioningState === "error" ? "error" : ready ? "ready" : "provisioning",
|
|
42
|
-
displayName: agent.profile?.name ?? "
|
|
46
|
+
displayName: agent.profile?.name ?? "Ada",
|
|
43
47
|
appearance: appearanceFrom(agent),
|
|
48
|
+
voicePreference: agent.profile?.voicePreference ?? null,
|
|
44
49
|
preferences: agent.profile?.responsePreferences ?? DEFAULT_PERSONAL_PREFERENCES,
|
|
45
50
|
revision: agent.revision,
|
|
46
51
|
errorMessage: agent.provisioningError ?? null
|
|
@@ -3,6 +3,7 @@ import type { GatewayService } from '../gateway/service.js';
|
|
|
3
3
|
import { type PersonalAgentRecord } from './repository.js';
|
|
4
4
|
export declare const PersonalPreferencesSchema: z.ZodObject<{
|
|
5
5
|
addressAs: z.ZodOptional<z.ZodString>;
|
|
6
|
+
guidance: z.ZodOptional<z.ZodString>;
|
|
6
7
|
warmth: z.ZodOptional<z.ZodEnum<{
|
|
7
8
|
balanced: "balanced";
|
|
8
9
|
reserved: "reserved";
|
|
@@ -31,9 +32,10 @@ export declare const PersonalPreferencesSchema: z.ZodObject<{
|
|
|
31
32
|
}, z.core.$strict>;
|
|
32
33
|
export type PersonalPreferences = z.infer<typeof PersonalPreferencesSchema>;
|
|
33
34
|
export declare const PersonalAppearanceSchema: z.ZodEnum<{
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
35
|
+
custom: "custom";
|
|
36
|
+
loopi: "loopi";
|
|
37
|
+
"loopi-curious": "loopi-curious";
|
|
38
|
+
"loopi-care": "loopi-care";
|
|
37
39
|
}>;
|
|
38
40
|
export type PersonalAppearance = z.infer<typeof PersonalAppearanceSchema>;
|
|
39
41
|
export declare function personalInstructions(preferences: PersonalPreferences): string;
|
|
@@ -43,6 +45,22 @@ export declare function listPersonalModels(): Promise<Array<{
|
|
|
43
45
|
name: string;
|
|
44
46
|
}>>;
|
|
45
47
|
export declare function ensurePersonalConversationVisibility(ownerId: string): void;
|
|
46
|
-
export declare function createOrResumePersonalAgent(service: GatewayService, ownerId: string, requestedModel?: string, availableModels?: typeof listPersonalModels
|
|
47
|
-
|
|
48
|
-
|
|
48
|
+
export declare function createOrResumePersonalAgent(service: GatewayService, ownerId: string, requestedModel?: string, availableModels?: typeof listPersonalModels, initial?: {
|
|
49
|
+
displayName: string;
|
|
50
|
+
appearance: Exclude<PersonalAppearance, 'custom'>;
|
|
51
|
+
voicePreference?: {
|
|
52
|
+
provider: string;
|
|
53
|
+
model: string;
|
|
54
|
+
voice: string;
|
|
55
|
+
};
|
|
56
|
+
}): Promise<PersonalAgentRecord>;
|
|
57
|
+
export declare function patchPersonalProfile(service: GatewayService, ownerId: string, revision: number, displayName: string, preferences: PersonalPreferences, appearance: PersonalAppearance, voicePreference?: {
|
|
58
|
+
provider: string;
|
|
59
|
+
model: string;
|
|
60
|
+
voice: string;
|
|
61
|
+
} | null): Promise<PersonalAgentRecord | null>;
|
|
62
|
+
export declare function updatePersonalProfileRecord(ownerId: string, revision: number, displayName: string, preferences: PersonalPreferences, appearance: PersonalAppearance, voicePreference?: {
|
|
63
|
+
provider: string;
|
|
64
|
+
model: string;
|
|
65
|
+
voice: string;
|
|
66
|
+
} | null): Promise<PersonalAgentRecord | null>;
|
|
@@ -4,12 +4,13 @@ import { init_config_repository, setSessionConfig } from "../storage/sqlite/conf
|
|
|
4
4
|
import { ResponsePreferencesSchema } from "../agent-config/schema.js";
|
|
5
5
|
import { init_agent_config } from "../agent-config/index.js";
|
|
6
6
|
import { AgentCatalogRepository, init_repository } from "../agent-catalog/repository.js";
|
|
7
|
+
import { AgentCatalogService } from "../agent-catalog/service.js";
|
|
7
8
|
import { createConversation, init_conversation_repository } from "../storage/sqlite/conversation-repository.js";
|
|
8
9
|
import { getAvailableModels, init_providers } from "../providers/index.js";
|
|
9
|
-
import { getModelThinking } from "../providers/model-thinking.js";
|
|
10
|
-
import { AgentCatalogService } from "../agent-catalog/service.js";
|
|
11
10
|
import { DEFAULT_PERSONAL_PREFERENCES, getPersonalAgent, personalAgentId } from "./repository.js";
|
|
11
|
+
import { getModelThinking } from "../providers/model-thinking.js";
|
|
12
12
|
import { PERSONAL_MAIN_TOOL_IDS } from "./policy.js";
|
|
13
|
+
import { completePersonalOnboarding } from "./onboarding.js";
|
|
13
14
|
import { z } from "zod";
|
|
14
15
|
//#region src/personal-agent/service.ts
|
|
15
16
|
init_agent_config();
|
|
@@ -20,12 +21,16 @@ init_session_repository();
|
|
|
20
21
|
init_config_repository();
|
|
21
22
|
const PersonalPreferencesSchema = ResponsePreferencesSchema;
|
|
22
23
|
const PersonalAppearanceSchema = z.enum([
|
|
23
|
-
"
|
|
24
|
-
"
|
|
25
|
-
"
|
|
24
|
+
"loopi",
|
|
25
|
+
"loopi-curious",
|
|
26
|
+
"loopi-care",
|
|
27
|
+
"custom"
|
|
26
28
|
]);
|
|
27
29
|
function appearanceEmoji(appearance) {
|
|
28
|
-
return appearance === "
|
|
30
|
+
return appearance === "loopi-curious" ? "◌" : appearance === "loopi-care" ? "♡" : "◉";
|
|
31
|
+
}
|
|
32
|
+
function appearanceAvatar(appearance) {
|
|
33
|
+
return appearance === "custom" ? "xopc:custom" : `xopc:loopi:${appearance === "loopi" ? "idle" : appearance.slice(6)}`;
|
|
29
34
|
}
|
|
30
35
|
const LEGACY_DELEGATION_RULE = "Answer simple requests directly. For complex work, use personal_task agents to find a suitable specialist, then create a Task and remain available to talk. Never claim a task was created before the tool confirms it.";
|
|
31
36
|
const PREVIOUS_DELEGATION_RULES = [
|
|
@@ -33,9 +38,16 @@ const PREVIOUS_DELEGATION_RULES = [
|
|
|
33
38
|
"For current news, delegate to an Agent with web_search. Include the requested date or time window and topic in the brief; require source links, publication dates, and a distinction between confirmed news and uncertain reports. Tell the user briefly that you are checking. Stay available while the Task runs, then summarize verified results in their preferred style.",
|
|
34
39
|
"If no suitable Agent is available, explain the specific missing capability and offer the next useful option. Never claim a Task was created before the tool confirms it."
|
|
35
40
|
].join("\n");
|
|
41
|
+
const PRIOR_DELEGATION_RULES = [
|
|
42
|
+
"Own the user’s request through completion. If you cannot reliably do it yourself because of missing tools, access, knowledge, time, or specialist judgment, first call personal_task(command=\"agents\"). Match the request to another Agent’s description and availableTools, then create a Task for a plausible candidate. This applies to short requests too. Your own limitation is not a system limitation. Do not stop at “I cannot” or ask the user to switch models or do your work before checking Agents.",
|
|
43
|
+
"If the chosen Agent or tool cannot complete the Task, inspect the actual blocker and try another suitable Agent or a reasonable alternative within the user’s authorization. Do not repeat the same failed approach indefinitely. Ask the user only for a decision, access, or information that no available Agent can supply. Explain a concrete blocker only after checking the available paths; never imply that an untried path was attempted.",
|
|
44
|
+
"For current news or other live facts, find an Agent with web_search and require dated sources. For coding, analysis, writing, media, or connected-app work, choose by the Agent’s role and tools rather than a fixed name. Give the Task a short title and a complete Markdown brief. After Task creation succeeds, tell the user briefly what is happening, stay available, and summarize verified outcomes in their preferred style.",
|
|
45
|
+
"Never claim a Task was created or completed before its tool result confirms that state. Respect the user’s authorization and the selected Agent’s permissions."
|
|
46
|
+
].join("\n");
|
|
36
47
|
const DELEGATION_RULES = [
|
|
37
48
|
"Own the user’s request through completion. If you cannot reliably do it yourself because of missing tools, access, knowledge, time, or specialist judgment, first call personal_task(command=\"agents\"). Match the request to another Agent’s description and availableTools, then create a Task for a plausible candidate. This applies to short requests too. Your own limitation is not a system limitation. Do not stop at “I cannot” or ask the user to switch models or do your work before checking Agents.",
|
|
38
49
|
"If the chosen Agent or tool cannot complete the Task, inspect the actual blocker and try another suitable Agent or a reasonable alternative within the user’s authorization. Do not repeat the same failed approach indefinitely. Ask the user only for a decision, access, or information that no available Agent can supply. Explain a concrete blocker only after checking the available paths; never imply that an untried path was attempted.",
|
|
50
|
+
"A worker question is yours to resolve first. Read the Task brief and earlier conversation; when the answer is already there, call personal_task(command=\"answer\", taskId=..., questionId=..., instruction=...) so the worker resumes. Ask the user only when the missing fact cannot be found. Once the user asks you to complete a task, retrying a suitable alternative Agent is already authorized; do not ask permission to try again.",
|
|
39
51
|
"For current news or other live facts, find an Agent with web_search and require dated sources. For coding, analysis, writing, media, or connected-app work, choose by the Agent’s role and tools rather than a fixed name. Give the Task a short title and a complete Markdown brief. After Task creation succeeds, tell the user briefly what is happening, stay available, and summarize verified outcomes in their preferred style.",
|
|
40
52
|
"Never claim a Task was created or completed before its tool result confirms that state. Respect the user’s authorization and the selected Agent’s permissions."
|
|
41
53
|
];
|
|
@@ -48,6 +60,7 @@ function personalInstructions(preferences) {
|
|
|
48
60
|
"Give the accurate answer or next step in the order this user prefers. Acknowledge feelings only when relevant, without guessing how the user feels. Avoid formulaic reassurance, praise, pet names, emojis, or jokes unless the user welcomes them and the moment fits. Be accurate about task state, evidence, and uncertainty."
|
|
49
61
|
];
|
|
50
62
|
if (preferences.addressAs) rules.push(`Address the user as ${JSON.stringify(preferences.addressAs)} when a name fits naturally.`);
|
|
63
|
+
if (preferences.guidance) rules.push(`User's explicit response preference: ${JSON.stringify(preferences.guidance)}. Follow it when relevant, subject to accuracy and the current request.`);
|
|
51
64
|
if (preferences.warmth) rules.push({
|
|
52
65
|
reserved: "Tone: calm and direct; skip emotional preambles.",
|
|
53
66
|
balanced: "Tone: friendly and natural.",
|
|
@@ -79,7 +92,11 @@ async function refreshPersonalDelegationGuidance(service, ownerId) {
|
|
|
79
92
|
const agent = new AgentCatalogRepository().get(personalAgentId(ownerId));
|
|
80
93
|
const instructions = agent?.profile?.instructions;
|
|
81
94
|
if (!agent || !instructions) return;
|
|
82
|
-
const oldRule =
|
|
95
|
+
const oldRule = [
|
|
96
|
+
PRIOR_DELEGATION_RULES,
|
|
97
|
+
PREVIOUS_DELEGATION_RULES,
|
|
98
|
+
LEGACY_DELEGATION_RULE
|
|
99
|
+
].find((rule) => instructions.includes(rule));
|
|
83
100
|
if (!oldRule) return;
|
|
84
101
|
try {
|
|
85
102
|
await new AgentCatalogService().update(agent.id, { profile: {
|
|
@@ -113,19 +130,20 @@ function ensurePersonalConversationVisibility(ownerId) {
|
|
|
113
130
|
}
|
|
114
131
|
});
|
|
115
132
|
}
|
|
116
|
-
function createOrResumePersonalAgent(service, ownerId, requestedModel, availableModels = listPersonalModels) {
|
|
133
|
+
function createOrResumePersonalAgent(service, ownerId, requestedModel, availableModels = listPersonalModels, initial) {
|
|
117
134
|
const current = inFlightProvisioning.get(ownerId);
|
|
118
135
|
if (current) return current;
|
|
119
|
-
const pending = provisionPersonalAgent(service, ownerId, requestedModel, availableModels);
|
|
136
|
+
const pending = provisionPersonalAgent(service, ownerId, requestedModel, availableModels, initial);
|
|
120
137
|
inFlightProvisioning.set(ownerId, pending);
|
|
121
138
|
pending.finally(() => {
|
|
122
139
|
if (inFlightProvisioning.get(ownerId) === pending) inFlightProvisioning.delete(ownerId);
|
|
123
140
|
}).catch(() => {});
|
|
124
141
|
return pending;
|
|
125
142
|
}
|
|
126
|
-
async function provisionPersonalAgent(service, ownerId, requestedModel, availableModels = listPersonalModels) {
|
|
143
|
+
async function provisionPersonalAgent(service, ownerId, requestedModel, availableModels = listPersonalModels, initial) {
|
|
127
144
|
const existingIdentity = getPersonalAgent(ownerId);
|
|
128
145
|
if (existingIdentity?.state === "ready") {
|
|
146
|
+
completePersonalOnboarding(ownerId);
|
|
129
147
|
await refreshPersonalDelegationGuidance(service, ownerId);
|
|
130
148
|
ensurePersonalConversationVisibility(ownerId);
|
|
131
149
|
return getPersonalAgent(ownerId) ?? existingIdentity;
|
|
@@ -142,11 +160,13 @@ async function provisionPersonalAgent(service, ownerId, requestedModel, availabl
|
|
|
142
160
|
id: agentId,
|
|
143
161
|
enabled: true,
|
|
144
162
|
profile: {
|
|
145
|
-
name:
|
|
163
|
+
name: initial?.displayName ?? "Ada",
|
|
146
164
|
description: "A personal AI that adapts its responses to the user and coordinates work.",
|
|
147
165
|
creature: "assistant",
|
|
148
166
|
language: "zh",
|
|
149
|
-
emoji: appearanceEmoji("
|
|
167
|
+
emoji: appearanceEmoji(initial?.appearance ?? "loopi"),
|
|
168
|
+
avatar: appearanceAvatar(initial?.appearance ?? "loopi"),
|
|
169
|
+
...initial?.voicePreference ? { voicePreference: initial.voicePreference } : {},
|
|
150
170
|
responsePreferences: DEFAULT_PERSONAL_PREFERENCES,
|
|
151
171
|
instructions: personalInstructions(DEFAULT_PERSONAL_PREFERENCES)
|
|
152
172
|
},
|
|
@@ -191,22 +211,25 @@ async function provisionPersonalAgent(service, ownerId, requestedModel, availabl
|
|
|
191
211
|
fixedModel: true,
|
|
192
212
|
thinkingLevel: "off"
|
|
193
213
|
}, process.cwd());
|
|
214
|
+
completePersonalOnboarding(ownerId);
|
|
194
215
|
return getPersonalAgent(ownerId) ?? record;
|
|
195
216
|
}
|
|
196
|
-
async function patchPersonalProfile(service, ownerId, revision, displayName, preferences, appearance) {
|
|
197
|
-
const updated = await updatePersonalProfileRecord(ownerId, revision, displayName, preferences, appearance);
|
|
217
|
+
async function patchPersonalProfile(service, ownerId, revision, displayName, preferences, appearance, voicePreference) {
|
|
218
|
+
const updated = await updatePersonalProfileRecord(ownerId, revision, displayName, preferences, appearance, voicePreference);
|
|
198
219
|
if (!updated) return null;
|
|
199
220
|
service.refreshAgentCatalog();
|
|
200
221
|
service.agentService.evictSessionAgent(updated.conversationId);
|
|
201
222
|
return updated;
|
|
202
223
|
}
|
|
203
|
-
async function updatePersonalProfileRecord(ownerId, revision, displayName, preferences, appearance) {
|
|
224
|
+
async function updatePersonalProfileRecord(ownerId, revision, displayName, preferences, appearance, voicePreference) {
|
|
204
225
|
const current = new AgentCatalogRepository().get(personalAgentId(ownerId));
|
|
205
226
|
if (!current || current.provisioningState !== "ready" || current.revision !== revision || getPersonalAgent(ownerId)?.state !== "ready") return null;
|
|
206
227
|
const profile = {
|
|
207
228
|
...current.profile,
|
|
208
229
|
name: displayName,
|
|
209
230
|
emoji: appearanceEmoji(appearance),
|
|
231
|
+
avatar: appearanceAvatar(appearance),
|
|
232
|
+
...voicePreference !== void 0 ? { voicePreference: voicePreference ?? void 0 } : {},
|
|
210
233
|
responsePreferences: preferences,
|
|
211
234
|
instructions: personalInstructions(preferences)
|
|
212
235
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { init_sync_provider_auth, resolveProviderApiKeyForAgentSync } from "../../auth/sync-provider-auth.js";
|
|
2
1
|
import { getApiKeyFromEnv, init_env_keys } from "../env-keys.js";
|
|
2
|
+
import { init_sync_provider_auth, resolveProviderApiKeyForAgentSync } from "../../auth/sync-provider-auth.js";
|
|
3
3
|
import { getDefaultAuthProfileStore } from "./auth-profile-store.js";
|
|
4
4
|
//#region src/providers/auth-runtime/resolve-auth.ts
|
|
5
5
|
init_env_keys();
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { __esmMin, __exportAll } from "../../_virtual/_rolldown/runtime.js";
|
|
2
2
|
import { getAgentDefaultModelRef, init_schema } from "../config/schema.js";
|
|
3
|
-
import { getModelOAuthProviderIds, init_registry } from "../auth/oauth/registry.js";
|
|
4
|
-
import { hasProviderAuthOnDiskSync, init_sync_provider_auth } from "../auth/sync-provider-auth.js";
|
|
5
3
|
import { PROVIDER_ENV_MAP, getApiKeyFromEnv, init_env_keys } from "./env-keys.js";
|
|
6
4
|
import { init_model_ref, splitProviderModelRef } from "./model-ref.js";
|
|
7
5
|
import { ModelRegistry, getModelRegistry, init_model_registry, prewarmModelRegistry, resetModelRegistry } from "./model-registry.js";
|
|
6
|
+
import { getModelOAuthProviderIds, init_registry } from "../auth/oauth/registry.js";
|
|
8
7
|
import { CredentialResolver, hasCredentials, init_credentials } from "../auth/credentials.js";
|
|
8
|
+
import { hasProviderAuthOnDiskSync, init_sync_provider_auth } from "../auth/sync-provider-auth.js";
|
|
9
9
|
import { EXTENSION_PROVIDER_BASE_URL, init_constants } from "./constants.js";
|
|
10
10
|
import { applyOfficialModelMetadataCorrections, getSupplementalModels, init_model_supplements } from "./model-supplements.js";
|
|
11
11
|
import { getProviderRegistry, init_plugin_registry } from "./plugin-registry.js";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { __esmMin } from "../../_virtual/_rolldown/runtime.js";
|
|
2
2
|
import { init_paths_state, resolveXopcCloudCatalogCachePath } from "../config/paths-state.js";
|
|
3
|
-
import { ComputerProfileSchema, init_src } from "../../packages/computer-control-contract/src/index.js";
|
|
4
3
|
import { init_write_file_atomic, writeTextAtomic } from "../infra/write-file-atomic.js";
|
|
4
|
+
import { ComputerProfileSchema, init_src } from "../../packages/computer-control-contract/src/index.js";
|
|
5
5
|
import { voiceManifestSchema } from "../../packages/realtime-protocol/src/voice-catalog.js";
|
|
6
6
|
import { init_voice } from "../../packages/realtime-protocol/src/voice.js";
|
|
7
7
|
import { readFileSync, rmSync } from "node:fs";
|
|
@@ -138,7 +138,7 @@ var init_model_catalog_persistence = __esmMin((() => {
|
|
|
138
138
|
baseUrl: z.string().url(),
|
|
139
139
|
api: z.enum(["openai-completions", "openai-responses"]),
|
|
140
140
|
recommendedModel: z.string().nullable(),
|
|
141
|
-
recommended: z.
|
|
141
|
+
recommended: z.partialRecord(z.enum([
|
|
142
142
|
"vision",
|
|
143
143
|
"image-generation",
|
|
144
144
|
"stt",
|
|
@@ -2,8 +2,8 @@ import { AgentCatalogRepository, init_repository } from "../agent-catalog/reposi
|
|
|
2
2
|
import { init_model_policy, isComputerModel, isDedicatedComputerProfile } from "../computer/model-policy.js";
|
|
3
3
|
import { getModelCatalogStore, init_model_catalog_store } from "./model-catalog-store.js";
|
|
4
4
|
import { getModelRegistry, init_model_registry } from "./model-registry.js";
|
|
5
|
-
import { parseImageGenerationModelRef } from "../agent/image/generation/model-ref.js";
|
|
6
5
|
import { getImageGenerationProvider } from "../agent/image/generation/provider-registry.js";
|
|
6
|
+
import { parseImageGenerationModelRef } from "../agent/image/generation/model-ref.js";
|
|
7
7
|
//#region src/providers/model-reference-auditor.ts
|
|
8
8
|
init_repository();
|
|
9
9
|
init_model_policy();
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { __esmMin } from "../../_virtual/_rolldown/runtime.js";
|
|
2
2
|
import { createLogger } from "../utils/logger/index.js";
|
|
3
3
|
import { init_logger } from "../utils/logger.js";
|
|
4
|
-
import { resolveModelsJsonPath } from "../config/paths.js";
|
|
5
4
|
import { init_resolve_config_value, resolveConfigValue, resolveHeaders } from "../config/resolve-config-value.js";
|
|
5
|
+
import { resolveModelsJsonPath } from "../config/paths.js";
|
|
6
6
|
import { getDefaultModelValues, init_models_json, validateModelsConfig } from "../config/models-json.js";
|
|
7
7
|
import { getApiKeyFromEnv, init_env_keys } from "./env-keys.js";
|
|
8
8
|
import { getModelCatalogStore, init_model_catalog_store } from "./model-catalog-store.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { __esmMin } from "../../_virtual/_rolldown/runtime.js";
|
|
2
|
-
import { getOAuthProviderDefinition, init_registry } from "../auth/oauth/registry.js";
|
|
3
2
|
import { getModelCatalogStore, init_model_catalog_store } from "./model-catalog-store.js";
|
|
3
|
+
import { getOAuthProviderDefinition, init_registry } from "../auth/oauth/registry.js";
|
|
4
4
|
import { XOPC_CLOUD_PROVIDER_ID, init_xopc_cloud_config, resolveXopcModelRouterUrl } from "./xopc-cloud-config.js";
|
|
5
5
|
//#region src/providers/register-runtime-providers.ts
|
|
6
6
|
function registerRuntimeProvider(modelRuntime, source) {
|
|
@@ -2,9 +2,9 @@ import { createLogger } from "../utils/logger/index.js";
|
|
|
2
2
|
import { init_logger } from "../utils/logger.js";
|
|
3
3
|
import { isTailscaleInstalled } from "../infra/tailscale.js";
|
|
4
4
|
import { resolveGatewayBindMode } from "../config/gateway-bind.js";
|
|
5
|
-
import { getTunnelService } from "../tunnel/tunnel-service.js";
|
|
6
5
|
import { collectExposureConflicts } from "./exposure-guards.js";
|
|
7
6
|
import { getTailscaleExposureState, maybeStartTailscaleFromConfig, stopTailscaleExposure } from "../gateway/tailscale-lifecycle.js";
|
|
7
|
+
import { getTunnelService } from "../tunnel/tunnel-service.js";
|
|
8
8
|
import { getTunnelConsentState } from "../tunnel/consent.js";
|
|
9
9
|
import { maybeAutoStartTunnelFromConfig } from "../tunnel/gateway-lifecycle.js";
|
|
10
10
|
//#region src/remote-access/exposure-manager.ts
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { createSqliteTranscriptRuntime } from "../../agent/embedded/transcript-runtime.js";
|
|
2
|
-
import { createDelegateChildHandle } from "../../agent/child-agent-factory.js";
|
|
3
|
-
import { createDelegationParentPolicy } from "../../agent/tools/delegation-parent-policy.js";
|
|
4
|
-
import { SessionStore } from "../../session/store.js";
|
|
5
1
|
import { MessageBus } from "../../infra/bus/queue.js";
|
|
6
2
|
import "../../infra/bus/index.js";
|
|
3
|
+
import { SessionStore } from "../../session/store.js";
|
|
4
|
+
import { createSqliteTranscriptRuntime } from "../../agent/embedded/transcript-runtime.js";
|
|
7
5
|
import { createStructuredOutputTool } from "../../agent/workflow/structured-output-tool.js";
|
|
6
|
+
import { createDelegateChildHandle } from "../../agent/child-agent-factory.js";
|
|
7
|
+
import { createDelegationParentPolicy } from "../../agent/tools/delegation-parent-policy.js";
|
|
8
8
|
import { createScopedWorkspaceTools } from "../../agent/tools/scoped-workspace-tools.js";
|
|
9
9
|
import { taskFollowUpTemplate } from "./contracts.js";
|
|
10
10
|
import { z } from "zod";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { init_paths_state, resolveStateDir } from "../../config/paths-state.js";
|
|
2
2
|
import { ExecutionEnvironmentStore } from "../../execution-environments/store.js";
|
|
3
3
|
import { ProjectStore } from "../../projects/project-store.js";
|
|
4
|
-
import { readWorkspaceFile } from "../../agent/sandbox/fileAccess.js";
|
|
5
4
|
import { LocalWorktreeManager } from "../../execution-environments/local-worktree-manager.js";
|
|
5
|
+
import { readWorkspaceFile } from "../../agent/sandbox/fileAccess.js";
|
|
6
6
|
import { workspaceFingerprint } from "./workspaceFingerprint.js";
|
|
7
7
|
import { dirname, join, resolve } from "node:path";
|
|
8
8
|
import { existsSync, lstatSync, mkdirSync, readdirSync, realpathSync } from "node:fs";
|
|
@@ -5,14 +5,14 @@ import { TaskRunRepository, init_task_run_repository } from "../../tasks/task-ru
|
|
|
5
5
|
import { AgentCatalogRepository, init_repository } from "../../agent-catalog/repository.js";
|
|
6
6
|
import { init_agent_scope, resolveDefaultAgentId } from "../../agent/agent-scope.js";
|
|
7
7
|
import { init_providers, isProviderConfiguredSync, resolveModel } from "../../providers/index.js";
|
|
8
|
+
import { runProcess } from "../../process/run-process.js";
|
|
8
9
|
import { ExecutionEnvironmentStore } from "../../execution-environments/store.js";
|
|
9
10
|
import { ProjectStore } from "../../projects/project-store.js";
|
|
10
|
-
import {
|
|
11
|
-
import { removeCommandContainer } from "../../agent/commands/command-isolation.js";
|
|
12
|
-
import { inspectGitRepository } from "../../execution-environments/git.js";
|
|
11
|
+
import { resolveModelSelector } from "../../config/agent-model-intents.js";
|
|
13
12
|
import { TaskContextRepository } from "../../tasks/task-context-repository.js";
|
|
14
13
|
import { TaskApplicationService } from "../../tasks/task-application-service.js";
|
|
15
|
-
import {
|
|
14
|
+
import { inspectGitRepository } from "../../execution-environments/git.js";
|
|
15
|
+
import { removeCommandContainer } from "../../agent/commands/command-isolation.js";
|
|
16
16
|
import { sceneContentHash } from "../contracts.js";
|
|
17
17
|
import { SceneConflictError, SceneNotFoundError, SceneRepository } from "../repository.js";
|
|
18
18
|
import { SceneSetupError } from "../service.js";
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { buildSessionContextForLlm, init_session_context_for_llm, isTranscriptContextEntry, mergeLlmMessagesPreservingContextRows, transcriptRowsFromJsonArray } from "./session-context-for-llm.js";
|
|
2
2
|
import { SessionStatus, init_types } from "./types.js";
|
|
3
3
|
import { effectiveWorkspacePathForSession, normalizeWorkingDirectoryInput, projectWorkspacePath } from "./session-workspace.js";
|
|
4
|
-
import { flattenMessageContent, messagesToClientHistory } from "./client-history.js";
|
|
5
|
-
import { emitSessionTranscriptUpdate, onSessionTranscriptUpdate } from "./transcript-events.js";
|
|
6
4
|
import { fallbackTitleFromMessages, generateSessionTitleFromMessages, getSessionTitleSource, isWebchatConversationId, maybeRefineSessionTitleWithLlm, maybeSetProvisionalSessionTitle, provisionalTitleFromUserText, sanitizeGeneratedSessionTitle, sanitizeSessionTitle, shouldAutoTitleConversationId, shouldRefineSessionTitleWithLlm } from "./session-title.js";
|
|
5
|
+
import { flattenMessageContent, messagesToClientHistory } from "./client-history.js";
|
|
7
6
|
import { SessionStore } from "./store.js";
|
|
8
7
|
import { applySessionPatchToMetadata } from "./patch-metadata.js";
|
|
9
8
|
import { SessionIndex } from "./manager.js";
|
|
9
|
+
import { emitSessionTranscriptUpdate, onSessionTranscriptUpdate } from "./transcript-events.js";
|
|
10
10
|
import { SessionConfigStore, resolveReasoningLevel, resolveThinkingLevel, resolveVerboseLevel } from "./config-store.js";
|
|
11
11
|
import { DEFAULT_ACTIVITY_DETAIL_LEVEL, resolveConfiguredActivityDetailDefault, resolveEffectiveReasoningLevel, resolveEffectiveThinkingLevel } from "./thinking-resolve.js";
|
|
12
12
|
import { DEFAULT_IDLE_MINUTES, DEFAULT_RESET_AT_HOUR, DEFAULT_RESET_MODE, evaluateSessionFreshness, resolveDailyResetAtMs, resolveSessionResetPolicy } from "./reset-policy.js";
|
|
@@ -6,11 +6,11 @@ import { findConversationIdByTranscriptId } from "../storage/sqlite/session-repo
|
|
|
6
6
|
import { getSessionConfig } from "../storage/sqlite/config-repository.js";
|
|
7
7
|
import { init_sqlite } from "../storage/sqlite/index.js";
|
|
8
8
|
import { SessionConfigSchema, init_schema } from "../config/schema.js";
|
|
9
|
-
import { isPersonalConversation } from "../personal-agent/repository.js";
|
|
10
9
|
import { normalizeThinkLevel, normalizeVerboseLevel } from "../agent/transcript/thinking-types.js";
|
|
11
10
|
import { evaluateSessionFreshness, resolveSessionResetPolicy } from "./reset-policy.js";
|
|
12
11
|
import { resolveChannelResetConfig, resolveSessionResetType } from "./reset-type.js";
|
|
13
12
|
import { resolveSessionLifecycleTimestamps } from "./lifecycle-timestamps.js";
|
|
13
|
+
import { isPersonalConversation } from "../personal-agent/repository.js";
|
|
14
14
|
import { randomUUID } from "node:crypto";
|
|
15
15
|
//#region src/session/resolve-session.ts
|
|
16
16
|
init_schema();
|
|
@@ -5,8 +5,8 @@ import { isCronConversationId } from "../routing/agent-session-key.js";
|
|
|
5
5
|
import { init_session_key } from "../routing/session-key.js";
|
|
6
6
|
import { init_providers, resolveModel } from "../providers/index.js";
|
|
7
7
|
import { completeWithResolvedCredentials } from "../providers/model-call.js";
|
|
8
|
-
import { readAgentMessageContent } from "../agent/memory/agent-message-access.js";
|
|
9
8
|
import { stripRuntimeContextFromUserMessage } from "./user-message-display.js";
|
|
9
|
+
import { readAgentMessageContent } from "../agent/memory/agent-message-access.js";
|
|
10
10
|
//#region src/session/session-title.ts
|
|
11
11
|
init_session_key();
|
|
12
12
|
init_providers();
|
|
@@ -13,16 +13,16 @@ import { appendCompactionBoundaryIfUnchanged, appendTranscriptEntry, listCompact
|
|
|
13
13
|
import { getSessionConfig, setSessionConfig } from "../storage/sqlite/config-repository.js";
|
|
14
14
|
import { init_sqlite } from "../storage/sqlite/index.js";
|
|
15
15
|
import { init_agent_session_key, resolveAgentIdFromConversationId } from "../routing/agent-session-key.js";
|
|
16
|
-
import { resolveEffectiveAgentProfile } from "../config/agent-profile.js";
|
|
17
16
|
import { DurableState } from "../storage/sqlite/durable-state.js";
|
|
18
|
-
import {
|
|
17
|
+
import { resolveEffectiveAgentProfile } from "../config/agent-profile.js";
|
|
18
|
+
import { readPostCompactionContext } from "../agent/reply/post-compaction-context.js";
|
|
19
19
|
import { SessionCompactor } from "../agent/memory/compaction.js";
|
|
20
20
|
import { resolveCompactionPolicy } from "../agent/memory/compaction-policy.js";
|
|
21
|
-
import { resolveUserContextSessionAccess } from "../user-context/access-policy.js";
|
|
22
|
-
import { readPostCompactionContext } from "../agent/reply/post-compaction-context.js";
|
|
23
21
|
import { promoteCompactionLedger } from "../agent/memory/compaction-promotion.js";
|
|
22
|
+
import { resolveUserContextSessionAccess } from "../user-context/access-policy.js";
|
|
24
23
|
import { SlidingWindow } from "../agent/memory/window.js";
|
|
25
24
|
import { isAppendOnlyLlmTranscriptMessage } from "./transcript-stats.js";
|
|
25
|
+
import { transcriptRowsToClientHistory } from "./client-history.js";
|
|
26
26
|
import { compactHistory } from "./compact-history.js";
|
|
27
27
|
import { backfillStructuredTurnOutcomes } from "./turn-outcome-projector.js";
|
|
28
28
|
import { computeTranscriptUserRoundDeleteRange } from "./user-round-delete.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { resolveReasoningLevel, resolveThinkingLevel } from "./config-store.js";
|
|
2
1
|
import { normalizeThinkLevel } from "../agent/transcript/thinking-types.js";
|
|
2
|
+
import { resolveReasoningLevel, resolveThinkingLevel } from "./config-store.js";
|
|
3
3
|
//#region src/session/thinking-resolve.ts
|
|
4
4
|
const FALLBACK = "medium";
|
|
5
5
|
/**
|
|
@@ -5,8 +5,8 @@ import { init_connection, requireXopcDatabase } from "../storage/sqlite/connecti
|
|
|
5
5
|
import { init_transaction, runSqliteWriteTransaction } from "../storage/sqlite/transaction.js";
|
|
6
6
|
import { init_paths } from "../config/paths.js";
|
|
7
7
|
import { DurableState } from "../storage/sqlite/durable-state.js";
|
|
8
|
-
import { SHARE_CONFIG_DEFAULTS } from "./share-types.js";
|
|
9
8
|
import { isPathUnderWorkspace } from "../gateway/workspace-editor-path.js";
|
|
9
|
+
import { SHARE_CONFIG_DEFAULTS } from "./share-types.js";
|
|
10
10
|
import { logShareAudit } from "./share-audit.js";
|
|
11
11
|
import { join, relative, resolve } from "node:path";
|
|
12
12
|
import { randomBytes, randomUUID } from "node:crypto";
|
|
@@ -2,9 +2,9 @@ import { resolveStateDir } from "../config/paths-state.js";
|
|
|
2
2
|
import { createLogger } from "../utils/logger/index.js";
|
|
3
3
|
import { init_logger } from "../utils/logger.js";
|
|
4
4
|
import { init_paths } from "../config/paths.js";
|
|
5
|
+
import { loadPlaywrightCoreModule } from "../browser/providers/playwright-doctor.js";
|
|
5
6
|
import { getShareStore } from "./share-store.js";
|
|
6
7
|
import { getSiteShareStore } from "./site-share-store.js";
|
|
7
|
-
import { loadPlaywrightCoreModule } from "../browser/providers/playwright-doctor.js";
|
|
8
8
|
import { join } from "node:path";
|
|
9
9
|
import { mkdir, readFile, stat, unlink, writeFile } from "node:fs/promises";
|
|
10
10
|
//#region src/share/share-thumbnail.ts
|
|
@@ -2,8 +2,8 @@ import { isPathUnderWorkspace } from "../gateway/workspace-editor-path.js";
|
|
|
2
2
|
import { relative, resolve } from "node:path";
|
|
3
3
|
import { createReadStream } from "node:fs";
|
|
4
4
|
import { lstat, readdir, realpath, stat } from "node:fs/promises";
|
|
5
|
-
import { pipeline } from "node:stream/promises";
|
|
6
5
|
import { Readable, Transform } from "node:stream";
|
|
6
|
+
import { pipeline } from "node:stream/promises";
|
|
7
7
|
import { crc32, createDeflateRaw } from "node:zlib";
|
|
8
8
|
//#region src/share/share-zip.ts
|
|
9
9
|
const SIG_LOCAL = 67324752;
|