@openclaw/codex 2026.6.9 → 2026.6.10-beta.1
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/{attempt-notifications-7oZeRa71.js → attempt-notifications-C3zROmkk.js} +1 -1
- package/dist/{command-handlers-BaqM9s9b.js → command-handlers-CLJjbqL9.js} +3 -3
- package/dist/{computer-use-BmuwYrW6.js → computer-use-BViK8fu1.js} +1 -1
- package/dist/{conversation-binding-DbG2ZJQY.js → conversation-binding-CndXa45M.js} +2 -2
- package/dist/harness.js +2 -2
- package/dist/index.js +6 -6
- package/dist/{media-understanding-provider-Dmfg4tH_.js → media-understanding-provider-DSQ2ry-4.js} +2 -2
- package/dist/media-understanding-provider.js +1 -1
- package/dist/{plugin-app-cache-key-vaZ_8Usz.js → plugin-app-cache-key-DX14mGOE.js} +1 -1
- package/dist/{provider-capabilities-ByR82ytL.js → provider-capabilities-D2Ee9YEI.js} +1 -1
- package/dist/{run-attempt-DYt00Jxz.js → run-attempt-4z6t1PlH.js} +73 -20
- package/dist/{side-question-h01W1aCe.js → side-question-BO7GbMFO.js} +2 -2
- package/dist/{thread-lifecycle-DQyii5vp.js → thread-lifecycle-CJdHuthD.js} +18 -2
- package/dist/{web-search-provider.runtime-BWG_oqLf.js → web-search-provider.runtime-CMEYazjn.js} +2 -2
- package/npm-shrinkwrap.json +2 -2
- package/package.json +4 -4
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { n as isJsonObject } from "./protocol-dh-ETiNd.js";
|
|
2
|
-
import { B as isCodexNotificationForTurn } from "./thread-lifecycle-
|
|
2
|
+
import { B as isCodexNotificationForTurn } from "./thread-lifecycle-CJdHuthD.js";
|
|
3
3
|
import { asBoolean } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
4
4
|
//#region extensions/codex/src/app-server/attempt-notifications.ts
|
|
5
5
|
/**
|
|
@@ -3,12 +3,12 @@ import { d as resolveCodexAppServerRuntimeOptions, o as isCodexFastServiceTier }
|
|
|
3
3
|
import { n as listCodexAppServerModels, t as listAllCodexAppServerModels } from "./models-CAmfBWRl.js";
|
|
4
4
|
import { l as summarizeCodexAccountUsage } from "./provider-B-OHpbD3.js";
|
|
5
5
|
import { l as writeCodexAppServerBinding, n as clearCodexAppServerBinding, o as readCodexAppServerBinding } from "./session-binding-HOuPt-E0.js";
|
|
6
|
-
import { i as describeControlFailure, r as CODEX_CONTROL_METHODS } from "./plugin-app-cache-key-
|
|
6
|
+
import { i as describeControlFailure, r as CODEX_CONTROL_METHODS } from "./plugin-app-cache-key-DX14mGOE.js";
|
|
7
7
|
import { a as formatCodexDisplayText, c as formatList, d as formatThreads, f as readString$1, i as formatAccount, l as formatModels, o as formatCodexStatus, r as buildHelp, s as formatComputerUseStatus, u as formatSkills } from "./app-server-policy-BPTiVNsW.js";
|
|
8
8
|
import { n as resolveCodexNativeExecutionBlock, r as resolveCodexNativeSandboxBlock } from "./sandbox-guard-3tnjhjFb.js";
|
|
9
|
-
import { _ as steerCodexConversationTurn, b as readCodexConversationBindingData, d as parseCodexFastModeArg, f as parseCodexPermissionsModeArg, g as setCodexConversationPermissions, h as setCodexConversationModel, m as setCodexConversationFastMode, o as formatCodexCliSessions, p as readCodexConversationActiveTurn, r as startCodexConversationThread, u as formatPermissionsMode, v as stopCodexConversationTurn, x as resolveCodexDefaultWorkspaceDir, y as createCodexCliNodeConversationBindingData } from "./conversation-binding-
|
|
9
|
+
import { _ as steerCodexConversationTurn, b as readCodexConversationBindingData, d as parseCodexFastModeArg, f as parseCodexPermissionsModeArg, g as setCodexConversationPermissions, h as setCodexConversationModel, m as setCodexConversationFastMode, o as formatCodexCliSessions, p as readCodexConversationActiveTurn, r as startCodexConversationThread, u as formatPermissionsMode, v as stopCodexConversationTurn, x as resolveCodexDefaultWorkspaceDir, y as createCodexCliNodeConversationBindingData } from "./conversation-binding-CndXa45M.js";
|
|
10
10
|
import { t as requestCodexAppServerJson } from "./request-Dcd452Nk.js";
|
|
11
|
-
import { n as installCodexComputerUse, r as readCodexComputerUseStatus } from "./computer-use-
|
|
11
|
+
import { n as installCodexComputerUse, r as readCodexComputerUseStatus } from "./computer-use-BViK8fu1.js";
|
|
12
12
|
import { n as rememberCodexRateLimits } from "./rate-limit-cache-C7qmZ0Jh.js";
|
|
13
13
|
import { parseStrictPositiveInteger } from "openclaw/plugin-sdk/number-runtime";
|
|
14
14
|
import { normalizeOptionalString, normalizeUniqueStringEntries } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { d as resolveCodexAppServerRuntimeOptions, f as resolveCodexComputerUseConfig } from "./config-CszD0vP3.js";
|
|
2
|
-
import { i as describeControlFailure } from "./plugin-app-cache-key-
|
|
2
|
+
import { i as describeControlFailure } from "./plugin-app-cache-key-DX14mGOE.js";
|
|
3
3
|
import { t as requestCodexAppServerJson } from "./request-Dcd452Nk.js";
|
|
4
4
|
import { existsSync } from "node:fs";
|
|
5
5
|
//#region extensions/codex/src/app-server/computer-use.ts
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { n as isJsonObject } from "./protocol-dh-ETiNd.js";
|
|
2
|
-
import { H as readCodexNotificationTurnId, V as readCodexNotificationThreadId, d as resolveCodexAppServerRequestModelSelection, p as resolveCodexBindingModelProviderFallback, t as CODEX_NATIVE_PERSONALITY_NONE } from "./thread-lifecycle-
|
|
2
|
+
import { H as readCodexNotificationTurnId, V as readCodexNotificationThreadId, d as resolveCodexAppServerRequestModelSelection, p as resolveCodexBindingModelProviderFallback, t as CODEX_NATIVE_PERSONALITY_NONE } from "./thread-lifecycle-CJdHuthD.js";
|
|
3
3
|
import { d as resolveCodexAppServerRuntimeOptions, h as resolveOpenClawExecPolicyForCodexAppServer, i as codexSandboxPolicyForTurn, n as canUseCodexModelBackedApprovalsReviewerForModel, o as isCodexFastServiceTier, p as resolveCodexModelBackedReviewerPolicyContext } from "./config-CszD0vP3.js";
|
|
4
4
|
import { r as assertCodexThreadStartResponse } from "./protocol-validators-B19q5BIX.js";
|
|
5
5
|
import { a as normalizeCodexAppServerBindingModelProvider, i as isCodexAppServerNativeAuthProfile, l as writeCodexAppServerBinding, n as clearCodexAppServerBinding, o as readCodexAppServerBinding } from "./session-binding-HOuPt-E0.js";
|
|
6
|
-
import { r as CODEX_CONTROL_METHODS } from "./plugin-app-cache-key-
|
|
6
|
+
import { r as CODEX_CONTROL_METHODS } from "./plugin-app-cache-key-DX14mGOE.js";
|
|
7
7
|
import { a as formatCodexDisplayText, t as resolveCodexAppServerForModelProvider } from "./app-server-policy-BPTiVNsW.js";
|
|
8
8
|
import { a as getLeasedSharedCodexAppServerClient, o as releaseLeasedSharedCodexAppServerClient, p as resolveCodexAppServerAuthProfileIdForAgent } from "./shared-client-Dtx5i7Ez.js";
|
|
9
9
|
import { n as resolveCodexNativeExecutionBlock, r as resolveCodexNativeSandboxBlock } from "./sandbox-guard-3tnjhjFb.js";
|
package/dist/harness.js
CHANGED
|
@@ -32,14 +32,14 @@ function createCodexAppServerAgentHarness(options) {
|
|
|
32
32
|
};
|
|
33
33
|
},
|
|
34
34
|
runAttempt: async (params) => {
|
|
35
|
-
const { runCodexAppServerAttempt } = await import("./run-attempt-
|
|
35
|
+
const { runCodexAppServerAttempt } = await import("./run-attempt-4z6t1PlH.js");
|
|
36
36
|
return runCodexAppServerAttempt(params, {
|
|
37
37
|
pluginConfig: options?.resolvePluginConfig?.() ?? options?.pluginConfig,
|
|
38
38
|
nativeHookRelay: { enabled: true }
|
|
39
39
|
});
|
|
40
40
|
},
|
|
41
41
|
runSideQuestion: async (params) => {
|
|
42
|
-
const { runCodexAppServerSideQuestion } = await import("./side-question-
|
|
42
|
+
const { runCodexAppServerSideQuestion } = await import("./side-question-BO7GbMFO.js");
|
|
43
43
|
return runCodexAppServerSideQuestion(params, {
|
|
44
44
|
pluginConfig: options?.resolvePluginConfig?.() ?? options?.pluginConfig,
|
|
45
45
|
nativeHookRelay: { enabled: true }
|
package/dist/index.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { createCodexAppServerAgentHarness } from "./harness.js";
|
|
2
|
-
import { F as ensureCodexPluginActivation, I as pluginReadParams, R as defaultCodexAppInventoryCache } from "./thread-lifecycle-
|
|
2
|
+
import { F as ensureCodexPluginActivation, I as pluginReadParams, R as defaultCodexAppInventoryCache } from "./thread-lifecycle-CJdHuthD.js";
|
|
3
3
|
import { d as resolveCodexAppServerRuntimeOptions, t as CODEX_PLUGINS_MARKETPLACE_NAME, u as readCodexPluginConfig } from "./config-CszD0vP3.js";
|
|
4
4
|
import { t as buildCodexProvider } from "./provider-B-OHpbD3.js";
|
|
5
|
-
import { t as buildCodexMediaUnderstandingProvider } from "./media-understanding-provider-
|
|
6
|
-
import { i as describeControlFailure, n as buildCodexPluginAppCacheKey } from "./plugin-app-cache-key-
|
|
5
|
+
import { t as buildCodexMediaUnderstandingProvider } from "./media-understanding-provider-DSQ2ry-4.js";
|
|
6
|
+
import { i as describeControlFailure, n as buildCodexPluginAppCacheKey } from "./plugin-app-cache-key-DX14mGOE.js";
|
|
7
7
|
import { a as formatCodexDisplayText } from "./app-server-policy-BPTiVNsW.js";
|
|
8
8
|
import { a as getLeasedSharedCodexAppServerClient, d as resolveCodexAppServerAuthAccountCacheKey, m as resolveCodexAppServerFallbackApiKeyCacheKey, o as releaseLeasedSharedCodexAppServerClient, p as resolveCodexAppServerAuthProfileIdForAgent, r as clearSharedCodexAppServerClientIfCurrentAndWait } from "./shared-client-Dtx5i7Ez.js";
|
|
9
|
-
import { a as createCodexCliSessionNodeInvokePolicies, c as resolveCodexCliSessionForBindingOnNode, i as createCodexCliSessionNodeHostCommands, l as resumeCodexCliSessionOnNode, n as handleCodexConversationInboundClaim, s as listCodexCliSessionsOnNode, t as handleCodexConversationBindingResolved } from "./conversation-binding-
|
|
9
|
+
import { a as createCodexCliSessionNodeInvokePolicies, c as resolveCodexCliSessionForBindingOnNode, i as createCodexCliSessionNodeHostCommands, l as resumeCodexCliSessionOnNode, n as handleCodexConversationInboundClaim, s as listCodexCliSessionsOnNode, t as handleCodexConversationBindingResolved } from "./conversation-binding-CndXa45M.js";
|
|
10
10
|
import { t as requestCodexAppServerJson } from "./request-Dcd452Nk.js";
|
|
11
11
|
import { t as createCodexWebSearchProviderBase } from "./web-search-provider.shared-BrZmlqyR.js";
|
|
12
12
|
import { mutateConfigFile } from "openclaw/plugin-sdk/config-mutation";
|
|
@@ -52,7 +52,7 @@ async function handleCodexCommand(ctx, options = {}) {
|
|
|
52
52
|
}
|
|
53
53
|
}
|
|
54
54
|
async function loadDefaultCodexSubcommandHandler() {
|
|
55
|
-
const { handleCodexSubcommand } = await import("./command-handlers-
|
|
55
|
+
const { handleCodexSubcommand } = await import("./command-handlers-CLJjbqL9.js");
|
|
56
56
|
return handleCodexSubcommand;
|
|
57
57
|
}
|
|
58
58
|
//#endregion
|
|
@@ -1542,7 +1542,7 @@ function buildCodexMigrationProvider(params = {}) {
|
|
|
1542
1542
|
//#region extensions/codex/src/web-search-provider.ts
|
|
1543
1543
|
let codexWebSearchRuntimePromise;
|
|
1544
1544
|
function loadCodexWebSearchRuntime() {
|
|
1545
|
-
codexWebSearchRuntimePromise ??= import("./web-search-provider.runtime-
|
|
1545
|
+
codexWebSearchRuntimePromise ??= import("./web-search-provider.runtime-CMEYazjn.js");
|
|
1546
1546
|
return codexWebSearchRuntimePromise;
|
|
1547
1547
|
}
|
|
1548
1548
|
const CodexWebSearchSchema = {
|
package/dist/{media-understanding-provider-Dmfg4tH_.js → media-understanding-provider-DSQ2ry-4.js}
RENAMED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { CODEX_PROVIDER_ID, FALLBACK_CODEX_MODELS } from "./provider-catalog.js";
|
|
2
2
|
import { n as isJsonObject } from "./protocol-dh-ETiNd.js";
|
|
3
|
-
import { N as mergeCodexThreadConfigs, r as buildCodexRuntimeThreadConfig } from "./thread-lifecycle-
|
|
4
|
-
import { S as readCodexNotificationItem } from "./attempt-notifications-
|
|
3
|
+
import { N as mergeCodexThreadConfigs, r as buildCodexRuntimeThreadConfig } from "./thread-lifecycle-CJdHuthD.js";
|
|
4
|
+
import { S as readCodexNotificationItem } from "./attempt-notifications-C3zROmkk.js";
|
|
5
5
|
import { d as resolveCodexAppServerRuntimeOptions } from "./config-CszD0vP3.js";
|
|
6
6
|
import { i as assertCodexTurnStartResponse, l as readCodexTurnCompletedNotification, o as readCodexErrorNotification, r as assertCodexThreadStartResponse } from "./protocol-validators-B19q5BIX.js";
|
|
7
7
|
import { i as readModelListResult } from "./models-CAmfBWRl.js";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as buildCodexMediaUnderstandingProvider } from "./media-understanding-provider-
|
|
1
|
+
import { t as buildCodexMediaUnderstandingProvider } from "./media-understanding-provider-DSQ2ry-4.js";
|
|
2
2
|
export { buildCodexMediaUnderstandingProvider };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { L as buildCodexAppInventoryCacheKey } from "./thread-lifecycle-
|
|
1
|
+
import { L as buildCodexAppInventoryCacheKey } from "./thread-lifecycle-CJdHuthD.js";
|
|
2
2
|
import { n as CodexAppServerRpcError } from "./client-CLrtWgrD.js";
|
|
3
3
|
import { h as resolveCodexAppServerHomeDir } from "./shared-client-Dtx5i7Ez.js";
|
|
4
4
|
import { createHash } from "node:crypto";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { n as isJsonObject } from "./protocol-dh-ETiNd.js";
|
|
2
|
-
import { C as isForcedPrivateQaCodexRuntime, S as filterCodexDynamicTools, _ as resolveCodexWebSearchPlan, w as normalizeCodexDynamicToolName, x as sanitizeInlineImageDataUrl, y as invalidInlineImageText } from "./thread-lifecycle-
|
|
2
|
+
import { C as isForcedPrivateQaCodexRuntime, S as filterCodexDynamicTools, _ as resolveCodexWebSearchPlan, w as normalizeCodexDynamicToolName, x as sanitizeInlineImageDataUrl, y as invalidInlineImageText } from "./thread-lifecycle-CJdHuthD.js";
|
|
3
3
|
import { c as isTrustedCodexModelBackedOpenAIProvider, u as readCodexPluginConfig } from "./config-CszD0vP3.js";
|
|
4
4
|
import { a as formatCodexDisplayText } from "./app-server-policy-BPTiVNsW.js";
|
|
5
5
|
import { o as releaseLeasedSharedCodexAppServerClient } from "./shared-client-Dtx5i7Ez.js";
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import { n as isJsonObject, t as flattenCodexDynamicToolFunctions } from "./protocol-dh-ETiNd.js";
|
|
2
|
-
import { A as resolveCodexContextEngineProjectionReserveTokens, D as fitCodexProjectedContextForTurnStart, E as resolveCodexDynamicToolsLoadingForRuntime, H as readCodexNotificationTurnId, M as buildCodexPluginThreadConfigInputFingerprint, N as mergeCodexThreadConfigs, O as projectContextEngineAssemblyForCodex, P as shouldBuildCodexPluginThreadConfig, R as defaultCodexAppInventoryCache, V as readCodexNotificationThreadId, _ as resolveCodexWebSearchPlan, a as buildDeveloperInstructions, b as sanitizeCodexHistoryImagePayloads, c as codexDynamicToolsFingerprint, f as resolveCodexAppServerThreadModelSelection, h as startOrResumeThread, i as buildContextEngineBinding, j as buildCodexPluginThreadConfig, k as resolveCodexContextEngineProjectionMaxChars, l as isContextEngineBindingCompatible, n as areCodexDynamicToolFingerprintsCompatible, o as buildTurnCollaborationMode, s as buildTurnStartParams, v as isCodexAppServerProfilerEnabled, z as describeCodexNotificationCorrelation } from "./thread-lifecycle-
|
|
3
|
-
import { C as readNotificationItemId, E as updateActiveTurnItemIds, S as readCodexNotificationItem, T as shouldDisarmAssistantCompletionIdleWatch, _ as isReasoningItemCompletionNotification, a as isCodexNotificationOutsideActiveRun, b as isTerminalTurnStatus, c as isCurrentThreadOptionalTurnRequestParams, d as isNativeResponseStreamDeltaNotification, f as isNativeToolProgressNotification, g as isRawToolOutputCompletionNotification, h as isRawReasoningCompletionNotification, i as isAssistantCompletionReleaseNotification, l as isCurrentThreadTurnRequestParams, m as isRawAssistantProgressNotification, n as describeNotificationActivity, o as isCodexTurnAbortMarkerNotification, p as isPendingOpenClawDynamicToolCompletionNotification, r as isAssistantCommentaryCompletionNotification, s as isCurrentApprovalTurnRequestParams, t as codexExecutionToolName, u as isFileChangePatchUpdatedNotification, v as isReasoningProgressNotification, w as readRawResponseToolCallId, x as isTurnNotification, y as isRetryableErrorNotification } from "./attempt-notifications-
|
|
2
|
+
import { A as resolveCodexContextEngineProjectionReserveTokens, D as fitCodexProjectedContextForTurnStart, E as resolveCodexDynamicToolsLoadingForRuntime, H as readCodexNotificationTurnId, M as buildCodexPluginThreadConfigInputFingerprint, N as mergeCodexThreadConfigs, O as projectContextEngineAssemblyForCodex, P as shouldBuildCodexPluginThreadConfig, R as defaultCodexAppInventoryCache, V as readCodexNotificationThreadId, _ as resolveCodexWebSearchPlan, a as buildDeveloperInstructions, b as sanitizeCodexHistoryImagePayloads, c as codexDynamicToolsFingerprint, f as resolveCodexAppServerThreadModelSelection, h as startOrResumeThread, i as buildContextEngineBinding, j as buildCodexPluginThreadConfig, k as resolveCodexContextEngineProjectionMaxChars, l as isContextEngineBindingCompatible, n as areCodexDynamicToolFingerprintsCompatible, o as buildTurnCollaborationMode, s as buildTurnStartParams, v as isCodexAppServerProfilerEnabled, z as describeCodexNotificationCorrelation } from "./thread-lifecycle-CJdHuthD.js";
|
|
3
|
+
import { C as readNotificationItemId, E as updateActiveTurnItemIds, S as readCodexNotificationItem, T as shouldDisarmAssistantCompletionIdleWatch, _ as isReasoningItemCompletionNotification, a as isCodexNotificationOutsideActiveRun, b as isTerminalTurnStatus, c as isCurrentThreadOptionalTurnRequestParams, d as isNativeResponseStreamDeltaNotification, f as isNativeToolProgressNotification, g as isRawToolOutputCompletionNotification, h as isRawReasoningCompletionNotification, i as isAssistantCompletionReleaseNotification, l as isCurrentThreadTurnRequestParams, m as isRawAssistantProgressNotification, n as describeNotificationActivity, o as isCodexTurnAbortMarkerNotification, p as isPendingOpenClawDynamicToolCompletionNotification, r as isAssistantCommentaryCompletionNotification, s as isCurrentApprovalTurnRequestParams, t as codexExecutionToolName, u as isFileChangePatchUpdatedNotification, v as isReasoningProgressNotification, w as readRawResponseToolCallId, x as isTurnNotification, y as isRetryableErrorNotification } from "./attempt-notifications-C3zROmkk.js";
|
|
4
4
|
import { _ as withMcpElicitationsApprovalPolicy, a as isCodexAppServerApprovalPolicyAllowedByRequirements, d as resolveCodexAppServerRuntimeOptions, f as resolveCodexComputerUseConfig, g as shouldAutoApproveCodexAppServerApprovals, h as resolveOpenClawExecPolicyForCodexAppServer, m as resolveCodexPluginsPolicy, p as resolveCodexModelBackedReviewerPolicyContext, s as isCodexSandboxExecServerEnabled, u as readCodexPluginConfig } from "./config-CszD0vP3.js";
|
|
5
5
|
import { a as readCodexDynamicToolCallParams, c as readCodexTurn, i as assertCodexTurnStartResponse } from "./protocol-validators-B19q5BIX.js";
|
|
6
6
|
import { i as formatCodexUsageLimitErrorMessage, o as resolveCodexUsageLimitResetAtMs, s as shouldRefreshCodexRateLimitsForUsageLimitMessage } from "./provider-B-OHpbD3.js";
|
|
7
7
|
import { a as isCodexAppServerConnectionClosedError, i as isCodexAppServerApprovalRequest, n as CodexAppServerRpcError, r as compareCodexAppServerVersions, s as MIN_CODEX_SANDBOX_EXEC_SERVER_APP_SERVER_VERSION } from "./client-CLrtWgrD.js";
|
|
8
8
|
import { i as isCodexAppServerNativeAuthProfile, l as writeCodexAppServerBinding, n as clearCodexAppServerBinding, o as readCodexAppServerBinding, r as clearCodexAppServerBindingForThread } from "./session-binding-HOuPt-E0.js";
|
|
9
|
-
import { n as buildCodexPluginAppCacheKey, r as CODEX_CONTROL_METHODS, t as buildCodexAppServerRuntimeFingerprint } from "./plugin-app-cache-key-
|
|
9
|
+
import { n as buildCodexPluginAppCacheKey, r as CODEX_CONTROL_METHODS, t as buildCodexAppServerRuntimeFingerprint } from "./plugin-app-cache-key-DX14mGOE.js";
|
|
10
10
|
import { a as formatCodexDisplayText, n as resolveCodexAppServerForOpenClawToolPolicy, t as resolveCodexAppServerForModelProvider } from "./app-server-policy-BPTiVNsW.js";
|
|
11
11
|
import { d as resolveCodexAppServerAuthAccountCacheKey, f as resolveCodexAppServerAuthProfileId, h as resolveCodexAppServerHomeDir, m as resolveCodexAppServerFallbackApiKeyCacheKey, n as clearSharedCodexAppServerClientIfCurrentAndUnclaimed, o as releaseLeasedSharedCodexAppServerClient, p as resolveCodexAppServerAuthProfileIdForAgent, s as retireSharedCodexAppServerClientIfCurrent, t as clearSharedCodexAppServerClientIfCurrent, u as refreshCodexAppServerAuthTokens } from "./shared-client-Dtx5i7Ez.js";
|
|
12
12
|
import { t as defaultLeasedCodexAppServerClientFactory } from "./client-factory-Bm6HsGob.js";
|
|
13
|
-
import { A as CODEX_POST_REASONING_REPLY_IDLE_TIMEOUT_MS, C as resolveCodexMessageToolProvider, D as shouldWarnCodexDynamicToolBuildStageSummary, E as shouldRequireCodexSandboxExecServerEnvironment, F as resolveCodexTurnTerminalIdleTimeoutMs, I as withCodexStartupTimeout, M as resolveCodexStartupTimeoutMs, N as resolveCodexTurnAssistantCompletionIdleTimeoutMs, P as resolveCodexTurnCompletionIdleTimeoutMs, S as resolveCodexExternalSandboxPolicyForOpenClawSandbox, T as shouldEnableCodexAppServerNativeToolSurface, _ as createCodexDynamicToolBuildStageTracker, a as buildCodexNativeHookRelayConfig, b as resolveCodexAppServerExecutionCwd, c as resolveCodexNativeHookRelayEvents, d as handleCodexAppServerElicitationRequest, f as createCodexDynamicToolBridge, g as buildDynamicTools, h as emitDynamicToolTerminalDiagnostic, i as CODEX_NATIVE_HOOK_RELAY_TTL_GRACE_MS, j as resolveCodexPostToolRawAssistantCompletionIdleTimeoutMs, k as handleCodexAppServerApprovalRequest, l as resolveCodexNativeHookRelayTtlMs, m as emitDynamicToolStartedDiagnostic, o as buildCodexNativeHookRelayDisabledConfig, p as emitDynamicToolErrorDiagnostic, s as createCodexNativeHookRelay, t as resolveCodexProviderWebSearchSupport, u as scheduleCodexNativeHookRelayUnregister, v as disableCodexPluginThreadConfig, w as resolveCodexSandboxEnvironmentSelection, x as resolveCodexAppServerHookChannelId, y as formatCodexDynamicToolBuildStageSummary } from "./provider-capabilities-
|
|
14
|
-
import { t as ensureCodexComputerUse } from "./computer-use-
|
|
13
|
+
import { A as CODEX_POST_REASONING_REPLY_IDLE_TIMEOUT_MS, C as resolveCodexMessageToolProvider, D as shouldWarnCodexDynamicToolBuildStageSummary, E as shouldRequireCodexSandboxExecServerEnvironment, F as resolveCodexTurnTerminalIdleTimeoutMs, I as withCodexStartupTimeout, M as resolveCodexStartupTimeoutMs, N as resolveCodexTurnAssistantCompletionIdleTimeoutMs, P as resolveCodexTurnCompletionIdleTimeoutMs, S as resolveCodexExternalSandboxPolicyForOpenClawSandbox, T as shouldEnableCodexAppServerNativeToolSurface, _ as createCodexDynamicToolBuildStageTracker, a as buildCodexNativeHookRelayConfig, b as resolveCodexAppServerExecutionCwd, c as resolveCodexNativeHookRelayEvents, d as handleCodexAppServerElicitationRequest, f as createCodexDynamicToolBridge, g as buildDynamicTools, h as emitDynamicToolTerminalDiagnostic, i as CODEX_NATIVE_HOOK_RELAY_TTL_GRACE_MS, j as resolveCodexPostToolRawAssistantCompletionIdleTimeoutMs, k as handleCodexAppServerApprovalRequest, l as resolveCodexNativeHookRelayTtlMs, m as emitDynamicToolStartedDiagnostic, o as buildCodexNativeHookRelayDisabledConfig, p as emitDynamicToolErrorDiagnostic, s as createCodexNativeHookRelay, t as resolveCodexProviderWebSearchSupport, u as scheduleCodexNativeHookRelayUnregister, v as disableCodexPluginThreadConfig, w as resolveCodexSandboxEnvironmentSelection, x as resolveCodexAppServerHookChannelId, y as formatCodexDynamicToolBuildStageSummary } from "./provider-capabilities-D2Ee9YEI.js";
|
|
14
|
+
import { t as ensureCodexComputerUse } from "./computer-use-BViK8fu1.js";
|
|
15
15
|
import { n as rememberCodexRateLimits, t as readRecentCodexRateLimits } from "./rate-limit-cache-C7qmZ0Jh.js";
|
|
16
16
|
import fs from "node:fs/promises";
|
|
17
17
|
import path, { posix } from "node:path";
|
|
@@ -21,7 +21,7 @@ import { createHash, randomUUID } from "node:crypto";
|
|
|
21
21
|
import fsSync from "node:fs";
|
|
22
22
|
import { markAuthProfileBlockedUntil, resolveAgentDir, resolveAgentWorkspaceDir } from "openclaw/plugin-sdk/agent-runtime";
|
|
23
23
|
import { loadExecApprovals } from "openclaw/plugin-sdk/exec-approvals-runtime";
|
|
24
|
-
import { CODEX_APP_SERVER_CONTEXT_ENGINE_HOST, TOOL_PROGRESS_OUTPUT_MAX_CHARS, acquireSessionWriteLock, appendSessionTranscriptMessage, assembleHarnessContextEngine, assertContextEngineHostSupport,
|
|
24
|
+
import { CODEX_APP_SERVER_CONTEXT_ENGINE_HOST, TOOL_PROGRESS_OUTPUT_MAX_CHARS, acquireSessionWriteLock, appendSessionTranscriptMessage, assembleHarnessContextEngine, assertContextEngineHostSupport, awaitAgentEndSideEffects, bootstrapHarnessContextEngine, buildBootstrapContextForFiles, buildHarnessContextEngineRuntimeContext, buildHarnessContextEngineRuntimeContextFromUsage, classifyAgentHarnessTerminalOutcome, clearActiveEmbeddedRun, embeddedAgentLog, emitAgentEvent, emitSessionTranscriptUpdate, finalizeHarnessContextEngineTurn, formatErrorMessage, formatToolAggregate, formatToolProgressOutput, getAgentHarnessHookRunner, getBeforeToolCallPolicyDiagnosticState, inferToolMetaFromArgs, isActiveHarnessContextEngine, loadCodexBundleMcpThreadConfig, normalizeUsage, resolveAgentHarnessBeforePromptBuildResult, resolveBootstrapFilesForRun, resolveContextEngineOwnerPluginId, resolveSandboxContext, resolveSessionAgentIds as resolveSessionAgentIds$1, resolveSessionWriteLockOptions, resolveUserPath, runAgentCleanupStep, runAgentEndSideEffects, runAgentHarnessAfterCompactionHook, runAgentHarnessAfterToolCallHook, runAgentHarnessBeforeCompactionHook, runAgentHarnessBeforeMessageWriteHook, runAgentHarnessLlmInputHook, runAgentHarnessLlmOutputHook, runHarnessContextEngineMaintenance, setActiveEmbeddedRun, supportsModelTools } from "openclaw/plugin-sdk/agent-harness-runtime";
|
|
25
25
|
import { buildMemorySystemPromptAddition } from "openclaw/plugin-sdk/core";
|
|
26
26
|
import { spawn } from "node:child_process";
|
|
27
27
|
import { once } from "node:events";
|
|
@@ -528,6 +528,25 @@ function prependCodexOpenClawPromptContext(prompt, context, options = {}) {
|
|
|
528
528
|
promptSection
|
|
529
529
|
].filter(Boolean).join("\n\n");
|
|
530
530
|
}
|
|
531
|
+
/**
|
|
532
|
+
* Maps the surviving user-request portion of an input range after delivery
|
|
533
|
+
* metadata has been relocated before the request.
|
|
534
|
+
*/
|
|
535
|
+
function resolveCodexDeliveryHintPreservedInputRange(params) {
|
|
536
|
+
const { prompt, promptInputRange, decoratedPrompt } = params;
|
|
537
|
+
const { deliveryHint, prompt: promptWithoutDeliveryHint } = splitLeadingCodexDeliveryHint(prompt);
|
|
538
|
+
if (!deliveryHint || !promptInputRange || promptInputRange.start < 0 || promptInputRange.end < promptInputRange.start || promptInputRange.end > prompt.length || !decoratedPrompt.endsWith(promptWithoutDeliveryHint)) return;
|
|
539
|
+
const promptWithoutDeliveryHintStart = prompt.length - promptWithoutDeliveryHint.length;
|
|
540
|
+
const inputStart = Math.max(promptInputRange.start, promptWithoutDeliveryHintStart);
|
|
541
|
+
const inputEnd = Math.max(inputStart, Math.min(promptInputRange.end, promptWithoutDeliveryHint.length + promptWithoutDeliveryHintStart));
|
|
542
|
+
const decoratedPromptSuffixStart = decoratedPrompt.length - promptWithoutDeliveryHint.length;
|
|
543
|
+
const requestHeader = "Current user request:\n";
|
|
544
|
+
const requestHeaderStart = decoratedPromptSuffixStart - 22;
|
|
545
|
+
return {
|
|
546
|
+
start: inputStart === promptWithoutDeliveryHintStart && decoratedPrompt.slice(requestHeaderStart, decoratedPromptSuffixStart) === requestHeader ? requestHeaderStart : decoratedPromptSuffixStart + inputStart - promptWithoutDeliveryHintStart,
|
|
547
|
+
end: decoratedPromptSuffixStart + inputEnd - promptWithoutDeliveryHintStart
|
|
548
|
+
};
|
|
549
|
+
}
|
|
531
550
|
function splitLeadingCodexDeliveryHint(prompt) {
|
|
532
551
|
const trimmedStart = prompt.trimStart();
|
|
533
552
|
const matchedHint = MESSAGE_TOOL_DELIVERY_HINTS.find((hint) => trimmedStart.startsWith(hint));
|
|
@@ -7651,11 +7670,18 @@ function shouldAwaitCodexAgentEndHook(params) {
|
|
|
7651
7670
|
return !params.messageChannel && !params.messageProvider;
|
|
7652
7671
|
}
|
|
7653
7672
|
async function runCodexAgentEndHook(params, hookParams) {
|
|
7673
|
+
const sideEffectParams = {
|
|
7674
|
+
...hookParams,
|
|
7675
|
+
ctx: {
|
|
7676
|
+
...hookParams.ctx,
|
|
7677
|
+
config: params.config
|
|
7678
|
+
}
|
|
7679
|
+
};
|
|
7654
7680
|
if (shouldAwaitCodexAgentEndHook(params)) {
|
|
7655
|
-
await
|
|
7681
|
+
await awaitAgentEndSideEffects(sideEffectParams);
|
|
7656
7682
|
return;
|
|
7657
7683
|
}
|
|
7658
|
-
|
|
7684
|
+
runAgentEndSideEffects(sideEffectParams);
|
|
7659
7685
|
}
|
|
7660
7686
|
async function runCodexAppServerAttempt(params, options = {}) {
|
|
7661
7687
|
const attemptStartedAt = Date.now();
|
|
@@ -8147,26 +8173,52 @@ async function runCodexAppServerAttempt(params, options = {}) {
|
|
|
8147
8173
|
prompt: prependCurrentInboundContext(promptText, params.currentInboundContext),
|
|
8148
8174
|
developerInstructions,
|
|
8149
8175
|
messages: codexModelInputHistoryMessages,
|
|
8150
|
-
ctx: hookContext
|
|
8176
|
+
ctx: hookContext,
|
|
8177
|
+
..."beforeAgentStartResult" in params ? { beforeAgentStartResult: params.beforeAgentStartResult } : {}
|
|
8151
8178
|
});
|
|
8152
|
-
const
|
|
8153
|
-
if (!
|
|
8154
|
-
const
|
|
8155
|
-
const turnPromptOffset = turnPromptText.length - prompt.length + promptTextOffset;
|
|
8179
|
+
const resolveShiftedPromptInputRange = (prompt, promptInputRange, turnPromptText) => {
|
|
8180
|
+
if (!promptInputRange || promptInputRange.start < 0 || promptInputRange.end < promptInputRange.start || promptInputRange.end > prompt.length || !turnPromptText.endsWith(prompt)) return;
|
|
8181
|
+
const turnPromptOffset = turnPromptText.length - prompt.length;
|
|
8156
8182
|
return {
|
|
8183
|
+
start: turnPromptOffset + promptInputRange.start,
|
|
8184
|
+
end: turnPromptOffset + promptInputRange.end
|
|
8185
|
+
};
|
|
8186
|
+
};
|
|
8187
|
+
const resolveShiftedPromptContextRange = (prompt, promptInputRange, turnPromptText) => {
|
|
8188
|
+
const promptTextInputOffset = promptInputRange ? promptInputRange.end - promptText.length : void 0;
|
|
8189
|
+
if (!promptContextRange || !promptInputRange || promptTextInputOffset === void 0 || promptInputRange.start < 0 || promptInputRange.end < promptInputRange.start || promptInputRange.end > prompt.length || promptTextInputOffset < promptInputRange.start || prompt.slice(promptTextInputOffset, promptInputRange.end) !== promptText || !turnPromptText.endsWith(prompt)) return;
|
|
8190
|
+
const promptTextOffset = prompt.endsWith(promptText) ? prompt.length - promptText.length : promptTextInputOffset;
|
|
8191
|
+
if (promptTextOffset < 0) return;
|
|
8192
|
+
const turnPromptOffset = turnPromptText.length - prompt.length + promptTextOffset;
|
|
8193
|
+
const contextRange = {
|
|
8157
8194
|
start: turnPromptOffset + promptContextRange.start,
|
|
8158
8195
|
end: turnPromptOffset + promptContextRange.end
|
|
8159
8196
|
};
|
|
8197
|
+
return {
|
|
8198
|
+
contextRange,
|
|
8199
|
+
requestRange: {
|
|
8200
|
+
start: contextRange.end,
|
|
8201
|
+
end: turnPromptOffset + promptText.length
|
|
8202
|
+
}
|
|
8203
|
+
};
|
|
8160
8204
|
};
|
|
8161
8205
|
let promptBuild = await buildPromptFromCurrentInputs();
|
|
8162
|
-
const decorateCodexTurnPromptText = (
|
|
8163
|
-
const turnPromptText = prependCodexOpenClawPromptContext(prompt, openClawPromptContext, { preservePromptWithoutContext: params.bootstrapContextMode === "lightweight" && params.bootstrapContextRunKind === "cron" });
|
|
8206
|
+
const decorateCodexTurnPromptText = (promptBuildResult) => {
|
|
8207
|
+
const turnPromptText = prependCodexOpenClawPromptContext(promptBuildResult.prompt, openClawPromptContext, { preservePromptWithoutContext: params.bootstrapContextMode === "lightweight" && params.bootstrapContextRunKind === "cron" });
|
|
8208
|
+
const projectedRanges = resolveShiftedPromptContextRange(promptBuildResult.prompt, promptBuildResult.promptInputRange, turnPromptText);
|
|
8209
|
+
const preservedRange = resolveShiftedPromptInputRange(promptBuildResult.prompt, promptBuildResult.promptInputRange, turnPromptText) ?? resolveCodexDeliveryHintPreservedInputRange({
|
|
8210
|
+
prompt: promptBuildResult.prompt,
|
|
8211
|
+
promptInputRange: promptBuildResult.promptInputRange,
|
|
8212
|
+
decoratedPrompt: turnPromptText
|
|
8213
|
+
});
|
|
8164
8214
|
return fitCodexProjectedContextForTurnStart({
|
|
8165
8215
|
promptText: turnPromptText,
|
|
8166
|
-
contextRange:
|
|
8216
|
+
contextRange: projectedRanges?.contextRange,
|
|
8217
|
+
requestRange: projectedRanges?.requestRange,
|
|
8218
|
+
preservedRange
|
|
8167
8219
|
});
|
|
8168
8220
|
};
|
|
8169
|
-
let codexTurnPromptText = decorateCodexTurnPromptText(promptBuild
|
|
8221
|
+
let codexTurnPromptText = decorateCodexTurnPromptText(promptBuild);
|
|
8170
8222
|
const buildCodexTurnCollaborationDeveloperInstructions = () => buildTurnCollaborationMode(params, {
|
|
8171
8223
|
turnScopedDeveloperInstructions: workspaceBootstrapContext.turnScopedDeveloperInstructions,
|
|
8172
8224
|
skillsCollaborationInstructions,
|
|
@@ -8176,15 +8228,16 @@ async function runCodexAppServerAttempt(params, options = {}) {
|
|
|
8176
8228
|
const buildRenderedCodexDeveloperInstructions = () => joinPresentSections(promptBuild.developerInstructions, buildCodexTurnCollaborationDeveloperInstructions());
|
|
8177
8229
|
const rebuildCodexPromptBuildFromCurrentProjection = async () => {
|
|
8178
8230
|
promptBuild = await buildPromptFromCurrentInputs();
|
|
8179
|
-
codexTurnPromptText = decorateCodexTurnPromptText(promptBuild
|
|
8231
|
+
codexTurnPromptText = decorateCodexTurnPromptText(promptBuild);
|
|
8180
8232
|
};
|
|
8181
8233
|
const rebuildCodexTurnPromptTextFromCurrentProjection = async () => {
|
|
8182
8234
|
const nextPromptBuild = await buildPromptFromCurrentInputs();
|
|
8183
8235
|
promptBuild = {
|
|
8184
8236
|
...promptBuild,
|
|
8185
|
-
prompt: nextPromptBuild.prompt
|
|
8237
|
+
prompt: nextPromptBuild.prompt,
|
|
8238
|
+
promptInputRange: nextPromptBuild.promptInputRange
|
|
8186
8239
|
};
|
|
8187
|
-
codexTurnPromptText = decorateCodexTurnPromptText(nextPromptBuild
|
|
8240
|
+
codexTurnPromptText = decorateCodexTurnPromptText(nextPromptBuild);
|
|
8188
8241
|
};
|
|
8189
8242
|
const selectNewerVisibleHistoryAfterBinding = (binding) => {
|
|
8190
8243
|
const bindingUpdatedAt = Date.parse(binding.updatedAt);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { n as isJsonObject } from "./protocol-dh-ETiNd.js";
|
|
2
|
-
import { H as readCodexNotificationTurnId, N as mergeCodexThreadConfigs, S as filterCodexDynamicTools, T as resolveCodexDynamicToolsLoading, V as readCodexNotificationThreadId, _ as resolveCodexWebSearchPlan, d as resolveCodexAppServerRequestModelSelection, m as resolveReasoningEffort, p as resolveCodexBindingModelProviderFallback, r as buildCodexRuntimeThreadConfig, t as CODEX_NATIVE_PERSONALITY_NONE, u as resolveCodexAppServerModelProvider } from "./thread-lifecycle-
|
|
2
|
+
import { H as readCodexNotificationTurnId, N as mergeCodexThreadConfigs, S as filterCodexDynamicTools, T as resolveCodexDynamicToolsLoading, V as readCodexNotificationThreadId, _ as resolveCodexWebSearchPlan, d as resolveCodexAppServerRequestModelSelection, m as resolveReasoningEffort, p as resolveCodexBindingModelProviderFallback, r as buildCodexRuntimeThreadConfig, t as CODEX_NATIVE_PERSONALITY_NONE, u as resolveCodexAppServerModelProvider } from "./thread-lifecycle-CJdHuthD.js";
|
|
3
3
|
import { d as resolveCodexAppServerRuntimeOptions, g as shouldAutoApproveCodexAppServerApprovals, h as resolveOpenClawExecPolicyForCodexAppServer, n as canUseCodexModelBackedApprovalsReviewerForModel, p as resolveCodexModelBackedReviewerPolicyContext, u as readCodexPluginConfig } from "./config-CszD0vP3.js";
|
|
4
4
|
import { a as readCodexDynamicToolCallParams, c as readCodexTurn, i as assertCodexTurnStartResponse, t as assertCodexThreadForkResponse } from "./protocol-validators-B19q5BIX.js";
|
|
5
5
|
import { i as formatCodexUsageLimitErrorMessage } from "./provider-B-OHpbD3.js";
|
|
@@ -8,7 +8,7 @@ import { i as isCodexAppServerNativeAuthProfile, o as readCodexAppServerBinding
|
|
|
8
8
|
import { t as resolveCodexAppServerForModelProvider } from "./app-server-policy-BPTiVNsW.js";
|
|
9
9
|
import { a as getLeasedSharedCodexAppServerClient, o as releaseLeasedSharedCodexAppServerClient, u as refreshCodexAppServerAuthTokens } from "./shared-client-Dtx5i7Ez.js";
|
|
10
10
|
import { n as resolveCodexNativeExecutionBlock } from "./sandbox-guard-3tnjhjFb.js";
|
|
11
|
-
import { C as resolveCodexMessageToolProvider, O as filterToolsForVisionInputs, T as shouldEnableCodexAppServerNativeToolSurface, a as buildCodexNativeHookRelayConfig, d as handleCodexAppServerElicitationRequest, f as createCodexDynamicToolBridge, h as emitDynamicToolTerminalDiagnostic, k as handleCodexAppServerApprovalRequest, m as emitDynamicToolStartedDiagnostic, n as resolveCodexProviderWebSearchSupportForClient, o as buildCodexNativeHookRelayDisabledConfig, p as emitDynamicToolErrorDiagnostic, r as CODEX_NATIVE_HOOK_RELAY_EVENTS } from "./provider-capabilities-
|
|
11
|
+
import { C as resolveCodexMessageToolProvider, O as filterToolsForVisionInputs, T as shouldEnableCodexAppServerNativeToolSurface, a as buildCodexNativeHookRelayConfig, d as handleCodexAppServerElicitationRequest, f as createCodexDynamicToolBridge, h as emitDynamicToolTerminalDiagnostic, k as handleCodexAppServerApprovalRequest, m as emitDynamicToolStartedDiagnostic, n as resolveCodexProviderWebSearchSupportForClient, o as buildCodexNativeHookRelayDisabledConfig, p as emitDynamicToolErrorDiagnostic, r as CODEX_NATIVE_HOOK_RELAY_EVENTS } from "./provider-capabilities-D2Ee9YEI.js";
|
|
12
12
|
import { n as rememberCodexRateLimits, t as readRecentCodexRateLimits } from "./rate-limit-cache-C7qmZ0Jh.js";
|
|
13
13
|
import { loadExecApprovals } from "openclaw/plugin-sdk/exec-approvals-runtime";
|
|
14
14
|
import { buildAgentHookContextChannelFields, embeddedAgentLog, formatErrorMessage, registerNativeHookRelay, resolveAgentDir, resolveAttemptSpawnWorkspaceDir, resolveModelAuthMode, resolveSandboxContext, resolveSessionAgentIds, supportsModelTools } from "openclaw/plugin-sdk/agent-harness-runtime";
|
|
@@ -917,13 +917,29 @@ function fitCodexProjectedContextForTurnStart(params) {
|
|
|
917
917
|
const maxChars = typeof params.maxChars === "number" && Number.isFinite(params.maxChars) ? Math.max(0, Math.floor(params.maxChars)) : CODEX_TURN_START_TEXT_INPUT_MAX_CHARS;
|
|
918
918
|
if (params.promptText.length <= maxChars) return params.promptText;
|
|
919
919
|
const range = normalizeProjectedContextRange(params.contextRange, params.promptText.length);
|
|
920
|
-
if (!range)
|
|
920
|
+
if (!range) {
|
|
921
|
+
const preservedRange = normalizeProjectedContextRange(params.preservedRange, params.promptText.length);
|
|
922
|
+
if (!preservedRange) return params.promptText;
|
|
923
|
+
const preservedText = params.promptText.slice(preservedRange.start, preservedRange.end);
|
|
924
|
+
if (!preservedText) return truncateOlderContext(params.promptText, maxChars);
|
|
925
|
+
if (preservedText.length >= maxChars) return truncateOlderContext(preservedText, maxChars);
|
|
926
|
+
return `${truncateOlderContext(params.promptText.slice(0, preservedRange.start), maxChars - preservedText.length)}${preservedText}`;
|
|
927
|
+
}
|
|
921
928
|
const beforeContext = params.promptText.slice(0, range.start);
|
|
922
929
|
const context = params.promptText.slice(range.start, range.end);
|
|
923
930
|
const afterContext = params.promptText.slice(range.end);
|
|
931
|
+
const requestRange = normalizeProjectedContextRange(params.requestRange, params.promptText.length);
|
|
932
|
+
if (requestRange && requestRange.start >= range.end && requestRange.end < params.promptText.length) {
|
|
933
|
+
const request = params.promptText.slice(requestRange.start, requestRange.end);
|
|
934
|
+
if (request.length >= maxChars) return truncateOlderContext(request, maxChars);
|
|
935
|
+
const fittedAppendedContext = truncateOlderContext(params.promptText.slice(requestRange.end), maxChars - request.length);
|
|
936
|
+
const fittedContext = truncateOlderContext(context, maxChars - request.length - fittedAppendedContext.length);
|
|
937
|
+
return `${truncateOlderContext(beforeContext, maxChars - fittedContext.length - request.length - fittedAppendedContext.length)}${fittedContext}${request}${fittedAppendedContext}`;
|
|
938
|
+
}
|
|
924
939
|
const contextBudget = maxChars - beforeContext.length - afterContext.length;
|
|
925
940
|
if (contextBudget > 0) return `${beforeContext}${truncateOlderContext(context, contextBudget)}${afterContext}`;
|
|
926
|
-
|
|
941
|
+
const afterContextText = truncateOlderContext(afterContext, maxChars);
|
|
942
|
+
return `${truncateOlderContext(context, maxChars - afterContextText.length)}${afterContextText}`;
|
|
927
943
|
}
|
|
928
944
|
function normalizeProjectedContextRange(range, textLength) {
|
|
929
945
|
if (!range) return;
|
package/dist/{web-search-provider.runtime-BWG_oqLf.js → web-search-provider.runtime-CMEYazjn.js}
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as isJsonObject } from "./protocol-dh-ETiNd.js";
|
|
2
|
-
import { g as buildCodexNativeWebSearchThreadConfig } from "./thread-lifecycle-
|
|
3
|
-
import { n as runBoundedCodexAppServerTurn } from "./media-understanding-provider-
|
|
2
|
+
import { g as buildCodexNativeWebSearchThreadConfig } from "./thread-lifecycle-CJdHuthD.js";
|
|
3
|
+
import { n as runBoundedCodexAppServerTurn } from "./media-understanding-provider-DSQ2ry-4.js";
|
|
4
4
|
import { readStringParam, resolveSearchTimeoutSeconds, wrapWebContent } from "openclaw/plugin-sdk/provider-web-search";
|
|
5
5
|
//#region extensions/codex/src/web-search-provider.runtime.ts
|
|
6
6
|
async function executeCodexWebSearchProviderTool(ctx, args, executionContext, options) {
|
package/npm-shrinkwrap.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openclaw/codex",
|
|
3
|
-
"version": "2026.6.
|
|
3
|
+
"version": "2026.6.10-beta.1",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "@openclaw/codex",
|
|
9
|
-
"version": "2026.6.
|
|
9
|
+
"version": "2026.6.10-beta.1",
|
|
10
10
|
"dependencies": {
|
|
11
11
|
"@openai/codex": "0.139.0",
|
|
12
12
|
"typebox": "1.1.39",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openclaw/codex",
|
|
3
|
-
"version": "2026.6.
|
|
3
|
+
"version": "2026.6.10-beta.1",
|
|
4
4
|
"description": "OpenClaw Codex app-server harness and model provider plugin with a Codex-managed GPT catalog.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -34,10 +34,10 @@
|
|
|
34
34
|
]
|
|
35
35
|
},
|
|
36
36
|
"compat": {
|
|
37
|
-
"pluginApi": ">=2026.6.
|
|
37
|
+
"pluginApi": ">=2026.6.10-beta.1"
|
|
38
38
|
},
|
|
39
39
|
"build": {
|
|
40
|
-
"openclawVersion": "2026.6.
|
|
40
|
+
"openclawVersion": "2026.6.10-beta.1"
|
|
41
41
|
},
|
|
42
42
|
"release": {
|
|
43
43
|
"publishToClawHub": true,
|
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
"README.md"
|
|
56
56
|
],
|
|
57
57
|
"peerDependencies": {
|
|
58
|
-
"openclaw": ">=2026.6.
|
|
58
|
+
"openclaw": ">=2026.6.10-beta.1"
|
|
59
59
|
},
|
|
60
60
|
"peerDependenciesMeta": {
|
|
61
61
|
"openclaw": {
|