@standardagents/builder 0.25.6 → 0.26.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (52) hide show
  1. package/dist/built-in-routes.js +269 -17
  2. package/dist/built-in-routes.js.map +1 -1
  3. package/dist/client/{ApiKeysView-B9XLopSb.js → ApiKeysView-jhfg43UH.js} +1 -1
  4. package/dist/client/CenteredContentView-CS0mV2EJ.js +1 -0
  5. package/dist/client/{CompositionView-DJOtNN7f.js → CompositionView-DhkLWmtE.js} +1 -1
  6. package/dist/client/{ConfirmDialog.vue_vue_type_script_setup_true_lang-55dXt19T.js → ConfirmDialog.vue_vue_type_script_setup_true_lang-D-WToRMy.js} +1 -1
  7. package/dist/client/{CopyButton.vue_vue_type_script_setup_true_lang-B6NqQmW9.js → CopyButton.vue_vue_type_script_setup_true_lang-Dhq0t0dd.js} +1 -1
  8. package/dist/client/{DataTable.vue_vue_type_script_setup_true_lang-0cbPVIIz.js → DataTable.vue_vue_type_script_setup_true_lang-D1MDCns-.js} +1 -1
  9. package/dist/client/{JsonViewer-B7yHhxqP.js → JsonViewer-BoHrE76S.js} +1 -1
  10. package/dist/client/{LoginView-mY9OytK6.js → LoginView-BpR2nMNf.js} +1 -1
  11. package/dist/client/{MarketplaceView-B9Z9YMuB.js → MarketplaceView-uUf1JYla.js} +1 -1
  12. package/dist/client/{Modal.vue_vue_type_script_setup_true_lang-DEVCRbXl.js → Modal.vue_vue_type_script_setup_true_lang-D-SDVFQI.js} +1 -1
  13. package/dist/client/{ModelModal.vue_vue_type_script_setup_true_lang-FxEBZ3A8.js → ModelModal.vue_vue_type_script_setup_true_lang-DE57Zr0r.js} +1 -1
  14. package/dist/client/{ModelsView-DTU8pk-T.js → ModelsView-CuM_OieH.js} +1 -1
  15. package/dist/client/{PromptEditView-BAKoULxX.js → PromptEditView-BWjrA2zr.js} +1 -1
  16. package/dist/client/{PromptModal-CoinSKIM.js → PromptModal-BFxhuG0Z.js} +1 -1
  17. package/dist/client/{PromptsView-DIkj3q-o.js → PromptsView-AlGsRB6k.js} +1 -1
  18. package/dist/client/{ProvidersView-B8A6ezDR.js → ProvidersView-CbXBs3SH.js} +1 -1
  19. package/dist/client/ThreadInspectorPane.vue_vue_type_script_setup_true_lang-Dm3d37hz.js +22 -0
  20. package/dist/client/{ThreadsView-DGCVdDej.js → ThreadsView-rN9rzJi1.js} +1 -1
  21. package/dist/client/{ToolsView-CC-WsZet.js → ToolsView-0Gpo_RFg.js} +1 -1
  22. package/dist/client/{UiCodeBlock.vue_vue_type_script_setup_true_lang-BH3WC9G_.js → UiCodeBlock.vue_vue_type_script_setup_true_lang-CNncALQo.js} +1 -1
  23. package/dist/client/{UsersView-U3Stwxui.js → UsersView-iXPbcguY.js} +1 -1
  24. package/dist/client/{VariablesView-0-a1F4cn.js → VariablesView-C9BB9h34.js} +1 -1
  25. package/dist/client/assets/{ThreadInspectorPane-ouC_RyKA.css → ThreadInspectorPane-CfpdDnUQ.css} +1 -1
  26. package/dist/client/assets/index-BTPsPULO.css +1 -0
  27. package/dist/client/{check-Dkzs1C3V.js → check-BdJVlUmI.js} +1 -1
  28. package/dist/client/{chevron-right-BGirddPg.js → chevron-right-D49O3XLU.js} +1 -1
  29. package/dist/client/{copy-C08OR8rY.js → copy-40uDyTgY.js} +1 -1
  30. package/dist/client/{formkit-YJ1Z7D5r.js → formkit-Bl-sERnF.js} +1 -1
  31. package/dist/client/index-BCoE48be.js +6 -0
  32. package/dist/client/index.html +4 -4
  33. package/dist/client/{package-guyzMTDG.js → package-1UgoERpx.js} +1 -1
  34. package/dist/client/{plus-DG3ZN5wg.js → plus-BzCjfYs0.js} +1 -1
  35. package/dist/client/{timeAgo-D7V247YG.js → timeAgo-cFwldMu-.js} +1 -1
  36. package/dist/client/{useActionFeedback-byARNQjQ.js → useActionFeedback-BVifffYQ.js} +1 -1
  37. package/dist/client/{vue-BqC6IZDY.js → vue-CmmJuziT.js} +1 -1
  38. package/dist/{index-CX9Ti98s.d.ts → index-DJ7B8CTp.d.ts} +63 -0
  39. package/dist/index.d.ts +2 -2
  40. package/dist/index.js +555 -84
  41. package/dist/index.js.map +1 -1
  42. package/dist/plugin.js +27 -3
  43. package/dist/plugin.js.map +1 -1
  44. package/dist/runtime.d.ts +184 -6
  45. package/dist/runtime.js +528 -81
  46. package/dist/runtime.js.map +1 -1
  47. package/dist/test.d.ts +1 -1
  48. package/package.json +5 -5
  49. package/dist/client/CenteredContentView-Bwv4MVSC.js +0 -1
  50. package/dist/client/ThreadInspectorPane.vue_vue_type_script_setup_true_lang-CvssvzLz.js +0 -22
  51. package/dist/client/assets/index-Ca3he3fq.css +0 -1
  52. package/dist/client/index-4Zwz6zXD.js +0 -6
