noumen 0.4.0 → 0.6.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.
- package/README.md +63 -8
- package/dist/a2a/index.d.ts +6 -4
- package/dist/acp/index.d.ts +7 -5
- package/dist/{agent-1nFVUP9E.d.ts → agent-DWE4_P5X.d.ts} +169 -485
- package/dist/{cache-DsRqxx6v.d.ts → cache-BlBwXXPS.d.ts} +1 -1
- package/dist/{chunk-4HW6LN6D.js → chunk-6MMYCGJQ.js} +366 -1227
- package/dist/chunk-6MMYCGJQ.js.map +1 -0
- package/dist/{chunk-5JN4SPI7.js → chunk-7IQCQI2G.js} +1 -1
- package/dist/{chunk-L3L3FG5T.js → chunk-CCM2AXZG.js} +1 -1
- package/dist/{chunk-L3L3FG5T.js.map → chunk-CCM2AXZG.js.map} +1 -1
- package/dist/{chunk-CS6WNDCF.js → chunk-I3JTUFPK.js} +2 -2
- package/dist/chunk-I3JTUFPK.js.map +1 -0
- package/dist/chunk-I5SBSOS6.js +40 -0
- package/dist/chunk-I5SBSOS6.js.map +1 -0
- package/dist/{chunk-HL6JCRZJ.js → chunk-XZN4QZLK.js} +4 -4
- package/dist/{chunk-EKOGVTBT.js → chunk-ZXSDKBYB.js} +4 -2
- package/dist/chunk-ZXSDKBYB.js.map +1 -0
- package/dist/cli/index.js +11 -11
- package/dist/client/index.d.ts +1 -1
- package/dist/computer-BPdxSo6X.d.ts +88 -0
- package/dist/docker.d.ts +129 -0
- package/dist/docker.js +401 -0
- package/dist/docker.js.map +1 -0
- package/dist/e2b.d.ts +157 -0
- package/dist/e2b.js +202 -0
- package/dist/e2b.js.map +1 -0
- package/dist/freestyle.d.ts +174 -0
- package/dist/freestyle.js +240 -0
- package/dist/freestyle.js.map +1 -0
- package/dist/index.d.ts +19 -204
- package/dist/index.js +38 -48
- package/dist/lsp/index.d.ts +4 -3
- package/dist/mcp/index.d.ts +5 -4
- package/dist/mcp/index.js +2 -2
- package/dist/{provider-factory-KCLIF34X.js → provider-factory-TUHU3DIG.js} +2 -2
- package/dist/providers/anthropic.d.ts +3 -3
- package/dist/providers/anthropic.js +4 -3
- package/dist/providers/anthropic.js.map +1 -1
- package/dist/providers/bedrock.d.ts +3 -3
- package/dist/providers/bedrock.js +2 -2
- package/dist/providers/bedrock.js.map +1 -1
- package/dist/providers/gemini.d.ts +2 -2
- package/dist/providers/gemini.js +1 -1
- package/dist/providers/gemini.js.map +1 -1
- package/dist/providers/ollama.d.ts +1 -1
- package/dist/providers/ollama.js +2 -2
- package/dist/providers/openai.d.ts +2 -2
- package/dist/providers/openai.js +2 -2
- package/dist/providers/openrouter.d.ts +1 -1
- package/dist/providers/openrouter.js +2 -2
- package/dist/providers/vertex.d.ts +3 -3
- package/dist/providers/vertex.js +4 -3
- package/dist/providers/vertex.js.map +1 -1
- package/dist/{resolve-4JA2BBDA.js → resolve-6KUZNEYW.js} +2 -2
- package/dist/sandbox-9qeMTNrD.d.ts +126 -0
- package/dist/server/index.d.ts +6 -4
- package/dist/{server-CHMxuWKq.d.ts → server-BzNGKTP6.d.ts} +1 -1
- package/dist/sprites.d.ts +136 -0
- package/dist/sprites.js +334 -0
- package/dist/sprites.js.map +1 -0
- package/dist/ssh.d.ts +187 -0
- package/dist/ssh.js +392 -0
- package/dist/ssh.js.map +1 -0
- package/dist/{types-RPKUTu1k.d.ts → types-DhXwOQwD.d.ts} +3 -89
- package/dist/{types-LrU4LRmX.d.ts → types-kiGBF35b.d.ts} +40 -2
- package/package.json +25 -1
- package/dist/chunk-4HW6LN6D.js.map +0 -1
- package/dist/chunk-CS6WNDCF.js.map +0 -1
- package/dist/chunk-EKOGVTBT.js.map +0 -1
- /package/dist/{chunk-5JN4SPI7.js.map → chunk-7IQCQI2G.js.map} +0 -0
- /package/dist/{chunk-HL6JCRZJ.js.map → chunk-XZN4QZLK.js.map} +0 -0
- /package/dist/{provider-factory-KCLIF34X.js.map → provider-factory-TUHU3DIG.js.map} +0 -0
- /package/dist/{resolve-4JA2BBDA.js.map → resolve-6KUZNEYW.js.map} +0 -0
|
@@ -1,8 +1,10 @@
|
|
|
1
|
-
import { A as AIProvider,
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { A as AIProvider, b as ChatMessage, S as StreamEvent, E as Entry, U as UUID, d as FileCheckpointSnapshot, f as ContentReplacementRecord$1, g as SessionInfo, M as ModelPricing, h as UsageRecord, i as CostSummary, j as ModelUsageSummary, k as ChatCompletionUsage, l as ThinkingConfig, m as MemoryConfig, O as OutputFormat, e as ContentPart, R as RunOptions, c as CheckpointConfig, n as ToolResult } from './types-kiGBF35b.js';
|
|
2
|
+
import { S as Sandbox } from './sandbox-9qeMTNrD.js';
|
|
3
|
+
import { T as Tool, H as HookDefinition, S as SubagentConfig, i as SubagentRun, j as TaskStore, e as LspServerManager, F as FileCheckpointManager, k as FileStateCacheConfig, L as LspServerConfig } from './types-DhXwOQwD.js';
|
|
4
|
+
import { C as CacheControlConfig } from './cache-BlBwXXPS.js';
|
|
4
5
|
import { M as McpServerConfig, T as TokenStorage } from './types-2kTLUCnD.js';
|
|
5
6
|
import { c as PermissionHandler, d as PermissionConfig } from './types-CD0rUKKT.js';
|
|
7
|
+
import { a as VirtualFs, V as VirtualComputer } from './computer-BPdxSo6X.js';
|
|
6
8
|
|
|
7
9
|
type ProviderName = "openai" | "anthropic" | "gemini" | "openrouter" | "bedrock" | "vertex" | "ollama";
|
|
8
10
|
declare const DEFAULT_MODELS: Record<string, string>;
|
|
@@ -26,506 +28,89 @@ declare function resolveProvider(input: AIProvider | ProviderName, opts?: Resolv
|
|
|
26
28
|
declare function detectProvider(): Promise<ProviderName | undefined>;
|
|
27
29
|
|
|
28
30
|
/**
|
|
29
|
-
*
|
|
30
|
-
*/
|
|
31
|
-
interface SandboxConfig {
|
|
32
|
-
filesystem?: {
|
|
33
|
-
/** Paths the agent may write to (default: `[cwd]`). Write is denied everywhere else. */
|
|
34
|
-
allowWrite?: string[];
|
|
35
|
-
/** Paths to explicitly deny writes within allowed regions. */
|
|
36
|
-
denyWrite?: string[];
|
|
37
|
-
/** Paths to deny reading. By default everything is readable. */
|
|
38
|
-
denyRead?: string[];
|
|
39
|
-
/** Paths to re-allow reading within denyRead regions. Takes precedence over denyRead. */
|
|
40
|
-
allowRead?: string[];
|
|
41
|
-
};
|
|
42
|
-
network?: {
|
|
43
|
-
/** Domains the agent may reach via HTTP/HTTPS/SOCKS. */
|
|
44
|
-
allowedDomains?: string[];
|
|
45
|
-
/** Domains to explicitly block. */
|
|
46
|
-
deniedDomains?: string[];
|
|
47
|
-
};
|
|
48
|
-
}
|
|
49
|
-
interface SandboxedLocalComputerOptions {
|
|
50
|
-
defaultCwd?: string;
|
|
51
|
-
defaultTimeout?: number;
|
|
52
|
-
sandbox?: SandboxConfig;
|
|
53
|
-
}
|
|
54
|
-
/**
|
|
55
|
-
* `VirtualComputer` that wraps every command with OS-level sandboxing via
|
|
56
|
-
* `@anthropic-ai/sandbox-runtime`. Uses macOS Seatbelt (`sandbox-exec`) or
|
|
57
|
-
* Linux bubblewrap (`bwrap`) under the hood.
|
|
58
|
-
*/
|
|
59
|
-
declare class SandboxedLocalComputer implements VirtualComputer {
|
|
60
|
-
private defaultCwd;
|
|
61
|
-
private defaultTimeout;
|
|
62
|
-
private sandboxConfig;
|
|
63
|
-
private initPromise;
|
|
64
|
-
private initialized;
|
|
65
|
-
constructor(opts?: SandboxedLocalComputerOptions);
|
|
66
|
-
private buildRuntimeConfig;
|
|
67
|
-
private ensureInitialized;
|
|
68
|
-
executeCommand(command: string, opts?: ExecOptions): Promise<CommandResult>;
|
|
69
|
-
/**
|
|
70
|
-
* Tear down the sandbox runtime. Call when the agent is done.
|
|
71
|
-
*/
|
|
72
|
-
dispose(): Promise<void>;
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
/**
|
|
76
|
-
* Minimal subset of the dockerode Container interface used by DockerComputer.
|
|
77
|
-
* Avoids a hard import of dockerode at the module level.
|
|
78
|
-
*/
|
|
79
|
-
interface DockerContainer {
|
|
80
|
-
exec(options: Record<string, unknown>): Promise<{
|
|
81
|
-
start(opts?: Record<string, unknown>): Promise<NodeJS.ReadableStream>;
|
|
82
|
-
inspect(): Promise<{
|
|
83
|
-
ExitCode: number;
|
|
84
|
-
}>;
|
|
85
|
-
}>;
|
|
86
|
-
}
|
|
87
|
-
interface DockerComputerOptions {
|
|
88
|
-
/** A dockerode Container instance for the target container. */
|
|
89
|
-
container: DockerContainer;
|
|
90
|
-
/** Default working directory for commands (default: /). */
|
|
91
|
-
defaultCwd?: string;
|
|
92
|
-
/** Default timeout in ms for commands (default: 30000). */
|
|
93
|
-
defaultTimeout?: number;
|
|
94
|
-
}
|
|
95
|
-
/**
|
|
96
|
-
* VirtualComputer backed by command execution inside a Docker container.
|
|
31
|
+
* AI-generated session title helper.
|
|
97
32
|
*
|
|
98
|
-
*
|
|
99
|
-
*
|
|
100
|
-
*/
|
|
101
|
-
declare class DockerComputer implements VirtualComputer {
|
|
102
|
-
private container;
|
|
103
|
-
private defaultCwd;
|
|
104
|
-
private defaultTimeout;
|
|
105
|
-
constructor(opts: DockerComputerOptions);
|
|
106
|
-
executeCommand(command: string, opts?: ExecOptions): Promise<CommandResult>;
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
/**
|
|
110
|
-
* Minimal subset of the E2B Sandbox interface used by E2BComputer and E2BFs.
|
|
111
|
-
* Avoids a hard import of `e2b` at the module level.
|
|
112
|
-
*/
|
|
113
|
-
interface E2BSandboxInstance {
|
|
114
|
-
commands: {
|
|
115
|
-
run(cmd: string, opts?: {
|
|
116
|
-
cwd?: string;
|
|
117
|
-
timeout?: number;
|
|
118
|
-
envs?: Record<string, string>;
|
|
119
|
-
}): Promise<{
|
|
120
|
-
exitCode: number;
|
|
121
|
-
stdout: string;
|
|
122
|
-
stderr: string;
|
|
123
|
-
}>;
|
|
124
|
-
};
|
|
125
|
-
files: {
|
|
126
|
-
read(path: string, opts?: {
|
|
127
|
-
format?: string;
|
|
128
|
-
}): Promise<string>;
|
|
129
|
-
write(path: string, data: string): Promise<unknown>;
|
|
130
|
-
remove(path: string): Promise<void>;
|
|
131
|
-
makeDir(path: string): Promise<unknown>;
|
|
132
|
-
list(path: string): Promise<Array<{
|
|
133
|
-
name: string;
|
|
134
|
-
path: string;
|
|
135
|
-
type?: string;
|
|
136
|
-
size?: number;
|
|
137
|
-
modifiedTime?: Date;
|
|
138
|
-
}>>;
|
|
139
|
-
exists(path: string): Promise<boolean>;
|
|
140
|
-
getInfo(path: string): Promise<{
|
|
141
|
-
name: string;
|
|
142
|
-
path: string;
|
|
143
|
-
type?: string;
|
|
144
|
-
size?: number;
|
|
145
|
-
modifiedTime?: Date;
|
|
146
|
-
}>;
|
|
147
|
-
};
|
|
148
|
-
}
|
|
149
|
-
interface E2BComputerOptions {
|
|
150
|
-
/** An E2B Sandbox instance created via `Sandbox.create()`. */
|
|
151
|
-
sandbox: E2BSandboxInstance;
|
|
152
|
-
/** Default working directory for commands. */
|
|
153
|
-
defaultCwd?: string;
|
|
154
|
-
/** Default timeout in ms for commands (default: 30000). */
|
|
155
|
-
defaultTimeout?: number;
|
|
156
|
-
}
|
|
157
|
-
/**
|
|
158
|
-
* VirtualComputer backed by command execution in an E2B cloud sandbox.
|
|
33
|
+
* Given a short prompt sourced from recent messages, ask a provider to
|
|
34
|
+
* produce a 3–7 word sentence-case title suitable for a session list.
|
|
159
35
|
*
|
|
160
|
-
*
|
|
161
|
-
*
|
|
36
|
+
* This is a pure helper: it never touches the filesystem and never knows
|
|
37
|
+
* about `SessionStorage`. Callers (e.g. `Agent.autoTitleIfMissing`) own
|
|
38
|
+
* persistence and event emission.
|
|
162
39
|
*/
|
|
163
|
-
declare class E2BComputer implements VirtualComputer {
|
|
164
|
-
private sandbox;
|
|
165
|
-
private defaultCwd;
|
|
166
|
-
private defaultTimeout;
|
|
167
|
-
constructor(opts: E2BComputerOptions);
|
|
168
|
-
executeCommand(command: string, opts?: ExecOptions): Promise<CommandResult>;
|
|
169
|
-
}
|
|
170
40
|
|
|
171
41
|
/**
|
|
172
|
-
*
|
|
173
|
-
* FreestyleFs. Avoids a hard import of `freestyle-sandboxes` at the module
|
|
174
|
-
* level — the real SDK is only loaded dynamically during `FreestyleSandbox`
|
|
175
|
-
* auto-creation.
|
|
176
|
-
*/
|
|
177
|
-
interface FreestyleVmInstance {
|
|
178
|
-
exec(command: string, opts?: {
|
|
179
|
-
cwd?: string;
|
|
180
|
-
timeout?: number;
|
|
181
|
-
}): Promise<{
|
|
182
|
-
stdout: string | null;
|
|
183
|
-
stderr: string | null;
|
|
184
|
-
statusCode: number | null;
|
|
185
|
-
}>;
|
|
186
|
-
fs: {
|
|
187
|
-
readTextFile(path: string): Promise<string>;
|
|
188
|
-
writeTextFile(path: string, content: string): Promise<void>;
|
|
189
|
-
readDir(path: string): Promise<Array<{
|
|
190
|
-
name: string;
|
|
191
|
-
kind: string;
|
|
192
|
-
}>>;
|
|
193
|
-
};
|
|
194
|
-
suspend(): Promise<unknown>;
|
|
195
|
-
start(): Promise<unknown>;
|
|
196
|
-
}
|
|
197
|
-
interface FreestyleComputerOptions {
|
|
198
|
-
/** A Freestyle VM instance. */
|
|
199
|
-
vm: FreestyleVmInstance;
|
|
200
|
-
/** Default working directory for commands. */
|
|
201
|
-
defaultCwd?: string;
|
|
202
|
-
/** Default timeout in ms for commands (default: 30000). */
|
|
203
|
-
defaultTimeout?: number;
|
|
204
|
-
}
|
|
205
|
-
/**
|
|
206
|
-
* VirtualComputer backed by command execution in a Freestyle VM.
|
|
42
|
+
* Config for the Agent's opt-in auto-title feature.
|
|
207
43
|
*
|
|
208
|
-
*
|
|
209
|
-
*
|
|
44
|
+
* Pass `true` for defaults (use the Agent's own provider + its
|
|
45
|
+
* `defaultModel`). Pass an object to customise the provider, model,
|
|
46
|
+
* system prompt, or input cap.
|
|
210
47
|
*/
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
private defaultTimeout;
|
|
215
|
-
constructor(opts: FreestyleComputerOptions);
|
|
216
|
-
executeCommand(command: string, opts?: ExecOptions): Promise<CommandResult>;
|
|
217
|
-
}
|
|
218
|
-
|
|
219
|
-
/**
|
|
220
|
-
* Bundled sandbox: a `VirtualFs` and `VirtualComputer` paired together.
|
|
221
|
-
*
|
|
222
|
-
* Use one of the built-in factories (`LocalSandbox`, `UnsandboxedLocal`,
|
|
223
|
-
* `SpritesSandbox`) or supply any object that satisfies this shape for
|
|
224
|
-
* custom sandboxes (Docker, E2B, Daytona, in-memory, etc.).
|
|
225
|
-
*/
|
|
226
|
-
interface Sandbox {
|
|
227
|
-
fs: VirtualFs;
|
|
228
|
-
computer: VirtualComputer;
|
|
229
|
-
/** Optional cleanup — called by Agent.close() to tear down OS-level sandbox state. */
|
|
230
|
-
dispose?(): Promise<void>;
|
|
48
|
+
interface AutoTitleConfig {
|
|
49
|
+
/** Master switch. Default false on `AgentOptions.autoTitle`. */
|
|
50
|
+
enabled?: boolean;
|
|
231
51
|
/**
|
|
232
|
-
*
|
|
233
|
-
*
|
|
234
|
-
*
|
|
235
|
-
* When `sandboxId` is provided the sandbox reconnects to an existing
|
|
236
|
-
* resource instead of creating a new one. This is used during session
|
|
237
|
-
* resume: the stored sandbox identifier is read from session metadata
|
|
238
|
-
* and passed here so the agent reattaches to its previous container.
|
|
239
|
-
*
|
|
240
|
-
* When omitted a fresh resource is provisioned (for factories that
|
|
241
|
-
* support auto-creation) or the call is a no-op (for factories that
|
|
242
|
-
* were given a pre-created resource up front).
|
|
52
|
+
* Override provider used for title generation. Falls back to the
|
|
53
|
+
* Agent's main provider.
|
|
243
54
|
*/
|
|
244
|
-
|
|
55
|
+
provider?: AIProvider;
|
|
245
56
|
/**
|
|
246
|
-
*
|
|
247
|
-
*
|
|
248
|
-
* Returns `undefined` before `init()` has resolved or for sandboxes
|
|
249
|
-
* that don't support reconnection.
|
|
57
|
+
* Override model (e.g. `"claude-haiku-4-5"`). Falls back to the
|
|
58
|
+
* provider's `defaultModel`.
|
|
250
59
|
*/
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
/**
|
|
255
|
-
|
|
256
|
-
/** Default timeout (ms) for shell commands. */
|
|
257
|
-
defaultTimeout?: number;
|
|
60
|
+
model?: string;
|
|
61
|
+
/** Override system prompt. */
|
|
62
|
+
systemPrompt?: string;
|
|
63
|
+
/** Cap on seed-text characters. Defaults to 2 000. */
|
|
64
|
+
maxInputChars?: number;
|
|
258
65
|
}
|
|
66
|
+
/** Default cap on characters fed to the title model. */
|
|
67
|
+
declare const DEFAULT_AUTO_TITLE_MAX_INPUT_CHARS = 2000;
|
|
259
68
|
/**
|
|
260
|
-
*
|
|
261
|
-
*
|
|
262
|
-
*
|
|
263
|
-
* Use this for development or fully-trusted environments where sandboxing
|
|
264
|
-
* overhead is unwanted. For production use, prefer `LocalSandbox()` (which
|
|
265
|
-
* wraps commands with `@anthropic-ai/sandbox-runtime`).
|
|
69
|
+
* System prompt for the auto-title generator. Mirrors the shape used by
|
|
70
|
+
* Claude Code so that output quality is familiar.
|
|
266
71
|
*/
|
|
267
|
-
declare
|
|
268
|
-
interface
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
sandbox?: SandboxConfig;
|
|
72
|
+
declare const DEFAULT_AUTO_TITLE_SYSTEM_PROMPT = "Generate a concise, sentence-case title (3-7 words) that captures the main topic or goal of this coding session. The title should be clear enough that the user recognizes the session in a list. Use sentence case: capitalize only the first word and proper nouns.\n\nReturn JSON with a single \"title\" field.\n\nGood examples:\n{\"title\": \"Fix login button on mobile\"}\n{\"title\": \"Add OAuth authentication\"}\n{\"title\": \"Debug failing CI tests\"}\n{\"title\": \"Refactor API client error handling\"}\n\nBad (too vague): {\"title\": \"Code changes\"}\nBad (too long): {\"title\": \"Investigate and fix the issue where the login button does not respond on mobile devices\"}\nBad (wrong case): {\"title\": \"Fix Login Button On Mobile\"}";
|
|
73
|
+
interface GenerateAutoTitleOptions {
|
|
74
|
+
provider: AIProvider;
|
|
75
|
+
/** Model override. When omitted, uses `provider.defaultModel`. */
|
|
76
|
+
model?: string;
|
|
77
|
+
/** System prompt override. Falls back to the built-in prompt. */
|
|
78
|
+
systemPrompt?: string;
|
|
79
|
+
/** Character cap on the flattened input. Defaults to 2 000. */
|
|
80
|
+
maxInputChars?: number;
|
|
81
|
+
signal?: AbortSignal;
|
|
278
82
|
}
|
|
279
83
|
/**
|
|
280
|
-
*
|
|
281
|
-
*
|
|
282
|
-
*
|
|
283
|
-
*
|
|
284
|
-
*
|
|
285
|
-
* Filesystem operations (`VirtualFs`) use the host `node:fs` — the sandbox
|
|
286
|
-
* boundary is enforced on shell commands (`VirtualComputer`), which is where
|
|
287
|
-
* the agent executes arbitrary code.
|
|
288
|
-
*
|
|
289
|
-
* Requires `@anthropic-ai/sandbox-runtime` as a peer dependency.
|
|
84
|
+
* Flatten recent user + assistant text into a single block of plain text
|
|
85
|
+
* suitable for the title model. Tool results are skipped; image parts
|
|
86
|
+
* are skipped; only the tail of the concatenated text is kept when long
|
|
87
|
+
* so the most recent context wins.
|
|
290
88
|
*/
|
|
291
|
-
declare function
|
|
292
|
-
interface SpritesSandboxOptions {
|
|
293
|
-
/** sprites.dev API token. */
|
|
294
|
-
token: string;
|
|
295
|
-
/**
|
|
296
|
-
* Name of an existing sprite container. When provided the sandbox
|
|
297
|
-
* attaches to this sprite directly — no auto-creation occurs and
|
|
298
|
-
* `dispose()` will **not** delete it (lifecycle is yours to manage).
|
|
299
|
-
*
|
|
300
|
-
* When omitted a new sprite is provisioned on the first `init()` call
|
|
301
|
-
* (via `POST /v1/sprites`). The auto-created sprite is deleted when
|
|
302
|
-
* `dispose()` is called, and its name is available via `sandboxId()`
|
|
303
|
-
* for session persistence.
|
|
304
|
-
*/
|
|
305
|
-
spriteName?: string;
|
|
306
|
-
/** Base URL for sprites API (default: https://api.sprites.dev). */
|
|
307
|
-
baseURL?: string;
|
|
308
|
-
/** Working directory inside the sprite (default: /home/sprite). */
|
|
309
|
-
workingDir?: string;
|
|
310
|
-
/**
|
|
311
|
-
* Optional prefix for auto-generated sprite names (default: "noumen-").
|
|
312
|
-
* Only used when `spriteName` is omitted.
|
|
313
|
-
*/
|
|
314
|
-
namePrefix?: string;
|
|
315
|
-
}
|
|
89
|
+
declare function extractTitleSeedText(messages: ChatMessage[], maxChars?: number): string;
|
|
316
90
|
/**
|
|
317
|
-
*
|
|
318
|
-
* Full isolation — the agent has no access to the host machine.
|
|
319
|
-
*
|
|
320
|
-
* **Auto-creation:** When `spriteName` is omitted the sandbox is created
|
|
321
|
-
* lazily on the first `init()` call via the Sprites REST API. The sprite
|
|
322
|
-
* name is available through `sandboxId()` so callers can persist it in
|
|
323
|
-
* session metadata for reconnection on resume. Pass the stored name back
|
|
324
|
-
* through `init(storedId)` to reattach instead of creating a new sprite.
|
|
325
|
-
*
|
|
326
|
-
* **Explicit ID:** When `spriteName` is provided the sandbox attaches to
|
|
327
|
-
* that sprite immediately on `init()`. `dispose()` is a no-op in this
|
|
328
|
-
* case — the caller owns the sprite's lifecycle.
|
|
91
|
+
* Attempt to pull a title out of a free-form model response.
|
|
329
92
|
*
|
|
330
|
-
*
|
|
331
|
-
*
|
|
332
|
-
*
|
|
333
|
-
*
|
|
93
|
+
* Strategy, cheapest-first:
|
|
94
|
+
* 1. Parse the whole string as JSON; return `.title` if present.
|
|
95
|
+
* 2. Slice out the first `{...}` block and `JSON.parse` that.
|
|
96
|
+
* 3. Fall back to the first bare quoted substring in the response.
|
|
334
97
|
*
|
|
335
|
-
*
|
|
336
|
-
*
|
|
337
|
-
*
|
|
338
|
-
* spriteName: "my-sprite",
|
|
339
|
-
* });
|
|
340
|
-
* ```
|
|
98
|
+
* Going through `JSON.parse` (instead of a bespoke regex-unescape) means
|
|
99
|
+
* `\n`, `\\`, `\uXXXX`, and any other valid JSON string escapes round-trip
|
|
100
|
+
* correctly — the previous regex only handled `\"`.
|
|
341
101
|
*/
|
|
342
|
-
declare function
|
|
343
|
-
interface DockerSandboxOptions {
|
|
344
|
-
/**
|
|
345
|
-
* A pre-existing dockerode Container instance. When provided the sandbox
|
|
346
|
-
* attaches to this container directly — no auto-creation occurs and
|
|
347
|
-
* `dispose()` will **not** stop or remove it.
|
|
348
|
-
*
|
|
349
|
-
* When omitted, a new container is created from `image` on the first
|
|
350
|
-
* `init()` call via a dynamic import of `dockerode`. The auto-created
|
|
351
|
-
* container is stopped and removed when `dispose()` is called.
|
|
352
|
-
*/
|
|
353
|
-
container?: DockerContainer;
|
|
354
|
-
/**
|
|
355
|
-
* Docker image to use for auto-creation (e.g. `"ubuntu:22.04"`).
|
|
356
|
-
* Required when `container` is omitted; ignored when `container` is provided.
|
|
357
|
-
*/
|
|
358
|
-
image?: string;
|
|
359
|
-
/** Command to run in the auto-created container (default: `["sleep", "infinity"]`). */
|
|
360
|
-
cmd?: string[];
|
|
361
|
-
/** Environment variables for the auto-created container. */
|
|
362
|
-
env?: string[];
|
|
363
|
-
/** Extra options passed to dockerode `createContainer`. */
|
|
364
|
-
dockerOptions?: Record<string, unknown>;
|
|
365
|
-
/** Working directory inside the container. */
|
|
366
|
-
cwd?: string;
|
|
367
|
-
/** Default timeout (ms) for shell commands. */
|
|
368
|
-
defaultTimeout?: number;
|
|
369
|
-
}
|
|
370
|
-
/**
|
|
371
|
-
* Create a `Sandbox` backed by a Docker container.
|
|
372
|
-
* Requires `dockerode` as an optional peer dependency.
|
|
373
|
-
*
|
|
374
|
-
* **Auto-creation:** When `container` is omitted and `image` is provided,
|
|
375
|
-
* the container is created and started lazily on the first `init()` call.
|
|
376
|
-
* The container ID is available through `sandboxId()` for session
|
|
377
|
-
* persistence. Pass the stored ID back through `init(storedId)` to
|
|
378
|
-
* reattach to an existing container on resume.
|
|
379
|
-
*
|
|
380
|
-
* **Explicit container:** When `container` is provided, `init()` binds
|
|
381
|
-
* it immediately. `dispose()` is a no-op — the caller owns the
|
|
382
|
-
* container's lifecycle.
|
|
383
|
-
*
|
|
384
|
-
* @example
|
|
385
|
-
* ```ts
|
|
386
|
-
* // Auto-create from image
|
|
387
|
-
* const sandbox = DockerSandbox({ image: "ubuntu:22.04", cwd: "/workspace" });
|
|
388
|
-
*
|
|
389
|
-
* // Explicit container (lifecycle managed externally)
|
|
390
|
-
* const sandbox = DockerSandbox({ container: myDockerodeContainer });
|
|
391
|
-
* ```
|
|
392
|
-
*/
|
|
393
|
-
declare function DockerSandbox(opts: DockerSandboxOptions): Sandbox;
|
|
394
|
-
interface E2BSandboxOptions {
|
|
395
|
-
/**
|
|
396
|
-
* A pre-existing E2B Sandbox instance (e.g. from `Sandbox.create()`).
|
|
397
|
-
* When provided the sandbox attaches to this instance — no auto-creation
|
|
398
|
-
* occurs and `dispose()` will **not** kill it.
|
|
399
|
-
*
|
|
400
|
-
* When omitted, a new E2B sandbox is created on the first `init()` call
|
|
401
|
-
* via a dynamic import of the `e2b` package. The auto-created sandbox
|
|
402
|
-
* is killed when `dispose()` is called.
|
|
403
|
-
*/
|
|
404
|
-
sandbox?: E2BSandboxInstance;
|
|
405
|
-
/**
|
|
406
|
-
* E2B template to use for auto-creation (default: `"base"`).
|
|
407
|
-
* Only used when `sandbox` is omitted.
|
|
408
|
-
*/
|
|
409
|
-
template?: string;
|
|
410
|
-
/**
|
|
411
|
-
* E2B API key. Falls back to the `E2B_API_KEY` environment variable
|
|
412
|
-
* when omitted. Only used during auto-creation.
|
|
413
|
-
*/
|
|
414
|
-
apiKey?: string;
|
|
415
|
-
/** Timeout (ms) for the auto-created E2B sandbox (default: E2B SDK default). */
|
|
416
|
-
timeoutMs?: number;
|
|
417
|
-
/** Working directory inside the sandbox. */
|
|
418
|
-
cwd?: string;
|
|
419
|
-
/** Default timeout (ms) for shell commands. */
|
|
420
|
-
defaultTimeout?: number;
|
|
421
|
-
}
|
|
102
|
+
declare function extractTitleFromResponse(raw: string): string | null;
|
|
422
103
|
/**
|
|
423
|
-
*
|
|
424
|
-
*
|
|
425
|
-
*
|
|
426
|
-
* **Auto-creation:** When `sandbox` is omitted the E2B sandbox is
|
|
427
|
-
* provisioned lazily on the first `init()` call via the E2B SDK.
|
|
428
|
-
* The sandbox ID is available through `sandboxId()` for session
|
|
429
|
-
* persistence. Pass the stored ID back through `init(storedId)` to
|
|
430
|
-
* reconnect to the same sandbox on resume (via `Sandbox.connect()`).
|
|
431
|
-
*
|
|
432
|
-
* **Explicit instance:** When `sandbox` is provided, `init()` binds
|
|
433
|
-
* it immediately. `dispose()` is a no-op — the caller owns the
|
|
434
|
-
* sandbox's lifecycle.
|
|
435
|
-
*
|
|
436
|
-
* @example
|
|
437
|
-
* ```ts
|
|
438
|
-
* // Auto-create — sandbox provisioned on first init()
|
|
439
|
-
* const sandbox = E2BSandbox({ template: "base" });
|
|
440
|
-
*
|
|
441
|
-
* // Explicit — attach to pre-existing instance
|
|
442
|
-
* const sandbox = E2BSandbox({ sandbox: await E2BSdk.Sandbox.create() });
|
|
443
|
-
* ```
|
|
104
|
+
* Drive the provider once to produce a session title. Returns null on
|
|
105
|
+
* empty seed text, empty model output, or provider errors (callers decide
|
|
106
|
+
* whether to retry — this helper never throws).
|
|
444
107
|
*/
|
|
445
|
-
declare function
|
|
446
|
-
interface FreestyleSandboxOptions {
|
|
447
|
-
/**
|
|
448
|
-
* A pre-existing Freestyle VM instance. When provided the sandbox
|
|
449
|
-
* attaches to this VM directly — no auto-creation occurs and
|
|
450
|
-
* `dispose()` will **not** suspend or delete it.
|
|
451
|
-
*
|
|
452
|
-
* When omitted, a new VM is created on the first `init()` call via
|
|
453
|
-
* a dynamic import of the `freestyle-sandboxes` package.
|
|
454
|
-
*/
|
|
455
|
-
vm?: FreestyleVmInstance;
|
|
456
|
-
/**
|
|
457
|
-
* Freestyle API key. Falls back to the `FREESTYLE_API_KEY` environment
|
|
458
|
-
* variable when omitted. Only used during auto-creation.
|
|
459
|
-
*/
|
|
460
|
-
apiKey?: string;
|
|
461
|
-
/** Snapshot ID to create the VM from. Only used during auto-creation. */
|
|
462
|
-
snapshotId?: string;
|
|
463
|
-
/**
|
|
464
|
-
* A `VmSpec` instance or configuration object passed through to
|
|
465
|
-
* `freestyle.vms.create()`. Only used during auto-creation.
|
|
466
|
-
*/
|
|
467
|
-
spec?: unknown;
|
|
468
|
-
/**
|
|
469
|
-
* Idle timeout in seconds for the auto-created VM (default: 600).
|
|
470
|
-
* The VM auto-suspends after this many seconds of network inactivity.
|
|
471
|
-
*/
|
|
472
|
-
idleTimeoutSeconds?: number;
|
|
473
|
-
/** Working directory inside the VM. */
|
|
474
|
-
cwd?: string;
|
|
475
|
-
/** Default timeout (ms) for shell commands. */
|
|
476
|
-
defaultTimeout?: number;
|
|
477
|
-
/** Files to provision at creation time. */
|
|
478
|
-
additionalFiles?: Record<string, {
|
|
479
|
-
content: string;
|
|
480
|
-
encoding?: string;
|
|
481
|
-
}>;
|
|
482
|
-
/** Git repos to clone at creation time. */
|
|
483
|
-
gitRepos?: Array<{
|
|
484
|
-
repo: string;
|
|
485
|
-
path: string;
|
|
486
|
-
rev?: string;
|
|
487
|
-
}>;
|
|
488
|
-
/**
|
|
489
|
-
* What to do with auto-created VMs on `dispose()`:
|
|
490
|
-
* - `"suspend"` (default) — suspends the VM, preserving full memory
|
|
491
|
-
* state for near-instant resume on reconnect.
|
|
492
|
-
* - `"delete"` — permanently deletes the VM and frees all resources.
|
|
493
|
-
*/
|
|
494
|
-
disposeStrategy?: "suspend" | "delete";
|
|
495
|
-
}
|
|
108
|
+
declare function generateAutoTitle(messages: ChatMessage[], opts: GenerateAutoTitleOptions): Promise<string | null>;
|
|
496
109
|
/**
|
|
497
|
-
*
|
|
498
|
-
*
|
|
499
|
-
*
|
|
500
|
-
* **Auto-creation:** When `vm` is omitted a new Freestyle VM is
|
|
501
|
-
* provisioned lazily on the first `init()` call. The VM ID is available
|
|
502
|
-
* through `sandboxId()` for session persistence. Pass the stored ID back
|
|
503
|
-
* through `init(storedId)` to reconnect (this also wakes suspended VMs).
|
|
504
|
-
*
|
|
505
|
-
* By default, auto-created VMs are **suspended** on `dispose()` rather
|
|
506
|
-
* than deleted. This preserves full memory state and allows near-instant
|
|
507
|
-
* resume. Set `disposeStrategy: "delete"` for full cleanup.
|
|
508
|
-
*
|
|
509
|
-
* **Explicit instance:** When `vm` is provided, `init()` binds it
|
|
510
|
-
* immediately. `dispose()` is a no-op — the caller owns the VM's
|
|
511
|
-
* lifecycle.
|
|
512
|
-
*
|
|
513
|
-
* @example
|
|
514
|
-
* ```ts
|
|
515
|
-
* // Auto-create — VM provisioned on first init()
|
|
516
|
-
* const sandbox = FreestyleSandbox({ cwd: "/workspace" });
|
|
517
|
-
*
|
|
518
|
-
* // Auto-create from a snapshot
|
|
519
|
-
* const sandbox = FreestyleSandbox({
|
|
520
|
-
* snapshotId: "abc123",
|
|
521
|
-
* cwd: "/workspace",
|
|
522
|
-
* });
|
|
523
|
-
*
|
|
524
|
-
* // Explicit — attach to pre-existing VM
|
|
525
|
-
* const sandbox = FreestyleSandbox({ vm: existingVm });
|
|
526
|
-
* ```
|
|
110
|
+
* Trim, collapse whitespace, strip wrapping quotes, clamp length.
|
|
111
|
+
* Returns null if the cleaned string would be empty.
|
|
527
112
|
*/
|
|
528
|
-
declare function
|
|
113
|
+
declare function normalizeTitle(raw: string): string | null;
|
|
529
114
|
|
|
530
115
|
interface SkillDefinition {
|
|
531
116
|
name: string;
|
|
@@ -719,13 +304,36 @@ declare class SessionStorage {
|
|
|
719
304
|
appendContentReplacement(sessionId: string, replacements: ContentReplacementRecord$1[]): Promise<void>;
|
|
720
305
|
appendMetadata(sessionId: string, key: string, value: unknown): Promise<void>;
|
|
721
306
|
/**
|
|
722
|
-
*
|
|
723
|
-
*
|
|
307
|
+
* Append a user-set session title. Wins over any `ai-title` when read.
|
|
308
|
+
* Idempotent-ish: callers may append as many as they like; the last one
|
|
309
|
+
* wins according to file order.
|
|
310
|
+
*/
|
|
311
|
+
appendCustomTitle(sessionId: string, title: string): Promise<void>;
|
|
312
|
+
/**
|
|
313
|
+
* Append an AI-generated session title. A `custom-title` (if present)
|
|
314
|
+
* always takes precedence on read.
|
|
315
|
+
*/
|
|
316
|
+
appendAiTitle(sessionId: string, title: string): Promise<void>;
|
|
317
|
+
/**
|
|
318
|
+
* Re-append custom-title, ai-title, and key metadata entries after a
|
|
319
|
+
* compact boundary so they remain discoverable in the active-entries
|
|
320
|
+
* window. Written as a single batched append so a crash mid-write can't
|
|
321
|
+
* leave the transcript with only a subset of the re-emitted entries.
|
|
724
322
|
*/
|
|
725
323
|
reAppendMetadataAfterCompact(sessionId: string): Promise<void>;
|
|
726
324
|
loadMessages(sessionId: string): Promise<ChatMessage[]>;
|
|
727
325
|
loadAllEntries(sessionId: string): Promise<Entry[]>;
|
|
728
326
|
sessionExists(sessionId: string): Promise<boolean>;
|
|
327
|
+
/**
|
|
328
|
+
* Return the currently persisted titles for a session. `title` reflects
|
|
329
|
+
* the display preference (custom > ai). Returns all-undefined if the
|
|
330
|
+
* session file doesn't exist.
|
|
331
|
+
*/
|
|
332
|
+
getSessionTitles(sessionId: string): Promise<{
|
|
333
|
+
title?: string;
|
|
334
|
+
customTitle?: string;
|
|
335
|
+
aiTitle?: string;
|
|
336
|
+
}>;
|
|
729
337
|
deleteSession(sessionId: string): Promise<void>;
|
|
730
338
|
listSessions(): Promise<SessionInfo[]>;
|
|
731
339
|
}
|
|
@@ -1127,10 +735,21 @@ interface AgentOptions {
|
|
|
1127
735
|
cwd?: string;
|
|
1128
736
|
/**
|
|
1129
737
|
* Bundled sandbox providing both filesystem and shell execution.
|
|
1130
|
-
*
|
|
1131
|
-
*
|
|
1132
|
-
*
|
|
1133
|
-
*
|
|
738
|
+
*
|
|
739
|
+
* Local backends live on the root barrel:
|
|
740
|
+
* - `LocalSandbox()` — OS-level sandboxing (requires `@anthropic-ai/sandbox-runtime`).
|
|
741
|
+
* - `UnsandboxedLocal()` — raw host access.
|
|
742
|
+
*
|
|
743
|
+
* Remote backends are subpath imports so their optional peer deps do
|
|
744
|
+
* not enter the module graph unless opted into:
|
|
745
|
+
* - `import { DockerSandbox } from "noumen/docker"`
|
|
746
|
+
* - `import { E2BSandbox } from "noumen/e2b"`
|
|
747
|
+
* - `import { FreestyleSandbox } from "noumen/freestyle"`
|
|
748
|
+
* - `import { SshSandbox } from "noumen/ssh"`
|
|
749
|
+
* - `import { SpritesSandbox } from "noumen/sprites"`
|
|
750
|
+
*
|
|
751
|
+
* You can also pass any `{ fs: VirtualFs; computer: VirtualComputer }`
|
|
752
|
+
* for custom sandboxes.
|
|
1134
753
|
*
|
|
1135
754
|
* Defaults to `UnsandboxedLocal({ cwd })` when omitted — the library
|
|
1136
755
|
* default is non-sandboxed for backward compatibility. The CLI defaults
|
|
@@ -1193,6 +812,17 @@ interface AgentOptions {
|
|
|
1193
812
|
outputFormat?: OutputFormat;
|
|
1194
813
|
/** Default structured output mode for all threads. */
|
|
1195
814
|
structuredOutputMode?: "alongside_tools" | "final_response";
|
|
815
|
+
/**
|
|
816
|
+
* Opt-in AI-generated session titles. When enabled, callers can invoke
|
|
817
|
+
* `agent.autoTitleIfMissing(sessionId)` (typically once per session,
|
|
818
|
+
* e.g. after the first assistant turn) to produce a short title and
|
|
819
|
+
* persist it as an `ai-title` JSONL entry. User-set `custom-title`
|
|
820
|
+
* entries (see `agent.setCustomTitle`) always take precedence on read.
|
|
821
|
+
*
|
|
822
|
+
* Pass `true` for defaults (same provider as the Agent, provider's
|
|
823
|
+
* default model, built-in prompt) or an object to customise.
|
|
824
|
+
*/
|
|
825
|
+
autoTitle?: AutoTitleConfig | boolean;
|
|
1196
826
|
};
|
|
1197
827
|
}
|
|
1198
828
|
interface RunCallbacks {
|
|
@@ -1266,6 +896,14 @@ declare class Agent {
|
|
|
1266
896
|
private historySnipConfig;
|
|
1267
897
|
private outputFormat;
|
|
1268
898
|
private structuredOutputMode;
|
|
899
|
+
private autoTitleConfig;
|
|
900
|
+
/**
|
|
901
|
+
* Keyed by `${sessionId}:${force ? "force" : "normal"}`. Parallel calls
|
|
902
|
+
* that pass the same `force` mode coalesce to one in-flight request; a
|
|
903
|
+
* `force: true` call arriving during a normal in-flight request runs its
|
|
904
|
+
* own pass so the caller's intent isn't silently dropped.
|
|
905
|
+
*/
|
|
906
|
+
private autoTitleInFlight;
|
|
1269
907
|
private providerPromise;
|
|
1270
908
|
private initPromise;
|
|
1271
909
|
constructor(opts: AgentOptions);
|
|
@@ -1276,6 +914,52 @@ declare class Agent {
|
|
|
1276
914
|
private createSpawnSubagent;
|
|
1277
915
|
createThread(opts?: ThreadOptions): Promise<Thread>;
|
|
1278
916
|
listSessions(): Promise<SessionInfo[]>;
|
|
917
|
+
/**
|
|
918
|
+
* Load the message history for a stored session, respecting compact
|
|
919
|
+
* boundaries and history snips. Returns `[]` when the session does
|
|
920
|
+
* not exist. Use this to rehydrate a UI — resuming a Thread for
|
|
921
|
+
* further execution should go through `resumeThread()` instead.
|
|
922
|
+
*/
|
|
923
|
+
getMessages(sessionId: string): Promise<ChatMessage[]>;
|
|
924
|
+
/**
|
|
925
|
+
* Persist a user-set title for a session. Takes precedence over any
|
|
926
|
+
* AI-generated title on read. No-op on empty / whitespace-only input.
|
|
927
|
+
*/
|
|
928
|
+
setCustomTitle(sessionId: string, title: string): Promise<void>;
|
|
929
|
+
/**
|
|
930
|
+
* Persist an AI-generated title for a session. A user-set title
|
|
931
|
+
* (see `setCustomTitle`) always wins on read, so writing this after a
|
|
932
|
+
* user has renamed the session is harmless.
|
|
933
|
+
*/
|
|
934
|
+
setAiTitle(sessionId: string, title: string): Promise<void>;
|
|
935
|
+
/**
|
|
936
|
+
* Delete a session's persisted transcript. Does not affect any
|
|
937
|
+
* currently-running `Thread` reading from the same session id.
|
|
938
|
+
*/
|
|
939
|
+
deleteSession(sessionId: string): Promise<void>;
|
|
940
|
+
/**
|
|
941
|
+
* Return the currently persisted titles for a session.
|
|
942
|
+
* `title` reflects the display preference (custom > ai).
|
|
943
|
+
*/
|
|
944
|
+
getSessionTitles(sessionId: string): Promise<{
|
|
945
|
+
title?: string;
|
|
946
|
+
customTitle?: string;
|
|
947
|
+
aiTitle?: string;
|
|
948
|
+
}>;
|
|
949
|
+
/**
|
|
950
|
+
* When `autoTitle` is enabled and the session has no title yet,
|
|
951
|
+
* generate one via the configured provider + model and persist it
|
|
952
|
+
* as an `ai-title` entry. Returns the new title on success, or `null`
|
|
953
|
+
* when skipped (feature disabled, title already present, empty seed,
|
|
954
|
+
* or provider error).
|
|
955
|
+
*
|
|
956
|
+
* Concurrency-safe: parallel calls for the same session coalesce to
|
|
957
|
+
* a single in-flight request.
|
|
958
|
+
*/
|
|
959
|
+
autoTitleIfMissing(sessionId: string, opts?: {
|
|
960
|
+
signal?: AbortSignal;
|
|
961
|
+
force?: boolean;
|
|
962
|
+
}): Promise<string | null>;
|
|
1279
963
|
getCostSummary(): CostSummary | null;
|
|
1280
964
|
/**
|
|
1281
965
|
* Create a thread that resumes an existing session. Automatically restores
|
|
@@ -1329,4 +1013,4 @@ declare class Agent {
|
|
|
1329
1013
|
close(): Promise<void>;
|
|
1330
1014
|
}
|
|
1331
1015
|
|
|
1332
|
-
export { type
|
|
1016
|
+
export { type WebSearchResult as $, Agent as A, type BudgetState as B, type ContextFile as C, DEFAULT_AUTO_TITLE_MAX_INPUT_CHARS as D, type ReactiveCompactResult as E, type ResolveProviderOptions as F, type GenerateAutoTitleOptions as G, type RetryEvent as H, type RunCallbacks as I, type RunResult as J, SUPPORTED_PROVIDERS as K, type SnipConfig as L, type MicrocompactConfig as M, type SnipResult as N, Thread as O, type ProjectContextConfig as P, type ThreadOptions as Q, type RetryConfig as R, type SkillDefinition as S, type ThreadConfig as T, type ToolResultBudgetConfig as U, type ToolResultBudgetResult as V, type ContentReplacementRecord as W, type ToolResultSpillResult as X, type ToolResultStorageConfig as Y, type TracingConfig as Z, type WebSearchConfig as _, type AutoTitleConfig as a, applyPersistedReplacements as a0, applySnipRemovals as a1, canAutoCompact as a2, createAutoCompactConfig as a3, createAutoCompactTracking as a4, createBudgetState as a5, createContentReplacementState as a6, createWebSearchTool as a7, detectProvider as a8, enforceToolResultBudget as a9, enforceToolResultStorageBudget as aa, extractTitleFromResponse as ab, extractTitleSeedText as ac, generateAutoTitle as ad, microcompactMessages as ae, normalizeTitle as af, persistToolResult as ag, projectSnippedView as ah, reconstructContentReplacementState as ai, recordAutoCompactFailure as aj, recordAutoCompactSuccess as ak, resolveProvider as al, shouldAutoCompact as am, snipMessagesByUuids as an, tryReactiveCompact as ao, webSearchToolPlaceholder as ap, SessionStorage as b, type ContextScope as c, type RetryContext as d, type RetryEngineOptions as e, type Span as f, type SpanAttributeValue as g, SpanStatusCode as h, type Tracer as i, type SpanOptions as j, type StoredCostState as k, type AgentOptions as l, type AutoCompactConfig as m, type AutoCompactTrackingState as n, CLEARED_PLACEHOLDER as o, COMPACTABLE_TOOLS as p, type ContentReplacementState as q, CostTracker as r, DEFAULT_AUTO_TITLE_SYSTEM_PROMPT as s, DEFAULT_MODELS as t, DEFAULT_RETRY_CONFIG as u, type DiagnoseCheckResult as v, type DiagnoseResult as w, type MicrocompactResult as x, type ProviderName as y, type ReactiveCompactConfig as z };
|