@jskit-ai/agent-docs 0.1.193 → 0.1.195

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.
Files changed (40) hide show
  1. package/guide/agent/app-extras/assistant-conversation.md +2608 -72
  2. package/guide/agent/app-extras/assistant-voice.md +244 -0
  3. package/guide/agent/app-extras/assistant.md +189 -20
  4. package/guide/agent/app-extras/realtime.md +6 -0
  5. package/guide/agent/app-setup/database-layer.md +74 -5
  6. package/guide/agent/app-setup/existing-application-migration.md +34 -29
  7. package/guide/agent/app-setup/multi-homing.md +93 -116
  8. package/guide/agent/framework/crud-operations.md +16 -2
  9. package/guide/agent/index.md +1 -0
  10. package/package.json +1 -1
  11. package/patterns/feature-package/example/booking-engine/package.json +1 -1
  12. package/patterns/minimal-foundation/example/package.json +4 -4
  13. package/patterns/shell-foundation/example/package.json +5 -5
  14. package/patterns/shell-foundation/example/packages/main/package.json +1 -1
  15. package/reference/autogen/PATTERN_INDEX.md +35 -35
  16. package/reference/autogen/README.md +2 -0
  17. package/reference/autogen/packages/assistant-core.md +974 -9
  18. package/reference/autogen/packages/assistant-runtime.md +126 -28
  19. package/reference/autogen/packages/assistant-voice-sherpa.md +82 -0
  20. package/reference/autogen/packages/assistant-voice.md +227 -0
  21. package/reference/autogen/packages/kernel.md +10 -0
  22. package/reference/autogen/packages/realtime.md +5 -2
  23. package/skills/jskit/SKILL.md +1 -1
  24. package/skills/jskit/references/crud-operations.md +16 -2
  25. package/skills/jskit/references/existing-application-migration.md +34 -29
  26. package/skills/jskit/references/multi-homing.md +93 -116
  27. package/skills/jskit/references/pattern-index.md +35 -35
  28. package/skills/jskit/references/patterns/app/minimal-foundation/example/package.json +4 -4
  29. package/skills/jskit/references/patterns/app/shell-foundation/example/package.json +5 -5
  30. package/skills/jskit/references/patterns/app/shell-foundation/example/packages/main/package.json +1 -1
  31. package/skills/jskit/references/patterns/auth/supabase-auth/example/package.json +1 -1
  32. package/skills/jskit/references/patterns/connectors/calendar-cli/example/package.json +4 -4
  33. package/skills/jskit/references/patterns/crud/json-api-resource-package/example/packages/books/package.json +2 -2
  34. package/skills/jskit/references/patterns/database/mysql-application/example/package.json +1 -1
  35. package/skills/jskit/references/patterns/database/postgres-application/example/package.json +1 -1
  36. package/skills/jskit/references/patterns/realtime/realtime-application/example/package.json +2 -2
  37. package/skills/jskit/references/patterns/server/feature-package/example/booking-engine/package.json +1 -1
  38. package/skills/jskit/references/patterns/users/user-administration-server/example/packages/users/package.json +2 -2
  39. package/skills/jskit/references/patterns/users/user-administration-server/example/packages/users-workspace/package.json +3 -3
  40. package/skills/jskit/references/patterns/workspaces/workspace-server/PATTERN.md +23 -28
@@ -72,6 +72,10 @@ Local functions
72
72
  - `stop()`
73
73
  - `updateConfiguration(value)`
74
74
 
75
+ ### `src/client/conversation/AssistantConversationStatus.vue`
76
+ Exports
77
+ - None
78
+
75
79
  ### `src/client/conversation/AssistantGoalControl.vue`
76
80
  Exports
77
81
  - None
@@ -148,12 +152,14 @@ Local functions
148
152
  Exports
149
153
  - `AssistantConversationElement`
150
154
  - `AssistantTranscript`
155
+ - `AssistantConversationStatus`
151
156
  - `AssistantPromptInput`
152
157
  - `AssistantComposerActions`
153
158
  - `AssistantProgress`
154
159
  - `AssistantComposerSupport`
155
160
  - `AssistantGoalControl`
156
161
  - `useAssistantSuggestions`
162
+ - `useAssistantQuestions`
157
163
  - `LongTextPreviewBlocks`
158
164
  - `LongTextInlineParts`
159
165
  - `useScrollToBottom`
@@ -185,11 +191,16 @@ Local functions
185
191
  ### `src/client/conversation/messageDelivery.js`
186
192
  Exports
187
193
  - `createAssistantMessageDelivery({ deliver: defaultDeliver } = {})`
188
- - `unmatchedOptimisticMessages(turns = [], optimisticMessages = [])`
194
+ - `unmatchedOptimisticMessages(turns = [], optimisticMessages = [], { receiptsOnly = false } = {})`
195
+ - `retainAssistantConversation`
189
196
  Local functions
190
197
  - `messageText(value)`
191
198
  - `turnMatchesOptimisticMessage(turn = {}, optimistic = {})`
192
199
 
200
+ ### `src/client/conversation/retainedConversation.js`
201
+ Exports
202
+ - `retainAssistantConversation(app, key, createRuntime, reader = { active: true })`
203
+
193
204
  ### `src/client/conversation/submitText.js`
194
205
  Exports
195
206
  - `createAssistantTextSubmission({ getState, setDraft, submit, afterDraftChange = async () => {} })`
@@ -218,6 +229,10 @@ Local functions
218
229
  - `attachmentProgress(progress = {}, possibleTotal, fallbackTotal = 0)`
219
230
  - `attachmentReceipt(row, uploaded = {})`
220
231
 
232
+ ### `src/client/conversation/useAssistantQuestions.js`
233
+ Exports
234
+ - `useAssistantQuestions({ message = "", extraChoice = null } = {})`
235
+
221
236
  ### `src/client/conversation/useAssistantSuggestions.js`
222
237
  Exports
223
238
  - `useAssistantSuggestions({ active = true, requestKey = "", draft = "", configuration = {}, generate, onSelect = () => false, debounceMs = 750 } = {})`
@@ -254,6 +269,79 @@ Local functions
254
269
  Exports
255
270
  - `assistantHttpClient`
256
271
 
272
+ ### `src/server/conversation/agentRun.js`
273
+ Exports
274
+ - `conversationAgentRunRecord(record, normalizedRunId, { normalizeState = normalizeRunState, isActive = runStateIsActive } = {})`
275
+ - `conversationAgentRunEvent(previous, normalizedRunId, { event = {}, patch = {} } = {}, { now = () => new Date(), normalizeState = normalizeRunState, isTerminal = runStateIsTerminal } = {})`
276
+ - `createCodexConversationRunStore({ storage, scope, segmentId, isCurrent, clock = () => new Date() } = {})`
277
+ - `createCodexConversationStore({ storage, scope, segmentId, isCurrent, transcript, streams } = {})`
278
+ Local functions
279
+ - `normalizeRunState(state)`
280
+ - `runStateIsActive(state)`
281
+ - `runStateIsTerminal(state)`
282
+
283
+ ### `src/server/conversation/attachments.js`
284
+ Exports
285
+ - `conversationAttachmentIds(value = [])`
286
+ - `createConversationAttachmentReader({ attachments, context, conversationId, signal, authorize, types, maximumBytes })`
287
+ Local functions
288
+ - `invalid(message)`
289
+
290
+ ### `src/server/conversation/claudeClient.js`
291
+ Exports
292
+ - `CLAUDE_JSON_MAX_FRAME_BYTES`
293
+ - `createClaudeJsonClient({ stream, onEvent = async () => {}, onControlRequest, onFailure = async () => {}, timeoutMs = 30_000 } = {})`
294
+ - `readClaudeJsonFrames`
295
+ Local functions
296
+ - `claudeProtocolError(message, code = "assistant_claude_protocol_error")`
297
+
298
+ ### `src/server/conversation/claudeHistory.js`
299
+ Exports
300
+ - `listClaudeConversationStorage({ configRoot, binding })`
301
+ - `deleteClaudeConversationHistory({ configRoot, workdir, conversationId })`
302
+ - `retireClaudeConversationHistory({ configRoot, binding, beforeDelete, requireIdle, signal })`
303
+ - `claudeMessageBlocks(frame, { includeNested = false } = {})`
304
+ - `readClaudeHistory(options)`
305
+ - `requireClaudeSessionId(id)`
306
+ - `archivedClaudeProjectDirectory(workdir)`
307
+ - `matchingClaudeProjectDirectories(names, directory)`
308
+ Local functions
309
+ - `claudeHistoryPath({ configRoot, workdir, conversationId })`
310
+
311
+ ### `src/server/conversation/claudeProcess.js`
312
+ Exports
313
+ - `readClaudeCodeAuthStatus({ env = process.env, credentialHome = { home: env.HOME || homedir() }, command = "claude", commandRunner, signal } = {})`
314
+ - `claudeModelConfiguration({ providerId, model: modelId }, connection)`
315
+ - `verifyClaudeProviderKey(provider, apiKey, fetchImpl)`
316
+ - `claudeFlagSettings({ effort = "", providerEnv, hooks, commandHook } = {})`
317
+ - `claudeCodeArguments({ sessionId, resume = false, model = "", effort = "", toolFree = false, applicationTools = false, outputSchema, terminal = false, instructionArguments = [], permissionMode, isolated = false, settings = { fallbackModel: [] } } = {})`
318
+ - `stopClaudeCodeProcess({ process: native, executionId, stopExecution })`
319
+ - `bindClaudeConversationAccount(entry, { identity, providerId, stop, save })`
320
+ - `claudePlanUsage(value)`
321
+ - `claudeCatalogueModels(initialization)`
322
+ - `createClaudeAccountQueries({ createProcess, accountIdentity, processes = () => [], isClosing = () => false })`
323
+ - `createClaudeCodeProcess({ command = "claude", execution = createLocalConversationExecution(), env = process.env, workdir, onEvent, onControlRequest, onFailure, onStarted, executionLimits, signal, commandWrapper, ...options } = {})`
324
+ Local functions
325
+ - `readNativeClaudeCodeAuthStatus({ env, credentialHome, command, commandRunner, signal })`
326
+
327
+ ### `src/server/conversation/claudeTools.js`
328
+ Exports
329
+ - `claudeApplicationToolResponse(request, { schemas, turn, signal })`
330
+ - `CLAUDE_APPLICATION_TOOL_SERVER`
331
+
332
+ ### `src/server/conversation/claudeTurn.js`
333
+ Exports
334
+ - `claudeNativeMessageId(id)`
335
+ - `waitForClaudeConversationTurn(conversation, input = {}, { signal, defaultTimeoutMs = 180_000, maximumTimeoutMs = Infinity, createError = failure, interruptedMessage = "Claude was interrupted when the application disconnected." } = {})`
336
+ - `runClaudeRenewalTurn(conversation, { clientMessageId, prompt, outputSchema, expectedThreadId, forbiddenThreadId, requireFreshHistory = false, timeoutMs = 180_000 }, { createError = failure, unreadableCode = "assistant_claude_turn_unreadable", failedCode = "assistant_claude_turn_failed", acceptedField = "inputAccepted" } = {})`
337
+ - `createClaudeConversationGoals({ conversationId, readHistory, readState, interrupt, send })`
338
+ - `createClaudeConversationOwner({ configRoot, store, preparation, process, onEvent, createError = failure, disconnectedMessage = "Claude was interrupted when the application disconnected." })`
339
+ - `createClaudeConversationTurn({ conversationId, onEvent = async () => {}, process, entry } = {})`
340
+ Local functions
341
+ - `failure(message, code = "assistant_claude_turn_failed")`
342
+ - `text(value)`
343
+ - `now()`
344
+
257
345
  ### `src/server/conversation/codexClient.js`
