@openclaw/codex 2026.7.1-beta.6 → 2026.7.2-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/README.md +27 -3
- package/dist/app-server-policy-DVcxdse_.js +49 -0
- package/dist/{attempt-notifications-BGsEIIDI.js → attempt-notifications-DEv9h7iC.js} +1 -1
- package/dist/auth-binding-C1czuHPA.js +62 -0
- package/dist/capabilities-42Dfn2TV.js +33 -0
- package/dist/cli-metadata.js +20 -0
- package/dist/{app-server-policy-C968Kgin.js → command-formatters-D6ZlGNmb.js} +8 -51
- package/dist/{command-handlers-Dv-pzAmg.js → command-handlers-Cpl9fUWv.js} +163 -60
- package/dist/{compact-4mVBriKT.js → compact-FnJmiPNA.js} +40 -10
- package/dist/computer-use-DVzr8OP1.js +685 -0
- package/dist/{config-CYEDnLJ2.js → config-c48K5HP9.js} +200 -29
- package/dist/conversation-control-DtQ-E7mr.js +288 -0
- package/dist/doctor-contract-api.js +120 -81
- package/dist/{provider-capabilities-CDnHbmUZ.js → dynamic-tools-BMLoaTeG.js} +5246 -5140
- package/dist/harness.js +55 -15
- package/dist/index.js +1435 -265
- package/dist/{media-understanding-provider-BHOu9-Gg.js → media-understanding-provider-D580L0P8.js} +28 -10
- package/dist/media-understanding-provider.js +1 -1
- package/dist/{models-DDmO1zwd.js → models-DuKzZA6G.js} +1 -1
- package/dist/notification-correlation-DfaCm0mx.js +67 -0
- package/dist/plugin-app-cache-key-BKNjHMEs.js +315 -0
- package/dist/{protocol-2POPqAY4.js → protocol-BMifTfdW.js} +3 -1
- package/dist/provider-catalog.js +66 -27
- package/dist/provider.js +306 -1
- package/dist/{provider-zjPfx5Fs.js → rate-limits-Dhp04Rqo.js} +4 -261
- package/dist/request-DborTWgw.js +111 -0
- package/dist/{run-attempt-FUyOjGCV.js → run-attempt-VPVJoYDP.js} +7897 -7136
- package/dist/runtime-artifact-C2ITXdhM.js +488 -0
- package/dist/{sandbox-guard-DA2TQfZW.js → sandbox-guard-D1Wky__S.js} +10 -1
- package/dist/{session-binding-C1ZXdP-x.js → session-binding-BMfX1OX-.js} +247 -88
- package/dist/session-catalog-7H112Tr_.js +2396 -0
- package/dist/session-cli-B28RhCyp.js +175 -0
- package/dist/{shared-client-4ICy3U6d.js → shared-client-D4mFI9al.js} +1997 -1297
- package/dist/{side-question-N4OaDer2.js → side-question-CgJBz52s.js} +135 -67
- package/dist/{thread-lifecycle-qWE88Dn2.js → thread-lifecycle-BgLXzjvV.js} +747 -317
- package/dist/transcript-mirror-DhLwFIL4.js +485 -0
- package/dist/transport-stdio-DXgGZ7Ib.js +88 -0
- package/dist/{web-search-provider.runtime-BSlriav6.js → web-search-provider.runtime-Bs-eTn5U.js} +3 -3
- package/npm-shrinkwrap.json +56 -30
- package/openclaw.plugin.json +168 -10
- package/package.json +8 -6
- package/dist/command-rpc-eLM_mtC7.js +0 -784
- package/dist/computer-use-Bmaz333N.js +0 -377
- package/dist/notification-correlation-Bo7KB3ks.js +0 -35
- package/dist/plugin-app-cache-key-BrhVdeEf.js +0 -98
- package/dist/request-BcJyl8KL.js +0 -36
|
@@ -1,14 +1,15 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { i as isJsonObject } from "./protocol-BMifTfdW.js";
|
|
2
|
+
import { b as shouldAutoApproveCodexAppServerApprovals, d as readCodexPluginConfig, g as resolveCodexModelBackedReviewerPolicyContext, i as canUseCodexModelBackedApprovalsReviewerForModel, y as resolveOpenClawExecPolicyForCodexAppServer } from "./config-c48K5HP9.js";
|
|
3
3
|
import { a as readCodexDynamicToolCallParams, c as readCodexTurn, i as assertCodexTurnStartResponse, t as assertCodexThreadForkResponse } from "./protocol-validators-dZQ-UTOa.js";
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import { n as
|
|
11
|
-
import {
|
|
4
|
+
import { A as isCodexAppServerApprovalRequest, T as resolveCodexAppServerPreparedAuthHandoff, a as getLeasedSharedCodexAppServerClient, g as ensureCodexAppServerClientRuntime, p as withLeasedCodexAppServerClientStartSelectionRetry, s as releaseCodexAppServerClientLease, v as readRecentCodexRateLimits } from "./shared-client-D4mFI9al.js";
|
|
5
|
+
import { O as resolveCodexDynamicToolsLoading, V as buildCodexPluginAppsConfigPatchFromPolicyContext, W as mergeCodexThreadConfigs, d as resolveCodexAppServerModelProvider, f as resolveCodexAppServerRequestModelSelection, h as resolveReasoningEffort, m as resolveCodexBindingModelProviderFallback, r as buildCodexRuntimeThreadConfig, t as CODEX_NATIVE_PERSONALITY_NONE, v as resolveCodexWebSearchPlan, w as filterCodexDynamicTools } from "./thread-lifecycle-BgLXzjvV.js";
|
|
6
|
+
import { c as sessionBindingIdentity } from "./session-binding-BMfX1OX-.js";
|
|
7
|
+
import { n as formatCodexUsageLimitErrorMessage } from "./rate-limits-Dhp04Rqo.js";
|
|
8
|
+
import { readCodexSupportedReasoningEfforts } from "./provider.js";
|
|
9
|
+
import { t as resolveCodexAppServerForModelProvider } from "./app-server-policy-DVcxdse_.js";
|
|
10
|
+
import { n as resolveCodexNativeExecutionBlock } from "./sandbox-guard-D1Wky__S.js";
|
|
11
|
+
import { a as resolveCodexBindingAppServerConnection, i as requireCodexSupervisionModelSelection, n as readCodexNotificationThreadId, r as readCodexNotificationTurnId } from "./notification-correlation-DfaCm0mx.js";
|
|
12
|
+
import { A as CodexNativeToolLifecycleProjector, B as handleDynamicToolCallWithTimeout, C as resolveCodexMessageToolProvider, I as emitCodexNativePreToolUseFailureDiagnostic, N as buildCodexNativeHookRelayConfig, O as filterToolsForVisionInputs, P as buildCodexNativeHookRelayDisabledConfig, T as shouldEnableCodexAppServerNativeToolSurface, W as resolveDynamicToolCallTimeoutMs, X as resolveCodexToolAbortTerminalReason, a as emitDynamicToolStartedDiagnostic, c as resolveCodexProviderWebSearchSupportForClient, i as emitDynamicToolErrorDiagnostic, j as CODEX_NATIVE_HOOK_RELAY_EVENTS, n as handleCodexAppServerApprovalRequest, o as emitDynamicToolTerminalDiagnostic, r as handleCodexAppServerElicitationRequest, t as createCodexDynamicToolBridge } from "./dynamic-tools-BMLoaTeG.js";
|
|
12
13
|
import { randomUUID } from "node:crypto";
|
|
13
14
|
import { loadExecApprovals } from "openclaw/plugin-sdk/exec-approvals-runtime";
|
|
14
15
|
import { buildAgentHookContextChannelFields, embeddedAgentLog, formatErrorMessage, registerNativeHookRelay, resolveAgentDir, resolveAttemptSpawnWorkspaceDir, resolveModelAuthMode, resolveSandboxContext, resolveSessionAgentIds, supportsModelTools } from "openclaw/plugin-sdk/agent-harness-runtime";
|
|
@@ -67,10 +68,27 @@ async function runCodexAppServerSideQuestion(params, options) {
|
|
|
67
68
|
config: params.cfg,
|
|
68
69
|
agentId: sessionAgentId
|
|
69
70
|
});
|
|
70
|
-
const
|
|
71
|
-
const
|
|
71
|
+
const usesSupervisionConnection = binding.connectionScope === "supervision";
|
|
72
|
+
const supervisionModelSelection = usesSupervisionConnection ? requireCodexSupervisionModelSelection(binding) : void 0;
|
|
73
|
+
const preparedRuntimeAuth = params.preparedRuntimeAuth;
|
|
74
|
+
const { authProfileId, nativeAuthProfile: preparedNativeAuthProfile, preparedAuth: startupPreparedAuth } = usesSupervisionConnection ? {
|
|
75
|
+
authProfileId: void 0,
|
|
76
|
+
nativeAuthProfile: true,
|
|
77
|
+
preparedAuth: void 0
|
|
78
|
+
} : await resolveCodexAppServerPreparedAuthHandoff({
|
|
79
|
+
authRequirement: preparedRuntimeAuth.plan.modelRoute?.authRequirement,
|
|
80
|
+
resolvedApiKey: preparedRuntimeAuth.resolvedApiKey,
|
|
81
|
+
authProfileId: preparedRuntimeAuth.plan.forwardedAuthProfileId,
|
|
82
|
+
authProfileStore: preparedRuntimeAuth.authProfileStore,
|
|
83
|
+
agentDir: params.agentDir,
|
|
84
|
+
config: params.cfg,
|
|
85
|
+
subscriptionProfileRequiredError: "Prepared Codex subscription route requires a scoped native OAuth or token profile.",
|
|
86
|
+
subscriptionProfileUnusableError: `Prepared Codex auth profile "${preparedRuntimeAuth.plan.forwardedAuthProfileId}" is unusable.`
|
|
87
|
+
});
|
|
88
|
+
const modelProvider = supervisionModelSelection ? supervisionModelSelection.modelProvider : resolveCodexAppServerModelProvider({
|
|
72
89
|
provider: params.provider,
|
|
73
90
|
authProfileId,
|
|
91
|
+
authProfileStore: preparedRuntimeAuth.authProfileStore,
|
|
74
92
|
agentDir: params.agentDir,
|
|
75
93
|
config: params.cfg
|
|
76
94
|
}) ?? resolveCodexBindingModelProviderFallback({
|
|
@@ -80,24 +98,23 @@ async function runCodexAppServerSideQuestion(params, options) {
|
|
|
80
98
|
bindingModelProvider: binding.modelProvider
|
|
81
99
|
});
|
|
82
100
|
const modelSelection = resolveCodexAppServerRequestModelSelection({
|
|
83
|
-
model: params.model,
|
|
101
|
+
model: supervisionModelSelection?.model ?? params.model,
|
|
84
102
|
modelProvider,
|
|
85
103
|
authProfileId,
|
|
104
|
+
authProfileStore: preparedRuntimeAuth.authProfileStore,
|
|
86
105
|
agentDir: params.agentDir,
|
|
87
106
|
config: params.cfg
|
|
88
107
|
});
|
|
89
108
|
const reviewerPolicyContext = resolveCodexModelBackedReviewerPolicyContext({
|
|
90
|
-
provider: params.provider,
|
|
91
|
-
model: params.model,
|
|
109
|
+
provider: usesSupervisionConnection ? "codex" : params.provider,
|
|
110
|
+
model: supervisionModelSelection?.model ?? params.model,
|
|
92
111
|
bindingModelProvider: binding.modelProvider,
|
|
93
112
|
bindingModel: binding.model,
|
|
94
|
-
nativeAuthProfile:
|
|
95
|
-
authProfileId,
|
|
96
|
-
agentDir: params.agentDir,
|
|
97
|
-
config: params.cfg
|
|
98
|
-
})
|
|
113
|
+
nativeAuthProfile: usesSupervisionConnection || preparedNativeAuthProfile
|
|
99
114
|
});
|
|
100
|
-
const
|
|
115
|
+
const connection = resolveCodexBindingAppServerConnection({
|
|
116
|
+
binding,
|
|
117
|
+
authProfileId,
|
|
101
118
|
pluginConfig,
|
|
102
119
|
execPolicy,
|
|
103
120
|
modelProvider: reviewerPolicyContext.modelProvider,
|
|
@@ -105,9 +122,29 @@ async function runCodexAppServerSideQuestion(params, options) {
|
|
|
105
122
|
config: params.cfg,
|
|
106
123
|
agentDir: params.agentDir
|
|
107
124
|
});
|
|
125
|
+
const appServer = connection.appServer;
|
|
108
126
|
const cwd = binding.cwd || params.workspaceDir || process.cwd();
|
|
109
127
|
const runId = params.opts?.runId ?? randomUUID();
|
|
110
|
-
const
|
|
128
|
+
const effectiveParams = supervisionModelSelection ? {
|
|
129
|
+
...params,
|
|
130
|
+
provider: supervisionModelSelection.modelProvider,
|
|
131
|
+
model: supervisionModelSelection.model,
|
|
132
|
+
runtimeModel: {
|
|
133
|
+
id: supervisionModelSelection.model,
|
|
134
|
+
name: supervisionModelSelection.model,
|
|
135
|
+
provider: supervisionModelSelection.modelProvider,
|
|
136
|
+
api: "openai-chatgpt-responses",
|
|
137
|
+
reasoning: true,
|
|
138
|
+
input: ["text", "image"],
|
|
139
|
+
cost: {
|
|
140
|
+
input: 0,
|
|
141
|
+
output: 0,
|
|
142
|
+
cacheRead: 0,
|
|
143
|
+
cacheWrite: 0
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
} : params;
|
|
147
|
+
const sideRunParams = buildSideRunAttemptParams(effectiveParams, {
|
|
111
148
|
cwd,
|
|
112
149
|
authProfileId,
|
|
113
150
|
runId
|
|
@@ -121,13 +158,16 @@ async function runCodexAppServerSideQuestion(params, options) {
|
|
|
121
158
|
if (nativeExecutionBlock) throw new Error(nativeExecutionBlock);
|
|
122
159
|
const nativeToolSurfaceEnabled = shouldEnableCodexAppServerNativeToolSurface(sideRunParams);
|
|
123
160
|
if (!nativeToolSurfaceEnabled) throw new Error("Codex-native /btw side-question mode is unavailable because the effective tool policy restricts Codex native tools for this session.");
|
|
124
|
-
const
|
|
161
|
+
const clientOptions = {
|
|
125
162
|
startOptions: appServer.start,
|
|
126
163
|
timeoutMs: appServer.requestTimeoutMs,
|
|
127
|
-
authProfileId,
|
|
164
|
+
...startupPreparedAuth ? { preparedAuth: startupPreparedAuth } : { authProfileId: connection.clientAuthProfileId },
|
|
128
165
|
agentDir: params.agentDir,
|
|
129
|
-
config: params.cfg
|
|
130
|
-
|
|
166
|
+
config: params.cfg,
|
|
167
|
+
...params.opts?.abortSignal ? { abandonSignal: params.opts.abortSignal } : {}
|
|
168
|
+
};
|
|
169
|
+
let client = await getLeasedSharedCodexAppServerClient(clientOptions);
|
|
170
|
+
const clientLease = { client };
|
|
131
171
|
const collector = new CodexSideQuestionCollector(params, () => readRecentCodexRateLimits(client));
|
|
132
172
|
const runAbortController = new AbortController();
|
|
133
173
|
let nativeToolLifecycleProjector;
|
|
@@ -157,7 +197,7 @@ async function runCodexAppServerSideQuestion(params, options) {
|
|
|
157
197
|
}
|
|
158
198
|
flushPendingNativePreToolUseFailures();
|
|
159
199
|
};
|
|
160
|
-
const
|
|
200
|
+
const handleNotification = (notification) => {
|
|
161
201
|
collector.handleNotification(notification);
|
|
162
202
|
if (notification.method !== "item/started" && notification.method !== "item/completed" && notification.method !== "rawResponseItem/completed" && notification.method !== "turn/completed") return;
|
|
163
203
|
if (!nativeToolLifecycleProjector) {
|
|
@@ -165,7 +205,8 @@ async function runCodexAppServerSideQuestion(params, options) {
|
|
|
165
205
|
return;
|
|
166
206
|
}
|
|
167
207
|
nativeToolLifecycleProjector.handleNotification(notification);
|
|
168
|
-
}
|
|
208
|
+
};
|
|
209
|
+
let removeNotificationHandler = client.addNotificationHandler(handleNotification);
|
|
169
210
|
const abortFromUpstream = () => runAbortController.abort(params.opts?.abortSignal?.reason ?? "codex_side_question_abort");
|
|
170
211
|
if (params.opts?.abortSignal?.aborted) abortFromUpstream();
|
|
171
212
|
else params.opts?.abortSignal?.addEventListener("abort", abortFromUpstream, { once: true });
|
|
@@ -192,7 +233,7 @@ async function runCodexAppServerSideQuestion(params, options) {
|
|
|
192
233
|
const approvalPolicy = useModelScopedPolicy ? modelScopedAppServer.approvalPolicy : binding.approvalPolicy ?? modelScopedAppServer.approvalPolicy;
|
|
193
234
|
const sandbox = useModelScopedPolicy ? modelScopedAppServer.sandbox : binding.sandbox ?? modelScopedAppServer.sandbox;
|
|
194
235
|
const { toolBridge, webSearchPlan } = await createCodexSideToolBridge({
|
|
195
|
-
params,
|
|
236
|
+
params: effectiveParams,
|
|
196
237
|
cwd,
|
|
197
238
|
pluginConfig,
|
|
198
239
|
sessionAgentId,
|
|
@@ -211,10 +252,14 @@ async function runCodexAppServerSideQuestion(params, options) {
|
|
|
211
252
|
});
|
|
212
253
|
ensureCodexAppServerClientRuntime(client, {
|
|
213
254
|
agentDir: params.agentDir,
|
|
214
|
-
authProfileId,
|
|
255
|
+
authProfileId: startupPreparedAuth?.kind === "api-key" ? void 0 : connection.requestAuthProfileId,
|
|
256
|
+
...!usesSupervisionConnection ? {
|
|
257
|
+
authProfileStore: preparedRuntimeAuth.authProfileStore,
|
|
258
|
+
authMode: startupPreparedAuth?.kind === "api-key" ? "prepared-api-key" : "profile"
|
|
259
|
+
} : {},
|
|
215
260
|
config: params.cfg
|
|
216
261
|
});
|
|
217
|
-
|
|
262
|
+
const registerRequestHandler = (targetClient) => targetClient.addRequestHandler(async (request) => {
|
|
218
263
|
if (!childThreadId || !turnId) return;
|
|
219
264
|
if (request.method === "mcpServer/elicitation/request") return handleCodexAppServerElicitationRequest({
|
|
220
265
|
requestParams: request.params,
|
|
@@ -232,9 +277,6 @@ async function runCodexAppServerSideQuestion(params, options) {
|
|
|
232
277
|
threadId: childThreadId,
|
|
233
278
|
turnId,
|
|
234
279
|
nativeHookRelay,
|
|
235
|
-
execPolicy,
|
|
236
|
-
execReviewerAgentId: sessionAgentId,
|
|
237
|
-
internalExecAutoReview: modelScopedAppServer.approvalsReviewer === "user",
|
|
238
280
|
autoApprove: shouldAutoApproveCodexAppServerApprovals({
|
|
239
281
|
approvalPolicy,
|
|
240
282
|
networkProxy: modelScopedAppServer.networkProxy,
|
|
@@ -284,6 +326,19 @@ async function runCodexAppServerSideQuestion(params, options) {
|
|
|
284
326
|
throw error;
|
|
285
327
|
}
|
|
286
328
|
});
|
|
329
|
+
removeRequestHandler = registerRequestHandler(client);
|
|
330
|
+
const rebindClientHandlers = (nextClient) => {
|
|
331
|
+
removeRequestHandler?.();
|
|
332
|
+
removeNotificationHandler();
|
|
333
|
+
client = nextClient;
|
|
334
|
+
ensureCodexAppServerClientRuntime(client, {
|
|
335
|
+
agentDir: params.agentDir,
|
|
336
|
+
authProfileId: connection.requestAuthProfileId,
|
|
337
|
+
config: params.cfg
|
|
338
|
+
});
|
|
339
|
+
removeNotificationHandler = client.addNotificationHandler(handleNotification);
|
|
340
|
+
removeRequestHandler = registerRequestHandler(client);
|
|
341
|
+
};
|
|
287
342
|
const serviceTier = binding.serviceTier ?? appServer.serviceTier;
|
|
288
343
|
const nativeHookRelayEvents = resolveCodexSideNativeHookRelayEvents({
|
|
289
344
|
configuredEvents: options.nativeHookRelay?.events,
|
|
@@ -323,24 +378,28 @@ async function runCodexAppServerSideQuestion(params, options) {
|
|
|
323
378
|
nativeCodeModeOnlyEnabled: appServer.codeModeOnly
|
|
324
379
|
});
|
|
325
380
|
const threadConfig = mergeCodexThreadConfigs(nativeHookRelayConfig, runtimeThreadConfig, binding.pluginAppPolicyContext ? buildCodexPluginAppsConfigPatchFromPolicyContext(binding.pluginAppPolicyContext) : void 0, modelScopedAppServer.networkProxy?.configPatch) ?? runtimeThreadConfig;
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
381
|
+
const forkResponse = assertCodexThreadForkResponse(await withLeasedCodexAppServerClientStartSelectionRetry({
|
|
382
|
+
lease: clientLease,
|
|
383
|
+
options: clientOptions,
|
|
384
|
+
signal: params.opts?.abortSignal,
|
|
385
|
+
run: async (forkClient, requestOptions) => await forkCodexSideThread(forkClient, {
|
|
386
|
+
threadId: binding.threadId,
|
|
387
|
+
model: modelSelection.model,
|
|
388
|
+
...modelSelection.modelProvider ? { modelProvider: modelSelection.modelProvider } : {},
|
|
389
|
+
cwd,
|
|
390
|
+
approvalPolicy,
|
|
391
|
+
approvalsReviewer: modelScopedAppServer.approvalsReviewer,
|
|
392
|
+
...modelScopedAppServer.networkProxy ? {} : { sandbox },
|
|
393
|
+
...serviceTier ? { serviceTier } : {},
|
|
394
|
+
config: threadConfig,
|
|
395
|
+
developerInstructions: SIDE_DEVELOPER_INSTRUCTIONS,
|
|
396
|
+
ephemeral: true,
|
|
397
|
+
threadSource: "user"
|
|
398
|
+
}, requestOptions),
|
|
399
|
+
onClientChange: rebindClientHandlers
|
|
400
|
+
}));
|
|
401
|
+
childThreadId = forkResponse.thread.id;
|
|
402
|
+
if (supervisionModelSelection && (forkResponse.model !== supervisionModelSelection.model || forkResponse.modelProvider !== supervisionModelSelection.modelProvider)) throw new Error("Codex supervised side thread did not preserve its native model and provider");
|
|
344
403
|
await client.request("thread/inject_items", {
|
|
345
404
|
threadId: childThreadId,
|
|
346
405
|
items: [sideBoundaryPromptItem()]
|
|
@@ -348,7 +407,7 @@ async function runCodexAppServerSideQuestion(params, options) {
|
|
|
348
407
|
timeoutMs: appServer.requestTimeoutMs,
|
|
349
408
|
signal: params.opts?.abortSignal
|
|
350
409
|
});
|
|
351
|
-
const effort = resolveReasoningEffort(params.resolvedThinkLevel ?? "off", modelSelection.model, readCodexSupportedReasoningEfforts(params.runtimeModel?.compat));
|
|
410
|
+
const effort = usesSupervisionConnection ? void 0 : resolveReasoningEffort(params.resolvedThinkLevel ?? "off", modelSelection.model, readCodexSupportedReasoningEfforts(params.runtimeModel?.compat));
|
|
352
411
|
turnId = assertCodexTurnStartResponse(await client.request("turn/start", {
|
|
353
412
|
threadId: childThreadId,
|
|
354
413
|
input: [{
|
|
@@ -358,15 +417,17 @@ async function runCodexAppServerSideQuestion(params, options) {
|
|
|
358
417
|
}],
|
|
359
418
|
cwd,
|
|
360
419
|
model: modelSelection.model,
|
|
361
|
-
personality: CODEX_NATIVE_PERSONALITY_NONE,
|
|
420
|
+
...usesSupervisionConnection ? {} : { personality: CODEX_NATIVE_PERSONALITY_NONE },
|
|
362
421
|
...serviceTier ? { serviceTier } : {},
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
422
|
+
...usesSupervisionConnection ? {} : {
|
|
423
|
+
effort,
|
|
424
|
+
collaborationMode: {
|
|
425
|
+
mode: "default",
|
|
426
|
+
settings: {
|
|
427
|
+
model: modelSelection.model,
|
|
428
|
+
reasoning_effort: effort,
|
|
429
|
+
developer_instructions: null
|
|
430
|
+
}
|
|
370
431
|
}
|
|
371
432
|
}
|
|
372
433
|
}, {
|
|
@@ -419,7 +480,7 @@ async function runCodexAppServerSideQuestion(params, options) {
|
|
|
419
480
|
}
|
|
420
481
|
} finally {
|
|
421
482
|
flushPendingNativePreToolUseFailures();
|
|
422
|
-
|
|
483
|
+
releaseCodexAppServerClientLease(clientLease);
|
|
423
484
|
nativeHookRelay?.unregister();
|
|
424
485
|
}
|
|
425
486
|
}
|
|
@@ -472,9 +533,12 @@ function buildSideRunAttemptParams(params, options) {
|
|
|
472
533
|
agentId: params.agentId,
|
|
473
534
|
...params.messageChannel ? { messageChannel: params.messageChannel } : {},
|
|
474
535
|
...params.messageProvider ? { messageProvider: params.messageProvider } : {},
|
|
536
|
+
...params.chatType ? { chatType: params.chatType } : {},
|
|
475
537
|
...params.agentAccountId ? { agentAccountId: params.agentAccountId } : {},
|
|
476
538
|
...params.messageTo ? { messageTo: params.messageTo } : {},
|
|
477
539
|
...params.messageThreadId !== void 0 ? { messageThreadId: params.messageThreadId } : {},
|
|
540
|
+
...params.chatId ? { chatId: params.chatId } : {},
|
|
541
|
+
...params.messageActionTurnCapability ? { messageActionTurnCapability: params.messageActionTurnCapability } : {},
|
|
478
542
|
...params.groupId !== void 0 ? { groupId: params.groupId } : {},
|
|
479
543
|
...params.groupChannel !== void 0 ? { groupChannel: params.groupChannel } : {},
|
|
480
544
|
...params.groupSpace !== void 0 ? { groupSpace: params.groupSpace } : {},
|
|
@@ -489,12 +553,13 @@ function buildSideRunAttemptParams(params, options) {
|
|
|
489
553
|
...params.toolsAllow ? { toolsAllow: params.toolsAllow } : {},
|
|
490
554
|
workspaceDir: options.cwd,
|
|
491
555
|
authProfileId: options.authProfileId,
|
|
492
|
-
authProfileIdSource: params.
|
|
556
|
+
authProfileIdSource: options.authProfileId ? params.preparedRuntimeAuth.plan.forwardedAuthProfileSource : void 0,
|
|
493
557
|
thinkLevel: params.resolvedThinkLevel ?? "off",
|
|
494
558
|
resolvedReasoningLevel: params.resolvedReasoningLevel,
|
|
495
|
-
authStorage:
|
|
496
|
-
authProfileStore:
|
|
497
|
-
modelRegistry:
|
|
559
|
+
authStorage: params.preparedRuntimeAuth.authStorage,
|
|
560
|
+
authProfileStore: params.preparedRuntimeAuth.authProfileStore,
|
|
561
|
+
modelRegistry: params.preparedRuntimeAuth.modelRegistry,
|
|
562
|
+
...params.preparedRuntimeAuth.resolvedApiKey ? { resolvedApiKey: params.preparedRuntimeAuth.resolvedApiKey } : {},
|
|
498
563
|
runId: options.runId,
|
|
499
564
|
abortSignal: params.opts?.abortSignal,
|
|
500
565
|
onAgentEvent: (event) => {
|
|
@@ -544,9 +609,12 @@ async function createCodexSideToolBridge(input) {
|
|
|
544
609
|
messageProvider: messageToolProvider,
|
|
545
610
|
toolPolicyMessageProvider: input.params.messageProvider ?? input.params.messageChannel
|
|
546
611
|
} : {},
|
|
612
|
+
...input.params.chatType ? { chatType: input.params.chatType } : {},
|
|
547
613
|
...input.params.agentAccountId ? { agentAccountId: input.params.agentAccountId } : {},
|
|
548
614
|
...input.params.messageTo ? { messageTo: input.params.messageTo } : {},
|
|
549
615
|
...input.params.messageThreadId !== void 0 ? { messageThreadId: input.params.messageThreadId } : {},
|
|
616
|
+
...input.params.chatId ? { nativeChannelId: input.params.chatId } : {},
|
|
617
|
+
...input.params.messageActionTurnCapability ? { messageActionTurnCapability: input.params.messageActionTurnCapability } : {},
|
|
550
618
|
...input.params.groupId !== void 0 ? { groupId: input.params.groupId } : {},
|
|
551
619
|
...input.params.groupChannel !== void 0 ? { groupChannel: input.params.groupChannel } : {},
|
|
552
620
|
...input.params.groupSpace !== void 0 ? { groupSpace: input.params.groupSpace } : {},
|
|
@@ -583,7 +651,7 @@ async function createCodexSideToolBridge(input) {
|
|
|
583
651
|
config: input.params.cfg,
|
|
584
652
|
webSearchAllowed: false
|
|
585
653
|
}) : requestedWebSearchPlan;
|
|
586
|
-
const exposedTools = tools.filter((tool) => tool.name !== "web_search");
|
|
654
|
+
const exposedTools = tools.filter((tool) => tool.name !== "web_search" && tool.name !== "computer");
|
|
587
655
|
const hookChannelFields = buildAgentHookContextChannelFields({
|
|
588
656
|
sessionKey: input.params.sessionKey,
|
|
589
657
|
messageChannel: input.params.messageChannel,
|