agent-neckbeard 1.1.26 → 1.1.28

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.cts CHANGED
@@ -1,5 +1,7 @@
1
1
  import { Buffer } from 'node:buffer';
2
2
  import { S as SandboxFileContent$1, a as SandboxCommandOptions, b as SandboxCommandResult, c as SandboxDetachedCommandOptions, d as SandboxDetachedCommand } from './sandbox-capabilities-CFjnZ_kB.cjs';
3
+ import { S as StartTurnRequest, T as TurnRecord, a as TurnHealth, b as ServedSession, c as ServeHandle } from './serve-Dan1HQKN.cjs';
4
+ export { P as PiTurnResult, d as TURN_PROTOCOL_VERSION, e as TurnOutcome, g as getPiTurnResult } from './serve-Dan1HQKN.cjs';
3
5
 
4
6
  /** Sandbox providers supported by the public and in-sandbox runtimes. */
5
7
  type SandboxProvider = 'e2b' | 'daytona' | 'modal' | 'docker';
@@ -55,6 +57,32 @@ interface ModalSandboxConfig {
55
57
  timeoutMs?: number;
56
58
  cpu?: number;
57
59
  memoryMiB?: number;
60
+ /**
61
+ * Regions the sandbox may run in, such as `['us']` or `['us-east']`. Modal
62
+ * otherwise places it in any region worldwide, and every file and command
63
+ * call pays the round trip. Pinned regions cost more; see docs/MODAL.md.
64
+ */
65
+ regions?: string[];
66
+ /**
67
+ * Whether to block all sandbox network egress. Cannot be combined with
68
+ * non-empty allow lists.
69
+ */
70
+ networkBlockAll?: boolean;
71
+ /**
72
+ * Comma-separated CIDR allow list for sandbox egress, any protocol.
73
+ *
74
+ * Example: '203.0.113.0/24,198.51.100.10/32'
75
+ */
76
+ networkAllowList?: string;
77
+ /**
78
+ * Comma-separated domain allow list for sandbox egress. Modal matches the
79
+ * TLS SNI, so it only allows HTTPS (port 443) to these domains; when set, the
80
+ * image's apt sources are switched to HTTPS. Wildcards are supported with a
81
+ * leading `*.`. Traffic matching either allow list is allowed.
82
+ *
83
+ * Example: '*.example.com,api.openai.com'
84
+ */
85
+ domainAllowList?: string;
58
86
  }