258
346
  Exports
259
347
  - `CodexAppServerJsonRpcClient`
@@ -264,9 +352,64 @@ Local functions
264
352
  - `addSocketListener(socket, eventName, handler)`
265
353
  - `socketMessageText(event, maxBytes = Number.POSITIVE_INFINITY)`
266
354
 
355
+ ### `src/server/conversation/codexConfiguration.js`
356
+ Exports
357
+ - `normalizeCodexThreadId(value)`
358
+ - `codexAppServerThreadSettings({ effectiveSettings, config = null, cwd = "", systemPrompt = null, hostContext = null, model = "", approvalPolicy, reasoningSummary, sandbox } = {})`
359
+ - `codexAppServerReadOnlyThreadSettings(settings)`
360
+ - `codexAppServerTurnSettings({ effectiveSettings, cwd = "", effort = "", model = "", approvalPolicy, reasoningSummary, sandboxPolicy, externalSandbox = false } = {})`
361
+ - `codexInteractiveArguments({ command, threadId = "", remoteEndpoint = "", model, effort, disableStartupUpdates = false, bypassApprovalsAndSandbox = false, bypassHookTrust = false } = {})`
362
+ - `codexAppServerProjectHookTrustConfig(provider, cwd = "", { persist = false } = {})`
363
+ - `prepareCodexModelCatalog({ command, runtimeDir, bundled = false, signal, additionalModels = [] })`
364
+ - `codexAppServerTextHasControlCharacters(value = "")`
365
+ - `createCodexAppServerIsolation({ clientName = "jskit", minimumVersion = "0.151.0", disabledFeatures = DISABLED_FEATURES, limits: { userAgentMaxLength = 512, mcpServerMaxCount = 128, mcpServerNameMaxLength = 256, configResponseMaxBytes = 256 * 1024, hookMaxCount = 256, hookErrorMaxCount = 256, hookFieldMaxLength = 2048, hookFingerprintMaxLength = 256 * 1024, hookResponseMaxBytes = 512 * 1024 } = {}, createError = codexAppServerIsolationPolicyError } = {})`
366
+ - `codexToolFreeConfiguration(options)`
367
+ - `readCodexToolFreeConfiguration(provider = null, workdir = "", assertCompatibility = codexConversationIsolation.assertCompatibility)`
368
+ - `codexCatalogRows(value = null, createError = message => new Error(message))`
369
+ - `codexCatalogReasoningEfforts(model = {})`
370
+ - `codexCatalogModels(rows)`
371
+ - `codexConfiguredModelCatalog(includeModel, model, reasoningEffort)`
372
+ - `codexProviderModelCatalog({ models })`
373
+ - `codexProviderConfiguration(provider, apiKey)`
374
+ - `codexProviderFileConfiguration(provider, key, codexHome)`
375
+ - `verifyCodexProviderKey(provider, apiKey, fetchImpl = fetch)`
376
+ - `createCodexAccountReader({ errorPrefix = "", identityNamespace = "codex-account-v1", secretNamespace = "codex-auth-secret-v1" } = {})`
377
+ - `codexAuthOutputRequiresReconnect(output = "")`
378
+ - `CODEX_APP_SERVER_ACCOUNT_ID_MAX_LENGTH`
379
+ Local functions
380
+ - `isPlainRecord(value)`
381
+ - `deepFreezeCodexAppServerHelperConfig(value)`
382
+ - `codexAppServerIsolationPolicyError(message = "", details = {})`
383
+
384
+ ### `src/server/conversation/codexConversations.js`
385
+ Exports
386
+ - `createCodexConversationCommands({ checkpoint, codexAppServerConversationMessageId, codexAppServerStreamMessage, conversationPreparation, ensureCodexAppServerProviderForActiveTurn, errorPrefix, helperLifecycle, helperOwnershipError, interruptFailedCode, namespace, providerSessions, steerFailedCode })`
387
+
388
+ ### `src/server/conversation/codexDetachedTurn.js`
389
+ Exports
390
+ - `CODEX_APP_SERVER_DETACHED_TURN_TIMEOUT_MS`
391
+ - `createCodexAppServerDetachedTurnWatcher(provider = null, threadId = "", { includeThreadHistory = true, allowEmptyResponse = false, onEvent = null, timeoutMs = CODEX_APP_SERVER_DETACHED_TURN_TIMEOUT_MS } = {})`
392
+ - `waitForCodexAppServerTurn(provider, threadId = "", turn = null, { timeoutMs = CODEX_APP_SERVER_DETACHED_TURN_TIMEOUT_MS, createError = codexAppServerTurnError } = {})`
393
+ Local functions
394
+ - `codexAppServerTurnTokenUsage(notification = {})`
395
+ - `codexAppServerTurnError(reason, details = {}, providerMessage = "")`
396
+
267
397
  ### `src/server/conversation/codexEvents.js`
268
398
  Exports
399
+ - `codexContextUsageFromNotification(notification = {})`
269
400
  - `classifyCodexAppServerEvent(notification = {})`
401
+ - `codexAppServerThreadRawValue(thread = {})`
402
+ - `codexAppServerThreadTurnId(thread = {})`
403
+ - `codexAppServerThreadError(thread = {})`
404
+ - `codexAppServerProviderThreadTurns(thread = null)`
405
+ - `codexAppServerProviderTurnId(turn = {})`
406
+ - `codexAppServerProviderTurnStatus(turn = {})`
407
+ - `codexAppServerProviderTurnItems(turn = {})`
408
+ - `codexAppServerProviderTurnClientIds(turn = {})`
409
+ - `codexAppServerProviderTurnForOperation(thread = null, { clientMessageId = "", turnId = "" } = {})`
410
+ - `inspectCodexAppServerRenewalThread(thread = null, { clientMessageId = "", turnId: expectedTurnId = "", requireFresh = false } = {})`
411
+ - `codexAppServerProviderTurnText(thread = null, turnId = "")`
412
+ - `codexAppServerProviderTurnError(turn = {})`
270
413
  - `codexAppServerAssistantItemText(item = {})`
271
414
  - `codexAppServerContentText(value = null)`
272
415
  - `codexAppServerContextRefreshReason(notification = {})`
@@ -287,37 +430,426 @@ Exports
287
430
  - `codexAppServerStatusFromValue(status = null)`
288
431
  - `codexAppServerUserMessageText(item = {})`
289
432
  Local functions
433
+ - `nonNegativeInteger(value)`
290
434
  - `codexAppServerTextInputText(input = {})`
291
435
  - `codexAppServerHookPromptText(item = {})`
292
436
  - `codexAppServerFinalEventText(notification = {}, event = null, payload = {})`
293
437
  - `codexAppServerSignalName(value = "")`
294
438
  - `codexAppServerSignalNames(value = null)`
295
439
  - `codexAppServerProviderThread(value = {})`
296
- - `codexAppServerProviderTurnId(turn = {})`
297
- - `codexAppServerProviderTurnItems(turn = {})`
298
440
  - `codexAppServerProviderThreadTurn(value = {}, turnId = "")`
299
441
  - `codexAppServerProviderTurnAssistantSegments(turn = {})`
300
442
 