package/dist/runtime.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { e as ThreadEnv, A as Agent, h as ThreadMetadata, i as ToolResult, M as Message, l as FileRecord, F as FlowState, n as FileStats, G as GrepResult, m as AttachmentRef, r as MessageContent, E as Env, g as ThreadInstance } from './index-CX9Ti98s.js';
2
- export { f as BuilderThreadEndpointHandler, B as Controller, a as ControllerContext, j as FlowResult, p as ImageContentPart, I as ImageMetadata, L as LLMResponse, q as MultimodalContent, R as RequestContext, S as StorageBackend, k as TelemetryEvent, o as TextContentPart, b as ThreadEndpointContext, T as ToolCall, c as createThreadEndpointHandler, d as defineController } from './index-CX9Ti98s.js';
1
+ import { e as ThreadEnv, A as Agent, h as ThreadMetadata, i as ToolResult, M as Message, l as FileRecord, F as FlowState, n as FileStats, G as GrepResult, m as AttachmentRef, r as MessageContent, E as Env, g as ThreadInstance } from './index-DJ7B8CTp.js';
2
+ export { f as BuilderThreadEndpointHandler, B as Controller, a as ControllerContext, j as FlowResult, p as ImageContentPart, I as ImageMetadata, L as LLMResponse, q as MultimodalContent, R as RequestContext, S as StorageBackend, k as TelemetryEvent, o as TextContentPart, b as ThreadEndpointContext, T as ToolCall, c as createThreadEndpointHandler, d as defineController } from './index-DJ7B8CTp.js';
3
3
  import { CodeExecutionOptions, CodeExecutionResult, SubagentRegistryEntry, InjectMessageInput, QueueMessageInput, ClientToolRequest, ClientToolResponse, SkillMetadata, SkillFileInput, ModelDefinition as ModelDefinition$1, ToolArgs, PromptTextPart, PromptEnvPart, VariableDefinition, SubpromptConfig as SubpromptConfig$1, PromptToolConfig as PromptToolConfig$1, SubagentToolConfig as SubagentToolConfig$1, ReasoningConfig, SideConfig as SideConfig$1, LLMProviderInterface, ContentPart, TextPart, ImagePart, FilePart, NamespaceContext, DefinitionLoader } from '@standardagents/spec';
