@opengeni/runtime 2.5.2-canary.0 → 2.5.3-canary.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/dist/{agent-Q2VNH5FV.js → agent-RJQLKFIW.js} +2 -2
- package/dist/{chunk-CD22I76N.js → chunk-FHGLYLBL.js} +2 -2
- package/dist/{chunk-GBHOT4KS.js → chunk-SD6MDONS.js} +350 -67
- package/dist/chunk-SD6MDONS.js.map +1 -0
- package/dist/{chunk-25B3EQRW.js → chunk-UNICCRW5.js} +4 -4
- package/dist/{chunk-LEIGL6X2.js → chunk-VVEGJPDR.js} +5 -5
- package/dist/index.d.ts +7 -0
- package/dist/index.js +18 -4
- package/dist/{localSources-Z5IJIIRV.js → localSources-PVFCAPN2.js} +3 -3
- package/dist/mcp-operation-dispatch.d.ts +45 -0
- package/dist/mcp-operation-observation.d.ts +137 -0
- package/dist/sandbox/index.js +3 -3
- package/dist/workspace-tool-gateway.js +4 -4
- package/package.json +11 -11
- package/src/index.ts +231 -45
- package/src/mcp-operation-dispatch.ts +144 -0
- package/src/mcp-operation-observation.ts +148 -0
- package/dist/chunk-GBHOT4KS.js.map +0 -1
- /package/dist/{agent-Q2VNH5FV.js.map → agent-RJQLKFIW.js.map} +0 -0
- /package/dist/{chunk-CD22I76N.js.map → chunk-FHGLYLBL.js.map} +0 -0
- /package/dist/{chunk-25B3EQRW.js.map → chunk-UNICCRW5.js.map} +0 -0
- /package/dist/{chunk-LEIGL6X2.js.map → chunk-VVEGJPDR.js.map} +0 -0
- /package/dist/{localSources-Z5IJIIRV.js.map → localSources-PVFCAPN2.js.map} +0 -0
|
@@ -32468,7 +32468,7 @@ var SandboxMemoryGenerationManager = class {
|
|
|
32468
32468
|
if (!transcript) {
|
|
32469
32469
|
throw new UserError(`Memory rollout transcript was not found: ${transcriptPath}`);
|
|
32470
32470
|
}
|
|
32471
|
-
const { SandboxAgent: SandboxAgent2 } = await import("./agent-
|
|
32471
|
+
const { SandboxAgent: SandboxAgent2 } = await import("./agent-RJQLKFIW.js");
|
|
32472
32472
|
const phaseOneAgent = new SandboxAgent2({
|
|
32473
32473
|
name: "sandbox-memory-phase-one",
|
|
32474
32474
|
instructions: renderRolloutExtractionInstructions(generate.extraPrompt),
|
|
@@ -32529,7 +32529,7 @@ var SandboxMemoryGenerationManager = class {
|
|
|
32529
32529
|
})) {
|
|
32530
32530
|
return;
|
|
32531
32531
|
}
|
|
32532
|
-
const { SandboxAgent: SandboxAgent2 } = await import("./agent-
|
|
32532
|
+
const { SandboxAgent: SandboxAgent2 } = await import("./agent-RJQLKFIW.js");
|
|
32533
32533
|
const phaseTwoAgent = new SandboxAgent2({
|
|
32534
32534
|
name: "sandbox-memory-phase-two",
|
|
32535
32535
|
model: generate.phaseTwoModel,
|
|
@@ -44150,8 +44150,8 @@ function normalizeRunAs(runAs) {
|
|
|
44150
44150
|
}
|
|
44151
44151
|
|
|
44152
44152
|
export {
|
|
44153
|
-
loadEnv,
|
|
44154
44153
|
external_exports,
|
|
44154
|
+
loadEnv,
|
|
44155
44155
|
getLogger,
|
|
44156
44156
|
logToolActionError,
|
|
44157
44157
|
logToolActionDebug,
|
|
@@ -44266,4 +44266,4 @@ export {
|
|
|
44266
44266
|
Runner,
|
|
44267
44267
|
Agent
|
|
44268
44268
|
};
|
|
44269
|
-
//# sourceMappingURL=chunk-
|
|
44269
|
+
//# sourceMappingURL=chunk-UNICCRW5.js.map
|
|
@@ -31,7 +31,7 @@ import {
|
|
|
31
31
|
validateCredentialPair,
|
|
32
32
|
validateRemoteSandboxPathForManifest,
|
|
33
33
|
validateSandboxArchiveLimits
|
|
34
|
-
} from "./chunk-
|
|
34
|
+
} from "./chunk-FHGLYLBL.js";
|
|
35
35
|
import {
|
|
36
36
|
Environment,
|
|
37
37
|
FileMode,
|
|
@@ -94,7 +94,7 @@ import {
|
|
|
94
94
|
shellQuote,
|
|
95
95
|
stableJsonStringify,
|
|
96
96
|
withSandboxSpan
|
|
97
|
-
} from "./chunk-
|
|
97
|
+
} from "./chunk-UNICCRW5.js";
|
|
98
98
|
|
|
99
99
|
// src/sandbox/index.ts
|
|
100
100
|
import { collectSandboxEnvironment, parseExposedPorts } from "@opengeni/config";
|
|
@@ -6565,7 +6565,7 @@ var CloudflareSandboxSession = class {
|
|
|
6565
6565
|
async materializeEntry(args) {
|
|
6566
6566
|
assertSandboxEntryMetadataSupported("CloudflareSandboxClient", args.path, args.entry, MOUNT_MANIFEST_METADATA_SUPPORT);
|
|
6567
6567
|
if (entryContainsLocalSource(args.entry)) {
|
|
6568
|
-
const { applyLocalSourceManifestEntryToState: applyLocalSourceManifestEntryToState2 } = await import("./localSources-
|
|
6568
|
+
const { applyLocalSourceManifestEntryToState: applyLocalSourceManifestEntryToState2 } = await import("./localSources-PVFCAPN2.js");
|
|
6569
6569
|
await applyLocalSourceManifestEntryToState2(this.state, args.path, args.entry, "cloudflare", this.writer(), this.remotePathResolver, this.manifestMaterializationOptions(args.runAs));
|
|
6570
6570
|
return;
|
|
6571
6571
|
}
|
|
@@ -6576,7 +6576,7 @@ var CloudflareSandboxSession = class {
|
|
|
6576
6576
|
assertSandboxManifestMetadataSupported("CloudflareSandboxClient", manifest, MOUNT_MANIFEST_METADATA_SUPPORT);
|
|
6577
6577
|
assertCloudflareManifestMountsSupported(manifest);
|
|
6578
6578
|
if (manifestContainsLocalSource(manifest)) {
|
|
6579
|
-
const { applyLocalSourceManifestToState: applyLocalSourceManifestToState2 } = await import("./localSources-
|
|
6579
|
+
const { applyLocalSourceManifestToState: applyLocalSourceManifestToState2 } = await import("./localSources-PVFCAPN2.js");
|
|
6580
6580
|
await applyLocalSourceManifestToState2(this.state, manifest, "cloudflare", this.writer(), this.remotePathResolver, this.manifestMaterializationOptions(runAs));
|
|
6581
6581
|
return;
|
|
6582
6582
|
}
|
|
@@ -37003,4 +37003,4 @@ export {
|
|
|
37003
37003
|
collectSandboxEnvironment2 as collectSandboxEnvironment,
|
|
37004
37004
|
parseExposedPorts2 as parseExposedPorts
|
|
37005
37005
|
};
|
|
37006
|
-
//# sourceMappingURL=chunk-
|
|
37006
|
+
//# sourceMappingURL=chunk-VVEGJPDR.js.map
|
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
import type { ModelProviderApi, ResolvedModelProvider, Settings } from "@opengeni/config";
|
|
2
|
+
import { type McpOperationPersistence } from "./mcp-operation-dispatch.js";
|
|
3
|
+
export { captureMcpOperationDispatch, hasActiveRecoverableMcpOperation, McpOperationOutcomeUnknownError, runRecoverableMcpOperation, type CapturedMcpOperation, type McpOperationPersistence, type RecoverableMcpOperation, } from "./mcp-operation-dispatch.js";
|
|
4
|
+
export { assertMcpOperationObservationAuthority, observeMcpOperation, runMcpOperationObservationWithAuthority, type McpOperationObservationAuthority, type McpObservationBinding, type McpObservationReceipt, } from "./mcp-operation-observation.js";
|
|
2
5
|
import { type SkillCatalogDescriptor } from "./skill-catalog.js";
|
|
3
6
|
export { formatSkillCatalog, type SkillCatalogDescriptor } from "./skill-catalog.js";
|
|
4
7
|
import { AttemptToolEnvironment, type AttemptToolAuthorization, type AttemptToolDefinition } from "@opengeni/codemode";
|
|
@@ -90,6 +93,8 @@ export type ResolveConnectionCredentialResult = {
|
|
|
90
93
|
connectionId: string;
|
|
91
94
|
authoritySource?: "host";
|
|
92
95
|
authorizeProviderRequest?: () => Promise<boolean>;
|
|
96
|
+
/** Metadata-only immutable authority binding supplied by the trusted worker resolver. */
|
|
97
|
+
operationAuthorityDigest?: string;
|
|
93
98
|
expiresAt?: Date | null;
|
|
94
99
|
} | {
|
|
95
100
|
status: "auth_needed";
|
|
@@ -707,6 +712,8 @@ export type ToolPreparationPhaseMeasurement = {
|
|
|
707
712
|
durationSeconds: number;
|
|
708
713
|
};
|
|
709
714
|
export type PrepareToolsOptions = {
|
|
715
|
+
/** Opt-in exact-attempt persistence; absence preserves ordinary MCP execution. */
|
|
716
|
+
mcpOperationPersistence?: McpOperationPersistence;
|
|
710
717
|
/** Live exact-owner control refresh; API remains read/observation authority. */
|
|
711
718
|
refreshOwnedCommand?: (commandId: string) => Promise<boolean>;
|
|
712
719
|
accountId?: string;
|
package/dist/index.js
CHANGED
|
@@ -30,6 +30,7 @@ import {
|
|
|
30
30
|
MCP_LIFECYCLE_POLICIES,
|
|
31
31
|
MCP_TOOL_CALL_OUTCOMES,
|
|
32
32
|
MIN_COMPACTION_THRESHOLD_RATIO,
|
|
33
|
+
McpOperationOutcomeUnknownError,
|
|
33
34
|
MultiProviderModelProvider,
|
|
34
35
|
OPENGENI_INNER_MCP_CUSTOM_DATA_KEY,
|
|
35
36
|
OPENGENI_MCP_RESULT_CUSTOM_DATA_KEY,
|
|
@@ -73,6 +74,7 @@ import {
|
|
|
73
74
|
appendWorkspaceGovernance,
|
|
74
75
|
appendWorkspaceMemory,
|
|
75
76
|
applyMissingManifestEntries,
|
|
77
|
+
assertMcpOperationObservationAuthority,
|
|
76
78
|
assertOpenSuffixResumable,
|
|
77
79
|
azureCliLoginCommand,
|
|
78
80
|
azureOpenAIDefaultQuery,
|
|
@@ -91,6 +93,7 @@ import {
|
|
|
91
93
|
buildRemoteV2ReplacementHistory,
|
|
92
94
|
buildSummaryItem,
|
|
93
95
|
callModelInputFilterForSettings,
|
|
96
|
+
captureMcpOperationDispatch,
|
|
94
97
|
clampCompactionThresholdRatio,
|
|
95
98
|
codemodeTokenSeedCommand,
|
|
96
99
|
compactMcpResultCustomDataRunState,
|
|
@@ -137,6 +140,7 @@ import {
|
|
|
137
140
|
gitCredentialBindingHash,
|
|
138
141
|
gitCredentialBindingTokenRefreshCommand,
|
|
139
142
|
gitProviderTokenRefreshCommand,
|
|
143
|
+
hasActiveRecoverableMcpOperation,
|
|
140
144
|
hasActiveWorkspaceInstructionPolicy,
|
|
141
145
|
hasCanonicalEditableArtifactToolSurface,
|
|
142
146
|
hasModelGeneratedItem,
|
|
@@ -174,6 +178,7 @@ import {
|
|
|
174
178
|
normalizeSdkEvent,
|
|
175
179
|
normalizeToolOutputForEvent,
|
|
176
180
|
normalizeVercelGatewayRequestBody,
|
|
181
|
+
observeMcpOperation,
|
|
177
182
|
oneShotGenesisTitleInputFilter,
|
|
178
183
|
opaqueEncryptedContentLength,
|
|
179
184
|
persistentAgentInstructionInspectionFor,
|
|
@@ -215,7 +220,9 @@ import {
|
|
|
215
220
|
runAzureCliLoginHook,
|
|
216
221
|
runBeforeAgentStartHooks,
|
|
217
222
|
runCodemodeTokenSeedHook,
|
|
223
|
+
runMcpOperationObservationWithAuthority,
|
|
218
224
|
runOwnedSandboxSetup,
|
|
225
|
+
runRecoverableMcpOperation,
|
|
219
226
|
runRepositoryCloneHook,
|
|
220
227
|
runRigSetupHook,
|
|
221
228
|
runtimeSkillIndexForAgent,
|
|
@@ -247,7 +254,7 @@ import {
|
|
|
247
254
|
workspaceEnvironmentInstructions,
|
|
248
255
|
wrapAttemptToolDefinitions,
|
|
249
256
|
wrapAttemptToolExecute
|
|
250
|
-
} from "./chunk-
|
|
257
|
+
} from "./chunk-SD6MDONS.js";
|
|
251
258
|
import {
|
|
252
259
|
ActiveBackendUnresolvableError,
|
|
253
260
|
BROWSER_CONTROL_ADMIN_TOKEN_FILE,
|
|
@@ -519,8 +526,8 @@ import {
|
|
|
519
526
|
withRunCredentialsClient,
|
|
520
527
|
withRunCredentialsSession,
|
|
521
528
|
withoutSandboxProviderIdentity
|
|
522
|
-
} from "./chunk-
|
|
523
|
-
import "./chunk-
|
|
529
|
+
} from "./chunk-VVEGJPDR.js";
|
|
530
|
+
import "./chunk-FHGLYLBL.js";
|
|
524
531
|
import {
|
|
525
532
|
SKILL_MAX_FILES,
|
|
526
533
|
SKILL_MAX_FILE_BYTES,
|
|
@@ -545,7 +552,7 @@ import {
|
|
|
545
552
|
} from "./chunk-JHM4OS7C.js";
|
|
546
553
|
import {
|
|
547
554
|
MaxTurnsExceededError
|
|
548
|
-
} from "./chunk-
|
|
555
|
+
} from "./chunk-UNICCRW5.js";
|
|
549
556
|
import "./chunk-PZ5AY32C.js";
|
|
550
557
|
export {
|
|
551
558
|
ActiveBackendUnresolvableError,
|
|
@@ -618,6 +625,7 @@ export {
|
|
|
618
625
|
MIN_COMPACTION_THRESHOLD_RATIO,
|
|
619
626
|
MODAL_EXEC_READINESS_TIMEOUT_MS,
|
|
620
627
|
MaxTurnsExceededError,
|
|
628
|
+
McpOperationOutcomeUnknownError,
|
|
621
629
|
MockAgentResponder,
|
|
622
630
|
MultiProviderModelProvider,
|
|
623
631
|
NEVER_SENT_DETAIL_KEY,
|
|
@@ -731,6 +739,7 @@ export {
|
|
|
731
739
|
applyMissingManifestEntries,
|
|
732
740
|
assertConsistentSandboxProviderIdentity,
|
|
733
741
|
assertDescriptorRegistryInvariants,
|
|
742
|
+
assertMcpOperationObservationAuthority,
|
|
734
743
|
assertOpenSuffixResumable,
|
|
735
744
|
assertProviderRegistryInvariants,
|
|
736
745
|
assertSafeRelPath,
|
|
@@ -760,6 +769,7 @@ export {
|
|
|
760
769
|
buildTerminalServerScript,
|
|
761
770
|
callModelInputFilterForSettings,
|
|
762
771
|
cancelSelfhostedOp,
|
|
772
|
+
captureMcpOperationDispatch,
|
|
763
773
|
captureVerifiedWorkspaceArchive,
|
|
764
774
|
captureWorkspaceArchiveForStorage,
|
|
765
775
|
clampCompactionThresholdRatio,
|
|
@@ -850,6 +860,7 @@ export {
|
|
|
850
860
|
gitCredentialBindingTokenRefreshCommand,
|
|
851
861
|
gitProviderTokenRefreshCommand,
|
|
852
862
|
gmailRestToolIsMutation,
|
|
863
|
+
hasActiveRecoverableMcpOperation,
|
|
853
864
|
hasActiveWorkspaceInstructionPolicy,
|
|
854
865
|
hasCanonicalEditableArtifactToolSurface,
|
|
855
866
|
hasModelGeneratedItem,
|
|
@@ -920,6 +931,7 @@ export {
|
|
|
920
931
|
normalizeSdkEvent,
|
|
921
932
|
normalizeToolOutputForEvent,
|
|
922
933
|
normalizeVercelGatewayRequestBody,
|
|
934
|
+
observeMcpOperation,
|
|
923
935
|
offlineAgentError,
|
|
924
936
|
offlineControlResponse,
|
|
925
937
|
oneShotGenesisTitleInputFilter,
|
|
@@ -998,7 +1010,9 @@ export {
|
|
|
998
1010
|
runCodemodeTokenSeedHook,
|
|
999
1011
|
runCredentialPointerFile,
|
|
1000
1012
|
runCredentialRoot,
|
|
1013
|
+
runMcpOperationObservationWithAuthority,
|
|
1001
1014
|
runOwnedSandboxSetup,
|
|
1015
|
+
runRecoverableMcpOperation,
|
|
1002
1016
|
runRepositoryCloneHook,
|
|
1003
1017
|
runRigSetupHook,
|
|
1004
1018
|
runStateCompatibilityProvider,
|
|
@@ -3,8 +3,8 @@ import {
|
|
|
3
3
|
applyLocalSourceManifestToState,
|
|
4
4
|
materializeLocalSourceManifest,
|
|
5
5
|
materializeLocalSourceManifestEntry
|
|
6
|
-
} from "./chunk-
|
|
7
|
-
import "./chunk-
|
|
6
|
+
} from "./chunk-FHGLYLBL.js";
|
|
7
|
+
import "./chunk-UNICCRW5.js";
|
|
8
8
|
import "./chunk-PZ5AY32C.js";
|
|
9
9
|
export {
|
|
10
10
|
applyLocalSourceManifestEntryToState,
|
|
@@ -12,4 +12,4 @@ export {
|
|
|
12
12
|
materializeLocalSourceManifest,
|
|
13
13
|
materializeLocalSourceManifestEntry
|
|
14
14
|
};
|
|
15
|
-
//# sourceMappingURL=localSources-
|
|
15
|
+
//# sourceMappingURL=localSources-PVFCAPN2.js.map
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import type { AttemptToolResult } from "@opengeni/contracts";
|
|
2
|
+
export type RecoverableMcpOperation = {
|
|
3
|
+
operationId: string;
|
|
4
|
+
sourceCallId?: string;
|
|
5
|
+
serverId: string;
|
|
6
|
+
originalTool: string;
|
|
7
|
+
observerTool: string;
|
|
8
|
+
destinationDigest: string;
|
|
9
|
+
argumentDigest: string;
|
|
10
|
+
};
|
|
11
|
+
export type CapturedMcpOperation = RecoverableMcpOperation & {
|
|
12
|
+
authorityDigest: string;
|
|
13
|
+
};
|
|
14
|
+
/** Worker-owned persistence. Its implementation must enforce canonical live
|
|
15
|
+
* attempt identity and store no arguments, URLs, headers, or credentials. */
|
|
16
|
+
export type McpOperationPersistence = {
|
|
17
|
+
capture: (operation: CapturedMcpOperation) => Promise<"created" | "existing">;
|
|
18
|
+
settleOriginal: (input: {
|
|
19
|
+
operationId: string;
|
|
20
|
+
outcome: "completed";
|
|
21
|
+
result: AttemptToolResult;
|
|
22
|
+
} | {
|
|
23
|
+
operationId: string;
|
|
24
|
+
outcome: "outcome_unknown";
|
|
25
|
+
}) => Promise<void>;
|
|
26
|
+
};
|
|
27
|
+
/** Presence is an execution-routing fact, not authorization. A closed context
|
|
28
|
+
* remains visible to late callbacks so they still hit the dispatch fence. */
|
|
29
|
+
export declare function hasActiveRecoverableMcpOperation(): boolean;
|
|
30
|
+
export declare class McpOperationOutcomeUnknownError extends Error {
|
|
31
|
+
readonly operationId: string;
|
|
32
|
+
readonly code = "mcp_operation_outcome_unknown";
|
|
33
|
+
constructor(operationId: string, cause: unknown);
|
|
34
|
+
}
|
|
35
|
+
/** Establish trusted in-process correlation around one gateway execution. */
|
|
36
|
+
export declare function runRecoverableMcpOperation(operation: RecoverableMcpOperation, persistence: McpOperationPersistence, execute: () => Promise<AttemptToolResult>): Promise<AttemptToolResult>;
|
|
37
|
+
/** Called by the authorized broker immediately before the physical request.
|
|
38
|
+
* A second dispatch with the same identity is never an observation. */
|
|
39
|
+
export declare function captureMcpOperationDispatch(input: {
|
|
40
|
+
operationId: string;
|
|
41
|
+
serverId: string;
|
|
42
|
+
toolName: string;
|
|
43
|
+
destinationDigest: string;
|
|
44
|
+
authorityDigest: string;
|
|
45
|
+
}): Promise<void>;
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export type McpOperationObservationAuthority = {
|
|
3
|
+
serverId: string;
|
|
4
|
+
observerTool: string;
|
|
5
|
+
destinationDigest: string;
|
|
6
|
+
authorityDigest: string;
|
|
7
|
+
};
|
|
8
|
+
/** Pin the actual broker request, not merely the earlier credential lookup. */
|
|
9
|
+
export declare function runMcpOperationObservationWithAuthority<T>(binding: McpOperationObservationAuthority, execute: () => Promise<T>): Promise<T>;
|
|
10
|
+
/** The caller is the credential broker, after live authorization and before
|
|
11
|
+
* physical tools/call dispatch. Unrelated ordinary calls remain unchanged. */
|
|
12
|
+
export declare function assertMcpOperationObservationAuthority(actual: {
|
|
13
|
+
serverId: string;
|
|
14
|
+
toolName?: string;
|
|
15
|
+
destinationDigest: string;
|
|
16
|
+
authorityDigest?: string;
|
|
17
|
+
}): void;
|
|
18
|
+
declare const receiptSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
19
|
+
version: z.ZodLiteral<1>;
|
|
20
|
+
operationRef: z.ZodString;
|
|
21
|
+
fingerprint: z.ZodObject<{
|
|
22
|
+
version: z.ZodLiteral<1>;
|
|
23
|
+
algorithm: z.ZodLiteral<"sha256">;
|
|
24
|
+
value: z.ZodString;
|
|
25
|
+
}, z.core.$strict>;
|
|
26
|
+
status: z.ZodLiteral<"unknown">;
|
|
27
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
28
|
+
version: z.ZodLiteral<1>;
|
|
29
|
+
operationRef: z.ZodString;
|
|
30
|
+
fingerprint: z.ZodObject<{
|
|
31
|
+
version: z.ZodLiteral<1>;
|
|
32
|
+
algorithm: z.ZodLiteral<"sha256">;
|
|
33
|
+
value: z.ZodString;
|
|
34
|
+
}, z.core.$strict>;
|
|
35
|
+
status: z.ZodLiteral<"pending">;
|
|
36
|
+
evidenceRevision: z.ZodString;
|
|
37
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
38
|
+
version: z.ZodLiteral<1>;
|
|
39
|
+
operationRef: z.ZodString;
|
|
40
|
+
fingerprint: z.ZodObject<{
|
|
41
|
+
version: z.ZodLiteral<1>;
|
|
42
|
+
algorithm: z.ZodLiteral<"sha256">;
|
|
43
|
+
value: z.ZodString;
|
|
44
|
+
}, z.core.$strict>;
|
|
45
|
+
status: z.ZodLiteral<"completed">;
|
|
46
|
+
receiptRevision: z.ZodString;
|
|
47
|
+
result: z.ZodObject<{
|
|
48
|
+
content: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
49
|
+
type: z.ZodLiteral<"text">;
|
|
50
|
+
text: z.ZodString;
|
|
51
|
+
annotations: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
|
|
52
|
+
_meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
|
|
53
|
+
}, z.core.$loose>, z.ZodObject<{
|
|
54
|
+
type: z.ZodLiteral<"image">;
|
|
55
|
+
data: z.ZodString;
|
|
56
|
+
mimeType: z.ZodString;
|
|
57
|
+
annotations: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
|
|
58
|
+
_meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
|
|
59
|
+
}, z.core.$loose>, z.ZodObject<{
|
|
60
|
+
type: z.ZodLiteral<"audio">;
|
|
61
|
+
data: z.ZodString;
|
|
62
|
+
mimeType: z.ZodString;
|
|
63
|
+
annotations: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
|
|
64
|
+
_meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
|
|
65
|
+
}, z.core.$loose>, z.ZodObject<{
|
|
66
|
+
type: z.ZodLiteral<"resource_link">;
|
|
67
|
+
name: z.ZodString;
|
|
68
|
+
title: z.ZodOptional<z.ZodString>;
|
|
69
|
+
uri: z.ZodString;
|
|
70
|
+
description: z.ZodOptional<z.ZodString>;
|
|
71
|
+
mimeType: z.ZodOptional<z.ZodString>;
|
|
72
|
+
size: z.ZodOptional<z.ZodNumber>;
|
|
73
|
+
icons: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
74
|
+
src: z.ZodString;
|
|
75
|
+
mimeType: z.ZodOptional<z.ZodString>;
|
|
76
|
+
sizes: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
77
|
+
theme: z.ZodOptional<z.ZodEnum<{
|
|
78
|
+
dark: "dark";
|
|
79
|
+
light: "light";
|
|
80
|
+
}>>;
|
|
81
|
+
}, z.core.$strict>>>;
|
|
82
|
+
annotations: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
|
|
83
|
+
_meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
|
|
84
|
+
}, z.core.$loose>, z.ZodObject<{
|
|
85
|
+
type: z.ZodLiteral<"resource">;
|
|
86
|
+
resource: z.ZodUnion<readonly [z.ZodObject<{
|
|
87
|
+
uri: z.ZodString;
|
|
88
|
+
mimeType: z.ZodOptional<z.ZodString>;
|
|
89
|
+
text: z.ZodString;
|
|
90
|
+
_meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
|
|
91
|
+
}, z.core.$loose>, z.ZodObject<{
|
|
92
|
+
uri: z.ZodString;
|
|
93
|
+
mimeType: z.ZodOptional<z.ZodString>;
|
|
94
|
+
blob: z.ZodString;
|
|
95
|
+
_meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
|
|
96
|
+
}, z.core.$loose>]>;
|
|
97
|
+
annotations: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
|
|
98
|
+
_meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
|
|
99
|
+
}, z.core.$loose>], "type">>;
|
|
100
|
+
structuredContent: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
|
|
101
|
+
isError: z.ZodOptional<z.ZodBoolean>;
|
|
102
|
+
_meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
|
|
103
|
+
}, z.core.$loose>;
|
|
104
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
105
|
+
version: z.ZodLiteral<1>;
|
|
106
|
+
operationRef: z.ZodString;
|
|
107
|
+
fingerprint: z.ZodObject<{
|
|
108
|
+
version: z.ZodLiteral<1>;
|
|
109
|
+
algorithm: z.ZodLiteral<"sha256">;
|
|
110
|
+
value: z.ZodString;
|
|
111
|
+
}, z.core.$strict>;
|
|
112
|
+
status: z.ZodLiteral<"conflict">;
|
|
113
|
+
}, z.core.$strict>], "status">;
|
|
114
|
+
declare const bindingSchema: z.ZodObject<{
|
|
115
|
+
operationId: z.ZodString;
|
|
116
|
+
serverId: z.ZodString;
|
|
117
|
+
originalTool: z.ZodString;
|
|
118
|
+
observerTool: z.ZodString;
|
|
119
|
+
argumentDigest: z.ZodString;
|
|
120
|
+
}, z.core.$strict>;
|
|
121
|
+
export type McpObservationBinding = z.infer<typeof bindingSchema>;
|
|
122
|
+
export type McpObservationReceipt = z.infer<typeof receiptSchema>;
|
|
123
|
+
/**
|
|
124
|
+
* One observation, never a mutation retry. This helper is deliberately not an
|
|
125
|
+
* authority resolver or a scheduler: its caller must load an immutable trusted
|
|
126
|
+
* binding and bind callObserver to that exact authorized provider destination.
|
|
127
|
+
* Tool annotations and model-supplied arguments cannot establish that trust.
|
|
128
|
+
*
|
|
129
|
+
* Durable settlement must additionally recheck authority under its own locks.
|
|
130
|
+
* A successful return alone is not a durable delivery or commit receipt.
|
|
131
|
+
*/
|
|
132
|
+
export declare function observeMcpOperation(input: {
|
|
133
|
+
binding: McpObservationBinding;
|
|
134
|
+
authorize: (phase: "before_request" | "before_delivery") => Promise<boolean>;
|
|
135
|
+
callObserver: (tool: string, args: Record<string, unknown>) => Promise<unknown>;
|
|
136
|
+
}): Promise<McpObservationReceipt>;
|
|
137
|
+
export {};
|
package/dist/sandbox/index.js
CHANGED
|
@@ -267,9 +267,9 @@ import {
|
|
|
267
267
|
withRunCredentialsClient,
|
|
268
268
|
withRunCredentialsSession,
|
|
269
269
|
withoutSandboxProviderIdentity
|
|
270
|
-
} from "../chunk-
|
|
271
|
-
import "../chunk-
|
|
272
|
-
import "../chunk-
|
|
270
|
+
} from "../chunk-VVEGJPDR.js";
|
|
271
|
+
import "../chunk-FHGLYLBL.js";
|
|
272
|
+
import "../chunk-UNICCRW5.js";
|
|
273
273
|
import "../chunk-PZ5AY32C.js";
|
|
274
274
|
export {
|
|
275
275
|
ActiveBackendUnresolvableError,
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import {
|
|
2
2
|
prepareAgentTools
|
|
3
|
-
} from "./chunk-
|
|
4
|
-
import "./chunk-
|
|
5
|
-
import "./chunk-
|
|
3
|
+
} from "./chunk-SD6MDONS.js";
|
|
4
|
+
import "./chunk-VVEGJPDR.js";
|
|
5
|
+
import "./chunk-FHGLYLBL.js";
|
|
6
6
|
import "./chunk-GB763TSV.js";
|
|
7
7
|
import "./chunk-UZ66CGC2.js";
|
|
8
8
|
import "./chunk-JHM4OS7C.js";
|
|
9
|
-
import "./chunk-
|
|
9
|
+
import "./chunk-UNICCRW5.js";
|
|
10
10
|
import "./chunk-PZ5AY32C.js";
|
|
11
11
|
export {
|
|
12
12
|
prepareAgentTools as prepareWorkspaceToolGatewayTools
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@opengeni/runtime",
|
|
3
|
-
"version": "2.5.
|
|
3
|
+
"version": "2.5.3-canary.0",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -62,16 +62,16 @@
|
|
|
62
62
|
"@openai/agents": "0.14.3",
|
|
63
63
|
"@openai/agents-core": "0.14.3",
|
|
64
64
|
"@openai/agents-extensions": "0.14.3",
|
|
65
|
-
"@opengeni/agent-proto": "^0.5.1-canary.
|
|
66
|
-
"@opengeni/capabilities": "^0.3.3-canary.
|
|
67
|
-
"@opengeni/codemode": "^0.5.
|
|
68
|
-
"@opengeni/codex": "^0.2.22-canary.
|
|
69
|
-
"@opengeni/config": "^1.1.
|
|
70
|
-
"@opengeni/contracts": "^3.0.
|
|
71
|
-
"@opengeni/network": "^0.3.1-canary.
|
|
72
|
-
"@opengeni/sdk": "^5.0.
|
|
73
|
-
"@opengeni/tool-gateway": "^0.1.
|
|
74
|
-
"@opengeni/xai-subscription": "^0.1.4-canary.
|
|
65
|
+
"@opengeni/agent-proto": "^0.5.1-canary.26",
|
|
66
|
+
"@opengeni/capabilities": "^0.3.3-canary.8",
|
|
67
|
+
"@opengeni/codemode": "^0.5.6-canary.0",
|
|
68
|
+
"@opengeni/codex": "^0.2.22-canary.8",
|
|
69
|
+
"@opengeni/config": "^1.1.2-canary.0",
|
|
70
|
+
"@opengeni/contracts": "^3.0.2-canary.0",
|
|
71
|
+
"@opengeni/network": "^0.3.1-canary.8",
|
|
72
|
+
"@opengeni/sdk": "^5.0.5-canary.0",
|
|
73
|
+
"@opengeni/tool-gateway": "^0.1.7-canary.0",
|
|
74
|
+
"@opengeni/xai-subscription": "^0.1.4-canary.8",
|
|
75
75
|
"debug": "4.4.3",
|
|
76
76
|
"modal": "0.9.0",
|
|
77
77
|
"openai": "6.47.0",
|