443
+ ### `src/server/conversation/codexGoalCommands.js`
444
+ Exports
445
+ - `createCodexGoalCommands({ conversationContext, ensureThreadReady, publish, readCodexAppServerAgentRunForSession, reconcileCodexAppServerGoalUpdated, submitCodexAppServerAssistantResult, subscribeCodexAppServerEvents, turnState })`
446
+
447
+ ### `src/server/conversation/codexHelperExecution.js`
448
+ Exports
449
+ - `errorMessage(value, fallback = "Codex could not be prepared.")`
450
+ - `createCodexHelperOwnershipError({ applicationName = "Application", errorPrefix = "" } = {})`
451
+ - `readCodexAppServerAccountIdentity(provider, codexAppServerHelperOwnershipError)`
452
+ - `assertCodexAppServerHelperAccountIdentity(provider, expectedSignature = "", codexAppServerHelperOwnershipError)`
453
+ - `sendPreparedCodexAppServerHelperTurn(provider, prepared, helperIsolation)`
454
+ - `prepareDetachedCodexHelperThread(owner, scope, preparation, { applicationName = "Application" } = {})`
455
+ Local functions
456
+ - `normalizeText(value)`
457
+
458
+ ### `src/server/conversation/codexHelperThreadLedger.js`
459
+ Exports
460
+ - `CODEX_HELPER_THREAD_LEDGER_SCHEMA_VERSION`
461
+ - `CODEX_HELPER_THREAD_LIFECYCLES`
462
+ - `createCodexHelperThreadLedgerOwner({ executionProfile, snapshotExecutionProfile = executionProfile, errorPrefix = "codex_helper_" } = {})`
463
+
464
+ ### `src/server/conversation/codexHelperThreadRecovery.js`
465
+ Exports
466
+ - `normalizeText(value)`
467
+ - `directoryExists(filePath = "")`
468
+ - `createCodexHelperThreadRecovery(lifecycle, { providerOwner, applicationName, errorPrefix })`
469
+
470
+ ### `src/server/conversation/codexHelperThreads.js`
471
+ Exports
472
+ - `createCodexHelperThreadLifecycle({ providerOwner, ledgerOwner, applicationName = "Application", errorPrefix = "" } = {})`
473
+ Local functions
474
+ - `isRecord(value)`
475
+
476
+ ### `src/server/conversation/codexHistoryAdapter.js`
477
+ Exports
478
+ - `startCodexHistoryAdapter({ token, codexHome, readHistoryPath, fetchImpl = fetch, maxRequestBytes = MAX_REQUEST_BYTES } = {})`
479
+ - `translateCodexHistory(body, destination = "openai")`
480
+ - `prepareCodexHistory(params, client, { baseUrl, modelProviderId, ...options } = {})`
481
+ Local functions
482
+ - `compactionHistoryError(reason, statusCode = 422)`
483
+ - `restoreCompactedHistory(body, { destination, historyPath, codexHome, signal, maxRequestBytes })`
484
+ - `forwardedHeaders(input)`
485
+
486
+ ### `src/server/conversation/codexMessageCommands.js`
487
+ Exports
488
+ - `createCodexMessageCommands({ output, journal, recovery, threadStatus, selection, observer, delivery, promptDeliveries: codexAppServerPromptDeliveries, createRuntime, debugError, debugLog, errorPrefix, messageIdPrefix, messageMetadata, namespace, providerSessions, recoverAdmission, steerFailedCode, turnAlreadyRunningError, turnState })`
489
+
490
+ ### `src/server/conversation/codexMessageDelivery.js`
491
+ Exports
492
+ - `createCodexAppServerMessageDelivery({ namespace, publish, messageMetadata, createStore, turnStateFromAgentRun, deliveryStateMetadataKey, output, journal, recovery })`
493
+
494
+ ### `src/server/conversation/codexNativeHistoryExport.js`
495
+ Exports
496
+ - `exportCodexNativeHistory(client, threadId, onRecord, { signal, maxPages = 20_000, maxBytes = 2 * 1024 ** 3, errorPrefix = "" } = {})`
497
+ Local functions
498
+ - `threadHistoryMetadata(thread)`
499
+
500
+ ### `src/server/conversation/codexNotificationObserver.js`
501
+ Exports
502
+ - `createCodexNotificationObserver({ journal, recovery, threadStatus, output, delivery, notificationQueue, namespace, createRuntime, createStore, publish, captureContext, debugLog, onNotificationSignal, turnStateFromAgentRun })`
503
+
504
+ ### `src/server/conversation/codexNotificationQueue.js`
505
+ Exports
506
+ - `createCodexAppServerNotificationQueue({ namespace = normalizeCodexRunText, isClosing = () => false, runInContext = (_context, operation) => operation(), reportError = () => {} } = {})`
507
+
508
+ ### `src/server/conversation/codexObservationControl.js`
509
+ Exports
510
+ - `createCodexObservationControl({ conversations, output, journal, namespace, createRuntime, publish, runInContext, turnState, errorPrefix })`
511
+
512
+ ### `src/server/conversation/codexOutput.js`
513
+ Exports
514
+ - `createCodexAppServerOutput({ namespace, createRuntime, createStore, publish, acquireProvider, turnState, turnStateFromAgentRun, debugLog, debugError, liveProgressMaxLength, storeReadError, messageMetadata, snapshotRecoveryItemLimit })`
515
+
516
+ ### `src/server/conversation/codexProcess.js`
517
+ Exports
518
+ - `runCodexAppServerProcess({ runtimeDir, command, args = [], runtimeToken: token, bundled = false, additionalModels = [] })`
519
+ - `ensureWritablePrivateDirectory(dirPath = "")`
520
+ - `codexAppServerMetadataPath(runtimeDir = "")`
521
+ - `normalizeCodexAppServerMetadata(metadata = {})`
522
+ - `readCodexAppServerMetadata(runtimeDir = "")`
523
+ - `writeCodexAppServerMetadata(runtimeDir = "", metadata = {})`
524
+ - `fileExists(filePath = "")`
525
+ - `tailTextFile(filePath = "", maxBytes = 4096)`
526
+ - `acquireCodexRuntimeLock(runtimeDir = "", { busyCode = "codex_runtime_busy", timeoutMs = CODEX_APP_SERVER_LOCK_TIMEOUT_MS } = {})`
527
+ - `codexAppServerExecutionMode(options = {})`
528
+ - `codexAppServerIsHelper(options = {})`
529
+ - `assertExistingDirectory(dirPath = "", label = "directory")`
530
+ - `codexAppServerHelperHomeDir(runtimeDir = "")`
531
+ - `codexAppServerHelperWorkspaceDir(runtimeDir = "")`
532
+ - `codexAppServerProcessCwd({ executionRoot = "", runtimeDir = "", workdir = "" } = {})`
533
+ - `codexAppServerRuntimeIdentity(runtime = {})`
534
+ - `normalizeCodexAppServerTerminalEnv(terminalEnv = {})`
535
+ - `codexAppServerCommandBaseEnv({ env = process.env, terminalEnv = {} } = {})`
536
+ - `codexAppServerCredentialHome(toolHomeSource = "", baseEnv = {})`
537
+ - `codexAppServerTerminalEnvHash(terminalEnv = {})`
538
+ - `createCodexAppServerRuntime({ execution, credentials, configuration = {} })`
539
+ - `CODEX_APP_SERVER_METADATA_SCHEMA_VERSION`
540
+ - `CODEX_APP_SERVER_TRANSPORT`
541
+ - `CODEX_APP_SERVER_RUNTIME_DIR_NAME`
542
+ - `CODEX_APP_SERVER_PROCESS_STATE`
543
+ Local functions
544
+ - `ensurePrivateDirectory(dirPath = "")`
545
+ - `codexAppServerLockDir(runtimeDir = "")`
546
+ - `readLockOwner(lockDir = "")`
547
+ - `lockIsStale(lockDir = "")`
548
+ - `normalizePositiveInteger(value, fallback)`
549
+ - `stableHash(value)`
550
+ - `codexAppServerHelperCommandBaseEnv(env = process.env, codexHome = "")`
551
+ - `codexAppServerLogPath(runtimeDir = "")`
552
+ - `codexAppServerSocketPath(runtimeDir = "")`
553
+ - `codexAppServerSocketPathBytes(socketPath = "")`
554
+ - `codexAppServerSocketPathTooLong(socketPath = "")`
555
+ - `codexAppServerUnixEndpoint(socketPath = "")`
556
+ - `codexAppServerProjectTrustOverride(workdir = "")`
557
+ - `codexAppServerRuntimeDirIsManaged(runtimeDir = "")`
558
+ - `removeCodexAppServerRuntimeDir(runtimeDir = "")`
559
+ - `removeCodexAppServerMetadataTemps(runtimeDir = "")`
560
+ - `codexAppServerRuntimeCleanupCanSkip(error)`
561
+ - `codexHistoryAdapterUrlIsValid(baseUrl, token)`
562
+ - `codexAppServerLivenessTimeoutMs(options = {})`
563
+ - `codexAppServerProcessCommandHash({ codexArgs = [], codexCommand = "", executionMode = "", processCwd = "", runtimeDir = "" } = {})`
564
+
565
+ ### `src/server/conversation/codexProcessLeader.js`
566
+ Exports
567
+ - None
568
+
569
+ ### `src/server/conversation/codexProvider.js`
570
+ Exports
571
+ - `CodexAppServerAgentProvider`
572
+ - `CODEX_APP_SERVER_INVALID_REQUEST_CODE`
573
+ - `assertCodexAuthPreflightReady(options = {}, { reason = "codex-auth-preflight", execution, credentials } = {})`
574
+ - `createCodexAppServerModelCatalogCache({ cacheMs = 30_000, errorPrefix = "" } = {})`
575
+ - `codexAppServerProviderConnectionGeneration(provider = null)`
576
+ - `ensureCodexAppServerThread({ observeThread, provider, settings, projectHooks = false, identity, workdir = "", onStage = () => {} } = {})`
577
+ - `sendCodexAppServerPrompt({ attachments = [], clientUserMessageId = "", outputSchema = null, provider, prompt = "", threadId = "", readOnly = false } = {}, authorized = {})`
578
+ - `resumeExactCodexAppServerThread({ expectedThreadId = "", provider, settings, projectHooks = false, workdir = "", errorCode = "codex_renewal_thread_unreadable" } = {})`
579
+ - `startFreshCodexAppServerThread({ provider, settings, projectHooks = false, identity, resumableThreadId = "", forbiddenThreadId = "", operationId = "", workdir = "", errorCode = "codex_renewal_fresh_thread_required", applicationName = "The application" } = {})`
580
+ - `defineCodexRenewalThreadIds(value = [], { errorCode = "codex_renewal_fresh_thread_required" } = {})`
581
+ - `codexRenewalThreadError(code, message, details = {}, { retryable = false } = {})`
582
+ - `codexAppServerEndpointForTarget(endpoint = "")`
583
+ - `codexAppServerRequestIsInvalid(error = null, method = "")`
584
+ - `codexAppServerThreadIsMissing(error = null, threadId = "")`
585
+ - `codexAppServerThreadHasReadableHistory(provider = null, threadId = "")`
586
+ - `deleteCodexAppServerThread({ provider, threadId } = {})`
587
+ - `deleteCodexAppServerHelperThread({ provider, threadId, turnId = "" } = {})`
588
+ - `inspectCodexAppServerMessageAdmission({ provider, threadId, messageId } = {})`
589
+ - `codexCliResumeCommand({ codexCommand = "", endpoint = "", threadId = "" } = {})`
590
+ - `codexLocalImageInput(attachments = [])`
591
+ - `codexTextInput(text = "")`
592
+ - `codexTurnInput(input = [])`
593
+ - `shellQuote(value = "")`
594
+ - `exportCodexNativeHistory`
595
+ - `retireCodexConversationHistory(provider, binding, { toolHomeSource, beforeDelete, signal, errorPrefix = "" } = {})`
596
+ - `createCodexAppServerProviderOwner`
597
+ - `codexAppServerOwnedRuntimeKey`
598
+ - `codexAppServerRuntimeStopWasVerified`
599
+ Local functions
600
+ - `normalizePositiveInteger(value, fallback)`
601
+ - `listCodexRenewalThreadIds(provider, workdir, errorCode)`
602
+ - `assertCodexRenewalThreadSnapshot(threadSnapshot = null, { threadId = "", workdir = "", errorCode } = {})`
603
+ - `codexRenewalThreadNeedsStatusRead(error = null, threadId = "")`
604
+ - `readCodexRenewalSuccessorThreadSnapshot({ provider, threadId = "", workdir = "", errorCode } = {})`
605
+ - `codexAppServerThreadResponseId(thread = null, fallback = "")`
606
+ - `codexAppServerModelCatalogError(message = "", errorPrefix = "")`
607
+ - `codexAppServerModelCatalogSnapshot(value = null, errorPrefix = "")`
608
+ - `codexAppServerHelperLoginParams(auth = {}, errorPrefix = "")`
609
+ - `codexAppServerHelperLoginResponseType(auth = {})`
610
+ - `codexAppServerHelperAccountType(auth = {})`
611
+ - `codexAppServerHelperRequestError(error = null, reason = "", errorPrefix = "")`
612
+ - `normalizeCodexAppServerInfo(initializeResult = null)`
613
+ - `tailAppend(text = "", chunk = "", maxBytes = CODEX_AUTH_PREFLIGHT_OUTPUT_TAIL_BYTES)`
614
+ - `codexAuthPreflightArgs()`
615
+ - `runCodexAuthPreflight({ codexCommand = "codex", env = process.env, executionRoot = "", runtimeDir = "", terminalEnv = {}, timeoutMs = CODEX_AUTH_PREFLIGHT_TIMEOUT_MS, toolHomeSource = "", workdir = "" } = {}, execution)`
616
+ - `codexAppServerThreadRequestParams(params = {}, threadEnv = {})`
617
+ - `codexControlProbeCommand(keys, marker)`
618
+ - `codexAppServerThreadInventoryError(errorCode, label, detail)`
619
+ - `listBoundedCodexAppServerThreadIds({ ancestorThreadId = "", archived = false, client, cwd = "", errorCode = "", label = "", requestLabel = "", runRequest, signal = null, sourceKinds = ["appServer"], state, verifyCwd = false } = {})`
620
+ - `codexPlanUsage(limits = {})`
621
+ - `normalizeAgentThread(value = {})`
622
+ - `normalizeAgentTurn(value = {})`
623
+
624
+ ### `src/server/conversation/codexProviderOwner.js`
625
+ Exports
626
+ - `codexAppServerOwnedRuntimeKey(providerKey = "", providerOptions = {})`
627
+ - `codexAppServerRuntimeStopWasVerified(result = {})`
628
+ - `createCodexAppServerProviderOwner({ runtimeRoot = "", assertOpen: assertApplicationOpen = () => {}, onRecoveryEvent = () => {}, debugLog = () => {}, debugError = error => error, providerFactory = null, prepareNativeHost = () => ({}), runtimeBusyCode = "codex_app_server_runtime_busy", exitUnverifiedCode = "codex_runtime_exit_unverified", requiredStopCode = "codex_runtime_exit_unverified", runtimeCloseError = "Codex app-server runtime close failed." } = {})`
629
+ Local functions
630
+ - `normalizeText(value)`
631
+ - `directoryExists(filePath = "")`
632
+
633
+ ### `src/server/conversation/codexProviderSelection.js`
634
+ Exports
635
+ - `createCodexProviderSelection({ providerSessions, turnState, helperLifecycle, helperOwnershipError, modelCatalogCacheMs, errorPrefix })`
636
+
637
+ ### `src/server/conversation/codexReasoning.js`
638
+ Exports
639
+ - `createCodexAppServerReasoning({ createStore, publish, turnStateFromAgentRun, debugLog, readCodexAppServerAgentRunForSession })`
640
+
641
+ ### `src/server/conversation/codexRenewalCommands.js`
642
+ Exports
643
+ - `createCodexRenewalCommands({ claimCodexAppServerTurnStart, codexAppServerNotificationQueue, completeCodexAppServerTurn, errorPrefix, markCodexAppServerTurnActive, markCodexAppServerTurnIdle, observer, selection, turnAlreadyRunningError, writeCodexAppServerUserMessageOwnership })`
644
+
645
+ ### `src/server/conversation/codexResultSettlement.js`
646
+ Exports
647
+ - `createCodexResultSettlement({ journal, output, createRuntime, publish, debugLog, debugError, turnState })`
648
+
649
+ ### `src/server/conversation/codexRunJournal.js`
650
+ Exports
651
+ - `createCodexRunJournal({ namespace, normalizeRunState, turnState, createRuntime, publish, checkpoint, debugLog, output, messageIdPrefix, sessionIdRequiredError, turnClaimsUnsupportedError, turnAlreadyRunningError, errorPrefix, idlePublishPayload, finalizingGraceMs, admissionTaskFinished, orphanedPromptMessage })`
652
+
653
+ ### `src/server/conversation/codexRuntimeLifecycle.js`
654
+ Exports
655
+ - `createCodexRuntimeLifecycle({ runOwner, providerSessions, helperLifecycle, captureContext, runInContext, debugLog, debugError, closingError = null })`
656
+
657
+ ### `src/server/conversation/codexSessionCleanup.js`
658
+ Exports
659
+ - `createCodexSessionCleanup({ namespace, runOwner, providerSessions, helperLifecycle, journal, conversations, debugLog, debugError })`
660
+
661
+ ### `src/server/conversation/codexSessionReconciliation.js`
662
+ Exports
663
+ - `createCodexSessionReconciliation({ runOwner, providerSessions, helperLifecycle, lifecycle, createRuntime, namespace, turnState, sessionIdRequiredError, debugLog, debugError })`
664
+
665
+ ### `src/server/conversation/codexThreadReadiness.js`
666
+ Exports
667
+ - `createCodexThreadReadiness({ providerSessions, selection, observer, threadStatus, recovery, turnState, debugLog, debugError })`
668
+
669
+ ### `src/server/conversation/codexThreadStatus.js`
670
+ Exports
671
+ - `createCodexThreadStatus({ journal, settlement, recovery, output, createRuntime, turnState, turnOutcomes, debugLog, debugError })`
672
+
301
673
  ### `src/server/conversation/codexTurn.js`
