@opengeni/worker-bundle 2.0.1 → 2.0.2-canary.38789554071001
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/activities/agent-run-admission.d.ts +1 -12
- package/dist/activities/agent-turn/admission.d.ts +88 -10
- package/dist/activities/agent-turn/agent-build.d.ts +14 -3
- package/dist/activities/agent-turn/claim.d.ts +4 -1
- package/dist/activities/agent-turn/claude-core.d.ts +195 -0
- package/dist/activities/agent-turn/code-search.d.ts +60 -0
- package/dist/activities/agent-turn/codex-capacity.d.ts +3 -0
- package/dist/activities/agent-turn/codex-core-capacity.d.ts +37 -0
- package/dist/activities/agent-turn/codex-core-claim.d.ts +40 -0
- package/dist/activities/agent-turn/codex-core-errors.d.ts +102 -0
- package/dist/activities/agent-turn/codex-core-failover.d.ts +15 -0
- package/dist/activities/agent-turn/codex-core-requests.d.ts +28 -0
- package/dist/activities/agent-turn/codex-core-settlement.d.ts +77 -0
- package/dist/activities/agent-turn/codex-credit-policy.d.ts +30 -0
- package/dist/activities/agent-turn/codex-plan-entitlement.d.ts +105 -0
- package/dist/activities/agent-turn/codex-usage-policy.d.ts +2 -0
- package/dist/activities/agent-turn/codex.d.ts +2 -19
- package/dist/activities/agent-turn/compaction-interruption.d.ts +32 -0
- package/dist/activities/agent-turn/compaction-prep.d.ts +30 -1
- package/dist/activities/agent-turn/credential-leases.d.ts +64 -37
- package/dist/activities/agent-turn/credential-restriction.d.ts +3 -0
- package/dist/activities/agent-turn/errors.d.ts +185 -26
- package/dist/activities/agent-turn/failure-settlement.d.ts +10 -43
- package/dist/activities/agent-turn/final-reply.d.ts +18 -0
- package/dist/activities/agent-turn/finalization-monitor.d.ts +7 -2
- package/dist/activities/agent-turn/finalization.d.ts +2 -0
- package/dist/activities/agent-turn/github-repository-bindings.d.ts +2 -0
- package/dist/activities/agent-turn/governance-model.d.ts +13 -1
- package/dist/activities/agent-turn/history-sink.d.ts +4 -1
- package/dist/activities/agent-turn/history.d.ts +2 -0
- package/dist/activities/agent-turn/input-wait-reply.d.ts +76 -0
- package/dist/activities/agent-turn/meaningful-output.d.ts +9 -0
- package/dist/activities/agent-turn/media-artifacts.d.ts +5 -3
- package/dist/activities/agent-turn/model-call-admission.d.ts +15 -0
- package/dist/activities/agent-turn/model-usage.d.ts +56 -14
- package/dist/activities/agent-turn/model-wire-dispatch.d.ts +15 -0
- package/dist/activities/agent-turn/optional-repositories.d.ts +59 -0
- package/dist/activities/agent-turn/prompt-tool-availability.d.ts +17 -0
- package/dist/activities/agent-turn/provider-dispatch-barrier.d.ts +12 -1
- package/dist/activities/agent-turn/provider-recovery-copy.d.ts +24 -0
- package/dist/activities/agent-turn/provider-recovery-metrics.d.ts +18 -0
- package/dist/activities/agent-turn/provider-recovery-policy.d.ts +6 -0
- package/dist/activities/agent-turn/quiescence.d.ts +6 -7
- package/dist/activities/agent-turn/recovery-warning.d.ts +6 -5
- package/dist/activities/agent-turn/refresh-credentials.d.ts +6 -0
- package/dist/activities/agent-turn/run-credentials.d.ts +9 -5
- package/dist/activities/agent-turn/run.d.ts +27 -2
- package/dist/activities/agent-turn/sandbox-establish.d.ts +1 -0
- package/dist/activities/agent-turn/sandbox-provision.d.ts +25 -1
- package/dist/activities/agent-turn/sandbox-route.d.ts +3 -0
- package/dist/activities/agent-turn/sandbox-runtime.d.ts +1 -1
- package/dist/activities/agent-turn/secret-resolver.d.ts +64 -0
- package/dist/activities/agent-turn/session-title.d.ts +60 -3
- package/dist/activities/agent-turn/session-usage-custody.d.ts +66 -0
- package/dist/activities/agent-turn/skill-checkout.d.ts +25 -6
- package/dist/activities/agent-turn/skill-read.d.ts +70 -2
- package/dist/activities/agent-turn/skill-search.d.ts +2 -0
- package/dist/activities/agent-turn/skill-tools.d.ts +41 -4
- package/dist/activities/agent-turn/skill-transfer.d.ts +18 -6
- package/dist/activities/agent-turn/stream-attempt.d.ts +6 -3
- package/dist/activities/agent-turn/subscription-capacity-arming.d.ts +41 -0
- package/dist/activities/agent-turn/subscription-core-capacity.d.ts +86 -0
- package/dist/activities/agent-turn/subscription-core-failover.d.ts +69 -0
- package/dist/activities/agent-turn/subscription-core-placed.d.ts +14 -0
- package/dist/activities/agent-turn/subscription-core-requests.d.ts +109 -0
- package/dist/activities/agent-turn/subscription-core-settlement.d.ts +112 -0
- package/dist/activities/agent-turn/subscription-lease.d.ts +44 -0
- package/dist/activities/agent-turn/subscription-serving-capacity.d.ts +6 -0
- package/dist/activities/agent-turn/subscription-serving-catalog.d.ts +13 -0
- package/dist/activities/agent-turn/subscription-serving-claim.d.ts +30 -0
- package/dist/activities/agent-turn/subscription-serving-providers.d.ts +2 -0
- package/dist/activities/agent-turn/tool-environment.d.ts +31 -6
- package/dist/activities/agent-turn/tool-policy.d.ts +55 -3
- package/dist/activities/agent-turn/turn-context.d.ts +104 -5
- package/dist/activities/agent-turn/web-search.d.ts +57 -0
- package/dist/activities/agent-turn/xai-core.d.ts +96 -0
- package/dist/activities/automations.d.ts +3 -1
- package/dist/activities/browser-deadline-checkpoint.d.ts +34 -0
- package/dist/activities/capabilities.d.ts +8 -20
- package/dist/activities/codemode-dispatcher.d.ts +20 -3
- package/dist/activities/codex-capacity.d.ts +1 -56
- package/dist/activities/codex-image-generation.d.ts +49 -3
- package/dist/activities/common.d.ts +3 -1
- package/dist/activities/context-compaction.d.ts +41 -2
- package/dist/activities/environment.d.ts +1 -19
- package/dist/activities/gmail-files.d.ts +50 -0
- package/dist/activities/goals.d.ts +1 -9
- package/dist/activities/incident-telemetry-authority.d.ts +5 -2
- package/dist/activities/incident-telemetry-preflight.d.ts +10 -3
- package/dist/activities/knowledge-indexing.d.ts +19 -0
- package/dist/activities/mcp-account-routes.d.ts +2 -21
- package/dist/activities/model-call-fact-reconciler.d.ts +34 -0
- package/dist/activities/open-suffix-resume.d.ts +15 -0
- package/dist/activities/parent-wake.d.ts +17 -12
- package/dist/activities/programmatic-approvals.d.ts +10 -0
- package/dist/activities/requester-unavailable-receipt.d.ts +8 -0
- package/dist/activities/retained-screenshots.d.ts +7 -2
- package/dist/activities/run-credential-renewal.d.ts +1 -0
- package/dist/activities/run-credentials.d.ts +16 -4
- package/dist/activities/run-input.d.ts +17 -0
- package/dist/activities/sandbox-lease.d.ts +132 -12
- package/dist/activities/scheduled-tasks.d.ts +4 -35
- package/dist/activities/session-archive.d.ts +58 -0
- package/dist/activities/session-state.d.ts +15 -3
- package/dist/activities/session-storage.d.ts +44 -0
- package/dist/activities/subscription-core-claude-waits.d.ts +2 -0
- package/dist/activities/subscription-core-codex-quota.d.ts +25 -0
- package/dist/activities/subscription-core-codex-waits.d.ts +153 -0
- package/dist/activities/subscription-core-image-operation.d.ts +29 -0
- package/dist/activities/subscription-core-usage-recheck.d.ts +49 -0
- package/dist/activities/subscription-core-wait-bindings.d.ts +3 -0
- package/dist/activities/subscription-core-xai-quota.d.ts +30 -0
- package/dist/activities/subscription-core-xai-waits.d.ts +2 -0
- package/dist/activities/types.d.ts +68 -5
- package/dist/activities/video-generation-admission.d.ts +2 -8
- package/dist/activities/video-generation-credential.d.ts +15 -12
- package/dist/activities/video-generation-subscription-core.d.ts +70 -0
- package/dist/activities/workspace-capture.d.ts +2 -0
- package/dist/activities/workspace-credential-provider.d.ts +47 -0
- package/dist/activities/xai-auth.d.ts +6 -18
- package/dist/activities/xai-image-generation.d.ts +22 -6
- package/dist/{activities-control-QA6OLRQY.js → activities-control-5IIVRXLA.js} +1569 -2883
- package/dist/activities-control-5IIVRXLA.js.map +1 -0
- package/dist/activities-control.d.ts +64 -4
- package/dist/{activities-turn-YVVKCGAK.js → activities-turn-FLYJOM54.js} +9300 -4403
- package/dist/activities-turn-FLYJOM54.js.map +1 -0
- package/dist/activities.d.ts +64 -4
- package/dist/artifact-materializer-entry.js +107 -36
- package/dist/artifact-materializer-entry.js.map +1 -1
- package/dist/artifact-outbox-entry.js +132 -61
- package/dist/artifact-outbox-entry.js.map +1 -1
- package/dist/browser-deadline-checkpoint-contract.d.ts +2 -0
- package/dist/{chunk-GDCLDKSH.js → chunk-24GP3BX5.js} +79 -72
- package/dist/chunk-24GP3BX5.js.map +1 -0
- package/dist/{chunk-RAMNYSAW.js → chunk-4ER3YXOT.js} +22 -4
- package/dist/chunk-4ER3YXOT.js.map +1 -0
- package/dist/{chunk-I7HKKMUJ.js → chunk-5NNS4327.js} +734 -58
- package/dist/chunk-5NNS4327.js.map +1 -0
- package/dist/chunk-MVESOYFC.js +3746 -0
- package/dist/chunk-MVESOYFC.js.map +1 -0
- package/dist/{chunk-M3NVMF2V.js → chunk-N57B3PJ5.js} +2307 -3951
- package/dist/chunk-N57B3PJ5.js.map +1 -0
- package/dist/chunk-NQDVJ6RI.js +2823 -0
- package/dist/chunk-NQDVJ6RI.js.map +1 -0
- package/dist/chunk-O7UPBWXK.js +79 -0
- package/dist/chunk-O7UPBWXK.js.map +1 -0
- package/dist/chunk-W2QSM5HR.js +414 -0
- package/dist/chunk-W2QSM5HR.js.map +1 -0
- package/dist/chunk-ZN3XJR33.js +227 -0
- package/dist/chunk-ZN3XJR33.js.map +1 -0
- package/dist/editable-artifact-outbox-dispatcher.d.ts +12 -1
- package/dist/editable-artifact-outbox-service.d.ts +3 -1
- package/dist/host-export-pump.d.ts +3 -1
- package/dist/host-export.d.ts +2 -2
- package/dist/host-export.js +1 -1
- package/dist/http.d.ts +1 -1
- package/dist/index.d.ts +49 -48
- package/dist/index.js +835 -256
- package/dist/index.js.map +1 -1
- package/dist/internal-maintenance.d.ts +63 -0
- package/dist/maintenance-cadence.d.ts +43 -0
- package/dist/observability-metrics.d.ts +293 -24
- package/dist/onepassword-vault-provider.d.ts +7 -0
- package/dist/parent-wake-PCLH7A3Y.js +24 -0
- package/dist/parent-wake-PCLH7A3Y.js.map +1 -0
- package/dist/personal-github-git-credentials.d.ts +1 -1
- package/dist/readiness-checks.d.ts +39 -0
- package/dist/retained-process-retry.d.ts +7 -0
- package/dist/sandbox-lease-BJYU72N3.js +84 -0
- package/dist/sandbox-lease-BJYU72N3.js.map +1 -0
- package/dist/sandbox-reaper-contract.d.ts +25 -0
- package/dist/sandbox-resume.d.ts +72 -4
- package/dist/sandbox-routing.d.ts +4 -2
- package/dist/session-event-fanout.d.ts +6 -0
- package/dist/site-auth-maintenance-WK3MR2PV.js +12 -0
- package/dist/site-auth-maintenance-WK3MR2PV.js.map +1 -0
- package/dist/telemetry-scheduler.d.ts +14 -0
- package/dist/temporal-runtime-logger.d.ts +22 -0
- package/dist/turn-task-queue-reader.d.ts +18 -0
- package/dist/turn-worker-activity-telemetry.d.ts +47 -0
- package/dist/worker-service-lifecycle.d.ts +12 -0
- package/dist/workflow-bundle.js +468 -71
- package/dist/workflows/activities.d.ts +1 -1
- package/dist/workflows/browser-deadline-checkpoint.d.ts +10 -0
- package/dist/workflows/sandbox-reaper.d.ts +10 -1
- package/dist/workflows/scheduled-tasks.d.ts +4 -0
- package/dist/workflows/session-storage.d.ts +2 -0
- package/dist/workflows/session.d.ts +36 -0
- package/dist/workflows/site-auth-maintenance.d.ts +2 -1
- package/dist/workflows/workflow-wake.d.ts +14 -3
- package/dist/workflows.d.ts +3 -1
- package/package.json +26 -20
- package/src/activities/agent-run-admission.ts +1 -82
- package/src/activities/agent-turn/admission.ts +175 -24
- package/src/activities/agent-turn/agent-build.ts +226 -145
- package/src/activities/agent-turn/claim.ts +363 -64
- package/src/activities/agent-turn/claude-core.ts +587 -0
- package/src/activities/agent-turn/code-search.ts +275 -0
- package/src/activities/agent-turn/codex-capacity.ts +30 -757
- package/src/activities/agent-turn/codex-core-capacity.ts +190 -0
- package/src/activities/agent-turn/codex-core-claim.ts +83 -0
- package/src/activities/agent-turn/codex-core-errors.ts +308 -0
- package/src/activities/agent-turn/codex-core-failover.ts +73 -0
- package/src/activities/agent-turn/codex-core-requests.ts +86 -0
- package/src/activities/agent-turn/codex-core-settlement.ts +263 -0
- package/src/activities/agent-turn/codex-credit-policy.ts +247 -0
- package/src/activities/agent-turn/codex-plan-entitlement.ts +254 -0
- package/src/activities/agent-turn/codex-usage-policy.ts +2 -0
- package/src/activities/agent-turn/codex.ts +8 -76
- package/src/activities/agent-turn/compaction-interruption.ts +56 -0
- package/src/activities/agent-turn/compaction-prep.ts +249 -36
- package/src/activities/agent-turn/credential-leases.ts +269 -214
- package/src/activities/agent-turn/credential-restriction.ts +14 -0
- package/src/activities/agent-turn/errors.ts +1152 -82
- package/src/activities/agent-turn/failure-settlement.ts +879 -886
- package/src/activities/agent-turn/final-reply.ts +46 -0
- package/src/activities/agent-turn/finalization-monitor.ts +17 -5
- package/src/activities/agent-turn/finalization.ts +107 -88
- package/src/activities/agent-turn/github-repository-bindings.ts +3 -1
- package/src/activities/agent-turn/governance-model.ts +90 -22
- package/src/activities/agent-turn/history-sink.ts +42 -12
- package/src/activities/agent-turn/history.ts +25 -5
- package/src/activities/agent-turn/input-wait-reply.ts +139 -0
- package/src/activities/agent-turn/knowledge-source-tools.ts +2 -0
- package/src/activities/agent-turn/meaningful-output.ts +44 -0
- package/src/activities/agent-turn/media-artifacts.ts +3 -1
- package/src/activities/agent-turn/model-call-admission.ts +114 -0
- package/src/activities/agent-turn/model-usage.ts +299 -233
- package/src/activities/agent-turn/model-wire-dispatch.ts +27 -0
- package/src/activities/agent-turn/optional-repositories.ts +224 -0
- package/src/activities/agent-turn/prompt-tool-availability.ts +27 -0
- package/src/activities/agent-turn/provider-dispatch-barrier.ts +22 -0
- package/src/activities/agent-turn/provider-recovery-copy.ts +76 -0
- package/src/activities/agent-turn/provider-recovery-metrics.ts +64 -0
- package/src/activities/agent-turn/provider-recovery-policy.ts +25 -0
- package/src/activities/agent-turn/quiescence.ts +7 -7
- package/src/activities/agent-turn/recovery-warning.ts +6 -8
- package/src/activities/agent-turn/refresh-credentials.ts +44 -0
- package/src/activities/agent-turn/run-credentials.ts +124 -76
- package/src/activities/agent-turn/run.ts +501 -112
- package/src/activities/agent-turn/sandbox-establish.ts +152 -75
- package/src/activities/agent-turn/sandbox-provision.ts +54 -1
- package/src/activities/agent-turn/sandbox-route.ts +4 -1
- package/src/activities/agent-turn/sandbox-runtime.ts +319 -11
- package/src/activities/agent-turn/secret-resolver.ts +155 -0
- package/src/activities/agent-turn/session-title.ts +177 -12
- package/src/activities/agent-turn/session-usage-custody.ts +170 -0
- package/src/activities/agent-turn/skill-checkout.ts +111 -24
- package/src/activities/agent-turn/skill-install.ts +1 -1
- package/src/activities/agent-turn/skill-read.ts +374 -28
- package/src/activities/agent-turn/skill-save.ts +35 -7
- package/src/activities/agent-turn/skill-search.ts +9 -0
- package/src/activities/agent-turn/skill-selection.ts +4 -0
- package/src/activities/agent-turn/skill-tools.ts +208 -21
- package/src/activities/agent-turn/skill-transfer.ts +68 -23
- package/src/activities/agent-turn/stream-attempt.ts +634 -111
- package/src/activities/agent-turn/subscription-capacity-arming.ts +81 -0
- package/src/activities/agent-turn/subscription-core-capacity.ts +439 -0
- package/src/activities/agent-turn/subscription-core-failover.ts +229 -0
- package/src/activities/agent-turn/subscription-core-placed.ts +37 -0
- package/src/activities/agent-turn/subscription-core-requests.ts +271 -0
- package/src/activities/agent-turn/subscription-core-settlement.ts +234 -0
- package/src/activities/agent-turn/subscription-lease.ts +140 -0
- package/src/activities/agent-turn/subscription-serving-capacity.ts +195 -0
- package/src/activities/agent-turn/subscription-serving-catalog.ts +71 -0
- package/src/activities/agent-turn/subscription-serving-claim.ts +178 -0
- package/src/activities/agent-turn/subscription-serving-providers.ts +15 -0
- package/src/activities/agent-turn/tool-environment.ts +384 -292
- package/src/activities/agent-turn/tool-policy.ts +104 -4
- package/src/activities/agent-turn/tool-result-spill.ts +1 -0
- package/src/activities/agent-turn/turn-context.ts +124 -8
- package/src/activities/agent-turn/web-search.ts +431 -0
- package/src/activities/agent-turn/xai-core.ts +301 -0
- package/src/activities/automations.ts +81 -6
- package/src/activities/browser-deadline-checkpoint.ts +297 -0
- package/src/activities/capabilities.ts +53 -213
- package/src/activities/codemode-dispatcher.ts +236 -14
- package/src/activities/codex-capacity.ts +27 -380
- package/src/activities/codex-image-generation.ts +252 -42
- package/src/activities/common.ts +12 -0
- package/src/activities/connector-attachments.ts +3 -1
- package/src/activities/context-compaction.ts +182 -21
- package/src/activities/environment.ts +18 -106
- package/src/activities/gmail-files.ts +108 -0
- package/src/activities/goals.ts +120 -204
- package/src/activities/image-generation-operation.ts +1 -1
- package/src/activities/incident-telemetry-authority.ts +80 -50
- package/src/activities/incident-telemetry-preflight.ts +27 -15
- package/src/activities/knowledge-indexing.ts +287 -17
- package/src/activities/knowledge-source-sync.ts +10 -0
- package/src/activities/mcp-account-routes.ts +2 -124
- package/src/activities/model-call-fact-reconciler.ts +112 -0
- package/src/activities/open-suffix-resume.ts +122 -88
- package/src/activities/parent-wake.ts +89 -21
- package/src/activities/programmatic-approvals.ts +26 -0
- package/src/activities/requester-unavailable-receipt.ts +14 -0
- package/src/activities/retained-screenshots.ts +135 -24
- package/src/activities/run-credential-renewal.ts +13 -1
- package/src/activities/run-credentials.ts +61 -19
- package/src/activities/run-input.ts +124 -9
- package/src/activities/sandbox-lease.ts +1615 -73
- package/src/activities/scheduled-tasks.ts +780 -147
- package/src/activities/session-archive.ts +382 -0
- package/src/activities/session-state.ts +219 -10
- package/src/activities/session-storage.ts +124 -0
- package/src/activities/site-auth-maintenance.ts +5 -2
- package/src/activities/subscription-core-claude-waits.ts +49 -0
- package/src/activities/subscription-core-codex-quota.ts +46 -0
- package/src/activities/subscription-core-codex-waits.ts +488 -0
- package/src/activities/subscription-core-image-operation.ts +126 -0
- package/src/activities/subscription-core-usage-recheck.ts +146 -0
- package/src/activities/subscription-core-wait-bindings.ts +12 -0
- package/src/activities/subscription-core-xai-quota.ts +85 -0
- package/src/activities/subscription-core-xai-waits.ts +48 -0
- package/src/activities/types.ts +85 -9
- package/src/activities/video-generation-admission.ts +1 -36
- package/src/activities/video-generation-credential.ts +38 -56
- package/src/activities/video-generation-reconciliation.ts +150 -131
- package/src/activities/video-generation-subscription-core.ts +180 -0
- package/src/activities/workspace-capture.ts +13 -2
- package/src/activities/workspace-credential-provider.ts +302 -0
- package/src/activities/xai-auth.ts +34 -112
- package/src/activities/xai-image-generation.ts +84 -36
- package/src/activities-control.ts +8 -0
- package/src/activities-turn.ts +5 -0
- package/src/activities.ts +17 -0
- package/src/activity-services.ts +29 -4
- package/src/browser-deadline-checkpoint-contract.ts +5 -0
- package/src/editable-artifact-hint-broker.ts +3 -0
- package/src/editable-artifact-materializer-service.ts +85 -39
- package/src/editable-artifact-materializer-subprocess.ts +47 -2
- package/src/editable-artifact-outbox-dispatcher.ts +107 -46
- package/src/editable-artifact-outbox-service.ts +55 -25
- package/src/github-rest-mcp.ts +1 -1
- package/src/host-export-pump.ts +26 -4
- package/src/host-export.ts +4 -1
- package/src/http.ts +4 -2
- package/src/index.ts +222 -282
- package/src/internal-maintenance.ts +347 -0
- package/src/maintenance-cadence.ts +156 -0
- package/src/observability-metrics.ts +1173 -73
- package/src/onepassword-vault-provider.ts +11 -0
- package/src/personal-github-git-credentials.ts +3 -1
- package/src/pr-review-credentials.ts +1 -1
- package/src/readiness-checks.ts +113 -0
- package/src/retained-process-retry.ts +36 -0
- package/src/sandbox-reaper-contract.ts +33 -0
- package/src/sandbox-resume.ts +444 -73
- package/src/sandbox-routing.ts +230 -75
- package/src/session-event-fanout.ts +23 -0
- package/src/telemetry-scheduler.ts +53 -0
- package/src/temporal-runtime-logger.ts +44 -0
- package/src/turn-task-queue-reader.ts +110 -0
- package/src/turn-worker-activity-telemetry.ts +209 -0
- package/src/worker-service-lifecycle.ts +54 -1
- package/src/workflows/activities.ts +16 -1
- package/src/workflows/browser-deadline-checkpoint.ts +55 -0
- package/src/workflows/file-upload-reaper.ts +2 -0
- package/src/workflows/sandbox-reaper.ts +88 -0
- package/src/workflows/scheduled-tasks.ts +26 -13
- package/src/workflows/session-storage.ts +19 -0
- package/src/workflows/session.ts +238 -33
- package/src/workflows/site-auth-maintenance.ts +2 -1
- package/src/workflows/workflow-wake.ts +26 -4
- package/src/workflows.ts +7 -0
- package/dist/activities/agent-turn/xai-capacity.d.ts +0 -2
- package/dist/activities/codex-fleet-shadow.d.ts +0 -74
- package/dist/activities/codex-rotation.d.ts +0 -200
- package/dist/activities/xai-quota.d.ts +0 -3
- package/dist/activities-control-QA6OLRQY.js.map +0 -1
- package/dist/activities-turn-YVVKCGAK.js.map +0 -1
- package/dist/chunk-GDCLDKSH.js.map +0 -1
- package/dist/chunk-I7HKKMUJ.js.map +0 -1
- package/dist/chunk-M3NVMF2V.js.map +0 -1
- package/dist/chunk-RAMNYSAW.js.map +0 -1
- package/src/activities/agent-turn/xai-capacity.ts +0 -257
- package/src/activities/codex-fleet-shadow.ts +0 -306
- package/src/activities/codex-rotation.ts +0 -685
- package/src/activities/xai-quota.ts +0 -35
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import type { TurnHeartbeatDetails } from "../../op-journal.js";
|
|
2
2
|
import type { Settings } from "@opengeni/config";
|
|
3
3
|
import type { CodexUsageHeaderSnapshot } from "@opengeni/codex";
|
|
4
|
-
import type { AppendEventInput, ApplySessionTurnSettlementInput } from "@opengeni/db";
|
|
5
|
-
import type { CodexCredentialPolicySnapshotV1, ModelContextContributionSummary, SessionStatus
|
|
4
|
+
import type { AppendEventInput, ApplySessionTurnSettlementInput, SubscriptionCoreTurnIdentity } from "@opengeni/db";
|
|
5
|
+
import type { CodexCredentialPolicySnapshotV1, ModelContextContributionSummary, SessionStatus } from "@opengeni/contracts";
|
|
6
6
|
import type { EstablishedSandboxSession, OpenGeniRuntime, RunCredentialCommandSession, SelfhostedSession, TurnToolCancellationFence } from "@opengeni/runtime";
|
|
7
7
|
import type { XaiSubscriptionRequestContext } from "@opengeni/xai-subscription";
|
|
8
8
|
import type { CodemodeAttemptDispatcher } from "../codemode-dispatcher.js";
|
|
@@ -15,6 +15,7 @@ import type { TurnOutcome } from "../../observability-metrics.js";
|
|
|
15
15
|
import type { ResumedTurnSandbox, TurnSandboxLeaseHolderId } from "../../sandbox-resume.js";
|
|
16
16
|
import type { TurnEventPublisher } from "./model-usage.js";
|
|
17
17
|
import type { TurnSandboxProvisioner } from "./sandbox-provision.js";
|
|
18
|
+
import { InitialModelWireDispatchClock } from "./model-wire-dispatch.js";
|
|
18
19
|
/** Stamps the claimed turn/attempt ids onto a phase's own outcome. */
|
|
19
20
|
export type ClaimedResult = (result: Omit<Extract<RunAgentTurnResult, {
|
|
20
21
|
status: Exclude<RunAgentTurnResult["status"], "unclaimed">;
|
|
@@ -25,8 +26,10 @@ export type TurnSettleFn = (input: {
|
|
|
25
26
|
sessionStatus: SessionStatus;
|
|
26
27
|
activeTurnId: string | null;
|
|
27
28
|
suppressGoalContinuation?: boolean;
|
|
29
|
+
allowanceGoalPause?: ApplySessionTurnSettlementInput["allowanceGoalPause"];
|
|
28
30
|
consumeRequestedCompactionFailure?: boolean;
|
|
29
31
|
runState?: ApplySessionTurnSettlementInput["runState"];
|
|
32
|
+
notStartedToolCallIds?: readonly string[];
|
|
30
33
|
}) => Promise<boolean>;
|
|
31
34
|
export type TurnControlState = {
|
|
32
35
|
cancellationRequestedAt: number | null;
|
|
@@ -41,6 +44,25 @@ export type AttemptIdentityState = {
|
|
|
41
44
|
triggerEventId: string | undefined;
|
|
42
45
|
executionGeneration: number;
|
|
43
46
|
providerRecoveryCount: number;
|
|
47
|
+
/** Durable recovery policy reason; never inferred from display wording. */
|
|
48
|
+
providerRecoveryPolicyCode?: string | undefined;
|
|
49
|
+
providerRecoveryStartedAt?: number | undefined;
|
|
50
|
+
providerRecoveryObservation?: import("./provider-recovery-metrics.js").ProviderRecoveryObservation | undefined;
|
|
51
|
+
modelMetricRoute?: {
|
|
52
|
+
provider: string;
|
|
53
|
+
model: string;
|
|
54
|
+
};
|
|
55
|
+
/** Public display labels of the accepted model route, for recovery copy only. */
|
|
56
|
+
modelRoutePresentation?: {
|
|
57
|
+
model: string;
|
|
58
|
+
modelLabel: string;
|
|
59
|
+
providerLabel: string;
|
|
60
|
+
};
|
|
61
|
+
/** The stored shared-core lease-busy chain this turn's previous attempt recorded. */
|
|
62
|
+
subscriptionLeaseBusy?: {
|
|
63
|
+
startedAt: number;
|
|
64
|
+
executionGeneration: number;
|
|
65
|
+
} | undefined;
|
|
44
66
|
modelRequestStarted: boolean;
|
|
45
67
|
redispatchesAtDispatch: number;
|
|
46
68
|
triggerType: string | null;
|
|
@@ -48,6 +70,7 @@ export type AttemptIdentityState = {
|
|
|
48
70
|
export type BillingState = {
|
|
49
71
|
isCodexTurn: boolean;
|
|
50
72
|
isXaiTurn: boolean;
|
|
73
|
+
isClaudeTurn: boolean;
|
|
51
74
|
isExternallyBilledTurn: boolean;
|
|
52
75
|
chargesOpenGeniCredits: boolean;
|
|
53
76
|
countsTowardTokenCap: boolean;
|
|
@@ -66,6 +89,9 @@ export type SandboxRuntimeState = {
|
|
|
66
89
|
}>;
|
|
67
90
|
turnSandboxProvisioner: TurnSandboxProvisioner<ResumedTurnSandbox> | null;
|
|
68
91
|
resumeManagedGroupBox: (() => Promise<ResumedTurnSandbox>) | null;
|
|
92
|
+
/** Physical resumeBoxForTurn promises still running for this attempt; the
|
|
93
|
+
* finalizer joins them so a cancelled establish completes its own cleanup. */
|
|
94
|
+
inFlightSandboxResumes: Set<Promise<unknown>>;
|
|
69
95
|
prefetchedManagedBox: Promise<ResumedTurnSandbox> | null;
|
|
70
96
|
prefetchedManagedBoxResult: ResumedTurnSandbox | null;
|
|
71
97
|
setupBoxSession: unknown;
|
|
@@ -80,10 +106,16 @@ export type SandboxRuntimeState = {
|
|
|
80
106
|
startupMilestoneBackend: Settings["sandboxBackend"] | null;
|
|
81
107
|
};
|
|
82
108
|
export type RenewalState = {
|
|
109
|
+
/** Secret-only local state; closed on every attempt finalization path. */
|
|
110
|
+
runMcpCredentials?: {
|
|
111
|
+
close(): void;
|
|
112
|
+
};
|
|
83
113
|
gitCredentialRenewals: GitCredentialRenewalController[];
|
|
84
114
|
gitCredentialRenewalClosed: boolean;
|
|
85
115
|
runCredentialRenewal: RunCredentialRenewalController | null;
|
|
86
116
|
runCredentialRenewalClosed: boolean;
|
|
117
|
+
/** Outcome of the most recent renewal attempt, for on-demand refresh reporting. */
|
|
118
|
+
runCredentialRenewalOutcome: "completed" | "auth_needed" | "error" | null;
|
|
87
119
|
runCredentialSession: RunCredentialCommandSession | null;
|
|
88
120
|
codemodeTokenRenewal: CodemodeTokenRenewalController | null;
|
|
89
121
|
codemodeTokenRenewalClosed: boolean;
|
|
@@ -104,11 +136,19 @@ export type EventingState = {
|
|
|
104
136
|
settle: TurnSettleFn | null;
|
|
105
137
|
turnStartedPublished: boolean;
|
|
106
138
|
stream: Awaited<ReturnType<OpenGeniRuntime["runStream"]>> | undefined;
|
|
139
|
+
/** Set by the stream attempt: refuses a wait that would leave a person unanswered. */
|
|
140
|
+
inputWaitReplyGuard: (() => Promise<string | null>) | null;
|
|
107
141
|
modelRunSettings: Settings;
|
|
108
142
|
firstModelRequestPreparationStartedAt: number | null;
|
|
109
143
|
firstModelRequestPreparationRecorded: boolean;
|
|
110
144
|
firstModelRequestCheckpointAt: number | null;
|
|
145
|
+
initialModelWireDispatch: InitialModelWireDispatchClock;
|
|
146
|
+
/** Diagnostic only: the current stream's timing hook for a native transport's
|
|
147
|
+
* literal provider dispatch. Never joins, fences or fails the request. */
|
|
148
|
+
providerDispatchObserver: (() => void) | null;
|
|
111
149
|
companyBrainContextContributions: readonly ModelContextContributionSummary[] | null;
|
|
150
|
+
/** Skill ids in this turn's frozen, model-visible Skill index; telemetry only. */
|
|
151
|
+
modelVisibleSkillIds: ReadonlySet<string> | null;
|
|
112
152
|
};
|
|
113
153
|
/** Rig telemetry (M3): set once the session loads; empty string for a rig-less
|
|
114
154
|
* turn (mirrors variableSetId). Read by the activity span's finally block. */
|
|
@@ -117,19 +157,74 @@ export type WorkspaceRefState = {
|
|
|
117
157
|
rigId: string;
|
|
118
158
|
rigVersionId: string;
|
|
119
159
|
};
|
|
160
|
+
/** A chat turn placed by the shared subscription core, for any provider. */
|
|
161
|
+
export type SubscriptionCoreTurn = {
|
|
162
|
+
identity: SubscriptionCoreTurnIdentity;
|
|
163
|
+
connectionId: string;
|
|
164
|
+
/** Refresh generation of the connection when it was placed. */
|
|
165
|
+
placedRefreshGeneration: number;
|
|
166
|
+
/**
|
|
167
|
+
* Refresh generation of the credential the latest request carried, when
|
|
168
|
+
* the provider's resolver reports it (SuperGrok and Claude; Codex keeps its
|
|
169
|
+
* own field).
|
|
170
|
+
*/
|
|
171
|
+
credentialVersion?: number;
|
|
172
|
+
personal: boolean;
|
|
173
|
+
/**
|
|
174
|
+
* The accepted product model id, for a provider whose refusals cool one
|
|
175
|
+
* model of the connection (Claude's per-model rate limits).
|
|
176
|
+
*/
|
|
177
|
+
productModelId?: string;
|
|
178
|
+
requests?: import("./subscription-core-requests.js").CoreSubscriptionRequests;
|
|
179
|
+
titleRequests?: import("./subscription-core-requests.js").CoreSubscriptionRequests;
|
|
180
|
+
/**
|
|
181
|
+
* The turn's quota observations from its responses (usage headers), when
|
|
182
|
+
* the provider reports them per response (Claude). `settled` joins every
|
|
183
|
+
* write so far and is true when one ended a stored exhaustion.
|
|
184
|
+
*/
|
|
185
|
+
quota?: {
|
|
186
|
+
settled(): Promise<boolean>;
|
|
187
|
+
};
|
|
188
|
+
};
|
|
189
|
+
/** A Codex chat turn running on the shared subscription core (M3 name). */
|
|
190
|
+
export type CodexSubscriptionCoreTurn = SubscriptionCoreTurn;
|
|
120
191
|
export type ProviderTurnState = {
|
|
121
192
|
effectiveCodexCredentialId: string | null;
|
|
122
193
|
/** Exact row version returned by the resolver for the latest provider request. */
|
|
123
194
|
effectiveCodexCredentialVersion: number | null;
|
|
124
195
|
/** Frozen alternate-account ceiling observed by the fenced allocator. */
|
|
125
196
|
codexCredentialFailoverLimit: number;
|
|
197
|
+
/**
|
|
198
|
+
* Accepted product model id (`codex/<slug>`) the Codex allocator filtered
|
|
199
|
+
* for. Failure settlement scopes plan entitlement and failover to it.
|
|
200
|
+
*/
|
|
201
|
+
codexProductModelId?: string | null;
|
|
126
202
|
/** Accepted Codex allocator policy captured with the first durable lease. */
|
|
127
203
|
codexPolicySnapshot: CodexCredentialPolicySnapshotV1 | null;
|
|
204
|
+
/**
|
|
205
|
+
* Set only when this Codex turn was placed by the shared subscription core
|
|
206
|
+
* (the account's Codex cutover is enabled). `effectiveCodexCredentialId` is
|
|
207
|
+
* then a core connection id: legacy Codex tables must never receive it.
|
|
208
|
+
*/
|
|
209
|
+
codexSubscriptionCore: CodexSubscriptionCoreTurn | null;
|
|
210
|
+
/** Epoch ms of the latest Codex model call that produced a response. */
|
|
211
|
+
lastCodexResponseCompletedAt?: number | null;
|
|
212
|
+
effectiveClaudeCredentialId: string | null;
|
|
213
|
+
/**
|
|
214
|
+
* Set only when this Claude turn was placed by the shared subscription core
|
|
215
|
+
* (the organization's Claude cutover committed and is enabled).
|
|
216
|
+
* `effectiveClaudeCredentialId` is then a core connection id: legacy Claude
|
|
217
|
+
* tables must never receive it.
|
|
218
|
+
*/
|
|
219
|
+
claudeSubscriptionCore: SubscriptionCoreTurn | null;
|
|
128
220
|
effectiveXaiCredentialId: string | null;
|
|
129
|
-
xaiRotationEnabled: boolean;
|
|
130
|
-
xaiAuthoritySnapshot: XaiProviderAccountAuthoritySnapshotV1 | null;
|
|
131
221
|
xaiRequestContext: XaiSubscriptionRequestContext | null;
|
|
132
|
-
|
|
222
|
+
/**
|
|
223
|
+
* Set when this SuperGrok turn was placed by the shared subscription core,
|
|
224
|
+
* the only SuperGrok path. `effectiveXaiCredentialId` is then its core
|
|
225
|
+
* connection id.
|
|
226
|
+
*/
|
|
227
|
+
xaiSubscriptionCore: SubscriptionCoreTurn | null;
|
|
133
228
|
priorSessionCodexCredentialId: string | null;
|
|
134
229
|
latestCodexUsage: CodexUsageHeaderSnapshot | null;
|
|
135
230
|
lastCodexRequestOpaqueArtifacts: readonly string[];
|
|
@@ -148,3 +243,7 @@ export declare function createTurnContext(input: {
|
|
|
148
243
|
settings: Settings;
|
|
149
244
|
cancellationRequestedAt: number | null;
|
|
150
245
|
}): TurnContext;
|
|
246
|
+
/** The turn's shared-core placement, whichever provider placed it (at most one does). */
|
|
247
|
+
export declare function subscriptionCoreTurnOf(providerTurn: SubscriptionCorePlacedFields): SubscriptionCoreTurn | null;
|
|
248
|
+
/** The provider fields that can hold a turn's shared-core placement. */
|
|
249
|
+
export type SubscriptionCorePlacedFields = Pick<ProviderTurnState, "codexSubscriptionCore" | "xaiSubscriptionCore"> & Partial<Pick<ProviderTurnState, "claudeSubscriptionCore">>;
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import type { AttemptToolDefinition } from "@opengeni/codemode";
|
|
2
|
+
import { type WebSearchProviderEndpoint, type WebSearchProviderToolName, type WebSearchSettings } from "@opengeni/config";
|
|
3
|
+
import { type WebSearchBilling, type WebSearchCallScope } from "@opengeni/core";
|
|
4
|
+
import type { Observability } from "@opengeni/observability";
|
|
5
|
+
import { WebSearchProviderError } from "@opengeni/runtime/web-search";
|
|
6
|
+
/**
|
|
7
|
+
* Which web search one turn gets: the provider's hosted tool, Opengeni's
|
|
8
|
+
* provider tools, or neither. Tool preparation and agent construction both
|
|
9
|
+
* call this with the same accepted model and settings, so they agree.
|
|
10
|
+
*/
|
|
11
|
+
export declare function turnWebSearchPlan(resolvedModel: {
|
|
12
|
+
configured: {
|
|
13
|
+
hostedWebSearch: boolean;
|
|
14
|
+
};
|
|
15
|
+
provider: {
|
|
16
|
+
kind?: string;
|
|
17
|
+
};
|
|
18
|
+
} | null, settings: WebSearchSettings, workspaceCreditModelsAllowed: boolean): {
|
|
19
|
+
hostedWebSearch: boolean;
|
|
20
|
+
providerTools: WebSearchProviderToolName[];
|
|
21
|
+
};
|
|
22
|
+
type Operation = "search" | "fetch";
|
|
23
|
+
/** Closed outcome set for `opengeni_web_search_calls_total`. */
|
|
24
|
+
export type WebSearchCallOutcome = "ok" | "provider_error" | "provider_retryable" | "billing_refused" | "error";
|
|
25
|
+
type WebSearchObservability = Pick<Observability, "warn" | "incrementCounter" | "observeHistogram">;
|
|
26
|
+
/**
|
|
27
|
+
* Process-wide provider health for failover ordering. A provider that just
|
|
28
|
+
* failed in a way that will repeat (rate limit, outage, rejected key) moves
|
|
29
|
+
* behind the healthy providers of its slot until its cooldown passes. It is
|
|
30
|
+
* never skipped: when every provider is cooling down they are tried in their
|
|
31
|
+
* configured order.
|
|
32
|
+
*/
|
|
33
|
+
export declare class WebProviderHealth {
|
|
34
|
+
private readonly now;
|
|
35
|
+
private readonly coolingUntil;
|
|
36
|
+
constructor(now?: () => number);
|
|
37
|
+
order<T extends {
|
|
38
|
+
endpoint: WebSearchProviderEndpoint;
|
|
39
|
+
}>(operation: Operation, candidates: readonly T[]): T[];
|
|
40
|
+
failed(operation: Operation, provider: string, error: WebSearchProviderError): void;
|
|
41
|
+
succeeded(operation: Operation, provider: string): void;
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* The `web_search` and `web_fetch` attempt tools for one turn. The caller
|
|
45
|
+
* decides which names the turn gets ({@link webSearchToolPlan}); this only
|
|
46
|
+
* builds them. Provider keys stay in the worker and never reach a sandbox.
|
|
47
|
+
*/
|
|
48
|
+
export declare function webSearchToolDefinitions(input: {
|
|
49
|
+
settings: WebSearchSettings;
|
|
50
|
+
tools: readonly WebSearchProviderToolName[];
|
|
51
|
+
scope: WebSearchCallScope;
|
|
52
|
+
billing: WebSearchBilling;
|
|
53
|
+
observability: WebSearchObservability;
|
|
54
|
+
fetch?: typeof fetch;
|
|
55
|
+
health?: WebProviderHealth;
|
|
56
|
+
}): AttemptToolDefinition[];
|
|
57
|
+
export {};
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* SuperGrok on the shared subscription core (design 5.3, SuperGrok track
|
|
3
|
+
* X1a): the provider-neutral chat placement and request custody bound to
|
|
4
|
+
* SuperGrok. SuperGrok runs only on the core (the legacy path was deleted in
|
|
5
|
+
* X4): the route is `core` after the SuperGrok drained cutover commits its
|
|
6
|
+
* receipt (X3), which this binary requires; any other route fails closed.
|
|
7
|
+
*/
|
|
8
|
+
import { type Database } from "@opengeni/db";
|
|
9
|
+
import type { Settings } from "@opengeni/config";
|
|
10
|
+
import type { XaiSubscriptionRequestContext } from "@opengeni/xai-subscription";
|
|
11
|
+
import type { CapacityPhaseDeps, CapacityPhaseOutcome } from "./codex-capacity.js";
|
|
12
|
+
import type { XaiTurnLease } from "./credential-leases.js";
|
|
13
|
+
import { type CoreTurnPlacementProvider } from "./subscription-core-capacity.js";
|
|
14
|
+
import { type CoreSubscriptionRequests } from "./subscription-core-requests.js";
|
|
15
|
+
import type { CoreRefusalBinding } from "./subscription-core-settlement.js";
|
|
16
|
+
import type { SubscriptionCoreTurn } from "./turn-context.js";
|
|
17
|
+
/** SuperGrok's chat placement on the shared core. */
|
|
18
|
+
export declare const XAI_CORE_TURN_PROVIDER: CoreTurnPlacementProvider;
|
|
19
|
+
/**
|
|
20
|
+
* The SuperGrok capacity phase by the organization's SuperGrok route: `core`
|
|
21
|
+
* places on the shared core; `maintenance` and a missing receipt (`legacy`,
|
|
22
|
+
* which this binary's readiness check already refuses) fail closed.
|
|
23
|
+
*/
|
|
24
|
+
export declare function selectXaiTurnCapacityByRoute(deps: CapacityPhaseDeps): Promise<CapacityPhaseOutcome>;
|
|
25
|
+
/** One attempt's SuperGrok request custody on the core (unknown outcomes are never replayed). */
|
|
26
|
+
export declare function createCoreXaiRequests(db: Database, core: SubscriptionCoreTurn, ref: {
|
|
27
|
+
connectionId: string;
|
|
28
|
+
holderId: string;
|
|
29
|
+
generation: number;
|
|
30
|
+
}, execution: {
|
|
31
|
+
attemptId: string;
|
|
32
|
+
executionGeneration: number;
|
|
33
|
+
}): {
|
|
34
|
+
reserve(request: import("./subscription-core-requests.js").SubscriptionCoreRequestIdentity): Promise<void>;
|
|
35
|
+
observe(request: import("./subscription-core-requests.js").SubscriptionCoreRequestSettlement): Promise<void>;
|
|
36
|
+
checkpoint(): Promise<void>;
|
|
37
|
+
canRecover(): boolean;
|
|
38
|
+
hasUnknownOutcome(): boolean;
|
|
39
|
+
unknownIsOwnAndSettled(): boolean;
|
|
40
|
+
admissionRefused(): boolean;
|
|
41
|
+
lastResponseReceivedAt(): Date | null;
|
|
42
|
+
};
|
|
43
|
+
export type XaiCoreRequestAuthorization = {
|
|
44
|
+
getToken: XaiSubscriptionRequestContext["getToken"];
|
|
45
|
+
refresh: XaiSubscriptionRequestContext["refresh"];
|
|
46
|
+
/**
|
|
47
|
+
* The same bearer for session-title requests. A title request never moves
|
|
48
|
+
* the main lane's refusal fence (`core.credentialVersion`).
|
|
49
|
+
*/
|
|
50
|
+
titleGetToken: XaiSubscriptionRequestContext["getToken"];
|
|
51
|
+
titleRefresh: XaiSubscriptionRequestContext["refresh"];
|
|
52
|
+
/** The dispatch fence every physical request passes before its reservation. */
|
|
53
|
+
assertDispatch: () => Promise<void>;
|
|
54
|
+
beforeProviderDispatch: NonNullable<XaiSubscriptionRequestContext["beforeProviderDispatch"]>;
|
|
55
|
+
onProviderRequestSettled: NonNullable<XaiSubscriptionRequestContext["onProviderRequestSettled"]>;
|
|
56
|
+
};
|
|
57
|
+
/**
|
|
58
|
+
* Materialization, refresh and custody for a core-placed SuperGrok turn: the
|
|
59
|
+
* bearer comes from the shared core resolver under the exact accepted turn
|
|
60
|
+
* and this attempt's live core lease; each physical request (each transport
|
|
61
|
+
* attempt and each continuation) is fenced and reserved before network I/O.
|
|
62
|
+
* Session-title requests use `core.titleRequests` with the same fence.
|
|
63
|
+
*/
|
|
64
|
+
export declare function buildXaiCoreRequestAuthorization(input: {
|
|
65
|
+
db: Database;
|
|
66
|
+
settings: Settings;
|
|
67
|
+
core: SubscriptionCoreTurn;
|
|
68
|
+
lease: XaiTurnLease;
|
|
69
|
+
execution: {
|
|
70
|
+
attemptId: string;
|
|
71
|
+
executionGeneration: number;
|
|
72
|
+
};
|
|
73
|
+
}): XaiCoreRequestAuthorization;
|
|
74
|
+
/**
|
|
75
|
+
* The session-title custody of a turn: none on the legacy route; on the core
|
|
76
|
+
* the turn's dispatch fence and its title lane, and a turn placed on the core
|
|
77
|
+
* without either fails closed instead of sending unreserved title requests.
|
|
78
|
+
*/
|
|
79
|
+
export declare function xaiCoreTitleCustody(core: Pick<SubscriptionCoreTurn, "titleRequests"> | null, authorization: Pick<XaiCoreRequestAuthorization, "assertDispatch" | "titleGetToken" | "titleRefresh"> | null): {
|
|
80
|
+
assertDispatch: () => Promise<void>;
|
|
81
|
+
requests: CoreSubscriptionRequests;
|
|
82
|
+
getToken: XaiSubscriptionRequestContext["getToken"];
|
|
83
|
+
refresh: XaiSubscriptionRequestContext["refresh"];
|
|
84
|
+
} | undefined;
|
|
85
|
+
/**
|
|
86
|
+
* The terminal unknown-outcome failure of a core SuperGrok turn, or null: an
|
|
87
|
+
* earlier or own request whose outcome is unknown is never replayed
|
|
88
|
+
* automatically.
|
|
89
|
+
*/
|
|
90
|
+
export declare function xaiCoreRequestOutcomeUnknown(error: unknown, core: Pick<SubscriptionCoreTurn, "requests">): (Error & {
|
|
91
|
+
code: string;
|
|
92
|
+
}) | null;
|
|
93
|
+
/** After the history commit, settle completed responses; true when no request is unresolved. */
|
|
94
|
+
export declare function xaiCoreLanesRecoverAfterCheckpoint(core: Pick<SubscriptionCoreTurn, "requests">, commitHistory: () => Promise<void>): Promise<boolean>;
|
|
95
|
+
/** SuperGrok's in-turn failover and refusal settlement on the core (X1b). */
|
|
96
|
+
export declare const XAI_CORE_REFUSAL: CoreRefusalBinding;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { assertWorkspaceModelPolicyAllows, createAndStartSessionWithOutcome, recordWorkspaceUsage } from "@opengeni/core";
|
|
2
|
-
import { assertAutomationRunAuthorityInTransaction, claimAutomationRun, settleAutomationRun } from "@opengeni/db";
|
|
2
|
+
import { assertAutomationRunAuthorityInTransaction, claimAutomationRun, settleAutomationRun, requireWorkspace } from "@opengeni/db";
|
|
3
3
|
import { agentRunAdmissionDenial } from "./agent-run-admission.js";
|
|
4
4
|
import type { ControlActivityServices, DispatchAutomationRunInput, DispatchAutomationRunResult } from "./types.js";
|
|
5
5
|
export type AutomationActivityOptions = {
|
|
@@ -7,6 +7,8 @@ export type AutomationActivityOptions = {
|
|
|
7
7
|
settle?: typeof settleAutomationRun;
|
|
8
8
|
assertAuthority?: typeof assertAutomationRunAuthorityInTransaction;
|
|
9
9
|
createSession?: typeof createAndStartSessionWithOutcome;
|
|
10
|
+
/** Workspace read for agent-configuration defaults (tests inject it). */
|
|
11
|
+
readWorkspace?: typeof requireWorkspace;
|
|
10
12
|
admit?: typeof agentRunAdmissionDenial;
|
|
11
13
|
assertModelPolicy?: typeof assertWorkspaceModelPolicyAllows;
|
|
12
14
|
recordUsage?: typeof recordWorkspaceUsage;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { type Settings } from "@opengeni/config";
|
|
2
|
+
import { readLease, type BrowserDeadlineCheckpointTarget } from "@opengeni/db";
|
|
3
|
+
import { BrowserControlClient } from "@opengeni/runtime";
|
|
4
|
+
import type { ControlActivityServices } from "./types.js";
|
|
5
|
+
type CheckpointController = Pick<BrowserControlClient, "captureState" | "endSession">;
|
|
6
|
+
type CheckpointPlacement = {
|
|
7
|
+
target: BrowserDeadlineCheckpointTarget;
|
|
8
|
+
lease: NonNullable<Awaited<ReturnType<typeof readLease>>>;
|
|
9
|
+
settings: Settings;
|
|
10
|
+
controllerRoot: string;
|
|
11
|
+
};
|
|
12
|
+
/** Whether this worker can save browser profiles: ownership, object storage,
|
|
13
|
+
* the controller delegation secret and the environments encryption key. */
|
|
14
|
+
export declare function browserCheckpointPrerequisites(settings: Settings, objectStorage: ControlActivityServices["objectStorage"]): boolean;
|
|
15
|
+
export declare function createBrowserDeadlineCheckpointActivities(services: () => Promise<ControlActivityServices>, connectController?: (placement: CheckpointPlacement) => Promise<CheckpointController>): {
|
|
16
|
+
listDueBrowserCheckpoints(): Promise<{
|
|
17
|
+
accountId: string;
|
|
18
|
+
workspaceId: string;
|
|
19
|
+
sandboxGroupId: string;
|
|
20
|
+
leaseId: string;
|
|
21
|
+
leaseEpoch: number;
|
|
22
|
+
instanceId: string;
|
|
23
|
+
browserSessionId: string;
|
|
24
|
+
controllerGeneration: string;
|
|
25
|
+
reason?: "idle" | "provider_deadline" | undefined;
|
|
26
|
+
idleMs?: number | undefined;
|
|
27
|
+
}[]>;
|
|
28
|
+
checkpointBrowserBeforeDeadline(target: BrowserDeadlineCheckpointTarget): Promise<{
|
|
29
|
+
status: "skipped";
|
|
30
|
+
} | {
|
|
31
|
+
status: "suspended";
|
|
32
|
+
}>;
|
|
33
|
+
};
|
|
34
|
+
export {};
|
|
@@ -1,27 +1,15 @@
|
|
|
1
1
|
import { type Settings } from "@opengeni/config";
|
|
2
|
-
import { settingsWithEnabledCapabilityMcpServers } from "@opengeni/core";
|
|
2
|
+
import { settingsWithCodexCredential as coreSettingsWithCodexCredential, settingsWithEnabledCapabilityMcpServers, settingsWithOrganizationProviderCredentials as coreSettingsWithOrganizationProviderCredentials, settingsWithWorkspaceGatewayCredential as coreSettingsWithWorkspaceGatewayCredential, settingsWithWorkspaceOpenRouterCredential as coreSettingsWithWorkspaceOpenRouterCredential, settingsWithWorkspaceOpperCredential as coreSettingsWithWorkspaceOpperCredential, withCodexProvider as coreWithCodexProvider, withXaiSubscriptionProvider as coreWithXaiSubscriptionProvider } from "@opengeni/core";
|
|
3
3
|
import { type Database, type SessionMcpServerForRun } from "@opengeni/db";
|
|
4
4
|
export { settingsWithEnabledCapabilityMcpServers };
|
|
5
5
|
export declare function settingsWithSessionMcpServersForRun(db: Database, workspaceId: string, sessionId: string, attemptId: string, settings: Settings, options?: {
|
|
6
6
|
onResolvedServers?: (servers: readonly SessionMcpServerForRun[]) => void;
|
|
7
7
|
}): Promise<Settings>;
|
|
8
8
|
export declare function settingsWithSessionMcpServers(settings: Settings, servers: SessionMcpServerForRun[]): Settings;
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
export declare function settingsWithCodexCredential(db: Database, workspaceId: string, settings: Settings, activeOverride?: boolean): Promise<Settings>;
|
|
17
|
-
/** Pure: append the synthetic codex-subscription provider, idempotently. */
|
|
18
|
-
export declare function withCodexProvider(settings: Settings): Settings;
|
|
19
|
-
/**
|
|
20
|
-
* Pure: append the synthetic SuperGrok/xAI subscription provider,
|
|
21
|
-
* idempotently. The overlay is catalogue metadata only; the exact account,
|
|
22
|
-
* authority snapshot, and bearer remain frozen later at turn admission.
|
|
23
|
-
*/
|
|
24
|
-
export declare function withXaiSubscriptionProvider(settings: Settings): Settings;
|
|
25
|
-
export declare function settingsWithWorkspaceGatewayCredential(db: Database, accountId: string, workspaceId: string, settings: Settings, retainedProductModelId?: string | null): Promise<Settings>;
|
|
26
|
-
export declare function settingsWithWorkspaceOpenRouterCredential(db: Database, accountId: string, workspaceId: string, settings: Settings, retainedProductModelId?: string | null): Promise<Settings>;
|
|
27
|
-
export declare function settingsWithOrganizationProviderCredentials(db: Database, accountId: string, workspaceId: string, settings: Settings, retainedProductModelId?: string | null): Promise<Settings>;
|
|
9
|
+
export declare const settingsWithCodexCredential: typeof coreSettingsWithCodexCredential;
|
|
10
|
+
export declare const withCodexProvider: typeof coreWithCodexProvider;
|
|
11
|
+
export declare const withXaiSubscriptionProvider: typeof coreWithXaiSubscriptionProvider;
|
|
12
|
+
export declare const settingsWithWorkspaceGatewayCredential: typeof coreSettingsWithWorkspaceGatewayCredential;
|
|
13
|
+
export declare const settingsWithWorkspaceOpenRouterCredential: typeof coreSettingsWithWorkspaceOpenRouterCredential;
|
|
14
|
+
export declare const settingsWithWorkspaceOpperCredential: typeof coreSettingsWithWorkspaceOpperCredential;
|
|
15
|
+
export declare const settingsWithOrganizationProviderCredentials: typeof coreSettingsWithOrganizationProviderCredentials;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { type AttemptToolEnvironment } from "@opengeni/codemode";
|
|
2
|
-
import { type ToolDisplayMetadata } from "@opengeni/contracts";
|
|
1
|
+
import { type AttemptToolCatalogEntry, type AttemptToolEnvironment } from "@opengeni/codemode";
|
|
2
|
+
import { CodemodeOperation, type ToolDisplayMetadata, type ToolFamily } from "@opengeni/contracts";
|
|
3
3
|
import { type Database } from "@opengeni/db";
|
|
4
4
|
import { type EventBus } from "@opengeni/events";
|
|
5
5
|
export type CodemodeDispatcherScope = {
|
|
@@ -27,6 +27,9 @@ export declare class CodemodeAttemptDispatcher {
|
|
|
27
27
|
private readonly turnSignal?;
|
|
28
28
|
private readonly maxConcurrentCalls;
|
|
29
29
|
private readonly toolDisplayMetadata?;
|
|
30
|
+
/** Content-free analytics family for a catalog entry; event enrichment only. */
|
|
31
|
+
private readonly toolFamily?;
|
|
32
|
+
private readonly approvalWait?;
|
|
30
33
|
private readonly stopController;
|
|
31
34
|
private readonly inFlight;
|
|
32
35
|
private pendingClaims;
|
|
@@ -34,13 +37,27 @@ export declare class CodemodeAttemptDispatcher {
|
|
|
34
37
|
private closing;
|
|
35
38
|
private readonly claimLeaseMs;
|
|
36
39
|
private readonly claimHeartbeatMs;
|
|
37
|
-
constructor(db: Database, bus: EventBus, environment: AttemptToolEnvironment, scope: CodemodeDispatcherScope, turnSignal?: AbortSignal | undefined, maxConcurrentCalls?: number, timings?: CodemodeDispatcherTimings, toolDisplayMetadata?: ((modelName: string) => ToolDisplayMetadata | undefined) | undefined
|
|
40
|
+
constructor(db: Database, bus: EventBus, environment: AttemptToolEnvironment, scope: CodemodeDispatcherScope, turnSignal?: AbortSignal | undefined, maxConcurrentCalls?: number, timings?: CodemodeDispatcherTimings, toolDisplayMetadata?: ((modelName: string) => ToolDisplayMetadata | undefined) | undefined,
|
|
41
|
+
/** Content-free analytics family for a catalog entry; event enrichment only. */
|
|
42
|
+
toolFamily?: ((entry: AttemptToolCatalogEntry) => ToolFamily | null) | undefined, approvalWait?: {
|
|
43
|
+
beginWait(): (accepted: boolean) => void;
|
|
44
|
+
} | undefined);
|
|
38
45
|
start(): void;
|
|
46
|
+
/**
|
|
47
|
+
* Join-on-use recovery before the first model request. The journal read needs
|
|
48
|
+
* no tool environment, so a turn with nothing unfinished returns at once and
|
|
49
|
+
* never waits on lazy MCP preparation. Only a stored waiting/queued/running
|
|
50
|
+
* operation awaits the prepared dispatcher to adopt and execute it.
|
|
51
|
+
*/
|
|
52
|
+
static resumeApproved(db: Database, scope: CodemodeDispatcherScope, callerSubjectId: string, decisionOperationId: string | undefined, prepared: () => Promise<CodemodeAttemptDispatcher | null>): Promise<CodemodeOperation[]>;
|
|
53
|
+
resumeApproved(callerSubjectId: string, decisionOperationId?: string): Promise<CodemodeOperation[]>;
|
|
54
|
+
private resumeOperations;
|
|
39
55
|
close(reason?: string): Promise<void>;
|
|
40
56
|
private execute;
|
|
41
57
|
private executeClaimed;
|
|
42
58
|
private ensureToolCallCreated;
|
|
43
59
|
private settleWithOutput;
|
|
60
|
+
private persistSettlement;
|
|
44
61
|
private failBeforeExecution;
|
|
45
62
|
}
|
|
46
63
|
export declare function codemodeToolCallCreatedClientEventId(operationId: string): string;
|
|
@@ -1,61 +1,7 @@
|
|
|
1
|
-
import { armCodexCapacityWait, reconcileCodexCapacityWait as reconcileCodexCapacityWaitDb, type CodexCapacityWakeTarget, type CodexCapacitySelectionContext } from "@opengeni/db";
|
|
2
1
|
import type { ControlActivityServices, GetCodexCapacityWaitInput, ReconcileCodexCapacityWaitInput, ReconcileCodexCapacityWaitResult } from "./types.js";
|
|
3
|
-
type CodexCapacitySignalServices = {
|
|
4
|
-
signalCodexCapacityWorkflow?: NonNullable<ControlActivityServices["signalCodexCapacityWorkflow"]> | null | undefined;
|
|
5
|
-
wakeSessionWorkflow: ControlActivityServices["wakeSessionWorkflow"];
|
|
6
|
-
};
|
|
7
|
-
/**
|
|
8
|
-
* Run a bounded set of usage refreshes, then repair every committed waiter
|
|
9
|
-
* revision even when an individual provider refresh failed. The database
|
|
10
|
-
* outbox remains authoritative; this helper only guarantees that every worker
|
|
11
|
-
* refresh path reaches the same post-commit delivery seam.
|
|
12
|
-
*/
|
|
13
|
-
export declare function refreshCodexUsageAndRepairCapacityWaiters(refreshes: readonly (() => Promise<unknown>)[], repairPendingWakes: () => Promise<void>): Promise<void>;
|
|
14
|
-
/** Deliver committed waiter revisions; Postgres remains the repairable outbox. */
|
|
15
|
-
export declare function signalCodexCapacityWakeTargets(services: CodexCapacitySignalServices, targets: readonly CodexCapacityWakeTarget[]): Promise<void>;
|
|
16
|
-
/** Repair a commit/signal crash edge by redelivering every pending revision. */
|
|
17
|
-
export declare function signalPendingCodexCapacityWakeTargets(services: CodexCapacitySignalServices & {
|
|
18
|
-
db: ControlActivityServices["db"];
|
|
19
|
-
}, workspaceId: string): Promise<void>;
|
|
20
|
-
export declare function codexCapacityDecision<TPolicyScope = never, TUnavailableDiagnostic = never>(context: CodexCapacitySelectionContext<TPolicyScope, TUnavailableDiagnostic>, now?: Date): ReturnType<Parameters<typeof reconcileCodexCapacityWaitDb>[2]>;
|
|
21
|
-
/**
|
|
22
|
-
* Arm a durable Codex waiter and immediately re-evaluate it under the
|
|
23
|
-
* allocator lock. A capacity mutation that commits just before the waiter is
|
|
24
|
-
* inserted cannot signal a row that does not exist yet, so every arm site must
|
|
25
|
-
* close that edge before returning an hours-away reset timer to the workflow.
|
|
26
|
-
* Mutations after the arm commit still advance the waiter's wake revision.
|
|
27
|
-
*/
|
|
28
|
-
export declare function armAndReconcileCodexCapacityWait(services: Pick<ControlActivityServices, "db" | "bus">, input: Parameters<typeof armCodexCapacityWait>[1], options?: {
|
|
29
|
-
onArmed?: () => void;
|
|
30
|
-
}): Promise<{
|
|
31
|
-
action: "stopped";
|
|
32
|
-
sessionStatus: "failed" | "queued";
|
|
33
|
-
waiter: import("@opengeni/db").CodexCapacityWait;
|
|
34
|
-
events: import("@opengeni/contracts").SessionEvent[];
|
|
35
|
-
} | {
|
|
36
|
-
action: "stale";
|
|
37
|
-
waiter: import("@opengeni/db").CodexCapacityWait | null;
|
|
38
|
-
events: import("@opengeni/contracts").SessionEvent[];
|
|
39
|
-
} | {
|
|
40
|
-
action: "waiting";
|
|
41
|
-
waiter: import("@opengeni/db").CodexCapacityWait;
|
|
42
|
-
events: import("@opengeni/contracts").SessionEvent[];
|
|
43
|
-
} | {
|
|
44
|
-
action: "resumed";
|
|
45
|
-
waiter: import("@opengeni/db").CodexCapacityWait;
|
|
46
|
-
events: import("@opengeni/contracts").SessionEvent[];
|
|
47
|
-
} | {
|
|
48
|
-
action: "paused";
|
|
49
|
-
waiter: import("@opengeni/db").CodexCapacityWait;
|
|
50
|
-
events: import("@opengeni/contracts").SessionEvent[];
|
|
51
|
-
} | {
|
|
52
|
-
action: "superseded";
|
|
53
|
-
waiter: import("@opengeni/db").CodexCapacityWait;
|
|
54
|
-
events: import("@opengeni/contracts").SessionEvent[];
|
|
55
|
-
}>;
|
|
56
2
|
export declare function createCodexCapacityActivities(services: () => Promise<ControlActivityServices>): {
|
|
57
3
|
getCodexCapacityWait: (input: GetCodexCapacityWaitInput) => Promise<{
|
|
58
|
-
provider?: "
|
|
4
|
+
provider?: Exclude<import("@opengeni/db").SubscriptionCoreWaiterProvider, "codex">;
|
|
59
5
|
waiterId: string;
|
|
60
6
|
generation: number;
|
|
61
7
|
nextCheckAt: string;
|
|
@@ -63,4 +9,3 @@ export declare function createCodexCapacityActivities(services: () => Promise<Co
|
|
|
63
9
|
} | null>;
|
|
64
10
|
reconcileCodexCapacityWait: (input: ReconcileCodexCapacityWaitInput) => Promise<ReconcileCodexCapacityWaitResult>;
|
|
65
11
|
};
|
|
66
|
-
export {};
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
import { type CodexRequestContext } from "@opengeni/codex";
|
|
2
|
-
import type
|
|
1
|
+
import { generateCodexSubscriptionImage, type CodexRequestContext } from "@opengeni/codex";
|
|
2
|
+
import { acquireSubscriptionCoreCodexOperationLease, buildSubscriptionCoreCodexConnectionTokenResolver, releaseSubscriptionCoreCodexOperationLease, renewSubscriptionCoreCodexOperationLease, reserveSubscriptionCoreCodexOperationRequest, settleSubscriptionCoreCodexOperationRequest, type Database, type SubscriptionCoreTurnIdentity } from "@opengeni/db";
|
|
3
|
+
import type { Settings } from "@opengeni/config";
|
|
3
4
|
import type { ObjectStorage } from "@opengeni/storage";
|
|
4
5
|
import type { GeneratedImageReceipt } from "./generated-images.js";
|
|
6
|
+
import { type ImageGenerationOperationPorts } from "./image-generation-operation.js";
|
|
5
7
|
import type { ResolvedImageGenerationReference } from "./image-generation-references.js";
|
|
6
8
|
/** Execute the same standalone subscription image path used by Codex clients. */
|
|
7
9
|
export declare function executeCodexImageGeneration(input: {
|
|
@@ -16,6 +18,50 @@ export declare function executeCodexImageGeneration(input: {
|
|
|
16
18
|
prompt: string;
|
|
17
19
|
references?: readonly ResolvedImageGenerationReference[];
|
|
18
20
|
credentialId: string;
|
|
19
|
-
codexContext: Pick<CodexRequestContext, "clientVersion" | "getToken" | "refresh" | "beforeProviderDispatch">;
|
|
21
|
+
codexContext: Pick<CodexRequestContext, "clientVersion" | "getToken" | "refresh" | "beforeProviderDispatch" | "onProviderRequestSettled">;
|
|
20
22
|
abortSignal?: AbortSignal;
|
|
23
|
+
/** Core turns only: the per-operation lease held around the provider call. */
|
|
24
|
+
operationLease?: {
|
|
25
|
+
acquire(): Promise<void>;
|
|
26
|
+
release(): Promise<void>;
|
|
27
|
+
};
|
|
28
|
+
/** Test seam for the provider request; production uses the Codex image client. */
|
|
29
|
+
generateImage?: typeof generateCodexSubscriptionImage;
|
|
30
|
+
}, ports?: ImageGenerationOperationPorts): Promise<GeneratedImageReceipt>;
|
|
31
|
+
/**
|
|
32
|
+
* A Codex image operation of a turn placed by the shared subscription core
|
|
33
|
+
* (M3 PR 2c, EP-T17). It runs on the turn's own leased chat connection under
|
|
34
|
+
* the turn's accepted authority, but holds its own operation lease (kind
|
|
35
|
+
* `image`, keyed by the ledger's turn/tool-call operation id) and reads and
|
|
36
|
+
* refreshes the credential through the operation seam. The chat-turn lease
|
|
37
|
+
* and the session binding are never read or written, so concurrent image
|
|
38
|
+
* calls never contend with the chat turn or each other.
|
|
39
|
+
*/
|
|
40
|
+
export declare function executeCoreCodexImageGeneration(input: Omit<Parameters<typeof executeCodexImageGeneration>[0], "credentialId" | "codexContext" | "operationLease"> & {
|
|
41
|
+
settings: Settings;
|
|
42
|
+
core: {
|
|
43
|
+
identity: SubscriptionCoreTurnIdentity;
|
|
44
|
+
connectionId: string;
|
|
45
|
+
};
|
|
46
|
+
executionGeneration: number;
|
|
47
|
+
clientVersion: string;
|
|
48
|
+
/**
|
|
49
|
+
* The turn's chat-lease dispatch fence (`leases.codex.assertCurrentForDispatch`):
|
|
50
|
+
* an image operation runs only while its turn's live attempt still holds
|
|
51
|
+
* the chat lease, checked before the operation lease is taken and before
|
|
52
|
+
* the provider call.
|
|
53
|
+
*/
|
|
54
|
+
assertChatLease: () => Promise<void>;
|
|
55
|
+
/** Uses the same live account spending policy as the owning chat turn. */
|
|
56
|
+
assertCreditAdmission: () => Promise<void>;
|
|
57
|
+
deps?: {
|
|
58
|
+
acquire?: typeof acquireSubscriptionCoreCodexOperationLease;
|
|
59
|
+
renew?: typeof renewSubscriptionCoreCodexOperationLease;
|
|
60
|
+
release?: typeof releaseSubscriptionCoreCodexOperationLease;
|
|
61
|
+
resolver?: typeof buildSubscriptionCoreCodexConnectionTokenResolver;
|
|
62
|
+
reserve?: typeof reserveSubscriptionCoreCodexOperationRequest;
|
|
63
|
+
settle?: typeof settleSubscriptionCoreCodexOperationRequest;
|
|
64
|
+
ports?: ImageGenerationOperationPorts;
|
|
65
|
+
generateImage?: typeof generateCodexSubscriptionImage;
|
|
66
|
+
};
|
|
21
67
|
}): Promise<GeneratedImageReceipt>;
|
|
@@ -11,7 +11,9 @@ export { mergeResourceRefs, mergeToolRefs } from "@opengeni/contracts";
|
|
|
11
11
|
* dispatch catch marks the scheduled_task_run "failed" rather than dispatched.
|
|
12
12
|
*/
|
|
13
13
|
export declare function assertReusableSessionRevivable(status: SessionStatus): void;
|
|
14
|
-
export declare function scheduledUserMessagePayload(prompt: string, resources: ResourceRef[], tools: ToolRef[], taskId: string, runId: string
|
|
14
|
+
export declare function scheduledUserMessagePayload(prompt: string, resources: ResourceRef[], tools: ToolRef[], taskId: string, runId: string, degradedAccounts?: readonly {
|
|
15
|
+
serverId: string;
|
|
16
|
+
}[]): Extract<SessionSystemUpdatePayload, {
|
|
15
17
|
type: "scheduled_occurrence";
|
|
16
18
|
}>;
|
|
17
19
|
export declare function workflowIdForSession(sessionId: string): string;
|