59
87
  interface ModalClientCredentials {
60
88
  tokenId?: string;
@@ -63,12 +91,285 @@ interface ModalClientCredentials {
63
91
  }
64
92
  type ModalSandboxCreateOptions = ModalSandboxConfig & ModalClientCredentials & {
65
93
  envs?: Record<string, string | undefined>;
94
+ /**
95
+ * Runs as the sandbox's main process, with `template` used as-is: no setup layer and no
96
+ * working directory override. For images that already contain everything, as `Agent` uses.
97
+ */
98
+ command?: string[];
99
+ /** Name of a Modal Secret with `REGISTRY_USERNAME` and `REGISTRY_PASSWORD`, to pull a private `template`. */
100
+ registrySecret?: string;
66
101
  };
67
102
  type ModalSandboxConnectOptions = ModalClientCredentials & {
68
103
  provider: 'modal';
69
104
  sandboxId: string;
70
105
  };
71
106
 
107
+ type DaytonaCreateOptions = Extract<SandboxClientCreateOptions, {
108
+ provider: 'daytona';
109
+ }>;
110
+ type E2bCreateOptions = Extract<SandboxClientCreateOptions, {
111
+ provider: 'e2b';
112
+ }>;
113
+ /** The Modal sandbox options `Agent` passes through; the image is its `template`. */
114
+ interface ModalAgentSandbox extends Pick<ModalSandboxCreateOptions, 'provider' | 'appName' | 'environment' | 'timeoutMs' | 'cpu' | 'memoryMiB' | 'regions' | 'networkBlockAll' | 'networkAllowList' | 'domainAllowList' | 'registrySecret'> {
115
+ }
116
+ interface DaytonaAgentSandbox extends Pick<DaytonaSandboxConfig, 'provider' | 'networkBlockAll' | 'networkAllowList' | 'domainAllowList' | 'autoStopInterval' | 'autoDeleteInterval'>, Pick<DaytonaCreateOptions, 'apiKey'> {
117
+ /** Snapshot resources: vCPUs, and memory and disk in GiB. */
118
+ resources?: {
119
+ cpu?: number;
120
+ memory?: number;
121
+ disk?: number;
122
+ };
123
+ }
124
+ interface E2bAgentSandbox extends Pick<E2bCreateOptions, 'provider' | 'apiKey' | 'timeoutMs'> {
125
+ /** Template resources. */
126
+ cpuCount?: number;
127
+ memoryMB?: number;
128
+ /** Credentials E2B uses to pull a private image when it builds the template. */
129
+ registry?: {
130
+ username: string;
131
+ password: string;
132
+ };
133
+ }
134
+ type AgentSandbox = ModalAgentSandbox | DaytonaAgentSandbox | E2bAgentSandbox;
135
+ interface AgentOptions {
136
+ /** Names this agent's Daytona snapshots and E2B templates; lowercase letters, digits, and dashes. */
137
+ name: string;
138
+ /** Registry image with the agent and `serve()`, such as `ghcr.io/acme/agent:<commit>`. */
139
+ image: string;
140
+ sandbox: AgentSandbox;
141
+ /** Starts the runtime in the image. Defaults to `node /app/agent.mjs`. */
142
+ command?: string[];
143
+ /** Port `serve()` listens on, passed to it as `NECKBEARD_PORT`. Defaults to 8080. */
144
+ port?: number;
145
+ /** Environment of every sandbox. Secrets go here or in `start()`, never in the image. */
146
+ envs?: Record<string, string | undefined>;
147
+ /** How long `start()` waits for the runtime to answer. Defaults to two minutes. */
148
+ startTimeoutMs?: number;
149
+ /** How long `prepare()` waits for a Daytona snapshot or E2B template build. Defaults to 30 minutes. */
150
+ prepareTimeoutMs?: number;
151
+ }
152
+ interface StartOptions {
153
+ envs?: Record<string, string | undefined>;
154
+ /** Names the conversation a persisted Pi session keeps, given to the runtime as `NECKBEARD_SESSION_ID`. */
155
+ sessionId?: string;
156
+ signal?: AbortSignal;
157
+ }
158
+ interface RunOptions<TEvent> extends Omit<TurnStreamOptions, 'after'> {
159
+ /** Receives each record as it streams, for example to store or show it, keyed by `seq`. */
160
+ onRecord?: (record: TurnRecord<TEvent>) => void | Promise<void>;
161
+ }
162
+ interface TurnStreamOptions {
163
+ /** Stops reading the stream; the turn keeps running. Use `abort()` to stop the turn. */
164
+ signal?: AbortSignal;
165
+ /** Resume after this record's `seq`. Defaults to -1, the start of the turn. */
166
+ after?: number;
167
+ /**
168
+ * How long to keep reconnecting without a healthy connection. Defaults to two minutes. A
169
+ * connection that sends nothing, not even the runtime's heartbeat every 15 seconds, for this long
170
+ * is abandoned, so keep it above 15 seconds.
171
+ */
172
+ reconnectTimeoutMs?: number;
173
+ }
174
+ /**
175
+ * Runs a Pi agent from a prebuilt image whose main process is `serve()` from
176
+ * `agent-neckbeard/serve`. Every method takes the sandbox ID, so any host process can drive a
177
+ * sandbox another one started.
178
+ */
179
+ declare class Agent<TEvent = unknown> {
180
+ private readonly options;
181
+ readonly name: string;
182
+ readonly image: string;
183
+ readonly command: string[];
184
+ readonly port: number;
185
+ private readonly endpoints;
186
+ private preparing?;
187
+ constructor(options: AgentOptions);
188
+ get provider(): AgentSandbox['provider'];
189
+ /**
190
+ * Name of the Daytona snapshot or E2B template for this image, command, and resources. Equal
191
+ * inputs share one, so preparing again is a lookup.
192
+ */
193
+ get artifactName(): string;
194
+ /**
195
+ * Creates the Daytona snapshot or E2B template for the image if it is missing and waits until
196
+ * it can start sandboxes. Run it from CI after pushing the image so no sandbox waits on a
197
+ * build. Modal pulls the image directly, so this does nothing there. `refresh` builds it again
198
+ * even when it exists, as after pushing new contents under a tag it was built from, since its
199
+ * name comes from the image's reference, not its contents.
200
+ */
201
+ prepare(options?: {
202
+ signal?: AbortSignal;
203
+ onLog?: (line: string) => void;
204
+ refresh?: boolean;
205
+ }): Promise<void>;
206
+ /** Starts a sandbox from the image and waits for its runtime. Returns the sandbox ID. */
207
+ start(options?: StartOptions): Promise<string>;
208
+ /**
209
+ * Starts a turn and streams its records until its `end` record. Starting a turn whose
210
+ * `turnId` the runtime already has resumes it instead of running it again.
211
+ */
212
+ prompt(sandboxId: string, turn: StartTurnRequest, options?: TurnStreamOptions): AsyncGenerator<TurnRecord<TEvent>>;
213
+ /**
214
+ * Runs a Pi turn to its end and returns its final assistant text, or null when it had none.
215
+ * Throws `ExecutionError` when the turn did not complete or its model did not stop on its own.
216
+ * Running a turn again with the same `turnId` replays its records from the start.
217
+ */
218
+ run(sandboxId: string, turn: StartTurnRequest, options?: RunOptions<TEvent>): Promise<string | null>;
219
+ /**
220
+ * Streams a turn's records after `options.after` until its `end` record, reconnecting when
221
+ * the connection drops. Throws `TurnLostError` when the runtime no longer has the turn.
222
+ */
223
+ events(sandboxId: string, turnId: string, options?: TurnStreamOptions): AsyncGenerator<TurnRecord<TEvent>>;
224
+ /** Asks the runtime to stop the turn; its stream then ends with an `aborted` record. */
225
+ abort(sandboxId: string, turnId: string, signal?: AbortSignal): Promise<void>;
226
+ health(sandboxId: string, signal?: AbortSignal): Promise<TurnHealth>;
227
+ /** Waits until no turn runs, for example before reading files a turn writes. */
228
+ waitForIdle(sandboxId: string, options?: {
229
+ timeoutMs?: number;
230
+ signal?: AbortSignal;
231
+ }): Promise<void>;
232
+ /**
233
+ * Deletes the sandbox without starting it. One that is already gone counts as deleted; any other
234
+ * failure throws, so cleanup can be retried, since a Daytona sandbox need not expire on its own.
235
+ */
236
+ kill(sandboxId: string): Promise<void>;
237
+ /** File and command access to a sandbox, for staging inputs and reading results. */
238
+ sandbox(sandboxId: string): Promise<SandboxClient>;
239
+ /**
240
+ * Deletes this agent's Daytona snapshots or E2B templates except the newest `keep` and the
241
+ * current one. Returns the names it deleted.
242
+ */
243
+ gc(options?: {
244
+ keep?: number;
245
+ alsoKeep?: string[];
246
+ }): Promise<string[]>;
247
+ private createSandbox;
248
+ private startE2bRuntime;
249
+ private waitForRuntime;
250
+ private endpoint;
251
+ private request;
252
+ private prepareDaytonaSnapshot;
253
+ private prepareE2bTemplate;
254
+ private listDaytonaSnapshots;
255
+ private e2bTemplates;
256
+ private listE2bTemplates;
257
+ }
258
+
259
+ /** Where `neckbeard build` installs an agent's skills in its image. */
260
+ declare const SKILLS_DIR = "/app/.agents/skills";
261
+ /**
262
+ * The image tag a host should run: `NECKBEARD_IMAGE_TAG`, else the commit its platform deployed,
263
+ * which is the commit CI tagged the image with.
264
+ */
265
+ declare function resolveImageTag(env?: NodeJS.ProcessEnv): string | undefined;
266
+ type ThinkingLevel = 'off' | 'minimal' | 'low' | 'medium' | 'high' | 'xhigh';
267
+ /** A Pi session for `defineAgent()` to create in the sandbox. */
268
+ interface PiSessionConfig {
269
+ /** `provider/model`, such as `openai/gpt-6.1-sol`. */
270
+ model: string;
271
+ thinkingLevel?: ThinkingLevel;
272
+ /** Pi's built-in tools to enable, such as `read` and `bash`. */
273
+ tools?: string[];
274
+ systemPrompt: string;
275
+ /**
276
+ * The working directory, relative to the sandbox user's home unless absolute. Created before the
277
+ * session, and exported to the agent's commands as `NECKBEARD_CWD`. Defaults to `workspace`.
278
+ */
279
+ cwd?: string;
280
+ /**
281
+ * Keeps the conversation in a file named for the `sessionId` passed to `start()`, so a restarted
282
+ * runtime, or a sandbox restored from a copy of the file, continues it. See `sessionFilePath()`.
283
+ * Otherwise the conversation lives in memory for the sandbox's life.
284
+ */
285
+ persist?: boolean;
286
+ }
287
+ /** An agent: its image, sandbox, and either a Pi session config or its own session factory. */
288
+ interface AgentDefinition {
289
+ /** Names the image and the provider's snapshots or templates; lowercase letters, digits, and dashes. */
290
+ name: string;
291
+ /** Registry the image lives under, such as `ghcr.io/acme`; the image is `<registry>/<name>:<tag>`. */
292
+ registry?: string;
293
+ /** A full image reference instead of `registry`, such as one built elsewhere. */
294
+ image?: string;
295
+ /** The sandbox, or a function returning it, read only on the host. */
296
+ sandbox: AgentSandbox | (() => AgentSandbox);
297
+ /**
298
+ * Environment of every sandbox, or a function returning it, read only on the host, so the image
299
+ * needs none of the host's configuration. Never secrets in the image. A `pi` agent is traced in
300
+ * Braintrust when this has BRAINTRUST_API_KEY and BRAINTRUST_PROJECT_NAME; see docs/AGENT.md#tracing.
301
+ */
302
+ envs?: Record<string, string | undefined> | (() => Record<string, string | undefined>);
303
+ /** The image's main process. Defaults to `node /app/agent.mjs`, the entry point `neckbeard build` writes. */
304
+ command?: string[];
305
+ /** The port the runtime listens on, given to it as NECKBEARD_PORT. Defaults to 8080. */
306
+ port?: number;
307
+ /** How long `start()` waits for the runtime to answer. Defaults to two minutes. */
308
+ startTimeoutMs?: number;
309
+ /** How long `prepare()` may take to create a Daytona snapshot or E2B template. Defaults to 30 minutes. */
310
+ prepareTimeoutMs?: number;
311
+ /** Ends a turn that runs longer as failed. */
312
+ maxTurnDurationMs?: number;
313
+ /** See `ServeOptions.abortGraceMs`. */
314
+ abortGraceMs?: number;
315
+ /** The agent's Pi session. */
316
+ pi?: PiSessionConfig;
317
+ /** Creates the session instead of `pi`, for one that config can't express. */
318
+ createSession?: () => Promise<ServedSession>;
319
+ build?: {
320
+ /** Packages the image installs instead of bundling; Pi's always are, and for a `pi` agent Braintrust when its package depends on it. */
321
+ external?: string[];
322
+ /** The Dockerfile `neckbeard push` builds the image with, relative to the package. Defaults to `sandbox/Dockerfile`. */
323
+ dockerfile?: string;
324
+ };
325
+ }
326
+ declare const definedAgentMarker: unique symbol;
327
+ /**
328
+ * An agent defined once for both sides. On the host it starts sandboxes and runs turns, building
329
+ * its `Agent` the first time one is needed, so importing it in the image requires no image tag or
330
+ * host configuration. In the image, `serve()` serves its session.
331
+ */
332
+ declare class DefinedAgent<TEvent = unknown> {
333
+ readonly definition: AgentDefinition;
334
+ readonly [definedAgentMarker] = true;
335
+ private client?;
336
+ private braintrustChecked;
337
+ constructor(definition: AgentDefinition);
338
+ get name(): string;
339
+ /** The image this host runs: `image`, else `<registry>/<name>:<tag>` with the tag `resolveImageTag()` finds. */
340
+ imageRef(tag?: string | undefined): string;
341
+ /** The `Agent` for an image, by default the one this host runs. */
342
+ forImage(image?: string): Agent<TEvent>;
343
+ private get agent();
344
+ get artifactName(): string;
345
+ prepare(options?: Parameters<Agent<TEvent>['prepare']>[0]): Promise<void>;
346
+ start(options?: StartOptions): Promise<string>;
347
+ prompt(sandboxId: string, turn: StartTurnRequest, options?: TurnStreamOptions): AsyncGenerator<TurnRecord<TEvent>>;
348
+ run(sandboxId: string, turn: StartTurnRequest, options?: RunOptions<TEvent>): Promise<string | null>;
349
+ events(sandboxId: string, turnId: string, options?: TurnStreamOptions): AsyncGenerator<TurnRecord<TEvent>>;
350
+ abort(sandboxId: string, turnId: string, signal?: AbortSignal): Promise<void>;
351
+ health(sandboxId: string, signal?: AbortSignal): Promise<TurnHealth>;
352
+ waitForIdle(sandboxId: string, options?: {
353
+ timeoutMs?: number;
354
+ signal?: AbortSignal;
355
+ }): Promise<void>;
356
+ kill(sandboxId: string): Promise<void>;
357
+ sandbox(sandboxId: string): ReturnType<Agent<TEvent>['sandbox']>;
358
+ gc(options?: {
359
+ keep?: number;
360
+ alsoKeep?: string[];
361
+ }): Promise<string[]>;
362
+ /** Where a persisted session's file is in a sandbox whose home is `homeDir`, as for copying it out and back. */
363
+ sessionFilePath(homeDir: string, sessionId: string): string;
364
+ /** Serves the agent's session; the image's entry point, which `neckbeard build` generates, calls it. */
365
+ serve(options?: {
366
+ port?: number;
367
+ host?: string;
368
+ }): Promise<ServeHandle>;
369
+ }
370
+ declare function defineAgent<TEvent = unknown>(definition: AgentDefinition): DefinedAgent<TEvent>;
371
+ declare function isDefinedAgent(value: unknown): value is DefinedAgent<unknown>;
372
+
72
373
  interface DockerSandboxConfig {
73
374
  provider: 'docker';
74
375
  /** Debian-compatible image with Node.js/npm for `Agent`; defaults to node:22-bookworm. */
@@ -111,7 +412,9 @@ declare class NeckbeardError extends Error {
111
412
  */
112
413
  declare class DeploymentError extends NeckbeardError {
113
414
  readonly cause?: Error | undefined;
114
- constructor(message: string, cause?: Error | undefined);
415
+ readonly sandboxId?: string | undefined;
416
+ /** A sandbox the failure left behind, for `kill()`. */
417
+ constructor(message: string, cause?: Error | undefined, sandboxId?: string | undefined);
115
418
  }
116
419
  /**
117
420
  * Error thrown when input or output schema validation fails.
@@ -134,6 +437,13 @@ declare class ExecutionError extends NeckbeardError {
134
437
  declare class RuntimeBusyError extends ExecutionError {
135
438
  constructor(message: string);
136
439
  }
440
+ /**
441
+ * Thrown when a sandbox's runtime no longer knows a turn, because the sandbox restarted or was
442
+ * replaced. The turn's outcome is unknown.
443
+ */
444
+ declare class TurnLostError extends ExecutionError {
445
+ constructor(message: string);
446
+ }
137
447
  /**
138
448
  * Error thrown when required environment variables are missing.
139
449
  */
@@ -221,6 +531,9 @@ interface ResolveAgentSourceFileOptions {
221
531
  */
222
532
  sandboxSourceFile?: string;
223
533
  }
534
+ /**
535
+ * @deprecated Only `LegacyBundledAgent` needs it; `Agent` runs a prebuilt image.
536
+ */
224
537
  declare function resolveAgentSourceFile(candidates: string[], options?: ResolveAgentSourceFileOptions): string;
225
538
  type NextConfigObject = {
226
539
  outputFileTracingIncludes?: Record<string, unknown>;
@@ -239,6 +552,9 @@ type NextWebpackContext = Record<string, unknown> & {
239
552
  isServer?: boolean;
240
553
  };
241
554
  type NextWebpackFunction = (config: NextWebpackConfig, context: NextWebpackContext) => NextWebpackConfig;
555
+ /**
556
+ * @deprecated Only `LegacyBundledAgent` needs it; `Agent` runs a prebuilt image.
557
+ */
242
558
  declare function withNeckbeardNextConfig<TConfig extends NextConfigObject>(nextConfig: TConfig, options: NeckbeardNextConfigOptions): TConfig & NextConfigObject;
243
559
  /**
244
560
  * Configuration for downloading a file into the sandbox filesystem.
@@ -368,7 +684,7 @@ interface AgentSessionHandler<TInput, TFrame> {
368
684
  }
369
685
  /**
370
686
  * Attached-session agent config. The sandbox runtime emits typed events for
371
- * sequential caller-owned turns created with `Agent.createSession()`.
687
+ * sequential caller-owned turns created with `LegacyBundledAgent.createSession()`.
372
688
  */
373
689
  interface SessionAgentConfig<TInput, TFrame> extends AgentSharedConfig<TInput> {
374
690
  session: AgentSessionHandler<TInput, TFrame>;
@@ -439,10 +755,12 @@ interface DaytonaSandboxConfig {
439
755
  }
440
756
  type SandboxConfig = E2BSandboxConfig | DaytonaSandboxConfig | ModalSandboxConfig | DockerSandboxConfig;
441
757
  /**
442
- * Agent config accepted by `new Agent(config)`. Can be either a structured task
758
+ * Agent config accepted by `new LegacyBundledAgent(config)`. Can be either a structured task
443
759
  * (`run`) or an attached-session handler (`session.handler`). Both run behind
444
760
  * the same persistent in-sandbox HTTP server.
445
761
  * The deprecated `server.handler` spelling remains accepted.
762
+ *
763
+ * @deprecated Use `Agent` with a prebuilt image and its `AgentOptions`.
446
764
  */
447
765
  type AgentConfig<TInput, TOutput, TFrame = unknown> = RunAgentConfig<TInput, TOutput> | SessionAgentConfig<TInput, TFrame> | ServerAgentConfig<TInput, TFrame>;
448
766
  type SandboxClientCreateOptions = ModalSandboxCreateOptions | DockerSandboxCreateOptions | {
@@ -477,6 +795,11 @@ type SandboxClientConnectOptions = ModalSandboxConnectOptions | DockerSandboxCon
477
795
  apiKey?: string;
478
796
  createTimeoutSec?: number;
479
797
  };
798
+ interface SandboxServerEndpoint {
799
+ url: string;
800
+ headers: Record<string, string>;
801
+ query: Record<string, string>;
802
+ }
480
803
  declare class SandboxClient {
481
804
  private readonly handle;
482
805
  private constructor();
@@ -558,6 +881,11 @@ declare class SandboxClient {
558
881
  */
559
882
  disposeSessionArtifacts(command: SandboxDetachedCommand): Promise<void>;
560
883
  setTimeout(timeoutMs: number): Promise<void>;
884
+ /**
885
+ * Where to reach an HTTP server the sandbox runs on `port`, with the provider's auth: send
886
+ * `headers` with every request and add `query` to every URL.
887
+ */
888
+ getServerEndpoint(port: number): Promise<SandboxServerEndpoint>;
561
889
  kill(): Promise<void>;
562
890
  destroy(): Promise<void>;
563
891
  }
@@ -566,7 +894,11 @@ type AgentMode = 'run' | 'stream';
566
894
  type AgentKind = 'task' | 'session';
567
895
  /** @deprecated Durable sessions use the separate, deprecated supervisor deployment API. */
568
896
  type SessionDurability = 'attached' | 'durable';
569
- declare class Agent<TInput, TOutput = unknown, TFrame = unknown> {
897
+ /**
898
+ * @deprecated Bundles the agent's code on the host and uploads it, its dependencies, and its
899
+ * local directories at every deploy. Use `Agent` with a prebuilt image instead.
900
+ */
901
+ declare class LegacyBundledAgent<TInput, TOutput = unknown, TFrame = unknown> {
570
902
  readonly sandbox: SandboxConfig;
571
903
  readonly provider: SandboxProvider;
572
904
  readonly template: string;
@@ -635,7 +967,7 @@ declare class Agent<TInput, TOutput = unknown, TFrame = unknown> {
635
967
  *
636
968
  * @example
637
969
  * ```typescript
638
- * const agent = new Agent({ ... });
970
+ * const agent = new LegacyBundledAgent({ ... });
639
971
  * const sandboxId = await agent.deploy();
640
972
  * console.log(`Deployed to sandbox: ${sandboxId}`);
641
973
  *
@@ -703,4 +1035,4 @@ declare class Agent<TInput, TOutput = unknown, TFrame = unknown> {
703
1035
  }): AsyncGenerator<TFrame>;
704
1036
  }
705
1037
 
706
- export { Agent, type AgentConfig, type AgentKind, type AgentMode, type AgentRunContext, type AgentRunResult, type AgentSandboxContext, type AgentSessionHandler, type AttachedAgentSession, type BuildOptions, ConfigurationError, type CreateAttachedSessionOptions, DEFAULT_DEPENDENCIES, type DaytonaSandboxConfig, DeploymentError, type DockerSandboxConfig, type E2BSandboxConfig, ExecutionError, type FileDownload, type LocalDirectoryUpload, type ModalSandboxConfig, NeckbeardError, type NeckbeardNextConfigOptions, type OsDependencies, type ResolveAgentSourceFileOptions, type RunAgentConfig, RuntimeBusyError, SandboxClient, type SandboxClientConnectOptions, type SandboxClientCreateOptions, SandboxCommandOptions, SandboxCommandResult, type SandboxConfig, SandboxDetachedCommand, SandboxDetachedCommandOptions, type SandboxFileContent, type SandboxProvider, type ServerAgentConfig, type SessionAgentConfig, type SessionDurability, ValidationError, resolveAgentSourceFile, withNeckbeardNextConfig };
1038
+ export { Agent, type AgentConfig, type AgentDefinition, type AgentKind, type AgentMode, type AgentOptions, type AgentRunContext, type AgentRunResult, type AgentSandbox, type AgentSandboxContext, type AgentSessionHandler, type AttachedAgentSession, type BuildOptions, ConfigurationError, type CreateAttachedSessionOptions, DEFAULT_DEPENDENCIES, type DaytonaAgentSandbox, type DaytonaSandboxConfig, DefinedAgent, DeploymentError, type DockerSandboxConfig, type E2BSandboxConfig, type E2bAgentSandbox, ExecutionError, type FileDownload, LegacyBundledAgent, type LocalDirectoryUpload, type ModalAgentSandbox, type ModalSandboxConfig, NeckbeardError, type NeckbeardNextConfigOptions, type OsDependencies, type PiSessionConfig, type ResolveAgentSourceFileOptions, type RunAgentConfig, type RunOptions, RuntimeBusyError, SKILLS_DIR, SandboxClient, type SandboxClientConnectOptions, type SandboxClientCreateOptions, SandboxCommandOptions, SandboxCommandResult, type SandboxConfig, SandboxDetachedCommand, SandboxDetachedCommandOptions, type SandboxFileContent, type SandboxProvider, type SandboxServerEndpoint, type ServerAgentConfig, type SessionAgentConfig, type SessionDurability, type StartOptions, StartTurnRequest, TurnHealth, TurnLostError, TurnRecord, type TurnStreamOptions, ValidationError, defineAgent, isDefinedAgent, resolveAgentSourceFile, resolveImageTag, withNeckbeardNextConfig };