302
674
  Exports
303
- - `createCodexAppServerDetachedTurnWatcher(provider = null, threadId = "", { includeThreadHistory = true, onEvent = null, timeoutMs = CODEX_APP_SERVER_DETACHED_TURN_TIMEOUT_MS } = {})`
675
+ - `createCodexAppServerRunOwner({ namespace = normalizeCodexRunText, normalizeRunState = normalizeCodexAppServerRunState, debugLog = () => {}, debugError = error => normalizeCodexRunText(error?.message || error), createRuntime, createStore, publish = async () => null, acquireProvider = async () => null, providerSessions = null, serverClosingError = null, helperThreads = null, modelCatalogCacheMs = 30_000, conversationPreparation = null, storeReadError = "The session store does not support agent-run reads.", sessionIdRequiredError = "A session ID is required.", turnClaimsUnsupportedError = "The session runtime does not support Codex turn claims.", turnAlreadyRunningError = "Codex is already working on this session.", messageIdPrefix = "codex:", idlePublishPayload = null, checkpoint = async () => null, messageMetadata = {}, deliveryStateMetadataKey = "assistant_delivery", hasRuntime = () => true, recoverAdmission = null, admissionTaskFinished = () => false, outcomeNotice = async () => null, resultDeliveryFailureMessage = ({ error = "" } = {}) => { const detail = normalizeCodexRunText(error); if (!detail) return "Codex app-server finished this turn, but the assistant result text was not received."; const punctuation = [".", "!", "?"].some(character => detail.endsWith(character)) ? "" : "."; return "Codex completed, but its response could not be processed: " + detail + punctuation; }, orphanedPromptMessage = "The application restarted before Codex confirmed the message. Your message is safe; retry it.", onNotificationSignal = async () => null, captureContext = () => null, runInContext = (_context, operation) => operation(), notificationQueue = null, activeReconcileMs = 2000, steerFailedCode = "codex_turn_steer_failed", interruptFailedCode = "codex_turn_interrupt_failed", errorPrefix = "" } = {})`
676
+ - `CODEX_APP_SERVER_RUN_STATE`
677
+ - `normalizeCodexAppServerRunState`
678
+ - `codexAppServerRunStateIsActive`
679
+ - `codexAppServerRunStateIsTerminal`
680
+ - `codexAppServerAgentRun`
681
+ - `codexAppServerPendingUserMessageClientIds`
682
+ - `codexAppServerPendingUserMessageOwnership`
683
+ - `codexAppServerProcessedResultEvent`
684
+ - `codexAppServerTurnStateFromAgentRun`
685
+ - `codexAppServerTurnState`
686
+ - `codexAppServerTurnOwnsActiveGoal`
687
+ - `codexAppServerTurnMatches`
688
+ - `codexAppServerTurnCanReceiveProviderCompletion`
689
+ - `codexAppServerTurnAwaitsProviderIdentity`
690
+ - `codexAppServerTurnCanReceiveProviderActivity`
691
+ - `codexAppServerTurnCanAdoptSuccessor`
692
+ - `codexAppServerTurnKey`
693
+ - `codexAppServerAgentRunPatch`
694
+ - `codexAppServerRunIdentityForPatch`
695
+ - `codexAppServerRunPatchIsStaleAfterTerminalState`
696
+ - `codexAppServerSteerFailure`
697
+ - `codexAppServerMessageRequiresNewTurn`
698
+ - `codexAppServerInterruptFailure`
699
+ - `codexAppServerInterruptUnavailableResponse`
700
+ - `codexAppServerFrozenTurnInterruptResponse`
701
+ - `codexAppServerConversationTurnIsActive`
702
+ - `codexAppServerMessageText`
703
+ - `codexAppServerMessageDisplayText`
704
+ - `codexAppServerThreadStatus`
705
+ - `codexAppServerReadThreadStatus`
706
+ - `codexAppServerTurnStatusIsActive`
707
+ - `codexAppServerTurnStatusIsComplete`
708
+ - `codexAppServerTurnStatusIsSuccessfulComplete`
709
+ - `codexAppServerTurnStatusIsProviderFailure`
710
+ - `createCodexAppServerDetachedTurnWatcher`
711
+ - `waitForCodexAppServerTurn`
712
+ - `createCodexAppServerNotificationQueue`
713
+ - `sendPreparedCodexAppServerHelperTurn`
714
+ - `codexAppServerThreadIsMissing`
715
+
716
+ ### `src/server/conversation/codexTurnControl.js`
717
+ Exports
718
+ - `createCodexTurnControl({ journal, settlement, recovery, threadStatus, debugError, debugLog, errorPrefix, interruptFailedCode, turnOutcomes, turnState })`
719
+
720
+ ### `src/server/conversation/codexTurnRecovery.js`
721
+ Exports
722
+ - `createCodexTurnRecovery({ journal, output, settlement, promptDeliveries, namespace, createRuntime, createStore, acquireProvider, turnState, turnStateFromAgentRun, debugLog, debugError, captureContext, runInContext, activeReconcileMs, hasRuntime, recoverAdmission, turnOutcomes, outcomeNotice, resultDeliveryFailureMessage })`
723
+
724
+ ### `src/server/conversation/codexTurnState.js`
725
+ Exports
726
+ - `normalizeCodexAppServerRunState(state)`
727
+ - `codexAppServerRunStateIsActive(state)`
728
+ - `codexAppServerRunStateIsTerminal(state)`
729
+ - `codexAppServerAgentRun(session = {})`
730
+ - `codexAppServerPendingUserMessageClientIds(run = {})`
731
+ - `codexAppServerPendingUserMessageOwnership(run = {}, clientId = "")`
732
+ - `codexAppServerProcessedResultEvent(session = {}, threadId = "", turnId = "")`
733
+ - `codexAppServerTurnStateFromAgentRun(run = {}, normalizeRunState = normalizeCodexAppServerRunState)`
734
+ - `codexAppServerTurnState(session = {}, normalizeRunState = normalizeCodexAppServerRunState)`
735
+ - `codexAppServerTurnOwnsActiveGoal(turn = {}, threadId = "")`
736
+ - `codexAppServerTurnMatches(turn = {}, threadId = "", turnId = "")`
737
+ - `codexAppServerTurnCanReceiveProviderCompletion(turn = {}, threadId = "", turnId = "")`
738
+ - `codexAppServerTurnAwaitsProviderIdentity(turn = {}, threadId = "", turnId = "")`
739
+ - `codexAppServerTurnCanReceiveProviderActivity(turn = {}, threadId = "", turnId = "")`
740
+ - `codexAppServerTurnCanAdoptSuccessor(turn = {}, threadId = "", turnId = "")`
741
+ - `codexAppServerTurnKey(threadId = "", turnId = "")`
742
+ - `codexAppServerAgentRunPatch({ error = "", inputSource = "", outerTurnId = "", phase, runState = CODEX_APP_SERVER_RUN_STATE.COMPLETED, session = {}, status = "", threadId = "", turnId = "", updatedAt = "" } = {}, normalizeRunState = normalizeCodexAppServerRunState)`
743
+ - `codexAppServerRunIdentityForPatch(session = {}, { threadId = "", turnId = "" } = {}, normalizeRunState = normalizeCodexAppServerRunState)`
744
+ - `codexAppServerRunPatchIsStaleAfterTerminalState(currentTurn = {}, patch = {}, normalizeRunState = normalizeCodexAppServerRunState)`
745
+ - `codexAppServerSteerFailure(result = {}, steerFailedCode = "codex_turn_steer_failed")`
746
+ - `codexAppServerMessageRequiresNewTurn({ reason = "provider_idle", threadId = "", turnId = "" } = {})`
747
+ - `codexAppServerInterruptFailure(result = {}, interruptFailedCode = "codex_turn_interrupt_failed")`
748
+ - `codexAppServerInterruptUnavailableResponse({ active = false, threadId = "", turnId = "" } = {}, interruptFailedCode = "codex_turn_interrupt_failed")`
749
+ - `codexAppServerFrozenTurnInterruptResponse({ threadId = "", turnId = "" } = {})`
750
+ - `codexAppServerConversationTurnIsActive(status = "")`
751
+ - `codexAppServerMessageText(input = {})`
752
+ - `codexAppServerMessageDisplayText(input = {}, fallback = "")`
753
+ - `CODEX_APP_SERVER_RUN_STATE`
754
+ - `codexAppServerRunInputSource(run = {})`
755
+ - `codexAppServerThreadStatus(thread = {})`
756
+ - `codexAppServerReadThreadStatus(provider = null, threadId = "", { observeLatestTurn = false } = {})`
304
757
  - `codexAppServerTurnStatusIsActive(status = "")`
