@tangle-network/sandbox 0.11.1 → 0.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +94 -16
- package/dist/agent/index.d.ts +3 -3
- package/dist/{client-D_67csnK.js → client-BCNrDjvA.js} +82 -18
- package/dist/{client-DBioX_CL.d.ts → client-iZbD-9Ks.d.ts} +2 -2
- package/dist/collaboration/index.js +1 -1
- package/dist/{collaboration-DDnuTcZd.js → collaboration-DdD_rFZQ.js} +1 -1
- package/dist/core.d.ts +5 -5
- package/dist/core.js +4 -4
- package/dist/{errors-ntvaf0_F.d.ts → errors-C8HMx78o.d.ts} +2 -2
- package/dist/{errors-Cbs78OlF.js → errors-D9fFOWX9.js} +12 -8
- package/dist/{index-Dj8LzvId.d.ts → index-Bhx4EQca.d.ts} +2 -2
- package/dist/index.d.ts +24 -6
- package/dist/index.js +8 -8
- package/dist/intelligence/index.js +1 -1
- package/dist/{runtime-api-kukaWPtF.js → runtime-api-XhAv6YiH.js} +12 -5
- package/dist/runtime.d.ts +3 -2
- package/dist/runtime.js +2 -2
- package/dist/{sandbox-DaLPTCRA.js → sandbox-CWeFm9Hj.js} +978 -57
- package/dist/{sandbox-BRoxCvpS.d.ts → sandbox-hbYwu_Ot.d.ts} +268 -32
- package/dist/session-gateway/index.d.ts +77 -20
- package/dist/session-gateway/index.js +332 -156
- package/dist/tangle/index.d.ts +1 -1
- package/dist/tangle/index.js +1 -1
- package/dist/{tangle-DHOkbr5a.js → tangle-C8CaT3tE.js} +70 -22
- package/dist/{types-D2C72ySk.d.ts → types-C67osezQ.d.ts} +584 -178
- package/package.json +9 -6
package/dist/index.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { $i as
|
|
2
|
-
import { C as
|
|
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, $i as TerminalStreamOptions, $n as SandboxFleetDispatchFailureClass, $r as SendSessionMessageRequest, $t as ListSandboxOptions, A as CreateIntelligenceReportOptions, Ai as ToolsConfig, An as ReapExpiredSandboxFleetsResult, Ar as SandboxResources, At as GitDiff, B as DirectoryPermission, Bi as WriteManyOptions, Bn as RolloutStartResult, Br as SandboxTerminals, Bt as GpuType, Ca as validateAgentProfileSecurity, Ci as TaskSessionProfile, Cn as ProvisionStatus, Cr as SandboxInfo, Ct as FleetPromptDispatchOptions, D as CommitTaskSessionOptions, Di as TeePublicKey, Dn as PublishPublicTemplateOptions, Dr as SandboxPortPreviewLink, Dt as GitBranch, Ei as TeeAttestationResponse, En as PublicTemplateVersionInfo, Er as SandboxPortBinding, Et as GitAuth, F as CreateSandboxOptions, Fi as UsageInfo, Fr as SandboxTerminalAttachOptions, Ft as GpuLeaseExecOptions, G as DriveTurnOptions, Gi as BatchTaskUsage, Gn as SSHCredentials, Gr as SandboxUser, Gt as IntelligenceReportBudget, H as DispatchedSession, Hi as BatchEvent, Hn as RolloutTurnPart, Hr as SandboxTraceEvent, Ht as HostAgentRuntimeBackend, I as CreateSessionOptions, Ii as WaitForOptions, In as Rollout, Ir as SandboxTerminalCreateOptions, It as GpuLeaseExecResult, J as DriverType, Ji as TerminalReadyInfo, Jn as SandboxEnvironment, Jr as SearchMatch, Jt as IntelligenceReportWindow, K as DriverConfig, Ki as TERMINAL_WS_ECHO_SUBPROTOCOL, Kn as SandboxClientConfig, Kr as ScopedToken, Kt as IntelligenceReportCompareTo, L as CreateTaskSessionOptions, Li as WaitForRolloutOptions, Ln as RolloutChildResult, Lr as SandboxTerminalInfo, Lt as GpuLeaseManager, M as CreateSandboxFleetOptions, Mi as UpdateUserOptions, Mn as ReconcileSandboxFleetsResult, Mr as SandboxRuntimeProfile, Mt as GpuLease, Ni as UploadOptions, Nn as RenameOptions, Nr as SandboxRuntimeProfileList, Nt as GpuLeaseBilling, O as CompletedTurnResult, Oi as TeePublicKeyResponse, On as PublishPublicTemplateVersionOptions, Or as SandboxProfileSummary, Ot as GitCommit, P as CreateSandboxFleetWithCoordinatorOptions, Pi as UploadProgress, Pr as SandboxStatus, Pt as GpuLeaseCommandResult, Q as EnsureDevServerOptions, Qi as TerminalStreamHandlers, Qn as SandboxFleetCostEstimate, Qr as SendSessionMessageOptions, Qt as ListSandboxFleetOptions, R as DeleteOptions, Ri as WriteFileOptions, Rn as RolloutOptions, Rr as SandboxTerminalManager, Rt as GpuLeaseProviderName, Sa as mergeAgentProfiles, Si as TaskSessionInfo, Sn as ProvisionResult, Sr as SandboxFleetWorkspaceSnapshotResult, St as FleetMachineId, T as CodeResult, Ti as TeeAttestationReport, Tn as PublicTemplateInfo, Tr as SandboxPermissionsConfig, Tt as GPU_LEASE_PROVIDER_NAMES, U as DownloadOptions, Ui as BatchEventDataMap, Un as RunCodeOptions, Ur as SandboxTraceExport, Ut as InstalledTool, V as DispatchPromptOptions, Vi as BatchBackendStats, Vn as RolloutStatus, Vr as SandboxTraceBundle, Vt as HostAgentDriverConfig, W as DownloadProgress, Wi as BatchSidecarGroup, Wn as SSHCommandDescriptor, Wr as SandboxTraceOptions, Wt as IntelligenceReport, X as EgressManager, Xi as TerminalStreamAuthFormat, Xn as SandboxFleetArtifact, Xr as SecretInfo, Xt as ListMessagesOptions, Yi as TerminalStream, Yn as SandboxEvent, Yr as SearchOptions, Z as EgressPolicy, Zi as TerminalStreamError, Zn as SandboxFleetArtifactSpec, Zr as SecretsManager, Zt as ListOptions, _ as BatchTask, _a as agentProfileSchema, _i as TaskOptions, _n as ProcessStatus, _r as SandboxFleetTraceOptions, _t as FleetDispatchResultBuffer, a as AttachSandboxFleetMachineOptions, aa as AgentProfileFileMount, ai as SessionListOptions, an as NonHostAgentDriverConfig, ar as SandboxFleetMachine, at as FileReadBatchResult, b as ChunkedUploadOptions, ba as defineGitHubResource, bi as TaskSessionCommitResult, bn as PromptResult, br as SandboxFleetWorkspaceReconcileResult, bt as FleetExecDispatchOptions, c as BackendInfo, ca as AgentProfilePermissionValue, ci as SessionStatus, cn as PreviewLinkInfo, cr as SandboxFleetMachineSpec, ct as FileRenameResult, d as BackendType, da as AgentProfileResources, di as SnapshotResult, dn as ProcessInfo, dr as SandboxFleetOperationsSummary, dt as FileTreeOptions, ea as TerminalStreamToken, ei as SentSessionMessage, en as McpServerConfig, er as SandboxFleetDispatchResponse, et as ExactProcessSpawnOptions, f as BatchBackend, fa as AgentProfileSecurityPolicy, fn as ProcessListOptions, fr as SandboxFleetPolicy, ft as FileTreeResult, g as BatchRunRequest, ga as Capability, gi as SubscriptionInfo, gn as ProcessSpawnOptions, gr as SandboxFleetTraceExport, gt as FleetDispatchCancelResult, h as BatchRunOptions, ha as AgentSubagentProfile, hi as StorageConfig, hn as ProcessSignal, hr as SandboxFleetTraceEvent, ht as FileWriteResult, i as AttachGpuLeaseOptions, ia as AgentProfileConnection, ii as SessionInfo, in as NetworkManager, ir as SandboxFleetIntelligenceEnvelope, it as FileReadBatchOptions, j as CreateRequestOptions, ji as TurnDriveResult, jn as ReconcileSandboxFleetsOptions, jr as SandboxRuntimeHealth, jt as GitStatus, k as CreateGpuLeaseOptions, ki as TokenRefreshHandler, kn as ReapExpiredSandboxFleetsOptions, kr as SandboxResourceUsage, kt as GitConfig, l as BackendManager, la as AgentProfilePrompt, li as SnapshotInfo, ln as PreviewLinkManager, lr as SandboxFleetManifest, lt as FileSystem, m as BatchResult, ma as AgentProfileValidationResult, mi as StartupOperation, mn as ProcessManager, mr as SandboxFleetTraceBundle, mt as FileUsageResult, n as AccessPolicyRule, na as AgentProfileCapabilities, ni as SessionEventStreamOptions, nn as MkdirOptions, nr as SandboxFleetDriverTimings, nt as ExecResult, o as BackendCapabilities, oa as AgentProfileMcpServer, oi as SessionMessage, on as PermissionLevel, or as SandboxFleetMachineMeteredUsage, ot as FileReadError, p as BatchOptions, pa as AgentProfileValidationIssue, pi as StartupDiagnostics, pn as ProcessLogEntry, pr as SandboxFleetToken, pt as FileUsageOptions, q as DriverInfo, qi as TerminalExitInfo, qn as SandboxConnection, qr as ScopedTokenScope, qt as IntelligenceReportSubjectType, r as AddUserOptions, ra as AgentProfileConfidential, ri as SessionForkOptions, rn as NetworkConfig, rr as SandboxFleetInfo, rt as FileInfo, s as BackendConfig, sa as AgentProfileModelHints, si as SessionMessageInputPart, sn as PermissionsManager, sr as SandboxFleetMachineRecord, st as FileReadResult, t as AcceleratorKind, ta as AgentProfile, ti as SessionBackendCredentials, tn as MintScopedTokenOptions, tr as SandboxFleetDriverCapability, tt as ExecOptions, u as BackendStatus, ua as AgentProfileResourceRef, ui as SnapshotOptions, un as Process, ur as SandboxFleetManifestMachine, ut as FileTreeFile, v as BatchTaskResult, va as capabilitySchema, vi as TaskResult, vr as SandboxFleetUsage, vt as FleetDispatchResultBufferOptions, wi as TeeAttestationOptions, wn as ProvisionStep, wr as SandboxIntelligenceEnvelope, x as ChunkedUploadResult, xa as defineInlineResource, xi as TaskSessionFileChange, xn as ProvisionEvent, xr as SandboxFleetWorkspaceRestoreResult, y as BranchOptions, ya as defineAgentProfile, yi as TaskSessionChanges, yn as PromptOptions, yr as SandboxFleetWorkspace, yt as FleetDispatchStreamOptions, z as DevServerInfo, zi as WriteManyFile, zn as RolloutScorer, zr as SandboxTerminalRequestOptions, zt as GpuLeaseStatus } from "./types-C67osezQ.js";
|
|
2
|
+
import { A as SandboxMcpEndpoint, C as RespondToPermissionOptions, D as CONTROL_PLANE_MCP_SERVER_NAME, E as BuildSandboxMcpConfigOptions, M as buildControlPlaneMcpConfig, N as buildSandboxMcpConfig, O as SANDBOX_MCP_SERVER_NAME, S as InterruptResult, T as BuildControlPlaneMcpConfigOptions, _ as InteractiveAuthFile, a as WorkspaceImagePublishResult, b as InteractiveSessionInfo, c as TraceExportResult, d as exportTraceBundle, f as otelTraceIdForTangleTrace, g as InteractiveAttachOptions, h as SandboxSession, i as WorkspaceImagePublishRequestOptions, j as SandboxMcpServerEntry, k as SandboxMcpConfig, l as TraceExportSink, m as SandboxTaskSession, n as SandboxInstance, o as WorkspaceImages, p as toOtelJson, r as WorkspaceImagePublishInput, s as TraceExportFormat, u as buildTraceExportPayload, v as InteractiveSessionHandle, w as StartInteractiveOptions, x as InteractiveSessionStatus, y as InteractiveSessionHost } from "./sandbox-hbYwu_Ot.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-iZbD-9Ks.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
|
-
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-
|
|
7
|
-
import { s as TangleSandboxClientConfig, t as TangleSandboxClient } from "./index-
|
|
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-C8HMx78o.js";
|
|
7
|
+
import { s as TangleSandboxClientConfig, t as TangleSandboxClient } from "./index-Bhx4EQca.js";
|
|
8
8
|
|
|
9
9
|
//#region src/attestation-heartbeat.d.ts
|
|
10
10
|
interface TeeAttestationHeartbeatSample {
|
|
@@ -1082,6 +1082,24 @@ type ProfileFileMountBox = Pick<SandboxInstance, "exec"> & {
|
|
|
1082
1082
|
* orphaned by the post-provision throw.
|
|
1083
1083
|
*/
|
|
1084
1084
|
declare function validateDeferredProfileFileMounts(files: readonly AgentProfileFileMount[]): void;
|
|
1085
|
+
interface SplitInlineProfileSkillsResult {
|
|
1086
|
+
/** Profile with inline skill refs removed (github refs kept — they resolve
|
|
1087
|
+
* server-side). Suitable for the create body, whose wire cap the full skill
|
|
1088
|
+
* corpus would exceed. */
|
|
1089
|
+
leanProfile: AgentProfile;
|
|
1090
|
+
/** How many inline skill refs were stripped. Zero means nothing to defer. */
|
|
1091
|
+
deferredSkillCount: number;
|
|
1092
|
+
}
|
|
1093
|
+
/**
|
|
1094
|
+
* Split inline `resources.skills` out of a profile the way
|
|
1095
|
+
* {@link splitInlineProfileFileMounts} splits inline files: the returned
|
|
1096
|
+
* `leanProfile` drops them so the create POST fits its wire cap. Unlike file
|
|
1097
|
+
* mounts, skills are NOT materialized to disk here — they are harness-specific
|
|
1098
|
+
* (each turn's harness needs them in its own dir), so they must ride the
|
|
1099
|
+
* per-turn profile. The full profile is delivered once (create-time priming)
|
|
1100
|
+
* and referenced by hash thereafter.
|
|
1101
|
+
*/
|
|
1102
|
+
declare function splitInlineProfileSkills(profile: AgentProfile): SplitInlineProfileSkillsResult;
|
|
1085
1103
|
declare function splitInlineProfileFileMounts(profile: AgentProfile): SplitInlineProfileFileMountsResult;
|
|
1086
1104
|
declare function materializeProfileFileMounts(box: ProfileFileMountBox, files: readonly AgentProfileFileMount[], options?: MaterializeProfileFileMountsOptions): Promise<MaterializeProfileFileMountsResult>;
|
|
1087
1105
|
//#endregion
|
|
@@ -1386,4 +1404,4 @@ interface RouterEvalMatrixCaseResult {
|
|
|
1386
1404
|
}
|
|
1387
1405
|
declare function runTangleRouterEvalMatrixInSandbox(options: RunTangleRouterEvalMatrixInSandboxOptions): Promise<RunTangleRouterEvalMatrixInSandboxResult>;
|
|
1388
1406
|
//#endregion
|
|
1389
|
-
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 ChunkedUploadOptions, type ChunkedUploadResult, 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 ExactProcessSpawnOptions, type ExecOptions, type ExecResult, type FileInfo, type FileReadBatchOptions, type FileReadBatchResult, type FileReadError, type FileReadResult, type FileRenameResult, 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 RenameOptions, 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, validateDeferredProfileFileMounts };
|
|
1407
|
+
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 AgentProfileSecurityPolicy, 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, type Capability, CapabilityError, type ChunkedUploadOptions, type ChunkedUploadResult, 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 DevServerInfo, type DirectoryPermission, type DispatchPromptOptions, type DispatchedSession, type DownloadOptions, type DownloadProgress, type DriveTurnOptions, type DriverConfig, type DriverInfo, type DriverType, type EgressManager, type EgressPolicy, EgressProxyRecoveryError, type EnsureDevServerOptions, type EventStreamOptions, type ExactProcessSpawnOptions, type ExecOptions, type ExecResult, type FileInfo, type FileReadBatchOptions, type FileReadBatchResult, type FileReadError, type FileReadResult, type FileRenameResult, type FileSystem, type FileTreeFile, type FileTreeOptions, type FileTreeResult, type FileUsageOptions, type FileUsageResult, 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 InteractiveAttachOptions, type InteractiveAuthFile, InteractiveSessionHandle, type InteractiveSessionHost, type InteractiveSessionInfo, type InteractiveSessionStatus, 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 ProcessListOptions, 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 RenameOptions, 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 SandboxTerminalAttachOptions, type SandboxTerminalCreateOptions, type SandboxTerminalInfo, type SandboxTerminalManager, type SandboxTerminalRequestOptions, type SandboxTerminals, 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 SplitInlineProfileSkillsResult, type StartInteractiveOptions, type StartupDiagnostics, type StartupOperation, StateError, type StorageConfig, type SubscriptionInfo, TERMINAL_WS_ECHO_SUBPROTOCOL, 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, type TerminalExitInfo, type TerminalReadyInfo, TerminalStream, type TerminalStreamAuthFormat, TerminalStreamError, type TerminalStreamHandlers, type TerminalStreamOptions, type TerminalStreamToken, 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 WorkspaceImagePublishInput, type WorkspaceImagePublishRequestOptions, type WorkspaceImagePublishResult, WorkspaceImages, type WriteFileOptions, type WriteManyFile, type WriteManyOptions, agentProfileSchema, applySandboxEventText, buildCollaborationDocumentId, buildControlPlaneMcpConfig, buildSandboxMcpConfig, buildTangleRouterEvalMatrixRequest, buildTangleRouterResponsesWebSearchRequest, buildTangleRouterSearchBackend, buildTangleRouterSearchProfile, buildTraceExportPayload, capabilitySchema, collectAgentResponseText, createConfidentialSandbox, createManageSandboxesTool, defineAgentProfile, defineGitHubResource, defineInlineResource, exportTraceBundle, fetchTangleRouterSearchConfig, generateAttestationNonce, generateDockerfile, getSandboxEventText, materializeProfileFileMounts, mergeAgentProfiles, normalizeCollaborationPath, normalizeRuntimeBackendConfig, otelTraceIdForTangleTrace, parseCollaborationDocumentId, parseSSEStream, resolveSandboxResources, runTangleRouterEvalMatrixInSandbox, sandboxResourcesForSize, serializeForSidecar, splitInlineProfileFileMounts, splitInlineProfileSkills, startTeeAttestationHeartbeat, toOtelJson, validateAgentProfileSecurity, validateDeferredProfileFileMounts };
|
package/dist/index.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import {
|
|
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-
|
|
3
|
-
import { a as
|
|
4
|
-
import { a as
|
|
5
|
-
import { a as CollaborationClient, i as parseCollaborationDocumentId, n as buildCollaborationDocumentId, r as normalizeCollaborationPath, t as CollaborationFileBridge } from "./collaboration-
|
|
6
|
-
import { t as TangleSandboxClient } from "./tangle-
|
|
7
|
-
import { defineAgentProfile, defineGitHubResource, defineInlineResource, mergeAgentProfiles } from "@tangle-network/agent-interface";
|
|
1
|
+
import { d as serializeForSidecar, l as normalizeRuntimeBackendConfig } from "./runtime-api-XhAv6YiH.js";
|
|
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-D9fFOWX9.js";
|
|
3
|
+
import { _ as otelTraceIdForTangleTrace, a as TERMINAL_WS_ECHO_SUBPROTOCOL, c as SandboxTaskSession, d as applySandboxEventText, f as collectAgentResponseText, g as exportTraceBundle, h as buildTraceExportPayload, i as WorkspaceImages, l as SandboxSession, o as TerminalStream, p as getSandboxEventText, s as TerminalStreamError, t as SandboxInstance, u as InteractiveSessionHandle, v as toOtelJson, y as parseSSEStream } from "./sandbox-CWeFm9Hj.js";
|
|
4
|
+
import { a as splitInlineProfileSkills, c as SandboxFleetClient, d as SANDBOX_SIZE_PRESET_NAMES, f as resolveSandboxResources, i as splitInlineProfileFileMounts, l as DEFAULT_SANDBOX_SIZE, n as SandboxClient, o as validateDeferredProfileFileMounts, p as sandboxResourcesForSize, r as materializeProfileFileMounts, s as SandboxFleet, t as IntelligenceClient, u as SANDBOX_SIZE_PRESETS } from "./client-BCNrDjvA.js";
|
|
5
|
+
import { a as CollaborationClient, i as parseCollaborationDocumentId, n as buildCollaborationDocumentId, r as normalizeCollaborationPath, t as CollaborationFileBridge } from "./collaboration-DdD_rFZQ.js";
|
|
6
|
+
import { t as TangleSandboxClient } from "./tangle-C8CaT3tE.js";
|
|
7
|
+
import { agentProfileSchema, capabilitySchema, defineAgentProfile, defineGitHubResource, defineInlineResource, mergeAgentProfiles, validateAgentProfileSecurity } from "@tangle-network/agent-interface";
|
|
8
8
|
//#region src/confidential.ts
|
|
9
9
|
function generateAttestationNonce(bytes = 32) {
|
|
10
10
|
const buffer = new Uint8Array(bytes);
|
|
@@ -1454,4 +1454,4 @@ function stripUndefined(value) {
|
|
|
1454
1454
|
return Object.fromEntries(Object.entries(value).filter(([, v]) => v !== void 0).map(([k, v]) => [k, stripUndefined(v)]));
|
|
1455
1455
|
}
|
|
1456
1456
|
//#endregion
|
|
1457
|
-
export { AuthError, CONTROL_PLANE_MCP_SERVER_NAME, CapabilityError, CollaborationClient, CollaborationFileBridge, DEFAULT_SANDBOX_SIZE, EgressProxyRecoveryError, GPU_LEASE_PROVIDER_NAMES, Image, ImageBuilder, IntelligenceClient, InteractiveSessionHandle, MANAGE_SANDBOXES_PARAMETERS, MANAGE_SANDBOXES_TOOL_NAME, NetworkError, NotFoundError, PartialFailureError, QuotaError, SANDBOX_MCP_SERVER_NAME, SANDBOX_SIZE_PRESETS, SANDBOX_SIZE_PRESET_NAMES, SandboxClient as Sandbox, SandboxClient, SandboxError, SandboxFleet, SandboxFleetClient, SandboxInstance, SandboxSession, SandboxTaskSession, ServerError, StateError, TangleSandboxClient, TimeoutError, ValidationError, 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, validateDeferredProfileFileMounts };
|
|
1457
|
+
export { AuthError, CONTROL_PLANE_MCP_SERVER_NAME, CapabilityError, CollaborationClient, CollaborationFileBridge, DEFAULT_SANDBOX_SIZE, EgressProxyRecoveryError, GPU_LEASE_PROVIDER_NAMES, Image, ImageBuilder, IntelligenceClient, InteractiveSessionHandle, MANAGE_SANDBOXES_PARAMETERS, MANAGE_SANDBOXES_TOOL_NAME, NetworkError, NotFoundError, PartialFailureError, QuotaError, SANDBOX_MCP_SERVER_NAME, SANDBOX_SIZE_PRESETS, SANDBOX_SIZE_PRESET_NAMES, SandboxClient as Sandbox, SandboxClient, SandboxError, SandboxFleet, SandboxFleetClient, SandboxInstance, SandboxSession, SandboxTaskSession, ServerError, StateError, TERMINAL_WS_ECHO_SUBPROTOCOL, TangleSandboxClient, TerminalStream, TerminalStreamError, TimeoutError, ValidationError, WorkspaceImages, agentProfileSchema, applySandboxEventText, buildCollaborationDocumentId, buildControlPlaneMcpConfig, buildSandboxMcpConfig, buildTangleRouterEvalMatrixRequest, buildTangleRouterResponsesWebSearchRequest, buildTangleRouterSearchBackend, buildTangleRouterSearchProfile, buildTraceExportPayload, capabilitySchema, collectAgentResponseText, createConfidentialSandbox, createManageSandboxesTool, defineAgentProfile, defineGitHubResource, defineInlineResource, exportTraceBundle, fetchTangleRouterSearchConfig, generateAttestationNonce, generateDockerfile, getSandboxEventText, materializeProfileFileMounts, mergeAgentProfiles, normalizeCollaborationPath, normalizeRuntimeBackendConfig, otelTraceIdForTangleTrace, parseCollaborationDocumentId, parseSSEStream, resolveSandboxResources, runTangleRouterEvalMatrixInSandbox, sandboxResourcesForSize, serializeForSidecar, splitInlineProfileFileMounts, splitInlineProfileSkills, startTeeAttestationHeartbeat, toOtelJson, validateAgentProfileSecurity, validateDeferredProfileFileMounts };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { d as TimeoutError, i as NetworkError, p as parseErrorResponse } from "../errors-
|
|
1
|
+
import { d as TimeoutError, i as NetworkError, p as parseErrorResponse } from "../errors-D9fFOWX9.js";
|
|
2
2
|
//#region src/intelligence/index.ts
|
|
3
3
|
/**
|
|
4
4
|
* `@tangle-network/sandbox/intelligence` — browser-safe typed client for the
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { c as SandboxError, d as TimeoutError, f as ValidationError, i as NetworkError, l as ServerError, p as parseErrorResponse, s as QuotaError } from "./errors-
|
|
1
|
+
import { c as SandboxError, d as TimeoutError, f as ValidationError, i as NetworkError, l as ServerError, p as parseErrorResponse, s as QuotaError } from "./errors-D9fFOWX9.js";
|
|
2
2
|
//#region src/backend-config.ts
|
|
3
3
|
const LEGACY_QUESTION_ALIAS_KEY = ["question", "Channel"].join("");
|
|
4
|
-
function
|
|
4
|
+
function normalizeRuntimeModelOverride(model) {
|
|
5
5
|
const parts = model.split("/");
|
|
6
6
|
if (parts.length >= 2) return {
|
|
7
7
|
provider: parts[0],
|
|
@@ -24,7 +24,7 @@ function normalizeRuntimeBackendConfig(backend, options = {}) {
|
|
|
24
24
|
...backend?.type ? { type: backend.type } : {},
|
|
25
25
|
...backend?.profile !== void 0 ? { profile: backend.profile } : {},
|
|
26
26
|
...callerInlineProfile !== void 0 ? { inlineProfile: callerInlineProfile } : {},
|
|
27
|
-
...backend?.model ? { model: backend.model } : options.model ? { model:
|
|
27
|
+
...backend?.model ? { model: backend.model } : options.model ? { model: normalizeRuntimeModelOverride(options.model) } : {},
|
|
28
28
|
...backend?.server ? { server: backend.server } : {},
|
|
29
29
|
...backend?.interactions !== void 0 ? { interactions: backend.interactions } : {},
|
|
30
30
|
...backend?.metadata !== void 0 ? { metadata: backend.metadata } : {}
|
|
@@ -192,7 +192,7 @@ function sizeOfInput(data) {
|
|
|
192
192
|
* always-accepted buffer type.
|
|
193
193
|
*/
|
|
194
194
|
async function normalizeToBytes(data) {
|
|
195
|
-
if (typeof data === "string") return new TextEncoder().encode(data);
|
|
195
|
+
if (typeof data === "string") return new Uint8Array(new TextEncoder().encode(data));
|
|
196
196
|
if (data instanceof ArrayBuffer) return new Uint8Array(data.slice(0));
|
|
197
197
|
if (ArrayBuffer.isView(data)) {
|
|
198
198
|
const copy = new Uint8Array(data.byteLength);
|
|
@@ -507,6 +507,12 @@ var SandboxRuntimeApi = class {
|
|
|
507
507
|
if (options.sessionId) params.set("sessionId", options.sessionId);
|
|
508
508
|
return (await this.json(`/files/tree?${params}`, { method: "GET" })).data;
|
|
509
509
|
}
|
|
510
|
+
async fileUsage(path, options = {}) {
|
|
511
|
+
await this.transport.ensureRunning();
|
|
512
|
+
const params = new URLSearchParams({ path });
|
|
513
|
+
if (options.sessionId) params.set("sessionId", options.sessionId);
|
|
514
|
+
return (await this.json(`/files/usage?${params}`, { method: "GET" })).data;
|
|
515
|
+
}
|
|
510
516
|
async createSession(options) {
|
|
511
517
|
await this.transport.ensureRunning();
|
|
512
518
|
const info = normalizeSessionInfo(await this.json("/agents/sessions", {
|
|
@@ -665,6 +671,7 @@ function normalizeSessionInfo(raw) {
|
|
|
665
671
|
"failed",
|
|
666
672
|
"cancelled"
|
|
667
673
|
].includes(status) ? status : "running",
|
|
674
|
+
latestExecutionId: typeof raw.latestExecutionId === "string" && raw.latestExecutionId.length > 0 ? raw.latestExecutionId : void 0,
|
|
668
675
|
backend: typeof raw.backendType === "string" ? raw.backendType : typeof raw.backend === "string" ? raw.backend : void 0,
|
|
669
676
|
model: typeof raw.model === "string" ? raw.model : void 0,
|
|
670
677
|
promptCount: typeof raw.promptCount === "number" ? raw.promptCount : void 0,
|
|
@@ -675,4 +682,4 @@ function normalizeSessionInfo(raw) {
|
|
|
675
682
|
};
|
|
676
683
|
}
|
|
677
684
|
//#endregion
|
|
678
|
-
export { FILE_DECODED_WRITE_MAX_BYTES as a, encodeTextForWire as c, SANDBOX_PROXY_REQUEST_MAX_BYTES as i, normalizeRuntimeBackendConfig as l, normalizeSessionInfo as n, combineAbortSignals as o, uploadChunked as r, encodePromptForWire as s, SandboxRuntimeApi as t,
|
|
685
|
+
export { FILE_DECODED_WRITE_MAX_BYTES as a, encodeTextForWire as c, serializeForSidecar as d, SANDBOX_PROXY_REQUEST_MAX_BYTES as i, normalizeRuntimeBackendConfig as l, normalizeSessionInfo as n, combineAbortSignals as o, uploadChunked as r, encodePromptForWire as s, SandboxRuntimeApi as t, normalizeRuntimeModelOverride as u };
|
package/dist/runtime.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
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-
|
|
1
|
+
import { $r as SendSessionMessageRequest, D as CommitTaskSessionOptions, Er as SandboxPortBinding, I as CreateSessionOptions, Ir as SandboxTerminalCreateOptions, L as CreateTaskSessionOptions, Lr as SandboxTerminalInfo, Nn as RenameOptions, Nr as SandboxRuntimeProfileList, Pi as UploadProgress, Qr as SendSessionMessageOptions, Ri as WriteFileOptions, Rr as SandboxTerminalManager, Si as TaskSessionInfo, Xt as ListMessagesOptions, at as FileReadBatchResult, b as ChunkedUploadOptions, bi as TaskSessionCommitResult, ct as FileRenameResult, dt as FileTreeOptions, ei as SentSessionMessage, ft as FileTreeResult, ht as FileWriteResult, ii as SessionInfo, it as FileReadBatchOptions, jr as SandboxRuntimeHealth, mt as FileUsageResult, oi as SessionMessage, pt as FileUsageOptions, x as ChunkedUploadResult, yi as TaskSessionChanges, zr as SandboxTerminalRequestOptions } from "./types-C67osezQ.js";
|
|
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-C8HMx78o.js";
|
|
3
3
|
|
|
4
4
|
//#region src/lib/chunked-upload.d.ts
|
|
5
5
|
/** The transport a caller wires this module to — {@link SandboxInstance.runtimeFetch}
|
|
@@ -60,6 +60,7 @@ declare class SandboxRuntimeApi {
|
|
|
60
60
|
deleteFile(path: string, options?: Pick<WriteFileOptions, "sessionId">): Promise<void>;
|
|
61
61
|
renameFile(sourcePath: string, destinationPath: string, options?: RenameOptions): Promise<FileRenameResult>;
|
|
62
62
|
fileTree(path: string, options?: FileTreeOptions): Promise<FileTreeResult>;
|
|
63
|
+
fileUsage(path: string, options?: FileUsageOptions): Promise<FileUsageResult>;
|
|
63
64
|
createSession(options: CreateSessionOptions): Promise<SessionInfo>;
|
|
64
65
|
messages(id: string, options?: Omit<ListMessagesOptions, "sessionId">): Promise<SessionMessage[]>;
|
|
65
66
|
createTaskSession(options: CreateTaskSessionOptions): Promise<TaskSessionInfo>;
|
package/dist/runtime.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { o as combineAbortSignals, r as uploadChunked, t as SandboxRuntimeApi } from "./runtime-api-
|
|
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, s as QuotaError, t as AuthError, u as StateError } from "./errors-
|
|
1
|
+
import { o as combineAbortSignals, r as uploadChunked, t as SandboxRuntimeApi } from "./runtime-api-XhAv6YiH.js";
|
|
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, s as QuotaError, t as AuthError, u as StateError } from "./errors-D9fFOWX9.js";
|
|
3
3
|
//#region src/runtime-client.ts
|
|
4
4
|
const DEFAULT_RUNTIME_TIMEOUT_MS = 3e4;
|
|
5
5
|
function requireToken(token) {
|