4
4
  export { AgentType, DefinitionLoader, GlobalNamespaceContext, HookSignatures, ImageContent, ModelCapabilities, ModelProvider, NamespaceContext, PackageSignature, PackedExports, PackedMeta, PackedMetadata, PackedNamespaceContext, PromptInput, PromptTextPart, ProviderAssistantMessage, ProviderError, ProviderErrorCode, ProviderFactory, ProviderFactoryConfig, ProviderFinishReason, ProviderGeneratedImage, ProviderMessage, ProviderMessageContent, ModelCapabilities as ProviderModelCapabilities, ProviderReasoningDetail, ProviderRequest, ProviderResponse, ProviderStreamChunk, ProviderSystemMessage, ProviderTool, ProviderToolCallPart, ProviderToolMessage, ProviderToolResultContent, ProviderUsage, ProviderUserMessage, ReasoningConfig, StructuredPrompt, TextContent, Tool, ToolArgs, ToolArgsNode, ToolArgsRawShape, ToolContent, belongsToPackage, defineAgent, defineHook, defineModel, definePrompt, defineTool, isPacked, isVisibleInNamespace, mapReasoningLevel } from '@standardagents/spec';
5
5
  import { DurableObject, WorkerEntrypoint } from 'cloudflare:workers';
@@ -173,6 +173,31 @@ interface CodeExecutionBridgeRegistration {
173
173
  }
174
174
 
175
175
  type ThreadEndpointCodeOptions = Pick<CodeExecutionOptions, "language" | "filename" | "execute" | "modules" | "memoryLimitBytes">;