305
758
  - `codexAppServerTurnStatusIsComplete(status = "")`
306
759
  - `codexAppServerTurnStatusIsSuccessfulComplete(status = "")`
307
760
  - `codexAppServerTurnStatusIsProviderFailure(status = "")`
761
+ - `normalizeCodexRunText(value)`
762
+ - `codexAppServerErrorMessage(value, fallback = "Codex could not be prepared.")`
763
+ - `codexAppServerMessageDeferred({ threadId = "", turnId = "" } = {}, steerFailedCode = "codex_turn_steer_failed")`
764
+ - `codexPromptInputFromRequest(input = {})`
765
+ - `CODEX_APP_SERVER_AGENT_RUN_ID`
766
+ - `CODEX_APP_SERVER_RESULT_PROCESSED_EVENT`
767
+ - `CODEX_AGENT_PROVIDER`
768
+ - `CODEX_APP_SERVER_ACTIVE_RUN_STATES`
769
+
770
+ ### `src/server/conversation/commandHook.js`
771
+ Exports
772
+ - None
773
+
774
+ ### `src/server/conversation/commandWrapper.js`
775
+ Exports
776
+ - `validateCommandWrapper(wrapper)`
777
+ - `wrapNativeCommand(wrapper, command)`
778
+ - `nativeCommandHook(wrapper, input)`
779
+ - `codexCommandHookCommand(wrapper)`
308
780
  Local functions
309
- - `codexAppServerTurnTokenUsage(notification = {})`
781
+ - `shellQuote(value)`
782
+
783
+ ### `src/server/conversation/configuration.js`
784
+ Exports
785
+ - `normalizeConversationConfiguration(configuration, { engine, defaultIntegrationId } = {})`
786
+ - `validateConversationConfiguration(configuration, { engine, connections, apiClientFactory, connectionRequired = false, structuredOutput = false, maxOutputCharacters, efforts = ["none", "minimal", "low", "medium", "high", "xhigh", "max", "ultra"] } = {})`
787
+ - `validateConnectionModel(configuration, connection)`
788
+
789
+ ### `src/server/conversation/continuity.js`
790
+ Exports
791
+ - `conversationMessageIdentity(turnId, message)`
792
+ - `conversationMessageVersion(message, { includeData = false } = {})`
793
+ - `createConversationChangeover({ state, transcript, agent, identity, presentation = {}, log = () => {}, captureContext = false, applicationMessages = false })`
794
+ - `conversationHistoryVersions(history)`
795
+ - `conversationRequestText({ text, origin, data })`
796
+ - `conversationContinuity({ history, briefing = "", maximumCharacters = 128_000 })`
797
+ - `conversationNativeMessages(history)`
798
+ Local functions
799
+ - `writtenMessages(history, native = false)`
800
+
801
+ ### `src/server/conversation/fileStorage.js`
802
+ Exports
803
+ - `createFileConversationStorage({ directory } = {})`
804
+
805
+ ### `src/server/conversation/hookBridge.js`
806
+ Exports
807
+ - `createConversationHookBridge({ resolveConversation, readInstructions } = {})`
310
808
 
311
809
  ### `src/server/conversation/index.js`
312
810
  Exports
313
811
  - `createConversationTranscript`
812
+ - `conversationMessageIdentity`
813
+ - `conversationMessageVersion`
814
+ - `createConversationChangeover`
314
815
  - `createMemoryConversationStorage`
816
+ - `createConversationStorage`
817
+ - `createReentrantConversationStorage`
818
+ - `createConversationOperationLease`
819
+ - `beginConversationOperation`
820
+ - `finishConversationOperation`
821
+ - `conversationAgentRunRecord`
822
+ - `conversationAgentRunEvent`
823
+ - `createFileConversationStorage`
315
824
  - `createConversationStreams`
825
+ - `createConversationSystemPrompt`
826
+ - `createConversationRuntime`
827
+ - `normalizeConversationConfiguration`
828
+ - `upgradeConversationRuntimeState`
829
+ - `createConversationHookBridge`
830
+ - `nativeConversationStoragePolicy`
831
+ - `createConversationProcessIdentity`
832
+ - `validateConversationOutputSchema`
833
+
834
+ ### `src/server/conversation/localExecution.js`
835
+ Exports
836
+ - `createLocalConversationExecution()`
837
+ - `createConversationProcessIdentity({ runtimeTokenEnvironmentName = "JSKIT_EXECUTION_RUNTIME_TOKEN", commandHashEnvironmentName = "JSKIT_EXECUTION_COMMAND_HASH", label = "Native", unavailableCode = "native_process_identity_unavailable" } = {})`
316
838
 
317
839
  ### `src/server/conversation/memoryStorage.js`
318
840
  Exports
319
841
  - `createMemoryConversationStorage()`
320
842
 
843
+ ### `src/server/conversation/nativeHistoryExport.js`
844
+ Exports
845
+ - `canonicalNativeHistoryJson(value)`
846
+ - `createNativeHistoryExport(onRecord, { signal, maxBytes = 2 * 1024 ** 3 } = {})`
847
+ - `retireNativeConversation({ binding, inspect, remove, beforeDelete, readConversation, exportConversation })`
848
+
849
+ ### `src/server/conversation/nativeStorage.js`
850
+ Exports
851
+ - `nativeConversationStoragePolicy(engineId)`
852
+
321
853
  ### `src/server/conversation/normalize.js`
322
854
  Exports
323
855
  - `normalizeText(value)`
@@ -325,6 +857,7 @@ Exports
325
857
 
326
858
  ### `src/server/conversation/openCodeClient.js`
327
859
  Exports
860
+ - `retireOpenCodeConversationHistory(storageClient, controlClient, binding, options = {})`
328
861
  - `openCodeAssistantMessageText(message = {})`
329
862
  - `OPENCODE_RESPONSE_LIMIT_BYTES`
330
863
  - `createOpenCodeServerClient({ allowAttachmentDirectories = false, baseUrl = "", directory = "", fetchImpl = globalThis.fetch, password = "", username = "opencode" } = {})`
