@songtonyli/dsh-cli 0.1.77 → 0.1.78
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/README.md +1 -1
- package/bin/dsh.mjs +1 -1
- package/node_modules/@deepseek-ai/cordis/package.json +4 -4
- package/node_modules/@deepseek-ai/cordis-plugin-group/package.json +3 -3
- package/node_modules/@deepseek-ai/cordis-plugin-include/package.json +4 -4
- package/node_modules/@deepseek-ai/cordis-plugin-loader/package.json +4 -4
- package/node_modules/@deepseek-ai/cordis-plugin-timer/package.json +3 -3
- package/node_modules/@deepseek-ai/cosmokit/package.json +1 -1
- package/node_modules/@deepseek-ai/dsh/package.json +122 -122
- package/node_modules/@deepseek-ai/dsh-acp/package.json +26 -26
- package/node_modules/@deepseek-ai/dsh-acp-app/package.json +6 -6
- package/node_modules/@deepseek-ai/dsh-agent/package.json +20 -20
- package/node_modules/@deepseek-ai/dsh-agent-default-model/package.json +10 -10
- package/node_modules/@deepseek-ai/dsh-agent-instructions/package.json +28 -28
- package/node_modules/@deepseek-ai/dsh-agent-loop/package.json +25 -25
- package/node_modules/@deepseek-ai/dsh-agent-preset/package.json +13 -13
- package/node_modules/@deepseek-ai/dsh-agent-preset/skills/cordis-composition-reference/references/packages.md +2 -0
- package/node_modules/@deepseek-ai/dsh-agent-preset-registry/package.json +34 -34
- package/node_modules/@deepseek-ai/dsh-agent-tool-presentation/package.json +11 -11
- package/node_modules/@deepseek-ai/dsh-anonymous-user-id/package.json +7 -7
- package/node_modules/@deepseek-ai/dsh-api-account-controller/package.json +9 -9
- package/node_modules/@deepseek-ai/dsh-api-authorization-controller/package.json +13 -13
- package/node_modules/@deepseek-ai/dsh-api-gateway/package.json +14 -14
- package/node_modules/@deepseek-ai/dsh-api-job-controller/package.json +12 -12
- package/node_modules/@deepseek-ai/dsh-api-remote-access/package.json +9 -9
- package/node_modules/@deepseek-ai/dsh-api-remotes/package.json +44 -44
- package/node_modules/@deepseek-ai/dsh-api-session-controller/package.json +75 -75
- package/node_modules/@deepseek-ai/dsh-api-settings-controller/package.json +16 -16
- package/node_modules/@deepseek-ai/dsh-api-terminal-controller/package.json +22 -22
- package/node_modules/@deepseek-ai/dsh-api-workspace-controller/package.json +21 -21
- package/node_modules/@deepseek-ai/dsh-api-workspace-files/package.json +15 -15
- package/node_modules/@deepseek-ai/dsh-app-boot/package.json +18 -18
- package/node_modules/@deepseek-ai/dsh-atomic-write/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-attachment/package.json +5 -5
- package/node_modules/@deepseek-ai/dsh-attachment-local/package.json +9 -9
- package/node_modules/@deepseek-ai/dsh-authorization/package.json +7 -7
- package/node_modules/@deepseek-ai/dsh-base/cordis.patch.yml +8 -1
- package/node_modules/@deepseek-ai/dsh-base/package.json +98 -97
- package/node_modules/@deepseek-ai/dsh-bash-local/package.json +11 -11
- package/node_modules/@deepseek-ai/dsh-bash-sandbox/package.json +14 -14
- package/node_modules/@deepseek-ai/dsh-brand/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-chunked-list/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-client-connection/package.json +13 -13
- package/node_modules/@deepseek-ai/dsh-client-file-upload/package.json +12 -12
- package/node_modules/@deepseek-ai/dsh-client-hmr/package.json +7 -7
- package/node_modules/@deepseek-ai/dsh-client-locale/package.json +10 -10
- package/node_modules/@deepseek-ai/dsh-client-modules/lib/index.js +1 -1
- package/node_modules/@deepseek-ai/dsh-client-modules/package.json +6 -6
- package/node_modules/@deepseek-ai/dsh-client-product-analytics/package.json +16 -16
- package/node_modules/@deepseek-ai/dsh-client-resources/package.json +5 -5
- package/node_modules/@deepseek-ai/dsh-client-shortcuts/package.json +9 -9
- package/node_modules/@deepseek-ai/dsh-client-ui-agent-preset/package.json +16 -16
- package/node_modules/@deepseek-ai/dsh-client-ui-approval/package.json +13 -13
- package/node_modules/@deepseek-ai/dsh-client-ui-attachment/package.json +10 -10
- package/node_modules/@deepseek-ai/dsh-client-ui-brand-official/package.json +5 -5
- package/node_modules/@deepseek-ai/dsh-client-ui-chat/package.json +37 -37
- package/node_modules/@deepseek-ai/dsh-client-ui-commands/package.json +14 -14
- package/node_modules/@deepseek-ai/dsh-client-ui-conversation/package.json +33 -33
- package/node_modules/@deepseek-ai/dsh-client-ui-cordis/package.json +13 -13
- package/node_modules/@deepseek-ai/dsh-client-ui-deepseek-model-label-1017/README.i18n.yaml +37 -0
- package/node_modules/@deepseek-ai/dsh-client-ui-deepseek-model-label-1017/README.md +91 -0
- package/node_modules/@deepseek-ai/dsh-client-ui-deepseek-model-label-1017/README.zh.md +91 -0
- package/node_modules/@deepseek-ai/dsh-client-ui-deepseek-model-label-1017/lib/client.js +75 -0
- package/node_modules/@deepseek-ai/dsh-client-ui-deepseek-model-label-1017/lib/index.js +6 -0
- package/node_modules/@deepseek-ai/dsh-client-ui-deepseek-model-label-1017/package.json +59 -0
- package/node_modules/@deepseek-ai/dsh-client-ui-deliverables/package.json +27 -27
- package/node_modules/@deepseek-ai/dsh-client-ui-directory-picker-browse/package.json +7 -7
- package/node_modules/@deepseek-ai/dsh-client-ui-directory-picker-native/package.json +5 -5
- package/node_modules/@deepseek-ai/dsh-client-ui-goal/package.json +14 -14
- package/node_modules/@deepseek-ai/dsh-client-ui-input-trigger/package.json +11 -11
- package/node_modules/@deepseek-ai/dsh-client-ui-jobs/package.json +10 -10
- package/node_modules/@deepseek-ai/dsh-client-ui-layout/package.json +9 -9
- package/node_modules/@deepseek-ai/dsh-client-ui-message-feedback/package.json +15 -15
- package/node_modules/@deepseek-ai/dsh-client-ui-model-selection/package.json +15 -15
- package/node_modules/@deepseek-ai/dsh-client-ui-open-in-app/package.json +18 -18
- package/node_modules/@deepseek-ai/dsh-client-ui-permission-presets/package.json +14 -14
- package/node_modules/@deepseek-ai/dsh-client-ui-plan/package.json +19 -19
- package/node_modules/@deepseek-ai/dsh-client-ui-plugin-manager/package.json +16 -16
- package/node_modules/@deepseek-ai/dsh-client-ui-plugin-market/package.json +12 -12
- package/node_modules/@deepseek-ai/dsh-client-ui-reference/package.json +15 -15
- package/node_modules/@deepseek-ai/dsh-client-ui-renderer/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-client-ui-schedule/package.json +19 -19
- package/node_modules/@deepseek-ai/dsh-client-ui-secret-mask/package.json +6 -6
- package/node_modules/@deepseek-ai/dsh-client-ui-session/package.json +9 -9
- package/node_modules/@deepseek-ai/dsh-client-ui-settings/package.json +7 -7
- package/node_modules/@deepseek-ai/dsh-client-ui-settings-account/lib/client.js +2 -2
- package/node_modules/@deepseek-ai/dsh-client-ui-settings-account/package.json +16 -16
- package/node_modules/@deepseek-ai/dsh-client-ui-settings-agent-loop/package.json +8 -8
- package/node_modules/@deepseek-ai/dsh-client-ui-settings-general/lib/client.js +1 -1
- package/node_modules/@deepseek-ai/dsh-client-ui-settings-general/package.json +15 -15
- package/node_modules/@deepseek-ai/dsh-client-ui-settings-models/package.json +11 -11
- package/node_modules/@deepseek-ai/dsh-client-ui-settings-plugin-inventory/package.json +11 -11
- package/node_modules/@deepseek-ai/dsh-client-ui-settings-plugins/package.json +7 -7
- package/node_modules/@deepseek-ai/dsh-client-ui-settings-session-log/package.json +8 -8
- package/node_modules/@deepseek-ai/dsh-client-ui-settings-shell/package.json +8 -8
- package/node_modules/@deepseek-ai/dsh-client-ui-settings-signin/package.json +6 -6
- package/node_modules/@deepseek-ai/dsh-client-ui-settings-subagent/package.json +8 -8
- package/node_modules/@deepseek-ai/dsh-client-ui-settings-web-search/README.i18n.yaml +10 -10
- package/node_modules/@deepseek-ai/dsh-client-ui-settings-web-search/README.md +9 -5
- package/node_modules/@deepseek-ai/dsh-client-ui-settings-web-search/README.zh.md +9 -5
- package/node_modules/@deepseek-ai/dsh-client-ui-settings-web-search/lib/client.js +266 -63
- package/node_modules/@deepseek-ai/dsh-client-ui-settings-web-search/lib/index.js +3 -3
- package/node_modules/@deepseek-ai/dsh-client-ui-settings-web-search/package.json +8 -8
- package/node_modules/@deepseek-ai/dsh-client-ui-shortcuts/package.json +9 -9
- package/node_modules/@deepseek-ai/dsh-client-ui-sidebar/lib/client.js +1 -1
- package/node_modules/@deepseek-ai/dsh-client-ui-sidebar/package.json +11 -11
- package/node_modules/@deepseek-ai/dsh-client-ui-sidebar-browser/package.json +10 -10
- package/node_modules/@deepseek-ai/dsh-client-ui-sidebar-documentpreview/package.json +18 -18
- package/node_modules/@deepseek-ai/dsh-client-ui-sidebar-files/package.json +13 -13
- package/node_modules/@deepseek-ai/dsh-client-ui-sidebar-right/package.json +14 -14
- package/node_modules/@deepseek-ai/dsh-client-ui-sidebar-terminal/package.json +14 -14
- package/node_modules/@deepseek-ai/dsh-client-ui-skill/package.json +16 -16
- package/node_modules/@deepseek-ai/dsh-client-ui-subagent/package.json +17 -17
- package/node_modules/@deepseek-ai/dsh-client-ui-theme/package.json +12 -12
- package/node_modules/@deepseek-ai/dsh-client-ui-tool/package.json +27 -27
- package/node_modules/@deepseek-ai/dsh-client-ui-trajectory/package.json +16 -16
- package/node_modules/@deepseek-ai/dsh-client-ui-user-questions/package.json +20 -20
- package/node_modules/@deepseek-ai/dsh-client-ui-workflow-run/package.json +13 -13
- package/node_modules/@deepseek-ai/dsh-client-ui-workspace/package.json +25 -25
- package/node_modules/@deepseek-ai/dsh-cmdline/package.json +6 -6
- package/node_modules/@deepseek-ai/dsh-command-compact/package.json +12 -12
- package/node_modules/@deepseek-ai/dsh-command-feedback/package.json +15 -15
- package/node_modules/@deepseek-ai/dsh-command-goal/package.json +14 -14
- package/node_modules/@deepseek-ai/dsh-commands/package.json +18 -18
- package/node_modules/@deepseek-ai/dsh-compaction/package.json +11 -11
- package/node_modules/@deepseek-ai/dsh-compaction-basic/package.json +26 -26
- package/node_modules/@deepseek-ai/dsh-compaction-image-offload/package.json +18 -18
- package/node_modules/@deepseek-ai/dsh-compaction-tool-result-pruner/package.json +17 -17
- package/node_modules/@deepseek-ai/dsh-config-editor/package.json +12 -12
- package/node_modules/@deepseek-ai/dsh-cordis-client-runner/lib/client.js +2 -2
- package/node_modules/@deepseek-ai/dsh-cordis-client-runner/package.json +9 -9
- package/node_modules/@deepseek-ai/dsh-cordis-host-runner/package.json +22 -22
- package/node_modules/@deepseek-ai/dsh-credentials/package.json +4 -4
- package/node_modules/@deepseek-ai/dsh-credentials-local/package.json +12 -12
- package/node_modules/@deepseek-ai/dsh-deepseek-account/package.json +11 -11
- package/node_modules/@deepseek-ai/dsh-deepseek-account-platform/package.json +12 -12
- package/node_modules/@deepseek-ai/dsh-deepseek-llm-api-extensions/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-deque/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-experimental-agent-team/package.json +22 -22
- package/node_modules/@deepseek-ai/dsh-experimental-agent-team-profile/package.json +7 -7
- package/node_modules/@deepseek-ai/dsh-experimental-api-speech-to-text/package.json +8 -8
- package/node_modules/@deepseek-ai/dsh-experimental-auto-review/package.json +43 -43
- package/node_modules/@deepseek-ai/dsh-experimental-badge-skill-bundle/package.json +4 -4
- package/node_modules/@deepseek-ai/dsh-experimental-client-ui-agent-team/package.json +11 -11
- package/node_modules/@deepseek-ai/dsh-experimental-client-ui-cot-translation/package.json +20 -20
- package/node_modules/@deepseek-ai/dsh-experimental-client-ui-voice-input/package.json +15 -15
- package/node_modules/@deepseek-ai/dsh-experimental-cot-translation-bundle/package.json +6 -6
- package/node_modules/@deepseek-ai/dsh-experimental-inspector/package.json +17 -17
- package/node_modules/@deepseek-ai/dsh-experimental-inspector-profile/package.json +6 -6
- package/node_modules/@deepseek-ai/dsh-experimental-plugin-market-bundle/package.json +5 -5
- package/node_modules/@deepseek-ai/dsh-experimental-ralph-bundle/package.json +5 -5
- package/node_modules/@deepseek-ai/dsh-experimental-session-inspector/package.json +12 -12
- package/node_modules/@deepseek-ai/dsh-experimental-session-search/package.json +5 -5
- package/node_modules/@deepseek-ai/dsh-experimental-session-titles-bundle/package.json +4 -4
- package/node_modules/@deepseek-ai/dsh-experimental-speech-to-text/package.json +11 -11
- package/node_modules/@deepseek-ai/dsh-experimental-speech-to-text-sensevoice/package.json +10 -10
- package/node_modules/@deepseek-ai/dsh-experimental-terminal-bundle/package.json +6 -6
- package/node_modules/@deepseek-ai/dsh-experimental-tool-agent-team/package.json +25 -25
- package/node_modules/@deepseek-ai/dsh-experimental-tool-worktree/package.json +22 -22
- package/node_modules/@deepseek-ai/dsh-experimental-translator/package.json +29 -29
- package/node_modules/@deepseek-ai/dsh-experimental-voice-input-bundle/package.json +8 -8
- package/node_modules/@deepseek-ai/dsh-experimental-worktree/package.json +24 -24
- package/node_modules/@deepseek-ai/dsh-file-reference/package.json +5 -5
- package/node_modules/@deepseek-ai/dsh-file-reference-local/package.json +16 -16
- package/node_modules/@deepseek-ai/dsh-fs/package.json +9 -9
- package/node_modules/@deepseek-ai/dsh-fs-local/package.json +7 -7
- package/node_modules/@deepseek-ai/dsh-fs-observation-policy/package.json +6 -6
- package/node_modules/@deepseek-ai/dsh-fs-sandbox/package.json +12 -12
- package/node_modules/@deepseek-ai/dsh-goal/package.json +23 -23
- package/node_modules/@deepseek-ai/dsh-goal-round-driver/package.json +17 -17
- package/node_modules/@deepseek-ai/dsh-harness-dev-context/package.json +13 -13
- package/node_modules/@deepseek-ai/dsh-headless/package.json +24 -24
- package/node_modules/@deepseek-ai/dsh-hmr/package.json +15 -15
- package/node_modules/@deepseek-ai/dsh-home-paths/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-host-directory-picker/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-host-directory-picker-auto/package.json +20 -20
- package/node_modules/@deepseek-ai/dsh-host-directory-picker-browse/package.json +5 -5
- package/node_modules/@deepseek-ai/dsh-host-directory-picker-native/package.json +5 -5
- package/node_modules/@deepseek-ai/dsh-host-frontend-static/package.json +10 -10
- package/node_modules/@deepseek-ai/dsh-host-open-in-app/package.json +9 -9
- package/node_modules/@deepseek-ai/dsh-host-plugin-inventory/package.json +13 -13
- package/node_modules/@deepseek-ai/dsh-host-product-telemetry-otel/package.json +8 -8
- package/node_modules/@deepseek-ai/dsh-host-webserver/package.json +4 -4
- package/node_modules/@deepseek-ai/dsh-http-proxy/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-jobs/package.json +11 -11
- package/node_modules/@deepseek-ai/dsh-jobs-local/package.json +16 -16
- package/node_modules/@deepseek-ai/dsh-launch-environment/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-lazy-require/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-llm/package.json +10 -10
- package/node_modules/@deepseek-ai/dsh-llm-cursor/package.json +25 -25
- package/node_modules/@deepseek-ai/dsh-llm-deepseek/package.json +44 -44
- package/node_modules/@deepseek-ai/dsh-llm-deepseek-account/package.json +19 -19
- package/node_modules/@deepseek-ai/dsh-llm-deepseek-api-key/package.json +14 -14
- package/node_modules/@deepseek-ai/dsh-llm-pi-ai/package.json +26 -26
- package/node_modules/@deepseek-ai/dsh-llm-retry/package.json +24 -24
- package/node_modules/@deepseek-ai/dsh-mcp-client/package.json +23 -23
- package/node_modules/@deepseek-ai/dsh-mcp-resources/package.json +14 -14
- package/node_modules/@deepseek-ai/dsh-message-feedback/package.json +19 -19
- package/node_modules/@deepseek-ai/dsh-native-command/package.json +4 -4
- package/node_modules/@deepseek-ai/dsh-no-progress-reminder/package.json +15 -15
- package/node_modules/@deepseek-ai/dsh-office-to-pdf/package.json +11 -11
- package/node_modules/@deepseek-ai/dsh-otel/package.json +5 -5
- package/node_modules/@deepseek-ai/dsh-output-retention/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-package-manifest/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-permission-presets/package.json +21 -21
- package/node_modules/@deepseek-ai/dsh-persona/package.json +7 -7
- package/node_modules/@deepseek-ai/dsh-plan-mode/package.json +22 -22
- package/node_modules/@deepseek-ai/dsh-plugin-manager/package.json +33 -33
- package/node_modules/@deepseek-ai/dsh-plugin-market/package.json +24 -24
- package/node_modules/@deepseek-ai/dsh-plugin-market-index/package.json +4 -4
- package/node_modules/@deepseek-ai/dsh-plugin-package-inventory-deepseek/package.json +19 -19
- package/node_modules/@deepseek-ai/dsh-ptc-runtime/package.json +5 -5
- package/node_modules/@deepseek-ai/dsh-ptc-runtime-node/package.json +23 -23
- package/node_modules/@deepseek-ai/dsh-pwsh-local/package.json +11 -11
- package/node_modules/@deepseek-ai/dsh-pwsh-sandbox/package.json +14 -14
- package/node_modules/@deepseek-ai/dsh-repeat-tool-reminder/package.json +12 -12
- package/node_modules/@deepseek-ai/dsh-sandbox/package.json +8 -8
- package/node_modules/@deepseek-ai/dsh-sandbox-apple-container/package.json +25 -25
- package/node_modules/@deepseek-ai/dsh-sandbox-local/package.json +12 -12
- package/node_modules/@deepseek-ai/dsh-sandbox-policy/package.json +14 -14
- package/node_modules/@deepseek-ai/dsh-sandbox-windows-acl/package.json +14 -14
- package/node_modules/@deepseek-ai/dsh-schedule/package.json +34 -34
- package/node_modules/@deepseek-ai/dsh-scope/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-sdk-app/package.json +9 -9
- package/node_modules/@deepseek-ai/dsh-sdk-jsonrpc-server/package.json +27 -27
- package/node_modules/@deepseek-ai/dsh-sdk-minimal/package.json +37 -37
- package/node_modules/@deepseek-ai/dsh-sdk-protocol/package.json +9 -9
- package/node_modules/@deepseek-ai/dsh-session/package.json +10 -10
- package/node_modules/@deepseek-ai/dsh-session-checkpoint-policy/package.json +18 -18
- package/node_modules/@deepseek-ai/dsh-session-format/package.json +4 -4
- package/node_modules/@deepseek-ai/dsh-session-format-catalog/package.json +11 -11
- package/node_modules/@deepseek-ai/dsh-session-format-v0-to-v1/package.json +6 -6
- package/node_modules/@deepseek-ai/dsh-session-format-v1-to-v2/package.json +8 -8
- package/node_modules/@deepseek-ai/dsh-session-format-v2-to-v3/package.json +6 -6
- package/node_modules/@deepseek-ai/dsh-session-format-v3-to-v4/package.json +5 -5
- package/node_modules/@deepseek-ai/dsh-session-log-deepseek/package.json +18 -18
- package/node_modules/@deepseek-ai/dsh-session-log-export/package.json +22 -22
- package/node_modules/@deepseek-ai/dsh-session-persistence/package.json +11 -11
- package/node_modules/@deepseek-ai/dsh-session-persistence-jsonl/package.json +13 -13
- package/node_modules/@deepseek-ai/dsh-session-projection/package.json +5 -5
- package/node_modules/@deepseek-ai/dsh-session-projection-cache/package.json +13 -13
- package/node_modules/@deepseek-ai/dsh-session-query/package.json +20 -20
- package/node_modules/@deepseek-ai/dsh-session-query-sqlite/package.json +13 -13
- package/node_modules/@deepseek-ai/dsh-session-reference/package.json +40 -40
- package/node_modules/@deepseek-ai/dsh-session-stats/package.json +11 -11
- package/node_modules/@deepseek-ai/dsh-session-telemetry/package.json +7 -7
- package/node_modules/@deepseek-ai/dsh-session-telemetry-otel/package.json +25 -25
- package/node_modules/@deepseek-ai/dsh-session-title/package.json +17 -17
- package/node_modules/@deepseek-ai/dsh-session-title-all-prompts-llm/package.json +15 -15
- package/node_modules/@deepseek-ai/dsh-session-title-first-prompt-llm/package.json +20 -20
- package/node_modules/@deepseek-ai/dsh-session-title-llm/package.json +13 -13
- package/node_modules/@deepseek-ai/dsh-session-turn-outline/package.json +11 -11
- package/node_modules/@deepseek-ai/dsh-settings/package.json +17 -17
- package/node_modules/@deepseek-ai/dsh-shell/package.json +7 -7
- package/node_modules/@deepseek-ai/dsh-shell-env/package.json +14 -14
- package/node_modules/@deepseek-ai/dsh-skill/package.json +9 -9
- package/node_modules/@deepseek-ai/dsh-skill-badge/package.json +5 -5
- package/node_modules/@deepseek-ai/dsh-skill-filesystem/package.json +10 -10
- package/node_modules/@deepseek-ai/dsh-skill-office/package.json +8 -8
- package/node_modules/@deepseek-ai/dsh-spill/package.json +9 -9
- package/node_modules/@deepseek-ai/dsh-spill-local/package.json +11 -11
- package/node_modules/@deepseek-ai/dsh-spill-policy/package.json +33 -33
- package/node_modules/@deepseek-ai/dsh-storage/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-storage-domain/package.json +6 -6
- package/node_modules/@deepseek-ai/dsh-storage-json/package.json +6 -6
- package/node_modules/@deepseek-ai/dsh-subagent/package.json +51 -51
- package/node_modules/@deepseek-ai/dsh-subagent-acp/package.json +24 -24
- package/node_modules/@deepseek-ai/dsh-subagent-fork-in-process/package.json +15 -15
- package/node_modules/@deepseek-ai/dsh-subagent-spawn-in-process/package.json +19 -19
- package/node_modules/@deepseek-ai/dsh-subprocess/package.json +6 -6
- package/node_modules/@deepseek-ai/dsh-subprocess-local/package.json +9 -9
- package/node_modules/@deepseek-ai/dsh-system-prompt/package.json +8 -8
- package/node_modules/@deepseek-ai/dsh-terminal/package.json +8 -8
- package/node_modules/@deepseek-ai/dsh-terminal-bash/package.json +22 -22
- package/node_modules/@deepseek-ai/dsh-time-context/package.json +21 -21
- package/node_modules/@deepseek-ai/dsh-timeout/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-tmux-context/package.json +14 -14
- package/node_modules/@deepseek-ai/dsh-token-meter/package.json +17 -17
- package/node_modules/@deepseek-ai/dsh-tool-ask-user/package.json +12 -12
- package/node_modules/@deepseek-ai/dsh-tool-bash/package.json +35 -35
- package/node_modules/@deepseek-ai/dsh-tool-bash-persistent/package.json +26 -26
- package/node_modules/@deepseek-ai/dsh-tool-call-timeout-policy/package.json +9 -9
- package/node_modules/@deepseek-ai/dsh-tool-cordis/package.json +16 -16
- package/node_modules/@deepseek-ai/dsh-tool-fs/package.json +34 -34
- package/node_modules/@deepseek-ai/dsh-tool-fs-search/package.json +30 -30
- package/node_modules/@deepseek-ai/dsh-tool-goal/package.json +20 -20
- package/node_modules/@deepseek-ai/dsh-tool-jobs/package.json +18 -18
- package/node_modules/@deepseek-ai/dsh-tool-present/package.json +22 -22
- package/node_modules/@deepseek-ai/dsh-tool-pwsh/package.json +34 -34
- package/node_modules/@deepseek-ai/dsh-tool-pwsh-persistent/package.json +27 -27
- package/node_modules/@deepseek-ai/dsh-tool-ralph/package.json +23 -23
- package/node_modules/@deepseek-ai/dsh-tool-schedule/package.json +14 -14
- package/node_modules/@deepseek-ai/dsh-tool-session-query/package.json +27 -27
- package/node_modules/@deepseek-ai/dsh-tool-skill/package.json +17 -17
- package/node_modules/@deepseek-ai/dsh-tool-str-replace-editor/package.json +22 -22
- package/node_modules/@deepseek-ai/dsh-tool-subagent/package.json +26 -26
- package/node_modules/@deepseek-ai/dsh-tool-subagent-control/package.json +21 -21
- package/node_modules/@deepseek-ai/dsh-tool-terminal/package.json +30 -30
- package/node_modules/@deepseek-ai/dsh-tool-todo/package.json +18 -18
- package/node_modules/@deepseek-ai/dsh-tool-web/package.json +22 -22
- package/node_modules/@deepseek-ai/dsh-tool-workflow/package.json +23 -23
- package/node_modules/@deepseek-ai/dsh-tool-working-directory/package.json +13 -13
- package/node_modules/@deepseek-ai/dsh-tool-workspace-dependencies/package.json +11 -11
- package/node_modules/@deepseek-ai/dsh-tools/package.json +27 -27
- package/node_modules/@deepseek-ai/dsh-tui-app/package.json +84 -84
- package/node_modules/@deepseek-ai/dsh-typert-loader/package.json +10 -10
- package/node_modules/@deepseek-ai/dsh-typert-protocol/package.json +4 -4
- package/node_modules/@deepseek-ai/dsh-typert-registry/package.json +4 -4
- package/node_modules/@deepseek-ai/dsh-user-approval/package.json +16 -16
- package/node_modules/@deepseek-ai/dsh-user-questions/package.json +18 -18
- package/node_modules/@deepseek-ai/dsh-util-code-language/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-util-crypto/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-util-time/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-util-values/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-util-workspace-path/package.json +3 -3
- package/node_modules/@deepseek-ai/dsh-web/lib/index.js +13 -9
- package/node_modules/@deepseek-ai/dsh-web/package.json +6 -6
- package/node_modules/@deepseek-ai/dsh-web-app/cordis.patch.yml +3 -0
- package/node_modules/@deepseek-ai/dsh-web-app/package.json +147 -146
- package/node_modules/@deepseek-ai/dsh-web-deepseek-api/README.i18n.yaml +49 -0
- package/node_modules/@deepseek-ai/dsh-web-deepseek-api/README.md +106 -0
- package/node_modules/@deepseek-ai/dsh-web-deepseek-api/README.zh.md +106 -0
- package/node_modules/@deepseek-ai/dsh-web-deepseek-api/lib/index.js +392 -0
- package/node_modules/@deepseek-ai/dsh-web-deepseek-api/locale/en.json +5 -0
- package/node_modules/@deepseek-ai/dsh-web-deepseek-api/locale/zh.json +6 -0
- package/node_modules/@deepseek-ai/dsh-web-deepseek-api/package.json +59 -0
- package/node_modules/@deepseek-ai/dsh-web-fetch-http/package.json +10 -10
- package/node_modules/@deepseek-ai/dsh-web-frontend/package.json +19 -19
- package/node_modules/@deepseek-ai/dsh-web-search-deepseek/README.i18n.yaml +15 -15
- package/node_modules/@deepseek-ai/dsh-web-search-deepseek/README.md +9 -9
- package/node_modules/@deepseek-ai/dsh-web-search-deepseek/README.zh.md +9 -9
- package/node_modules/@deepseek-ai/dsh-web-search-deepseek/lib/index.js +3 -2
- package/node_modules/@deepseek-ai/dsh-web-search-deepseek/package.json +18 -18
- package/node_modules/@deepseek-ai/dsh-web-search-exa/package.json +9 -9
- package/node_modules/@deepseek-ai/dsh-web-search-perplexity/package.json +9 -9
- package/node_modules/@deepseek-ai/dsh-win32-process/package.json +4 -4
- package/node_modules/@deepseek-ai/dsh-workflow/package.json +11 -11
- package/node_modules/@deepseek-ai/dsh-workflow-ptc/package.json +39 -39
- package/node_modules/@deepseek-ai/dsh-working-directory/package.json +21 -21
- package/node_modules/@deepseek-ai/dsh-workspace/package.json +14 -14
- package/node_modules/@deepseek-ai/dsh-workspace-changes/package.json +23 -23
- package/node_modules/@deepseek-ai/schemastery/package.json +2 -2
- package/package.json +308 -304
|
@@ -0,0 +1,392 @@
|
|
|
1
|
+
import z from "@deepseek-ai/schemastery";
|
|
2
|
+
import { credentialRef } from "@deepseek-ai/dsh-credentials";
|
|
3
|
+
import { launchEnvironmentOf } from "@deepseek-ai/dsh-launch-environment";
|
|
4
|
+
import { WebError } from "@deepseek-ai/dsh-web";
|
|
5
|
+
//#region lib/types/transport.js
|
|
6
|
+
const ACCOUNT_PROVIDER = "deepseek-account";
|
|
7
|
+
const USER_AGENT = "deepseek-harness/0.0.1";
|
|
8
|
+
/**
|
|
9
|
+
* Resolve credential sources for one operation without retaining secret values.
|
|
10
|
+
* @param ctx - Provider context with request routing and credential services.
|
|
11
|
+
* @param config - Literal key and credential reference from the settings snapshot.
|
|
12
|
+
* @returns Authentication sources for one operation.
|
|
13
|
+
*/
|
|
14
|
+
function deepSeekWebAuth(ctx, config) {
|
|
15
|
+
const apiKeyEnv = credentialRef(config.apiKeyEnv);
|
|
16
|
+
const literalApiKey = config.apiKey !== void 0 && config.apiKey.length > 0 ? config.apiKey : void 0;
|
|
17
|
+
return {
|
|
18
|
+
...literalApiKey === void 0 ? {} : { apiKey: literalApiKey },
|
|
19
|
+
resolveAccountToken: async (endpoint) => {
|
|
20
|
+
if (ctx.get("agents")?.currentInitiator()?.session.requestContext()?.provider !== ACCOUNT_PROVIDER) return void 0;
|
|
21
|
+
return await ctx.get("deepseekAccount")?.resolveToken(endpoint);
|
|
22
|
+
},
|
|
23
|
+
resolveApiKey: async () => {
|
|
24
|
+
const credentials = ctx.get("credentials");
|
|
25
|
+
if (credentials !== void 0) return (await credentials.resolve(apiKeyEnv))?.value;
|
|
26
|
+
const ambient = launchEnvironmentOf(ctx).get(apiKeyEnv);
|
|
27
|
+
return ambient !== void 0 && ambient.value.length > 0 ? ambient.value : void 0;
|
|
28
|
+
},
|
|
29
|
+
apiKeyEnv
|
|
30
|
+
};
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Check whether an authentication source exists; does not resolve credentials.
|
|
34
|
+
* @param auth - Sources for the operation.
|
|
35
|
+
* @returns Whether a literal key or resolver is present.
|
|
36
|
+
*/
|
|
37
|
+
function hasDeepSeekWebCredential(auth) {
|
|
38
|
+
return (auth.apiKey?.length ?? 0) > 0 || auth.resolveApiKey !== void 0 || auth.resolveAccountToken !== void 0;
|
|
39
|
+
}
|
|
40
|
+
/** Narrow a remote JSON object.
|
|
41
|
+
* @param value - Untrusted JSON.
|
|
42
|
+
* @returns Whether readable object fields exist.
|
|
43
|
+
*/
|
|
44
|
+
function isRecord(value) {
|
|
45
|
+
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
46
|
+
}
|
|
47
|
+
/** Report malformed upstream JSON without embedding response content.
|
|
48
|
+
* @returns The stable provider error.
|
|
49
|
+
*/
|
|
50
|
+
function invalidResponse() {
|
|
51
|
+
return new WebError("DeepSeek returned an invalid response body", "WEB_PROVIDER_ERROR");
|
|
52
|
+
}
|
|
53
|
+
/** Dispatch one operation using a single settings and credential snapshot.
|
|
54
|
+
* @param options - Authentication sources for this operation.
|
|
55
|
+
* @param request - Resolved endpoint, JSON payload, and response decoder.
|
|
56
|
+
* @param signal - Caller cancellation signal.
|
|
57
|
+
* @returns The validated provider result.
|
|
58
|
+
*/
|
|
59
|
+
async function dispatchDeepSeekWeb(options, request, signal) {
|
|
60
|
+
const { endpoint, body, decode, recordRequest, guidance } = request;
|
|
61
|
+
const auth = await authHeaders(options, request, signal);
|
|
62
|
+
throwIfSearchAborted(signal);
|
|
63
|
+
recordRequest?.(endpoint);
|
|
64
|
+
throwIfSearchAborted(signal);
|
|
65
|
+
let response;
|
|
66
|
+
try {
|
|
67
|
+
response = await fetch(endpoint, {
|
|
68
|
+
method: "POST",
|
|
69
|
+
redirect: "error",
|
|
70
|
+
headers: {
|
|
71
|
+
...auth.headers,
|
|
72
|
+
...request.headers,
|
|
73
|
+
"content-type": "application/json",
|
|
74
|
+
"accept": "application/json",
|
|
75
|
+
"user-agent": USER_AGENT
|
|
76
|
+
},
|
|
77
|
+
body: JSON.stringify(body),
|
|
78
|
+
...signal !== void 0 ? { signal } : {}
|
|
79
|
+
});
|
|
80
|
+
} catch (error) {
|
|
81
|
+
if (signal?.aborted === true || isAbortError(error)) throw searchAborted(signal, error);
|
|
82
|
+
throw searchEndpointError(guidance, endpoint, `DeepSeek web request failed: ${String(error)}`, error);
|
|
83
|
+
}
|
|
84
|
+
if (!response.ok) {
|
|
85
|
+
const status = response.status;
|
|
86
|
+
let message = `DeepSeek API error (HTTP ${status})`;
|
|
87
|
+
try {
|
|
88
|
+
const parsed = await response.json();
|
|
89
|
+
if (isRecord(parsed)) {
|
|
90
|
+
const detail = typeof parsed.error === "string" ? parsed.error : isRecord(parsed.error) ? parsed.error.message : parsed.message;
|
|
91
|
+
if (typeof detail === "string" && detail.length > 0) message += `: ${detail}`;
|
|
92
|
+
}
|
|
93
|
+
} catch (error) {
|
|
94
|
+
if (signal?.aborted === true || isAbortError(error)) throw searchAborted(signal, error);
|
|
95
|
+
}
|
|
96
|
+
if (status === 401 && auth.kind === "account") throw accountRejectedError(message);
|
|
97
|
+
throw searchEndpointError(guidance, endpoint, message);
|
|
98
|
+
}
|
|
99
|
+
try {
|
|
100
|
+
const payload = await response.json();
|
|
101
|
+
throwIfSearchAborted(signal);
|
|
102
|
+
return decode(payload);
|
|
103
|
+
} catch (error) {
|
|
104
|
+
if (signal?.aborted === true || isAbortError(error)) throw searchAborted(signal, error);
|
|
105
|
+
throw searchEndpointError(guidance, endpoint, error instanceof WebError ? error.message : `DeepSeek returned an unprocessable response body: ${String(error)}`, error);
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
/** Replace endpoint guidance with sign-in guidance when DeepSeek rejects the account token. */
|
|
109
|
+
function accountRejectedError(message) {
|
|
110
|
+
return new WebError(`${message}\n\nDeepSeek rejected the account sign-in used for this web request. Guide the user to sign in to DeepSeek again; the endpoint does not need changing.`, "WEB_PROVIDER_ERROR");
|
|
111
|
+
}
|
|
112
|
+
/**
|
|
113
|
+
* Add endpoint recovery instructions to failures that occur after request dispatch begins.
|
|
114
|
+
* @param options - the plugin, settings field, and settings page the guidance names.
|
|
115
|
+
* @param endpoint - the dispatched endpoint.
|
|
116
|
+
* @param message - the failure description.
|
|
117
|
+
* @param cause - the underlying failure, when one exists.
|
|
118
|
+
* @returns the provider failure with recovery instructions.
|
|
119
|
+
*/
|
|
120
|
+
function searchEndpointError(options, endpoint, message, cause) {
|
|
121
|
+
return new WebError(`${message}\n\nThe web request used endpoint ${JSON.stringify(endpoint)}. ${options.subject} endpoint configuration is separate from chat. If that endpoint is not intended, guide the user to Plugins > Built-in plugin settings > ${options.page}, where they can change and save ${options.label}. If that settings page is unavailable, the user can set ${options.plugin}.${options.field} to a trusted DeepSeek endpoint. Only the user should choose or change the endpoint.`, "WEB_PROVIDER_ERROR", cause === void 0 ? void 0 : { cause });
|
|
122
|
+
}
|
|
123
|
+
/**
|
|
124
|
+
* Resolve one operation's authentication headers without retaining a credential on the provider.
|
|
125
|
+
* @param options - the caller's snapshot, so the credential and the endpoint it is sent to come from one section.
|
|
126
|
+
* @param request - the resolved request; its endpoint scopes the account token.
|
|
127
|
+
* @param signal - abort signal for the surrounding operation.
|
|
128
|
+
* @returns the account-token header when one resolves, otherwise the API-key headers, tagged by credential kind.
|
|
129
|
+
*/
|
|
130
|
+
async function authHeaders(options, request, signal) {
|
|
131
|
+
const { resolveAccountToken } = options;
|
|
132
|
+
const token = resolveAccountToken === void 0 ? void 0 : await resolveCredential(() => resolveAccountToken(request.endpoint), signal);
|
|
133
|
+
if (token !== void 0 && token.length > 0) return {
|
|
134
|
+
kind: "account",
|
|
135
|
+
headers: { "x-dsh-auth-token": token }
|
|
136
|
+
};
|
|
137
|
+
const apiKey = await resolveApiKey(options, request.guidance.plugin, signal);
|
|
138
|
+
return {
|
|
139
|
+
kind: "api-key",
|
|
140
|
+
headers: {
|
|
141
|
+
...request.apiKeyHeaders?.(apiKey),
|
|
142
|
+
"authorization": `Bearer ${apiKey}`
|
|
143
|
+
}
|
|
144
|
+
};
|
|
145
|
+
}
|
|
146
|
+
/**
|
|
147
|
+
* Resolve one operation's API key without retaining it on the provider.
|
|
148
|
+
* @param options - the caller's snapshot, so the key and the endpoint it is sent to come from one section.
|
|
149
|
+
* @param plugin - configuration namespace named by the missing-key diagnostic.
|
|
150
|
+
* @param signal - abort signal for the surrounding operation.
|
|
151
|
+
* @returns the resolved key.
|
|
152
|
+
*/
|
|
153
|
+
async function resolveApiKey(options, plugin, signal) {
|
|
154
|
+
throwIfSearchAborted(signal);
|
|
155
|
+
if (options.apiKey !== void 0 && options.apiKey.length > 0) return options.apiKey;
|
|
156
|
+
const { resolveApiKey } = options;
|
|
157
|
+
const resolved = resolveApiKey === void 0 ? void 0 : await resolveCredential(resolveApiKey, signal);
|
|
158
|
+
if (resolved !== void 0 && resolved.length > 0) return resolved;
|
|
159
|
+
throw new WebError(`DeepSeek web access has no API key for "${options.apiKeyEnv ?? "DEEPSEEK_API_KEY"}"; store it through the credentials service (the web Models page writes it), export it in the launching environment, or set a literal "apiKey" in the ${plugin} config; a conversation using a DeepSeek Account model searches with the account sign-in instead`, "WEB_PROVIDER_CREDENTIAL_MISSING");
|
|
160
|
+
}
|
|
161
|
+
/**
|
|
162
|
+
* Run one credential resolver under the search's cancellation signal. An
|
|
163
|
+
* already-cancelled search never starts the resolver.
|
|
164
|
+
* @param resolve - the resolver; a synchronous throw is mapped like a rejection.
|
|
165
|
+
* @param signal - abort signal for the surrounding search.
|
|
166
|
+
* @returns the resolved credential, or undefined when the resolver supplied none.
|
|
167
|
+
* @throws {@link WebError} `WEB_ABORTED` on cancellation, `WEB_PROVIDER_ERROR` when the resolver fails.
|
|
168
|
+
*/
|
|
169
|
+
async function resolveCredential(resolve, signal) {
|
|
170
|
+
throwIfSearchAborted(signal);
|
|
171
|
+
try {
|
|
172
|
+
return await abortable(resolve(), signal);
|
|
173
|
+
} catch (error) {
|
|
174
|
+
if (signal?.aborted === true || isAbortError(error)) throw searchAborted(signal, error);
|
|
175
|
+
throw new WebError(`DeepSeek web credential resolution failed: ${String(error)}`, "WEB_PROVIDER_ERROR", { cause: error });
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
/**
|
|
179
|
+
* Race a same-process asynchronous preflight against caller cancellation. The
|
|
180
|
+
* attached settlement handlers keep observing an uncooperative operation after
|
|
181
|
+
* abort so a later rejection cannot become unhandled.
|
|
182
|
+
*/
|
|
183
|
+
function abortable(operation, signal) {
|
|
184
|
+
if (signal === void 0) return operation;
|
|
185
|
+
if (signal.aborted) return Promise.reject(searchAborted(signal));
|
|
186
|
+
return new Promise((resolve, reject) => {
|
|
187
|
+
const onAbort = () => {
|
|
188
|
+
reject(searchAborted(signal));
|
|
189
|
+
};
|
|
190
|
+
signal.addEventListener("abort", onAbort, { once: true });
|
|
191
|
+
operation.then((value) => {
|
|
192
|
+
signal.removeEventListener("abort", onAbort);
|
|
193
|
+
resolve(value);
|
|
194
|
+
}, (error) => {
|
|
195
|
+
signal.removeEventListener("abort", onAbort);
|
|
196
|
+
reject(new Error(String(error).replace(/^Error: /u, ""), { cause: error }));
|
|
197
|
+
});
|
|
198
|
+
});
|
|
199
|
+
}
|
|
200
|
+
/** Throw the provider's stable cancellation error when the caller already aborted. */
|
|
201
|
+
function throwIfSearchAborted(signal) {
|
|
202
|
+
if (signal?.aborted === true) throw searchAborted(signal);
|
|
203
|
+
}
|
|
204
|
+
/** Build the provider's stable cancellation error while retaining the caller's reason. */
|
|
205
|
+
function searchAborted(signal, fallback) {
|
|
206
|
+
return new WebError("DeepSeek web request aborted", "WEB_ABORTED", { cause: signal?.aborted === true ? signal.reason : fallback });
|
|
207
|
+
}
|
|
208
|
+
/** True for a fetch/`AbortSignal` abort, surfaced as `WEB_ABORTED`. */
|
|
209
|
+
function isAbortError(error) {
|
|
210
|
+
return error instanceof DOMException && error.name === "AbortError";
|
|
211
|
+
}
|
|
212
|
+
//#endregion
|
|
213
|
+
//#region lib/types/search.js
|
|
214
|
+
/** Stable id the Search API provider registers under in the search registry. */
|
|
215
|
+
const DEEPSEEK_SEARCH_API_PROVIDER_ID = "deepseek-search-api";
|
|
216
|
+
/** Default Search and Fetch API base, including its `/v1/tools` prefix; `/search` and `/fetch` are appended. */
|
|
217
|
+
const DEEPSEEK_WEB_API_BASE_URL = "https://api.deepseek.com/v1/tools";
|
|
218
|
+
/** Default Search API result count, the service's own default. */
|
|
219
|
+
const DEEPSEEK_DEFAULT_COUNT = 10;
|
|
220
|
+
/** Longest `ori_question` the Search API accepts, in characters. */
|
|
221
|
+
const ORIGINAL_QUESTION_MAX_CHARS = 128;
|
|
222
|
+
/** Settings named by endpoint failures of either API in this package. */
|
|
223
|
+
const DEEPSEEK_WEB_API_GUIDANCE = {
|
|
224
|
+
plugin: "web-deepseek-api",
|
|
225
|
+
field: "baseURL",
|
|
226
|
+
label: "Search / Fetch API base URL",
|
|
227
|
+
page: "Web search"
|
|
228
|
+
};
|
|
229
|
+
/**
|
|
230
|
+
* Validate a Search API response and project its sources into the web service.
|
|
231
|
+
* @param response - untrusted JSON from the Search endpoint.
|
|
232
|
+
* @returns sources with provider order and nullable publication dates preserved.
|
|
233
|
+
* @throws {@link WebError} when the response does not contain valid search results.
|
|
234
|
+
*/
|
|
235
|
+
function mapSearchResponse(response) {
|
|
236
|
+
if (!isRecord(response) || !Array.isArray(response.results)) throw invalidResponse();
|
|
237
|
+
return {
|
|
238
|
+
sources: response.results.map((item) => {
|
|
239
|
+
if (!isRecord(item) || typeof item.url !== "string" || item.url.length === 0 || typeof item.title !== "string" || typeof item.snippet !== "string" || item.date !== null && typeof item.date !== "string") throw invalidResponse();
|
|
240
|
+
return {
|
|
241
|
+
url: item.url,
|
|
242
|
+
...item.title.length > 0 ? { title: item.title } : {},
|
|
243
|
+
...item.snippet.length > 0 ? { snippet: item.snippet } : {},
|
|
244
|
+
...item.date !== null && item.date.length > 0 ? { publishedAt: item.date } : {}
|
|
245
|
+
};
|
|
246
|
+
}),
|
|
247
|
+
truncated: false
|
|
248
|
+
};
|
|
249
|
+
}
|
|
250
|
+
/**
|
|
251
|
+
* Search through the DeepSeek Search API. HTTP redirects fail as `WEB_PROVIDER_ERROR`;
|
|
252
|
+
* failures after dispatch name the endpoint and tell the model how the user can configure it.
|
|
253
|
+
*/
|
|
254
|
+
var DeepSeekSearchApiProvider = class {
|
|
255
|
+
resolveOptions;
|
|
256
|
+
id = DEEPSEEK_SEARCH_API_PROVIDER_ID;
|
|
257
|
+
/**
|
|
258
|
+
* @param resolveOptions - the options for the NEXT search, read once at each
|
|
259
|
+
* search's entry so one search never mixes two settings sections.
|
|
260
|
+
*/
|
|
261
|
+
constructor(resolveOptions) {
|
|
262
|
+
this.resolveOptions = resolveOptions;
|
|
263
|
+
}
|
|
264
|
+
available() {
|
|
265
|
+
const options = this.resolveOptions();
|
|
266
|
+
return hasDeepSeekWebCredential(options) && URL.canParse(options.baseURL) && isPositiveInteger(options.count);
|
|
267
|
+
}
|
|
268
|
+
search(request, signal) {
|
|
269
|
+
const options = this.resolveOptions();
|
|
270
|
+
const question = boundedQuestion(options.originalQuestion?.());
|
|
271
|
+
return dispatchDeepSeekWeb(options, {
|
|
272
|
+
endpoint: `${options.baseURL.replace(/\/+$/u, "")}/search`,
|
|
273
|
+
body: {
|
|
274
|
+
query: request.query,
|
|
275
|
+
count: Math.min(options.count, request.maxResults ?? options.count),
|
|
276
|
+
need_content: false,
|
|
277
|
+
...question === void 0 ? {} : { ori_question: question }
|
|
278
|
+
},
|
|
279
|
+
decode: mapSearchResponse,
|
|
280
|
+
guidance: {
|
|
281
|
+
subject: "Search",
|
|
282
|
+
...DEEPSEEK_WEB_API_GUIDANCE
|
|
283
|
+
}
|
|
284
|
+
}, signal);
|
|
285
|
+
}
|
|
286
|
+
};
|
|
287
|
+
/**
|
|
288
|
+
* Bound the triggering question to what `ori_question` accepts: whitespace
|
|
289
|
+
* collapses to single spaces and the first 128 characters remain.
|
|
290
|
+
* @param question - the user question, when one exists.
|
|
291
|
+
* @returns the bounded question, or undefined when nothing remains.
|
|
292
|
+
*/
|
|
293
|
+
function boundedQuestion(question) {
|
|
294
|
+
const collapsed = question?.replace(/\s+/gu, " ").trim() ?? "";
|
|
295
|
+
if (collapsed.length === 0) return void 0;
|
|
296
|
+
return Array.from(collapsed).slice(0, ORIGINAL_QUESTION_MAX_CHARS).join("");
|
|
297
|
+
}
|
|
298
|
+
/** True for positive integral request limits. */
|
|
299
|
+
function isPositiveInteger(value) {
|
|
300
|
+
return Number.isInteger(value) && value > 0;
|
|
301
|
+
}
|
|
302
|
+
//#endregion
|
|
303
|
+
//#region lib/types/fetch.js
|
|
304
|
+
/** Stable id the Fetch API provider registers under in the fetch registry. */
|
|
305
|
+
const DEEPSEEK_FETCH_API_PROVIDER_ID = "deepseek-fetch-api";
|
|
306
|
+
/**
|
|
307
|
+
* Fetch page Markdown through the DeepSeek Fetch API. The API reports neither the
|
|
308
|
+
* target's status nor a final URL, and it fails when the target yields no usable
|
|
309
|
+
* content, so a success is the requested page retrieved with HTTP 200.
|
|
310
|
+
*/
|
|
311
|
+
var DeepSeekFetchApiProvider = class {
|
|
312
|
+
resolveOptions;
|
|
313
|
+
id = DEEPSEEK_FETCH_API_PROVIDER_ID;
|
|
314
|
+
/** @param resolveOptions - the options for the NEXT fetch, read once at each fetch's entry. */
|
|
315
|
+
constructor(resolveOptions) {
|
|
316
|
+
this.resolveOptions = resolveOptions;
|
|
317
|
+
}
|
|
318
|
+
available() {
|
|
319
|
+
const options = this.resolveOptions();
|
|
320
|
+
return hasDeepSeekWebCredential(options) && URL.canParse(options.baseURL);
|
|
321
|
+
}
|
|
322
|
+
fetch(request, signal) {
|
|
323
|
+
const options = this.resolveOptions();
|
|
324
|
+
return dispatchDeepSeekWeb(options, {
|
|
325
|
+
endpoint: `${options.baseURL.replace(/\/+$/u, "")}/fetch`,
|
|
326
|
+
body: { url: request.url },
|
|
327
|
+
decode: (payload) => {
|
|
328
|
+
if (!isRecord(payload) || typeof payload.content !== "string") throw invalidResponse();
|
|
329
|
+
return {
|
|
330
|
+
url: request.url,
|
|
331
|
+
statusCode: 200,
|
|
332
|
+
body: {
|
|
333
|
+
kind: "text",
|
|
334
|
+
content: payload.content
|
|
335
|
+
},
|
|
336
|
+
truncated: false
|
|
337
|
+
};
|
|
338
|
+
},
|
|
339
|
+
guidance: {
|
|
340
|
+
subject: "Fetch",
|
|
341
|
+
...DEEPSEEK_WEB_API_GUIDANCE
|
|
342
|
+
}
|
|
343
|
+
}, signal);
|
|
344
|
+
}
|
|
345
|
+
};
|
|
346
|
+
//#endregion
|
|
347
|
+
//#region lib/types/index.js
|
|
348
|
+
/** Cordis plugin name used by loader diagnostics. */
|
|
349
|
+
const name = "web-deepseek-api";
|
|
350
|
+
/** The web seam both providers register into. */
|
|
351
|
+
const inject = ["web"];
|
|
352
|
+
const Config = z.object({
|
|
353
|
+
apiKey: z.string().role("secret").volatile(),
|
|
354
|
+
apiKeyEnv: z.string().role("credential-ref").default("DEEPSEEK_API_KEY").volatile(),
|
|
355
|
+
baseURL: z.string().default(DEEPSEEK_WEB_API_BASE_URL).volatile(),
|
|
356
|
+
count: z.number().step(1).min(1).max(50).default(10).volatile(),
|
|
357
|
+
sendOriginalQuestion: z.boolean().default(true).volatile()
|
|
358
|
+
});
|
|
359
|
+
/**
|
|
360
|
+
* Read the text of the latest human prompt, the question that triggered the
|
|
361
|
+
* current turn. Injected user-role context carries another source kind.
|
|
362
|
+
* @param session - the initiating Session, when the search runs inside one.
|
|
363
|
+
* @returns the prompt's joined text blocks, or undefined without a prompt.
|
|
364
|
+
*/
|
|
365
|
+
function latestUserQuestion(session) {
|
|
366
|
+
const prompt = session?.deriveMessages().findLast((message) => message.role === "user" && message.source.kind === "user");
|
|
367
|
+
if (prompt === void 0) return void 0;
|
|
368
|
+
return prompt.content.flatMap((block) => block.type === "text" ? [block.text] : []).join("\n");
|
|
369
|
+
}
|
|
370
|
+
/**
|
|
371
|
+
* Register the Search API and Fetch API providers over one live settings section.
|
|
372
|
+
* @param ctx - plugin context owning both registrations.
|
|
373
|
+
* @param config - live settings, read once per operation.
|
|
374
|
+
*/
|
|
375
|
+
function apply(ctx, config) {
|
|
376
|
+
const auth = () => deepSeekWebAuth(ctx, {
|
|
377
|
+
apiKey: config.apiKey.get(),
|
|
378
|
+
apiKeyEnv: config.apiKeyEnv.get()
|
|
379
|
+
});
|
|
380
|
+
ctx.web.registerSearchProvider(new DeepSeekSearchApiProvider(() => ({
|
|
381
|
+
...auth(),
|
|
382
|
+
baseURL: config.baseURL.get(),
|
|
383
|
+
count: config.count.get(),
|
|
384
|
+
...config.sendOriginalQuestion.get() ? { originalQuestion: () => latestUserQuestion(ctx.get("agents")?.currentInitiator()?.session) } : {}
|
|
385
|
+
})));
|
|
386
|
+
ctx.web.registerFetchProvider(new DeepSeekFetchApiProvider(() => ({
|
|
387
|
+
...auth(),
|
|
388
|
+
baseURL: config.baseURL.get()
|
|
389
|
+
})));
|
|
390
|
+
}
|
|
391
|
+
//#endregion
|
|
392
|
+
export { Config, DEEPSEEK_DEFAULT_COUNT, DEEPSEEK_FETCH_API_PROVIDER_ID, DEEPSEEK_SEARCH_API_PROVIDER_ID, DEEPSEEK_WEB_API_BASE_URL, DeepSeekFetchApiProvider, DeepSeekSearchApiProvider, apply, inject, mapSearchResponse, name };
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@deepseek-ai/dsh-web-deepseek-api",
|
|
3
|
+
"description": "DeepSeek Search and Fetch API providers for the DeepSeek Harness web capability seam (ctx.web)",
|
|
4
|
+
"version": "0.2.1-rc.2",
|
|
5
|
+
"publishConfig": {
|
|
6
|
+
"access": "public"
|
|
7
|
+
},
|
|
8
|
+
"repository": {
|
|
9
|
+
"type": "git",
|
|
10
|
+
"url": "git+https://github.com/deepseek-ai/deepseek-harness.git",
|
|
11
|
+
"directory": "packages/web/web-deepseek-api"
|
|
12
|
+
},
|
|
13
|
+
"type": "module",
|
|
14
|
+
"main": "lib/index.js",
|
|
15
|
+
"types": "lib/types/index.d.ts",
|
|
16
|
+
"exports": {
|
|
17
|
+
".": {
|
|
18
|
+
"types": "./lib/types/index.d.ts",
|
|
19
|
+
"default": "./lib/index.js"
|
|
20
|
+
},
|
|
21
|
+
"./src/*": "./src/*",
|
|
22
|
+
"./package.json": "./package.json",
|
|
23
|
+
"./locale/*.json": "./locale/*.json"
|
|
24
|
+
},
|
|
25
|
+
"files": [
|
|
26
|
+
"locale/*.json",
|
|
27
|
+
"lib/index.js",
|
|
28
|
+
"lib/types/**/*.d.ts"
|
|
29
|
+
],
|
|
30
|
+
"license": "MIT",
|
|
31
|
+
"peerDependencies": {
|
|
32
|
+
"@deepseek-ai/dsh-agent": "0.2.1-rc.2",
|
|
33
|
+
"@deepseek-ai/dsh-credentials": "0.2.1-rc.2",
|
|
34
|
+
"@deepseek-ai/dsh-deepseek-account": "0.2.1-rc.2",
|
|
35
|
+
"@deepseek-ai/dsh-launch-environment": "0.2.1-rc.2",
|
|
36
|
+
"@deepseek-ai/dsh-session": "0.2.1-rc.2",
|
|
37
|
+
"@deepseek-ai/dsh-web": "0.2.1-rc.2",
|
|
38
|
+
"@deepseek-ai/cordis": "4.0.5"
|
|
39
|
+
},
|
|
40
|
+
"dependencies": {
|
|
41
|
+
"@deepseek-ai/schemastery": "3.18.5"
|
|
42
|
+
},
|
|
43
|
+
"devDependencies": {
|
|
44
|
+
"@deepseek-ai/dsh-agent": "0.2.1-rc.2",
|
|
45
|
+
"@deepseek-ai/dsh-credentials": "0.2.1-rc.2",
|
|
46
|
+
"@deepseek-ai/dsh-credentials-local": "0.2.1-rc.2",
|
|
47
|
+
"@deepseek-ai/dsh-deepseek-account": "0.2.1-rc.2",
|
|
48
|
+
"@deepseek-ai/dsh-launch-environment": "0.2.1-rc.2",
|
|
49
|
+
"@deepseek-ai/dsh-session": "0.2.1-rc.2",
|
|
50
|
+
"@deepseek-ai/dsh-web": "0.2.1-rc.2",
|
|
51
|
+
"@deepseek-ai/cordis": "4.0.5",
|
|
52
|
+
"@deepseek-ai/dsh-http-proxy": "0.2.1-rc.2"
|
|
53
|
+
},
|
|
54
|
+
"peerDependenciesMeta": {
|
|
55
|
+
"@deepseek-ai/dsh-deepseek-account": {
|
|
56
|
+
"optional": true
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@deepseek-ai/dsh-web-fetch-http",
|
|
3
3
|
"description": "Anonymous public HTTP(S) fetch provider for the DeepSeek Harness web capability seam (ctx.web)",
|
|
4
|
-
"version": "0.2.1-
|
|
4
|
+
"version": "0.2.1-rc.2",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
7
7
|
},
|
|
@@ -29,20 +29,20 @@
|
|
|
29
29
|
],
|
|
30
30
|
"license": "MIT",
|
|
31
31
|
"peerDependencies": {
|
|
32
|
-
"@deepseek-ai/cordis": "4.0.5
|
|
33
|
-
"@deepseek-ai/dsh-timeout": "0.2.1-
|
|
34
|
-
"@deepseek-ai/dsh-web": "0.2.1-
|
|
35
|
-
"@deepseek-ai/dsh-http-proxy": "0.2.1-
|
|
32
|
+
"@deepseek-ai/cordis": "4.0.5",
|
|
33
|
+
"@deepseek-ai/dsh-timeout": "0.2.1-rc.2",
|
|
34
|
+
"@deepseek-ai/dsh-web": "0.2.1-rc.2",
|
|
35
|
+
"@deepseek-ai/dsh-http-proxy": "0.2.1-rc.2"
|
|
36
36
|
},
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@deepseek-ai/schemastery": "3.18.5
|
|
38
|
+
"@deepseek-ai/schemastery": "3.18.5",
|
|
39
39
|
"ipaddr.js": "^2.5.0",
|
|
40
40
|
"undici": "8.11.2"
|
|
41
41
|
},
|
|
42
42
|
"devDependencies": {
|
|
43
|
-
"@deepseek-ai/cordis": "4.0.5
|
|
44
|
-
"@deepseek-ai/dsh-timeout": "0.2.1-
|
|
45
|
-
"@deepseek-ai/dsh-web": "0.2.1-
|
|
46
|
-
"@deepseek-ai/dsh-http-proxy": "0.2.1-
|
|
43
|
+
"@deepseek-ai/cordis": "4.0.5",
|
|
44
|
+
"@deepseek-ai/dsh-timeout": "0.2.1-rc.2",
|
|
45
|
+
"@deepseek-ai/dsh-web": "0.2.1-rc.2",
|
|
46
|
+
"@deepseek-ai/dsh-http-proxy": "0.2.1-rc.2"
|
|
47
47
|
}
|
|
48
48
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@deepseek-ai/dsh-web-frontend",
|
|
3
3
|
"description": "Web application entry: vite build over the @deepseek-ai/dsh-client-web shell library; dist/ served by apps/cli's dsh web",
|
|
4
|
-
"version": "0.2.1-
|
|
4
|
+
"version": "0.2.1-rc.2",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
7
7
|
},
|
|
@@ -23,14 +23,14 @@
|
|
|
23
23
|
],
|
|
24
24
|
"license": "MIT",
|
|
25
25
|
"devDependencies": {
|
|
26
|
-
"@deepseek-ai/cordis-plugin-group": "1.0.5
|
|
27
|
-
"@deepseek-ai/dsh-client-modules": "0.2.1-
|
|
28
|
-
"@deepseek-ai/dsh-client-ui-deliverables": "0.2.1-
|
|
29
|
-
"@deepseek-ai/dsh-cmdline": "0.2.1-
|
|
30
|
-
"@deepseek-ai/dsh-pwsh-local": "0.2.1-
|
|
31
|
-
"@deepseek-ai/dsh-experimental-agent-team": "0.2.1-
|
|
32
|
-
"@deepseek-ai/dsh-session-projection-cache": "0.2.1-
|
|
33
|
-
"@deepseek-ai/dsh-util-values": "0.2.1-
|
|
26
|
+
"@deepseek-ai/cordis-plugin-group": "1.0.5",
|
|
27
|
+
"@deepseek-ai/dsh-client-modules": "0.2.1-rc.2",
|
|
28
|
+
"@deepseek-ai/dsh-client-ui-deliverables": "0.2.1-rc.2",
|
|
29
|
+
"@deepseek-ai/dsh-cmdline": "0.2.1-rc.2",
|
|
30
|
+
"@deepseek-ai/dsh-pwsh-local": "0.2.1-rc.2",
|
|
31
|
+
"@deepseek-ai/dsh-experimental-agent-team": "0.2.1-rc.2",
|
|
32
|
+
"@deepseek-ai/dsh-session-projection-cache": "0.2.1-rc.2",
|
|
33
|
+
"@deepseek-ai/dsh-util-values": "0.2.1-rc.2",
|
|
34
34
|
"@types/node": "^22.20.1",
|
|
35
35
|
"@types/ws": "8.18.1",
|
|
36
36
|
"@vitejs/plugin-react": "^4.7.0",
|
|
@@ -43,15 +43,15 @@
|
|
|
43
43
|
"vite": "^6.4.3",
|
|
44
44
|
"vitest": "^4.1.11",
|
|
45
45
|
"ws": "8.21.3",
|
|
46
|
-
"@deepseek-ai/dsh-client-ui-theme": "0.2.1-
|
|
47
|
-
"@deepseek-ai/dsh-launch-environment": "0.2.1-
|
|
48
|
-
"@deepseek-ai/dsh-workspace-changes": "0.2.1-
|
|
49
|
-
"@deepseek-ai/dsh-subprocess-local": "0.2.1-
|
|
50
|
-
"@deepseek-ai/dsh-experimental-auto-review": "0.2.1-
|
|
51
|
-
"@deepseek-ai/dsh-experimental-speech-to-text": "0.2.1-
|
|
52
|
-
"@deepseek-ai/dsh-experimental-voice-input-bundle": "0.2.1-
|
|
53
|
-
"@deepseek-ai/dsh-experimental-cot-translation-bundle": "0.2.1-
|
|
54
|
-
"@deepseek-ai/dsh-experimental-worktree": "0.2.1-
|
|
55
|
-
"@deepseek-ai/dsh-experimental-plugin-market-bundle": "0.2.1-
|
|
46
|
+
"@deepseek-ai/dsh-client-ui-theme": "0.2.1-rc.2",
|
|
47
|
+
"@deepseek-ai/dsh-launch-environment": "0.2.1-rc.2",
|
|
48
|
+
"@deepseek-ai/dsh-workspace-changes": "0.2.1-rc.2",
|
|
49
|
+
"@deepseek-ai/dsh-subprocess-local": "0.2.1-rc.2",
|
|
50
|
+
"@deepseek-ai/dsh-experimental-auto-review": "0.2.1-rc.2",
|
|
51
|
+
"@deepseek-ai/dsh-experimental-speech-to-text": "0.2.1-rc.2",
|
|
52
|
+
"@deepseek-ai/dsh-experimental-voice-input-bundle": "0.2.1-rc.2",
|
|
53
|
+
"@deepseek-ai/dsh-experimental-cot-translation-bundle": "0.2.1-rc.2",
|
|
54
|
+
"@deepseek-ai/dsh-experimental-worktree": "0.2.1-rc.2",
|
|
55
|
+
"@deepseek-ai/dsh-experimental-plugin-market-bundle": "0.2.1-rc.2"
|
|
56
56
|
}
|
|
57
57
|
}
|
|
@@ -9,8 +9,8 @@
|
|
|
9
9
|
en: d2c50aae9d869902
|
|
10
10
|
zh: ee9f3f0ff575cbf9
|
|
11
11
|
/deepseek-ai-dsh-web-search-deepseek/summary:
|
|
12
|
-
en:
|
|
13
|
-
zh:
|
|
12
|
+
en: 264b231bc3342f9c
|
|
13
|
+
zh: 218eb246c9948743
|
|
14
14
|
/deepseek-ai-dsh-web-search-deepseek/table-of-contents:
|
|
15
15
|
en: d152484eb41ac6b4
|
|
16
16
|
zh: 09388d293f9be9cb
|
|
@@ -33,8 +33,8 @@
|
|
|
33
33
|
en: 467b8238cf7e140c
|
|
34
34
|
zh: 85a519c8811557aa
|
|
35
35
|
/deepseek-ai-dsh-web-search-deepseek/use-this-package/failures-and-recovery:
|
|
36
|
-
en:
|
|
37
|
-
zh:
|
|
36
|
+
en: e8b3d05fa39ccf47
|
|
37
|
+
zh: 2faa8b06ce0c4ad4
|
|
38
38
|
/deepseek-ai-dsh-web-search-deepseek/understand-the-implementation:
|
|
39
39
|
en: 9842c69ad3636bb3
|
|
40
40
|
zh: 3cdc3f816cbdd0cb
|
|
@@ -48,8 +48,8 @@
|
|
|
48
48
|
en: d6469ab9ac915762
|
|
49
49
|
zh: 07ddf7b12c748eaf
|
|
50
50
|
/deepseek-ai-dsh-web-search-deepseek/further-exploration:
|
|
51
|
-
en:
|
|
52
|
-
zh:
|
|
51
|
+
en: 19219558735b84a1
|
|
52
|
+
zh: 0e7f935aaf50c391
|
|
53
53
|
/deepseek-ai-dsh-web-search-deepseek/model-experience:
|
|
54
54
|
en: 215e7ba838619b7b
|
|
55
55
|
zh: a311da3843709f90
|
|
@@ -57,11 +57,11 @@
|
|
|
57
57
|
en: 722e4bf02953e236
|
|
58
58
|
zh: b3432958beb7b60f
|
|
59
59
|
/deepseek-ai-dsh-web-search-deepseek/model-experience/auxiliary-deepseek-search-request/what-the-model-sees:
|
|
60
|
-
en:
|
|
61
|
-
zh:
|
|
60
|
+
en: 6b2b2909347efee8
|
|
61
|
+
zh: 664c3e210ec75cfd
|
|
62
62
|
/deepseek-ai-dsh-web-search-deepseek/model-experience/auxiliary-deepseek-search-request/token-effect:
|
|
63
|
-
en:
|
|
64
|
-
zh:
|
|
63
|
+
en: 9b079b978c305dd8
|
|
64
|
+
zh: af2c3f39976b34de
|
|
65
65
|
/deepseek-ai-dsh-web-search-deepseek/model-experience/auxiliary-deepseek-search-request/kv-cache-effect:
|
|
66
66
|
en: 2bac9662f1792a79
|
|
67
67
|
zh: 556d9baabd79f9cb
|
|
@@ -78,11 +78,11 @@
|
|
|
78
78
|
en: f5d5f97a153f7c70
|
|
79
79
|
zh: f681f89596f500f5
|
|
80
80
|
/deepseek-ai-dsh-web-search-deepseek/known-limitations-and-deferred-work:
|
|
81
|
-
en:
|
|
82
|
-
zh:
|
|
81
|
+
en: c26e32bcb03c3cc1
|
|
82
|
+
zh: 49b2d0bfc01771a9
|
|
83
83
|
/deepseek-ai-dsh-web-search-deepseek/known-limitations-and-deferred-work/dev-note:
|
|
84
84
|
en: 7f775cc79dbce94b
|
|
85
85
|
zh: 12b8f68f9e7c48ca
|
|
86
|
-
/deepseek-ai-dsh-web-search-deepseek/known-limitations-and-deferred-work/dev-note/
|
|
87
|
-
en:
|
|
88
|
-
zh:
|
|
86
|
+
/deepseek-ai-dsh-web-search-deepseek/known-limitations-and-deferred-work/dev-note/dedicated-retrieval-endpoint:
|
|
87
|
+
en: 2a0437bd17a5a8a4
|
|
88
|
+
zh: 4032f3feb2388f6e
|