@mininglamp-oss/octo-runtime 1.1.11 → 1.1.13
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 +26 -142
- package/apps/cli/README.md +7 -102
- package/apps/cli/dist/adapters.d.ts +19 -1
- package/apps/cli/dist/adapters.js +153 -27
- package/apps/cli/dist/build-info.json +2 -2
- package/apps/cli/dist/codex.d.ts +5 -0
- package/apps/cli/dist/codex.js +36 -0
- package/apps/cli/dist/command-tree.d.ts +1 -13
- package/apps/cli/dist/command-tree.js +130 -316
- package/apps/cli/dist/foreground.d.ts +1 -2
- package/apps/cli/dist/help.d.ts +0 -1
- package/apps/cli/dist/help.js +2 -13
- package/apps/cli/dist/kernel.d.ts +4 -0
- package/apps/cli/dist/kernel.js +84 -0
- package/apps/cli/dist/logs.d.ts +2 -2
- package/apps/cli/dist/logs.js +14 -17
- package/apps/cli/dist/main.js +63 -180
- package/apps/cli/dist/manifest.json +33 -72
- package/apps/cli/dist/module-manifest.d.ts +1 -1
- package/apps/cli/dist/module-manifest.js +2 -3
- package/apps/cli/dist/openclaw.d.ts +0 -8
- package/apps/cli/dist/openclaw.js +2 -114
- package/apps/cli/dist/output.d.ts +1 -0
- package/apps/cli/dist/output.js +16 -23
- package/apps/cli/dist/playboard.js +32 -15
- package/apps/cli/dist/provider-launch.d.ts +28 -0
- package/apps/cli/dist/provider-launch.js +52 -0
- package/apps/cli/dist/providers.d.ts +182 -0
- package/apps/cli/dist/providers.js +34 -0
- package/apps/cli/dist/service-control.js +0 -1
- package/dist/public/adapter-sdk.d.ts +2 -0
- package/dist/public/adapter-sdk.js +2 -0
- package/dist/public/host.d.ts +2 -4
- package/dist/public/host.js +1 -1
- package/dist/public/protocol.d.ts +1 -1
- package/dist/public/protocol.js +1 -1
- package/node_modules/@mininglamp-oss/octo-runtime-acp-client/dist/index.js +4 -4
- package/node_modules/@mininglamp-oss/octo-runtime-acp-client/package.json +3 -3
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-acp/dist/index.d.ts +15 -14
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-acp/dist/index.js +24 -28
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-acp/package.json +4 -4
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-antigravity/dist/index.d.ts +10 -35
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-antigravity/dist/index.js +22 -29
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-antigravity/package.json +3 -3
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-claude-code/dist/index.d.ts +14 -68
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-claude-code/dist/index.js +60 -43
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-claude-code/package.json +3 -3
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-codebuddy/dist/index.d.ts +19 -31
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-codebuddy/dist/index.js +29 -18
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-codebuddy/package.json +4 -4
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/app-server.d.ts +6 -5
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/app-server.js +42 -35
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/engine.d.ts +54 -0
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/engine.js +147 -0
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/environment.js +4 -8
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/index.d.ts +20 -92
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/index.js +104 -216
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/mcp.d.ts +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/mcp.js +4 -11
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/service.d.ts +9 -5
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/service.js +77 -81
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/package.json +3 -3
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-dsh/dist/{chunk-R3PDZLX5.js → chunk-H3S6WM37.js} +3 -3
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-dsh/dist/{chunk-FGFEM7JP.js → chunk-RISQ6NGV.js} +1 -1
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-dsh/dist/{chunk-TSRZVLIG.js → chunk-SMTJTIN7.js} +1 -1
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-dsh/dist/dsh-sdk-NOTICE.txt +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-dsh/dist/errors.js +1 -1
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-dsh/dist/index.d.ts +4 -2
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-dsh/dist/index.js +15 -17
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-dsh/dist/launch.js +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-dsh/dist/trajectory.js +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-dsh/package.json +4 -4
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-grok-build/dist/adapter.d.ts +14 -14
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-grok-build/dist/adapter.js +23 -30
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-grok-build/dist/client.js +4 -7
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-grok-build/dist/index.d.ts +13 -21
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-grok-build/dist/index.js +48 -26
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-grok-build/package.json +5 -5
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-hermes/dist/index.d.ts +16 -14
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-hermes/dist/index.js +15 -7
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-hermes/package.json +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-kimi-code/dist/index.d.ts +16 -14
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-kimi-code/dist/index.js +14 -6
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-kimi-code/package.json +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-mcode/dist/index.d.ts +16 -14
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-mcode/dist/index.js +15 -7
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-mcode/package.json +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-openclaw/dist/index.d.ts +7 -3
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-openclaw/dist/index.js +27 -29
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-openclaw/package.json +4 -4
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-opencode/dist/index.d.ts +16 -25
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-opencode/dist/index.js +109 -178
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-opencode/package.json +4 -4
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-qodercli/dist/index.d.ts +16 -14
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-qodercli/dist/index.js +15 -6
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-qodercli/package.json +3 -2
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-qoderclicn/dist/index.d.ts +16 -14
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-qoderclicn/dist/index.js +15 -6
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-qoderclicn/package.json +3 -2
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/activity.d.ts +5 -1
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/agent-env.d.ts +49 -0
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/agent-env.js +256 -0
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/approval.js +7 -2
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/environment.js +1 -1
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/execution-scope.d.ts +5 -1
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/index.d.ts +26 -13
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/index.js +117 -59
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/mcp.js +1 -1
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/module-manifest.d.ts +1 -13
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/module-manifest.js +4 -27
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/process-launch.d.ts +11 -1
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/process-launch.js +89 -8
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/provider-launch.d.ts +10 -0
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/provider-launch.js +25 -0
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/public-display.js +10 -3
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/runtime-log-worker.js +4 -8
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/runtime-log.d.ts +0 -4
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/runtime-log.js +6 -60
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/service-status.d.ts +0 -10
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/service-status.js +0 -83
- package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/package.json +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/adapters.d.ts +19 -1
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/adapters.js +153 -27
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/build-info.json +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/codex.d.ts +5 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/codex.js +36 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/command-tree.d.ts +1 -13
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/command-tree.js +130 -316
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/foreground.d.ts +1 -2
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/help.d.ts +0 -1
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/help.js +2 -13
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/kernel.d.ts +4 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/kernel.js +84 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/logs.d.ts +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/logs.js +14 -17
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/main.js +63 -180
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/manifest.json +33 -72
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/module-manifest.d.ts +1 -1
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/module-manifest.js +2 -3
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/openclaw.d.ts +0 -8
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/openclaw.js +2 -114
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/output.d.ts +1 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/output.js +16 -23
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/playboard.js +32 -15
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/provider-launch.d.ts +28 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/provider-launch.js +52 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/providers.d.ts +182 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/providers.js +34 -0
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/service-control.js +0 -1
- package/node_modules/@mininglamp-oss/octo-runtime-cli/package.json +20 -23
- package/node_modules/@mininglamp-oss/octo-runtime-client/build-info.json +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-client/dist/async-question-reply.d.ts +2 -3
- package/node_modules/@mininglamp-oss/octo-runtime-client/dist/async-question-reply.js +31 -20
- package/node_modules/@mininglamp-oss/octo-runtime-client/dist/client.d.ts +1 -1
- package/node_modules/@mininglamp-oss/octo-runtime-client/dist/client.js +80 -50
- package/node_modules/@mininglamp-oss/octo-runtime-client/dist/index.d.ts +1 -1
- package/node_modules/@mininglamp-oss/octo-runtime-client/dist/invocation-lifecycle.js +17 -2
- package/node_modules/@mininglamp-oss/octo-runtime-client/dist/startup-catalog.js +3 -15
- package/node_modules/@mininglamp-oss/octo-runtime-client/dist/submission-error.d.ts +2 -0
- package/node_modules/@mininglamp-oss/octo-runtime-client/dist/submission-error.js +6 -0
- package/node_modules/@mininglamp-oss/octo-runtime-client/dist/types.d.ts +19 -4
- package/node_modules/@mininglamp-oss/octo-runtime-client/{schema → fixtures}/kernel-ipc-fixtures.json +28 -6
- package/node_modules/@mininglamp-oss/octo-runtime-client/package.json +5 -5
- package/node_modules/@mininglamp-oss/octo-runtime-client/schema/kernel-ipc.schema.json +3 -104
- package/node_modules/@mininglamp-oss/octo-runtime-client/schema/protocol.schema.json +316 -1250
- package/node_modules/@mininglamp-oss/octo-runtime-cross-service/package.json +1 -1
- package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/index.d.ts +0 -2
- package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/index.js +28 -57
- package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/invoke-input.d.ts +2 -2
- package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/invoke-input.js +13 -78
- package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/watchdog.d.ts +3 -1
- package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/watchdog.js +5 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-core/package.json +3 -3
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/index.d.ts +1 -1
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/index.js +1 -1
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/server.d.ts +5 -0
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/server.js +18 -18
- package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/package.json +5 -5
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/index.d.ts +1 -7
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/index.js +0 -5
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/package.json +4 -18
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/browser.d.ts +1 -2
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/browser.js +1 -2
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/context-catalog.d.ts +0 -1
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/context-catalog.js +3 -5
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/context-configuration.js +1 -8
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/context.d.ts +1 -2
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/context.js +3 -267
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/failure.d.ts +2 -0
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/failure.js +17 -3
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/generated/protocol-types.d.ts +104 -373
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/generated/protocol-types.js +32 -1
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/image-input.d.ts +9 -0
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/image-input.js +20 -0
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/index.d.ts +6 -15
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/index.js +33 -178
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/invoke-input.d.ts +23 -36
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/invoke-input.js +54 -45
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/multimodal.d.ts +1 -6
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/multimodal.js +9 -17
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/run-protocol.d.ts +2 -1
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/run-protocol.js +5 -28
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/service-processes.js +2 -1
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/package.json +1 -1
- package/node_modules/semver/classes/range.js +2 -2
- package/node_modules/semver/internal/constants.js +30 -0
- package/node_modules/semver/internal/trim-comparator-whitespace.js +438 -0
- package/node_modules/semver/package.json +1 -1
- package/node_modules/ws/README.md +21 -29
- package/node_modules/ws/lib/buffer-util.js +13 -2
- package/node_modules/ws/lib/sender.js +4 -1
- package/node_modules/ws/lib/websocket.js +8 -3
- package/node_modules/ws/package.json +1 -1
- package/package.json +37 -148
- package/packages/octo-runtime-protocol/schema/kernel-ipc.schema.json +3 -104
- package/packages/octo-runtime-protocol/schema/protocol.schema.json +316 -1250
- package/packages/octo-runtime-protocol/{schema → test/fixtures}/kernel-ipc-fixtures.json +28 -6
- package/apps/cli/dist/extra-command-config.d.ts +0 -4
- package/apps/cli/dist/extra-command-config.js +0 -50
- package/apps/cli/dist/extra-commands.d.ts +0 -15
- package/apps/cli/dist/extra-commands.js +0 -275
- package/apps/cli/dist/extras.d.ts +0 -8
- package/apps/cli/dist/extras.js +0 -82
- package/apps/cli/dist/global-extras.d.ts +0 -16
- package/apps/cli/dist/global-extras.js +0 -201
- package/apps/cli/dist/status-output.d.ts +0 -10
- package/apps/cli/dist/status-output.js +0 -65
- package/dist/public/channel-gateway-commands.d.ts +0 -1
- package/dist/public/channel-gateway-commands.js +0 -1
- package/dist/public/channel-gateway.d.ts +0 -3
- package/dist/public/channel-gateway.js +0 -1
- package/dist/public/channel-wecom-commands.d.ts +0 -1
- package/dist/public/channel-wecom-commands.js +0 -1
- package/dist/public/channel-wecom.d.ts +0 -2
- package/dist/public/channel-wecom.js +0 -1
- package/dist/public/codex.d.ts +0 -1
- package/dist/public/codex.js +0 -1
- package/dist/public/dsh.d.ts +0 -2
- package/dist/public/dsh.js +0 -1
- package/dist/public/extra.d.ts +0 -5
- package/dist/public/extra.js +0 -3
- package/dist/public/webui-commands.d.ts +0 -1
- package/dist/public/webui-commands.js +0 -1
- package/dist/public/webui.d.ts +0 -1
- package/dist/public/webui.js +0 -1
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/extra-command-config.d.ts +0 -4
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/extra-command-config.js +0 -50
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/extra-commands.d.ts +0 -15
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/extra-commands.js +0 -275
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/extras.d.ts +0 -8
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/extras.js +0 -82
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/global-extras.d.ts +0 -16
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/global-extras.js +0 -201
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/status-output.d.ts +0 -10
- package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/status-output.js +0 -65
- package/node_modules/@mininglamp-oss/octo-runtime-client/schema/context-configuration-fixtures.json +0 -1219
- package/node_modules/@mininglamp-oss/octo-runtime-client/schema/context-fixtures.json +0 -5988
- package/node_modules/@mininglamp-oss/octo-runtime-client/schema/kernel-client.behavior.json +0 -56
- package/node_modules/@mininglamp-oss/octo-runtime-client/schema/native-invoke-fixtures.json +0 -116
- package/node_modules/@mininglamp-oss/octo-runtime-client/schema/run-protocol-fixtures.json +0 -761
- package/node_modules/@mininglamp-oss/octo-runtime-client/schema/runtime-selection-fixtures.json +0 -663
- package/node_modules/@mininglamp-oss/octo-runtime-client/schema/session-name-fixtures.json +0 -191
- package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/context.d.ts +0 -12
- package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/context.js +0 -89
- package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/execution-preparation.d.ts +0 -33
- package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/execution-preparation.js +0 -93
- package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/model-input.d.ts +0 -8
- package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/model-input.js +0 -62
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/config-schema.json +0 -458
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/context-gap.d.ts +0 -50
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/context-gap.js +0 -140
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/history-context.d.ts +0 -3
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/history-context.js +0 -27
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/host-session-store.d.ts +0 -17
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/host-session-store.js +0 -123
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/im-channel.d.ts +0 -15
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/im-channel.js +0 -1489
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/rules-context.d.ts +0 -28
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/rules-context.js +0 -77
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/session-store.d.ts +0 -71
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/session-store.js +0 -153
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/stable-context.d.ts +0 -15
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/application/stable-context.js +0 -28
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/commands.d.ts +0 -4
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/commands.js +0 -124
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/contracts.d.ts +0 -172
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/contracts.js +0 -1
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/delivery/artifact-policy.d.ts +0 -22
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/delivery/artifact-policy.js +0 -46
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/delivery/artifacts.d.ts +0 -16
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/delivery/artifacts.js +0 -285
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/delivery/dispatcher.d.ts +0 -20
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/delivery/dispatcher.js +0 -109
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/delivery/identity.d.ts +0 -15
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/delivery/identity.js +0 -36
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/delivery/scheduler.d.ts +0 -16
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/delivery/scheduler.js +0 -98
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/delivery/send-error.d.ts +0 -6
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/delivery/send-error.js +0 -10
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/execution/dispatcher.d.ts +0 -17
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/execution/dispatcher.js +0 -238
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/execution/model-wait.d.ts +0 -29
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/execution/model-wait.js +0 -171
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/execution/task.d.ts +0 -44
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/execution/task.js +0 -392
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/execution/tool-environment.d.ts +0 -3
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/execution/tool-environment.js +0 -27
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/extra.d.ts +0 -4
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/extra.js +0 -87
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/index.d.ts +0 -20
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/index.js +0 -13
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/lifecycle/configuration.d.ts +0 -9
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/lifecycle/configuration.js +0 -162
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/lifecycle/manager.d.ts +0 -12
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/lifecycle/manager.js +0 -154
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/ports.d.ts +0 -34
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/ports.js +0 -1
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/presentation/run-projector.d.ts +0 -67
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/presentation/run-projector.js +0 -588
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/presentation/typing.d.ts +0 -16
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/presentation/typing.js +0 -83
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/cards.d.ts +0 -132
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/cards.js +0 -226
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/client.d.ts +0 -65
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/client.js +0 -202
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/conversations.d.ts +0 -112
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/conversations.js +0 -138
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/errors.d.ts +0 -48
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/errors.js +0 -116
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/events.d.ts +0 -51
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/events.js +0 -79
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/files.d.ts +0 -30
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/files.js +0 -222
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/index.d.ts +0 -13
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/index.js +0 -13
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/messages.d.ts +0 -92
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/messages.js +0 -173
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/rules.d.ts +0 -84
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/rules.js +0 -110
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/types.d.ts +0 -87
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/types.js +0 -45
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/url.d.ts +0 -2
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/api/url.js +0 -7
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/auth.d.ts +0 -5
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/auth.js +0 -23
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/card-action.d.ts +0 -20
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/card-action.js +0 -75
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/card-session.d.ts +0 -22
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/card-session.js +0 -136
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/cards.d.ts +0 -7
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/cards.js +0 -40
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/channel.d.ts +0 -70
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/channel.js +0 -646
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/connection-error.d.ts +0 -17
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/connection-error.js +0 -91
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/connector.d.ts +0 -18
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/connector.js +0 -148
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/contexts.d.ts +0 -15
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/contexts.js +0 -257
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/history-content.d.ts +0 -12
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/history-content.js +0 -133
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/history-messages.d.ts +0 -21
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/history-messages.js +0 -76
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/image-input.d.ts +0 -6
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/image-input.js +0 -163
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/interaction-card.d.ts +0 -4
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/interaction-card.js +0 -113
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/mentions.d.ts +0 -13
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/mentions.js +0 -75
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/message-content.d.ts +0 -6
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/message-content.js +0 -117
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/message-identities.d.ts +0 -16
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/message-identities.js +0 -74
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/message-time.d.ts +0 -4
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/message-time.js +0 -19
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/message-trigger.d.ts +0 -7
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/message-trigger.js +0 -90
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/normalize.d.ts +0 -20
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/normalize.js +0 -85
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/reasoning-frame.d.ts +0 -34
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/reasoning-frame.js +0 -430
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/resources.d.ts +0 -6
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/resources.js +0 -63
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/retry-after.d.ts +0 -6
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/retry-after.js +0 -60
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/session-command.d.ts +0 -9
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/session-command.js +0 -71
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/wukong.d.ts +0 -44
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/transport/wukong.js +0 -357
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/package.json +0 -33
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/config-schema.json +0 -276
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/application/im-channel.d.ts +0 -11
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/application/im-channel.js +0 -754
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/application/session-store.d.ts +0 -35
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/application/session-store.js +0 -93
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/commands.d.ts +0 -4
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/commands.js +0 -128
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/contracts.d.ts +0 -78
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/contracts.js +0 -1
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/delivery/dispatcher.d.ts +0 -16
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/delivery/dispatcher.js +0 -69
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/execution/dispatcher.d.ts +0 -12
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/execution/dispatcher.js +0 -95
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/extra.d.ts +0 -3
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/extra.js +0 -85
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/index.d.ts +0 -10
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/index.js +0 -6
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/lifecycle/configuration.d.ts +0 -6
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/lifecycle/configuration.js +0 -109
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/lifecycle/manager.d.ts +0 -12
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/lifecycle/manager.js +0 -73
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/ports.d.ts +0 -24
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/ports.js +0 -1
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/presentation/run-projector.d.ts +0 -45
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/presentation/run-projector.js +0 -258
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/transport/channel.d.ts +0 -21
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/transport/channel.js +0 -124
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/transport/connection.d.ts +0 -53
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/transport/connection.js +0 -219
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/transport/stream-session.d.ts +0 -10
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/transport/stream-session.js +0 -52
- package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/package.json +0 -31
- package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/config-schema.json +0 -134
- package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/dist/commands.d.ts +0 -3
- package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/dist/commands.js +0 -51
- package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/dist/index.d.ts +0 -3
- package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/dist/index.js +0 -423
- package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/dist/store.d.ts +0 -25
- package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/dist/store.js +0 -130
- package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/dist/web/assets/index-BLMf2Etg.js +0 -73
- package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/dist/web/assets/index-CYTpqItx.css +0 -1
- package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/dist/web/index.html +0 -3
- package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/package.json +0 -28
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/context-loader.d.ts +0 -32
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/context-loader.js +0 -165
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/execution.d.ts +0 -44
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/execution.js +0 -207
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/extra-commands.d.ts +0 -70
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/extra-commands.js +0 -16
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/extra-config.d.ts +0 -20
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/extra-config.js +0 -154
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/extra-dependencies.d.ts +0 -4
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/extra-dependencies.js +0 -21
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/extra-service.d.ts +0 -45
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/extra-service.js +0 -417
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/extras.d.ts +0 -62
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/extras.js +0 -389
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/shutdown.d.ts +0 -7
- package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/shutdown.js +0 -39
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/execution-plan.d.ts +0 -3
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/execution-plan.js +0 -80
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/model-context.d.ts +0 -3
- package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/model-context.js +0 -9
- package/node_modules/@types/debug/LICENSE +0 -21
- package/node_modules/@types/debug/README.md +0 -69
- package/node_modules/@types/debug/index.d.ts +0 -50
- package/node_modules/@types/debug/package.json +0 -58
- package/node_modules/@types/mdast/LICENSE +0 -21
- package/node_modules/@types/mdast/README.md +0 -15
- package/node_modules/@types/mdast/index.d.ts +0 -1123
- package/node_modules/@types/mdast/package.json +0 -47
- package/node_modules/@types/ms/LICENSE +0 -21
- package/node_modules/@types/ms/README.md +0 -82
- package/node_modules/@types/ms/index.d.ts +0 -63
- package/node_modules/@types/ms/package.json +0 -26
- package/node_modules/@types/unist/LICENSE +0 -21
- package/node_modules/@types/unist/README.md +0 -15
- package/node_modules/@types/unist/index.d.ts +0 -119
- package/node_modules/@types/unist/package.json +0 -60
- package/node_modules/character-entities/index.d.ts +0 -6
- package/node_modules/character-entities/index.js +0 -2132
- package/node_modules/character-entities/license +0 -22
- package/node_modules/character-entities/package.json +0 -78
- package/node_modules/character-entities/readme.md +0 -152
- package/node_modules/debug/LICENSE +0 -20
- package/node_modules/debug/README.md +0 -481
- package/node_modules/debug/package.json +0 -64
- package/node_modules/debug/src/browser.js +0 -272
- package/node_modules/debug/src/common.js +0 -292
- package/node_modules/debug/src/index.js +0 -10
- package/node_modules/debug/src/node.js +0 -263
- package/node_modules/decode-named-character-reference/index.d.ts +0 -13
- package/node_modules/decode-named-character-reference/index.d.ts.map +0 -1
- package/node_modules/decode-named-character-reference/index.dom.d.ts +0 -6
- package/node_modules/decode-named-character-reference/index.dom.d.ts.map +0 -1
- package/node_modules/decode-named-character-reference/index.dom.js +0 -32
- package/node_modules/decode-named-character-reference/index.js +0 -19
- package/node_modules/decode-named-character-reference/license +0 -22
- package/node_modules/decode-named-character-reference/package.json +0 -90
- package/node_modules/decode-named-character-reference/readme.md +0 -136
- package/node_modules/dequal/dist/index.js +0 -86
- package/node_modules/dequal/dist/index.min.js +0 -1
- package/node_modules/dequal/dist/index.mjs +0 -84
- package/node_modules/dequal/index.d.ts +0 -1
- package/node_modules/dequal/license +0 -21
- package/node_modules/dequal/lite/index.d.ts +0 -1
- package/node_modules/dequal/lite/index.js +0 -31
- package/node_modules/dequal/lite/index.min.js +0 -1
- package/node_modules/dequal/lite/index.mjs +0 -29
- package/node_modules/dequal/package.json +0 -57
- package/node_modules/dequal/readme.md +0 -112
- package/node_modules/devlop/lib/default.js +0 -9
- package/node_modules/devlop/lib/development.d.ts +0 -84
- package/node_modules/devlop/lib/development.js +0 -238
- package/node_modules/devlop/license +0 -22
- package/node_modules/devlop/package.json +0 -80
- package/node_modules/devlop/readme.md +0 -360
- package/node_modules/mdast-util-from-markdown/dev/index.d.ts +0 -23
- package/node_modules/mdast-util-from-markdown/dev/index.js +0 -2
- package/node_modules/mdast-util-from-markdown/dev/lib/index.d.ts +0 -53
- package/node_modules/mdast-util-from-markdown/dev/lib/index.d.ts.map +0 -1
- package/node_modules/mdast-util-from-markdown/dev/lib/index.js +0 -1455
- package/node_modules/mdast-util-from-markdown/dev/lib/types.d.ts +0 -321
- package/node_modules/mdast-util-from-markdown/dev/lib/types.js +0 -2
- package/node_modules/mdast-util-from-markdown/index.d.ts +0 -23
- package/node_modules/mdast-util-from-markdown/index.js +0 -2
- package/node_modules/mdast-util-from-markdown/lib/index.d.ts +0 -53
- package/node_modules/mdast-util-from-markdown/lib/index.d.ts.map +0 -1
- package/node_modules/mdast-util-from-markdown/lib/index.js +0 -1270
- package/node_modules/mdast-util-from-markdown/lib/types.d.ts +0 -321
- package/node_modules/mdast-util-from-markdown/lib/types.js +0 -2
- package/node_modules/mdast-util-from-markdown/license +0 -22
- package/node_modules/mdast-util-from-markdown/package.json +0 -98
- package/node_modules/mdast-util-from-markdown/readme.md +0 -549
- package/node_modules/mdast-util-to-string/index.d.ts +0 -2
- package/node_modules/mdast-util-to-string/index.js +0 -5
- package/node_modules/mdast-util-to-string/lib/index.d.ts +0 -31
- package/node_modules/mdast-util-to-string/lib/index.js +0 -108
- package/node_modules/mdast-util-to-string/license +0 -22
- package/node_modules/mdast-util-to-string/package.json +0 -78
- package/node_modules/mdast-util-to-string/readme.md +0 -218
- package/node_modules/micromark/dev/index.d.ts +0 -82
- package/node_modules/micromark/dev/index.d.ts.map +0 -1
- package/node_modules/micromark/dev/index.js +0 -68
- package/node_modules/micromark/dev/lib/compile.d.ts +0 -16
- package/node_modules/micromark/dev/lib/compile.d.ts.map +0 -1
- package/node_modules/micromark/dev/lib/compile.js +0 -1162
- package/node_modules/micromark/dev/lib/constructs.d.ts +0 -73
- package/node_modules/micromark/dev/lib/constructs.d.ts.map +0 -1
- package/node_modules/micromark/dev/lib/constructs.js +0 -101
- package/node_modules/micromark/dev/lib/create-tokenizer.d.ts +0 -46
- package/node_modules/micromark/dev/lib/create-tokenizer.d.ts.map +0 -1
- package/node_modules/micromark/dev/lib/create-tokenizer.js +0 -718
- package/node_modules/micromark/dev/lib/initialize/content.d.ts +0 -4
- package/node_modules/micromark/dev/lib/initialize/content.d.ts.map +0 -1
- package/node_modules/micromark/dev/lib/initialize/content.js +0 -99
- package/node_modules/micromark/dev/lib/initialize/document.d.ts +0 -10
- package/node_modules/micromark/dev/lib/initialize/document.d.ts.map +0 -1
- package/node_modules/micromark/dev/lib/initialize/document.js +0 -449
- package/node_modules/micromark/dev/lib/initialize/flow.d.ts +0 -4
- package/node_modules/micromark/dev/lib/initialize/flow.d.ts.map +0 -1
- package/node_modules/micromark/dev/lib/initialize/flow.js +0 -86
- package/node_modules/micromark/dev/lib/initialize/text.d.ts +0 -8
- package/node_modules/micromark/dev/lib/initialize/text.d.ts.map +0 -1
- package/node_modules/micromark/dev/lib/initialize/text.js +0 -248
- package/node_modules/micromark/dev/lib/parse.d.ts +0 -10
- package/node_modules/micromark/dev/lib/parse.d.ts.map +0 -1
- package/node_modules/micromark/dev/lib/parse.js +0 -58
- package/node_modules/micromark/dev/lib/postprocess.d.ts +0 -9
- package/node_modules/micromark/dev/lib/postprocess.d.ts.map +0 -1
- package/node_modules/micromark/dev/lib/postprocess.js +0 -19
- package/node_modules/micromark/dev/lib/preprocess.d.ts +0 -13
- package/node_modules/micromark/dev/lib/preprocess.d.ts.map +0 -1
- package/node_modules/micromark/dev/lib/preprocess.js +0 -139
- package/node_modules/micromark/dev/stream.d.ts +0 -35
- package/node_modules/micromark/dev/stream.d.ts.map +0 -1
- package/node_modules/micromark/dev/stream.js +0 -270
- package/node_modules/micromark/index.d.ts +0 -82
- package/node_modules/micromark/index.d.ts.map +0 -1
- package/node_modules/micromark/index.js +0 -60
- package/node_modules/micromark/lib/compile.d.ts +0 -16
- package/node_modules/micromark/lib/compile.d.ts.map +0 -1
- package/node_modules/micromark/lib/compile.js +0 -1068
- package/node_modules/micromark/lib/constructs.d.ts +0 -73
- package/node_modules/micromark/lib/constructs.d.ts.map +0 -1
- package/node_modules/micromark/lib/constructs.js +0 -85
- package/node_modules/micromark/lib/create-tokenizer.d.ts +0 -46
- package/node_modules/micromark/lib/create-tokenizer.d.ts.map +0 -1
- package/node_modules/micromark/lib/create-tokenizer.js +0 -613
- package/node_modules/micromark/lib/initialize/content.d.ts +0 -4
- package/node_modules/micromark/lib/initialize/content.d.ts.map +0 -1
- package/node_modules/micromark/lib/initialize/content.js +0 -79
- package/node_modules/micromark/lib/initialize/document.d.ts +0 -10
- package/node_modules/micromark/lib/initialize/document.d.ts.map +0 -1
- package/node_modules/micromark/lib/initialize/document.js +0 -370
- package/node_modules/micromark/lib/initialize/flow.d.ts +0 -4
- package/node_modules/micromark/lib/initialize/flow.d.ts.map +0 -1
- package/node_modules/micromark/lib/initialize/flow.js +0 -58
- package/node_modules/micromark/lib/initialize/text.d.ts +0 -8
- package/node_modules/micromark/lib/initialize/text.d.ts.map +0 -1
- package/node_modules/micromark/lib/initialize/text.js +0 -216
- package/node_modules/micromark/lib/parse.d.ts +0 -10
- package/node_modules/micromark/lib/parse.d.ts.map +0 -1
- package/node_modules/micromark/lib/parse.js +0 -56
- package/node_modules/micromark/lib/postprocess.d.ts +0 -9
- package/node_modules/micromark/lib/postprocess.d.ts.map +0 -1
- package/node_modules/micromark/lib/postprocess.js +0 -18
- package/node_modules/micromark/lib/preprocess.d.ts +0 -13
- package/node_modules/micromark/lib/preprocess.d.ts.map +0 -1
- package/node_modules/micromark/lib/preprocess.js +0 -112
- package/node_modules/micromark/license +0 -22
- package/node_modules/micromark/package.json +0 -87
- package/node_modules/micromark/readme.md +0 -488
- package/node_modules/micromark/stream.d.ts +0 -35
- package/node_modules/micromark/stream.d.ts.map +0 -1
- package/node_modules/micromark/stream.js +0 -256
- package/node_modules/micromark-core-commonmark/dev/index.d.ts +0 -23
- package/node_modules/micromark-core-commonmark/dev/index.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/index.js +0 -22
- package/node_modules/micromark-core-commonmark/dev/lib/attention.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/attention.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/attention.js +0 -294
- package/node_modules/micromark-core-commonmark/dev/lib/autolink.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/autolink.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/autolink.js +0 -269
- package/node_modules/micromark-core-commonmark/dev/lib/blank-line.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/blank-line.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/blank-line.js +0 -62
- package/node_modules/micromark-core-commonmark/dev/lib/block-quote.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/block-quote.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/block-quote.js +0 -162
- package/node_modules/micromark-core-commonmark/dev/lib/character-escape.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/character-escape.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/character-escape.js +0 -69
- package/node_modules/micromark-core-commonmark/dev/lib/character-reference.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/character-reference.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/character-reference.js +0 -166
- package/node_modules/micromark-core-commonmark/dev/lib/code-fenced.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/code-fenced.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/code-fenced.js +0 -472
- package/node_modules/micromark-core-commonmark/dev/lib/code-indented.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/code-indented.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/code-indented.js +0 -178
- package/node_modules/micromark-core-commonmark/dev/lib/code-text.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/code-text.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/code-text.js +0 -257
- package/node_modules/micromark-core-commonmark/dev/lib/content.d.ts +0 -7
- package/node_modules/micromark-core-commonmark/dev/lib/content.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/content.js +0 -185
- package/node_modules/micromark-core-commonmark/dev/lib/definition.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/definition.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/definition.js +0 -295
- package/node_modules/micromark-core-commonmark/dev/lib/hard-break-escape.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/hard-break-escape.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/hard-break-escape.js +0 -65
- package/node_modules/micromark-core-commonmark/dev/lib/heading-atx.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/heading-atx.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/heading-atx.js +0 -229
- package/node_modules/micromark-core-commonmark/dev/lib/html-flow.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/html-flow.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/html-flow.js +0 -938
- package/node_modules/micromark-core-commonmark/dev/lib/html-text.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/html-text.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/html-text.js +0 -783
- package/node_modules/micromark-core-commonmark/dev/lib/label-end.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/label-end.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/label-end.js +0 -658
- package/node_modules/micromark-core-commonmark/dev/lib/label-start-image.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/label-start-image.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/label-start-image.js +0 -119
- package/node_modules/micromark-core-commonmark/dev/lib/label-start-link.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/label-start-link.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/label-start-link.js +0 -71
- package/node_modules/micromark-core-commonmark/dev/lib/line-ending.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/line-ending.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/line-ending.js +0 -34
- package/node_modules/micromark-core-commonmark/dev/lib/list.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/list.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/list.js +0 -306
- package/node_modules/micromark-core-commonmark/dev/lib/partial-non-lazy-continuation.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/partial-non-lazy-continuation.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/partial-non-lazy-continuation.js +0 -67
- package/node_modules/micromark-core-commonmark/dev/lib/setext-underline.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/setext-underline.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/setext-underline.js +0 -213
- package/node_modules/micromark-core-commonmark/dev/lib/thematic-break.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/dev/lib/thematic-break.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/dev/lib/thematic-break.js +0 -120
- package/node_modules/micromark-core-commonmark/index.d.ts +0 -23
- package/node_modules/micromark-core-commonmark/index.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/index.js +0 -22
- package/node_modules/micromark-core-commonmark/lib/attention.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/attention.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/attention.js +0 -231
- package/node_modules/micromark-core-commonmark/lib/autolink.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/autolink.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/autolink.js +0 -233
- package/node_modules/micromark-core-commonmark/lib/blank-line.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/blank-line.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/blank-line.js +0 -61
- package/node_modules/micromark-core-commonmark/lib/block-quote.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/block-quote.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/block-quote.js +0 -143
- package/node_modules/micromark-core-commonmark/lib/character-escape.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/character-escape.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/character-escape.js +0 -64
- package/node_modules/micromark-core-commonmark/lib/character-reference.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/character-reference.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/character-reference.js +0 -149
- package/node_modules/micromark-core-commonmark/lib/code-fenced.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/code-fenced.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/code-fenced.js +0 -422
- package/node_modules/micromark-core-commonmark/lib/code-indented.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/code-indented.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/code-indented.js +0 -159
- package/node_modules/micromark-core-commonmark/lib/code-text.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/code-text.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/code-text.js +0 -225
- package/node_modules/micromark-core-commonmark/lib/content.d.ts +0 -7
- package/node_modules/micromark-core-commonmark/lib/content.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/content.js +0 -163
- package/node_modules/micromark-core-commonmark/lib/definition.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/definition.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/definition.js +0 -254
- package/node_modules/micromark-core-commonmark/lib/hard-break-escape.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/hard-break-escape.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/hard-break-escape.js +0 -60
- package/node_modules/micromark-core-commonmark/lib/heading-atx.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/heading-atx.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/heading-atx.js +0 -191
- package/node_modules/micromark-core-commonmark/lib/html-flow.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/html-flow.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/html-flow.js +0 -827
- package/node_modules/micromark-core-commonmark/lib/html-text.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/html-text.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/html-text.js +0 -678
- package/node_modules/micromark-core-commonmark/lib/label-end.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/label-end.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/label-end.js +0 -561
- package/node_modules/micromark-core-commonmark/lib/label-start-image.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/label-start-image.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/label-start-image.js +0 -110
- package/node_modules/micromark-core-commonmark/lib/label-start-link.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/label-start-link.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/label-start-link.js +0 -63
- package/node_modules/micromark-core-commonmark/lib/line-ending.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/line-ending.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/line-ending.js +0 -33
- package/node_modules/micromark-core-commonmark/lib/list.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/list.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/list.js +0 -213
- package/node_modules/micromark-core-commonmark/lib/partial-non-lazy-continuation.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/partial-non-lazy-continuation.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/partial-non-lazy-continuation.js +0 -61
- package/node_modules/micromark-core-commonmark/lib/setext-underline.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/setext-underline.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/setext-underline.js +0 -187
- package/node_modules/micromark-core-commonmark/lib/thematic-break.d.ts +0 -4
- package/node_modules/micromark-core-commonmark/lib/thematic-break.d.ts.map +0 -1
- package/node_modules/micromark-core-commonmark/lib/thematic-break.js +0 -102
- package/node_modules/micromark-core-commonmark/license +0 -22
- package/node_modules/micromark-core-commonmark/package.json +0 -62
- package/node_modules/micromark-core-commonmark/readme.md +0 -171
- package/node_modules/micromark-factory-destination/dev/index.d.ts +0 -42
- package/node_modules/micromark-factory-destination/dev/index.d.ts.map +0 -1
- package/node_modules/micromark-factory-destination/dev/index.js +0 -255
- package/node_modules/micromark-factory-destination/index.d.ts +0 -42
- package/node_modules/micromark-factory-destination/index.d.ts.map +0 -1
- package/node_modules/micromark-factory-destination/index.js +0 -206
- package/node_modules/micromark-factory-destination/license +0 -22
- package/node_modules/micromark-factory-destination/package.json +0 -57
- package/node_modules/micromark-factory-destination/readme.md +0 -234
- package/node_modules/micromark-factory-label/dev/index.d.ts +0 -37
- package/node_modules/micromark-factory-label/dev/index.d.ts.map +0 -1
- package/node_modules/micromark-factory-label/dev/index.js +0 -172
- package/node_modules/micromark-factory-label/index.d.ts +0 -37
- package/node_modules/micromark-factory-label/index.d.ts.map +0 -1
- package/node_modules/micromark-factory-label/index.js +0 -148
- package/node_modules/micromark-factory-label/license +0 -22
- package/node_modules/micromark-factory-label/package.json +0 -60
- package/node_modules/micromark-factory-label/readme.md +0 -224
- package/node_modules/micromark-factory-space/dev/index.d.ts +0 -60
- package/node_modules/micromark-factory-space/dev/index.d.ts.map +0 -1
- package/node_modules/micromark-factory-space/dev/index.js +0 -122
- package/node_modules/micromark-factory-space/index.d.ts +0 -60
- package/node_modules/micromark-factory-space/index.d.ts.map +0 -1
- package/node_modules/micromark-factory-space/index.js +0 -116
- package/node_modules/micromark-factory-space/license +0 -22
- package/node_modules/micromark-factory-space/package.json +0 -46
- package/node_modules/micromark-factory-space/readme.md +0 -225
- package/node_modules/micromark-factory-title/dev/index.d.ts +0 -36
- package/node_modules/micromark-factory-title/dev/index.d.ts.map +0 -1
- package/node_modules/micromark-factory-title/dev/index.js +0 -169
- package/node_modules/micromark-factory-title/index.d.ts +0 -36
- package/node_modules/micromark-factory-title/index.d.ts.map +0 -1
- package/node_modules/micromark-factory-title/index.js +0 -158
- package/node_modules/micromark-factory-title/license +0 -22
- package/node_modules/micromark-factory-title/package.json +0 -58
- package/node_modules/micromark-factory-title/readme.md +0 -229
- package/node_modules/micromark-factory-whitespace/dev/index.d.ts +0 -22
- package/node_modules/micromark-factory-whitespace/dev/index.d.ts.map +0 -1
- package/node_modules/micromark-factory-whitespace/dev/index.js +0 -53
- package/node_modules/micromark-factory-whitespace/index.d.ts +0 -22
- package/node_modules/micromark-factory-whitespace/index.d.ts.map +0 -1
- package/node_modules/micromark-factory-whitespace/index.js +0 -44
- package/node_modules/micromark-factory-whitespace/license +0 -22
- package/node_modules/micromark-factory-whitespace/package.json +0 -57
- package/node_modules/micromark-factory-whitespace/readme.md +0 -205
- package/node_modules/micromark-util-character/dev/index.d.ts +0 -195
- package/node_modules/micromark-util-character/dev/index.d.ts.map +0 -1
- package/node_modules/micromark-util-character/dev/index.js +0 -252
- package/node_modules/micromark-util-character/index.d.ts +0 -195
- package/node_modules/micromark-util-character/index.d.ts.map +0 -1
- package/node_modules/micromark-util-character/index.js +0 -246
- package/node_modules/micromark-util-character/license +0 -22
- package/node_modules/micromark-util-character/package.json +0 -57
- package/node_modules/micromark-util-character/readme.md +0 -446
- package/node_modules/micromark-util-chunked/dev/index.d.ts +0 -41
- package/node_modules/micromark-util-chunked/dev/index.d.ts.map +0 -1
- package/node_modules/micromark-util-chunked/dev/index.js +0 -89
- package/node_modules/micromark-util-chunked/index.d.ts +0 -41
- package/node_modules/micromark-util-chunked/index.d.ts.map +0 -1
- package/node_modules/micromark-util-chunked/index.js +0 -81
- package/node_modules/micromark-util-chunked/license +0 -22
- package/node_modules/micromark-util-chunked/package.json +0 -57
- package/node_modules/micromark-util-chunked/readme.md +0 -219
- package/node_modules/micromark-util-classify-character/dev/index.d.ts +0 -18
- package/node_modules/micromark-util-classify-character/dev/index.d.ts.map +0 -1
- package/node_modules/micromark-util-classify-character/dev/index.js +0 -38
- package/node_modules/micromark-util-classify-character/index.d.ts +0 -18
- package/node_modules/micromark-util-classify-character/index.d.ts.map +0 -1
- package/node_modules/micromark-util-classify-character/index.js +0 -27
- package/node_modules/micromark-util-classify-character/license +0 -22
- package/node_modules/micromark-util-classify-character/package.json +0 -59
- package/node_modules/micromark-util-classify-character/readme.md +0 -205
- package/node_modules/micromark-util-combine-extensions/index.d.ts +0 -22
- package/node_modules/micromark-util-combine-extensions/index.d.ts.map +0 -1
- package/node_modules/micromark-util-combine-extensions/index.js +0 -143
- package/node_modules/micromark-util-combine-extensions/license +0 -22
- package/node_modules/micromark-util-combine-extensions/package.json +0 -52
- package/node_modules/micromark-util-combine-extensions/readme.md +0 -201
- package/node_modules/micromark-util-decode-numeric-character-reference/dev/index.d.ts +0 -16
- package/node_modules/micromark-util-decode-numeric-character-reference/dev/index.d.ts.map +0 -1
- package/node_modules/micromark-util-decode-numeric-character-reference/dev/index.js +0 -42
- package/node_modules/micromark-util-decode-numeric-character-reference/index.d.ts +0 -16
- package/node_modules/micromark-util-decode-numeric-character-reference/index.d.ts.map +0 -1
- package/node_modules/micromark-util-decode-numeric-character-reference/index.js +0 -32
- package/node_modules/micromark-util-decode-numeric-character-reference/license +0 -22
- package/node_modules/micromark-util-decode-numeric-character-reference/package.json +0 -59
- package/node_modules/micromark-util-decode-numeric-character-reference/readme.md +0 -184
- package/node_modules/micromark-util-decode-string/dev/index.d.ts +0 -14
- package/node_modules/micromark-util-decode-string/dev/index.d.ts.map +0 -1
- package/node_modules/micromark-util-decode-string/dev/index.js +0 -53
- package/node_modules/micromark-util-decode-string/index.d.ts +0 -14
- package/node_modules/micromark-util-decode-string/index.d.ts.map +0 -1
- package/node_modules/micromark-util-decode-string/index.js +0 -45
- package/node_modules/micromark-util-decode-string/license +0 -22
- package/node_modules/micromark-util-decode-string/package.json +0 -63
- package/node_modules/micromark-util-decode-string/readme.md +0 -179
- package/node_modules/micromark-util-edit-map/dev/index.d.ts +0 -78
- package/node_modules/micromark-util-edit-map/dev/index.d.ts.map +0 -1
- package/node_modules/micromark-util-edit-map/dev/index.js +0 -237
- package/node_modules/micromark-util-edit-map/index.d.ts +0 -78
- package/node_modules/micromark-util-edit-map/index.d.ts.map +0 -1
- package/node_modules/micromark-util-edit-map/index.js +0 -225
- package/node_modules/micromark-util-edit-map/license +0 -22
- package/node_modules/micromark-util-edit-map/package.json +0 -48
- package/node_modules/micromark-util-edit-map/readme.md +0 -234
- package/node_modules/micromark-util-encode/index.d.ts +0 -14
- package/node_modules/micromark-util-encode/index.d.ts.map +0 -1
- package/node_modules/micromark-util-encode/index.js +0 -33
- package/node_modules/micromark-util-encode/license +0 -22
- package/node_modules/micromark-util-encode/package.json +0 -47
- package/node_modules/micromark-util-encode/readme.md +0 -176
- package/node_modules/micromark-util-html-tag-name/index.d.ts +0 -30
- package/node_modules/micromark-util-html-tag-name/index.d.ts.map +0 -1
- package/node_modules/micromark-util-html-tag-name/index.js +0 -93
- package/node_modules/micromark-util-html-tag-name/license +0 -22
- package/node_modules/micromark-util-html-tag-name/package.json +0 -47
- package/node_modules/micromark-util-html-tag-name/readme.md +0 -193
- package/node_modules/micromark-util-normalize-identifier/dev/index.d.ts +0 -21
- package/node_modules/micromark-util-normalize-identifier/dev/index.d.ts.map +0 -1
- package/node_modules/micromark-util-normalize-identifier/dev/index.js +0 -38
- package/node_modules/micromark-util-normalize-identifier/index.d.ts +0 -21
- package/node_modules/micromark-util-normalize-identifier/index.d.ts.map +0 -1
- package/node_modules/micromark-util-normalize-identifier/index.js +0 -33
- package/node_modules/micromark-util-normalize-identifier/license +0 -22
- package/node_modules/micromark-util-normalize-identifier/package.json +0 -58
- package/node_modules/micromark-util-normalize-identifier/readme.md +0 -187
- package/node_modules/micromark-util-resolve-all/index.d.ts +0 -22
- package/node_modules/micromark-util-resolve-all/index.d.ts.map +0 -1
- package/node_modules/micromark-util-resolve-all/index.js +0 -32
- package/node_modules/micromark-util-resolve-all/license +0 -22
- package/node_modules/micromark-util-resolve-all/package.json +0 -48
- package/node_modules/micromark-util-resolve-all/readme.md +0 -238
- package/node_modules/micromark-util-sanitize-uri/dev/index.d.ts +0 -36
- package/node_modules/micromark-util-sanitize-uri/dev/index.d.ts.map +0 -1
- package/node_modules/micromark-util-sanitize-uri/dev/index.js +0 -124
- package/node_modules/micromark-util-sanitize-uri/index.d.ts +0 -36
- package/node_modules/micromark-util-sanitize-uri/index.d.ts.map +0 -1
- package/node_modules/micromark-util-sanitize-uri/index.js +0 -107
- package/node_modules/micromark-util-sanitize-uri/license +0 -22
- package/node_modules/micromark-util-sanitize-uri/package.json +0 -59
- package/node_modules/micromark-util-sanitize-uri/readme.md +0 -214
- package/node_modules/micromark-util-subtokenize/dev/index.d.ts +0 -12
- package/node_modules/micromark-util-subtokenize/dev/index.d.ts.map +0 -1
- package/node_modules/micromark-util-subtokenize/dev/index.js +0 -284
- package/node_modules/micromark-util-subtokenize/dev/lib/splice-buffer.d.ts +0 -161
- package/node_modules/micromark-util-subtokenize/dev/lib/splice-buffer.d.ts.map +0 -1
- package/node_modules/micromark-util-subtokenize/dev/lib/splice-buffer.js +0 -288
- package/node_modules/micromark-util-subtokenize/index.d.ts +0 -12
- package/node_modules/micromark-util-subtokenize/index.d.ts.map +0 -1
- package/node_modules/micromark-util-subtokenize/index.js +0 -228
- package/node_modules/micromark-util-subtokenize/lib/splice-buffer.d.ts +0 -161
- package/node_modules/micromark-util-subtokenize/lib/splice-buffer.d.ts.map +0 -1
- package/node_modules/micromark-util-subtokenize/lib/splice-buffer.js +0 -251
- package/node_modules/micromark-util-subtokenize/license +0 -22
- package/node_modules/micromark-util-subtokenize/package.json +0 -60
- package/node_modules/micromark-util-subtokenize/readme.md +0 -181
- package/node_modules/micromark-util-symbol/lib/codes.d.ts +0 -139
- package/node_modules/micromark-util-symbol/lib/codes.d.ts.map +0 -1
- package/node_modules/micromark-util-symbol/lib/codes.js +0 -158
- package/node_modules/micromark-util-symbol/lib/constants.d.ts +0 -37
- package/node_modules/micromark-util-symbol/lib/constants.d.ts.map +0 -1
- package/node_modules/micromark-util-symbol/lib/constants.js +0 -44
- package/node_modules/micromark-util-symbol/lib/default.d.ts +0 -5
- package/node_modules/micromark-util-symbol/lib/default.d.ts.map +0 -1
- package/node_modules/micromark-util-symbol/lib/default.js +0 -4
- package/node_modules/micromark-util-symbol/lib/types.d.ts +0 -106
- package/node_modules/micromark-util-symbol/lib/types.d.ts.map +0 -1
- package/node_modules/micromark-util-symbol/lib/types.js +0 -453
- package/node_modules/micromark-util-symbol/lib/values.d.ts +0 -102
- package/node_modules/micromark-util-symbol/lib/values.d.ts.map +0 -1
- package/node_modules/micromark-util-symbol/lib/values.js +0 -109
- package/node_modules/micromark-util-symbol/license +0 -22
- package/node_modules/micromark-util-symbol/package.json +0 -43
- package/node_modules/micromark-util-symbol/readme.md +0 -168
- package/node_modules/micromark-util-types/index.d.ts +0 -1315
- package/node_modules/micromark-util-types/index.js +0 -2
- package/node_modules/micromark-util-types/license +0 -22
- package/node_modules/micromark-util-types/package.json +0 -37
- package/node_modules/micromark-util-types/readme.md +0 -151
- package/node_modules/ms/index.js +0 -162
- package/node_modules/ms/license.md +0 -21
- package/node_modules/ms/package.json +0 -38
- package/node_modules/ms/readme.md +0 -59
- package/node_modules/unist-util-stringify-position/index.d.ts +0 -1
- package/node_modules/unist-util-stringify-position/index.js +0 -1
- package/node_modules/unist-util-stringify-position/lib/index.d.ts +0 -61
- package/node_modules/unist-util-stringify-position/lib/index.js +0 -84
- package/node_modules/unist-util-stringify-position/license +0 -22
- package/node_modules/unist-util-stringify-position/package.json +0 -80
- package/node_modules/unist-util-stringify-position/readme.md +0 -206
- package/packages/octo-runtime-extra-channel-gateway/config-schema.json +0 -458
- package/packages/octo-runtime-extra-channel-wecom/config-schema.json +0 -276
- package/packages/octo-runtime-extra-webui/config-schema.json +0 -134
|
@@ -1,172 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Octo gateway 配置、入站消息、执行端口和投递回执。
|
|
3
|
-
*/
|
|
4
|
-
import type { ApprovalMode, ContextEnvelope, ContextItem, CanonicalEvent, InteractionResponse, InteractionRequestedPayload, InvokeEnvironment, ModelInputPart, ProviderSession } from "@mininglamp-oss/octo-runtime-protocol";
|
|
5
|
-
import type { RunPresentation } from "./presentation/run-projector.js";
|
|
6
|
-
import type { ImGapPlan, ImGapTurnToken } from "./application/context-gap.js";
|
|
7
|
-
import type { ImArtifactPolicy } from "./delivery/artifact-policy.js";
|
|
8
|
-
import type { ImStableContextState } from "./application/stable-context.js";
|
|
9
|
-
export interface ImPositionObservation {
|
|
10
|
-
conversationId: string;
|
|
11
|
-
conversationKind: "group" | "thread";
|
|
12
|
-
messageSeq: number;
|
|
13
|
-
own?: boolean;
|
|
14
|
-
turn?: ImGapTurnToken;
|
|
15
|
-
outputFingerprint?: string;
|
|
16
|
-
}
|
|
17
|
-
export interface ImAdapterConfig {
|
|
18
|
-
adapter_type?: string;
|
|
19
|
-
workdir?: string;
|
|
20
|
-
model?: string;
|
|
21
|
-
effort?: string;
|
|
22
|
-
provider_agent_id?: string;
|
|
23
|
-
}
|
|
24
|
-
export interface ImCommonConfig {
|
|
25
|
-
bot_id: string;
|
|
26
|
-
bot_name?: string;
|
|
27
|
-
enabled?: boolean;
|
|
28
|
-
adapter: ImAdapterConfig;
|
|
29
|
-
context?: ContextEnvelope;
|
|
30
|
-
approval_mode?: ApprovalMode;
|
|
31
|
-
run_timeout_ms?: number;
|
|
32
|
-
/** Codex 专用的故障恢复预算;不会让其他 Adapter 自动重跑。 */
|
|
33
|
-
codex_retry?: {
|
|
34
|
-
enabled?: boolean;
|
|
35
|
-
max_consecutive_retries?: number;
|
|
36
|
-
max_total_retries?: number;
|
|
37
|
-
recovery_timeout_ms?: number;
|
|
38
|
-
initial_delay_ms?: number;
|
|
39
|
-
max_delay_ms?: number;
|
|
40
|
-
};
|
|
41
|
-
/** 省略沿用平台消息准入;显式名单限制所有频道,空数组拒绝全部发送者。 */
|
|
42
|
-
allowed_sender_ids?: string[];
|
|
43
|
-
}
|
|
44
|
-
export interface OctoBotConfig extends ImCommonConfig {
|
|
45
|
-
api_url: string;
|
|
46
|
-
bf_token?: string;
|
|
47
|
-
/** 自动稳定说明的用户任务刷新周期,默认 30;首轮必带,reset/new 后重新计轮。 */
|
|
48
|
-
stable_context_refresh_interval_turns?: number;
|
|
49
|
-
/** .octospec/tasks/channel-group-admission/plan.md:群/话题入口开关,省略为 true,不影响私聊。 */
|
|
50
|
-
groups_enabled?: boolean;
|
|
51
|
-
/** 仅约束群范围;省略、null、[] 均不增加限制,关闭入口使用 groups_enabled=false。 */
|
|
52
|
-
group_ids?: string[] | null;
|
|
53
|
-
cards?: boolean;
|
|
54
|
-
typing?: boolean;
|
|
55
|
-
/** 渠道固定产物交付;由宿主配置,模型 Context 不能扩大文件访问范围。 */
|
|
56
|
-
artifact_delivery?: {
|
|
57
|
-
mode?: "channel" | "tools";
|
|
58
|
-
/** 可选的 Gateway 本机产物目录限制;省略不额外限制,空列表拒绝全部,不改变 Agent 工作区。 */
|
|
59
|
-
allowed_roots?: string[];
|
|
60
|
-
allowed_mime_types?: string[];
|
|
61
|
-
max_file_bytes?: number;
|
|
62
|
-
max_total_bytes?: number;
|
|
63
|
-
max_files?: number;
|
|
64
|
-
timeout_ms?: number;
|
|
65
|
-
};
|
|
66
|
-
}
|
|
67
|
-
/** 终态回复的冻结投递合同;成功 final 才准备产物,所有终态都遵守当前交付的取消期限。 */
|
|
68
|
-
export interface ImFinalReplyOptions {
|
|
69
|
-
artifacts: ImArtifactPolicy;
|
|
70
|
-
signal: AbortSignal;
|
|
71
|
-
obsolete(): boolean;
|
|
72
|
-
}
|
|
73
|
-
export type ImBotConfig = OctoBotConfig;
|
|
74
|
-
/** Authenticated scope, resolved from octo-auth rather than caller configuration. */
|
|
75
|
-
export type ScopedOctoBotConfig = OctoBotConfig & {
|
|
76
|
-
spaceId: string;
|
|
77
|
-
};
|
|
78
|
-
/** 平台归一化后的单条消息。平台回调身份与正文保留在 connector 的闭包内。 */
|
|
79
|
-
export interface ImInboundMessage {
|
|
80
|
-
position?: {
|
|
81
|
-
messageSeq: number;
|
|
82
|
-
};
|
|
83
|
-
/** 同代次卡片重试:buildContext 返回 Gateway 已组合的冻结快照,不再采集或追加默认项。 */
|
|
84
|
-
historyRetry?: boolean;
|
|
85
|
-
/** 同代次卡片重试复用原投递合同,不从更新后的配置重建文件访问策略。 */
|
|
86
|
-
frozenArtifacts?: ImArtifactPolicy;
|
|
87
|
-
bindHistoryTurn?(token: ImGapTurnToken): void;
|
|
88
|
-
markRead?(signal: AbortSignal): Promise<void>;
|
|
89
|
-
messageId: string;
|
|
90
|
-
senderId: string;
|
|
91
|
-
conversationId: string;
|
|
92
|
-
conversationKind: "direct" | "group" | "thread";
|
|
93
|
-
text: string;
|
|
94
|
-
/** Gateway 群/话题已核验的完整控制命令;null 禁止正文回退,省略沿用 DM/内部调用行为。 */
|
|
95
|
-
sessionControl?: "/reset" | "/new" | "/stop" | null;
|
|
96
|
-
buildInputs?(signal: AbortSignal): Promise<ModelInputPart[]>;
|
|
97
|
-
/** 终态提示也携带该轮投递期限;普通控制回复可省略,不进行产物准备。 */
|
|
98
|
-
reply(text: string, effectKey?: string, options?: Pick<ImFinalReplyOptions, "signal" | "obsolete">): Promise<void>;
|
|
99
|
-
replyFinal?(text: string, effectKey: string, options?: ImFinalReplyOptions): Promise<void>;
|
|
100
|
-
replyFailure?(event: CanonicalEvent, effectKey: string, options?: Pick<ImFinalReplyOptions, "signal" | "obsolete">): Promise<void>;
|
|
101
|
-
buildContext(signal: AbortSignal, options?: {
|
|
102
|
-
initialSession: boolean;
|
|
103
|
-
configuredItems?: readonly ContextItem[];
|
|
104
|
-
historyGap?: ImGapPlan;
|
|
105
|
-
onHistoryGapPrepared?(plan: ImGapPlan): void;
|
|
106
|
-
}): Promise<ContextEnvelope>;
|
|
107
|
-
executionEnvironment?(): InvokeEnvironment;
|
|
108
|
-
runMetadata?: Record<string, unknown>;
|
|
109
|
-
beginPresentation?(runId: string, onDiagnostic: (code: string, data?: Record<string, unknown>) => void, controls: ImRunControls): ImPresentation;
|
|
110
|
-
}
|
|
111
|
-
export interface ImPresentation {
|
|
112
|
-
interaction?(request: InteractionRequestedPayload): Promise<boolean>;
|
|
113
|
-
resolveInteraction?(id: string, status: string): Promise<void>;
|
|
114
|
-
update(snapshot: RunPresentation): void;
|
|
115
|
-
finish(): Promise<void>;
|
|
116
|
-
}
|
|
117
|
-
/** 控制原执行;平台连接器先验证真实操作者和原卡片身份。 */
|
|
118
|
-
export interface ImRunControls {
|
|
119
|
-
respond?(response: InteractionResponse): Promise<void>;
|
|
120
|
-
cancel(): Promise<boolean>;
|
|
121
|
-
retry(senderId: string, occurrenceId: string): boolean;
|
|
122
|
-
}
|
|
123
|
-
export interface ImTaskAttempt {
|
|
124
|
-
runId: string;
|
|
125
|
-
invocationId: string;
|
|
126
|
-
/** not_submitted 是本次调用事实,不是 Provider 执行终态或整轮未执行的证明。 */
|
|
127
|
-
outcome: string;
|
|
128
|
-
failureCode?: string;
|
|
129
|
-
diagnosticId?: string;
|
|
130
|
-
}
|
|
131
|
-
export interface ChannelCallbacks {
|
|
132
|
-
onRulesChanged?(change: {
|
|
133
|
-
groupNo: string;
|
|
134
|
-
shortId?: string;
|
|
135
|
-
}): void;
|
|
136
|
-
onPosition?(position: ImPositionObservation): void;
|
|
137
|
-
/** 已受理任务的 REST 回执位置,归 Bot/任务所有,不要求接收 WS 仍在线。 */
|
|
138
|
-
onTaskPosition?(position: ImPositionObservation): void;
|
|
139
|
-
authorizeSpace?: (spaceId: string) => void;
|
|
140
|
-
onMessage(message: ImInboundMessage): void;
|
|
141
|
-
onDisconnect(code: string, retryable?: boolean): void;
|
|
142
|
-
onDiagnostic?(code: string): void;
|
|
143
|
-
}
|
|
144
|
-
export interface ImAddress {
|
|
145
|
-
channelId: string;
|
|
146
|
-
channelType: number;
|
|
147
|
-
}
|
|
148
|
-
export type ImConnectionState = "stopped" | "connecting" | "online" | "retrying" | "failed";
|
|
149
|
-
export interface ImSession {
|
|
150
|
-
id?: string;
|
|
151
|
-
sessionName?: string;
|
|
152
|
-
generation: number;
|
|
153
|
-
providerSession?: ProviderSession;
|
|
154
|
-
lastEventId?: string;
|
|
155
|
-
lastRunId?: string;
|
|
156
|
-
activeInvocationId?: string;
|
|
157
|
-
pending: number;
|
|
158
|
-
tail: Promise<void>;
|
|
159
|
-
/** 同代次排队快照共享资格对象;reset 替换对象,不修改旧请求。 */
|
|
160
|
-
initialization?: {
|
|
161
|
-
attempted: boolean;
|
|
162
|
-
};
|
|
163
|
-
/** 与初始化资格相同的同代次共享对象,reset 替换而非修改旧轮状态。 */
|
|
164
|
-
stableContext?: ImStableContextState;
|
|
165
|
-
}
|
|
166
|
-
export type DeliveryState = "pending" | "delivered" | "failed" | "unknown";
|
|
167
|
-
export interface ImDeliveryReceipt {
|
|
168
|
-
effectKey: string;
|
|
169
|
-
state: DeliveryState;
|
|
170
|
-
messageId?: string;
|
|
171
|
-
code?: string;
|
|
172
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import type { ContextEnvelope, ContextItem } from "@mininglamp-oss/octo-runtime-protocol";
|
|
2
|
-
import type { OctoBotConfig } from "../contracts.js";
|
|
3
|
-
export interface ImArtifactPolicy {
|
|
4
|
-
mode: "channel" | "tools";
|
|
5
|
-
workspace?: string;
|
|
6
|
-
roots?: string[];
|
|
7
|
-
mimeTypes?: string[];
|
|
8
|
-
maxFileBytes: number;
|
|
9
|
-
maxTotalBytes: number;
|
|
10
|
-
maxFiles: number;
|
|
11
|
-
timeoutMs: number;
|
|
12
|
-
}
|
|
13
|
-
export declare const ARTIFACT_LIMITS: {
|
|
14
|
-
readonly max_file_bytes: number;
|
|
15
|
-
readonly max_total_bytes: number;
|
|
16
|
-
readonly max_files: 16;
|
|
17
|
-
readonly timeout_ms: 30000;
|
|
18
|
-
};
|
|
19
|
-
/** 本地引用均按 Gateway 文件系统尝试读取;仅可信宿主配置可额外限制根目录。 */
|
|
20
|
-
export declare function artifactPolicy(config: OctoBotConfig, context: ContextEnvelope): ImArtifactPolicy;
|
|
21
|
-
/** 默认交付只约定本地引用格式;真实上传策略由代码执行,不以提示词授予访问权限。 */
|
|
22
|
-
export declare function artifactContext(policy: ImArtifactPolicy): ContextItem;
|
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
export const ARTIFACT_LIMITS = {
|
|
2
|
-
max_file_bytes: 20 * 1024 * 1024,
|
|
3
|
-
max_total_bytes: 50 * 1024 * 1024,
|
|
4
|
-
max_files: 16,
|
|
5
|
-
timeout_ms: 30_000
|
|
6
|
-
};
|
|
7
|
-
/** 本地引用均按 Gateway 文件系统尝试读取;仅可信宿主配置可额外限制根目录。 */
|
|
8
|
-
export function artifactPolicy(config, context) {
|
|
9
|
-
const options = config.artifact_delivery;
|
|
10
|
-
const workspace = context.items.find((item) => item.namespace === "octo.execution" && item.name === "workspace")?.payload.path;
|
|
11
|
-
return {
|
|
12
|
-
mode: options?.mode ?? "channel",
|
|
13
|
-
...(typeof workspace === "string" ? { workspace } : {}),
|
|
14
|
-
...(options?.allowed_roots !== undefined ? { roots: [...options.allowed_roots] } : {}),
|
|
15
|
-
...(options?.allowed_mime_types ? { mimeTypes: [...options.allowed_mime_types] } : {}),
|
|
16
|
-
maxFileBytes: options?.max_file_bytes ?? ARTIFACT_LIMITS.max_file_bytes,
|
|
17
|
-
maxTotalBytes: options?.max_total_bytes ?? ARTIFACT_LIMITS.max_total_bytes,
|
|
18
|
-
maxFiles: options?.max_files ?? ARTIFACT_LIMITS.max_files,
|
|
19
|
-
timeoutMs: options?.timeout_ms ?? ARTIFACT_LIMITS.timeout_ms
|
|
20
|
-
};
|
|
21
|
-
}
|
|
22
|
-
/** 默认交付只约定本地引用格式;真实上传策略由代码执行,不以提示词授予访问权限。 */
|
|
23
|
-
export function artifactContext(policy) {
|
|
24
|
-
return {
|
|
25
|
-
namespace: "extra.im",
|
|
26
|
-
name: "artifact-delivery",
|
|
27
|
-
guidance: policy.mode === "channel"
|
|
28
|
-
? "If your final deliverable is a local file, reference it using Markdown with an absolute path: [label](/absolute/path); for images, use ."
|
|
29
|
-
: [
|
|
30
|
-
"This channel does not automatically upload output files.",
|
|
31
|
-
"Use normal tool calls when the task requires file delivery and return recipient-accessible URLs.",
|
|
32
|
-
"Do not present runtime-local paths as downloadable attachments.",
|
|
33
|
-
"Do not send a duplicate final reply with a messaging tool."
|
|
34
|
-
].join("\n"),
|
|
35
|
-
payload: {
|
|
36
|
-
mode: policy.mode,
|
|
37
|
-
...(policy.workspace ? { workspace: policy.workspace } : {}),
|
|
38
|
-
...(policy.roots !== undefined ? { allowedRoots: policy.roots } : {}),
|
|
39
|
-
...(policy.mimeTypes ? { allowedMimeTypes: policy.mimeTypes } : {}),
|
|
40
|
-
maxFileBytes: policy.maxFileBytes,
|
|
41
|
-
maxTotalBytes: policy.maxTotalBytes,
|
|
42
|
-
maxFiles: policy.maxFiles,
|
|
43
|
-
timeoutMs: policy.timeoutMs
|
|
44
|
-
}
|
|
45
|
-
};
|
|
46
|
-
}
|
package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/delivery/artifacts.d.ts
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import type { ImArtifactPolicy } from "./artifact-policy.js";
|
|
2
|
-
export type ArtifactUpload = (bytes: Uint8Array, filename: string, mime: string, signal: AbortSignal) => Promise<string>;
|
|
3
|
-
/** 已核验并上传的文件元数据;不向发送层暴露本机路径。 */
|
|
4
|
-
export interface ArtifactFile {
|
|
5
|
-
url: string;
|
|
6
|
-
name: string;
|
|
7
|
-
size: number;
|
|
8
|
-
extension: string;
|
|
9
|
-
}
|
|
10
|
-
export interface PreparedArtifacts {
|
|
11
|
-
text: string;
|
|
12
|
-
files: ArtifactFile[];
|
|
13
|
-
incomplete?: true;
|
|
14
|
-
}
|
|
15
|
-
/** 只交付成功 final 的显式引用;失败不改变生成终态,缓存由 transport 的 final effect 闭包持有。 */
|
|
16
|
-
export declare function prepareArtifacts(text: string, policy: ImArtifactPolicy, ownerSignal: AbortSignal, upload: ArtifactUpload): Promise<PreparedArtifacts>;
|
package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/delivery/artifacts.js
DELETED
|
@@ -1,285 +0,0 @@
|
|
|
1
|
-
import { constants } from "node:fs";
|
|
2
|
-
import { lstat, open, realpath } from "node:fs/promises";
|
|
3
|
-
import path from "node:path";
|
|
4
|
-
import { fileURLToPath } from "node:url";
|
|
5
|
-
import { fromMarkdown } from "mdast-util-from-markdown";
|
|
6
|
-
import { inferContentType } from "../transport/api/files.js";
|
|
7
|
-
function span(node) {
|
|
8
|
-
const start = node.position?.start.offset, end = node.position?.end.offset;
|
|
9
|
-
return start === undefined || end === undefined ? undefined : { start, end };
|
|
10
|
-
}
|
|
11
|
-
/** AST 决定哪些引用有效,parser token 提供精确地址区间,避免重序列化破坏原 Markdown。 */
|
|
12
|
-
function references(text) {
|
|
13
|
-
const tokens = [];
|
|
14
|
-
const tree = fromMarkdown(text, {
|
|
15
|
-
mdastExtensions: [
|
|
16
|
-
{
|
|
17
|
-
beforeEnter(token) {
|
|
18
|
-
if ([
|
|
19
|
-
"resourceDestinationString",
|
|
20
|
-
"definitionDestinationString",
|
|
21
|
-
"label",
|
|
22
|
-
"definitionTitle"
|
|
23
|
-
].includes(token.type))
|
|
24
|
-
tokens.push({ type: token.type, start: token.start.offset, end: token.end.offset });
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
]
|
|
28
|
-
});
|
|
29
|
-
const definitions = new Map();
|
|
30
|
-
const uses = [];
|
|
31
|
-
const inline = [];
|
|
32
|
-
const visit = (node, blocked = false) => {
|
|
33
|
-
blocked ||= ["blockquote", "code", "inlineCode", "html"].includes(node.type);
|
|
34
|
-
if (node.type === "definition" && node.identifier && !definitions.has(node.identifier))
|
|
35
|
-
definitions.set(node.identifier, { node, blocked });
|
|
36
|
-
if (["linkReference", "imageReference"].includes(node.type))
|
|
37
|
-
uses.push({ node, blocked });
|
|
38
|
-
if (!blocked && ["link", "image"].includes(node.type))
|
|
39
|
-
inline.push(node);
|
|
40
|
-
for (const child of node.children ?? [])
|
|
41
|
-
visit(child, blocked);
|
|
42
|
-
};
|
|
43
|
-
visit(tree);
|
|
44
|
-
const within = (node, type) => {
|
|
45
|
-
const range = span(node);
|
|
46
|
-
return (range &&
|
|
47
|
-
tokens
|
|
48
|
-
.filter((token) => token.type === type && token.start >= range.start && token.end <= range.end)
|
|
49
|
-
.at(-1));
|
|
50
|
-
};
|
|
51
|
-
const targets = [];
|
|
52
|
-
const fileTargets = new Set();
|
|
53
|
-
for (const node of inline) {
|
|
54
|
-
const destination = within(node, "resourceDestinationString");
|
|
55
|
-
if (destination && node.url) {
|
|
56
|
-
targets.push({ ...destination, url: node.url });
|
|
57
|
-
if (node.type === "link")
|
|
58
|
-
fileTargets.add(node.url);
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
const expansions = [];
|
|
62
|
-
const expansionDestinations = new Set();
|
|
63
|
-
const used = new Set();
|
|
64
|
-
for (const use of uses) {
|
|
65
|
-
if (use.blocked || !use.node.identifier)
|
|
66
|
-
continue;
|
|
67
|
-
const definition = definitions.get(use.node.identifier);
|
|
68
|
-
if (!definition?.node.url)
|
|
69
|
-
continue;
|
|
70
|
-
const destination = within(definition.node, "definitionDestinationString");
|
|
71
|
-
if (!destination)
|
|
72
|
-
continue;
|
|
73
|
-
if (use.node.type === "linkReference")
|
|
74
|
-
fileTargets.add(definition.node.url);
|
|
75
|
-
const protectedExample = definition.blocked ||
|
|
76
|
-
uses.some((other) => other.blocked && other.node.identifier === use.node.identifier);
|
|
77
|
-
if (protectedExample) {
|
|
78
|
-
const range = span(use.node), label = tokens.find((token) => token.type === "label" && token.start === range?.start);
|
|
79
|
-
if (range && label) {
|
|
80
|
-
expansions.push({
|
|
81
|
-
range,
|
|
82
|
-
label,
|
|
83
|
-
title: within(definition.node, "definitionTitle"),
|
|
84
|
-
url: definition.node.url
|
|
85
|
-
});
|
|
86
|
-
expansionDestinations.add(`${destination.start}:${destination.end}`);
|
|
87
|
-
targets.push({ ...destination, url: definition.node.url });
|
|
88
|
-
}
|
|
89
|
-
}
|
|
90
|
-
else if (!used.has(use.node.identifier)) {
|
|
91
|
-
targets.push({ ...destination, url: definition.node.url });
|
|
92
|
-
used.add(use.node.identifier);
|
|
93
|
-
}
|
|
94
|
-
}
|
|
95
|
-
return {
|
|
96
|
-
targets,
|
|
97
|
-
fileTargets,
|
|
98
|
-
edits: (urls) => {
|
|
99
|
-
let edits = targets
|
|
100
|
-
.filter((target) => !expansionDestinations.has(`${target.start}:${target.end}`))
|
|
101
|
-
.flatMap((target) => {
|
|
102
|
-
const url = urls.get(target.url);
|
|
103
|
-
return url ? [{ ...target, url }] : [];
|
|
104
|
-
});
|
|
105
|
-
// 内层图片先替换,再将已替换的 label 合入外层引用,避免区间重叠破坏 Markdown。
|
|
106
|
-
for (const entry of expansions.sort((a, b) => a.range.end - a.range.start - (b.range.end - b.range.start))) {
|
|
107
|
-
const url = urls.get(entry.url);
|
|
108
|
-
if (!url)
|
|
109
|
-
continue;
|
|
110
|
-
let label = text.slice(entry.label.start, entry.label.end);
|
|
111
|
-
const nested = edits.filter((edit) => edit.start >= entry.label.start && edit.end <= entry.label.end);
|
|
112
|
-
for (const edit of nested.sort((a, b) => b.start - a.start))
|
|
113
|
-
label =
|
|
114
|
-
label.slice(0, edit.start - entry.label.start) +
|
|
115
|
-
edit.url +
|
|
116
|
-
label.slice(edit.end - entry.label.start);
|
|
117
|
-
edits = edits.filter((edit) => edit.start < entry.range.start || edit.end > entry.range.end);
|
|
118
|
-
edits.push({
|
|
119
|
-
...entry.range,
|
|
120
|
-
url: `${label}(<${url}>${entry.title ? ` ${text.slice(entry.title.start, entry.title.end)}` : ""})`
|
|
121
|
-
});
|
|
122
|
-
}
|
|
123
|
-
return edits;
|
|
124
|
-
}
|
|
125
|
-
};
|
|
126
|
-
}
|
|
127
|
-
function localPath(target, workspace) {
|
|
128
|
-
if (/^file:/i.test(target)) {
|
|
129
|
-
try {
|
|
130
|
-
return fileURLToPath(target);
|
|
131
|
-
}
|
|
132
|
-
catch {
|
|
133
|
-
throw new Error("path-unavailable");
|
|
134
|
-
}
|
|
135
|
-
}
|
|
136
|
-
// 其他操作系统的盘符/UNC 也是本地引用,不能当作外部 URL 跳过或在本机错误拼接。
|
|
137
|
-
if (/^[a-z]:[\\/]/i.test(target) || target.startsWith("\\\\")) {
|
|
138
|
-
if (process.platform !== "win32")
|
|
139
|
-
throw new Error("path-unavailable");
|
|
140
|
-
return target;
|
|
141
|
-
}
|
|
142
|
-
if (/^[a-z][a-z\d+.-]*:/i.test(target) || target.startsWith("//") || target.startsWith("#"))
|
|
143
|
-
return undefined;
|
|
144
|
-
const clean = target.split(/[?#]/, 1)[0];
|
|
145
|
-
let decoded;
|
|
146
|
-
try {
|
|
147
|
-
decoded = decodeURIComponent(clean);
|
|
148
|
-
}
|
|
149
|
-
catch {
|
|
150
|
-
throw new Error("invalid-path");
|
|
151
|
-
}
|
|
152
|
-
if (!decoded || decoded.includes("\0") || decoded.startsWith("~"))
|
|
153
|
-
throw new Error("invalid-path");
|
|
154
|
-
if (path.isAbsolute(decoded))
|
|
155
|
-
return decoded;
|
|
156
|
-
if (!workspace)
|
|
157
|
-
throw new Error("workspace-unavailable");
|
|
158
|
-
return path.resolve(workspace, decoded);
|
|
159
|
-
}
|
|
160
|
-
function contained(root, file) {
|
|
161
|
-
const relative = path.relative(root, file);
|
|
162
|
-
return (relative === "" ||
|
|
163
|
-
(!relative.startsWith(`..${path.sep}`) && relative !== ".." && !path.isAbsolute(relative)));
|
|
164
|
-
}
|
|
165
|
-
function failureName(target) {
|
|
166
|
-
const name = target.split(/[\\/]/).at(-1)?.split(/[?#]/, 1)[0] || "file";
|
|
167
|
-
return name.replace(/[\r\n`[\]<>]/g, "_").slice(0, 120);
|
|
168
|
-
}
|
|
169
|
-
/** 只交付成功 final 的显式引用;失败不改变生成终态,缓存由 transport 的 final effect 闭包持有。 */
|
|
170
|
-
export async function prepareArtifacts(text, policy, ownerSignal, upload) {
|
|
171
|
-
if (policy.mode === "tools")
|
|
172
|
-
return { text, files: [] };
|
|
173
|
-
ownerSignal.throwIfAborted();
|
|
174
|
-
const parsed = references(text);
|
|
175
|
-
const signal = AbortSignal.any([ownerSignal, AbortSignal.timeout(policy.timeoutMs)]);
|
|
176
|
-
const urls = new Map();
|
|
177
|
-
const files = new Map();
|
|
178
|
-
const cards = new Map();
|
|
179
|
-
const failures = [];
|
|
180
|
-
let total = 0;
|
|
181
|
-
let count = 0;
|
|
182
|
-
let roots;
|
|
183
|
-
for (const target of new Set(parsed.targets.map((entry) => entry.url))) {
|
|
184
|
-
try {
|
|
185
|
-
const file = localPath(target, policy.workspace);
|
|
186
|
-
if (file === undefined)
|
|
187
|
-
continue;
|
|
188
|
-
signal.throwIfAborted();
|
|
189
|
-
if (policy.roots !== undefined && !roots)
|
|
190
|
-
roots = await Promise.all(policy.roots.map((root) => realpath(root)));
|
|
191
|
-
const resolved = await realpath(file).catch(() => {
|
|
192
|
-
throw new Error("file-unavailable");
|
|
193
|
-
});
|
|
194
|
-
if (roots && !roots.some((root) => contained(root, resolved)))
|
|
195
|
-
throw new Error("directory-policy");
|
|
196
|
-
let result = files.get(resolved);
|
|
197
|
-
if (!result) {
|
|
198
|
-
if (++count > policy.maxFiles)
|
|
199
|
-
throw new Error("file-count-limit");
|
|
200
|
-
result = (async () => {
|
|
201
|
-
let handle;
|
|
202
|
-
try {
|
|
203
|
-
const entry = await lstat(resolved);
|
|
204
|
-
if (!entry.isFile())
|
|
205
|
-
throw new Error("not-regular-file");
|
|
206
|
-
handle = await open(resolved, constants.O_RDONLY | (constants.O_NOFOLLOW ?? 0) | (constants.O_NONBLOCK ?? 0));
|
|
207
|
-
const stat = await handle.stat();
|
|
208
|
-
if (!stat.isFile() ||
|
|
209
|
-
stat.dev !== entry.dev ||
|
|
210
|
-
stat.ino !== entry.ino ||
|
|
211
|
-
(await realpath(file)) !== resolved)
|
|
212
|
-
throw new Error("file-changed");
|
|
213
|
-
if (stat.size > policy.maxFileBytes)
|
|
214
|
-
throw new Error("file-size-limit");
|
|
215
|
-
if (total + stat.size > policy.maxTotalBytes)
|
|
216
|
-
throw new Error("total-size-limit");
|
|
217
|
-
const mime = inferContentType(resolved);
|
|
218
|
-
if (policy.mimeTypes && !policy.mimeTypes.includes(mime))
|
|
219
|
-
throw new Error("type-policy");
|
|
220
|
-
total += stat.size;
|
|
221
|
-
signal.throwIfAborted();
|
|
222
|
-
// 同一描述符读取且预分配有界容量,文件增长也不能绕过已核验的字节预算。
|
|
223
|
-
const bytes = Buffer.alloc(stat.size);
|
|
224
|
-
let offset = 0;
|
|
225
|
-
while (offset < bytes.length) {
|
|
226
|
-
signal.throwIfAborted();
|
|
227
|
-
const read = await handle.read(bytes, offset, Math.min(64 << 10, bytes.length - offset), offset);
|
|
228
|
-
if (!read.bytesRead)
|
|
229
|
-
throw new Error("file-changed");
|
|
230
|
-
offset += read.bytesRead;
|
|
231
|
-
}
|
|
232
|
-
const after = await handle.stat();
|
|
233
|
-
if (after.size !== stat.size ||
|
|
234
|
-
after.mtimeMs !== stat.mtimeMs ||
|
|
235
|
-
after.ctimeMs !== stat.ctimeMs)
|
|
236
|
-
throw new Error("file-changed");
|
|
237
|
-
signal.throwIfAborted();
|
|
238
|
-
const name = path.basename(resolved);
|
|
239
|
-
return {
|
|
240
|
-
url: await upload(bytes, name, mime, signal),
|
|
241
|
-
name,
|
|
242
|
-
size: bytes.length,
|
|
243
|
-
extension: path.extname(name).slice(1).toLowerCase()
|
|
244
|
-
};
|
|
245
|
-
}
|
|
246
|
-
finally {
|
|
247
|
-
await handle?.close();
|
|
248
|
-
}
|
|
249
|
-
})();
|
|
250
|
-
files.set(resolved, result);
|
|
251
|
-
}
|
|
252
|
-
const artifact = await result;
|
|
253
|
-
if (parsed.fileTargets.has(target))
|
|
254
|
-
cards.set(resolved, artifact);
|
|
255
|
-
// 对最终 Markdown 只写安全地址字节;不让云地址中的括号、空格或实体改变原文结构。
|
|
256
|
-
urls.set(target, artifact.url
|
|
257
|
-
.replace(/[\s()<>"\\]/g, (character) => `%${character.charCodeAt(0).toString(16).toUpperCase()}`)
|
|
258
|
-
.replace(/&/g, "&"));
|
|
259
|
-
}
|
|
260
|
-
catch (error) {
|
|
261
|
-
ownerSignal.throwIfAborted();
|
|
262
|
-
const reason = signal.aborted
|
|
263
|
-
? "delivery-timeout"
|
|
264
|
-
: error instanceof Error && /^[a-z-]+$/.test(error.message)
|
|
265
|
-
? error.message
|
|
266
|
-
: "upload-failed";
|
|
267
|
-
failures.push(`${failureName(target)} (${reason})`);
|
|
268
|
-
}
|
|
269
|
-
}
|
|
270
|
-
ownerSignal.throwIfAborted();
|
|
271
|
-
let output = text;
|
|
272
|
-
const edits = parsed.edits(urls);
|
|
273
|
-
// 同一定义可能被多个 reference 使用,重复区间只替换一次。
|
|
274
|
-
for (const edit of [
|
|
275
|
-
...new Map(edits.map((entry) => [`${entry.start}:${entry.end}`, entry])).values()
|
|
276
|
-
].sort((a, b) => b.start - a.start))
|
|
277
|
-
output = output.slice(0, edit.start) + edit.url + output.slice(edit.end);
|
|
278
|
-
if (failures.length)
|
|
279
|
-
output += `\n\nAttachment delivery failed: ${failures.join("; ")}. These local references are unavailable to channel recipients; generation was not rerun.`;
|
|
280
|
-
return {
|
|
281
|
-
text: output,
|
|
282
|
-
files: [...cards.values()],
|
|
283
|
-
...(failures.length ? { incomplete: true } : {})
|
|
284
|
-
};
|
|
285
|
-
}
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* 投递回执与重试:按 effectKey 记录发送结果,避免已确认的消息重复投递。
|
|
3
|
-
* 只重试投递操作;执行失败或网络结果未知都不能由此触发 AgentRun 重跑。
|
|
4
|
-
*/
|
|
5
|
-
import type { ImDeliveryReceipt } from "../contracts.js";
|
|
6
|
-
export declare class ImDeliveryDispatcher {
|
|
7
|
-
#private;
|
|
8
|
-
readonly signal: AbortSignal;
|
|
9
|
-
constructor(signal: AbortSignal);
|
|
10
|
-
/** 状态仅读取数量,避免复制和输出用于防重的内部回执。 */
|
|
11
|
-
get receiptCount(): number;
|
|
12
|
-
deliver(effectKey: string, operation: () => Promise<string | void>, options?: {
|
|
13
|
-
transient?: boolean;
|
|
14
|
-
/** 仅当前 finalMsg/卡片 finish 显式指定剩余尝试数,包含首发,最多四次。 */
|
|
15
|
-
attempts?: 1 | 2 | 3 | 4;
|
|
16
|
-
obsolete?: () => boolean;
|
|
17
|
-
cardOperation?: "send" | "edit";
|
|
18
|
-
onDiagnostic?: (code: string, data?: Record<string, unknown>) => void;
|
|
19
|
-
}): Promise<ImDeliveryReceipt>;
|
|
20
|
-
}
|
package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/delivery/dispatcher.js
DELETED
|
@@ -1,109 +0,0 @@
|
|
|
1
|
-
import { sanitizeDiagnosticBody } from "@mininglamp-oss/octo-runtime-adapter-sdk";
|
|
2
|
-
import { OctoApiError } from "../transport/api/errors.js";
|
|
3
|
-
import { ImSendError } from "./send-error.js";
|
|
4
|
-
export class ImDeliveryDispatcher {
|
|
5
|
-
signal;
|
|
6
|
-
#receipts = new Map();
|
|
7
|
-
constructor(signal) {
|
|
8
|
-
this.signal = signal;
|
|
9
|
-
}
|
|
10
|
-
/** 状态仅读取数量,避免复制和输出用于防重的内部回执。 */
|
|
11
|
-
get receiptCount() {
|
|
12
|
-
return this.#receipts.size;
|
|
13
|
-
}
|
|
14
|
-
async deliver(effectKey, operation, options = {}) {
|
|
15
|
-
const previous = this.#receipts.get(effectKey);
|
|
16
|
-
if (previous?.state === "delivered")
|
|
17
|
-
return { ...previous };
|
|
18
|
-
const attempts = options.transient ? 1 : (options.attempts ?? 3);
|
|
19
|
-
let receipt = { effectKey, state: "pending" };
|
|
20
|
-
this.#record(receipt);
|
|
21
|
-
for (let attempt = 0; attempt < attempts && !this.signal.aborted; attempt++) {
|
|
22
|
-
if (options.obsolete?.())
|
|
23
|
-
break;
|
|
24
|
-
try {
|
|
25
|
-
const messageId = await operation();
|
|
26
|
-
receipt = { effectKey, state: "delivered", ...(messageId ? { messageId } : {}) };
|
|
27
|
-
this.#record(receipt);
|
|
28
|
-
return receipt;
|
|
29
|
-
}
|
|
30
|
-
catch (error) {
|
|
31
|
-
const status = error instanceof OctoApiError ? error.status : undefined;
|
|
32
|
-
// 无 HTTP 回应时可能已经送达;保留 unknown,不能把网络异常当作确定未发送。
|
|
33
|
-
const state = error instanceof ImSendError ? error.state : status ? "failed" : "unknown";
|
|
34
|
-
receipt = {
|
|
35
|
-
effectKey,
|
|
36
|
-
state: receipt.state === "unknown" ? "unknown" : state,
|
|
37
|
-
code: error instanceof ImSendError
|
|
38
|
-
? error.code
|
|
39
|
-
: status
|
|
40
|
-
? options.cardOperation
|
|
41
|
-
? `IM_CARD_${options.cardOperation.toUpperCase()}_${status}`
|
|
42
|
-
: `IM_HTTP_${status}`
|
|
43
|
-
: "IM_DELIVERY_UNKNOWN"
|
|
44
|
-
};
|
|
45
|
-
this.#record(receipt);
|
|
46
|
-
// HTTP 状态只描述本次投递,不代表业务永久失败;诊断先脱敏再限长,不记录请求正文。
|
|
47
|
-
try {
|
|
48
|
-
options.onDiagnostic?.(receipt.code, options.cardOperation && error instanceof OctoApiError
|
|
49
|
-
? {
|
|
50
|
-
path: error.path.split(/[?#]/, 1)[0],
|
|
51
|
-
http_status: error.status,
|
|
52
|
-
response_body: sanitizeDiagnosticBody(error.body)
|
|
53
|
-
}
|
|
54
|
-
: undefined);
|
|
55
|
-
}
|
|
56
|
-
catch {
|
|
57
|
-
/* 诊断回调失败不得改变投递结果或触发额外发送。 */
|
|
58
|
-
}
|
|
59
|
-
// 仅本轮 REST 收尾可重试未知响应;明确取消/拒绝立即结束,不另开确认窗口。
|
|
60
|
-
if (error instanceof ImSendError && !(options.attempts && error.state === "unknown"))
|
|
61
|
-
break;
|
|
62
|
-
if (status && status !== 429 && status < 500)
|
|
63
|
-
break;
|
|
64
|
-
if (attempt + 1 === attempts)
|
|
65
|
-
break;
|
|
66
|
-
const delay = error instanceof OctoApiError && status === 429
|
|
67
|
-
? error.retryAfterMs
|
|
68
|
-
: 200 * (attempt + 1);
|
|
69
|
-
if (delay > 3_000)
|
|
70
|
-
break;
|
|
71
|
-
try {
|
|
72
|
-
await new Promise((resolve, reject) => {
|
|
73
|
-
const abort = () => {
|
|
74
|
-
clearTimeout(timer);
|
|
75
|
-
this.signal.removeEventListener("abort", abort);
|
|
76
|
-
reject(new Error("IM_DELIVERY_CANCELLED"));
|
|
77
|
-
};
|
|
78
|
-
const timer = setTimeout(() => {
|
|
79
|
-
this.signal.removeEventListener("abort", abort);
|
|
80
|
-
resolve();
|
|
81
|
-
}, delay);
|
|
82
|
-
this.signal.addEventListener("abort", abort, { once: true });
|
|
83
|
-
if (this.signal.aborted)
|
|
84
|
-
abort();
|
|
85
|
-
});
|
|
86
|
-
}
|
|
87
|
-
catch {
|
|
88
|
-
break;
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
}
|
|
92
|
-
if (receipt.state === "pending") {
|
|
93
|
-
receipt = { effectKey, state: "failed", code: "IM_DELIVERY_CANCELLED" };
|
|
94
|
-
try {
|
|
95
|
-
options.onDiagnostic?.(receipt.code);
|
|
96
|
-
}
|
|
97
|
-
catch {
|
|
98
|
-
/* 取消诊断同样不能阻断清理。 */
|
|
99
|
-
}
|
|
100
|
-
}
|
|
101
|
-
this.#record(receipt);
|
|
102
|
-
return receipt;
|
|
103
|
-
}
|
|
104
|
-
#record(receipt) {
|
|
105
|
-
this.#receipts.set(receipt.effectKey, receipt);
|
|
106
|
-
if (this.#receipts.size > 512)
|
|
107
|
-
this.#receipts.delete(this.#receipts.keys().next().value);
|
|
108
|
-
}
|
|
109
|
-
}
|