@@ -346,17 +879,367 @@ Local functions
346
879
  - `stablePromptBody(input = {})`
347
880
  - `eventSessionId(value = null)`
348
881
  - `decodeOpenCodeEventData(value = "")`
882
+ - `inspectOpenCodeConversationFamily(storageClient, controlClient, binding, { signal } = {})`
883
+ - `exportOpenCodeNativeHistory(storageClient, controlClient, id, onRecord, { signal: inputSignal } = {})`
884
+
885
+ ### `src/server/conversation/openCodePlugin.js`
886
+ Exports
887
+ - `conversationInstructions({ client, registryPath = process.env.JSKIT_OPENCODE_ENV_REGISTRY, resolveHostInstructions } = {})`
888
+
889
+ ### `src/server/conversation/openCodeProcess.js`
890
+ Exports
891
+ - `openCodeProcessEnvironment(baseEnv = {}, { cacheRoot = "", dbPath = "", inlineConfig = "", outputTokenMax = 0, password = "" } = {})`
892
+ - `openCodeConversationAgent({ nativeTools = false, tools = false } = {})`
893
+ - `openCodeConversationAgents({ sessionEnvironmentRegistry = "" } = {})`
894
+ - `createOpenCodeConversationServer({ command = "opencode", execution = createLocalConversationExecution(), env = process.env, workdir, stateDirectory, databasePath, sessionEnvironmentRegistry, connection, maxOutputTokens, onStarted, onFailure, executionLimits, signal } = {})`
895
+ - `createOpenCodeServerProcess({ command = "opencode", execution = createLocalConversationExecution(), env = process.env, workdir, privateRoot, directory = "", connections = [], port = 0, fetchImpl = globalThis.fetch, allowAttachmentDirectories = false, expectedVersion = OPENCODE_EXPECTED_VERSION, readinessTimeoutMs = OPENCODE_READY_TIMEOUT_MS, onStarted, onFailure, executionLimits, signal } = {})`
896
+ - `readOpenCodeZenModelIds({ fetchImpl = globalThis.fetch, timeoutMs = OPENCODE_ZEN_CATALOG_TIMEOUT_MS } = {})`
897
+ - `readOpenCodeCatalog({ createServerProcess, privateRoot = "", workdir = "" } = {})`
898
+ - `verifyOpenCodeApiKey({ apiKey = "", agentId = openCodeConversationAgent(), prepareCommand, modelId = "", modelProviderId = "", privateRoot = "", workdir = "" } = {})`
899
+ - `OPENCODE_EXPECTED_VERSION`
900
+ - `OPENCODE_HOST`
901
+ - `OPENCODE_READY_TIMEOUT_MS`
902
+ - `OPENCODE_STOP_TIMEOUT_MS`
903
+ - `openCodeApplicationToolSchemas`
904
+ - `createOpenCodeSharedRuntime`
905
+ - `openCodeServerForDirectory`
906
+ - `readOpenCodeEnvironments`
907
+ - `openCodeEnvironmentForDirectory`
908
+ - `openCodeEnvironmentForSession`
909
+ - `assertOpenCodeModelProvider`
910
+ - `limitOpenCodeModelOutput`
911
+ - `ensureOpenCodeSession`
912
+ - `openCodeModel`
913
+ - `sameOpenCodeSelection`
914
+ - `createOpenCodeConversationPlugin`
915
+ Local functions
916
+ - `text(value = "")`
917
+ - `availableLoopbackPort()`
918
+ - `waitForOpenCodeReady({ client, expectedVersion = OPENCODE_EXPECTED_VERSION, processHandle, timeoutMs = OPENCODE_READY_TIMEOUT_MS, signal } = {})`
919
+ - `openCodeZenCatalogError(cause = null)`
920
+
921
+ ### `src/server/conversation/openCodeRuntime.js`
922
+ Exports
923
+ - `assertOpenCodeModelProvider(selected, input = {})`
924
+ - `limitOpenCodeModelOutput(input = {}, output = {})`
925
+ - `readOpenCodeEnvironments(registryPath = "")`
926
+ - `openCodeEnvironmentForDirectory(environments, cwd = "")`
927
+ - `openCodeEnvironmentForSession(environments, sessionId = "", client = null)`
928
+ - `openCodeServerForDirectory(server = {}, workdir = "")`
929
+ - `openCodeModel(selection = {}, executionProfile = null)`
930
+ - `sameOpenCodeSelection(left = {}, right = {})`
931
+ - `ensureOpenCodeSession(target, { selection, model, workdir = target.workdir, identity = {}, signal, invalidIdentity = () => new Error("OpenCode did not return a native conversation ID.") })`
932
+ - `createOpenCodeSharedRuntime({ onStop = () => {}, scope } = {})`
933
+ Local functions
934
+ - `text(value)`
935
+ - `openCodeTurnSnapshot(turn = null, threadId = "")`
936
+ - `openCodeCredentialFailure(value = "")`
937
+ - `openCodeProviderApiFailure(error = {})`
938
+ - `pathContains(root = "", candidate = "")`
939
+
940
+ ### `src/server/conversation/openCodeTools.js`
941
+ Exports
942
+ - `createOpenCodeToolBridge({ execute, maxArgumentBytes, schemas })`
943
+
944
+ ### `src/server/conversation/openCodeTurn.js`
945
+ Exports
946
+ - `openCodeDetachedPrompt(input = {})`
947
+ - `openCodeStructuredOutput(value = "")`
948
+ - `observeOpenCodeEvents(client, conversationId, { abortController, signal = abortController.signal, ...options } = {})`
949
+ - `openCodeMessageError(message = {})`
950
+ - `inspectOpenCodeMessageAdmission(client, conversationId, inputMessageId, { signal = AbortSignal.timeout(OPENCODE_INTERRUPT_TIMEOUT_MS) } = {})`
951
+ - `steerOpenCodeTurn(client, conversationId, turn, input, { signal } = {})`
952
+ - `dispatchOpenCodeTurn(client, conversationId, turn, input, options = {})`
953
+ - `openCodeMessageRows(value = null)`
954
+ - `openCodePersistentConversationMessages(rows, conversationMessageId)`
955
+ - `projectOpenCodeConversationMessages(messages, expectedId, { maximumOutput, outputSchema, previous, onMessage })`
956
+ - `openCodeRowsForInput(value = null, inputMessageId = "")`
957
+ - `openCodeLastAssistantResult(value = null, { readError = openCodeMessageError } = {})`
958
+ - `waitForOpenCodeMessages(client, conversationId = "", inputMessageId = "", { onMessages = null, readFailure = () => null, readError = openCodeMessageError, signal } = {})`
959
+ - `waitForOpenCodeFinalResponse(client, conversationId, turn, { agent, model, recoveryMessageId, beforeRecovery = null, ...options } = {})`
960
+ - `observeOpenCodeTurnCompletion(runtime, target, conversationId, turn, { events, signal, timeoutMs, finalResponse, projectResult = value => value, afterClose, ...waitOptions } = {})`
961
+ - `runOpenCodeConversationTurn(client, conversationId, input = {}, { expectedThreadId = "", forbiddenThreadId = "", requireFreshHistory = false, completeResult, close } = {})`
962
+ - `OPENCODE_INTERRUPT_TIMEOUT_MS`
963
+ Local functions
964
+ - `text(value)`
965
+ - `record(value = null)`
966
+ - `openCodeEventSummary(event = {})`
967
+ - `consumeOpenCodeEvents(client, conversationId, { eventStartedAt = null, onEvent = null, onError = null, onReady = null, readError = openCodeMessageError, signal } = {})`
968
+ - `openCodeMessageResultForInput(value = null, inputMessageId = "", { readError = openCodeMessageError } = {})`
969
+ - `latestOpenCodeMessageResult(value, readError)`
970
+
971
+ ### `src/server/conversation/provider.js`
972
+ Exports
973
+ - `createConversationProviderFactory({ connections, apiClientFactory, fetch, limits, actions, toolCatalog } = {})`
974
+
975
+ ### `src/server/conversation/providers/api.js`
976
+ Exports
977
+ - `createApiConversationDriver({ connections, apiClientFactory, fetch, limits = {} })`
978
+ Local functions
979
+ - `toolResultContent(result)`
980
+
981
+ ### `src/server/conversation/providers/claude.js`
982
+ Exports
983
+ - `createClaudeConversationAdapter({ getProcess, isActive, startProcess, stopProcess } = {})`
984
+
985
+ ### `src/server/conversation/providers/claudeDriver.js`
986
+ Exports
987
+ - `createClaudeConversationDriver({ connections, host = {}, limits = {} } = {})`
988
+ Local functions
989
+ - `hash(value)`
990
+ - `nativeInput(input)`
991
+ - `claudeGoalValue(goal, conversationId)`
992
+
993
+ ### `src/server/conversation/providers/codex.js`
994
+ Exports
995
+ - `createCodexConversationAdapter(host)`
996
+
997
+ ### `src/server/conversation/providers/codexDriver.js`
998
+ Exports
999
+ - `createCodexConversationDriver({ connections, host = {}, limits = {} } = {})`
1000
+ Local functions
1001
+ - `hash(value)`
1002
+ - `goalValue(goal)`
1003
+ - `nativeInput(input)`
1004
+
1005
+ ### `src/server/conversation/providers/opencode.js`
1006
+ Exports
1007
+ - `createOpenCodeConversationAdapter({ resolveInstructions } = {})`
1008
+
1009
+ ### `src/server/conversation/providers/opencodeDriver.js`
1010
+ Exports
1011
+ - `createOpenCodeConversationDriver({ connections, host = {}, limits = {} } = {})`
1012
+ Local functions
1013
+ - `hash(value)`
1014
+ - `nativeMessageId(id)`
1015
+
1016
+ ### `src/server/conversation/providers/scoped.js`
1017
+ Exports
1018
+ - `runScopedConversationTurn({ operations, scope = {}, input = {}, context: options = {}, executionProfile: profileSnapshot } = {})`
1019
+ - `readPersistentConversation(options)`
1020
+ - `startPersistentConversationTurn(options)`
1021
+ - `inspectPersistentConversationAdmission(options)`
1022
+ - `preparePersistentConversationChangeover(options)`
1023
+ - `inspectPersistentConversationDelivery(options)`
1024
+ - `stopPersistentConversation({ sessionId, record, context, operations, records, projection })`
1025
+ - `deletePersistentConversation({ sessionId, record, context, operations, records, projection })`
1026
+ Local functions
1027
+ - `requireSuccess(result)`
1028
+ - `qualifyTranscript(turns, record, response, receipts)`
1029
+ - `publishTranscript({ sessionId, store, receipts, publish }, context, record, turns, response = {})`
1030
+ - `streamMessage({ sessionId, store, projection, publish }, context, record, event)`
1031
+
1032
+ ### `src/server/conversation/runtime.js`
1033
+ Exports
1034
+ - `createConversationRuntime({ engine: defaultEngine = "api", defaultIntegrationId, storage, authorize, connections, apiClientFactory, apiHistory, actions, toolPolicy, toolCatalog, attachments, fetch, host: defaultHost, limits = {} } = {})`
1035
+ Local functions
1036
+ - `failure(message, code, statusCode = 409)`
1037
+ - `submittedMessage(turn)`
1038
+ - `retainedSegments(state)`
1039
+ - `nativeIdentity(segment)`
1040
+ - `pendingSuccessor(state)`
1041
+ - `sameRequest(left, right)`
1042
+
1043
+ ### `src/server/conversation/runtimeStateUpgrade.js`
1044
+ Exports
1045
+ - `hasUnfinishedConversationRewind(runtime)`
1046
+ - `upgradeConversationRuntimeState({ metadata, conversationLog })`
1047
+ Local functions
1048
+ - `object(value)`
1049
+ - `invalid(message)`
1050
+ - `validateSegment(segment)`
1051
+ - `nativeIdentity(segment)`
1052
+ - `inspectRequest(request, segment, version, warnings)`
1053
+
1054
+ ### `src/server/conversation/storage.js`
1055
+ Exports
1056
+ - `createConversationOperationLease()`
1057
+ - `beginConversationOperation(lease)`
1058
+ - `finishConversationOperation(lease, participant)`
1059
+ - `createReentrantConversationStorage(storage)`
1060
+ - `createConversationStorage({ readRecord, writeRecord, deleteRecord })`
1061
+ Local functions
1062
+ - `conversationMessageStorageKey({ role, at, messageId } = {})`
349
1063
 