176
+ /**
177
+ * Result of one watchdog assessment (see performWatchdogAssessment). Returned
178
+ * to whichever delivery invoked it — the internal alarm check, the
179
+ * ThreadWatchdog companion probe, or the diagnostics revive endpoint — so the
180
+ * caller can schedule/record without re-deriving thread state.
181
+ */
182
+ interface WatchdogProbeResult {
183
+ /** What the thread looked like, after any recovery action taken. */
184
+ verdict: "healthy" | "observing" | "recovered" | "parked" | "idle";
185
+ /** The recovery action performed (all actions are already done on return). */
186
+ action: "none" | "finalized_resumed" | "finalized_parked" | "finalized_deferred" | "aborted_takeover_resumed";
187
+ executing: boolean;
188
+ incompleteLogs: number;
189
+ queuedMessages: number;
190
+ /** Milliseconds since the last execution heartbeat; null when unknown/∞. */
191
+ silenceMs: number | null;
192
+ ceilingMs: number;
193
+ strikes: number;
194
+ /**
195
+ * True when a live-but-wedged executor was taken over: the zombie turn may
196
+ * still own this DO's alarm invocation, so the caller should force a
197
+ * restart (ThreadWatchdog calls forceRestart()) to free the alarm chain.
198
+ */
199
+ requestRestart: boolean;
200
+ }
176
201
  declare class DurableThread<Env extends ThreadEnv = ThreadEnv> extends DurableObject<Env> {
177
202
  private migratedToVersion;
178
203
  private logSockets;
@@ -607,7 +632,7 @@ declare class DurableThread<Env extends ThreadEnv = ThreadEnv> extends DurableOb
607
632
  * @param includeSilent Include silent messages (UI-only messages)
608
633
  * @param maxDepth Maximum depth to include (default: 0 for top-level only)
609
634
  */
610
- getMessages(limit?: number, offset?: number, order?: "ASC" | "DESC", includeSilent?: boolean, maxDepth?: number): Promise<{
635
+ getMessages(limit?: number, offset?: number, order?: "ASC" | "DESC" | "asc" | "desc", includeSilent?: boolean, maxDepth?: number): Promise<{
611
636
  messages: {
612
637
  id: string;
613
638
  role: string;
@@ -1087,15 +1112,82 @@ declare class DurableThread<Env extends ThreadEnv = ThreadEnv> extends DurableOb
1087
1112
  alarm(): Promise<void>;
1088
1113
  /** Heartbeat: called by LLMRequest on each attempt and streamed chunk. */
1089
1114
  noteExecutionProgress(): void;
1115
+ /**
1116
+ * The per-thread companion watchdog DO (ThreadWatchdog), derived from the
1117
+ * thread id. It exists because this thread's OWN alarm cannot fire while a
1118
+ * queue-dispatched turn runs inside alarm() — the companion delivers the
1119
+ * same check via RPC, which interleaves at await points even mid-turn.
1120
+ * Returns null on deployments whose generated config predates the binding.
1121
+ */
1122
+ private watchdogCompanion;
1090
1123
  /** Arm the standing watchdog for an execution start. One pending row max. */
1091
1124
  private armExecutionWatchdog;
1092
1125
  /** Disarm on clean execution end. Completed check rows are noise, not history. */
1093
1126
  private disarmExecutionWatchdog;
1094
1127
  /**
1095
- * The standing check. Evaluates the thread's state AT FIRE TIME — it knows
1096
- * nothing about whichever request was in flight when it was armed.
1128
+ * The standing check, alarm-queue delivery. Evaluates the thread's state AT
1129
+ * FIRE TIME — it knows nothing about whichever request was in flight when it
1130
+ * was armed. NOTE this delivery path cannot fire while a queue-dispatched
1131
+ * turn runs (the turn owns this DO's single alarm invocation); the
1132
+ * ThreadWatchdog companion delivers the same assessment via watchdogProbe()
1133
+ * in exactly that window.
1097
1134
  */
1098
1135
  private watchdogCheck;
1136
+ /**
1137
+ * RPC delivery of the standing check — called by the ThreadWatchdog
1138
+ * companion (and the diagnostics revive endpoint). Runs in a fresh request
1139
+ * context, so it interleaves with a running turn at await points and its
1140
+ * own awaits/timers are alive even when a wedged turn's context is frozen.
1141
+ * Does NOT touch the internal watchdogCheck alarm rows — those belong to
1142
+ * the alarm delivery path.
1143
+ */
1144
+ watchdogProbe(threadId: string): Promise<WatchdogProbeResult>;
1145
+ /**
1146
+ * Reset this Durable Object instance on request. Used by the watchdog
1147
+ * companion after a wedged-executor takeover: the zombie turn may still own
1148
+ * this DO's single alarm invocation, which would block the just-enqueued
1149
+ * recovery alarm forever. Aborting guarantees a fresh instance whose alarm
1150
+ * chain re-arms from persisted queue state on first wake.
1151
+ */
1152
+ forceRestart(reason: string): Promise<void>;
1153
+ /**
1154
+ * Execution-health snapshot for the diagnostics endpoint and `agents diag`.
1155
+ * Exposes the state the 2026-07-08 post-mortem could not see from outside:
1156
+ * the alarm queue (was a turn item pending/processing/failed? was the
1157
+ * watchdog row gone?), the volatile execution flags, and open request logs.
1158
+ * Read-only; safe to call at any time.
1159
+ */
1160
+ getDiagnostics(): Promise<{
1161
+ executing: boolean;
1162
+ lastProgressAt: number | null;
1163
+ silenceMs: number | null;
1164
+ watchdogStrikes: number;
1165
+ watchdogCeilingMs: number;
1166
+ stopped: boolean;
1167
+ incompleteLogs: Array<{
1168
+ id: string;
1169
+ model: string | null;
1170
+ provider: string | null;
1171
+ created_at: number;
1172
+ }>;
1173
+ alarmQueue: Array<{
1174
+ id: string;
1175
+ method: string;
1176
+ status: string;
1177
+ scheduled_at: number;
1178
+ created_at: number;
1179
+ attempts: number;
1180
+ error: string | null;
1181
+ }>;
1182
+ messageQueueCount: number;
1183
+ contextUsage: Record<string, unknown> | null;
1184
+ }>;
1185
+ /**
1186
+ * The shared watchdog decision core. Both deliveries (alarm + companion
1187
+ * probe) evaluate and ACT through this method; the caller only decides what
1188
+ * to do with its own scheduling based on the verdict.
1189
+ */
1190
+ private performWatchdogAssessment;
1099
1191
  /** Mark logs the dead executor abandoned, and tell connected clients. */
1100
1192
  private finalizeLostExecutionLogs;
1101
1193
  /**
@@ -2102,6 +2194,92 @@ declare class CodeExecutionBridge extends WorkerEntrypoint<ThreadEnv, CodeExecut
2102
2194
  call(threadId: string, runId: string, functionId: string, encodedArgs: unknown[]): Promise<unknown>;
2103
2195
  }
2104
2196
 
2197
+ /**
2198
+ * ThreadWatchdog — a per-thread companion Durable Object whose only job is to
2199
+ * deliver liveness checks INTO a DurableThread on a schedule the thread cannot
2200
+ * starve.
2201
+ *
2202
+ * Why this exists (2026-07-08 incident, api.standardcode.ai): every normal
2203
+ * turn is dispatched through the thread's own AlarmQueue and runs INSIDE its
2204
+ * alarm() handler. Cloudflare serializes alarm invocations per object and the
2205
+ * queue only re-arms the storage alarm after the current item finishes — so
2206
+ * while a turn runs, the thread's own standing `watchdogCheck` alarm rows are
2207
+ * inert. When a provider request wedged (zero bytes for 18+ minutes, in-flight
2208
+ * stall-guard timers frozen with the turn's context), nothing could fire: the
2209
+ * thread sat "working" forever, and the user's UI polling kept the instance
2210
+ * resident, which is exactly what prevented fresh-instance wake recovery.
2211
+ * A manual RPC delivery of the same check recovered the thread in one call —
2212
+ * the LOGIC was sound, the DELIVERY was starved. This object is that delivery.
2213
+ *
2214
+ * Design rules:
2215
+ * - The alarm handler stays tiny: one probe RPC + reschedule. It must never
2216
+ * run long work, so it can never starve itself the way thread turns do.
2217
+ * - Reschedule-first: the next alarm is set before the probe runs, so a crash
2218
+ * mid-probe never kills the chain.
2219
+ * - Parent-child lifecycle is explicit (Cloudflare has no cascade): the
2220
+ * companion is created lazily by the thread's execution start (`arm`),
2221
+ * stands itself down when the thread probes clean, and is destroyed by
2222
+ * `DurableThread.deleteThread()`/`terminateThread()`. Standing down keeps
2223
+ * the check-in history (the UI reads it) but drops the alarm — a DO with no
2224
+ * alarm and no traffic hibernates at zero cost.
2225
+ * - Probe timeouts are counted, not fatal: a thread DO whose input gate is
2226
+ * permanently blocked cannot be revived at the application layer, so after
2227
+ * MAX_UNREACHABLE consecutive timeouts the companion logs loudly and stands
2228
+ * down instead of ticking forever.
2229
+ */
2230
+ /** One recorded check-in, newest first in storage. */
2231
+ interface WatchdogCheckin {
2232
+ at: number;
2233
+ /** Thread verdict, or 'unreachable' when the probe itself failed/timed out. */
2234
+ verdict: "healthy" | "observing" | "recovered" | "parked" | "idle" | "unreachable";
2235
+ /** What the probe did, for the UI's determination column. */
2236
+ action: string;
2237
+ executing: boolean | null;
2238
+ incompleteLogs: number | null;
2239
+ silenceMs: number | null;
2240
+ probeMs: number;
2241
+ error?: string;
2242
+ }
2243
+ interface ThreadWatchdogState {
2244
+ armed: boolean;
2245
+ threadId: string | null;
2246
+ armedAt: number | null;
2247
+ history: WatchdogCheckin[];
2248
+ }
2249
+ interface ThreadWatchdogEnv {
2250
+ AGENT_BUILDER_THREAD: {
2251
+ idFromName(name: string): unknown;
2252
+ get(id: unknown): unknown;
2253
+ };
2254
+ [key: string]: unknown;
2255
+ }
2256
+ declare class ThreadWatchdog extends DurableObject<ThreadWatchdogEnv> {
2257
+ /**
2258
+ * Arm (or re-arm) the standing check for a thread execution. Idempotent —
2259
+ * called at every execution start. Resets the unreachable counter because a
2260
+ * fresh arm proves the thread is answering RPCs right now.
2261
+ */
2262
+ arm(threadId: string): Promise<void>;
2263
+ /**
2264
+ * Hint that the thread believes its execution ended cleanly. The companion
2265
+ * does NOT trust this (a bogus "clean end" was one of the incident's failure
2266
+ * modes) — it just moves the next check close so a genuinely clean thread
2267
+ * stands down in seconds instead of a full cadence.
2268
+ */
2269
+ disarmHint(): Promise<void>;
2270
+ /** Diagnostics view for the thread inspector UI and the diag CLI. */
2271
+ getState(): Promise<ThreadWatchdogState>;
2272
+ /**
2273
+ * Explicit cascade from the parent thread (delete/terminate). Cloudflare
2274
+ * has no automatic parent-child cleanup — this IS the cleanup.
2275
+ */
2276
+ destroy(): Promise<void>;
2277
+ alarm(): Promise<void>;
2278
+ private getThreadStub;
2279
+ private probeThread;
2280
+ private recordCheckin;
2281
+ }
2282
+
2105
2283
  /**
2106
2284
  * Model definition module for AgentBuilder.
2107
2285
  *
@@ -3538,4 +3716,4 @@ declare function createNamespaceContext(agentDef: {
3538
3716
  */
3539
3717
  declare function isQualifiedName(name: string): boolean;
3540
3718
 
3541
- export { Agent, type AgentBuilderEnv, type AgentDefinition, AttachmentRef, type AuthContext, type AuthUser, type BroadcastOptions, CodeExecutionBridge, DurableAgentBuilder, DurableThread, Env, FileRecord, FileStats, FlowState, FlowStateSdk, type FlowStateWithSdk, GrepResult, type ImageContextConfig, type InjectMessageOptions$1 as InjectMessageOptions, type Provider as LLMProviderInterface, Message, MessageContent, type ModelDefinition, NamespaceResolutionError, NamespacedRegistry, type PromptContent, type PromptDefinition, type PromptIncludePart, type PromptPart, type PromptToolConfig, type Provider$1 as Provider, type ProviderContentPart, type ProviderFilePart, type ProviderImagePart, ProviderRegistry, type ProviderTextPart, type SessionToolBinding, type SessionToolConfig, type SideConfig, type SubagentToolConfig, type SubpromptConfig, ThreadEnv, ThreadInstance, ThreadMetadata, type ThreadRegistryEntry, type ToolConfig, ToolResult, type UpdateThreadParams, type User, authenticate, buildImageDescription, cat, createNamespaceContext, emitThreadEvent, enhanceFlowState, exists, find, forceTurn, generateImageDescription, getFileStats, getMessages, getMessagesToSummarize, getShortName, getThumbnail, getUnsummarizedImageAttachments, getVisibleAgentNames, getVisibleModelNames, getVisiblePromptNames, getVisibleToolNames, grep, hasImageAttachments, head, injectMessage, isQualifiedName, linkFile, mkdir, move, optimizeImageContext, parseQualifiedName, qualifyName, queueTool, readFile, readdir, reloadHistory, rename, replaceImagesWithDescriptions, requireAdmin, requireAuth, resolveAgent, resolveHook, resolveModel, resolvePrompt, resolveTool, rmdir, stat, tail, unlink, updateThread, writeFile, writeImage };
3719
+ export { Agent, type AgentBuilderEnv, type AgentDefinition, AttachmentRef, type AuthContext, type AuthUser, type BroadcastOptions, CodeExecutionBridge, DurableAgentBuilder, DurableThread, Env, FileRecord, FileStats, FlowState, FlowStateSdk, type FlowStateWithSdk, GrepResult, type ImageContextConfig, type InjectMessageOptions$1 as InjectMessageOptions, type Provider as LLMProviderInterface, Message, MessageContent, type ModelDefinition, NamespaceResolutionError, NamespacedRegistry, type PromptContent, type PromptDefinition, type PromptIncludePart, type PromptPart, type PromptToolConfig, type Provider$1 as Provider, type ProviderContentPart, type ProviderFilePart, type ProviderImagePart, ProviderRegistry, type ProviderTextPart, type SessionToolBinding, type SessionToolConfig, type SideConfig, type SubagentToolConfig, type SubpromptConfig, ThreadEnv, ThreadInstance, ThreadMetadata, type ThreadRegistryEntry, ThreadWatchdog, type ThreadWatchdogState, type ToolConfig, ToolResult, type UpdateThreadParams, type User, type WatchdogCheckin, type WatchdogProbeResult, authenticate, buildImageDescription, cat, createNamespaceContext, emitThreadEvent, enhanceFlowState, exists, find, forceTurn, generateImageDescription, getFileStats, getMessages, getMessagesToSummarize, getShortName, getThumbnail, getUnsummarizedImageAttachments, getVisibleAgentNames, getVisibleModelNames, getVisiblePromptNames, getVisibleToolNames, grep, hasImageAttachments, head, injectMessage, isQualifiedName, linkFile, mkdir, move, optimizeImageContext, parseQualifiedName, qualifyName, queueTool, readFile, readdir, reloadHistory, rename, replaceImagesWithDescriptions, requireAdmin, requireAuth, resolveAgent, resolveHook, resolveModel, resolvePrompt, resolveTool, rmdir, stat, tail, unlink, updateThread, writeFile, writeImage };