@tangle-network/sandbox 0.10.3 → 0.10.4
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/agent/index.d.ts +3 -3
- package/dist/{client-Cr39zlgv.d.ts → client-B8i6qrQr.d.ts} +2 -2
- package/dist/{client-Df1K1d_Q.js → client-DTpHjPjc.js} +1 -1
- package/dist/core.d.ts +3 -3
- package/dist/core.js +2 -2
- package/dist/{index-DzEUjav-.d.ts → index-BFnMEze6.d.ts} +2 -2
- package/dist/index.d.ts +5 -5
- package/dist/index.js +3 -3
- package/dist/runtime.d.ts +1 -1
- package/dist/{sandbox-CxBHIBV1.js → sandbox-Be9WAqSg.js} +121 -8
- package/dist/{sandbox-BhYmj7L3.d.ts → sandbox-BtNWbfd3.d.ts} +57 -1
- package/dist/tangle/index.d.ts +1 -1
- package/dist/tangle/index.js +1 -1
- package/dist/{tangle-BdRRHMpX.js → tangle-D6UfK_B0.js} +1 -1
- package/dist/{types-Cmpv-ox_.d.ts → types-BvSoEHz8.d.ts} +95 -1
- package/package.json +1 -1
package/dist/agent/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { D as CodeLanguage, E as CodeExecutionResult, T as CodeExecutionOptions, k as CodeResultPart } from "../types-
|
|
2
|
-
import { n as SandboxInstance } from "../sandbox-
|
|
3
|
-
import { i as SandboxClient } from "../client-
|
|
1
|
+
import { D as CodeLanguage, E as CodeExecutionResult, T as CodeExecutionOptions, k as CodeResultPart } from "../types-BvSoEHz8.js";
|
|
2
|
+
import { n as SandboxInstance } from "../sandbox-BtNWbfd3.js";
|
|
3
|
+
import { i as SandboxClient } from "../client-B8i6qrQr.js";
|
|
4
4
|
import * as _$_modelcontextprotocol_sdk_server_index_js0 from "@modelcontextprotocol/sdk/server/index.js";
|
|
5
5
|
|
|
6
6
|
//#region src/agent/tools/_specs.d.ts
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Bt as IntelligenceReport, Cn as PublishPublicTemplateVersionOptions, Dn as ReconcileSandboxFleetsResult, En as ReconcileSandboxFleetsOptions, F as CreateSandboxFleetOptions,
|
|
2
|
-
import { a as TraceExportSink, i as TraceExportResult, n as SandboxInstance, t as HttpClient } from "./sandbox-
|
|
1
|
+
import { Bn as SandboxClientConfig, Bt as IntelligenceReport, Cn as PublishPublicTemplateVersionOptions, Di as UsageInfo, Dn as ReconcileSandboxFleetsResult, En as ReconcileSandboxFleetsOptions, F as CreateSandboxFleetOptions, Gn as SandboxFleetArtifactSpec, Hn as SandboxEnvironment, Ht as IntelligenceReportCompareTo, I as CreateSandboxFleetTokenOptions, Jn as SandboxFleetDispatchResponse, Jt as ListSandboxFleetOptions, Kn as SandboxFleetCostEstimate, L as CreateSandboxFleetWithCoordinatorOptions, N as CreateIntelligenceReportOptions, P as CreateRequestOptions, R as CreateSandboxOptions, Sn as PublishPublicTemplateOptions, Sr as SandboxProfileSummary, Tn as ReapExpiredSandboxFleetsResult, Ur as SecretsManager, Vt as IntelligenceReportBudget, Wn as SandboxFleetArtifact, Wt as IntelligenceReportWindow, Yn as SandboxFleetDriverCapability, Yt as ListSandboxOptions, Zn as SandboxFleetInfo, _ as BatchResult, _r as SandboxInfo, _t as FleetExecDispatchResult, a as AttachSandboxFleetMachineOptions, ar as SandboxFleetOperationsSummary, bn as PublicTemplateInfo, bt as FleetPromptDispatchResult, ci as SubscriptionInfo, cr as SandboxFleetTraceBundle, dr as SandboxFleetTraceOptions, et as ExecOptions, fr as SandboxFleetUsage, ft as FleetDispatchCancelResult, g as BatchOptions, gr as SandboxFleetWorkspaceSnapshotResult, gt as FleetExecDispatchOptions, hn as PromptResult, hr as SandboxFleetWorkspaceRestoreResult, ht as FleetDispatchStreamOptions, ii as SshKeysManager, m as BatchEvent, mn as PromptOptions, mr as SandboxFleetWorkspaceReconcileResult, mt as FleetDispatchResultBufferOptions, pn as PromptInputPart, pt as FleetDispatchResultBuffer, rr as SandboxFleetManifest, sr as SandboxFleetToken, tr as SandboxFleetMachineRecord, tt as ExecResult, v as BatchRunOptions, vt as FleetMachineId, wn as ReapExpiredSandboxFleetsOptions, x as BatchTask, xi as TokenRefreshHandler, xn as PublicTemplateVersionInfo, y as BatchRunRequest, yt as FleetPromptDispatchOptions } from "./types-BvSoEHz8.js";
|
|
2
|
+
import { a as TraceExportSink, i as TraceExportResult, n as SandboxInstance, t as HttpClient } from "./sandbox-BtNWbfd3.js";
|
|
3
3
|
|
|
4
4
|
//#region src/lib/sse-parser.d.ts
|
|
5
5
|
/**
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { a as NotFoundError, d as TimeoutError, f as ValidationError, i as NetworkError, p as parseErrorResponse, t as AuthError } from "./errors-DSz87Rkk.js";
|
|
2
|
-
import { d as exportTraceBundle, g as parseSSEStream, l as normalizeConnection, m as encodePromptForWire, n as normalizeStartupDiagnostics, t as SandboxInstance } from "./sandbox-
|
|
2
|
+
import { d as exportTraceBundle, g as parseSSEStream, l as normalizeConnection, m as encodePromptForWire, n as normalizeStartupDiagnostics, t as SandboxInstance } from "./sandbox-Be9WAqSg.js";
|
|
3
3
|
//#region src/resources.ts
|
|
4
4
|
/**
|
|
5
5
|
* Compute tiers, ordered smallest → largest. Defined HERE (not imported from
|
package/dist/core.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { $t as NetworkConfig,
|
|
2
|
-
import { n as SandboxInstance } from "./sandbox-
|
|
3
|
-
import { i as SandboxClient } from "./client-
|
|
1
|
+
import { $t as NetworkConfig, Bn as SandboxClientConfig, Or as SandboxStatus, R as CreateSandboxOptions, _r as SandboxInfo, an as PreviewLinkManager, et as ExecOptions, in as PreviewLinkInfo, tt as ExecResult } from "./types-BvSoEHz8.js";
|
|
2
|
+
import { n as SandboxInstance } from "./sandbox-BtNWbfd3.js";
|
|
3
|
+
import { i as SandboxClient } from "./client-B8i6qrQr.js";
|
|
4
4
|
import { a as NotFoundError, c as SandboxError, d as ServerError, f as StateError, i as NetworkError, l as SandboxErrorJson, m as ValidationError, n as CapabilityError, o as PartialFailureError, p as TimeoutError, s as QuotaError, t as AuthError, u as SandboxFailureDetail } from "./errors--P_nbLzM.js";
|
|
5
5
|
export { AuthError, CapabilityError, type CreateSandboxOptions, type ExecOptions, type ExecResult, type NetworkConfig, NetworkError, NotFoundError, PartialFailureError, type PreviewLinkInfo, type PreviewLinkManager, QuotaError, SandboxClient as Sandbox, SandboxClient, type SandboxClientConfig, SandboxError, type SandboxErrorJson, type SandboxFailureDetail, type SandboxInfo, SandboxInstance, type SandboxStatus, ServerError, StateError, TimeoutError, ValidationError };
|
package/dist/core.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { a as NotFoundError, c as SandboxError, d as TimeoutError, f as ValidationError, i as NetworkError, l as ServerError, n as CapabilityError, o as PartialFailureError, s as QuotaError, t as AuthError, u as StateError } from "./errors-DSz87Rkk.js";
|
|
2
|
-
import { t as SandboxInstance } from "./sandbox-
|
|
3
|
-
import { n as SandboxClient } from "./client-
|
|
2
|
+
import { t as SandboxInstance } from "./sandbox-Be9WAqSg.js";
|
|
3
|
+
import { n as SandboxClient } from "./client-DTpHjPjc.js";
|
|
4
4
|
export { AuthError, CapabilityError, NetworkError, NotFoundError, PartialFailureError, QuotaError, SandboxClient as Sandbox, SandboxClient, SandboxError, SandboxInstance, ServerError, StateError, TimeoutError, ValidationError };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { R as CreateSandboxOptions } from "./types-
|
|
2
|
-
import { n as SandboxInstance, t as HttpClient } from "./sandbox-
|
|
1
|
+
import { R as CreateSandboxOptions } from "./types-BvSoEHz8.js";
|
|
2
|
+
import { n as SandboxInstance, t as HttpClient } from "./sandbox-BtNWbfd3.js";
|
|
3
3
|
|
|
4
4
|
//#region src/tangle/abi.d.ts
|
|
5
5
|
/**
|
package/dist/index.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { $ as EventStreamOptions, $n as
|
|
2
|
-
import { C as SandboxMcpConfig, D as buildSandboxMcpConfig, E as buildControlPlaneMcpConfig, S as SANDBOX_MCP_SERVER_NAME, T as SandboxMcpServerEntry, _ as RespondToPermissionOptions, a as TraceExportSink, b as BuildSandboxMcpConfigOptions, c as otelTraceIdForTangleTrace, d as SandboxSession, f as InteractiveAuthFile, g as InterruptResult, h as InteractiveSessionInfo, i as TraceExportResult, l as toOtelJson, m as InteractiveSessionHost, n as SandboxInstance, o as buildTraceExportPayload, p as InteractiveSessionHandle, r as TraceExportFormat, s as exportTraceBundle, u as SandboxTaskSession, v as StartInteractiveOptions, w as SandboxMcpEndpoint, x as CONTROL_PLANE_MCP_SERVER_NAME, y as BuildControlPlaneMcpConfigOptions } from "./sandbox-
|
|
3
|
-
import { a as Team, c as SessionBroadcastEvent, d as SandboxFleetClient, f as ParseSSEStreamOptions, i as SandboxClient, l as SessionBroadcastResult, m as parseSSEStream, n as IntelligenceClient, o as TeamInvitation, p as ParsedSSEEvent, r as InviteTeamMemberOptions, s as TeamMember, t as CreateTeamOptions, u as SandboxFleet } from "./client-
|
|
1
|
+
import { $ as EventStreamOptions, $n as SandboxFleetMachine, $r as SessionMessageInputPart, $t as NetworkConfig, A as CommitTaskSessionOptions, Ai as WriteFileOptions, An as Rollout, Ar as SandboxTerminalInfo, At as GpuLeaseCommandResult, B as CreateTaskSessionOptions, Bi as AgentProfilePermissionValue, Bn as SandboxClientConfig, Br as SearchMatch, Bt as IntelligenceReport, C as BatchTaskUsage, Ci as TurnDriveResult, Cn as PublishPublicTemplateVersionOptions, Cr as SandboxResourceUsage, Ct as GitBranch, Di as UsageInfo, Dn as ReconcileSandboxFleetsResult, Dr as SandboxRuntimeProfileList, Dt as GitStatus, Ei as UploadProgress, En as ReconcileSandboxFleetsOptions, Er as SandboxRuntimeProfile, Et as GitDiff, F as CreateSandboxFleetOptions, Fi as AgentProfileConfidential, Fn as RolloutStatus, Fr as SandboxTraceExport, Ft as GpuLeaseStatus, G as DownloadOptions, Gi as AgentProfileValidationResult, Gn as SandboxFleetArtifactSpec, Gr as SendSessionMessageRequest, H as DirectoryPermission, Hi as AgentProfileResourceRef, Hn as SandboxEnvironment, Hr as SecretInfo, Ht as IntelligenceReportCompareTo, Ii as AgentProfileConnection, In as RolloutTurnPart, Ir as SandboxTraceOptions, It as GpuType, J as DriverConfig, Ji as defineGitHubResource, Jn as SandboxFleetDispatchResponse, Jr as SessionEventStreamOptions, Jt as ListSandboxFleetOptions, K as DownloadProgress, Ki as AgentSubagentProfile, Kn as SandboxFleetCostEstimate, Kr as SentSessionMessage, Kt as ListMessagesOptions, L as CreateSandboxFleetWithCoordinatorOptions, Li as AgentProfileFileMount, Ln as RunCodeOptions, Lr as SandboxUser, Lt as HostAgentDriverConfig, M as CreateGpuLeaseOptions, Mi as WriteManyOptions, Mn as RolloutOptions, Mr as SandboxTerminalRequestOptions, Mt as GpuLeaseExecResult, N as CreateIntelligenceReportOptions, Ni as AgentProfile, Nn as RolloutScorer, Nr as SandboxTraceBundle, Nt as GpuLeaseManager, O as CodeResult, Oi as WaitForOptions, Or as SandboxStatus, Ot as GpuLease, P as CreateRequestOptions, Pi as AgentProfileCapabilities, Pn as RolloutStartResult, Pr as SandboxTraceEvent, Pt as GpuLeaseProviderName, Q as EgressPolicy, Qn as SandboxFleetIntelligenceEnvelope, Qr as SessionMessage, Qt as MkdirOptions, R as CreateSandboxOptions, Ri as AgentProfileMcpServer, Rn as SSHCommandDescriptor, Rr as ScopedToken, Rt as HostAgentRuntimeBackend, S as BatchTaskResult, Si as ToolsConfig, Sn as PublishPublicTemplateOptions, Sr as SandboxProfileSummary, St as GitAuth, Ti as UploadOptions, Tn as ReapExpiredSandboxFleetsResult, Tr as SandboxRuntimeHealth, Tt as GitConfig, U as DispatchPromptOptions, Ui as AgentProfileResources, Un as SandboxEvent, Ur as SecretsManager, Ut as IntelligenceReportSubjectType, V as DeleteOptions, Vi as AgentProfilePrompt, Vn as SandboxConnection, Vr as SearchOptions, Vt as IntelligenceReportBudget, W as DispatchedSession, Wi as AgentProfileValidationIssue, Wn as SandboxFleetArtifact, Wr as SendSessionMessageOptions, Wt as IntelligenceReportWindow, X as DriverType, Xi as mergeAgentProfiles, Xn as SandboxFleetDriverTimings, Xr as SessionInfo, Xt as McpServerConfig, Y as DriverInfo, Yi as defineInlineResource, Yn as SandboxFleetDriverCapability, Yr as SessionForkOptions, Yt as ListSandboxOptions, Z as EgressManager, Zn as SandboxFleetInfo, Zr as SessionListOptions, Zt as MintScopedTokenOptions, _ as BatchResult, _i as TeeAttestationReport, _n as ProvisionResult, _r as SandboxInfo, a as AttachSandboxFleetMachineOptions, ai as StartupDiagnostics, an as PreviewLinkManager, ar as SandboxFleetOperationsSummary, at as FileReadError, b as BatchSidecarGroup, bi as TeePublicKeyResponse, bn as PublicTemplateInfo, br as SandboxPortBinding, c as BackendInfo, ci as SubscriptionInfo, cn as ProcessLogEntry, cr as SandboxFleetTraceBundle, ct as FileTreeFile, d as BackendType, di as TaskSessionChanges, dn as ProcessSpawnOptions, dr as SandboxFleetTraceOptions, dt as FileWriteResult, ei as SessionStatus, en as NetworkManager, er as SandboxFleetMachineMeteredUsage, et as ExecOptions, f as BatchBackend, fi as TaskSessionCommitResult, fn as ProcessStatus, fr as SandboxFleetUsage, ft as FleetDispatchCancelResult, g as BatchOptions, gi as TeeAttestationOptions, gn as ProvisionEvent, gr as SandboxFleetWorkspaceSnapshotResult, gt as FleetExecDispatchOptions, h as BatchEventDataMap, hi as TaskSessionProfile, hn as PromptResult, hr as SandboxFleetWorkspaceRestoreResult, ht as FleetDispatchStreamOptions, i as AttachGpuLeaseOptions, in as PreviewLinkInfo, ir as SandboxFleetManifestMachine, it as FileReadBatchResult, j as CompletedTurnResult, ji as WriteManyFile, jn as RolloutChildResult, jr as SandboxTerminalManager, jt as GpuLeaseExecOptions, ki as WaitForRolloutOptions, kr as SandboxTerminalCreateOptions, kt as GpuLeaseBilling, l as BackendManager, li as TaskOptions, ln as ProcessManager, lr as SandboxFleetTraceEvent, lt as FileTreeOptions, m as BatchEvent, mi as TaskSessionInfo, mn as PromptOptions, mr as SandboxFleetWorkspaceReconcileResult, mt as FleetDispatchResultBufferOptions, n as AccessPolicyRule, ni as SnapshotOptions, nn as PermissionLevel, nr as SandboxFleetMachineSpec, nt as FileInfo, o as BackendCapabilities, oi as StartupOperation, on as Process, or as SandboxFleetPolicy, ot as FileReadResult, p as BatchBackendStats, pi as TaskSessionFileChange, pr as SandboxFleetWorkspace, pt as FleetDispatchResultBuffer, q as DriveTurnOptions, qi as defineAgentProfile, qn as SandboxFleetDispatchFailureClass, qr as SessionBackendCredentials, qt as ListOptions, r as AddUserOptions, ri as SnapshotResult, rn as PermissionsManager, rr as SandboxFleetManifest, rt as FileReadBatchOptions, s as BackendConfig, si as StorageConfig, sn as ProcessInfo, sr as SandboxFleetToken, st as FileSystem, t as AcceleratorKind, ti as SnapshotInfo, tn as NonHostAgentDriverConfig, tr as SandboxFleetMachineRecord, tt as ExecResult, u as BackendStatus, ui as TaskResult, un as ProcessSignal, ur as SandboxFleetTraceExport, ut as FileTreeResult, v as BatchRunOptions, vi as TeeAttestationResponse, vn as ProvisionStatus, vr as SandboxIntelligenceEnvelope, vt as FleetMachineId, w as BranchOptions, wi as UpdateUserOptions, wn as ReapExpiredSandboxFleetsOptions, wr as SandboxResources, wt as GitCommit, x as BatchTask, xi as TokenRefreshHandler, xn as PublicTemplateVersionInfo, xr as SandboxPortPreviewLink, xt as GPU_LEASE_PROVIDER_NAMES, y as BatchRunRequest, yi as TeePublicKey, yn as ProvisionStep, yr as SandboxPermissionsConfig, yt as FleetPromptDispatchOptions, z as CreateSessionOptions, zi as AgentProfileModelHints, zn as SSHCredentials, zr as ScopedTokenScope, zt as InstalledTool } from "./types-BvSoEHz8.js";
|
|
2
|
+
import { C as SandboxMcpConfig, D as buildSandboxMcpConfig, E as buildControlPlaneMcpConfig, S as SANDBOX_MCP_SERVER_NAME, T as SandboxMcpServerEntry, _ as RespondToPermissionOptions, a as TraceExportSink, b as BuildSandboxMcpConfigOptions, c as otelTraceIdForTangleTrace, d as SandboxSession, f as InteractiveAuthFile, g as InterruptResult, h as InteractiveSessionInfo, i as TraceExportResult, l as toOtelJson, m as InteractiveSessionHost, n as SandboxInstance, o as buildTraceExportPayload, p as InteractiveSessionHandle, r as TraceExportFormat, s as exportTraceBundle, u as SandboxTaskSession, v as StartInteractiveOptions, w as SandboxMcpEndpoint, x as CONTROL_PLANE_MCP_SERVER_NAME, y as BuildControlPlaneMcpConfigOptions } from "./sandbox-BtNWbfd3.js";
|
|
3
|
+
import { a as Team, c as SessionBroadcastEvent, d as SandboxFleetClient, f as ParseSSEStreamOptions, i as SandboxClient, l as SessionBroadcastResult, m as parseSSEStream, n as IntelligenceClient, o as TeamInvitation, p as ParsedSSEEvent, r as InviteTeamMemberOptions, s as TeamMember, t as CreateTeamOptions, u as SandboxFleet } from "./client-B8i6qrQr.js";
|
|
4
4
|
import { d as AnyTokenPayload, h as IssueCollaborationTokenOptions, m as CollaborationTokenPayload, p as CollaborationAccess } from "./index-CyHojkuA.js";
|
|
5
5
|
import { _ as CollaborationTransportConfig, a as CollaborationClient, c as CollaborationClientConfig, d as CollaborationDocumentRef, f as CollaborationFileBridgeOptions, g as CollaborationTokenRefreshResponse, h as CollaborationTokenRefreshRequest, i as parseCollaborationDocumentId, l as CollaborationDocumentAdapter, m as CollaborationPermissions, n as buildCollaborationDocumentId, o as CollaborationBootstrapRequest, p as CollaborationFileEvent, r as normalizeCollaborationPath, s as CollaborationBootstrapResponse, t as CollaborationFileBridge, u as CollaborationDocumentChange, v as SaveCollaborationSnapshotRequest, y as SaveCollaborationSnapshotResponse } from "./index-DKzapw-9.js";
|
|
6
6
|
import { a as NotFoundError, c as SandboxError, d as ServerError, f as StateError, i as NetworkError, l as SandboxErrorJson, m as ValidationError, n as CapabilityError, o as PartialFailureError, p as TimeoutError, r as EgressProxyRecoveryError, s as QuotaError, t as AuthError, u as SandboxFailureDetail } from "./errors--P_nbLzM.js";
|
|
7
|
-
import { s as TangleSandboxClientConfig, t as TangleSandboxClient } from "./index-
|
|
7
|
+
import { s as TangleSandboxClientConfig, t as TangleSandboxClient } from "./index-BFnMEze6.js";
|
|
8
8
|
|
|
9
9
|
//#region src/attestation-heartbeat.d.ts
|
|
10
10
|
interface TeeAttestationHeartbeatSample {
|
|
@@ -1371,4 +1371,4 @@ interface RouterEvalMatrixCaseResult {
|
|
|
1371
1371
|
}
|
|
1372
1372
|
declare function runTangleRouterEvalMatrixInSandbox(options: RunTangleRouterEvalMatrixInSandboxOptions): Promise<RunTangleRouterEvalMatrixInSandboxResult>;
|
|
1373
1373
|
//#endregion
|
|
1374
|
-
export { type AcceleratorKind, type AccessPolicyRule, type AddUserOptions, type AgentProfile, type AgentProfileCapabilities, type AgentProfileConnection, type AgentProfileFileMount, type AgentProfileMcpServer, type AgentProfileModelHints, type AgentProfilePermissionValue, type AgentProfilePrompt, type AgentProfileResourceRef, type AgentProfileResources, type AgentProfileValidationIssue, type AgentProfileValidationResult, type AgentSubagentProfile, type AnyTokenPayload, type AttachGpuLeaseOptions, type AttachSandboxFleetMachineOptions, AuthError, type BackendCapabilities, type BackendConfig, type BackendInfo, type BackendManager, type BackendStatus, type BackendType, type BatchBackend, type BatchBackendStats, type BatchEvent, type BatchEventDataMap, type BatchOptions, type BatchResult, type BatchRunOptions, type BatchRunRequest, type BatchSidecarGroup, type BatchTask, type BatchTaskResult, type BatchTaskUsage, type BranchOptions, type BuildControlPlaneMcpConfigOptions, type BuildProgressEvent, type BuildSandboxMcpConfigOptions, CONTROL_PLANE_MCP_SERVER_NAME, CapabilityError, type CodeResult, type CollaborationAccess, type CollaborationBootstrapRequest, type CollaborationBootstrapResponse, CollaborationClient, type CollaborationClientConfig, type CollaborationDocumentAdapter, type CollaborationDocumentChange, type CollaborationDocumentRef, CollaborationFileBridge, type CollaborationFileBridgeOptions, type CollaborationFileEvent, type CollaborationPermissions, type CollaborationTokenPayload, type CollaborationTokenRefreshRequest, type CollaborationTokenRefreshResponse, type CollaborationTransportConfig, type CommitTaskSessionOptions, type CompletedTurnResult, type ConfidentialSandboxResult, type ConfidentialTeeType, type CreateConfidentialSandboxOptions, type CreateGpuLeaseOptions, type CreateIntelligenceReportOptions, type CreateSandboxFleetOptions, type CreateSandboxFleetWithCoordinatorOptions, type CreateSandboxOptions, type CreateSessionOptions, type CreateTaskSessionOptions, type CreateTeamOptions, DEFAULT_SANDBOX_SIZE, type DeleteOptions, type DirectoryPermission, type DispatchPromptOptions, type DispatchedSession, type DownloadOptions, type DownloadProgress, type DriveTurnOptions, type DriverConfig, type DriverInfo, type DriverType, type EgressManager, type EgressPolicy, EgressProxyRecoveryError, type EventStreamOptions, type ExecOptions, type ExecResult, type FileInfo, type FileReadBatchOptions, type FileReadBatchResult, type FileReadError, type FileReadResult, type FileSystem, type FileTreeFile, type FileTreeOptions, type FileTreeResult, type FileWriteResult, type FleetDispatchCancelResult, type FleetDispatchResultBuffer, type FleetDispatchResultBufferOptions, type FleetDispatchStreamOptions, type FleetExecDispatchOptions, type FleetMachineId, type FleetPromptDispatchOptions, GPU_LEASE_PROVIDER_NAMES, type GitAuth, type GitBranch, type GitCommit, type GitConfig, type GitDiff, type GitStatus, type GpuLease, type GpuLeaseBilling, type GpuLeaseCommandResult, type GpuLeaseExecOptions, type GpuLeaseExecResult, type GpuLeaseManager, type GpuLeaseProviderName, type GpuLeaseStatus, type GpuType, type HostAgentDriverConfig, type HostAgentRuntimeBackend, Image, type ImageBuildClient, type ImageBuildClientConfig, type ImageBuildFetchClient, type ImageBuildOptions, type ImageBuildResult, ImageBuilder, type ImageSpec, type InstalledTool, IntelligenceClient, type IntelligenceReport, type IntelligenceReportBudget, type IntelligenceReportCompareTo, type IntelligenceReportSubjectType, type IntelligenceReportWindow, type InteractiveAuthFile, InteractiveSessionHandle, type InteractiveSessionHost, type InteractiveSessionInfo, type InterruptResult, type InviteTeamMemberOptions, type IssueCollaborationTokenOptions, type ListMessagesOptions, type ListOptions, type ListSandboxFleetOptions, type ListSandboxOptions, MANAGE_SANDBOXES_PARAMETERS, MANAGE_SANDBOXES_TOOL_NAME, type ManageSandboxesInput, type ManageSandboxesTool, type ManageSandboxesToolOptions, type MaterializeProfileFileMountsOptions, type MaterializeProfileFileMountsResult, type McpServerConfig, type MintScopedTokenOptions, type MkdirOptions, type NetworkConfig, NetworkError, type NetworkManager, type NonHostAgentDriverConfig, NotFoundError, type ParseSSEStreamOptions, type ParsedSSEEvent, PartialFailureError, type PermissionLevel, type PermissionsManager, type PreviewLinkInfo, type PreviewLinkManager, type Process, type ProcessInfo, type ProcessLogEntry, type ProcessManager, type ProcessSignal, type ProcessSpawnOptions, type ProcessStatus, type PromptOptions, type PromptResult, type ProvisionEvent, type ProvisionResult, type ProvisionStatus, type ProvisionStep, type PublicTemplateInfo, type PublicTemplateVersionInfo, type PublishPublicTemplateOptions, type PublishPublicTemplateVersionOptions, QuotaError, type ReapExpiredSandboxFleetsOptions, type ReapExpiredSandboxFleetsResult, type ReconcileSandboxFleetsOptions, type ReconcileSandboxFleetsResult, type RespondToPermissionOptions, type RouterEvalMatrixAgentProfile, type RouterEvalMatrixCaseResult, type RouterEvalMatrixHarness, type RouterEvalMatrixPayload, type RouterEvalMatrixSandboxBox, type RouterEvalMatrixSandboxClient, type RouterEvalMatrixScenario, type RouterEvalMatrixSuiteResponse, type RouterImportedRunResponse, type RouterSearchConfig, type RouterSearchConfigOptions, type RunCodeOptions, type RunTangleRouterEvalMatrixInSandboxOptions, type RunTangleRouterEvalMatrixInSandboxResult, SANDBOX_MCP_SERVER_NAME, SANDBOX_SIZE_PRESETS, SANDBOX_SIZE_PRESET_NAMES, type SSHCommandDescriptor, type SSHCredentials, SandboxClient as Sandbox, SandboxClient, type SandboxClientConfig, type SandboxConnection, type SandboxEnvironment, SandboxError, type SandboxErrorJson, type SandboxEvent, type SandboxFailureDetail, SandboxFleet, type SandboxFleetArtifact, type SandboxFleetArtifactSpec, SandboxFleetClient, type SandboxFleetCostEstimate, type SandboxFleetDispatchFailureClass, type SandboxFleetDispatchResponse, type SandboxFleetDriverCapability, type SandboxFleetDriverTimings, type SandboxFleetInfo, type SandboxFleetIntelligenceEnvelope, type SandboxFleetMachine, type SandboxFleetMachineMeteredUsage, type SandboxFleetMachineRecord, type SandboxFleetMachineSpec, type SandboxFleetManifest, type SandboxFleetManifestMachine, type SandboxFleetOperationsSummary, type SandboxFleetPolicy, type SandboxFleetToken, type SandboxFleetTraceBundle, type SandboxFleetTraceEvent, type SandboxFleetTraceExport, type SandboxFleetTraceOptions, type SandboxFleetUsage, type SandboxFleetWorkspace, type SandboxFleetWorkspaceReconcileResult, type SandboxFleetWorkspaceRestoreResult, type SandboxFleetWorkspaceSnapshotResult, type SandboxInfo, SandboxInstance, type SandboxIntelligenceEnvelope, type SandboxMcpConfig, type SandboxMcpEndpoint, type SandboxMcpServerEntry, type SandboxPermissionsConfig, type SandboxPortBinding, type SandboxPortPreviewLink, type SandboxProfileSummary, type SandboxResourceUsage, type SandboxResources, type SandboxRuntimeHealth, type SandboxRuntimeProfile, type SandboxRuntimeProfileList, SandboxSession, type SandboxSizePreset, type SandboxStatus, SandboxTaskSession, type SandboxTerminalCreateOptions, type SandboxTerminalInfo, type SandboxTerminalManager, type SandboxTerminalRequestOptions, type SandboxTraceBundle, type SandboxTraceEvent, type SandboxTraceExport, type SandboxTraceOptions, type SandboxUser, type SaveCollaborationSnapshotRequest, type SaveCollaborationSnapshotResponse, type ScopedToken, type ScopedTokenScope, type SearchMatch, type SearchOptions, type SecretInfo, type SecretsManager, type SendSessionMessageOptions, type SendSessionMessageRequest, type SentSessionMessage, ServerError, type SessionBackendCredentials, type SessionBroadcastEvent, type SessionBroadcastResult, type SessionEventStreamOptions, type SessionForkOptions, type SessionInfo, type SessionListOptions, type SessionMessage, type SessionMessageInputPart, type SessionStatus, type SnapshotInfo, type SnapshotOptions, type SnapshotResult, type SplitInlineProfileFileMountsResult, type StartInteractiveOptions, type StartupDiagnostics, type StartupOperation, StateError, type StorageConfig, type SubscriptionInfo, TangleSandboxClient, type TangleSandboxClientConfig, type TangleSearchProvider, type TaskOptions, type TaskResult, type TaskSessionChanges, type TaskSessionCommitResult, type TaskSessionFileChange, type TaskSessionInfo, type TaskSessionProfile, type Team, type TeamInvitation, type TeamMember, type TeeAttestationHeartbeat, type TeeAttestationHeartbeatOptions, type TeeAttestationHeartbeatSample, type TeeAttestationOptions, type TeeAttestationReport, type TeeAttestationResponse, type TeePublicKey, type TeePublicKeyResponse, TimeoutError, type TokenRefreshHandler, type ToolsConfig, type TraceExportFormat, type TraceExportResult, type TraceExportSink, type TurnDriveResult, type UpdateUserOptions, type UploadOptions, type UploadProgress, type UsageInfo, ValidationError, type WaitForOptions, type WriteFileOptions, type WriteManyFile, type WriteManyOptions, applySandboxEventText, buildCollaborationDocumentId, buildControlPlaneMcpConfig, buildSandboxMcpConfig, buildTangleRouterEvalMatrixRequest, buildTangleRouterResponsesWebSearchRequest, buildTangleRouterSearchBackend, buildTangleRouterSearchProfile, buildTraceExportPayload, collectAgentResponseText, createConfidentialSandbox, createManageSandboxesTool, defineAgentProfile, defineGitHubResource, defineInlineResource, exportTraceBundle, fetchTangleRouterSearchConfig, generateAttestationNonce, generateDockerfile, getSandboxEventText, materializeProfileFileMounts, mergeAgentProfiles, normalizeCollaborationPath, normalizeRuntimeBackendConfig, otelTraceIdForTangleTrace, parseCollaborationDocumentId, parseSSEStream, resolveSandboxResources, runTangleRouterEvalMatrixInSandbox, sandboxResourcesForSize, serializeForSidecar, splitInlineProfileFileMounts, startTeeAttestationHeartbeat, toOtelJson };
|
|
1374
|
+
export { type AcceleratorKind, type AccessPolicyRule, type AddUserOptions, type AgentProfile, type AgentProfileCapabilities, type AgentProfileConnection, type AgentProfileFileMount, type AgentProfileMcpServer, type AgentProfileModelHints, type AgentProfilePermissionValue, type AgentProfilePrompt, type AgentProfileResourceRef, type AgentProfileResources, type AgentProfileValidationIssue, type AgentProfileValidationResult, type AgentSubagentProfile, type AnyTokenPayload, type AttachGpuLeaseOptions, type AttachSandboxFleetMachineOptions, AuthError, type BackendCapabilities, type BackendConfig, type BackendInfo, type BackendManager, type BackendStatus, type BackendType, type BatchBackend, type BatchBackendStats, type BatchEvent, type BatchEventDataMap, type BatchOptions, type BatchResult, type BatchRunOptions, type BatchRunRequest, type BatchSidecarGroup, type BatchTask, type BatchTaskResult, type BatchTaskUsage, type BranchOptions, type BuildControlPlaneMcpConfigOptions, type BuildProgressEvent, type BuildSandboxMcpConfigOptions, CONTROL_PLANE_MCP_SERVER_NAME, CapabilityError, type CodeResult, type CollaborationAccess, type CollaborationBootstrapRequest, type CollaborationBootstrapResponse, CollaborationClient, type CollaborationClientConfig, type CollaborationDocumentAdapter, type CollaborationDocumentChange, type CollaborationDocumentRef, CollaborationFileBridge, type CollaborationFileBridgeOptions, type CollaborationFileEvent, type CollaborationPermissions, type CollaborationTokenPayload, type CollaborationTokenRefreshRequest, type CollaborationTokenRefreshResponse, type CollaborationTransportConfig, type CommitTaskSessionOptions, type CompletedTurnResult, type ConfidentialSandboxResult, type ConfidentialTeeType, type CreateConfidentialSandboxOptions, type CreateGpuLeaseOptions, type CreateIntelligenceReportOptions, type CreateRequestOptions, type CreateSandboxFleetOptions, type CreateSandboxFleetWithCoordinatorOptions, type CreateSandboxOptions, type CreateSessionOptions, type CreateTaskSessionOptions, type CreateTeamOptions, DEFAULT_SANDBOX_SIZE, type DeleteOptions, type DirectoryPermission, type DispatchPromptOptions, type DispatchedSession, type DownloadOptions, type DownloadProgress, type DriveTurnOptions, type DriverConfig, type DriverInfo, type DriverType, type EgressManager, type EgressPolicy, EgressProxyRecoveryError, type EventStreamOptions, type ExecOptions, type ExecResult, type FileInfo, type FileReadBatchOptions, type FileReadBatchResult, type FileReadError, type FileReadResult, type FileSystem, type FileTreeFile, type FileTreeOptions, type FileTreeResult, type FileWriteResult, type FleetDispatchCancelResult, type FleetDispatchResultBuffer, type FleetDispatchResultBufferOptions, type FleetDispatchStreamOptions, type FleetExecDispatchOptions, type FleetMachineId, type FleetPromptDispatchOptions, GPU_LEASE_PROVIDER_NAMES, type GitAuth, type GitBranch, type GitCommit, type GitConfig, type GitDiff, type GitStatus, type GpuLease, type GpuLeaseBilling, type GpuLeaseCommandResult, type GpuLeaseExecOptions, type GpuLeaseExecResult, type GpuLeaseManager, type GpuLeaseProviderName, type GpuLeaseStatus, type GpuType, type HostAgentDriverConfig, type HostAgentRuntimeBackend, Image, type ImageBuildClient, type ImageBuildClientConfig, type ImageBuildFetchClient, type ImageBuildOptions, type ImageBuildResult, ImageBuilder, type ImageSpec, type InstalledTool, IntelligenceClient, type IntelligenceReport, type IntelligenceReportBudget, type IntelligenceReportCompareTo, type IntelligenceReportSubjectType, type IntelligenceReportWindow, type InteractiveAuthFile, InteractiveSessionHandle, type InteractiveSessionHost, type InteractiveSessionInfo, type InterruptResult, type InviteTeamMemberOptions, type IssueCollaborationTokenOptions, type ListMessagesOptions, type ListOptions, type ListSandboxFleetOptions, type ListSandboxOptions, MANAGE_SANDBOXES_PARAMETERS, MANAGE_SANDBOXES_TOOL_NAME, type ManageSandboxesInput, type ManageSandboxesTool, type ManageSandboxesToolOptions, type MaterializeProfileFileMountsOptions, type MaterializeProfileFileMountsResult, type McpServerConfig, type MintScopedTokenOptions, type MkdirOptions, type NetworkConfig, NetworkError, type NetworkManager, type NonHostAgentDriverConfig, NotFoundError, type ParseSSEStreamOptions, type ParsedSSEEvent, PartialFailureError, type PermissionLevel, type PermissionsManager, type PreviewLinkInfo, type PreviewLinkManager, type Process, type ProcessInfo, type ProcessLogEntry, type ProcessManager, type ProcessSignal, type ProcessSpawnOptions, type ProcessStatus, type PromptOptions, type PromptResult, type ProvisionEvent, type ProvisionResult, type ProvisionStatus, type ProvisionStep, type PublicTemplateInfo, type PublicTemplateVersionInfo, type PublishPublicTemplateOptions, type PublishPublicTemplateVersionOptions, QuotaError, type ReapExpiredSandboxFleetsOptions, type ReapExpiredSandboxFleetsResult, type ReconcileSandboxFleetsOptions, type ReconcileSandboxFleetsResult, type RespondToPermissionOptions, type Rollout, type RolloutChildResult, type RolloutOptions, type RolloutScorer, type RolloutStartResult, type RolloutStatus, type RolloutTurnPart, type RouterEvalMatrixAgentProfile, type RouterEvalMatrixCaseResult, type RouterEvalMatrixHarness, type RouterEvalMatrixPayload, type RouterEvalMatrixSandboxBox, type RouterEvalMatrixSandboxClient, type RouterEvalMatrixScenario, type RouterEvalMatrixSuiteResponse, type RouterImportedRunResponse, type RouterSearchConfig, type RouterSearchConfigOptions, type RunCodeOptions, type RunTangleRouterEvalMatrixInSandboxOptions, type RunTangleRouterEvalMatrixInSandboxResult, SANDBOX_MCP_SERVER_NAME, SANDBOX_SIZE_PRESETS, SANDBOX_SIZE_PRESET_NAMES, type SSHCommandDescriptor, type SSHCredentials, SandboxClient as Sandbox, SandboxClient, type SandboxClientConfig, type SandboxConnection, type SandboxEnvironment, SandboxError, type SandboxErrorJson, type SandboxEvent, type SandboxFailureDetail, SandboxFleet, type SandboxFleetArtifact, type SandboxFleetArtifactSpec, SandboxFleetClient, type SandboxFleetCostEstimate, type SandboxFleetDispatchFailureClass, type SandboxFleetDispatchResponse, type SandboxFleetDriverCapability, type SandboxFleetDriverTimings, type SandboxFleetInfo, type SandboxFleetIntelligenceEnvelope, type SandboxFleetMachine, type SandboxFleetMachineMeteredUsage, type SandboxFleetMachineRecord, type SandboxFleetMachineSpec, type SandboxFleetManifest, type SandboxFleetManifestMachine, type SandboxFleetOperationsSummary, type SandboxFleetPolicy, type SandboxFleetToken, type SandboxFleetTraceBundle, type SandboxFleetTraceEvent, type SandboxFleetTraceExport, type SandboxFleetTraceOptions, type SandboxFleetUsage, type SandboxFleetWorkspace, type SandboxFleetWorkspaceReconcileResult, type SandboxFleetWorkspaceRestoreResult, type SandboxFleetWorkspaceSnapshotResult, type SandboxInfo, SandboxInstance, type SandboxIntelligenceEnvelope, type SandboxMcpConfig, type SandboxMcpEndpoint, type SandboxMcpServerEntry, type SandboxPermissionsConfig, type SandboxPortBinding, type SandboxPortPreviewLink, type SandboxProfileSummary, type SandboxResourceUsage, type SandboxResources, type SandboxRuntimeHealth, type SandboxRuntimeProfile, type SandboxRuntimeProfileList, SandboxSession, type SandboxSizePreset, type SandboxStatus, SandboxTaskSession, type SandboxTerminalCreateOptions, type SandboxTerminalInfo, type SandboxTerminalManager, type SandboxTerminalRequestOptions, type SandboxTraceBundle, type SandboxTraceEvent, type SandboxTraceExport, type SandboxTraceOptions, type SandboxUser, type SaveCollaborationSnapshotRequest, type SaveCollaborationSnapshotResponse, type ScopedToken, type ScopedTokenScope, type SearchMatch, type SearchOptions, type SecretInfo, type SecretsManager, type SendSessionMessageOptions, type SendSessionMessageRequest, type SentSessionMessage, ServerError, type SessionBackendCredentials, type SessionBroadcastEvent, type SessionBroadcastResult, type SessionEventStreamOptions, type SessionForkOptions, type SessionInfo, type SessionListOptions, type SessionMessage, type SessionMessageInputPart, type SessionStatus, type SnapshotInfo, type SnapshotOptions, type SnapshotResult, type SplitInlineProfileFileMountsResult, type StartInteractiveOptions, type StartupDiagnostics, type StartupOperation, StateError, type StorageConfig, type SubscriptionInfo, TangleSandboxClient, type TangleSandboxClientConfig, type TangleSearchProvider, type TaskOptions, type TaskResult, type TaskSessionChanges, type TaskSessionCommitResult, type TaskSessionFileChange, type TaskSessionInfo, type TaskSessionProfile, type Team, type TeamInvitation, type TeamMember, type TeeAttestationHeartbeat, type TeeAttestationHeartbeatOptions, type TeeAttestationHeartbeatSample, type TeeAttestationOptions, type TeeAttestationReport, type TeeAttestationResponse, type TeePublicKey, type TeePublicKeyResponse, TimeoutError, type TokenRefreshHandler, type ToolsConfig, type TraceExportFormat, type TraceExportResult, type TraceExportSink, type TurnDriveResult, type UpdateUserOptions, type UploadOptions, type UploadProgress, type UsageInfo, ValidationError, type WaitForOptions, type WaitForRolloutOptions, type WriteFileOptions, type WriteManyFile, type WriteManyOptions, applySandboxEventText, buildCollaborationDocumentId, buildControlPlaneMcpConfig, buildSandboxMcpConfig, buildTangleRouterEvalMatrixRequest, buildTangleRouterResponsesWebSearchRequest, buildTangleRouterSearchBackend, buildTangleRouterSearchProfile, buildTraceExportPayload, collectAgentResponseText, createConfidentialSandbox, createManageSandboxesTool, defineAgentProfile, defineGitHubResource, defineInlineResource, exportTraceBundle, fetchTangleRouterSearchConfig, generateAttestationNonce, generateDockerfile, getSandboxEventText, materializeProfileFileMounts, mergeAgentProfiles, normalizeCollaborationPath, normalizeRuntimeBackendConfig, otelTraceIdForTangleTrace, parseCollaborationDocumentId, parseSSEStream, resolveSandboxResources, runTangleRouterEvalMatrixInSandbox, sandboxResourcesForSize, serializeForSidecar, splitInlineProfileFileMounts, startTeeAttestationHeartbeat, toOtelJson };
|
package/dist/index.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { i as serializeForSidecar, r as normalizeRuntimeBackendConfig } from "./runtime-api-CYA2DUQw.js";
|
|
2
2
|
import { a as NotFoundError, c as SandboxError, d as TimeoutError, f as ValidationError, i as NetworkError, l as ServerError, n as CapabilityError, o as PartialFailureError, r as EgressProxyRecoveryError, s as QuotaError, t as AuthError, u as StateError } from "./errors-DSz87Rkk.js";
|
|
3
|
-
import { a as InteractiveSessionHandle, c as getSandboxEventText, d as exportTraceBundle, f as otelTraceIdForTangleTrace, g as parseSSEStream, h as encodeTextForWire, i as SandboxSession, o as applySandboxEventText, p as toOtelJson, r as SandboxTaskSession, s as collectAgentResponseText, t as SandboxInstance, u as buildTraceExportPayload } from "./sandbox-
|
|
4
|
-
import { a as DEFAULT_SANDBOX_SIZE, c as resolveSandboxResources, i as SandboxFleetClient, l as sandboxResourcesForSize, n as SandboxClient, o as SANDBOX_SIZE_PRESETS, r as SandboxFleet, s as SANDBOX_SIZE_PRESET_NAMES, t as IntelligenceClient } from "./client-
|
|
3
|
+
import { a as InteractiveSessionHandle, c as getSandboxEventText, d as exportTraceBundle, f as otelTraceIdForTangleTrace, g as parseSSEStream, h as encodeTextForWire, i as SandboxSession, o as applySandboxEventText, p as toOtelJson, r as SandboxTaskSession, s as collectAgentResponseText, t as SandboxInstance, u as buildTraceExportPayload } from "./sandbox-Be9WAqSg.js";
|
|
4
|
+
import { a as DEFAULT_SANDBOX_SIZE, c as resolveSandboxResources, i as SandboxFleetClient, l as sandboxResourcesForSize, n as SandboxClient, o as SANDBOX_SIZE_PRESETS, r as SandboxFleet, s as SANDBOX_SIZE_PRESET_NAMES, t as IntelligenceClient } from "./client-DTpHjPjc.js";
|
|
5
5
|
import { a as CollaborationClient, i as parseCollaborationDocumentId, n as buildCollaborationDocumentId, r as normalizeCollaborationPath, t as CollaborationFileBridge } from "./collaboration-QZXrXdIb.js";
|
|
6
|
-
import { t as TangleSandboxClient } from "./tangle-
|
|
6
|
+
import { t as TangleSandboxClient } from "./tangle-D6UfK_B0.js";
|
|
7
7
|
import { defineAgentProfile, defineGitHubResource, defineInlineResource, mergeAgentProfiles } from "@tangle-network/agent-interface";
|
|
8
8
|
//#region src/confidential.ts
|
|
9
9
|
function generateAttestationNonce(bytes = 32) {
|
package/dist/runtime.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { A as CommitTaskSessionOptions,
|
|
1
|
+
import { A as CommitTaskSessionOptions, Ai as WriteFileOptions, Ar as SandboxTerminalInfo, B as CreateTaskSessionOptions, Dr as SandboxRuntimeProfileList, Gr as SendSessionMessageRequest, Kr as SentSessionMessage, Kt as ListMessagesOptions, Mr as SandboxTerminalRequestOptions, Qr as SessionMessage, Tr as SandboxRuntimeHealth, Wr as SendSessionMessageOptions, Xr as SessionInfo, br as SandboxPortBinding, di as TaskSessionChanges, dt as FileWriteResult, fi as TaskSessionCommitResult, it as FileReadBatchResult, jr as SandboxTerminalManager, kr as SandboxTerminalCreateOptions, lt as FileTreeOptions, mi as TaskSessionInfo, rt as FileReadBatchOptions, ut as FileTreeResult, z as CreateSessionOptions } from "./types-BvSoEHz8.js";
|
|
2
2
|
import { a as NotFoundError, c as SandboxError, d as ServerError, f as StateError, i as NetworkError, l as SandboxErrorJson, m as ValidationError, n as CapabilityError, o as PartialFailureError, p as TimeoutError, s as QuotaError, t as AuthError, u as SandboxFailureDetail } from "./errors--P_nbLzM.js";
|
|
3
3
|
|
|
4
4
|
//#region src/runtime-api.d.ts
|
|
@@ -752,6 +752,13 @@ function isTransientSnapshotVisibilityError(error) {
|
|
|
752
752
|
return message.includes("SNAPSHOT_NOT_FOUND") || message.includes("Failed to list snapshot") || message.includes("Storage agent error (404)");
|
|
753
753
|
}
|
|
754
754
|
/**
|
|
755
|
+
* The extra separator is intentional: absolute paths produce `//`, allowing
|
|
756
|
+
* the runtime route wildcard to retain the path's leading slash.
|
|
757
|
+
*/
|
|
758
|
+
function runtimeFilesystemPath(endpoint, path) {
|
|
759
|
+
return `${endpoint}/${path}`;
|
|
760
|
+
}
|
|
761
|
+
/**
|
|
755
762
|
* Single source of truth for a run's outcome, shared by
|
|
756
763
|
* `prompt`/`task`/`_sessionResult`/turn settling. A run succeeds only when it
|
|
757
764
|
* reached a terminal event, raised no run-level error, hit no approval gate,
|
|
@@ -2366,7 +2373,7 @@ var SandboxInstance = class SandboxInstance {
|
|
|
2366
2373
|
const fs = await import("node:fs/promises");
|
|
2367
2374
|
const path = await import("node:path");
|
|
2368
2375
|
await fs.mkdir(path.dirname(localPath), { recursive: true });
|
|
2369
|
-
const response = await this.runtimeFetch(
|
|
2376
|
+
const response = await this.runtimeFetch(runtimeFilesystemPath("/fs/download", remotePath), { method: "GET" });
|
|
2370
2377
|
if (!response.ok) {
|
|
2371
2378
|
const body = await response.text();
|
|
2372
2379
|
throw parseErrorResponse(response.status, body, void 0, response.headers);
|
|
@@ -2416,7 +2423,7 @@ var SandboxInstance = class SandboxInstance {
|
|
|
2416
2423
|
const fs = await import("node:fs/promises");
|
|
2417
2424
|
const path = await import("node:path");
|
|
2418
2425
|
const { execSync } = await import("node:child_process");
|
|
2419
|
-
const response = await this.runtimeFetch(
|
|
2426
|
+
const response = await this.runtimeFetch(runtimeFilesystemPath("/fs/download-dir", remoteDir), { method: "GET" });
|
|
2420
2427
|
if (!response.ok) {
|
|
2421
2428
|
const body = await response.text();
|
|
2422
2429
|
throw parseErrorResponse(response.status, body, void 0, response.headers);
|
|
@@ -2439,7 +2446,8 @@ var SandboxInstance = class SandboxInstance {
|
|
|
2439
2446
|
if (options?.long) params.set("long", "true");
|
|
2440
2447
|
if (options?.sessionId) params.set("sessionId", options.sessionId);
|
|
2441
2448
|
const query = params.toString();
|
|
2442
|
-
const
|
|
2449
|
+
const basePath = runtimeFilesystemPath("/fs/list", path);
|
|
2450
|
+
const url = query ? `${basePath}?${query}` : basePath;
|
|
2443
2451
|
const response = await this.runtimeFetch(url, { method: "GET" });
|
|
2444
2452
|
if (!response.ok) {
|
|
2445
2453
|
const body = await response.text();
|
|
@@ -2461,7 +2469,7 @@ var SandboxInstance = class SandboxInstance {
|
|
|
2461
2469
|
}
|
|
2462
2470
|
async fsStat(path) {
|
|
2463
2471
|
await this.ensureRunning();
|
|
2464
|
-
const response = await this.runtimeFetch(
|
|
2472
|
+
const response = await this.runtimeFetch(runtimeFilesystemPath("/fs/stat", path), { method: "GET" });
|
|
2465
2473
|
if (!response.ok) {
|
|
2466
2474
|
const body = await response.text();
|
|
2467
2475
|
throw parseErrorResponse(response.status, body, void 0, response.headers);
|
|
@@ -2499,7 +2507,8 @@ var SandboxInstance = class SandboxInstance {
|
|
|
2499
2507
|
if (options?.recursive) params.set("recursive", "true");
|
|
2500
2508
|
if (options?.sessionId) params.set("sessionId", options.sessionId);
|
|
2501
2509
|
const query = params.toString();
|
|
2502
|
-
const
|
|
2510
|
+
const basePath = runtimeFilesystemPath("/fs", path);
|
|
2511
|
+
const url = query ? `${basePath}?${query}` : basePath;
|
|
2503
2512
|
const response = await this.runtimeFetch(url, { method: "DELETE" });
|
|
2504
2513
|
if (!response.ok) {
|
|
2505
2514
|
const body = await response.text();
|
|
@@ -2511,7 +2520,8 @@ var SandboxInstance = class SandboxInstance {
|
|
|
2511
2520
|
const params = new URLSearchParams();
|
|
2512
2521
|
if (options?.recursive) params.set("recursive", "true");
|
|
2513
2522
|
const query = params.toString();
|
|
2514
|
-
const
|
|
2523
|
+
const basePath = runtimeFilesystemPath("/fs/mkdir", path);
|
|
2524
|
+
const url = query ? `${basePath}?${query}` : basePath;
|
|
2515
2525
|
const response = await this.runtimeFetch(url, { method: "POST" });
|
|
2516
2526
|
if (!response.ok) {
|
|
2517
2527
|
const body = await response.text();
|
|
@@ -2520,7 +2530,7 @@ var SandboxInstance = class SandboxInstance {
|
|
|
2520
2530
|
}
|
|
2521
2531
|
async fsExists(path) {
|
|
2522
2532
|
await this.ensureRunning();
|
|
2523
|
-
const response = await this.runtimeFetch(
|
|
2533
|
+
const response = await this.runtimeFetch(runtimeFilesystemPath("/fs/exists", path), { method: "GET" });
|
|
2524
2534
|
if (!response.ok) {
|
|
2525
2535
|
const body = await response.text();
|
|
2526
2536
|
throw parseErrorResponse(response.status, body, void 0, response.headers);
|
|
@@ -3721,7 +3731,89 @@ var SandboxInstance = class SandboxInstance {
|
|
|
3721
3731
|
return ((await response.json()).children ?? []).map((child) => new SandboxInstance(this.client, this.parseInfo(child), this.defaultRuntimeBackend));
|
|
3722
3732
|
}
|
|
3723
3733
|
/**
|
|
3734
|
+
* Speculative rollouts: branch this RUNNING sandbox into `n` copy-on-write
|
|
3735
|
+
* children, run the SAME agent turn in every child in parallel, and
|
|
3736
|
+
* optionally score each child by running `scorer.command` inside it (exit 0
|
|
3737
|
+
* passes; stdout is parsed as the numeric score — highest wins).
|
|
3738
|
+
*
|
|
3739
|
+
* Async-op shape: resolves as soon as the children exist (their turns are
|
|
3740
|
+
* still running); poll {@link getRollout} or use {@link waitForRollout} for
|
|
3741
|
+
* results. Children are first-class sandboxes the caller may promote or
|
|
3742
|
+
* delete — each occupies a concurrent-session quota slot like a create.
|
|
3743
|
+
*
|
|
3744
|
+
* @example
|
|
3745
|
+
* ```typescript
|
|
3746
|
+
* const started = await box.rollout({
|
|
3747
|
+
* n: 4,
|
|
3748
|
+
* parts: [{ type: "text", text: "make the failing test pass" }],
|
|
3749
|
+
* scorer: { type: "command", command: "npm test --silent && echo 1" },
|
|
3750
|
+
* });
|
|
3751
|
+
* const settled = await box.waitForRollout(started.rolloutId);
|
|
3752
|
+
* console.log(settled.winner, settled.results);
|
|
3753
|
+
* ```
|
|
3754
|
+
*/
|
|
3755
|
+
async rollout(options) {
|
|
3756
|
+
if (!Number.isInteger(options.n) || options.n < 1 || options.n > 8) throw new ValidationError(`rollout n must be an integer in [1, 8] (got ${options.n})`);
|
|
3757
|
+
if (!Array.isArray(options.parts) || options.parts.length === 0) throw new ValidationError("rollout parts must be a non-empty array");
|
|
3758
|
+
if (options.scorer?.type === "command" && !options.scorer.command) throw new ValidationError("scorer.command is required when scorer.type is \"command\"");
|
|
3759
|
+
const response = await this.client.fetch(`/v1/sandboxes/${this.id}/rollouts`, {
|
|
3760
|
+
method: "POST",
|
|
3761
|
+
body: JSON.stringify({
|
|
3762
|
+
n: options.n,
|
|
3763
|
+
parts: options.parts,
|
|
3764
|
+
...options.scorer ? { scorer: options.scorer } : {}
|
|
3765
|
+
})
|
|
3766
|
+
});
|
|
3767
|
+
if (!response.ok) {
|
|
3768
|
+
const body = await response.text();
|
|
3769
|
+
throw parseErrorResponse(response.status, body, void 0, response.headers);
|
|
3770
|
+
}
|
|
3771
|
+
const data = await response.json();
|
|
3772
|
+
if (typeof data.rolloutId !== "string" || data.rolloutId.length === 0) throw new ServerError(`Rollout create returned ${response.status} but body had no rolloutId: ${JSON.stringify(data).slice(0, 200)}`, response.status);
|
|
3773
|
+
return data;
|
|
3774
|
+
}
|
|
3775
|
+
/**
|
|
3776
|
+
* Poll a rollout's status and per-child results.
|
|
3777
|
+
*
|
|
3778
|
+
* Failed or timed-out children appear as result entries with `error` set —
|
|
3779
|
+
* partial results are never dropped. Rollout poll-state lives in
|
|
3780
|
+
* orchestrator RAM: after an orchestrator restart this returns 404 while
|
|
3781
|
+
* the children themselves survive as first-class sandboxes.
|
|
3782
|
+
*/
|
|
3783
|
+
async getRollout(rolloutId) {
|
|
3784
|
+
if (!rolloutId) throw new ValidationError("rolloutId is required");
|
|
3785
|
+
const response = await this.client.fetch(`/v1/sandboxes/${this.id}/rollouts/${encodeURIComponent(rolloutId)}`, { method: "GET" });
|
|
3786
|
+
if (!response.ok) {
|
|
3787
|
+
const body = await response.text();
|
|
3788
|
+
throw parseErrorResponse(response.status, body, void 0, response.headers);
|
|
3789
|
+
}
|
|
3790
|
+
return await response.json();
|
|
3791
|
+
}
|
|
3792
|
+
/**
|
|
3793
|
+
* Poll {@link getRollout} until the rollout leaves `running`, then return
|
|
3794
|
+
* the terminal record — including `partial`/`failed` outcomes, whose
|
|
3795
|
+
* per-child `error` entries are results the caller inspects, not
|
|
3796
|
+
* exceptions. Throws {@link TimeoutError} on deadline or abort.
|
|
3797
|
+
*/
|
|
3798
|
+
async waitForRollout(rolloutId, options) {
|
|
3799
|
+
const timeoutMs = options?.timeoutMs ?? 36e4;
|
|
3800
|
+
const pollIntervalMs = options?.pollIntervalMs ?? 2e3;
|
|
3801
|
+
const startTime = Date.now();
|
|
3802
|
+
while (true) {
|
|
3803
|
+
if (options?.signal?.aborted) throw new TimeoutError(0, "Aborted");
|
|
3804
|
+
const record = await this.getRollout(rolloutId);
|
|
3805
|
+
if (record.status !== "running") return record;
|
|
3806
|
+
if (Date.now() - startTime > timeoutMs) throw new TimeoutError(timeoutMs, `Timed out waiting for rollout ${rolloutId} to settle`);
|
|
3807
|
+
await this.sleep(pollIntervalMs);
|
|
3808
|
+
}
|
|
3809
|
+
}
|
|
3810
|
+
/**
|
|
3724
3811
|
* Stop the sandbox (keeps state for resume).
|
|
3812
|
+
*
|
|
3813
|
+
* The stop response carries the orchestrator's per-phase stop breakdown
|
|
3814
|
+
* (`stop_metering` / `container_kill` / `stop_complete` /
|
|
3815
|
+
* `stop_unaccounted`); after this resolves, {@link startupDiagnostics}
|
|
3816
|
+
* returns it (replacing the create breakdown).
|
|
3725
3817
|
*/
|
|
3726
3818
|
async stop() {
|
|
3727
3819
|
const response = await this.client.fetch(`/v1/sandboxes/${this.id}/stop`, { method: "POST" });
|
|
@@ -3729,7 +3821,9 @@ var SandboxInstance = class SandboxInstance {
|
|
|
3729
3821
|
const body = await response.text();
|
|
3730
3822
|
throw parseErrorResponse(response.status, body, void 0, response.headers);
|
|
3731
3823
|
}
|
|
3824
|
+
const diagnostics = await this.readLifecycleDiagnostics(response);
|
|
3732
3825
|
await this.refresh();
|
|
3826
|
+
if (diagnostics) this.info.startupDiagnostics = diagnostics;
|
|
3733
3827
|
}
|
|
3734
3828
|
/**
|
|
3735
3829
|
* Resume a stopped sandbox.
|
|
@@ -3746,10 +3840,18 @@ var SandboxInstance = class SandboxInstance {
|
|
|
3746
3840
|
const body = await response.text();
|
|
3747
3841
|
throw parseErrorResponse(response.status, body, void 0, response.headers);
|
|
3748
3842
|
}
|
|
3843
|
+
const diagnostics = await this.readLifecycleDiagnostics(response);
|
|
3749
3844
|
await this.refresh();
|
|
3845
|
+
if (diagnostics) this.info.startupDiagnostics = diagnostics;
|
|
3750
3846
|
}
|
|
3751
3847
|
/**
|
|
3752
3848
|
* Delete the sandbox permanently.
|
|
3849
|
+
*
|
|
3850
|
+
* The delete response carries the orchestrator's per-phase delete breakdown
|
|
3851
|
+
* (`container_remove` / `storage_binding_wait` / `cleanup_parallel` /
|
|
3852
|
+
* `delete_complete` / `delete_unaccounted`); after this resolves,
|
|
3853
|
+
* {@link startupDiagnostics} returns it for post-mortem reads on the
|
|
3854
|
+
* now-gone sandbox.
|
|
3753
3855
|
*/
|
|
3754
3856
|
async delete() {
|
|
3755
3857
|
const response = await this.client.fetch(`/v1/sandboxes/${this.id}`, { method: "DELETE" });
|
|
@@ -3757,6 +3859,17 @@ var SandboxInstance = class SandboxInstance {
|
|
|
3757
3859
|
const body = await response.text();
|
|
3758
3860
|
throw parseErrorResponse(response.status, body, void 0, response.headers);
|
|
3759
3861
|
}
|
|
3862
|
+
const diagnostics = await this.readLifecycleDiagnostics(response);
|
|
3863
|
+
if (diagnostics) this.info.startupDiagnostics = diagnostics;
|
|
3864
|
+
}
|
|
3865
|
+
/**
|
|
3866
|
+
* Read the per-phase lifecycle breakdown off a stop/resume/delete response
|
|
3867
|
+
* body. Never throws: diagnostics are measurement data — a body that fails
|
|
3868
|
+
* to parse (older API, empty body) must not fail the lifecycle call.
|
|
3869
|
+
*/
|
|
3870
|
+
async readLifecycleDiagnostics(response) {
|
|
3871
|
+
const data = await response.json().catch(() => null);
|
|
3872
|
+
return data ? normalizeStartupDiagnostics(data.startupDiagnostics) : null;
|
|
3760
3873
|
}
|
|
3761
3874
|
/**
|
|
3762
3875
|
* keepAlive is intentionally unavailable until the API exposes timeout updates.
|
|
@@ -4382,7 +4495,7 @@ var SandboxInstance = class SandboxInstance {
|
|
|
4382
4495
|
const search = new URLSearchParams();
|
|
4383
4496
|
search.set("sessionId", id);
|
|
4384
4497
|
if (opts?.since) search.set("since", opts.since);
|
|
4385
|
-
const response = await this.runtimeFetch(`/agents/events
|
|
4498
|
+
const response = await this.runtimeFetch(`/agents/events?${search.toString()}`, { signal: opts?.signal });
|
|
4386
4499
|
if (!response.ok) {
|
|
4387
4500
|
const body = await response.text();
|
|
4388
4501
|
throw parseErrorResponse(response.status, body, void 0, response.headers);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $ as EventStreamOptions, A as CommitTaskSessionOptions, B as CreateTaskSessionOptions, Bt as IntelligenceReport, Ci as
|
|
1
|
+
import { $ as EventStreamOptions, A as CommitTaskSessionOptions, Ai as WriteFileOptions, An as Rollout, B as CreateTaskSessionOptions, Br as SearchMatch, Bt as IntelligenceReport, Ci as TurnDriveResult, Cr as SandboxResourceUsage, Ct as GitBranch, D as CodeLanguage, Dr as SandboxRuntimeProfileList, Dt as GitStatus, E as CodeExecutionResult, Et as GitDiff, Gr as SendSessionMessageRequest, Gt as JsonValue, Ht as IntelligenceReportCompareTo, Ir as SandboxTraceOptions, Jr as SessionEventStreamOptions, Kr as SentSessionMessage, Kt as ListMessagesOptions, Mi as WriteManyOptions, Mn as RolloutOptions, Nr as SandboxTraceBundle, Nt as GpuLeaseManager, Oi as WaitForOptions, On as RestoreSnapshotOptions, Or as SandboxStatus, Ot as GpuLease, Pn as RolloutStartResult, Qr as SessionMessage, Rn as SSHCommandDescriptor, Rr as ScopedToken, T as CodeExecutionOptions, Tr as SandboxRuntimeHealth, U as DispatchPromptOptions, Un as SandboxEvent, Vn as SandboxConnection, Vr as SearchOptions, Vt as IntelligenceReportBudget, W as DispatchedSession, Wr as SendSessionMessageOptions, Wt as IntelligenceReportWindow, Xr as SessionInfo, Y as DriverInfo, Yr as SessionForkOptions, Z as EgressManager, Zr as SessionListOptions, Zt as MintScopedTokenOptions, _n as ProvisionResult, _r as SandboxInfo, ai as StartupDiagnostics, an as PreviewLinkManager, bi as TeePublicKeyResponse, br as SandboxPortBinding, cr as SandboxFleetTraceBundle, di as TaskSessionChanges, dt as FileWriteResult, en as NetworkManager, et as ExecOptions, fi as TaskSessionCommitResult, gi as TeeAttestationOptions, gn as ProvisionEvent, hn as PromptResult, j as CompletedTurnResult, ji as WriteManyFile, jr as SandboxTerminalManager, ki as WaitForRolloutOptions, kn as ResumeOptions, l as BackendManager, li as TaskOptions, ln as ProcessManager, mi as TaskSessionInfo, mn as PromptOptions, ni as SnapshotOptions, pn as PromptInputPart, q as DriveTurnOptions, ri as SnapshotResult, rn as PermissionsManager, s as BackendConfig, st as FileSystem, ti as SnapshotInfo, tt as ExecResult, ui as TaskResult, vi as TeeAttestationResponse, w as BranchOptions, wt as GitCommit, z as CreateSessionOptions, zn as SSHCredentials, zt as InstalledTool } from "./types-BvSoEHz8.js";
|
|
2
2
|
|
|
3
3
|
//#region src/mcp.d.ts
|
|
4
4
|
/**
|
|
@@ -1236,8 +1236,52 @@ declare class SandboxInstance {
|
|
|
1236
1236
|
* ```
|
|
1237
1237
|
*/
|
|
1238
1238
|
branch(count: number, options?: BranchOptions): Promise<SandboxInstance[]>;
|
|
1239
|
+
/**
|
|
1240
|
+
* Speculative rollouts: branch this RUNNING sandbox into `n` copy-on-write
|
|
1241
|
+
* children, run the SAME agent turn in every child in parallel, and
|
|
1242
|
+
* optionally score each child by running `scorer.command` inside it (exit 0
|
|
1243
|
+
* passes; stdout is parsed as the numeric score — highest wins).
|
|
1244
|
+
*
|
|
1245
|
+
* Async-op shape: resolves as soon as the children exist (their turns are
|
|
1246
|
+
* still running); poll {@link getRollout} or use {@link waitForRollout} for
|
|
1247
|
+
* results. Children are first-class sandboxes the caller may promote or
|
|
1248
|
+
* delete — each occupies a concurrent-session quota slot like a create.
|
|
1249
|
+
*
|
|
1250
|
+
* @example
|
|
1251
|
+
* ```typescript
|
|
1252
|
+
* const started = await box.rollout({
|
|
1253
|
+
* n: 4,
|
|
1254
|
+
* parts: [{ type: "text", text: "make the failing test pass" }],
|
|
1255
|
+
* scorer: { type: "command", command: "npm test --silent && echo 1" },
|
|
1256
|
+
* });
|
|
1257
|
+
* const settled = await box.waitForRollout(started.rolloutId);
|
|
1258
|
+
* console.log(settled.winner, settled.results);
|
|
1259
|
+
* ```
|
|
1260
|
+
*/
|
|
1261
|
+
rollout(options: RolloutOptions): Promise<RolloutStartResult>;
|
|
1262
|
+
/**
|
|
1263
|
+
* Poll a rollout's status and per-child results.
|
|
1264
|
+
*
|
|
1265
|
+
* Failed or timed-out children appear as result entries with `error` set —
|
|
1266
|
+
* partial results are never dropped. Rollout poll-state lives in
|
|
1267
|
+
* orchestrator RAM: after an orchestrator restart this returns 404 while
|
|
1268
|
+
* the children themselves survive as first-class sandboxes.
|
|
1269
|
+
*/
|
|
1270
|
+
getRollout(rolloutId: string): Promise<Rollout>;
|
|
1271
|
+
/**
|
|
1272
|
+
* Poll {@link getRollout} until the rollout leaves `running`, then return
|
|
1273
|
+
* the terminal record — including `partial`/`failed` outcomes, whose
|
|
1274
|
+
* per-child `error` entries are results the caller inspects, not
|
|
1275
|
+
* exceptions. Throws {@link TimeoutError} on deadline or abort.
|
|
1276
|
+
*/
|
|
1277
|
+
waitForRollout(rolloutId: string, options?: WaitForRolloutOptions): Promise<Rollout>;
|
|
1239
1278
|
/**
|
|
1240
1279
|
* Stop the sandbox (keeps state for resume).
|
|
1280
|
+
*
|
|
1281
|
+
* The stop response carries the orchestrator's per-phase stop breakdown
|
|
1282
|
+
* (`stop_metering` / `container_kill` / `stop_complete` /
|
|
1283
|
+
* `stop_unaccounted`); after this resolves, {@link startupDiagnostics}
|
|
1284
|
+
* returns it (replacing the create breakdown).
|
|
1241
1285
|
*/
|
|
1242
1286
|
stop(): Promise<void>;
|
|
1243
1287
|
/**
|
|
@@ -1246,8 +1290,20 @@ declare class SandboxInstance {
|
|
|
1246
1290
|
resume(options?: ResumeOptions): Promise<void>;
|
|
1247
1291
|
/**
|
|
1248
1292
|
* Delete the sandbox permanently.
|
|
1293
|
+
*
|
|
1294
|
+
* The delete response carries the orchestrator's per-phase delete breakdown
|
|
1295
|
+
* (`container_remove` / `storage_binding_wait` / `cleanup_parallel` /
|
|
1296
|
+
* `delete_complete` / `delete_unaccounted`); after this resolves,
|
|
1297
|
+
* {@link startupDiagnostics} returns it for post-mortem reads on the
|
|
1298
|
+
* now-gone sandbox.
|
|
1249
1299
|
*/
|
|
1250
1300
|
delete(): Promise<void>;
|
|
1301
|
+
/**
|
|
1302
|
+
* Read the per-phase lifecycle breakdown off a stop/resume/delete response
|
|
1303
|
+
* body. Never throws: diagnostics are measurement data — a body that fails
|
|
1304
|
+
* to parse (older API, empty body) must not fail the lifecycle call.
|
|
1305
|
+
*/
|
|
1306
|
+
private readLifecycleDiagnostics;
|
|
1251
1307
|
/**
|
|
1252
1308
|
* keepAlive is intentionally unavailable until the API exposes timeout updates.
|
|
1253
1309
|
* @param seconds - Reserved for future support
|
package/dist/tangle/index.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as TANGLE_JOBS_CONTRACT, c as AgentSandboxBlueprintAbi, d as SandboxCreateParamTypes, f as SandboxCreateResponseParamTypes, i as TANGLE_CHAIN_ID, l as ITangleJobsAbi, n as JOB_SANDBOX_CREATE, o as TANGLE_MAINNET_RPC, p as SandboxIdParamTypes, r as JOB_SANDBOX_DELETE, s as TangleSandboxClientConfig, t as TangleSandboxClient, u as JsonResponseParamTypes } from "../index-
|
|
1
|
+
import { a as TANGLE_JOBS_CONTRACT, c as AgentSandboxBlueprintAbi, d as SandboxCreateParamTypes, f as SandboxCreateResponseParamTypes, i as TANGLE_CHAIN_ID, l as ITangleJobsAbi, n as JOB_SANDBOX_CREATE, o as TANGLE_MAINNET_RPC, p as SandboxIdParamTypes, r as JOB_SANDBOX_DELETE, s as TangleSandboxClientConfig, t as TangleSandboxClient, u as JsonResponseParamTypes } from "../index-BFnMEze6.js";
|
|
2
2
|
export { AgentSandboxBlueprintAbi, ITangleJobsAbi, JOB_SANDBOX_CREATE, JOB_SANDBOX_DELETE, JsonResponseParamTypes, SandboxCreateParamTypes, SandboxCreateResponseParamTypes, SandboxIdParamTypes, TANGLE_CHAIN_ID, TANGLE_JOBS_CONTRACT, TANGLE_MAINNET_RPC, TangleSandboxClient, TangleSandboxClientConfig };
|
package/dist/tangle/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as TANGLE_JOBS_CONTRACT, c as ITangleJobsAbi, d as SandboxCreateResponseParamTypes, f as SandboxIdParamTypes, i as TANGLE_CHAIN_ID, l as JsonResponseParamTypes, n as JOB_SANDBOX_CREATE, o as TANGLE_MAINNET_RPC, r as JOB_SANDBOX_DELETE, s as AgentSandboxBlueprintAbi, t as TangleSandboxClient, u as SandboxCreateParamTypes } from "../tangle-
|
|
1
|
+
import { a as TANGLE_JOBS_CONTRACT, c as ITangleJobsAbi, d as SandboxCreateResponseParamTypes, f as SandboxIdParamTypes, i as TANGLE_CHAIN_ID, l as JsonResponseParamTypes, n as JOB_SANDBOX_CREATE, o as TANGLE_MAINNET_RPC, r as JOB_SANDBOX_DELETE, s as AgentSandboxBlueprintAbi, t as TangleSandboxClient, u as SandboxCreateParamTypes } from "../tangle-D6UfK_B0.js";
|
|
2
2
|
export { AgentSandboxBlueprintAbi, ITangleJobsAbi, JOB_SANDBOX_CREATE, JOB_SANDBOX_DELETE, JsonResponseParamTypes, SandboxCreateParamTypes, SandboxCreateResponseParamTypes, SandboxIdParamTypes, TANGLE_CHAIN_ID, TANGLE_JOBS_CONTRACT, TANGLE_MAINNET_RPC, TangleSandboxClient };
|
|
@@ -2915,6 +2915,100 @@ interface BranchOptions {
|
|
|
2915
2915
|
*/
|
|
2916
2916
|
metadata?: Record<string, unknown>;
|
|
2917
2917
|
}
|
|
2918
|
+
/**
|
|
2919
|
+
* One message part of the agent turn sent to every rollout child.
|
|
2920
|
+
* `type` selects the part kind (e.g. `"text"`); the remaining fields are
|
|
2921
|
+
* validated structurally by the child's agent runtime.
|
|
2922
|
+
*/
|
|
2923
|
+
type RolloutTurnPart = {
|
|
2924
|
+
type: string;
|
|
2925
|
+
} & Record<string, unknown>;
|
|
2926
|
+
/**
|
|
2927
|
+
* How each rollout child is scored after its turn completes.
|
|
2928
|
+
*
|
|
2929
|
+
* `command` runs inside the child's sandbox: exit 0 passes and stdout is
|
|
2930
|
+
* parsed as the numeric score (highest score wins). A non-zero exit records
|
|
2931
|
+
* the exit code with no score; exit 0 with non-numeric stdout is reported as
|
|
2932
|
+
* a per-child error rather than silently ranking score-less.
|
|
2933
|
+
*/
|
|
2934
|
+
type RolloutScorer = {
|
|
2935
|
+
type: "none";
|
|
2936
|
+
} | {
|
|
2937
|
+
type: "command";
|
|
2938
|
+
command: string;
|
|
2939
|
+
};
|
|
2940
|
+
/**
|
|
2941
|
+
* Options for {@link SandboxInstance.rollout} — speculative rollouts.
|
|
2942
|
+
*/
|
|
2943
|
+
interface RolloutOptions {
|
|
2944
|
+
/** Number of copy-on-write children to branch (1–8). */
|
|
2945
|
+
n: number;
|
|
2946
|
+
/** The agent-turn message parts sent identically to every child. */
|
|
2947
|
+
parts: RolloutTurnPart[];
|
|
2948
|
+
/** Optional per-child scorer. Defaults to no scoring. */
|
|
2949
|
+
scorer?: RolloutScorer;
|
|
2950
|
+
}
|
|
2951
|
+
/**
|
|
2952
|
+
* Rollout lifecycle. `partial` means some children produced results while
|
|
2953
|
+
* others failed or timed out — failed children appear as error entries,
|
|
2954
|
+
* never dropped.
|
|
2955
|
+
*/
|
|
2956
|
+
type RolloutStatus = "running" | "completed" | "partial" | "failed";
|
|
2957
|
+
/** One child's outcome inside a rollout. */
|
|
2958
|
+
interface RolloutChildResult {
|
|
2959
|
+
/** The child sandbox id — a first-class sandbox the caller may keep. */
|
|
2960
|
+
sandboxId: string;
|
|
2961
|
+
/** Final assistant text of the turn. Absent when the turn failed. */
|
|
2962
|
+
output?: string;
|
|
2963
|
+
/** Why this child produced no usable result (turn failure or timeout). */
|
|
2964
|
+
error?: string;
|
|
2965
|
+
/** Scorer command exit code. Present only when the scorer ran. */
|
|
2966
|
+
exitCode?: number;
|
|
2967
|
+
/** Parsed scorer stdout. Present only when the scorer exited 0 with a number. */
|
|
2968
|
+
score?: number;
|
|
2969
|
+
/** Wall-clock duration of this child's turn (and scorer) in ms. */
|
|
2970
|
+
durationMs: number;
|
|
2971
|
+
}
|
|
2972
|
+
/**
|
|
2973
|
+
* Immediate response of `POST /v1/sandboxes/{id}/rollouts`: the children
|
|
2974
|
+
* exist and their turns are running. Poll {@link SandboxInstance.getRollout}
|
|
2975
|
+
* (or use {@link SandboxInstance.waitForRollout}) for results.
|
|
2976
|
+
*/
|
|
2977
|
+
interface RolloutStartResult {
|
|
2978
|
+
rolloutId: string;
|
|
2979
|
+
status: RolloutStatus;
|
|
2980
|
+
/** Child sandbox ids, in branch order. */
|
|
2981
|
+
children: string[];
|
|
2982
|
+
/** Time the copy-on-write branch of all children took, in ms. */
|
|
2983
|
+
materializeTimeMs?: number;
|
|
2984
|
+
/** Per-child wall-clock turn deadline the server applied, in ms. */
|
|
2985
|
+
turnTimeoutMs?: number;
|
|
2986
|
+
}
|
|
2987
|
+
/** Full poll-state of a rollout. */
|
|
2988
|
+
interface Rollout extends RolloutStartResult {
|
|
2989
|
+
/** One entry per child once the rollout settles; empty while running. */
|
|
2990
|
+
results: RolloutChildResult[];
|
|
2991
|
+
/** Child sandboxId with the highest numeric score (command scorer only). */
|
|
2992
|
+
winner?: string;
|
|
2993
|
+
/** Rollout-level failure, distinct from per-child errors. */
|
|
2994
|
+
error?: string;
|
|
2995
|
+
createdAt?: string;
|
|
2996
|
+
updatedAt?: string;
|
|
2997
|
+
}
|
|
2998
|
+
/**
|
|
2999
|
+
* Options for {@link SandboxInstance.waitForRollout}.
|
|
3000
|
+
*/
|
|
3001
|
+
interface WaitForRolloutOptions {
|
|
3002
|
+
/**
|
|
3003
|
+
* Timeout in milliseconds (default: 360000). Should exceed the server's
|
|
3004
|
+
* per-child turn deadline (`ROLLOUT_TURN_TIMEOUT_MS`, default 300000).
|
|
3005
|
+
*/
|
|
3006
|
+
timeoutMs?: number;
|
|
3007
|
+
/** Poll interval in milliseconds (default: 2000). */
|
|
3008
|
+
pollIntervalMs?: number;
|
|
3009
|
+
/** AbortSignal for cancellation. */
|
|
3010
|
+
signal?: AbortSignal;
|
|
3011
|
+
}
|
|
2918
3012
|
/**
|
|
2919
3013
|
* Infrastructure driver identifier.
|
|
2920
3014
|
*
|
|
@@ -4749,4 +4843,4 @@ interface CodeExecutionOptions {
|
|
|
4749
4843
|
idempotencyKey?: string;
|
|
4750
4844
|
}
|
|
4751
4845
|
//#endregion
|
|
4752
|
-
export { EventStreamOptions as $,
|
|
4846
|
+
export { EventStreamOptions as $, SandboxFleetMachine as $n, SessionMessageInputPart as $r, NetworkConfig as $t, CommitTaskSessionOptions as A, WriteFileOptions as Ai, Rollout as An, SandboxTerminalInfo as Ar, GpuLeaseCommandResult as At, CreateTaskSessionOptions as B, AgentProfilePermissionValue as Bi, SandboxClientConfig as Bn, SearchMatch as Br, IntelligenceReport as Bt, BatchTaskUsage as C, TurnDriveResult as Ci, PublishPublicTemplateVersionOptions as Cn, SandboxResourceUsage as Cr, GitBranch as Ct, CodeLanguage as D, UsageInfo as Di, ReconcileSandboxFleetsResult as Dn, SandboxRuntimeProfileList as Dr, GitStatus as Dt, CodeExecutionResult as E, UploadProgress as Ei, ReconcileSandboxFleetsOptions as En, SandboxRuntimeProfile as Er, GitDiff as Et, CreateSandboxFleetOptions as F, AgentProfileConfidential as Fi, RolloutStatus as Fn, SandboxTraceExport as Fr, GpuLeaseStatus as Ft, DownloadOptions as G, AgentProfileValidationResult as Gi, SandboxFleetArtifactSpec as Gn, SendSessionMessageRequest as Gr, JsonValue as Gt, DirectoryPermission as H, AgentProfileResourceRef as Hi, SandboxEnvironment as Hn, SecretInfo as Hr, IntelligenceReportCompareTo as Ht, CreateSandboxFleetTokenOptions as I, AgentProfileConnection as Ii, RolloutTurnPart as In, SandboxTraceOptions as Ir, GpuType as It, DriverConfig as J, defineGitHubResource as Ji, SandboxFleetDispatchResponse as Jn, SessionEventStreamOptions as Jr, ListSandboxFleetOptions as Jt, DownloadProgress as K, AgentSubagentProfile as Ki, SandboxFleetCostEstimate as Kn, SentSessionMessage as Kr, ListMessagesOptions as Kt, CreateSandboxFleetWithCoordinatorOptions as L, AgentProfileFileMount as Li, RunCodeOptions as Ln, SandboxUser as Lr, HostAgentDriverConfig as Lt, CreateGpuLeaseOptions as M, WriteManyOptions as Mi, RolloutOptions as Mn, SandboxTerminalRequestOptions as Mr, GpuLeaseExecResult as Mt, CreateIntelligenceReportOptions as N, AgentProfile as Ni, RolloutScorer as Nn, SandboxTraceBundle as Nr, GpuLeaseManager as Nt, CodeResult as O, WaitForOptions as Oi, RestoreSnapshotOptions as On, SandboxStatus as Or, GpuLease as Ot, CreateRequestOptions as P, AgentProfileCapabilities as Pi, RolloutStartResult as Pn, SandboxTraceEvent as Pr, GpuLeaseProviderName as Pt, EgressPolicy as Q, SandboxFleetIntelligenceEnvelope as Qn, SessionMessage as Qr, MkdirOptions as Qt, CreateSandboxOptions as R, AgentProfileMcpServer as Ri, SSHCommandDescriptor as Rn, ScopedToken as Rr, HostAgentRuntimeBackend as Rt, BatchTaskResult as S, ToolsConfig as Si, PublishPublicTemplateOptions as Sn, SandboxProfileSummary as Sr, GitAuth as St, CodeExecutionOptions as T, UploadOptions as Ti, ReapExpiredSandboxFleetsResult as Tn, SandboxRuntimeHealth as Tr, GitConfig as Tt, DispatchPromptOptions as U, AgentProfileResources as Ui, SandboxEvent as Un, SecretsManager as Ur, IntelligenceReportSubjectType as Ut, DeleteOptions as V, AgentProfilePrompt as Vi, SandboxConnection as Vn, SearchOptions as Vr, IntelligenceReportBudget as Vt, DispatchedSession as W, AgentProfileValidationIssue as Wi, SandboxFleetArtifact as Wn, SendSessionMessageOptions as Wr, IntelligenceReportWindow as Wt, DriverType as X, mergeAgentProfiles as Xi, SandboxFleetDriverTimings as Xn, SessionInfo as Xr, McpServerConfig as Xt, DriverInfo as Y, defineInlineResource as Yi, SandboxFleetDriverCapability as Yn, SessionForkOptions as Yr, ListSandboxOptions as Yt, EgressManager as Z, SandboxFleetInfo as Zn, SessionListOptions as Zr, MintScopedTokenOptions as Zt, BatchResult as _, TeeAttestationReport as _i, ProvisionResult as _n, SandboxInfo as _r, FleetExecDispatchResult as _t, AttachSandboxFleetMachineOptions as a, StartupDiagnostics as ai, PreviewLinkManager as an, SandboxFleetOperationsSummary as ar, FileReadError as at, BatchSidecarGroup as b, TeePublicKeyResponse as bi, PublicTemplateInfo as bn, SandboxPortBinding as br, FleetPromptDispatchResult as bt, BackendInfo as c, SubscriptionInfo as ci, ProcessLogEntry as cn, SandboxFleetTraceBundle as cr, FileTreeFile as ct, BackendType as d, TaskSessionChanges as di, ProcessSpawnOptions as dn, SandboxFleetTraceOptions as dr, FileWriteResult as dt, SessionStatus as ei, NetworkManager as en, SandboxFleetMachineMeteredUsage as er, ExecOptions as et, BatchBackend as f, TaskSessionCommitResult as fi, ProcessStatus as fn, SandboxFleetUsage as fr, FleetDispatchCancelResult as ft, BatchOptions as g, TeeAttestationOptions as gi, ProvisionEvent as gn, SandboxFleetWorkspaceSnapshotResult as gr, FleetExecDispatchOptions as gt, BatchEventDataMap as h, TaskSessionProfile as hi, PromptResult as hn, SandboxFleetWorkspaceRestoreResult as hr, FleetDispatchStreamOptions as ht, AttachGpuLeaseOptions as i, SshKeysManager as ii, PreviewLinkInfo as in, SandboxFleetManifestMachine as ir, FileReadBatchResult as it, CompletedTurnResult as j, WriteManyFile as ji, RolloutChildResult as jn, SandboxTerminalManager as jr, GpuLeaseExecOptions as jt, CodeResultPart as k, WaitForRolloutOptions as ki, ResumeOptions as kn, SandboxTerminalCreateOptions as kr, GpuLeaseBilling as kt, BackendManager as l, TaskOptions as li, ProcessManager as ln, SandboxFleetTraceEvent as lr, FileTreeOptions as lt, BatchEvent as m, TaskSessionInfo as mi, PromptOptions as mn, SandboxFleetWorkspaceReconcileResult as mr, FleetDispatchResultBufferOptions as mt, AccessPolicyRule as n, SnapshotOptions as ni, PermissionLevel as nn, SandboxFleetMachineSpec as nr, FileInfo as nt, BackendCapabilities as o, StartupOperation as oi, Process as on, SandboxFleetPolicy as or, FileReadResult as ot, BatchBackendStats as p, TaskSessionFileChange as pi, PromptInputPart as pn, SandboxFleetWorkspace as pr, FleetDispatchResultBuffer as pt, DriveTurnOptions as q, defineAgentProfile as qi, SandboxFleetDispatchFailureClass as qn, SessionBackendCredentials as qr, ListOptions as qt, AddUserOptions as r, SnapshotResult as ri, PermissionsManager as rn, SandboxFleetManifest as rr, FileReadBatchOptions as rt, BackendConfig as s, StorageConfig as si, ProcessInfo as sn, SandboxFleetToken as sr, FileSystem as st, AcceleratorKind as t, SnapshotInfo as ti, NonHostAgentDriverConfig as tn, SandboxFleetMachineRecord as tr, ExecResult as tt, BackendStatus as u, TaskResult as ui, ProcessSignal as un, SandboxFleetTraceExport as ur, FileTreeResult as ut, BatchRunOptions as v, TeeAttestationResponse as vi, ProvisionStatus as vn, SandboxIntelligenceEnvelope as vr, FleetMachineId as vt, BranchOptions as w, UpdateUserOptions as wi, ReapExpiredSandboxFleetsOptions as wn, SandboxResources as wr, GitCommit as wt, BatchTask as x, TokenRefreshHandler as xi, PublicTemplateVersionInfo as xn, SandboxPortPreviewLink as xr, GPU_LEASE_PROVIDER_NAMES as xt, BatchRunRequest as y, TeePublicKey as yi, ProvisionStep as yn, SandboxPermissionsConfig as yr, FleetPromptDispatchOptions as yt, CreateSessionOptions as z, AgentProfileModelHints as zi, SSHCredentials as zn, ScopedTokenScope as zr, InstalledTool as zt };
|
package/package.json
CHANGED