350
1064
  ### `src/server/conversation/streams.js`
351
1065
  Exports
352
1066
  - `createConversationStreams({ clock = () => new Date() } = {})`
353
1067
 
1068
+ ### `src/server/conversation/structuredOutput.js`
1069
+ Exports
1070
+ - `validateConversationOutputSchema(outputSchema, { maxOutputCharacters, createError = (message, details) => Object.assign(new TypeError(message), { details }) } = {})`
1071
+ - `conversationOutputSchema(schema)`
1072
+ - `parseConversationOutput(text, schema)`
1073
+ Local functions
1074
+ - `isPlainRecord(value)`
1075
+
1076
+ ### `src/server/conversation/systemPrompt.js`
1077
+ Exports
1078
+ - `createConversationSystemPrompt()`
1079
+
1080
+ ### `src/server/conversation/tools.js`
1081
+ Exports
1082
+ - `createConversationTools({ catalog, context, signal: turnSignal, previousCalls = [], authorize, save, emit, maximumCalls = 32, discoveryOnly = false, transient = false, propagateErrors = false })`
1083
+
354
1084
  ### `src/server/conversation/transcript.js`
355
1085
  Exports
356
- - `createConversationTranscript({ storage, clock = () => new Date() } = {})`
1086
+ - `createConversationTranscript({ storage, clock = () => new Date(), applicationTurns = false } = {})`
357
1087
  Local functions
358
1088
  - `hasMessages(turn)`
359
1089
 
1090
+ ### `src/server/hosts/claudeHistory.js`
1091
+ Exports
1092
+ - `listClaudeConversationStorage`
1093
+ - `readClaudeHistory`
1094
+ - `retireClaudeConversationHistory`
1095
+
1096
+ ### `src/server/hosts/claudeProcess.js`
1097
+ Exports
1098
+ - `bindClaudeConversationAccount`
1099
+ - `claudeCodeArguments`
1100
+ - `claudeCatalogueModels`
1101
+ - `claudeFlagSettings`
1102
+ - `claudeModelConfiguration`
1103
+ - `createClaudeAccountQueries`
1104
+ - `createClaudeCodeProcess`
1105
+ - `readClaudeCodeAuthStatus`
1106
+ - `verifyClaudeProviderKey`
1107
+
1108
+ ### `src/server/hosts/claudeTurn.js`
1109
+ Exports
1110
+ - `createClaudeConversationOwner`
1111
+ - `claudeNativeMessageId`
1112
+
1113
+ ### `src/server/hosts/codexConfiguration.js`
1114
+ Exports
1115
+ - `codexAppServerThreadSettings`
1116
+ - `codexAppServerReadOnlyThreadSettings`
1117
+ - `codexAppServerTurnSettings`
1118
+ - `codexInteractiveArguments`
1119
+ - `normalizeCodexThreadId`
1120
+ - `codexAppServerProjectHookTrustConfig`
1121
+ - `codexAuthOutputRequiresReconnect`
1122
+ - `codexProviderConfiguration`
1123
+ - `codexProviderFileConfiguration`
1124
+ - `verifyCodexProviderKey`
1125
+ - `codexProviderModelCatalog`
1126
+ - `codexCatalogRows`
1127
+ - `codexCatalogReasoningEfforts`
1128
+ - `codexCatalogModels`
1129
+ - `codexConfiguredModelCatalog`
1130
+ - `createCodexAccountReader`
1131
+ - `createCodexAppServerIsolation`
1132
+ - `readCodexToolFreeConfiguration`
1133
+
1134
+ ### `src/server/hosts/codexEvents.js`
1135
+ Exports
1136
+ - `codexContextUsageFromNotification`
1137
+ - `codexAppServerContextRefreshReason`
1138
+ - `codexAppServerNotificationEvent`
1139
+ - `codexAppServerNotificationItemId`
1140
+ - `codexAppServerNotificationTurnId`
1141
+ - `codexAppServerProviderThreadAssistantSegments`
1142
+ - `codexAppServerProviderThreadTurns`
1143
+ - `codexAppServerProviderTurnForOperation`
1144
+ - `codexAppServerProviderTurnId`
1145
+ - `codexAppServerThreadError`
1146
+ - `codexAppServerThreadTurnId`
1147
+
1148
+ ### `src/server/hosts/codexProcess.js`
1149
+ Exports
1150
+ - `CODEX_APP_SERVER_METADATA_SCHEMA_VERSION`
1151
+ - `CODEX_APP_SERVER_RUNTIME_DIR_NAME`
1152
+ - `CODEX_APP_SERVER_TRANSPORT`
1153
+ - `codexAppServerExecutionMode`
1154
+ - `codexAppServerHelperHomeDir`
1155
+ - `codexAppServerHelperWorkspaceDir`
1156
+ - `codexAppServerIsHelper`
1157
+ - `createCodexAppServerRuntime`
1158
+ - `normalizeCodexAppServerTerminalEnv`
1159
+ - `runCodexAppServerProcess`
1160
+
1161
+ ### `src/server/hosts/codexProvider.js`
1162
+ Exports
1163
+ - `CODEX_APP_SERVER_INVALID_REQUEST_CODE`
1164
+ - `CodexAppServerAgentProvider`
1165
+ - `assertCodexAuthPreflightReady`
1166
+ - `codexAppServerEndpointForTarget`
1167
+ - `codexAppServerRequestIsInvalid`
1168
+ - `codexAppServerRuntimeStopWasVerified`
1169
+ - `codexCliResumeCommand`
1170
+ - `codexRenewalThreadError`
1171
+ - `codexTextInput`
1172
+ - `codexTurnInput`
1173
+ - `createCodexAppServerProviderOwner`
1174
+ - `defineCodexRenewalThreadIds`
1175
+ - `deleteCodexAppServerHelperThread`
1176
+ - `deleteCodexAppServerThread`
1177
+ - `ensureCodexAppServerThread`
1178
+ - `inspectCodexAppServerMessageAdmission`
1179
+ - `retireCodexConversationHistory`
1180
+ - `resumeExactCodexAppServerThread`
1181
+ - `sendCodexAppServerPrompt`
1182
+ - `shellQuote`
1183
+ - `startFreshCodexAppServerThread`
1184
+
1185
+ ### `src/server/hosts/codexTurn.js`
1186
+ Exports
1187
+ - `codexAppServerAgentRun`
1188
+ - `codexAppServerConversationTurnIsActive`
1189
+ - `codexAppServerFrozenTurnInterruptResponse`
1190
+ - `codexAppServerInterruptUnavailableResponse`
1191
+ - `codexAppServerMessageDisplayText`
1192
+ - `codexAppServerMessageText`
1193
+ - `codexAppServerThreadStatus`
1194
+ - `codexAppServerTurnState`
1195
+ - `codexAppServerTurnStateFromAgentRun`
1196
+ - `createCodexAppServerNotificationQueue`
1197
+ - `createCodexAppServerRunOwner`
1198
+ - `sendPreparedCodexAppServerHelperTurn`
1199
+ - `CODEX_HELPER_THREAD_LEDGER_SCHEMA_VERSION`
1200
+ - `CODEX_HELPER_THREAD_LIFECYCLES`
1201
+ - `createCodexHelperThreadLedgerOwner`
1202
+
1203
+ ### `src/server/hosts/nativeHistory.js`
1204
+ Exports
1205
+ - `retireNativeConversation`
1206
+
1207
+ ### `src/server/hosts/openCodeClient.js`
1208
+ Exports
1209
+ - `retireOpenCodeConversationHistory`
1210
+
1211
+ ### `src/server/hosts/openCodeProcess.js`
1212
+ Exports
1213
+ - `OPENCODE_EXPECTED_VERSION`
1214
+ - `OPENCODE_HOST`
1215
+ - `OPENCODE_READY_TIMEOUT_MS`
1216
+ - `assertOpenCodeModelProvider`
1217
+ - `createOpenCodeConversationPlugin`
1218
+ - `createOpenCodeServerProcess`
1219
+ - `createOpenCodeSharedRuntime`
1220
+ - `ensureOpenCodeSession`
1221
+ - `limitOpenCodeModelOutput`
1222
+ - `openCodeApplicationToolSchemas`
1223
+ - `openCodeConversationAgents`
1224
+ - `openCodeEnvironmentForDirectory`
1225
+ - `openCodeEnvironmentForSession`
1226
+ - `openCodeModel`
1227
+ - `openCodeProcessEnvironment`
1228
+ - `openCodeServerForDirectory`
1229
+ - `readOpenCodeEnvironments`
1230
+ - `readOpenCodeCatalog`
1231
+ - `readOpenCodeZenModelIds`
1232
+ - `verifyOpenCodeApiKey`
1233
+ - `sameOpenCodeSelection`
1234
+
1235
+ ### `src/server/hosts/openCodeTurn.js`
1236
+ Exports
1237
+ - `openCodeDetachedPrompt`
1238
+ - `openCodeMessageError`
1239
+ - `openCodeRowsForInput`
1240
+ - `openCodeStructuredOutput`
1241
+ - `runOpenCodeConversationTurn`
1242
+
360
1243
  ### `src/server/index.js`
361
1244
  Exports
362
1245
  - `createAiClient`
@@ -373,6 +1256,10 @@ Exports
373
1256
  - `writeNdjson`
374
1257
  - `resolveWorkspaceSlug`
375
1258
  - `createServiceToolCatalog`
1259
+ - `consumeCompletionStream`
1260
+ - `sanitizeAssistantMessageText`
1261
+ - `runAssistantToolLoop`
1262
+ - `runBoundedAssistantToolLoop`
376
1263
 
377
1264
  ### `src/server/lib/aiClient.js`
378
1265
  Exports
@@ -382,10 +1269,32 @@ Exports
382
1269
 
383
1270
  ### `src/server/lib/aiConnectionClient.js`
384
1271
  Exports
385
- - `createAiConnectionClient(connection, { fetch, timeoutMs = 120_000, maxOutputTokens } = {})`
1272
+ - `createAiConnectionClient(connection, { fetch, timeoutMs = 120_000, maxOutputTokens, effort } = {})`
386
1273
  Local functions
387
1274
  - `sdkMessages(messages)`
388
1275
 
1276
+ ### `src/server/lib/assistantCompletion.js`
1277
+ Exports
1278
+ - `consumeCompletionStream(stream, onText = () => {}, { signal, limits, preserveWhitespace = false, requireCallIds = false, callIdPrefix = "" } = {})`
1279
+ - `sanitizeAssistantMessageText(value, { preserveWhitespace = false } = {})`
1280
+ Local functions
1281
+ - `extractTextDelta(deltaContent)`
1282
+ - `parseDsmlToolCallsFromText(value = "")`
1283
+
1284
+ ### `src/server/lib/assistantToolLoop.js`
1285
+ Exports
1286
+ - `runAssistantToolLoop({ messages, input, toolSet, toToolSchema, complete, executeToolCalls, finish, preserveWhitespace = false })`
1287
+ - `runBoundedAssistantToolLoop({ prompt, signal, policy, complete, outputSchema, limitError, invalidResponseError = new Error("The assistant returned an invalid response."), failureError = new Error("The assistant could not complete this request."), toolCatalog, toolContext })`
1288
+ Local functions
1289
+ - `requiresCurrentTime(value = "")`
1290
+ - `resolvePreflightTools(toolDescriptors = [], input = "")`
1291
+ - `buildRecoveryPrompt({ reason = "", toolFailures = [], toolSuccesses = [] } = {})`
1292
+ - `buildRecoveryFallbackAnswer({ reason = "", toolFailures = [], toolSuccesses = [] } = {})`
1293
+ - `toSafeToolResultText(value)`
1294
+ - `buildToolOutcomeFallbackAnswer({ toolFailures = [], toolSuccesses = [] } = {})`
1295
+ - `buildAssistantToolCallMessage(toolCalls = [])`
1296
+ - `boundedResponseSchema(outputSchema, descriptors)`
1297
+
389
1298
  ### `src/server/lib/ndjson.js`
390
1299
  Exports
391
1300
  - `NDJSON_CONTENT_TYPE`
@@ -444,7 +1353,8 @@ Exports
444
1353
 
445
1354
  ### `src/server/lib/serviceToolCatalog.js`
446
1355
  Exports
447
- - `createServiceToolCatalog(actions, { barredActionIds = [], skipActionPrefixes = [], maxDirectTools: rawMaxDirectTools = DEFAULT_MAX_DIRECT_TOOLS, discoveryPageSize: rawDiscoveryPageSize = DEFAULT_DISCOVERY_PAGE_SIZE, maxToolArgumentBytes: rawMaxToolArgumentBytes = DEFAULT_MAX_TOOL_ARGUMENT_BYTES, maxToolResultBytes: rawMaxToolResultBytes = DEFAULT_MAX_TOOL_RESULT_BYTES } = {})`
1356
+ - `createServiceToolCatalog(actions, { isActionAvailable, barredActionIds = [], skipActionPrefixes = [], maxDirectTools: rawMaxDirectTools = DEFAULT_MAX_DIRECT_TOOLS, discoveryPageSize: rawDiscoveryPageSize = DEFAULT_DISCOVERY_PAGE_SIZE, maxToolArgumentBytes: rawMaxToolArgumentBytes = DEFAULT_MAX_TOOL_ARGUMENT_BYTES, maxToolResultBytes: rawMaxToolResultBytes = DEFAULT_MAX_TOOL_RESULT_BYTES } = {})`
1357
+ - `DISCOVERY_TOOL_DESCRIPTORS`
448
1358
  Local functions
449
1359
  - `normalizePreflightIntents(value)`
450
1360
  - `normalizeAssistantExtension(value)`
@@ -499,6 +1409,10 @@ Exports
499
1409
  - `assistantResource`
500
1410
  - `assistantConversationOutputValidator`
501
1411
 
1412
+ ### `src/shared/assistantResponseText.js`
1413
+ Exports
1414
+ - `isAssistantProgressOnlyText(value)`
1415
+
502
1416
  ### `src/shared/assistantSettingsResource.js`
503
1417
  Exports
504
1418
  - `MAX_SYSTEM_PROMPT_CHARS`
@@ -525,6 +1439,8 @@ Local functions
525
1439
  ### `src/shared/conversation/attachments.js`
526
1440
  Exports
527
1441
  - `attachmentSizeLabel(size)`
1442
+ - `conversationAttachmentManifest(attachments = [])`
1443
+ - `prepareConversationAttachmentMessage(input, attachments, displayAttachments)`
528
1444
 
529
1445
  ### `src/shared/conversation/index.js`
530
1446
  Exports
@@ -570,6 +1486,32 @@ Local functions
570
1486
  - `parseLineNumberedQuestionPrompt(value = "")`
571
1487
  - `parseInlineNumberedQuestionPrompt(value = "")`
572
1488
 
1489
+ ### `src/shared/conversation/pagination.js`
1490
+ Exports
1491
+ - `CONVERSATION_LOG_PAGE_LIMIT`
1492
+ - `normalizeConversationLogPagination(pagination = {})`
1493
+ - `normalizeConversationLogPage(payload = {})`
1494
+ - `mergeConversationLogPages(pages = [])`
1495
+ - `conversationLogReadQuery({ beforeTurnId = "", limit = CONVERSATION_LOG_PAGE_LIMIT } = {})`
1496
+ Local functions
1497
+ - `isRecord(value)`
1498
+
1499
+ ### `src/shared/conversation/patches.js`
1500
+ Exports
1501
+ - `normalizeConversationMessage(message = {}, { normalizeAttachments = value => Array.isArray(value) ? value : [] } = {})`
1502
+ - `normalizeConversationTurn(turn = {}, index = 0, options = {})`
1503
+ - `applyConversationLogPatch(payload = {}, patch = null, options = {})`
1504
+ Local functions
1505
+ - `isRecord(value)`
1506
+ - `chronologicalConversationActivity(messages = [])`
1507
+
1508
+ ### `src/shared/conversation/questions.js`
1509
+ Exports
1510
+ - `latestAssistantMessageAwaitingUserReply(conversationLog = {})`
1511
+ Local functions
1512
+ - `messageText(value = "")`
1513
+ - `conversationTurns(conversationLog = {})`
1514
+
573
1515
  ### `src/shared/conversation/scrollFollowState.js`
574
1516
  Exports
575
1517
  - `DEFAULT_SCROLL_FOLLOW_THRESHOLD_PX`
@@ -628,6 +1570,7 @@ Exports
628
1570
  - `normalizeConversationStatus`
629
1571
  - `parseJsonObject`
630
1572
  - `toPositiveInteger`
1573
+ - `isAssistantProgressOnlyText`
631
1574
 
632
1575
  ### `src/shared/jsonApiTransports.js`
633
1576
  Exports
@@ -636,6 +1579,14 @@ Exports
636
1579
  - `ASSISTANT_CONVERSATIONS_TRANSPORT`
637
1580
  - `ASSISTANT_CONVERSATION_MESSAGES_TRANSPORT`
638
1581
 
1582
+ ### `src/shared/nativeProviders.js`
1583
+ Exports
1584
+ - `NATIVE_AI_PROVIDERS`
1585
+ - `nativeAiProvider(id)`
1586
+ - `nativeAiModel(id, providerId = "")`
1587
+ Local functions
1588
+ - `model(id, contextWindow, variants, options = {})`
1589
+
639
1590
  ### `src/shared/queryKeys.js`
640
1591
  Exports
641
1592
  - `ASSISTANT_QUERY_KEY_PREFIX`
@@ -676,7 +1627,21 @@ Exports
676
1627
 
677
1628
  ### `src/testing/conversationStorageContract.js`
678
1629
  Exports
679
- - `verifyConversationStorageContract(storage)`
1630
+ - `verifyConversationStorageContract(storage, { runtime = false } = {})`
1631
+
1632
+ ### `src/testing/nativeCodex.js`
1633
+ Exports
1634
+ - `CodexAppServerJsonRpcClient`
1635
+ - `startCodexHistoryAdapter`
1636
+ - `classifyCodexAppServerEvent`
1637
+ - `codexAppServerErrorText`
1638
+ - `codexAppServerNotificationUsageLimitExceeded`
1639
+ - `codexAppServerOutputOwnerTurnId`
1640
+ - `prepareCodexModelCatalog`
1641
+
1642
+ ### `src/testing/nativeOpenCode.js`
1643
+ Exports
1644
+ - `createOpenCodeServerClient`
680
1645
 
681
1646
  ### examples
682
1647