@vellumai/plugin-api 0.10.11-dev.202607241836.91be689 → 0.10.11-dev.202607241933.decb522
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/index.d.ts +1424 -2006
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -1,82 +1,6 @@
|
|
|
1
1
|
/// <reference path="./app.d.ts" />
|
|
2
2
|
import { z } from 'zod';
|
|
3
3
|
|
|
4
|
-
declare type _AcpServerMessages = AcpSessionSpawnedEvent | AcpSessionUpdateEvent | AcpSessionCompletedEvent | AcpSessionErrorEvent | AcpSessionUsageEvent;
|
|
5
|
-
|
|
6
|
-
declare type AcpSessionCompletedEvent = z.infer<typeof AcpSessionCompletedEventSchema>;
|
|
7
|
-
|
|
8
|
-
declare const AcpSessionCompletedEventSchema: z.ZodObject<{
|
|
9
|
-
type: z.ZodLiteral<"acp_session_completed">;
|
|
10
|
-
acpSessionId: z.ZodString;
|
|
11
|
-
stopReason: z.ZodEnum<{
|
|
12
|
-
cancelled: "cancelled";
|
|
13
|
-
end_turn: "end_turn";
|
|
14
|
-
max_tokens: "max_tokens";
|
|
15
|
-
max_turn_requests: "max_turn_requests";
|
|
16
|
-
refusal: "refusal";
|
|
17
|
-
}>;
|
|
18
|
-
}, z.core.$strict>;
|
|
19
|
-
|
|
20
|
-
declare type AcpSessionErrorEvent = z.infer<typeof AcpSessionErrorEventSchema>;
|
|
21
|
-
|
|
22
|
-
declare const AcpSessionErrorEventSchema: z.ZodObject<{
|
|
23
|
-
type: z.ZodLiteral<"acp_session_error">;
|
|
24
|
-
acpSessionId: z.ZodString;
|
|
25
|
-
error: z.ZodString;
|
|
26
|
-
}, z.core.$strict>;
|
|
27
|
-
|
|
28
|
-
declare type AcpSessionSpawnedEvent = z.infer<typeof AcpSessionSpawnedEventSchema>;
|
|
29
|
-
|
|
30
|
-
declare const AcpSessionSpawnedEventSchema: z.ZodObject<{
|
|
31
|
-
type: z.ZodLiteral<"acp_session_spawned">;
|
|
32
|
-
acpSessionId: z.ZodString;
|
|
33
|
-
agent: z.ZodString;
|
|
34
|
-
parentConversationId: z.ZodString;
|
|
35
|
-
parentToolUseId: z.ZodOptional<z.ZodString>;
|
|
36
|
-
task: z.ZodOptional<z.ZodString>;
|
|
37
|
-
}, z.core.$strict>;
|
|
38
|
-
|
|
39
|
-
declare type AcpSessionUpdateEvent = z.infer<typeof AcpSessionUpdateEventSchema>;
|
|
40
|
-
|
|
41
|
-
declare const AcpSessionUpdateEventSchema: z.ZodObject<{
|
|
42
|
-
type: z.ZodLiteral<"acp_session_update">;
|
|
43
|
-
acpSessionId: z.ZodString;
|
|
44
|
-
updateType: z.ZodEnum<{
|
|
45
|
-
agent_message_chunk: "agent_message_chunk";
|
|
46
|
-
agent_thought_chunk: "agent_thought_chunk";
|
|
47
|
-
user_message_chunk: "user_message_chunk";
|
|
48
|
-
tool_call: "tool_call";
|
|
49
|
-
tool_call_update: "tool_call_update";
|
|
50
|
-
plan: "plan";
|
|
51
|
-
}>;
|
|
52
|
-
content: z.ZodOptional<z.ZodString>;
|
|
53
|
-
toolCallId: z.ZodOptional<z.ZodString>;
|
|
54
|
-
toolTitle: z.ZodOptional<z.ZodString>;
|
|
55
|
-
toolKind: z.ZodOptional<z.ZodString>;
|
|
56
|
-
toolStatus: z.ZodOptional<z.ZodString>;
|
|
57
|
-
rawInput: z.ZodOptional<z.ZodUnknown>;
|
|
58
|
-
rawOutput: z.ZodOptional<z.ZodUnknown>;
|
|
59
|
-
locations: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
60
|
-
path: z.ZodString;
|
|
61
|
-
line: z.ZodOptional<z.ZodNumber>;
|
|
62
|
-
}, z.core.$strip>>>;
|
|
63
|
-
messageId: z.ZodOptional<z.ZodString>;
|
|
64
|
-
seq: z.ZodOptional<z.ZodNumber>;
|
|
65
|
-
}, z.core.$strict>;
|
|
66
|
-
|
|
67
|
-
declare type AcpSessionUsageEvent = z.infer<typeof AcpSessionUsageEventSchema>;
|
|
68
|
-
|
|
69
|
-
declare const AcpSessionUsageEventSchema: z.ZodObject<{
|
|
70
|
-
type: z.ZodLiteral<"acp_session_usage">;
|
|
71
|
-
acpSessionId: z.ZodString;
|
|
72
|
-
usedTokens: z.ZodNumber;
|
|
73
|
-
contextSize: z.ZodNumber;
|
|
74
|
-
inputTokens: z.ZodOptional<z.ZodNumber>;
|
|
75
|
-
outputTokens: z.ZodOptional<z.ZodNumber>;
|
|
76
|
-
costAmount: z.ZodOptional<z.ZodNumber>;
|
|
77
|
-
costCurrency: z.ZodOptional<z.ZodString>;
|
|
78
|
-
}, z.core.$strict>;
|
|
79
|
-
|
|
80
4
|
/**
|
|
81
5
|
* Append a message to a conversation. This is the low-level insert: it
|
|
82
6
|
* persists and indexes the row only — it does not project the message into
|
|
@@ -152,15 +76,6 @@ export declare type AgentLoopExitReason =
|
|
|
152
76
|
/** An unhandled error ended the turn. */
|
|
153
77
|
| "error";
|
|
154
78
|
|
|
155
|
-
declare type AppFilesChangedEvent = z.infer<typeof AppFilesChangedEventSchema>;
|
|
156
|
-
|
|
157
|
-
declare const AppFilesChangedEventSchema: z.ZodObject<{
|
|
158
|
-
type: z.ZodLiteral<"app_files_changed">;
|
|
159
|
-
appId: z.ZodString;
|
|
160
|
-
}, z.core.$strip>;
|
|
161
|
-
|
|
162
|
-
declare type _AppsServerMessages = AppFilesChangedEvent;
|
|
163
|
-
|
|
164
79
|
/**
|
|
165
80
|
* How {@link listConversations} (and friends) treats archived rows.
|
|
166
81
|
*
|
|
@@ -174,42 +89,6 @@ declare type _AppsServerMessages = AppFilesChangedEvent;
|
|
|
174
89
|
*/
|
|
175
90
|
declare type ArchiveStatusFilter = "active" | "archived" | "all";
|
|
176
91
|
|
|
177
|
-
declare type AssistantActivityStateEvent = z.infer<typeof AssistantActivityStateEventSchema>;
|
|
178
|
-
|
|
179
|
-
declare const AssistantActivityStateEventSchema: z.ZodObject<{
|
|
180
|
-
type: z.ZodLiteral<"assistant_activity_state">;
|
|
181
|
-
conversationId: z.ZodString;
|
|
182
|
-
activityVersion: z.ZodNumber;
|
|
183
|
-
phase: z.ZodEnum<{
|
|
184
|
-
thinking: "thinking";
|
|
185
|
-
idle: "idle";
|
|
186
|
-
streaming: "streaming";
|
|
187
|
-
tool_running: "tool_running";
|
|
188
|
-
awaiting_confirmation: "awaiting_confirmation";
|
|
189
|
-
}>;
|
|
190
|
-
anchor: z.ZodEnum<{
|
|
191
|
-
assistant_turn: "assistant_turn";
|
|
192
|
-
user_turn: "user_turn";
|
|
193
|
-
global: "global";
|
|
194
|
-
}>;
|
|
195
|
-
reason: z.ZodEnum<{
|
|
196
|
-
thinking_delta: "thinking_delta";
|
|
197
|
-
generation_cancelled: "generation_cancelled";
|
|
198
|
-
message_dequeued: "message_dequeued";
|
|
199
|
-
first_text_delta: "first_text_delta";
|
|
200
|
-
tool_use_start: "tool_use_start";
|
|
201
|
-
preview_start: "preview_start";
|
|
202
|
-
tool_result_received: "tool_result_received";
|
|
203
|
-
confirmation_requested: "confirmation_requested";
|
|
204
|
-
confirmation_resolved: "confirmation_resolved";
|
|
205
|
-
context_compacting: "context_compacting";
|
|
206
|
-
message_complete: "message_complete";
|
|
207
|
-
error_terminal: "error_terminal";
|
|
208
|
-
}>;
|
|
209
|
-
requestId: z.ZodOptional<z.ZodString>;
|
|
210
|
-
statusText: z.ZodOptional<z.ZodString>;
|
|
211
|
-
}, z.core.$strip>;
|
|
212
|
-
|
|
213
92
|
declare type AssistantConfig = z.infer<typeof AssistantConfigSchema>;
|
|
214
93
|
|
|
215
94
|
declare const AssistantConfigSchema: z.ZodObject<{
|
|
@@ -1252,314 +1131,1424 @@ declare const AssistantConfigSchema: z.ZodObject<{
|
|
|
1252
1131
|
maxStepsPerSession: z.ZodDefault<z.ZodNumber>;
|
|
1253
1132
|
}, z.core.$strip>;
|
|
1254
1133
|
|
|
1255
|
-
/** Daemon-side specialization of the generic event envelope. */
|
|
1256
|
-
export declare type AssistantEvent = BaseAssistantEvent<ServerMessage>;
|
|
1257
|
-
|
|
1258
|
-
export declare type AssistantEventCallback = (event: AssistantEvent) => void | Promise<void>;
|
|
1259
|
-
|
|
1260
|
-
/** Filter that determines which events a subscriber receives. */
|
|
1261
|
-
export declare type AssistantEventFilter = {
|
|
1262
|
-
/** When set, restrict delivery to events for this conversation. */
|
|
1263
|
-
conversationId?: string;
|
|
1264
|
-
};
|
|
1265
|
-
|
|
1266
1134
|
/**
|
|
1267
|
-
*
|
|
1268
|
-
*
|
|
1269
|
-
* Filtering is applied at subscription level:
|
|
1270
|
-
* - `conversationId`: scoped events match subscribers with same conversationId
|
|
1271
|
-
* or no conversationId filter (broadcast to all).
|
|
1272
|
-
* - `targetCapability` (on publish): targeted events only reach subscribers
|
|
1273
|
-
* whose capabilities include the target. Untargeted events fan out to all.
|
|
1274
|
-
*
|
|
1275
|
-
* Client connections register as subscribers with metadata and are queryable
|
|
1276
|
-
* via `listClients()`, `getMostRecentClientByCapability()`, etc.
|
|
1135
|
+
* Daemon-side event envelope: the canonical `AssistantEventEnvelope` wrapping
|
|
1136
|
+
* an `AssistantEvent` message payload.
|
|
1277
1137
|
*/
|
|
1278
|
-
export declare
|
|
1279
|
-
private readonly subscribers;
|
|
1280
|
-
private readonly maxSubscribers;
|
|
1281
|
-
/** Monotonic source for per-connection ids, scoped to this hub. */
|
|
1282
|
-
private connectionCounter;
|
|
1283
|
-
constructor(options?: {
|
|
1284
|
-
maxSubscribers?: number;
|
|
1285
|
-
});
|
|
1286
|
-
/**
|
|
1287
|
-
* Register a subscriber that will be called for each matching event.
|
|
1288
|
-
*
|
|
1289
|
-
* **Client deduplication:** When a client subscriber is registered with a
|
|
1290
|
-
* `clientId` that already exists, all stale entries for that clientId are
|
|
1291
|
-
* disposed first. This prevents subscriber stacking when clients reconnect
|
|
1292
|
-
* (e.g. Chrome extension reload, SSE token refresh) before the old
|
|
1293
|
-
* connection's abort signal fires.
|
|
1294
|
-
*
|
|
1295
|
-
* When the subscriber cap (`maxSubscribers`) has been reached, the **oldest**
|
|
1296
|
-
* subscriber is evicted to make room: its `onEvict` callback is invoked (so
|
|
1297
|
-
* it can close its SSE stream) and its entry is removed from the hub.
|
|
1298
|
-
*/
|
|
1299
|
-
subscribe(subscriber: SubscriberInput): AssistantEventSubscription;
|
|
1300
|
-
/**
|
|
1301
|
-
* Publish an event to all matching subscribers.
|
|
1302
|
-
*
|
|
1303
|
-
* Matching rules:
|
|
1304
|
-
* - if `excludeClientId` is set, the subscriber with that clientId is
|
|
1305
|
-
* skipped regardless of every other rule (self-echo suppression — the
|
|
1306
|
-
* client that originated the mutation does not receive its own
|
|
1307
|
-
* invalidation back through the hub).
|
|
1308
|
-
* - if `targetClientId` is set, deliver only to the subscriber with that
|
|
1309
|
-
* clientId, bypassing the conversation-id filter entirely (the web-origin
|
|
1310
|
-
* event's conversationId differs from the macOS client's subscribed
|
|
1311
|
-
* conversation).
|
|
1312
|
-
* - if `filter.conversationId` is set (and `targetClientId` is not), the
|
|
1313
|
-
* `event.conversationId` must equal it
|
|
1314
|
-
* - if `targetCapability` is set, only subscribers whose capabilities include
|
|
1315
|
-
* it receive the event; untargeted events go to all
|
|
1316
|
-
* - if `targetInterfaceId` is set, only client subscribers whose
|
|
1317
|
-
* `interfaceId` matches receive the event; process subscribers and
|
|
1318
|
-
* non-matching clients are skipped. Used to narrow legacy
|
|
1319
|
-
* broadcasts (e.g. `conversation_list_invalidated`) to a specific
|
|
1320
|
-
* client surface during a migration window.
|
|
1321
|
-
*
|
|
1322
|
-
* Fanout is isolated: a throwing or rejecting subscriber does not abort
|
|
1323
|
-
* delivery to remaining subscribers.
|
|
1324
|
-
*/
|
|
1325
|
-
publish(event: AssistantEvent, options?: {
|
|
1326
|
-
targetCapability?: HostProxyCapability;
|
|
1327
|
-
targetClientId?: string;
|
|
1328
|
-
targetInterfaceId?: InterfaceId;
|
|
1329
|
-
/**
|
|
1330
|
-
* Skip the subscriber with this `clientId`. Used for self-echo
|
|
1331
|
-
* suppression on `sync_changed`: the route handler echoes the
|
|
1332
|
-
* originating tab's `X-Vellum-Client-Id` back on the event, and the
|
|
1333
|
-
* hub uses it here to avoid re-delivering the invalidation to the
|
|
1334
|
-
* tab that already mutated its own optimistic state.
|
|
1335
|
-
*/
|
|
1336
|
-
excludeClientId?: string;
|
|
1337
|
-
}): Promise<void>;
|
|
1338
|
-
/**
|
|
1339
|
-
* Return the active client subscriber with the given clientId, or
|
|
1340
|
-
* `undefined` if no such subscriber exists.
|
|
1341
|
-
*/
|
|
1342
|
-
getClientById(clientId: string): ClientEntry | undefined;
|
|
1343
|
-
/**
|
|
1344
|
-
* Return the verified actor principal id captured at SSE subscription time
|
|
1345
|
-
* for the given client, or `undefined` if the client is unknown or
|
|
1346
|
-
* connected without a principal (e.g. legacy/service tokens).
|
|
1347
|
-
*
|
|
1348
|
-
* Used by host proxies to bind cross-client targeted execution to the same
|
|
1349
|
-
* authenticated user identity that opened the target client's SSE stream.
|
|
1350
|
-
*/
|
|
1351
|
-
getActorPrincipalIdForClient(clientId: string): string | undefined;
|
|
1352
|
-
/**
|
|
1353
|
-
* Returns true when at least one active subscriber would receive the given
|
|
1354
|
-
* event based on the same conversation matching rules as publish().
|
|
1355
|
-
*/
|
|
1356
|
-
hasSubscribersForEvent(event: Pick<AssistantEvent, "conversationId">): boolean;
|
|
1357
|
-
private clientEntries;
|
|
1358
|
-
/**
|
|
1359
|
-
* Return all active client subscribers, sorted by `lastActiveAt` descending.
|
|
1360
|
-
*/
|
|
1361
|
-
listClients(): ClientEntry[];
|
|
1362
|
-
/**
|
|
1363
|
-
* Return all client subscribers that support the given capability,
|
|
1364
|
-
* sorted by `lastActiveAt` descending.
|
|
1365
|
-
*/
|
|
1366
|
-
listClientsByCapability(capability: HostProxyCapability): ClientEntry[];
|
|
1367
|
-
/**
|
|
1368
|
-
* Return the most recently active client that supports the given
|
|
1369
|
-
* capability, or `undefined` if none exists.
|
|
1370
|
-
*/
|
|
1371
|
-
getMostRecentClientByCapability(capability: HostProxyCapability): ClientEntry | undefined;
|
|
1372
|
-
/**
|
|
1373
|
-
* Return all client subscribers with the given interface type,
|
|
1374
|
-
* sorted by `lastActiveAt` descending.
|
|
1375
|
-
*/
|
|
1376
|
-
listClientsByInterface(interfaceId: InterfaceId): ClientEntry[];
|
|
1377
|
-
/**
|
|
1378
|
-
* Touch a client subscriber — update `lastActiveAt`. Used by heartbeat.
|
|
1379
|
-
*/
|
|
1380
|
-
touchClient(clientId: string): void;
|
|
1381
|
-
/**
|
|
1382
|
-
* Force-disconnect a client by disposing all subscribers for the given
|
|
1383
|
-
* `clientId`. Returns the number of disposed entries.
|
|
1384
|
-
*
|
|
1385
|
-
* Used by `assistant clients disconnect <clientId>` to forcibly remove
|
|
1386
|
-
* stale or unwanted client connections.
|
|
1387
|
-
*/
|
|
1388
|
-
disposeClient(clientId: string): number;
|
|
1389
|
-
/** Number of currently active subscribers (useful for tests and caps). */
|
|
1390
|
-
subscriberCount(): number;
|
|
1391
|
-
/** Returns true if the hub can accept a subscriber without evicting anyone. */
|
|
1392
|
-
hasCapacity(): boolean;
|
|
1393
|
-
}
|
|
1394
|
-
|
|
1395
|
-
/** The plugin-facing event hub. See module docs. */
|
|
1396
|
-
export declare const assistantEventHub: PluginEventHub;
|
|
1397
|
-
|
|
1398
|
-
/** Opaque handle returned by `subscribe`. Call `dispose()` to remove the subscription. */
|
|
1399
|
-
export declare interface AssistantEventSubscription {
|
|
1400
|
-
dispose(): void;
|
|
1401
|
-
/** True until `dispose()` has been called. */
|
|
1402
|
-
readonly active: boolean;
|
|
1403
|
-
/**
|
|
1404
|
-
* Per-connection identifier, unique within the hub instance. Distinguishes
|
|
1405
|
-
* connections that share a `clientId` (e.g. an old connection and the new
|
|
1406
|
-
* one that replaced it on reconnect) so subscribe / dispose / shed log
|
|
1407
|
-
* lines can be attributed to a specific connection.
|
|
1408
|
-
*/
|
|
1409
|
-
readonly connectionId: string;
|
|
1410
|
-
}
|
|
1411
|
-
|
|
1412
|
-
declare type AssistantStatusEvent = z.infer<typeof AssistantStatusEventSchema>;
|
|
1413
|
-
|
|
1414
|
-
declare const AssistantStatusEventSchema: z.ZodObject<{
|
|
1415
|
-
type: z.ZodLiteral<"assistant_status">;
|
|
1416
|
-
version: z.ZodOptional<z.ZodString>;
|
|
1417
|
-
keyFingerprint: z.ZodOptional<z.ZodString>;
|
|
1418
|
-
}, z.core.$strip>;
|
|
1419
|
-
|
|
1420
|
-
declare type AssistantTextDeltaEvent = z.infer<typeof AssistantTextDeltaEventSchema>;
|
|
1421
|
-
|
|
1422
|
-
declare const AssistantTextDeltaEventSchema: z.ZodObject<{
|
|
1423
|
-
type: z.ZodLiteral<"assistant_text_delta">;
|
|
1424
|
-
text: z.ZodString;
|
|
1425
|
-
messageId: z.ZodOptional<z.ZodString>;
|
|
1426
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
1427
|
-
}, z.core.$strip>;
|
|
1428
|
-
|
|
1429
|
-
declare type AssistantThinkingDeltaEvent = z.infer<typeof AssistantThinkingDeltaEventSchema>;
|
|
1430
|
-
|
|
1431
|
-
declare const AssistantThinkingDeltaEventSchema: z.ZodObject<{
|
|
1432
|
-
type: z.ZodLiteral<"assistant_thinking_delta">;
|
|
1433
|
-
thinking: z.ZodString;
|
|
1434
|
-
messageId: z.ZodOptional<z.ZodString>;
|
|
1435
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
1436
|
-
timestampMs: z.ZodOptional<z.ZodNumber>;
|
|
1437
|
-
}, z.core.$strip>;
|
|
1438
|
-
|
|
1439
|
-
declare type AssistantTurnStartEvent = z.infer<typeof AssistantTurnStartEventSchema>;
|
|
1440
|
-
|
|
1441
|
-
declare const AssistantTurnStartEventSchema: z.ZodObject<{
|
|
1442
|
-
type: z.ZodLiteral<"assistant_turn_start">;
|
|
1443
|
-
messageId: z.ZodString;
|
|
1444
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
1445
|
-
}, z.core.$strip>;
|
|
1446
|
-
|
|
1447
|
-
declare interface AudioEmbeddingInput {
|
|
1448
|
-
type: "audio";
|
|
1449
|
-
data: Buffer;
|
|
1450
|
-
mimeType: string;
|
|
1451
|
-
}
|
|
1452
|
-
|
|
1453
|
-
declare type AvatarUpdatedEvent = z.infer<typeof AvatarUpdatedEventSchema>;
|
|
1454
|
-
|
|
1455
|
-
declare const AvatarUpdatedEventSchema: z.ZodObject<{
|
|
1456
|
-
type: z.ZodLiteral<"avatar_updated">;
|
|
1457
|
-
avatarPath: z.ZodString;
|
|
1458
|
-
}, z.core.$strip>;
|
|
1138
|
+
export declare type AssistantEvent = AssistantEventEnvelope;
|
|
1459
1139
|
|
|
1460
|
-
declare type
|
|
1461
|
-
|
|
1462
|
-
declare const BackgroundToolCompletedEventSchema: z.ZodObject<{
|
|
1463
|
-
type: z.ZodLiteral<"background_tool_completed">;
|
|
1464
|
-
id: z.ZodString;
|
|
1465
|
-
conversationId: z.ZodString;
|
|
1466
|
-
status: z.ZodEnum<{
|
|
1467
|
-
cancelled: "cancelled";
|
|
1468
|
-
completed: "completed";
|
|
1469
|
-
failed: "failed";
|
|
1470
|
-
}>;
|
|
1471
|
-
exitCode: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
1472
|
-
output: z.ZodOptional<z.ZodString>;
|
|
1473
|
-
completedAt: z.ZodNumber;
|
|
1474
|
-
}, z.core.$strip>;
|
|
1475
|
-
|
|
1476
|
-
declare type _BackgroundToolsServerMessages = BackgroundToolStartedEvent | BackgroundToolCompletedEvent;
|
|
1477
|
-
|
|
1478
|
-
declare type BackgroundToolStartedEvent = z.infer<typeof BackgroundToolStartedEventSchema>;
|
|
1479
|
-
|
|
1480
|
-
declare const BackgroundToolStartedEventSchema: z.ZodObject<{
|
|
1481
|
-
type: z.ZodLiteral<"background_tool_started">;
|
|
1482
|
-
id: z.ZodString;
|
|
1483
|
-
toolName: z.ZodString;
|
|
1484
|
-
conversationId: z.ZodString;
|
|
1485
|
-
command: z.ZodString;
|
|
1486
|
-
startedAt: z.ZodNumber;
|
|
1487
|
-
}, z.core.$strip>;
|
|
1488
|
-
|
|
1489
|
-
/**
|
|
1490
|
-
* Media payload for an image or file content block. One unified type covers
|
|
1491
|
-
* both blocks and both storage forms:
|
|
1492
|
-
*
|
|
1493
|
-
* - `base64` — the bytes travel inline with the block. This is the runtime
|
|
1494
|
-
* shape the provider transforms consume and the shape produced for a live
|
|
1495
|
-
* (in-flight) turn.
|
|
1496
|
-
* - `workspace_ref` — the bytes live somewhere in the workspace, not inline.
|
|
1497
|
-
* This is the shape PERSISTED into `messages.content`, keeping large blobs
|
|
1498
|
-
* out of the DB row and the lexical index. It is resolved back to inline
|
|
1499
|
-
* bytes at the provider send boundary (`providers/media-resolve.ts`); any
|
|
1500
|
-
* consumer that needs the raw bytes from stored content resolves it with
|
|
1501
|
-
* `resolveMediaSourceData(source)`.
|
|
1502
|
-
*
|
|
1503
|
-
* `filename` is optional on both arms (present for file blocks and for
|
|
1504
|
-
* generated-media references). For references, `sizeBytes` (and, for images,
|
|
1505
|
-
* `width`/`height`) are captured at persist time so size-only consumers — the
|
|
1506
|
-
* per-turn token estimator especially — can cost the block without reading the
|
|
1507
|
-
* file back off disk.
|
|
1508
|
-
*/
|
|
1509
|
-
declare interface Base64MediaSource {
|
|
1510
|
-
type: "base64";
|
|
1511
|
-
media_type: string;
|
|
1512
|
-
data: string;
|
|
1513
|
-
filename?: string;
|
|
1514
|
-
}
|
|
1140
|
+
export declare type AssistantEventCallback = (event: AssistantEvent) => void | Promise<void>;
|
|
1515
1141
|
|
|
1516
|
-
|
|
1517
|
-
* A single assistant event wrapping an outbound message payload.
|
|
1518
|
-
*
|
|
1519
|
-
* Generic over the payload type. The `TMessage` default of `unknown` keeps
|
|
1520
|
-
* the envelope nameable without a type argument when the caller does not
|
|
1521
|
-
* care about message narrowing.
|
|
1522
|
-
*/
|
|
1523
|
-
declare interface BaseAssistantEvent<TMessage = unknown> {
|
|
1524
|
-
/** Globally unique event identifier (UUID). */
|
|
1525
|
-
id: string;
|
|
1526
|
-
/** Resolved conversation id when available. */
|
|
1527
|
-
conversationId?: string;
|
|
1528
|
-
/**
|
|
1529
|
-
* Monotonic per-conversation sequence number. Assigned by the daemon at
|
|
1530
|
-
* publish time for conversation-scoped events; absent for unscoped
|
|
1531
|
-
* broadcasts. Clients track the highest observed `seq` per conversation
|
|
1532
|
-
* and pass it back on reconnect to request replay of missed events.
|
|
1533
|
-
*/
|
|
1534
|
-
seq?: number;
|
|
1535
|
-
/** ISO-8601 timestamp of when the event was emitted. */
|
|
1536
|
-
emittedAt: string;
|
|
1537
|
-
/** Outbound message payload. */
|
|
1538
|
-
message: TMessage;
|
|
1539
|
-
}
|
|
1142
|
+
declare type AssistantEventEnvelope = z.infer<typeof AssistantEventEnvelopeSchema>;
|
|
1540
1143
|
|
|
1541
1144
|
/**
|
|
1542
|
-
*
|
|
1543
|
-
* `post-compact`, `post-tool-use`, `stop`, `pre-model-call`,
|
|
1544
|
-
* `post-model-call`).
|
|
1145
|
+
* SSE wire envelope wrapping every outbound event from the daemon.
|
|
1545
1146
|
*
|
|
1546
|
-
*
|
|
1547
|
-
* the
|
|
1548
|
-
* construct the `XInputContext` shapes and never supply these.
|
|
1147
|
+
* Transport-level metadata (`id`, `seq`, `emittedAt`, `conversationId`)
|
|
1148
|
+
* surrounds the semantic event payload in `message`.
|
|
1549
1149
|
*/
|
|
1550
|
-
declare
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
|
|
1556
|
-
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
|
|
1562
|
-
|
|
1150
|
+
declare const AssistantEventEnvelopeSchema: z.ZodObject<{
|
|
1151
|
+
id: z.ZodString;
|
|
1152
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
1153
|
+
seq: z.ZodOptional<z.ZodNumber>;
|
|
1154
|
+
emittedAt: z.ZodString;
|
|
1155
|
+
message: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
1156
|
+
type: z.ZodLiteral<"acp_session_completed">;
|
|
1157
|
+
acpSessionId: z.ZodString;
|
|
1158
|
+
stopReason: z.ZodEnum<{
|
|
1159
|
+
cancelled: "cancelled";
|
|
1160
|
+
end_turn: "end_turn";
|
|
1161
|
+
max_tokens: "max_tokens";
|
|
1162
|
+
max_turn_requests: "max_turn_requests";
|
|
1163
|
+
refusal: "refusal";
|
|
1164
|
+
}>;
|
|
1165
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
1166
|
+
type: z.ZodLiteral<"acp_session_error">;
|
|
1167
|
+
acpSessionId: z.ZodString;
|
|
1168
|
+
error: z.ZodString;
|
|
1169
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
1170
|
+
type: z.ZodLiteral<"acp_session_spawned">;
|
|
1171
|
+
acpSessionId: z.ZodString;
|
|
1172
|
+
agent: z.ZodString;
|
|
1173
|
+
parentConversationId: z.ZodString;
|
|
1174
|
+
parentToolUseId: z.ZodOptional<z.ZodString>;
|
|
1175
|
+
task: z.ZodOptional<z.ZodString>;
|
|
1176
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
1177
|
+
type: z.ZodLiteral<"acp_session_update">;
|
|
1178
|
+
acpSessionId: z.ZodString;
|
|
1179
|
+
updateType: z.ZodEnum<{
|
|
1180
|
+
agent_message_chunk: "agent_message_chunk";
|
|
1181
|
+
agent_thought_chunk: "agent_thought_chunk";
|
|
1182
|
+
user_message_chunk: "user_message_chunk";
|
|
1183
|
+
tool_call: "tool_call";
|
|
1184
|
+
tool_call_update: "tool_call_update";
|
|
1185
|
+
plan: "plan";
|
|
1186
|
+
}>;
|
|
1187
|
+
content: z.ZodOptional<z.ZodString>;
|
|
1188
|
+
toolCallId: z.ZodOptional<z.ZodString>;
|
|
1189
|
+
toolTitle: z.ZodOptional<z.ZodString>;
|
|
1190
|
+
toolKind: z.ZodOptional<z.ZodString>;
|
|
1191
|
+
toolStatus: z.ZodOptional<z.ZodString>;
|
|
1192
|
+
rawInput: z.ZodOptional<z.ZodUnknown>;
|
|
1193
|
+
rawOutput: z.ZodOptional<z.ZodUnknown>;
|
|
1194
|
+
locations: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1195
|
+
path: z.ZodString;
|
|
1196
|
+
line: z.ZodOptional<z.ZodNumber>;
|
|
1197
|
+
}, z.core.$strip>>>;
|
|
1198
|
+
messageId: z.ZodOptional<z.ZodString>;
|
|
1199
|
+
seq: z.ZodOptional<z.ZodNumber>;
|
|
1200
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
1201
|
+
type: z.ZodLiteral<"acp_session_usage">;
|
|
1202
|
+
acpSessionId: z.ZodString;
|
|
1203
|
+
usedTokens: z.ZodNumber;
|
|
1204
|
+
contextSize: z.ZodNumber;
|
|
1205
|
+
inputTokens: z.ZodOptional<z.ZodNumber>;
|
|
1206
|
+
outputTokens: z.ZodOptional<z.ZodNumber>;
|
|
1207
|
+
costAmount: z.ZodOptional<z.ZodNumber>;
|
|
1208
|
+
costCurrency: z.ZodOptional<z.ZodString>;
|
|
1209
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
1210
|
+
type: z.ZodLiteral<"app_files_changed">;
|
|
1211
|
+
appId: z.ZodString;
|
|
1212
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1213
|
+
type: z.ZodLiteral<"assistant_activity_state">;
|
|
1214
|
+
conversationId: z.ZodString;
|
|
1215
|
+
activityVersion: z.ZodNumber;
|
|
1216
|
+
phase: z.ZodEnum<{
|
|
1217
|
+
thinking: "thinking";
|
|
1218
|
+
idle: "idle";
|
|
1219
|
+
streaming: "streaming";
|
|
1220
|
+
tool_running: "tool_running";
|
|
1221
|
+
awaiting_confirmation: "awaiting_confirmation";
|
|
1222
|
+
}>;
|
|
1223
|
+
anchor: z.ZodEnum<{
|
|
1224
|
+
assistant_turn: "assistant_turn";
|
|
1225
|
+
user_turn: "user_turn";
|
|
1226
|
+
global: "global";
|
|
1227
|
+
}>;
|
|
1228
|
+
reason: z.ZodEnum<{
|
|
1229
|
+
thinking_delta: "thinking_delta";
|
|
1230
|
+
message_dequeued: "message_dequeued";
|
|
1231
|
+
first_text_delta: "first_text_delta";
|
|
1232
|
+
tool_use_start: "tool_use_start";
|
|
1233
|
+
preview_start: "preview_start";
|
|
1234
|
+
tool_result_received: "tool_result_received";
|
|
1235
|
+
confirmation_requested: "confirmation_requested";
|
|
1236
|
+
confirmation_resolved: "confirmation_resolved";
|
|
1237
|
+
context_compacting: "context_compacting";
|
|
1238
|
+
message_complete: "message_complete";
|
|
1239
|
+
generation_cancelled: "generation_cancelled";
|
|
1240
|
+
error_terminal: "error_terminal";
|
|
1241
|
+
}>;
|
|
1242
|
+
requestId: z.ZodOptional<z.ZodString>;
|
|
1243
|
+
statusText: z.ZodOptional<z.ZodString>;
|
|
1244
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1245
|
+
type: z.ZodLiteral<"assistant_status">;
|
|
1246
|
+
version: z.ZodOptional<z.ZodString>;
|
|
1247
|
+
keyFingerprint: z.ZodOptional<z.ZodString>;
|
|
1248
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1249
|
+
type: z.ZodLiteral<"assistant_text_delta">;
|
|
1250
|
+
text: z.ZodString;
|
|
1251
|
+
messageId: z.ZodOptional<z.ZodString>;
|
|
1252
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
1253
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1254
|
+
type: z.ZodLiteral<"assistant_thinking_delta">;
|
|
1255
|
+
thinking: z.ZodString;
|
|
1256
|
+
messageId: z.ZodOptional<z.ZodString>;
|
|
1257
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
1258
|
+
timestampMs: z.ZodOptional<z.ZodNumber>;
|
|
1259
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1260
|
+
type: z.ZodLiteral<"assistant_turn_start">;
|
|
1261
|
+
messageId: z.ZodString;
|
|
1262
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
1263
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1264
|
+
type: z.ZodLiteral<"avatar_updated">;
|
|
1265
|
+
avatarPath: z.ZodString;
|
|
1266
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1267
|
+
type: z.ZodLiteral<"background_tool_completed">;
|
|
1268
|
+
id: z.ZodString;
|
|
1269
|
+
conversationId: z.ZodString;
|
|
1270
|
+
status: z.ZodEnum<{
|
|
1271
|
+
cancelled: "cancelled";
|
|
1272
|
+
completed: "completed";
|
|
1273
|
+
failed: "failed";
|
|
1274
|
+
}>;
|
|
1275
|
+
exitCode: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
1276
|
+
output: z.ZodOptional<z.ZodString>;
|
|
1277
|
+
completedAt: z.ZodNumber;
|
|
1278
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1279
|
+
type: z.ZodLiteral<"background_tool_started">;
|
|
1280
|
+
id: z.ZodString;
|
|
1281
|
+
toolName: z.ZodString;
|
|
1282
|
+
conversationId: z.ZodString;
|
|
1283
|
+
command: z.ZodString;
|
|
1284
|
+
startedAt: z.ZodNumber;
|
|
1285
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1286
|
+
type: z.ZodLiteral<"bookmark.created">;
|
|
1287
|
+
bookmark: z.ZodObject<{
|
|
1288
|
+
id: z.ZodString;
|
|
1289
|
+
messageId: z.ZodString;
|
|
1290
|
+
conversationId: z.ZodString;
|
|
1291
|
+
conversationTitle: z.ZodNullable<z.ZodString>;
|
|
1292
|
+
messagePreview: z.ZodString;
|
|
1293
|
+
messageRole: z.ZodString;
|
|
1294
|
+
messageCreatedAt: z.ZodNumber;
|
|
1295
|
+
createdAt: z.ZodNumber;
|
|
1296
|
+
}, z.core.$strip>;
|
|
1297
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1298
|
+
type: z.ZodLiteral<"bookmark.deleted">;
|
|
1299
|
+
messageId: z.ZodString;
|
|
1300
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1301
|
+
type: z.ZodLiteral<"client_settings_update">;
|
|
1302
|
+
key: z.ZodString;
|
|
1303
|
+
value: z.ZodString;
|
|
1304
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1305
|
+
type: z.ZodLiteral<"compaction_circuit_closed">;
|
|
1306
|
+
conversationId: z.ZodString;
|
|
1307
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1308
|
+
type: z.ZodLiteral<"compaction_circuit_open">;
|
|
1309
|
+
conversationId: z.ZodString;
|
|
1310
|
+
reason: z.ZodLiteral<"3_consecutive_failures">;
|
|
1311
|
+
openUntil: z.ZodNumber;
|
|
1312
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1313
|
+
type: z.ZodLiteral<"config_changed">;
|
|
1314
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1315
|
+
type: z.ZodLiteral<"confirmation_request">;
|
|
1316
|
+
requestId: z.ZodString;
|
|
1317
|
+
toolName: z.ZodString;
|
|
1318
|
+
input: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
1319
|
+
riskLevel: z.ZodString;
|
|
1320
|
+
riskReason: z.ZodOptional<z.ZodString>;
|
|
1321
|
+
isContainerized: z.ZodOptional<z.ZodBoolean>;
|
|
1322
|
+
executionTarget: z.ZodOptional<z.ZodEnum<{
|
|
1323
|
+
sandbox: "sandbox";
|
|
1324
|
+
host: "host";
|
|
1325
|
+
}>>;
|
|
1326
|
+
allowlistOptions: z.ZodArray<z.ZodObject<{
|
|
1327
|
+
label: z.ZodString;
|
|
1328
|
+
description: z.ZodString;
|
|
1329
|
+
pattern: z.ZodString;
|
|
1330
|
+
}, z.core.$strip>>;
|
|
1331
|
+
scopeOptions: z.ZodArray<z.ZodObject<{
|
|
1332
|
+
label: z.ZodString;
|
|
1333
|
+
scope: z.ZodString;
|
|
1334
|
+
}, z.core.$strip>>;
|
|
1335
|
+
directoryScopeOptions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1336
|
+
label: z.ZodString;
|
|
1337
|
+
scope: z.ZodString;
|
|
1338
|
+
}, z.core.$strip>>>;
|
|
1339
|
+
diff: z.ZodOptional<z.ZodObject<{
|
|
1340
|
+
filePath: z.ZodString;
|
|
1341
|
+
oldContent: z.ZodString;
|
|
1342
|
+
newContent: z.ZodString;
|
|
1343
|
+
isNewFile: z.ZodBoolean;
|
|
1344
|
+
}, z.core.$strip>>;
|
|
1345
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
1346
|
+
persistentDecisionsAllowed: z.ZodOptional<z.ZodBoolean>;
|
|
1347
|
+
toolUseId: z.ZodOptional<z.ZodString>;
|
|
1348
|
+
acpToolKind: z.ZodOptional<z.ZodString>;
|
|
1349
|
+
acpOptions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1350
|
+
optionId: z.ZodString;
|
|
1351
|
+
name: z.ZodString;
|
|
1352
|
+
kind: z.ZodEnum<{
|
|
1353
|
+
allow_once: "allow_once";
|
|
1354
|
+
allow_always: "allow_always";
|
|
1355
|
+
reject_once: "reject_once";
|
|
1356
|
+
reject_always: "reject_always";
|
|
1357
|
+
}>;
|
|
1358
|
+
}, z.core.$strip>>>;
|
|
1359
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1360
|
+
type: z.ZodLiteral<"confirmation_state_changed">;
|
|
1361
|
+
conversationId: z.ZodString;
|
|
1362
|
+
requestId: z.ZodString;
|
|
1363
|
+
state: z.ZodEnum<{
|
|
1364
|
+
timed_out: "timed_out";
|
|
1365
|
+
pending: "pending";
|
|
1366
|
+
approved: "approved";
|
|
1367
|
+
denied: "denied";
|
|
1368
|
+
resolved_stale: "resolved_stale";
|
|
1369
|
+
}>;
|
|
1370
|
+
source: z.ZodEnum<{
|
|
1371
|
+
button: "button";
|
|
1372
|
+
inline_nl: "inline_nl";
|
|
1373
|
+
auto_deny: "auto_deny";
|
|
1374
|
+
timeout: "timeout";
|
|
1375
|
+
system: "system";
|
|
1376
|
+
}>;
|
|
1377
|
+
causedByRequestId: z.ZodOptional<z.ZodString>;
|
|
1378
|
+
decisionText: z.ZodOptional<z.ZodString>;
|
|
1379
|
+
toolUseId: z.ZodOptional<z.ZodString>;
|
|
1380
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1381
|
+
type: z.ZodLiteral<"contact_request">;
|
|
1382
|
+
requestId: z.ZodString;
|
|
1383
|
+
channel: z.ZodOptional<z.ZodString>;
|
|
1384
|
+
placeholder: z.ZodOptional<z.ZodString>;
|
|
1385
|
+
label: z.ZodOptional<z.ZodString>;
|
|
1386
|
+
description: z.ZodOptional<z.ZodString>;
|
|
1387
|
+
role: z.ZodOptional<z.ZodString>;
|
|
1388
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1389
|
+
type: z.ZodLiteral<"contacts_changed">;
|
|
1390
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1391
|
+
type: z.ZodLiteral<"context_compacted">;
|
|
1392
|
+
conversationId: z.ZodString;
|
|
1393
|
+
previousEstimatedInputTokens: z.ZodNumber;
|
|
1394
|
+
estimatedInputTokens: z.ZodNumber;
|
|
1395
|
+
maxInputTokens: z.ZodNumber;
|
|
1396
|
+
thresholdTokens: z.ZodNumber;
|
|
1397
|
+
compactedMessages: z.ZodNumber;
|
|
1398
|
+
summaryCalls: z.ZodNumber;
|
|
1399
|
+
summaryInputTokens: z.ZodNumber;
|
|
1400
|
+
summaryOutputTokens: z.ZodNumber;
|
|
1401
|
+
summaryModel: z.ZodString;
|
|
1402
|
+
summaryCharCount: z.ZodOptional<z.ZodNumber>;
|
|
1403
|
+
summaryHeaderCount: z.ZodOptional<z.ZodNumber>;
|
|
1404
|
+
summaryHadMemoryEcho: z.ZodOptional<z.ZodBoolean>;
|
|
1405
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1406
|
+
type: z.ZodLiteral<"conversation_error">;
|
|
1407
|
+
conversationId: z.ZodString;
|
|
1408
|
+
code: z.ZodEnum<{
|
|
1409
|
+
PROVIDER_NETWORK: "PROVIDER_NETWORK";
|
|
1410
|
+
PROVIDER_RATE_LIMIT: "PROVIDER_RATE_LIMIT";
|
|
1411
|
+
MANAGED_USAGE_LIMIT: "MANAGED_USAGE_LIMIT";
|
|
1412
|
+
PROVIDER_OVERLOADED: "PROVIDER_OVERLOADED";
|
|
1413
|
+
PROVIDER_API: "PROVIDER_API";
|
|
1414
|
+
IMAGE_TOO_LARGE: "IMAGE_TOO_LARGE";
|
|
1415
|
+
PROVIDER_BILLING: "PROVIDER_BILLING";
|
|
1416
|
+
PROVIDER_ORDERING: "PROVIDER_ORDERING";
|
|
1417
|
+
PROVIDER_WEB_SEARCH: "PROVIDER_WEB_SEARCH";
|
|
1418
|
+
PROVIDER_NOT_CONFIGURED: "PROVIDER_NOT_CONFIGURED";
|
|
1419
|
+
PROVIDER_INVALID_KEY: "PROVIDER_INVALID_KEY";
|
|
1420
|
+
MANAGED_KEY_INVALID: "MANAGED_KEY_INVALID";
|
|
1421
|
+
CONTEXT_TOO_LARGE: "CONTEXT_TOO_LARGE";
|
|
1422
|
+
BUDGET_YIELD_UNRECOVERED: "BUDGET_YIELD_UNRECOVERED";
|
|
1423
|
+
MAX_TOKENS_REACHED: "MAX_TOKENS_REACHED";
|
|
1424
|
+
CONVERSATION_ABORTED: "CONVERSATION_ABORTED";
|
|
1425
|
+
CONVERSATION_PROCESSING_FAILED: "CONVERSATION_PROCESSING_FAILED";
|
|
1426
|
+
DISK_SPACE_CRITICAL: "DISK_SPACE_CRITICAL";
|
|
1427
|
+
UNKNOWN: "UNKNOWN";
|
|
1428
|
+
}>;
|
|
1429
|
+
userMessage: z.ZodString;
|
|
1430
|
+
retryable: z.ZodBoolean;
|
|
1431
|
+
debugDetails: z.ZodOptional<z.ZodString>;
|
|
1432
|
+
errorCategory: z.ZodOptional<z.ZodString>;
|
|
1433
|
+
connectionName: z.ZodOptional<z.ZodString>;
|
|
1434
|
+
profileName: z.ZodOptional<z.ZodString>;
|
|
1435
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1436
|
+
type: z.ZodLiteral<"conversation_inference_profile_updated">;
|
|
1437
|
+
conversationId: z.ZodString;
|
|
1438
|
+
profile: z.ZodNullable<z.ZodString>;
|
|
1439
|
+
sessionId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1440
|
+
expiresAt: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
1441
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1442
|
+
type: z.ZodLiteral<"conversation_list_invalidated">;
|
|
1443
|
+
reason: z.ZodEnum<{
|
|
1444
|
+
created: "created";
|
|
1445
|
+
renamed: "renamed";
|
|
1446
|
+
deleted: "deleted";
|
|
1447
|
+
reordered: "reordered";
|
|
1448
|
+
seen_changed: "seen_changed";
|
|
1449
|
+
}>;
|
|
1450
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1451
|
+
type: z.ZodLiteral<"conversation_notice">;
|
|
1452
|
+
conversationId: z.ZodString;
|
|
1453
|
+
source: z.ZodEnum<{
|
|
1454
|
+
memory_v3: "memory_v3";
|
|
1455
|
+
}>;
|
|
1456
|
+
code: z.ZodEnum<{
|
|
1457
|
+
PROVIDER_NETWORK: "PROVIDER_NETWORK";
|
|
1458
|
+
PROVIDER_RATE_LIMIT: "PROVIDER_RATE_LIMIT";
|
|
1459
|
+
MANAGED_USAGE_LIMIT: "MANAGED_USAGE_LIMIT";
|
|
1460
|
+
PROVIDER_OVERLOADED: "PROVIDER_OVERLOADED";
|
|
1461
|
+
PROVIDER_API: "PROVIDER_API";
|
|
1462
|
+
IMAGE_TOO_LARGE: "IMAGE_TOO_LARGE";
|
|
1463
|
+
PROVIDER_BILLING: "PROVIDER_BILLING";
|
|
1464
|
+
PROVIDER_ORDERING: "PROVIDER_ORDERING";
|
|
1465
|
+
PROVIDER_WEB_SEARCH: "PROVIDER_WEB_SEARCH";
|
|
1466
|
+
PROVIDER_NOT_CONFIGURED: "PROVIDER_NOT_CONFIGURED";
|
|
1467
|
+
PROVIDER_INVALID_KEY: "PROVIDER_INVALID_KEY";
|
|
1468
|
+
MANAGED_KEY_INVALID: "MANAGED_KEY_INVALID";
|
|
1469
|
+
CONTEXT_TOO_LARGE: "CONTEXT_TOO_LARGE";
|
|
1470
|
+
BUDGET_YIELD_UNRECOVERED: "BUDGET_YIELD_UNRECOVERED";
|
|
1471
|
+
MAX_TOKENS_REACHED: "MAX_TOKENS_REACHED";
|
|
1472
|
+
CONVERSATION_ABORTED: "CONVERSATION_ABORTED";
|
|
1473
|
+
CONVERSATION_PROCESSING_FAILED: "CONVERSATION_PROCESSING_FAILED";
|
|
1474
|
+
DISK_SPACE_CRITICAL: "DISK_SPACE_CRITICAL";
|
|
1475
|
+
UNKNOWN: "UNKNOWN";
|
|
1476
|
+
}>;
|
|
1477
|
+
userMessage: z.ZodString;
|
|
1478
|
+
errorCategory: z.ZodOptional<z.ZodString>;
|
|
1479
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1480
|
+
type: z.ZodLiteral<"conversation_title_updated">;
|
|
1481
|
+
conversationId: z.ZodString;
|
|
1482
|
+
title: z.ZodString;
|
|
1483
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1484
|
+
type: z.ZodLiteral<"disk_pressure_status_changed">;
|
|
1485
|
+
status: z.ZodObject<{
|
|
1486
|
+
enabled: z.ZodBoolean;
|
|
1487
|
+
state: z.ZodEnum<{
|
|
1488
|
+
unknown: "unknown";
|
|
1489
|
+
disabled: "disabled";
|
|
1490
|
+
critical: "critical";
|
|
1491
|
+
ok: "ok";
|
|
1492
|
+
warning: "warning";
|
|
1493
|
+
}>;
|
|
1494
|
+
locked: z.ZodBoolean;
|
|
1495
|
+
acknowledged: z.ZodBoolean;
|
|
1496
|
+
overrideActive: z.ZodBoolean;
|
|
1497
|
+
effectivelyLocked: z.ZodBoolean;
|
|
1498
|
+
lockId: z.ZodNullable<z.ZodString>;
|
|
1499
|
+
usagePercent: z.ZodNullable<z.ZodNumber>;
|
|
1500
|
+
thresholdPercent: z.ZodNumber;
|
|
1501
|
+
path: z.ZodNullable<z.ZodString>;
|
|
1502
|
+
lastCheckedAt: z.ZodNullable<z.ZodString>;
|
|
1503
|
+
blockedCapabilities: z.ZodArray<z.ZodEnum<{
|
|
1504
|
+
"agent-turns": "agent-turns";
|
|
1505
|
+
"background-work": "background-work";
|
|
1506
|
+
"remote-ingress": "remote-ingress";
|
|
1507
|
+
}>>;
|
|
1508
|
+
error: z.ZodNullable<z.ZodString>;
|
|
1509
|
+
}, z.core.$strip>;
|
|
1510
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1511
|
+
type: z.ZodLiteral<"document_comment_created">;
|
|
1512
|
+
conversationId: z.ZodString;
|
|
1513
|
+
surfaceId: z.ZodString;
|
|
1514
|
+
comment: z.ZodObject<{
|
|
1515
|
+
id: z.ZodString;
|
|
1516
|
+
surfaceId: z.ZodString;
|
|
1517
|
+
author: z.ZodString;
|
|
1518
|
+
content: z.ZodString;
|
|
1519
|
+
anchorStart: z.ZodOptional<z.ZodNumber>;
|
|
1520
|
+
anchorEnd: z.ZodOptional<z.ZodNumber>;
|
|
1521
|
+
anchorText: z.ZodOptional<z.ZodString>;
|
|
1522
|
+
parentCommentId: z.ZodOptional<z.ZodString>;
|
|
1523
|
+
status: z.ZodString;
|
|
1524
|
+
createdAt: z.ZodNumber;
|
|
1525
|
+
updatedAt: z.ZodNumber;
|
|
1526
|
+
}, z.core.$strip>;
|
|
1527
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1528
|
+
type: z.ZodLiteral<"document_comment_deleted">;
|
|
1529
|
+
conversationId: z.ZodString;
|
|
1530
|
+
surfaceId: z.ZodString;
|
|
1531
|
+
commentId: z.ZodString;
|
|
1532
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1533
|
+
type: z.ZodLiteral<"document_comment_reopened">;
|
|
1534
|
+
conversationId: z.ZodString;
|
|
1535
|
+
surfaceId: z.ZodString;
|
|
1536
|
+
commentId: z.ZodString;
|
|
1537
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1538
|
+
type: z.ZodLiteral<"document_comment_resolved">;
|
|
1539
|
+
conversationId: z.ZodString;
|
|
1540
|
+
surfaceId: z.ZodString;
|
|
1541
|
+
commentId: z.ZodString;
|
|
1542
|
+
resolvedBy: z.ZodString;
|
|
1543
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1544
|
+
type: z.ZodLiteral<"document_editor_show">;
|
|
1545
|
+
conversationId: z.ZodString;
|
|
1546
|
+
surfaceId: z.ZodString;
|
|
1547
|
+
title: z.ZodString;
|
|
1548
|
+
initialContent: z.ZodString;
|
|
1549
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1550
|
+
type: z.ZodLiteral<"document_editor_update">;
|
|
1551
|
+
conversationId: z.ZodString;
|
|
1552
|
+
surfaceId: z.ZodString;
|
|
1553
|
+
markdown: z.ZodString;
|
|
1554
|
+
mode: z.ZodString;
|
|
1555
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1556
|
+
type: z.ZodLiteral<"error">;
|
|
1557
|
+
message: z.ZodString;
|
|
1558
|
+
code: z.ZodOptional<z.ZodString>;
|
|
1559
|
+
category: z.ZodOptional<z.ZodString>;
|
|
1560
|
+
errorCategory: z.ZodOptional<z.ZodString>;
|
|
1561
|
+
requestId: z.ZodOptional<z.ZodString>;
|
|
1562
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
1563
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1564
|
+
type: z.ZodLiteral<"generation_cancelled">;
|
|
1565
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
1566
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1567
|
+
type: z.ZodLiteral<"generation_handoff">;
|
|
1568
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
1569
|
+
requestId: z.ZodOptional<z.ZodString>;
|
|
1570
|
+
queuedCount: z.ZodNumber;
|
|
1571
|
+
messageId: z.ZodOptional<z.ZodString>;
|
|
1572
|
+
attachments: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1573
|
+
id: z.ZodOptional<z.ZodString>;
|
|
1574
|
+
filename: z.ZodString;
|
|
1575
|
+
mimeType: z.ZodString;
|
|
1576
|
+
data: z.ZodString;
|
|
1577
|
+
sourceType: z.ZodOptional<z.ZodEnum<{
|
|
1578
|
+
host_file: "host_file";
|
|
1579
|
+
sandbox_file: "sandbox_file";
|
|
1580
|
+
tool_block: "tool_block";
|
|
1581
|
+
}>>;
|
|
1582
|
+
sizeBytes: z.ZodOptional<z.ZodNumber>;
|
|
1583
|
+
thumbnailData: z.ZodOptional<z.ZodString>;
|
|
1584
|
+
fileBacked: z.ZodOptional<z.ZodBoolean>;
|
|
1585
|
+
filePath: z.ZodOptional<z.ZodString>;
|
|
1586
|
+
}, z.core.$strip>>>;
|
|
1587
|
+
attachmentWarnings: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1588
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1589
|
+
type: z.ZodLiteral<"heartbeat_alert">;
|
|
1590
|
+
title: z.ZodString;
|
|
1591
|
+
body: z.ZodString;
|
|
1592
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1593
|
+
type: z.ZodLiteral<"heartbeat_conversation_created">;
|
|
1594
|
+
conversationId: z.ZodString;
|
|
1595
|
+
title: z.ZodString;
|
|
1596
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1597
|
+
type: z.ZodLiteral<"home_feed_updated">;
|
|
1598
|
+
updatedAt: z.ZodString;
|
|
1599
|
+
newItemCount: z.ZodNumber;
|
|
1600
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1601
|
+
type: z.ZodLiteral<"hook_event">;
|
|
1602
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
1603
|
+
hookName: z.ZodString;
|
|
1604
|
+
owner: z.ZodObject<{
|
|
1605
|
+
kind: z.ZodEnum<{
|
|
1606
|
+
plugin: "plugin";
|
|
1607
|
+
workspace: "workspace";
|
|
1608
|
+
}>;
|
|
1609
|
+
id: z.ZodString;
|
|
1610
|
+
}, z.core.$strip>;
|
|
1611
|
+
detail: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
1612
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1613
|
+
type: z.ZodLiteral<"host_app_control_cancel">;
|
|
1614
|
+
requestId: z.ZodString;
|
|
1615
|
+
conversationId: z.ZodString;
|
|
1616
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1617
|
+
type: z.ZodLiteral<"host_app_control_request">;
|
|
1618
|
+
requestId: z.ZodString;
|
|
1619
|
+
conversationId: z.ZodString;
|
|
1620
|
+
toolName: z.ZodString;
|
|
1621
|
+
input: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
1622
|
+
tool: z.ZodLiteral<"start">;
|
|
1623
|
+
app: z.ZodString;
|
|
1624
|
+
args: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1625
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1626
|
+
tool: z.ZodLiteral<"observe">;
|
|
1627
|
+
app: z.ZodString;
|
|
1628
|
+
settle_ms: z.ZodOptional<z.ZodNumber>;
|
|
1629
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1630
|
+
tool: z.ZodLiteral<"press">;
|
|
1631
|
+
app: z.ZodString;
|
|
1632
|
+
key: z.ZodString;
|
|
1633
|
+
modifiers: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1634
|
+
duration_ms: z.ZodOptional<z.ZodNumber>;
|
|
1635
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1636
|
+
tool: z.ZodLiteral<"combo">;
|
|
1637
|
+
app: z.ZodString;
|
|
1638
|
+
keys: z.ZodArray<z.ZodString>;
|
|
1639
|
+
duration_ms: z.ZodOptional<z.ZodNumber>;
|
|
1640
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1641
|
+
tool: z.ZodLiteral<"sequence">;
|
|
1642
|
+
app: z.ZodString;
|
|
1643
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
1644
|
+
key: z.ZodString;
|
|
1645
|
+
modifiers: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1646
|
+
duration_ms: z.ZodOptional<z.ZodNumber>;
|
|
1647
|
+
gap_ms: z.ZodOptional<z.ZodNumber>;
|
|
1648
|
+
}, z.core.$strip>>;
|
|
1649
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1650
|
+
tool: z.ZodLiteral<"type">;
|
|
1651
|
+
app: z.ZodString;
|
|
1652
|
+
text: z.ZodString;
|
|
1653
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1654
|
+
tool: z.ZodLiteral<"click">;
|
|
1655
|
+
app: z.ZodString;
|
|
1656
|
+
x: z.ZodNumber;
|
|
1657
|
+
y: z.ZodNumber;
|
|
1658
|
+
button: z.ZodOptional<z.ZodEnum<{
|
|
1659
|
+
left: "left";
|
|
1660
|
+
right: "right";
|
|
1661
|
+
middle: "middle";
|
|
1662
|
+
}>>;
|
|
1663
|
+
double: z.ZodOptional<z.ZodBoolean>;
|
|
1664
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1665
|
+
tool: z.ZodLiteral<"drag">;
|
|
1666
|
+
app: z.ZodString;
|
|
1667
|
+
from_x: z.ZodNumber;
|
|
1668
|
+
from_y: z.ZodNumber;
|
|
1669
|
+
to_x: z.ZodNumber;
|
|
1670
|
+
to_y: z.ZodNumber;
|
|
1671
|
+
button: z.ZodOptional<z.ZodEnum<{
|
|
1672
|
+
left: "left";
|
|
1673
|
+
right: "right";
|
|
1674
|
+
middle: "middle";
|
|
1675
|
+
}>>;
|
|
1676
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1677
|
+
tool: z.ZodLiteral<"stop">;
|
|
1678
|
+
app: z.ZodOptional<z.ZodString>;
|
|
1679
|
+
reason: z.ZodOptional<z.ZodString>;
|
|
1680
|
+
}, z.core.$strip>], "tool">;
|
|
1681
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1682
|
+
type: z.ZodLiteral<"host_bash_cancel">;
|
|
1683
|
+
requestId: z.ZodString;
|
|
1684
|
+
conversationId: z.ZodString;
|
|
1685
|
+
targetClientId: z.ZodOptional<z.ZodString>;
|
|
1686
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1687
|
+
type: z.ZodLiteral<"host_bash_request">;
|
|
1688
|
+
requestId: z.ZodString;
|
|
1689
|
+
conversationId: z.ZodString;
|
|
1690
|
+
command: z.ZodString;
|
|
1691
|
+
working_dir: z.ZodOptional<z.ZodString>;
|
|
1692
|
+
timeout_seconds: z.ZodOptional<z.ZodNumber>;
|
|
1693
|
+
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
1694
|
+
targetClientId: z.ZodOptional<z.ZodString>;
|
|
1695
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1696
|
+
type: z.ZodLiteral<"host_browser_cancel">;
|
|
1697
|
+
requestId: z.ZodString;
|
|
1698
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1699
|
+
type: z.ZodLiteral<"host_browser_request">;
|
|
1700
|
+
requestId: z.ZodString;
|
|
1701
|
+
conversationId: z.ZodString;
|
|
1702
|
+
cdpMethod: z.ZodString;
|
|
1703
|
+
cdpParams: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
1704
|
+
cdpSessionId: z.ZodOptional<z.ZodString>;
|
|
1705
|
+
timeout_seconds: z.ZodOptional<z.ZodNumber>;
|
|
1706
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1707
|
+
type: z.ZodLiteral<"host_cu_cancel">;
|
|
1708
|
+
requestId: z.ZodString;
|
|
1709
|
+
conversationId: z.ZodString;
|
|
1710
|
+
targetClientId: z.ZodOptional<z.ZodString>;
|
|
1711
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1712
|
+
type: z.ZodLiteral<"host_cu_request">;
|
|
1713
|
+
requestId: z.ZodString;
|
|
1714
|
+
conversationId: z.ZodString;
|
|
1715
|
+
targetClientId: z.ZodOptional<z.ZodString>;
|
|
1716
|
+
toolName: z.ZodString;
|
|
1717
|
+
input: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
1718
|
+
stepNumber: z.ZodNumber;
|
|
1719
|
+
reasoning: z.ZodOptional<z.ZodString>;
|
|
1720
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1721
|
+
type: z.ZodLiteral<"host_file_cancel">;
|
|
1722
|
+
requestId: z.ZodString;
|
|
1723
|
+
conversationId: z.ZodString;
|
|
1724
|
+
targetClientId: z.ZodOptional<z.ZodString>;
|
|
1725
|
+
}, z.core.$strip>, z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
1726
|
+
type: z.ZodLiteral<"host_file_request">;
|
|
1727
|
+
requestId: z.ZodString;
|
|
1728
|
+
conversationId: z.ZodString;
|
|
1729
|
+
targetClientId: z.ZodOptional<z.ZodString>;
|
|
1730
|
+
operation: z.ZodLiteral<"read">;
|
|
1731
|
+
path: z.ZodString;
|
|
1732
|
+
offset: z.ZodOptional<z.ZodNumber>;
|
|
1733
|
+
limit: z.ZodOptional<z.ZodNumber>;
|
|
1734
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1735
|
+
type: z.ZodLiteral<"host_file_request">;
|
|
1736
|
+
requestId: z.ZodString;
|
|
1737
|
+
conversationId: z.ZodString;
|
|
1738
|
+
targetClientId: z.ZodOptional<z.ZodString>;
|
|
1739
|
+
operation: z.ZodLiteral<"write">;
|
|
1740
|
+
path: z.ZodString;
|
|
1741
|
+
content: z.ZodString;
|
|
1742
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1743
|
+
type: z.ZodLiteral<"host_file_request">;
|
|
1744
|
+
requestId: z.ZodString;
|
|
1745
|
+
conversationId: z.ZodString;
|
|
1746
|
+
targetClientId: z.ZodOptional<z.ZodString>;
|
|
1747
|
+
operation: z.ZodLiteral<"edit">;
|
|
1748
|
+
path: z.ZodString;
|
|
1749
|
+
old_string: z.ZodString;
|
|
1750
|
+
new_string: z.ZodString;
|
|
1751
|
+
replace_all: z.ZodOptional<z.ZodBoolean>;
|
|
1752
|
+
}, z.core.$strip>], "operation">, z.ZodObject<{
|
|
1753
|
+
type: z.ZodLiteral<"host_transfer_cancel">;
|
|
1754
|
+
requestId: z.ZodString;
|
|
1755
|
+
conversationId: z.ZodString;
|
|
1756
|
+
targetClientId: z.ZodOptional<z.ZodString>;
|
|
1757
|
+
}, z.core.$strip>, z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
1758
|
+
type: z.ZodLiteral<"host_transfer_request">;
|
|
1759
|
+
requestId: z.ZodString;
|
|
1760
|
+
conversationId: z.ZodString;
|
|
1761
|
+
targetClientId: z.ZodOptional<z.ZodString>;
|
|
1762
|
+
direction: z.ZodLiteral<"to_host">;
|
|
1763
|
+
transferId: z.ZodString;
|
|
1764
|
+
destPath: z.ZodString;
|
|
1765
|
+
sizeBytes: z.ZodNumber;
|
|
1766
|
+
sha256: z.ZodString;
|
|
1767
|
+
overwrite: z.ZodBoolean;
|
|
1768
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1769
|
+
type: z.ZodLiteral<"host_transfer_request">;
|
|
1770
|
+
requestId: z.ZodString;
|
|
1771
|
+
conversationId: z.ZodString;
|
|
1772
|
+
targetClientId: z.ZodOptional<z.ZodString>;
|
|
1773
|
+
direction: z.ZodLiteral<"to_sandbox">;
|
|
1774
|
+
transferId: z.ZodString;
|
|
1775
|
+
sourcePath: z.ZodString;
|
|
1776
|
+
}, z.core.$strip>], "direction">, z.ZodObject<{
|
|
1777
|
+
type: z.ZodLiteral<"host_ui_snapshot_cancel">;
|
|
1778
|
+
requestId: z.ZodString;
|
|
1779
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1780
|
+
type: z.ZodLiteral<"host_ui_snapshot_request">;
|
|
1781
|
+
requestId: z.ZodString;
|
|
1782
|
+
view: z.ZodEnum<{
|
|
1783
|
+
sampler: "sampler";
|
|
1784
|
+
chat: "chat";
|
|
1785
|
+
}>;
|
|
1786
|
+
tokens: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
1787
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1788
|
+
type: z.ZodLiteral<"identity_changed">;
|
|
1789
|
+
name: z.ZodString;
|
|
1790
|
+
role: z.ZodString;
|
|
1791
|
+
personality: z.ZodString;
|
|
1792
|
+
emoji: z.ZodString;
|
|
1793
|
+
home: z.ZodString;
|
|
1794
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1795
|
+
type: z.ZodLiteral<"interaction_resolved">;
|
|
1796
|
+
requestId: z.ZodString;
|
|
1797
|
+
conversationId: z.ZodString;
|
|
1798
|
+
state: z.ZodEnum<{
|
|
1799
|
+
cancelled: "cancelled";
|
|
1800
|
+
superseded: "superseded";
|
|
1801
|
+
approved: "approved";
|
|
1802
|
+
rejected: "rejected";
|
|
1803
|
+
answered: "answered";
|
|
1804
|
+
}>;
|
|
1805
|
+
kind: z.ZodString;
|
|
1806
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1807
|
+
type: z.ZodLiteral<"memory_recalled">;
|
|
1808
|
+
provider: z.ZodString;
|
|
1809
|
+
model: z.ZodString;
|
|
1810
|
+
degradation: z.ZodOptional<z.ZodObject<{
|
|
1811
|
+
semanticUnavailable: z.ZodBoolean;
|
|
1812
|
+
reason: z.ZodString;
|
|
1813
|
+
fallbackSources: z.ZodArray<z.ZodString>;
|
|
1814
|
+
}, z.core.$strip>>;
|
|
1815
|
+
semanticHits: z.ZodNumber;
|
|
1816
|
+
tier1Count: z.ZodNumber;
|
|
1817
|
+
tier2Count: z.ZodNumber;
|
|
1818
|
+
hybridSearchLatencyMs: z.ZodNumber;
|
|
1819
|
+
sparseVectorUsed: z.ZodBoolean;
|
|
1820
|
+
mergedCount: z.ZodNumber;
|
|
1821
|
+
selectedCount: z.ZodNumber;
|
|
1822
|
+
injectedTokens: z.ZodNumber;
|
|
1823
|
+
latencyMs: z.ZodNumber;
|
|
1824
|
+
topCandidates: z.ZodArray<z.ZodObject<{
|
|
1825
|
+
key: z.ZodString;
|
|
1826
|
+
type: z.ZodString;
|
|
1827
|
+
kind: z.ZodString;
|
|
1828
|
+
finalScore: z.ZodNumber;
|
|
1829
|
+
semantic: z.ZodNumber;
|
|
1830
|
+
recency: z.ZodNumber;
|
|
1831
|
+
}, z.core.$strip>>;
|
|
1832
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1833
|
+
type: z.ZodLiteral<"memory_status">;
|
|
1834
|
+
enabled: z.ZodBoolean;
|
|
1835
|
+
degraded: z.ZodBoolean;
|
|
1836
|
+
degradation: z.ZodOptional<z.ZodObject<{
|
|
1837
|
+
semanticUnavailable: z.ZodBoolean;
|
|
1838
|
+
reason: z.ZodString;
|
|
1839
|
+
fallbackSources: z.ZodArray<z.ZodString>;
|
|
1840
|
+
}, z.core.$strip>>;
|
|
1841
|
+
reason: z.ZodOptional<z.ZodString>;
|
|
1842
|
+
provider: z.ZodOptional<z.ZodString>;
|
|
1843
|
+
model: z.ZodOptional<z.ZodString>;
|
|
1844
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1845
|
+
type: z.ZodLiteral<"message_complete">;
|
|
1846
|
+
messageId: z.ZodOptional<z.ZodString>;
|
|
1847
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
1848
|
+
source: z.ZodOptional<z.ZodEnum<{
|
|
1849
|
+
main: "main";
|
|
1850
|
+
aux: "aux";
|
|
1851
|
+
}>>;
|
|
1852
|
+
attachments: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1853
|
+
id: z.ZodOptional<z.ZodString>;
|
|
1854
|
+
filename: z.ZodString;
|
|
1855
|
+
mimeType: z.ZodString;
|
|
1856
|
+
data: z.ZodString;
|
|
1857
|
+
sourceType: z.ZodOptional<z.ZodEnum<{
|
|
1858
|
+
host_file: "host_file";
|
|
1859
|
+
sandbox_file: "sandbox_file";
|
|
1860
|
+
tool_block: "tool_block";
|
|
1861
|
+
}>>;
|
|
1862
|
+
sizeBytes: z.ZodOptional<z.ZodNumber>;
|
|
1863
|
+
thumbnailData: z.ZodOptional<z.ZodString>;
|
|
1864
|
+
fileBacked: z.ZodOptional<z.ZodBoolean>;
|
|
1865
|
+
filePath: z.ZodOptional<z.ZodString>;
|
|
1866
|
+
}, z.core.$strip>>>;
|
|
1867
|
+
attachmentWarnings: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1868
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1869
|
+
type: z.ZodLiteral<"message_dequeued">;
|
|
1870
|
+
conversationId: z.ZodString;
|
|
1871
|
+
requestId: z.ZodString;
|
|
1872
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1873
|
+
type: z.ZodLiteral<"message_queued">;
|
|
1874
|
+
conversationId: z.ZodString;
|
|
1875
|
+
requestId: z.ZodString;
|
|
1876
|
+
position: z.ZodNumber;
|
|
1877
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1878
|
+
type: z.ZodLiteral<"message_queued_deleted">;
|
|
1879
|
+
conversationId: z.ZodString;
|
|
1880
|
+
requestId: z.ZodString;
|
|
1881
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1882
|
+
type: z.ZodLiteral<"message_request_complete">;
|
|
1883
|
+
conversationId: z.ZodString;
|
|
1884
|
+
requestId: z.ZodString;
|
|
1885
|
+
runStillActive: z.ZodOptional<z.ZodBoolean>;
|
|
1886
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1887
|
+
type: z.ZodLiteral<"message_steered">;
|
|
1888
|
+
conversationId: z.ZodString;
|
|
1889
|
+
requestId: z.ZodString;
|
|
1890
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1891
|
+
type: z.ZodLiteral<"model_info">;
|
|
1892
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
1893
|
+
model: z.ZodString;
|
|
1894
|
+
provider: z.ZodString;
|
|
1895
|
+
configuredProviders: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1896
|
+
availableModels: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1897
|
+
id: z.ZodString;
|
|
1898
|
+
displayName: z.ZodString;
|
|
1899
|
+
}, z.core.$strip>>>;
|
|
1900
|
+
allProviders: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1901
|
+
id: z.ZodString;
|
|
1902
|
+
displayName: z.ZodString;
|
|
1903
|
+
models: z.ZodArray<z.ZodObject<{
|
|
1904
|
+
id: z.ZodString;
|
|
1905
|
+
displayName: z.ZodString;
|
|
1906
|
+
}, z.core.$strip>>;
|
|
1907
|
+
defaultModel: z.ZodString;
|
|
1908
|
+
apiKeyUrl: z.ZodOptional<z.ZodString>;
|
|
1909
|
+
apiKeyPlaceholder: z.ZodOptional<z.ZodString>;
|
|
1910
|
+
}, z.core.$strip>>>;
|
|
1911
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1912
|
+
type: z.ZodLiteral<"navigate_settings">;
|
|
1913
|
+
tab: z.ZodString;
|
|
1914
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1915
|
+
type: z.ZodLiteral<"notification_conversation_created">;
|
|
1916
|
+
conversationId: z.ZodString;
|
|
1917
|
+
title: z.ZodString;
|
|
1918
|
+
sourceEventName: z.ZodString;
|
|
1919
|
+
targetGuardianPrincipalId: z.ZodOptional<z.ZodString>;
|
|
1920
|
+
groupId: z.ZodOptional<z.ZodString>;
|
|
1921
|
+
source: z.ZodOptional<z.ZodString>;
|
|
1922
|
+
silent: z.ZodOptional<z.ZodBoolean>;
|
|
1923
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1924
|
+
type: z.ZodLiteral<"notification_intent">;
|
|
1925
|
+
sourceEventName: z.ZodString;
|
|
1926
|
+
title: z.ZodString;
|
|
1927
|
+
body: z.ZodString;
|
|
1928
|
+
deliveryId: z.ZodOptional<z.ZodString>;
|
|
1929
|
+
deepLinkMetadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
1930
|
+
targetGuardianPrincipalId: z.ZodOptional<z.ZodString>;
|
|
1931
|
+
silent: z.ZodOptional<z.ZodBoolean>;
|
|
1932
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1933
|
+
type: z.ZodLiteral<"oauth_connect_result">;
|
|
1934
|
+
success: z.ZodBoolean;
|
|
1935
|
+
service: z.ZodOptional<z.ZodString>;
|
|
1936
|
+
grantedScopes: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1937
|
+
accountInfo: z.ZodOptional<z.ZodString>;
|
|
1938
|
+
error: z.ZodOptional<z.ZodString>;
|
|
1939
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1940
|
+
type: z.ZodLiteral<"open_conversation">;
|
|
1941
|
+
conversationId: z.ZodString;
|
|
1942
|
+
title: z.ZodOptional<z.ZodString>;
|
|
1943
|
+
anchorMessageId: z.ZodOptional<z.ZodString>;
|
|
1944
|
+
focus: z.ZodOptional<z.ZodBoolean>;
|
|
1945
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1946
|
+
type: z.ZodLiteral<"open_panel">;
|
|
1947
|
+
panelType: z.ZodString;
|
|
1948
|
+
data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
1949
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
1950
|
+
surfaceId: z.ZodOptional<z.ZodString>;
|
|
1951
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1952
|
+
type: z.ZodLiteral<"open_url">;
|
|
1953
|
+
url: z.ZodString;
|
|
1954
|
+
title: z.ZodOptional<z.ZodString>;
|
|
1955
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
1956
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1957
|
+
type: z.ZodLiteral<"platform_disconnected">;
|
|
1958
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1959
|
+
type: z.ZodLiteral<"question_request">;
|
|
1960
|
+
requestId: z.ZodString;
|
|
1961
|
+
questions: z.ZodArray<z.ZodObject<{
|
|
1962
|
+
id: z.ZodString;
|
|
1963
|
+
question: z.ZodString;
|
|
1964
|
+
description: z.ZodOptional<z.ZodString>;
|
|
1965
|
+
options: z.ZodArray<z.ZodObject<{
|
|
1966
|
+
id: z.ZodString;
|
|
1967
|
+
label: z.ZodString;
|
|
1968
|
+
description: z.ZodOptional<z.ZodString>;
|
|
1969
|
+
}, z.core.$strip>>;
|
|
1970
|
+
freeTextPlaceholder: z.ZodOptional<z.ZodString>;
|
|
1971
|
+
}, z.core.$strip>>;
|
|
1972
|
+
question: z.ZodString;
|
|
1973
|
+
description: z.ZodOptional<z.ZodString>;
|
|
1974
|
+
options: z.ZodArray<z.ZodObject<{
|
|
1975
|
+
id: z.ZodString;
|
|
1976
|
+
label: z.ZodString;
|
|
1977
|
+
description: z.ZodOptional<z.ZodString>;
|
|
1978
|
+
}, z.core.$strip>>;
|
|
1979
|
+
freeTextPlaceholder: z.ZodOptional<z.ZodString>;
|
|
1980
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
1981
|
+
toolUseId: z.ZodOptional<z.ZodString>;
|
|
1982
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1983
|
+
type: z.ZodLiteral<"recording_pause">;
|
|
1984
|
+
recordingId: z.ZodString;
|
|
1985
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1986
|
+
type: z.ZodLiteral<"recording_resume">;
|
|
1987
|
+
recordingId: z.ZodString;
|
|
1988
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1989
|
+
type: z.ZodLiteral<"recording_start">;
|
|
1990
|
+
recordingId: z.ZodString;
|
|
1991
|
+
attachToConversationId: z.ZodOptional<z.ZodString>;
|
|
1992
|
+
options: z.ZodOptional<z.ZodObject<{
|
|
1993
|
+
captureScope: z.ZodOptional<z.ZodEnum<{
|
|
1994
|
+
display: "display";
|
|
1995
|
+
window: "window";
|
|
1996
|
+
}>>;
|
|
1997
|
+
displayId: z.ZodOptional<z.ZodString>;
|
|
1998
|
+
windowId: z.ZodOptional<z.ZodNumber>;
|
|
1999
|
+
includeAudio: z.ZodOptional<z.ZodBoolean>;
|
|
2000
|
+
includeMicrophone: z.ZodOptional<z.ZodBoolean>;
|
|
2001
|
+
promptForSource: z.ZodOptional<z.ZodBoolean>;
|
|
2002
|
+
}, z.core.$strip>>;
|
|
2003
|
+
operationToken: z.ZodOptional<z.ZodString>;
|
|
2004
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2005
|
+
type: z.ZodLiteral<"recording_stop">;
|
|
2006
|
+
recordingId: z.ZodString;
|
|
2007
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2008
|
+
type: z.ZodLiteral<"relationship_state_updated">;
|
|
2009
|
+
updatedAt: z.ZodString;
|
|
2010
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2011
|
+
type: z.ZodLiteral<"schedule_conversation_created">;
|
|
2012
|
+
conversationId: z.ZodString;
|
|
2013
|
+
scheduleJobId: z.ZodString;
|
|
2014
|
+
title: z.ZodString;
|
|
2015
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2016
|
+
type: z.ZodLiteral<"secret_request">;
|
|
2017
|
+
requestId: z.ZodString;
|
|
2018
|
+
service: z.ZodString;
|
|
2019
|
+
field: z.ZodString;
|
|
2020
|
+
label: z.ZodString;
|
|
2021
|
+
description: z.ZodOptional<z.ZodString>;
|
|
2022
|
+
placeholder: z.ZodOptional<z.ZodString>;
|
|
2023
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
2024
|
+
purpose: z.ZodOptional<z.ZodString>;
|
|
2025
|
+
allowedTools: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
2026
|
+
allowedDomains: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
2027
|
+
allowOneTimeSend: z.ZodOptional<z.ZodBoolean>;
|
|
2028
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2029
|
+
type: z.ZodLiteral<"service_group_update_complete">;
|
|
2030
|
+
installedVersion: z.ZodString;
|
|
2031
|
+
success: z.ZodBoolean;
|
|
2032
|
+
rolledBackToVersion: z.ZodOptional<z.ZodString>;
|
|
2033
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2034
|
+
type: z.ZodLiteral<"service_group_update_progress">;
|
|
2035
|
+
statusMessage: z.ZodString;
|
|
2036
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2037
|
+
type: z.ZodLiteral<"service_group_update_starting">;
|
|
2038
|
+
targetVersion: z.ZodString;
|
|
2039
|
+
expectedDowntimeSeconds: z.ZodNumber;
|
|
2040
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2041
|
+
type: z.ZodLiteral<"show_platform_login">;
|
|
2042
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2043
|
+
type: z.ZodLiteral<"skills_state_changed">;
|
|
2044
|
+
name: z.ZodString;
|
|
2045
|
+
state: z.ZodEnum<{
|
|
2046
|
+
enabled: "enabled";
|
|
2047
|
+
disabled: "disabled";
|
|
2048
|
+
installed: "installed";
|
|
2049
|
+
uninstalled: "uninstalled";
|
|
2050
|
+
}>;
|
|
2051
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2052
|
+
type: z.ZodLiteral<"sounds_config_updated">;
|
|
2053
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2054
|
+
type: z.ZodLiteral<"subagent_event">;
|
|
2055
|
+
conversationId: z.ZodString;
|
|
2056
|
+
subagentId: z.ZodString;
|
|
2057
|
+
event: z.ZodObject<{
|
|
2058
|
+
type: z.ZodString;
|
|
2059
|
+
content: z.ZodOptional<z.ZodString>;
|
|
2060
|
+
text: z.ZodOptional<z.ZodString>;
|
|
2061
|
+
result: z.ZodOptional<z.ZodString>;
|
|
2062
|
+
input: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
2063
|
+
toolName: z.ZodOptional<z.ZodString>;
|
|
2064
|
+
isError: z.ZodOptional<z.ZodBoolean>;
|
|
2065
|
+
toolUseId: z.ZodOptional<z.ZodString>;
|
|
2066
|
+
}, z.core.$loose>;
|
|
2067
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
2068
|
+
type: z.ZodLiteral<"subagent_spawned">;
|
|
2069
|
+
subagentId: z.ZodString;
|
|
2070
|
+
parentConversationId: z.ZodString;
|
|
2071
|
+
label: z.ZodString;
|
|
2072
|
+
objective: z.ZodString;
|
|
2073
|
+
isFork: z.ZodOptional<z.ZodBoolean>;
|
|
2074
|
+
parentToolUseId: z.ZodOptional<z.ZodString>;
|
|
2075
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
2076
|
+
type: z.ZodLiteral<"subagent_status_changed">;
|
|
2077
|
+
subagentId: z.ZodString;
|
|
2078
|
+
status: z.ZodEnum<{
|
|
2079
|
+
completed: "completed";
|
|
2080
|
+
failed: "failed";
|
|
2081
|
+
pending: "pending";
|
|
2082
|
+
running: "running";
|
|
2083
|
+
awaiting_input: "awaiting_input";
|
|
2084
|
+
aborted: "aborted";
|
|
2085
|
+
interrupted: "interrupted";
|
|
2086
|
+
}>;
|
|
2087
|
+
error: z.ZodOptional<z.ZodString>;
|
|
2088
|
+
usage: z.ZodOptional<z.ZodObject<{
|
|
2089
|
+
inputTokens: z.ZodNumber;
|
|
2090
|
+
outputTokens: z.ZodNumber;
|
|
2091
|
+
estimatedCost: z.ZodNumber;
|
|
2092
|
+
}, z.core.$strict>>;
|
|
2093
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
2094
|
+
type: z.ZodLiteral<"sync_changed">;
|
|
2095
|
+
tags: z.ZodArray<z.ZodString>;
|
|
2096
|
+
originClientId: z.ZodOptional<z.ZodString>;
|
|
2097
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2098
|
+
type: z.ZodLiteral<"tool_input_delta">;
|
|
2099
|
+
toolName: z.ZodString;
|
|
2100
|
+
content: z.ZodString;
|
|
2101
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
2102
|
+
toolUseId: z.ZodOptional<z.ZodString>;
|
|
2103
|
+
messageId: z.ZodOptional<z.ZodString>;
|
|
2104
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2105
|
+
type: z.ZodLiteral<"tool_output_chunk">;
|
|
2106
|
+
chunk: z.ZodString;
|
|
2107
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
2108
|
+
toolUseId: z.ZodOptional<z.ZodString>;
|
|
2109
|
+
subType: z.ZodOptional<z.ZodEnum<{
|
|
2110
|
+
status: "status";
|
|
2111
|
+
tool_start: "tool_start";
|
|
2112
|
+
tool_complete: "tool_complete";
|
|
2113
|
+
}>>;
|
|
2114
|
+
subToolName: z.ZodOptional<z.ZodString>;
|
|
2115
|
+
subToolInput: z.ZodOptional<z.ZodString>;
|
|
2116
|
+
subToolIsError: z.ZodOptional<z.ZodBoolean>;
|
|
2117
|
+
subToolId: z.ZodOptional<z.ZodString>;
|
|
2118
|
+
messageId: z.ZodOptional<z.ZodString>;
|
|
2119
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2120
|
+
type: z.ZodLiteral<"tool_result">;
|
|
2121
|
+
toolName: z.ZodString;
|
|
2122
|
+
result: z.ZodString;
|
|
2123
|
+
isError: z.ZodOptional<z.ZodBoolean>;
|
|
2124
|
+
diff: z.ZodOptional<z.ZodObject<{
|
|
2125
|
+
filePath: z.ZodString;
|
|
2126
|
+
oldContent: z.ZodString;
|
|
2127
|
+
newContent: z.ZodString;
|
|
2128
|
+
isNewFile: z.ZodBoolean;
|
|
2129
|
+
}, z.core.$strip>>;
|
|
2130
|
+
status: z.ZodOptional<z.ZodString>;
|
|
2131
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
2132
|
+
imageData: z.ZodOptional<z.ZodString>;
|
|
2133
|
+
imageDataList: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
2134
|
+
toolUseId: z.ZodOptional<z.ZodString>;
|
|
2135
|
+
messageId: z.ZodOptional<z.ZodString>;
|
|
2136
|
+
riskLevel: z.ZodOptional<z.ZodString>;
|
|
2137
|
+
riskReason: z.ZodOptional<z.ZodString>;
|
|
2138
|
+
matchedTrustRuleId: z.ZodOptional<z.ZodString>;
|
|
2139
|
+
isContainerized: z.ZodOptional<z.ZodBoolean>;
|
|
2140
|
+
riskScopeOptions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
2141
|
+
pattern: z.ZodString;
|
|
2142
|
+
label: z.ZodString;
|
|
2143
|
+
}, z.core.$strip>>>;
|
|
2144
|
+
riskAllowlistOptions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
2145
|
+
label: z.ZodString;
|
|
2146
|
+
description: z.ZodString;
|
|
2147
|
+
pattern: z.ZodString;
|
|
2148
|
+
}, z.core.$strip>>>;
|
|
2149
|
+
riskDirectoryScopeOptions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
2150
|
+
label: z.ZodString;
|
|
2151
|
+
scope: z.ZodString;
|
|
2152
|
+
}, z.core.$strip>>>;
|
|
2153
|
+
approvalMode: z.ZodOptional<z.ZodString>;
|
|
2154
|
+
approvalReason: z.ZodOptional<z.ZodString>;
|
|
2155
|
+
riskThreshold: z.ZodOptional<z.ZodString>;
|
|
2156
|
+
activityMetadata: z.ZodOptional<z.ZodObject<{
|
|
2157
|
+
webSearch: z.ZodOptional<z.ZodObject<{
|
|
2158
|
+
query: z.ZodString;
|
|
2159
|
+
provider: z.ZodEnum<{
|
|
2160
|
+
"anthropic-native": "anthropic-native";
|
|
2161
|
+
brave: "brave";
|
|
2162
|
+
perplexity: "perplexity";
|
|
2163
|
+
tavily: "tavily";
|
|
2164
|
+
firecrawl: "firecrawl";
|
|
2165
|
+
}>;
|
|
2166
|
+
resultCount: z.ZodNumber;
|
|
2167
|
+
durationMs: z.ZodNumber;
|
|
2168
|
+
results: z.ZodArray<z.ZodObject<{
|
|
2169
|
+
rank: z.ZodNumber;
|
|
2170
|
+
title: z.ZodString;
|
|
2171
|
+
url: z.ZodString;
|
|
2172
|
+
domain: z.ZodString;
|
|
2173
|
+
faviconUrl: z.ZodOptional<z.ZodString>;
|
|
2174
|
+
snippet: z.ZodOptional<z.ZodString>;
|
|
2175
|
+
age: z.ZodOptional<z.ZodString>;
|
|
2176
|
+
score: z.ZodOptional<z.ZodNumber>;
|
|
2177
|
+
}, z.core.$strip>>;
|
|
2178
|
+
errorMessage: z.ZodOptional<z.ZodString>;
|
|
2179
|
+
}, z.core.$strip>>;
|
|
2180
|
+
webFetch: z.ZodOptional<z.ZodObject<{
|
|
2181
|
+
url: z.ZodString;
|
|
2182
|
+
finalUrl: z.ZodString;
|
|
2183
|
+
provider: z.ZodOptional<z.ZodEnum<{
|
|
2184
|
+
default: "default";
|
|
2185
|
+
firecrawl: "firecrawl";
|
|
2186
|
+
}>>;
|
|
2187
|
+
status: z.ZodNumber;
|
|
2188
|
+
contentType: z.ZodOptional<z.ZodString>;
|
|
2189
|
+
byteCount: z.ZodNumber;
|
|
2190
|
+
charCount: z.ZodNumber;
|
|
2191
|
+
truncated: z.ZodBoolean;
|
|
2192
|
+
title: z.ZodOptional<z.ZodString>;
|
|
2193
|
+
domain: z.ZodString;
|
|
2194
|
+
faviconUrl: z.ZodOptional<z.ZodString>;
|
|
2195
|
+
redirectCount: z.ZodNumber;
|
|
2196
|
+
durationMs: z.ZodNumber;
|
|
2197
|
+
errorMessage: z.ZodOptional<z.ZodString>;
|
|
2198
|
+
mayRequireJavaScript: z.ZodOptional<z.ZodBoolean>;
|
|
2199
|
+
}, z.core.$strip>>;
|
|
2200
|
+
}, z.core.$strip>>;
|
|
2201
|
+
errorCode: z.ZodOptional<z.ZodString>;
|
|
2202
|
+
completedAt: z.ZodOptional<z.ZodNumber>;
|
|
2203
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2204
|
+
type: z.ZodLiteral<"tool_use_preview_start">;
|
|
2205
|
+
toolUseId: z.ZodString;
|
|
2206
|
+
toolName: z.ZodString;
|
|
2207
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
2208
|
+
messageId: z.ZodOptional<z.ZodString>;
|
|
2209
|
+
previewStartedAt: z.ZodOptional<z.ZodNumber>;
|
|
2210
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2211
|
+
type: z.ZodLiteral<"tool_use_start">;
|
|
2212
|
+
toolName: z.ZodString;
|
|
2213
|
+
input: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
2214
|
+
toolUseId: z.ZodOptional<z.ZodString>;
|
|
2215
|
+
messageId: z.ZodOptional<z.ZodString>;
|
|
2216
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
2217
|
+
startedAt: z.ZodOptional<z.ZodNumber>;
|
|
2218
|
+
previewStartedAt: z.ZodOptional<z.ZodNumber>;
|
|
2219
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2220
|
+
type: z.ZodLiteral<"ui_surface_complete">;
|
|
2221
|
+
conversationId: z.ZodString;
|
|
2222
|
+
surfaceId: z.ZodString;
|
|
2223
|
+
summary: z.ZodString;
|
|
2224
|
+
submittedData: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
2225
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2226
|
+
type: z.ZodLiteral<"ui_surface_dismiss">;
|
|
2227
|
+
conversationId: z.ZodString;
|
|
2228
|
+
surfaceId: z.ZodString;
|
|
2229
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2230
|
+
type: z.ZodLiteral<"ui_surface_show">;
|
|
2231
|
+
conversationId: z.ZodString;
|
|
2232
|
+
surfaceId: z.ZodString;
|
|
2233
|
+
surfaceType: z.ZodString;
|
|
2234
|
+
title: z.ZodOptional<z.ZodString>;
|
|
2235
|
+
data: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
2236
|
+
actions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
2237
|
+
id: z.ZodString;
|
|
2238
|
+
label: z.ZodString;
|
|
2239
|
+
style: z.ZodOptional<z.ZodEnum<{
|
|
2240
|
+
primary: "primary";
|
|
2241
|
+
secondary: "secondary";
|
|
2242
|
+
destructive: "destructive";
|
|
2243
|
+
}>>;
|
|
2244
|
+
data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
2245
|
+
}, z.core.$strip>>>;
|
|
2246
|
+
display: z.ZodOptional<z.ZodEnum<{
|
|
2247
|
+
inline: "inline";
|
|
2248
|
+
panel: "panel";
|
|
2249
|
+
}>>;
|
|
2250
|
+
messageId: z.ZodOptional<z.ZodString>;
|
|
2251
|
+
persistent: z.ZodOptional<z.ZodBoolean>;
|
|
2252
|
+
toolCallId: z.ZodOptional<z.ZodString>;
|
|
2253
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2254
|
+
type: z.ZodLiteral<"ui_surface_undo_result">;
|
|
2255
|
+
conversationId: z.ZodString;
|
|
2256
|
+
surfaceId: z.ZodString;
|
|
2257
|
+
success: z.ZodBoolean;
|
|
2258
|
+
remainingUndos: z.ZodNumber;
|
|
2259
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2260
|
+
type: z.ZodLiteral<"ui_surface_update">;
|
|
2261
|
+
conversationId: z.ZodString;
|
|
2262
|
+
surfaceId: z.ZodString;
|
|
2263
|
+
data: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
2264
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2265
|
+
type: z.ZodLiteral<"usage_progress">;
|
|
2266
|
+
conversationId: z.ZodString;
|
|
2267
|
+
inputTokens: z.ZodNumber;
|
|
2268
|
+
outputTokens: z.ZodNumber;
|
|
2269
|
+
estimatedCost: z.ZodNumber;
|
|
2270
|
+
model: z.ZodString;
|
|
2271
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2272
|
+
type: z.ZodLiteral<"usage_update">;
|
|
2273
|
+
conversationId: z.ZodString;
|
|
2274
|
+
inputTokens: z.ZodNumber;
|
|
2275
|
+
outputTokens: z.ZodNumber;
|
|
2276
|
+
cacheCreationInputTokens: z.ZodOptional<z.ZodNumber>;
|
|
2277
|
+
cacheReadInputTokens: z.ZodOptional<z.ZodNumber>;
|
|
2278
|
+
totalInputTokens: z.ZodNumber;
|
|
2279
|
+
totalOutputTokens: z.ZodNumber;
|
|
2280
|
+
estimatedCost: z.ZodNumber;
|
|
2281
|
+
model: z.ZodString;
|
|
2282
|
+
contextWindowTokens: z.ZodOptional<z.ZodNumber>;
|
|
2283
|
+
contextWindowMaxTokens: z.ZodOptional<z.ZodNumber>;
|
|
2284
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
2285
|
+
type: z.ZodLiteral<"user_message_echo">;
|
|
2286
|
+
text: z.ZodString;
|
|
2287
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
2288
|
+
messageId: z.ZodOptional<z.ZodString>;
|
|
2289
|
+
requestId: z.ZodOptional<z.ZodString>;
|
|
2290
|
+
clientMessageId: z.ZodOptional<z.ZodString>;
|
|
2291
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
2292
|
+
type: z.ZodLiteral<"workflow_completed">;
|
|
2293
|
+
runId: z.ZodString;
|
|
2294
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
2295
|
+
status: z.ZodEnum<{
|
|
2296
|
+
completed: "completed";
|
|
2297
|
+
failed: "failed";
|
|
2298
|
+
running: "running";
|
|
2299
|
+
aborted: "aborted";
|
|
2300
|
+
interrupted: "interrupted";
|
|
2301
|
+
cap_exceeded: "cap_exceeded";
|
|
2302
|
+
}>;
|
|
2303
|
+
agentsSpawned: z.ZodNumber;
|
|
2304
|
+
inputTokens: z.ZodNumber;
|
|
2305
|
+
outputTokens: z.ZodNumber;
|
|
2306
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
2307
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
2308
|
+
type: z.ZodLiteral<"workflow_leaf_finished">;
|
|
2309
|
+
runId: z.ZodString;
|
|
2310
|
+
conversationId: z.ZodString;
|
|
2311
|
+
seq: z.ZodNumber;
|
|
2312
|
+
status: z.ZodEnum<{
|
|
2313
|
+
completed: "completed";
|
|
2314
|
+
failed: "failed";
|
|
2315
|
+
}>;
|
|
2316
|
+
label: z.ZodOptional<z.ZodString>;
|
|
2317
|
+
inputTokens: z.ZodOptional<z.ZodNumber>;
|
|
2318
|
+
outputTokens: z.ZodOptional<z.ZodNumber>;
|
|
2319
|
+
resultSummary: z.ZodOptional<z.ZodString>;
|
|
2320
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
2321
|
+
type: z.ZodLiteral<"workflow_leaf_started">;
|
|
2322
|
+
runId: z.ZodString;
|
|
2323
|
+
conversationId: z.ZodString;
|
|
2324
|
+
seq: z.ZodNumber;
|
|
2325
|
+
label: z.ZodOptional<z.ZodString>;
|
|
2326
|
+
phase: z.ZodOptional<z.ZodString>;
|
|
2327
|
+
promptSummary: z.ZodOptional<z.ZodString>;
|
|
2328
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
2329
|
+
type: z.ZodLiteral<"workflow_progress">;
|
|
2330
|
+
runId: z.ZodString;
|
|
2331
|
+
conversationId: z.ZodOptional<z.ZodString>;
|
|
2332
|
+
agentsSpawned: z.ZodNumber;
|
|
2333
|
+
phase: z.ZodOptional<z.ZodString>;
|
|
2334
|
+
label: z.ZodOptional<z.ZodString>;
|
|
2335
|
+
message: z.ZodOptional<z.ZodString>;
|
|
2336
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
2337
|
+
type: z.ZodLiteral<"workflow_started">;
|
|
2338
|
+
runId: z.ZodString;
|
|
2339
|
+
conversationId: z.ZodString;
|
|
2340
|
+
toolUseId: z.ZodOptional<z.ZodString>;
|
|
2341
|
+
label: z.ZodOptional<z.ZodString>;
|
|
2342
|
+
}, z.core.$strict>], "type">;
|
|
2343
|
+
}, z.core.$strip>;
|
|
2344
|
+
|
|
2345
|
+
/** Filter that determines which events a subscriber receives. */
|
|
2346
|
+
export declare type AssistantEventFilter = {
|
|
2347
|
+
/** When set, restrict delivery to events for this conversation. */
|
|
2348
|
+
conversationId?: string;
|
|
2349
|
+
};
|
|
2350
|
+
|
|
2351
|
+
/**
|
|
2352
|
+
* Lightweight pub/sub hub for `AssistantEvent` messages.
|
|
2353
|
+
*
|
|
2354
|
+
* Filtering is applied at subscription level:
|
|
2355
|
+
* - `conversationId`: scoped events match subscribers with same conversationId
|
|
2356
|
+
* or no conversationId filter (broadcast to all).
|
|
2357
|
+
* - `targetCapability` (on publish): targeted events only reach subscribers
|
|
2358
|
+
* whose capabilities include the target. Untargeted events fan out to all.
|
|
2359
|
+
*
|
|
2360
|
+
* Client connections register as subscribers with metadata and are queryable
|
|
2361
|
+
* via `listClients()`, `getMostRecentClientByCapability()`, etc.
|
|
2362
|
+
*/
|
|
2363
|
+
export declare class AssistantEventHub {
|
|
2364
|
+
private readonly subscribers;
|
|
2365
|
+
private readonly maxSubscribers;
|
|
2366
|
+
/** Monotonic source for per-connection ids, scoped to this hub. */
|
|
2367
|
+
private connectionCounter;
|
|
2368
|
+
constructor(options?: {
|
|
2369
|
+
maxSubscribers?: number;
|
|
2370
|
+
});
|
|
2371
|
+
/**
|
|
2372
|
+
* Register a subscriber that will be called for each matching event.
|
|
2373
|
+
*
|
|
2374
|
+
* **Client deduplication:** When a client subscriber is registered with a
|
|
2375
|
+
* `clientId` that already exists, all stale entries for that clientId are
|
|
2376
|
+
* disposed first. This prevents subscriber stacking when clients reconnect
|
|
2377
|
+
* (e.g. Chrome extension reload, SSE token refresh) before the old
|
|
2378
|
+
* connection's abort signal fires.
|
|
2379
|
+
*
|
|
2380
|
+
* When the subscriber cap (`maxSubscribers`) has been reached, the **oldest**
|
|
2381
|
+
* subscriber is evicted to make room: its `onEvict` callback is invoked (so
|
|
2382
|
+
* it can close its SSE stream) and its entry is removed from the hub.
|
|
2383
|
+
*/
|
|
2384
|
+
subscribe(subscriber: SubscriberInput): AssistantEventSubscription;
|
|
2385
|
+
/**
|
|
2386
|
+
* Publish an event to all matching subscribers.
|
|
2387
|
+
*
|
|
2388
|
+
* Matching rules:
|
|
2389
|
+
* - if `excludeClientId` is set, the subscriber with that clientId is
|
|
2390
|
+
* skipped regardless of every other rule (self-echo suppression — the
|
|
2391
|
+
* client that originated the mutation does not receive its own
|
|
2392
|
+
* invalidation back through the hub).
|
|
2393
|
+
* - if `targetClientId` is set, deliver only to the subscriber with that
|
|
2394
|
+
* clientId, bypassing the conversation-id filter entirely (the web-origin
|
|
2395
|
+
* event's conversationId differs from the macOS client's subscribed
|
|
2396
|
+
* conversation).
|
|
2397
|
+
* - if `filter.conversationId` is set (and `targetClientId` is not), the
|
|
2398
|
+
* `event.conversationId` must equal it
|
|
2399
|
+
* - if `targetCapability` is set, only subscribers whose capabilities include
|
|
2400
|
+
* it receive the event; untargeted events go to all
|
|
2401
|
+
* - if `targetInterfaceId` is set, only client subscribers whose
|
|
2402
|
+
* `interfaceId` matches receive the event; process subscribers and
|
|
2403
|
+
* non-matching clients are skipped. Used to narrow legacy
|
|
2404
|
+
* broadcasts (e.g. `conversation_list_invalidated`) to a specific
|
|
2405
|
+
* client surface during a migration window.
|
|
2406
|
+
*
|
|
2407
|
+
* Fanout is isolated: a throwing or rejecting subscriber does not abort
|
|
2408
|
+
* delivery to remaining subscribers.
|
|
2409
|
+
*/
|
|
2410
|
+
publish(event: AssistantEvent, options?: {
|
|
2411
|
+
targetCapability?: HostProxyCapability;
|
|
2412
|
+
targetClientId?: string;
|
|
2413
|
+
targetInterfaceId?: InterfaceId;
|
|
2414
|
+
/**
|
|
2415
|
+
* Skip the subscriber with this `clientId`. Used for self-echo
|
|
2416
|
+
* suppression on `sync_changed`: the route handler echoes the
|
|
2417
|
+
* originating tab's `X-Vellum-Client-Id` back on the event, and the
|
|
2418
|
+
* hub uses it here to avoid re-delivering the invalidation to the
|
|
2419
|
+
* tab that already mutated its own optimistic state.
|
|
2420
|
+
*/
|
|
2421
|
+
excludeClientId?: string;
|
|
2422
|
+
}): Promise<void>;
|
|
2423
|
+
/**
|
|
2424
|
+
* Return the active client subscriber with the given clientId, or
|
|
2425
|
+
* `undefined` if no such subscriber exists.
|
|
2426
|
+
*/
|
|
2427
|
+
getClientById(clientId: string): ClientEntry | undefined;
|
|
2428
|
+
/**
|
|
2429
|
+
* Return the verified actor principal id captured at SSE subscription time
|
|
2430
|
+
* for the given client, or `undefined` if the client is unknown or
|
|
2431
|
+
* connected without a principal (e.g. legacy/service tokens).
|
|
2432
|
+
*
|
|
2433
|
+
* Used by host proxies to bind cross-client targeted execution to the same
|
|
2434
|
+
* authenticated user identity that opened the target client's SSE stream.
|
|
2435
|
+
*/
|
|
2436
|
+
getActorPrincipalIdForClient(clientId: string): string | undefined;
|
|
2437
|
+
/**
|
|
2438
|
+
* Returns true when at least one active subscriber would receive the given
|
|
2439
|
+
* event based on the same conversation matching rules as publish().
|
|
2440
|
+
*/
|
|
2441
|
+
hasSubscribersForEvent(event: Pick<AssistantEvent, "conversationId">): boolean;
|
|
2442
|
+
private clientEntries;
|
|
2443
|
+
/**
|
|
2444
|
+
* Return all active client subscribers, sorted by `lastActiveAt` descending.
|
|
2445
|
+
*/
|
|
2446
|
+
listClients(): ClientEntry[];
|
|
2447
|
+
/**
|
|
2448
|
+
* Return all client subscribers that support the given capability,
|
|
2449
|
+
* sorted by `lastActiveAt` descending.
|
|
2450
|
+
*/
|
|
2451
|
+
listClientsByCapability(capability: HostProxyCapability): ClientEntry[];
|
|
2452
|
+
/**
|
|
2453
|
+
* Return the most recently active client that supports the given
|
|
2454
|
+
* capability, or `undefined` if none exists.
|
|
2455
|
+
*/
|
|
2456
|
+
getMostRecentClientByCapability(capability: HostProxyCapability): ClientEntry | undefined;
|
|
2457
|
+
/**
|
|
2458
|
+
* Return all client subscribers with the given interface type,
|
|
2459
|
+
* sorted by `lastActiveAt` descending.
|
|
2460
|
+
*/
|
|
2461
|
+
listClientsByInterface(interfaceId: InterfaceId): ClientEntry[];
|
|
2462
|
+
/**
|
|
2463
|
+
* Touch a client subscriber — update `lastActiveAt`. Used by heartbeat.
|
|
2464
|
+
*/
|
|
2465
|
+
touchClient(clientId: string): void;
|
|
2466
|
+
/**
|
|
2467
|
+
* Force-disconnect a client by disposing all subscribers for the given
|
|
2468
|
+
* `clientId`. Returns the number of disposed entries.
|
|
2469
|
+
*
|
|
2470
|
+
* Used by `assistant clients disconnect <clientId>` to forcibly remove
|
|
2471
|
+
* stale or unwanted client connections.
|
|
2472
|
+
*/
|
|
2473
|
+
disposeClient(clientId: string): number;
|
|
2474
|
+
/** Number of currently active subscribers (useful for tests and caps). */
|
|
2475
|
+
subscriberCount(): number;
|
|
2476
|
+
/** Returns true if the hub can accept a subscriber without evicting anyone. */
|
|
2477
|
+
hasCapacity(): boolean;
|
|
2478
|
+
}
|
|
2479
|
+
|
|
2480
|
+
/** The plugin-facing event hub. See module docs. */
|
|
2481
|
+
export declare const assistantEventHub: PluginEventHub;
|
|
2482
|
+
|
|
2483
|
+
/** Opaque handle returned by `subscribe`. Call `dispose()` to remove the subscription. */
|
|
2484
|
+
export declare interface AssistantEventSubscription {
|
|
2485
|
+
dispose(): void;
|
|
2486
|
+
/** True until `dispose()` has been called. */
|
|
2487
|
+
readonly active: boolean;
|
|
2488
|
+
/**
|
|
2489
|
+
* Per-connection identifier, unique within the hub instance. Distinguishes
|
|
2490
|
+
* connections that share a `clientId` (e.g. an old connection and the new
|
|
2491
|
+
* one that replaced it on reconnect) so subscribe / dispose / shed log
|
|
2492
|
+
* lines can be attributed to a specific connection.
|
|
2493
|
+
*/
|
|
2494
|
+
readonly connectionId: string;
|
|
2495
|
+
}
|
|
2496
|
+
|
|
2497
|
+
declare interface AudioEmbeddingInput {
|
|
2498
|
+
type: "audio";
|
|
2499
|
+
data: Buffer;
|
|
2500
|
+
mimeType: string;
|
|
2501
|
+
}
|
|
2502
|
+
|
|
2503
|
+
/**
|
|
2504
|
+
* Media payload for an image or file content block. One unified type covers
|
|
2505
|
+
* both blocks and both storage forms:
|
|
2506
|
+
*
|
|
2507
|
+
* - `base64` — the bytes travel inline with the block. This is the runtime
|
|
2508
|
+
* shape the provider transforms consume and the shape produced for a live
|
|
2509
|
+
* (in-flight) turn.
|
|
2510
|
+
* - `workspace_ref` — the bytes live somewhere in the workspace, not inline.
|
|
2511
|
+
* This is the shape PERSISTED into `messages.content`, keeping large blobs
|
|
2512
|
+
* out of the DB row and the lexical index. It is resolved back to inline
|
|
2513
|
+
* bytes at the provider send boundary (`providers/media-resolve.ts`); any
|
|
2514
|
+
* consumer that needs the raw bytes from stored content resolves it with
|
|
2515
|
+
* `resolveMediaSourceData(source)`.
|
|
2516
|
+
*
|
|
2517
|
+
* `filename` is optional on both arms (present for file blocks and for
|
|
2518
|
+
* generated-media references). For references, `sizeBytes` (and, for images,
|
|
2519
|
+
* `width`/`height`) are captured at persist time so size-only consumers — the
|
|
2520
|
+
* per-turn token estimator especially — can cost the block without reading the
|
|
2521
|
+
* file back off disk.
|
|
2522
|
+
*/
|
|
2523
|
+
declare interface Base64MediaSource {
|
|
2524
|
+
type: "base64";
|
|
2525
|
+
media_type: string;
|
|
2526
|
+
data: string;
|
|
2527
|
+
filename?: string;
|
|
2528
|
+
}
|
|
2529
|
+
|
|
2530
|
+
/**
|
|
2531
|
+
* Capabilities shared by every chain-hook context (`user-prompt-submit`,
|
|
2532
|
+
* `post-compact`, `post-tool-use`, `stop`, `pre-model-call`,
|
|
2533
|
+
* `post-model-call`).
|
|
2534
|
+
*
|
|
2535
|
+
* Both are stamped onto each hook's draft by the pipeline (`runHook`) before
|
|
2536
|
+
* the hook runs, bound to that hook's identity — dispatching call sites
|
|
2537
|
+
* construct the `XInputContext` shapes and never supply these.
|
|
2538
|
+
*/
|
|
2539
|
+
declare interface BaseHookContext {
|
|
2540
|
+
/**
|
|
2541
|
+
* Logger bound to the emitting hook — pre-tagged with the hook name and
|
|
2542
|
+
* owning plugin (plus `conversationId` / `requestId` when the dispatching
|
|
2543
|
+
* context carries them), so hook log lines are attributed without manual
|
|
2544
|
+
* tagging.
|
|
2545
|
+
*/
|
|
2546
|
+
readonly logger: PluginLogger;
|
|
2547
|
+
/**
|
|
2548
|
+
* Per-hook `hook_event` emitter, bound to this hook's owner — see
|
|
2549
|
+
* {@link HookBroadcast}.
|
|
2550
|
+
*/
|
|
2551
|
+
readonly broadcast: HookBroadcast;
|
|
1563
2552
|
}
|
|
1564
2553
|
|
|
1565
2554
|
declare interface BaseSubscriberEntry {
|
|
@@ -1578,31 +2567,6 @@ declare interface BaseSubscriberEntry {
|
|
|
1578
2567
|
connectionId: string;
|
|
1579
2568
|
}
|
|
1580
2569
|
|
|
1581
|
-
declare type BookmarkCreatedEvent = z.infer<typeof BookmarkCreatedEventSchema>;
|
|
1582
|
-
|
|
1583
|
-
declare const BookmarkCreatedEventSchema: z.ZodObject<{
|
|
1584
|
-
type: z.ZodLiteral<"bookmark.created">;
|
|
1585
|
-
bookmark: z.ZodObject<{
|
|
1586
|
-
id: z.ZodString;
|
|
1587
|
-
messageId: z.ZodString;
|
|
1588
|
-
conversationId: z.ZodString;
|
|
1589
|
-
conversationTitle: z.ZodNullable<z.ZodString>;
|
|
1590
|
-
messagePreview: z.ZodString;
|
|
1591
|
-
messageRole: z.ZodString;
|
|
1592
|
-
messageCreatedAt: z.ZodNumber;
|
|
1593
|
-
createdAt: z.ZodNumber;
|
|
1594
|
-
}, z.core.$strip>;
|
|
1595
|
-
}, z.core.$strip>;
|
|
1596
|
-
|
|
1597
|
-
declare type BookmarkDeletedEvent = z.infer<typeof BookmarkDeletedEventSchema>;
|
|
1598
|
-
|
|
1599
|
-
declare const BookmarkDeletedEventSchema: z.ZodObject<{
|
|
1600
|
-
type: z.ZodLiteral<"bookmark.deleted">;
|
|
1601
|
-
messageId: z.ZodString;
|
|
1602
|
-
}, z.core.$strip>;
|
|
1603
|
-
|
|
1604
|
-
declare type _BookmarksServerMessages = BookmarkCreatedEvent | BookmarkDeletedEvent;
|
|
1605
|
-
|
|
1606
2570
|
/**
|
|
1607
2571
|
* Build a model-facing excerpt of stored message content around a query,
|
|
1608
2572
|
* preserving external-content envelopes so third-party boundaries stay
|
|
@@ -1610,68 +2574,6 @@ declare type _BookmarksServerMessages = BookmarkCreatedEvent | BookmarkDeletedEv
|
|
|
1610
2574
|
*/
|
|
1611
2575
|
export declare function buildMessageExcerpt(rawContent: string, query: string): Promise<string>;
|
|
1612
2576
|
|
|
1613
|
-
/**
|
|
1614
|
-
* Canonical channel-id vocabulary shared between the assistant daemon and the
|
|
1615
|
-
* gateway.
|
|
1616
|
-
*
|
|
1617
|
-
* A "channel" is an external messaging surface an actor can reach the
|
|
1618
|
-
* assistant through (Slack, Telegram, WhatsApp, phone, …) plus a couple of
|
|
1619
|
-
* internal ids (`vellum` for native app conversations, `platform` for the
|
|
1620
|
-
* internal control plane). This is the single source of truth for that set:
|
|
1621
|
-
* the assistant adopts it wholesale as its `ChannelId`, and the gateway
|
|
1622
|
-
* asserts its own (narrower) inbound list is a subset of it so the two sides
|
|
1623
|
-
* cannot silently drift.
|
|
1624
|
-
*
|
|
1625
|
-
* Both packages depend on `@vellumai/service-contracts`, so hoisting the set
|
|
1626
|
-
* here (rather than maintaining a copy on each side) means adding or renaming
|
|
1627
|
-
* a channel happens in exactly one place.
|
|
1628
|
-
*
|
|
1629
|
-
* Note that a consumer may legitimately handle only a *subset* of these — the
|
|
1630
|
-
* gateway, for example, never ingresses `platform`. Use a local list guarded
|
|
1631
|
-
* by `satisfies readonly ChannelId[]` for those cases rather than redefining
|
|
1632
|
-
* the union.
|
|
1633
|
-
*/
|
|
1634
|
-
declare const CHANNEL_IDS: readonly ["telegram", "phone", "vellum", "whatsapp", "slack", "email", "platform", "a2a"];
|
|
1635
|
-
|
|
1636
|
-
declare type ChannelId = (typeof CHANNEL_IDS)[number];
|
|
1637
|
-
|
|
1638
|
-
declare interface ChannelVerificationSessionResponse {
|
|
1639
|
-
type: "channel_verification_session_response";
|
|
1640
|
-
success: boolean;
|
|
1641
|
-
secret?: string;
|
|
1642
|
-
instruction?: string;
|
|
1643
|
-
/** Present when action is 'status'. */
|
|
1644
|
-
bound?: boolean;
|
|
1645
|
-
guardianExternalUserId?: string;
|
|
1646
|
-
/** The channel this status pertains to (e.g. "telegram", "phone"). Present when action is 'status'. */
|
|
1647
|
-
channel?: ChannelId;
|
|
1648
|
-
/** The assistant ID scoped to this status. Present when action is 'status'. */
|
|
1649
|
-
assistantId?: string;
|
|
1650
|
-
/** The delivery chat ID for the guardian (e.g. Telegram chat ID). Present when action is 'status' and bound is true. */
|
|
1651
|
-
guardianDeliveryChatId?: string;
|
|
1652
|
-
/** Optional channel username/handle for the bound guardian (for UI display). */
|
|
1653
|
-
guardianUsername?: string;
|
|
1654
|
-
/** Optional display name for the bound guardian (for UI display). */
|
|
1655
|
-
guardianDisplayName?: string;
|
|
1656
|
-
/** Whether a pending verification challenge exists for this (assistantId, channel). Used by relay setup to detect active voice verification sessions. */
|
|
1657
|
-
hasPendingChallenge?: boolean;
|
|
1658
|
-
error?: string;
|
|
1659
|
-
/** Human-readable error detail (e.g. for already_bound failures). */
|
|
1660
|
-
message?: string;
|
|
1661
|
-
/** Conversation ID for outbound verification flows. */
|
|
1662
|
-
verificationSessionId?: string;
|
|
1663
|
-
/** Epoch ms when the verification session expires. */
|
|
1664
|
-
expiresAt?: number;
|
|
1665
|
-
/** Epoch ms after which a resend is allowed. */
|
|
1666
|
-
nextResendAt?: number;
|
|
1667
|
-
/** Number of sends for this session. */
|
|
1668
|
-
sendCount?: number;
|
|
1669
|
-
/** Telegram deep-link URL for bootstrap (M3 placeholder). */
|
|
1670
|
-
telegramBootstrapUrl?: string;
|
|
1671
|
-
/** True when the outbound session is still in pending_bootstrap state (Telegram handle flow). Prevents the client from clearing the bootstrap URL during status polling. */
|
|
1672
|
-
pendingBootstrap?: boolean;
|
|
1673
|
-
}
|
|
1674
|
-
|
|
1675
2577
|
export declare const CLI_COMMAND_HELP: readonly CliCommandHelp[];
|
|
1676
2578
|
|
|
1677
2579
|
declare interface CliArgumentHelp {
|
|
@@ -1729,14 +2631,6 @@ declare interface ClientEntry extends BaseSubscriberEntry {
|
|
|
1729
2631
|
actorPrincipalId?: string;
|
|
1730
2632
|
}
|
|
1731
2633
|
|
|
1732
|
-
declare type ClientSettingsUpdateEvent = z.infer<typeof ClientSettingsUpdateEventSchema>;
|
|
1733
|
-
|
|
1734
|
-
declare const ClientSettingsUpdateEventSchema: z.ZodObject<{
|
|
1735
|
-
type: z.ZodLiteral<"client_settings_update">;
|
|
1736
|
-
key: z.ZodString;
|
|
1737
|
-
value: z.ZodString;
|
|
1738
|
-
}, z.core.$strip>;
|
|
1739
|
-
|
|
1740
2634
|
declare interface CliOptionHelp {
|
|
1741
2635
|
/** Commander flag spec, e.g. `"--path <file>"` or `"-l, --limit <n>"`. */
|
|
1742
2636
|
flags: string;
|
|
@@ -1770,147 +2664,10 @@ declare interface CliSubcommandHelp {
|
|
|
1770
2664
|
subcommands?: CliSubcommandHelp[];
|
|
1771
2665
|
}
|
|
1772
2666
|
|
|
1773
|
-
declare type CompactionCircuitClosedEvent = z.infer<typeof CompactionCircuitClosedEventSchema>;
|
|
1774
|
-
|
|
1775
|
-
declare const CompactionCircuitClosedEventSchema: z.ZodObject<{
|
|
1776
|
-
type: z.ZodLiteral<"compaction_circuit_closed">;
|
|
1777
|
-
conversationId: z.ZodString;
|
|
1778
|
-
}, z.core.$strip>;
|
|
1779
|
-
|
|
1780
|
-
declare type CompactionCircuitOpenEvent = z.infer<typeof CompactionCircuitOpenEventSchema>;
|
|
1781
|
-
|
|
1782
|
-
declare const CompactionCircuitOpenEventSchema: z.ZodObject<{
|
|
1783
|
-
type: z.ZodLiteral<"compaction_circuit_open">;
|
|
1784
|
-
conversationId: z.ZodString;
|
|
1785
|
-
reason: z.ZodLiteral<"3_consecutive_failures">;
|
|
1786
|
-
openUntil: z.ZodNumber;
|
|
1787
|
-
}, z.core.$strip>;
|
|
1788
|
-
|
|
1789
|
-
declare type _ComputerUseServerMessages = RecordingStartEvent | RecordingStopEvent | RecordingPauseEvent | RecordingResumeEvent;
|
|
1790
|
-
|
|
1791
|
-
declare type ConfigChangedEvent = z.infer<typeof ConfigChangedEventSchema>;
|
|
1792
|
-
|
|
1793
|
-
declare const ConfigChangedEventSchema: z.ZodObject<{
|
|
1794
|
-
type: z.ZodLiteral<"config_changed">;
|
|
1795
|
-
}, z.core.$strip>;
|
|
1796
|
-
|
|
1797
2667
|
declare type ConfiguredProviderOptions = Pick<ResolveCallSiteOpts, "overrideProfile" | "forceOverrideProfile" | "selectionSeed">;
|
|
1798
2668
|
|
|
1799
|
-
declare type ConfirmationRequestEvent = z.infer<typeof ConfirmationRequestEventSchema>;
|
|
1800
|
-
|
|
1801
|
-
declare const ConfirmationRequestEventSchema: z.ZodObject<{
|
|
1802
|
-
type: z.ZodLiteral<"confirmation_request">;
|
|
1803
|
-
requestId: z.ZodString;
|
|
1804
|
-
toolName: z.ZodString;
|
|
1805
|
-
input: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
1806
|
-
riskLevel: z.ZodString;
|
|
1807
|
-
riskReason: z.ZodOptional<z.ZodString>;
|
|
1808
|
-
isContainerized: z.ZodOptional<z.ZodBoolean>;
|
|
1809
|
-
executionTarget: z.ZodOptional<z.ZodEnum<{
|
|
1810
|
-
sandbox: "sandbox";
|
|
1811
|
-
host: "host";
|
|
1812
|
-
}>>;
|
|
1813
|
-
allowlistOptions: z.ZodArray<z.ZodObject<{
|
|
1814
|
-
label: z.ZodString;
|
|
1815
|
-
description: z.ZodString;
|
|
1816
|
-
pattern: z.ZodString;
|
|
1817
|
-
}, z.core.$strip>>;
|
|
1818
|
-
scopeOptions: z.ZodArray<z.ZodObject<{
|
|
1819
|
-
label: z.ZodString;
|
|
1820
|
-
scope: z.ZodString;
|
|
1821
|
-
}, z.core.$strip>>;
|
|
1822
|
-
directoryScopeOptions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1823
|
-
label: z.ZodString;
|
|
1824
|
-
scope: z.ZodString;
|
|
1825
|
-
}, z.core.$strip>>>;
|
|
1826
|
-
diff: z.ZodOptional<z.ZodObject<{
|
|
1827
|
-
filePath: z.ZodString;
|
|
1828
|
-
oldContent: z.ZodString;
|
|
1829
|
-
newContent: z.ZodString;
|
|
1830
|
-
isNewFile: z.ZodBoolean;
|
|
1831
|
-
}, z.core.$strip>>;
|
|
1832
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
1833
|
-
persistentDecisionsAllowed: z.ZodOptional<z.ZodBoolean>;
|
|
1834
|
-
toolUseId: z.ZodOptional<z.ZodString>;
|
|
1835
|
-
acpToolKind: z.ZodOptional<z.ZodString>;
|
|
1836
|
-
acpOptions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1837
|
-
optionId: z.ZodString;
|
|
1838
|
-
name: z.ZodString;
|
|
1839
|
-
kind: z.ZodEnum<{
|
|
1840
|
-
allow_once: "allow_once";
|
|
1841
|
-
allow_always: "allow_always";
|
|
1842
|
-
reject_once: "reject_once";
|
|
1843
|
-
reject_always: "reject_always";
|
|
1844
|
-
}>;
|
|
1845
|
-
}, z.core.$strip>>>;
|
|
1846
|
-
}, z.core.$strip>;
|
|
1847
|
-
|
|
1848
|
-
declare type ConfirmationStateChangedEvent = z.infer<typeof ConfirmationStateChangedEventSchema>;
|
|
1849
|
-
|
|
1850
|
-
declare const ConfirmationStateChangedEventSchema: z.ZodObject<{
|
|
1851
|
-
type: z.ZodLiteral<"confirmation_state_changed">;
|
|
1852
|
-
conversationId: z.ZodString;
|
|
1853
|
-
requestId: z.ZodString;
|
|
1854
|
-
state: z.ZodEnum<{
|
|
1855
|
-
timed_out: "timed_out";
|
|
1856
|
-
pending: "pending";
|
|
1857
|
-
approved: "approved";
|
|
1858
|
-
denied: "denied";
|
|
1859
|
-
resolved_stale: "resolved_stale";
|
|
1860
|
-
}>;
|
|
1861
|
-
source: z.ZodEnum<{
|
|
1862
|
-
button: "button";
|
|
1863
|
-
inline_nl: "inline_nl";
|
|
1864
|
-
auto_deny: "auto_deny";
|
|
1865
|
-
timeout: "timeout";
|
|
1866
|
-
system: "system";
|
|
1867
|
-
}>;
|
|
1868
|
-
causedByRequestId: z.ZodOptional<z.ZodString>;
|
|
1869
|
-
decisionText: z.ZodOptional<z.ZodString>;
|
|
1870
|
-
toolUseId: z.ZodOptional<z.ZodString>;
|
|
1871
|
-
}, z.core.$strip>;
|
|
1872
|
-
|
|
1873
|
-
declare type ContactRequestEvent = z.infer<typeof ContactRequestEventSchema>;
|
|
1874
|
-
|
|
1875
|
-
declare const ContactRequestEventSchema: z.ZodObject<{
|
|
1876
|
-
type: z.ZodLiteral<"contact_request">;
|
|
1877
|
-
requestId: z.ZodString;
|
|
1878
|
-
channel: z.ZodOptional<z.ZodString>;
|
|
1879
|
-
placeholder: z.ZodOptional<z.ZodString>;
|
|
1880
|
-
label: z.ZodOptional<z.ZodString>;
|
|
1881
|
-
description: z.ZodOptional<z.ZodString>;
|
|
1882
|
-
role: z.ZodOptional<z.ZodString>;
|
|
1883
|
-
}, z.core.$strip>;
|
|
1884
|
-
|
|
1885
|
-
declare type ContactsChangedEvent = z.infer<typeof ContactsChangedEventSchema>;
|
|
1886
|
-
|
|
1887
|
-
declare const ContactsChangedEventSchema: z.ZodObject<{
|
|
1888
|
-
type: z.ZodLiteral<"contacts_changed">;
|
|
1889
|
-
}, z.core.$strip>;
|
|
1890
|
-
|
|
1891
|
-
declare type _ContactsServerMessages = ContactsChangedEvent | ContactRequestEvent;
|
|
1892
|
-
|
|
1893
2669
|
export declare type ContentBlock = TextContent | ThinkingContent | RedactedThinkingContent | ImageContent | FileContent | ToolUseContent | ToolResultContent | ServerToolUseContent | WebSearchToolResultContent;
|
|
1894
2670
|
|
|
1895
|
-
declare type ContextCompactedEvent = z.infer<typeof ContextCompactedEventSchema>;
|
|
1896
|
-
|
|
1897
|
-
declare const ContextCompactedEventSchema: z.ZodObject<{
|
|
1898
|
-
type: z.ZodLiteral<"context_compacted">;
|
|
1899
|
-
conversationId: z.ZodString;
|
|
1900
|
-
previousEstimatedInputTokens: z.ZodNumber;
|
|
1901
|
-
estimatedInputTokens: z.ZodNumber;
|
|
1902
|
-
maxInputTokens: z.ZodNumber;
|
|
1903
|
-
thresholdTokens: z.ZodNumber;
|
|
1904
|
-
compactedMessages: z.ZodNumber;
|
|
1905
|
-
summaryCalls: z.ZodNumber;
|
|
1906
|
-
summaryInputTokens: z.ZodNumber;
|
|
1907
|
-
summaryOutputTokens: z.ZodNumber;
|
|
1908
|
-
summaryModel: z.ZodString;
|
|
1909
|
-
summaryCharCount: z.ZodOptional<z.ZodNumber>;
|
|
1910
|
-
summaryHeaderCount: z.ZodOptional<z.ZodNumber>;
|
|
1911
|
-
summaryHadMemoryEcho: z.ZodOptional<z.ZodBoolean>;
|
|
1912
|
-
}, z.core.$strip>;
|
|
1913
|
-
|
|
1914
2671
|
/** How a conversation was created / its execution mode. */
|
|
1915
2672
|
declare type ConversationCreateType = "standard" | "background" | "scheduled";
|
|
1916
2673
|
|
|
@@ -1941,96 +2698,6 @@ declare interface ConversationDeletedInputContext {
|
|
|
1941
2698
|
readonly conversationId: string;
|
|
1942
2699
|
}
|
|
1943
2700
|
|
|
1944
|
-
declare type ConversationErrorEvent = z.infer<typeof ConversationErrorEventSchema>;
|
|
1945
|
-
|
|
1946
|
-
declare const ConversationErrorEventSchema: z.ZodObject<{
|
|
1947
|
-
type: z.ZodLiteral<"conversation_error">;
|
|
1948
|
-
conversationId: z.ZodString;
|
|
1949
|
-
code: z.ZodEnum<{
|
|
1950
|
-
PROVIDER_NETWORK: "PROVIDER_NETWORK";
|
|
1951
|
-
PROVIDER_RATE_LIMIT: "PROVIDER_RATE_LIMIT";
|
|
1952
|
-
MANAGED_USAGE_LIMIT: "MANAGED_USAGE_LIMIT";
|
|
1953
|
-
PROVIDER_OVERLOADED: "PROVIDER_OVERLOADED";
|
|
1954
|
-
PROVIDER_API: "PROVIDER_API";
|
|
1955
|
-
IMAGE_TOO_LARGE: "IMAGE_TOO_LARGE";
|
|
1956
|
-
PROVIDER_BILLING: "PROVIDER_BILLING";
|
|
1957
|
-
PROVIDER_ORDERING: "PROVIDER_ORDERING";
|
|
1958
|
-
PROVIDER_WEB_SEARCH: "PROVIDER_WEB_SEARCH";
|
|
1959
|
-
PROVIDER_NOT_CONFIGURED: "PROVIDER_NOT_CONFIGURED";
|
|
1960
|
-
PROVIDER_INVALID_KEY: "PROVIDER_INVALID_KEY";
|
|
1961
|
-
MANAGED_KEY_INVALID: "MANAGED_KEY_INVALID";
|
|
1962
|
-
CONTEXT_TOO_LARGE: "CONTEXT_TOO_LARGE";
|
|
1963
|
-
BUDGET_YIELD_UNRECOVERED: "BUDGET_YIELD_UNRECOVERED";
|
|
1964
|
-
MAX_TOKENS_REACHED: "MAX_TOKENS_REACHED";
|
|
1965
|
-
CONVERSATION_ABORTED: "CONVERSATION_ABORTED";
|
|
1966
|
-
CONVERSATION_PROCESSING_FAILED: "CONVERSATION_PROCESSING_FAILED";
|
|
1967
|
-
DISK_SPACE_CRITICAL: "DISK_SPACE_CRITICAL";
|
|
1968
|
-
UNKNOWN: "UNKNOWN";
|
|
1969
|
-
}>;
|
|
1970
|
-
userMessage: z.ZodString;
|
|
1971
|
-
retryable: z.ZodBoolean;
|
|
1972
|
-
debugDetails: z.ZodOptional<z.ZodString>;
|
|
1973
|
-
errorCategory: z.ZodOptional<z.ZodString>;
|
|
1974
|
-
connectionName: z.ZodOptional<z.ZodString>;
|
|
1975
|
-
profileName: z.ZodOptional<z.ZodString>;
|
|
1976
|
-
}, z.core.$strip>;
|
|
1977
|
-
|
|
1978
|
-
declare type ConversationInferenceProfileUpdatedEvent = z.infer<typeof ConversationInferenceProfileUpdatedEventSchema>;
|
|
1979
|
-
|
|
1980
|
-
declare const ConversationInferenceProfileUpdatedEventSchema: z.ZodObject<{
|
|
1981
|
-
type: z.ZodLiteral<"conversation_inference_profile_updated">;
|
|
1982
|
-
conversationId: z.ZodString;
|
|
1983
|
-
profile: z.ZodNullable<z.ZodString>;
|
|
1984
|
-
sessionId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1985
|
-
expiresAt: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
1986
|
-
}, z.core.$strip>;
|
|
1987
|
-
|
|
1988
|
-
declare type ConversationListInvalidatedEvent = z.infer<typeof ConversationListInvalidatedEventSchema>;
|
|
1989
|
-
|
|
1990
|
-
declare const ConversationListInvalidatedEventSchema: z.ZodObject<{
|
|
1991
|
-
type: z.ZodLiteral<"conversation_list_invalidated">;
|
|
1992
|
-
reason: z.ZodEnum<{
|
|
1993
|
-
created: "created";
|
|
1994
|
-
renamed: "renamed";
|
|
1995
|
-
deleted: "deleted";
|
|
1996
|
-
reordered: "reordered";
|
|
1997
|
-
seen_changed: "seen_changed";
|
|
1998
|
-
}>;
|
|
1999
|
-
}, z.core.$strip>;
|
|
2000
|
-
|
|
2001
|
-
declare type ConversationNoticeEvent = z.infer<typeof ConversationNoticeEventSchema>;
|
|
2002
|
-
|
|
2003
|
-
declare const ConversationNoticeEventSchema: z.ZodObject<{
|
|
2004
|
-
type: z.ZodLiteral<"conversation_notice">;
|
|
2005
|
-
conversationId: z.ZodString;
|
|
2006
|
-
source: z.ZodEnum<{
|
|
2007
|
-
memory_v3: "memory_v3";
|
|
2008
|
-
}>;
|
|
2009
|
-
code: z.ZodEnum<{
|
|
2010
|
-
PROVIDER_NETWORK: "PROVIDER_NETWORK";
|
|
2011
|
-
PROVIDER_RATE_LIMIT: "PROVIDER_RATE_LIMIT";
|
|
2012
|
-
MANAGED_USAGE_LIMIT: "MANAGED_USAGE_LIMIT";
|
|
2013
|
-
PROVIDER_OVERLOADED: "PROVIDER_OVERLOADED";
|
|
2014
|
-
PROVIDER_API: "PROVIDER_API";
|
|
2015
|
-
IMAGE_TOO_LARGE: "IMAGE_TOO_LARGE";
|
|
2016
|
-
PROVIDER_BILLING: "PROVIDER_BILLING";
|
|
2017
|
-
PROVIDER_ORDERING: "PROVIDER_ORDERING";
|
|
2018
|
-
PROVIDER_WEB_SEARCH: "PROVIDER_WEB_SEARCH";
|
|
2019
|
-
PROVIDER_NOT_CONFIGURED: "PROVIDER_NOT_CONFIGURED";
|
|
2020
|
-
PROVIDER_INVALID_KEY: "PROVIDER_INVALID_KEY";
|
|
2021
|
-
MANAGED_KEY_INVALID: "MANAGED_KEY_INVALID";
|
|
2022
|
-
CONTEXT_TOO_LARGE: "CONTEXT_TOO_LARGE";
|
|
2023
|
-
BUDGET_YIELD_UNRECOVERED: "BUDGET_YIELD_UNRECOVERED";
|
|
2024
|
-
MAX_TOKENS_REACHED: "MAX_TOKENS_REACHED";
|
|
2025
|
-
CONVERSATION_ABORTED: "CONVERSATION_ABORTED";
|
|
2026
|
-
CONVERSATION_PROCESSING_FAILED: "CONVERSATION_PROCESSING_FAILED";
|
|
2027
|
-
DISK_SPACE_CRITICAL: "DISK_SPACE_CRITICAL";
|
|
2028
|
-
UNKNOWN: "UNKNOWN";
|
|
2029
|
-
}>;
|
|
2030
|
-
userMessage: z.ZodString;
|
|
2031
|
-
errorCategory: z.ZodOptional<z.ZodString>;
|
|
2032
|
-
}, z.core.$strip>;
|
|
2033
|
-
|
|
2034
2701
|
export declare interface ConversationRow {
|
|
2035
2702
|
id: string;
|
|
2036
2703
|
title: string | null;
|
|
@@ -2075,16 +2742,6 @@ export declare interface ConversationRow {
|
|
|
2075
2742
|
*/
|
|
2076
2743
|
export declare type ConversationsClearedContext = BaseHookContext;
|
|
2077
2744
|
|
|
2078
|
-
declare type _ConversationsServerMessages = AssistantStatusEvent | GenerationCancelledEvent | GenerationHandoffEvent | ModelInfoEvent | UsageUpdateEvent | UsageProgressEvent | ContextCompactedEvent | CompactionCircuitOpenEvent | CompactionCircuitClosedEvent | ConversationErrorEvent | ConversationNoticeEvent | ConversationTitleUpdatedEvent | ConversationListInvalidatedEvent | ScheduleConversationCreatedEvent | OpenConversationEvent;
|
|
2079
|
-
|
|
2080
|
-
declare type ConversationTitleUpdatedEvent = z.infer<typeof ConversationTitleUpdatedEventSchema>;
|
|
2081
|
-
|
|
2082
|
-
declare const ConversationTitleUpdatedEventSchema: z.ZodObject<{
|
|
2083
|
-
type: z.ZodLiteral<"conversation_title_updated">;
|
|
2084
|
-
conversationId: z.ZodString;
|
|
2085
|
-
title: z.ZodString;
|
|
2086
|
-
}, z.core.$strip>;
|
|
2087
|
-
|
|
2088
2745
|
/** Read-side alias of {@link ConversationCreateType}. */
|
|
2089
2746
|
declare type ConversationType = ConversationCreateType;
|
|
2090
2747
|
|
|
@@ -2137,113 +2794,9 @@ declare interface DiffInfo {
|
|
|
2137
2794
|
isNewFile: boolean;
|
|
2138
2795
|
}
|
|
2139
2796
|
|
|
2140
|
-
declare type DiskPressureStatusChangedEvent = z.infer<typeof DiskPressureStatusChangedEventSchema>;
|
|
2141
|
-
|
|
2142
|
-
declare const DiskPressureStatusChangedEventSchema: z.ZodObject<{
|
|
2143
|
-
type: z.ZodLiteral<"disk_pressure_status_changed">;
|
|
2144
|
-
status: z.ZodObject<{
|
|
2145
|
-
enabled: z.ZodBoolean;
|
|
2146
|
-
state: z.ZodEnum<{
|
|
2147
|
-
unknown: "unknown";
|
|
2148
|
-
disabled: "disabled";
|
|
2149
|
-
critical: "critical";
|
|
2150
|
-
warning: "warning";
|
|
2151
|
-
ok: "ok";
|
|
2152
|
-
}>;
|
|
2153
|
-
locked: z.ZodBoolean;
|
|
2154
|
-
acknowledged: z.ZodBoolean;
|
|
2155
|
-
overrideActive: z.ZodBoolean;
|
|
2156
|
-
effectivelyLocked: z.ZodBoolean;
|
|
2157
|
-
lockId: z.ZodNullable<z.ZodString>;
|
|
2158
|
-
usagePercent: z.ZodNullable<z.ZodNumber>;
|
|
2159
|
-
thresholdPercent: z.ZodNumber;
|
|
2160
|
-
path: z.ZodNullable<z.ZodString>;
|
|
2161
|
-
lastCheckedAt: z.ZodNullable<z.ZodString>;
|
|
2162
|
-
blockedCapabilities: z.ZodArray<z.ZodEnum<{
|
|
2163
|
-
"agent-turns": "agent-turns";
|
|
2164
|
-
"background-work": "background-work";
|
|
2165
|
-
"remote-ingress": "remote-ingress";
|
|
2166
|
-
}>>;
|
|
2167
|
-
error: z.ZodNullable<z.ZodString>;
|
|
2168
|
-
}, z.core.$strip>;
|
|
2169
|
-
}, z.core.$strip>;
|
|
2170
|
-
|
|
2171
2797
|
/** Distributive Omit that preserves union discrimination. */
|
|
2172
2798
|
declare type DistributiveOmit<T, K extends PropertyKey> = T extends unknown ? Omit<T, K> : never;
|
|
2173
2799
|
|
|
2174
|
-
declare type DocumentCommentCreatedEvent = z.infer<typeof DocumentCommentCreatedEventSchema>;
|
|
2175
|
-
|
|
2176
|
-
declare const DocumentCommentCreatedEventSchema: z.ZodObject<{
|
|
2177
|
-
type: z.ZodLiteral<"document_comment_created">;
|
|
2178
|
-
conversationId: z.ZodString;
|
|
2179
|
-
surfaceId: z.ZodString;
|
|
2180
|
-
comment: z.ZodObject<{
|
|
2181
|
-
id: z.ZodString;
|
|
2182
|
-
surfaceId: z.ZodString;
|
|
2183
|
-
author: z.ZodString;
|
|
2184
|
-
content: z.ZodString;
|
|
2185
|
-
anchorStart: z.ZodOptional<z.ZodNumber>;
|
|
2186
|
-
anchorEnd: z.ZodOptional<z.ZodNumber>;
|
|
2187
|
-
anchorText: z.ZodOptional<z.ZodString>;
|
|
2188
|
-
parentCommentId: z.ZodOptional<z.ZodString>;
|
|
2189
|
-
status: z.ZodString;
|
|
2190
|
-
createdAt: z.ZodNumber;
|
|
2191
|
-
updatedAt: z.ZodNumber;
|
|
2192
|
-
}, z.core.$strip>;
|
|
2193
|
-
}, z.core.$strip>;
|
|
2194
|
-
|
|
2195
|
-
declare type DocumentCommentDeletedEvent = z.infer<typeof DocumentCommentDeletedEventSchema>;
|
|
2196
|
-
|
|
2197
|
-
declare const DocumentCommentDeletedEventSchema: z.ZodObject<{
|
|
2198
|
-
type: z.ZodLiteral<"document_comment_deleted">;
|
|
2199
|
-
conversationId: z.ZodString;
|
|
2200
|
-
surfaceId: z.ZodString;
|
|
2201
|
-
commentId: z.ZodString;
|
|
2202
|
-
}, z.core.$strip>;
|
|
2203
|
-
|
|
2204
|
-
declare type DocumentCommentReopenedEvent = z.infer<typeof DocumentCommentReopenedEventSchema>;
|
|
2205
|
-
|
|
2206
|
-
declare const DocumentCommentReopenedEventSchema: z.ZodObject<{
|
|
2207
|
-
type: z.ZodLiteral<"document_comment_reopened">;
|
|
2208
|
-
conversationId: z.ZodString;
|
|
2209
|
-
surfaceId: z.ZodString;
|
|
2210
|
-
commentId: z.ZodString;
|
|
2211
|
-
}, z.core.$strip>;
|
|
2212
|
-
|
|
2213
|
-
declare type DocumentCommentResolvedEvent = z.infer<typeof DocumentCommentResolvedEventSchema>;
|
|
2214
|
-
|
|
2215
|
-
declare const DocumentCommentResolvedEventSchema: z.ZodObject<{
|
|
2216
|
-
type: z.ZodLiteral<"document_comment_resolved">;
|
|
2217
|
-
conversationId: z.ZodString;
|
|
2218
|
-
surfaceId: z.ZodString;
|
|
2219
|
-
commentId: z.ZodString;
|
|
2220
|
-
resolvedBy: z.ZodString;
|
|
2221
|
-
}, z.core.$strip>;
|
|
2222
|
-
|
|
2223
|
-
declare type _DocumentCommentsServerMessages = DocumentCommentCreatedEvent | DocumentCommentResolvedEvent | DocumentCommentReopenedEvent | DocumentCommentDeletedEvent;
|
|
2224
|
-
|
|
2225
|
-
declare type DocumentEditorShowEvent = z.infer<typeof DocumentEditorShowEventSchema>;
|
|
2226
|
-
|
|
2227
|
-
declare const DocumentEditorShowEventSchema: z.ZodObject<{
|
|
2228
|
-
type: z.ZodLiteral<"document_editor_show">;
|
|
2229
|
-
conversationId: z.ZodString;
|
|
2230
|
-
surfaceId: z.ZodString;
|
|
2231
|
-
title: z.ZodString;
|
|
2232
|
-
initialContent: z.ZodString;
|
|
2233
|
-
}, z.core.$strip>;
|
|
2234
|
-
|
|
2235
|
-
declare type DocumentEditorUpdateEvent = z.infer<typeof DocumentEditorUpdateEventSchema>;
|
|
2236
|
-
|
|
2237
|
-
declare const DocumentEditorUpdateEventSchema: z.ZodObject<{
|
|
2238
|
-
type: z.ZodLiteral<"document_editor_update">;
|
|
2239
|
-
conversationId: z.ZodString;
|
|
2240
|
-
surfaceId: z.ZodString;
|
|
2241
|
-
markdown: z.ZodString;
|
|
2242
|
-
mode: z.ZodString;
|
|
2243
|
-
}, z.core.$strip>;
|
|
2244
|
-
|
|
2245
|
-
declare type _DocumentsServerMessages = DocumentEditorShowEvent | DocumentEditorUpdateEvent;
|
|
2246
|
-
|
|
2247
2800
|
/**
|
|
2248
2801
|
* Whether the given model or profile can process image input.
|
|
2249
2802
|
*
|
|
@@ -2275,18 +2828,6 @@ declare type EmbeddingInput = string | MultimodalEmbeddingInput;
|
|
|
2275
2828
|
*/
|
|
2276
2829
|
declare type EmbeddingTargetType = Parameters<embedAndUpsert_2>[1];
|
|
2277
2830
|
|
|
2278
|
-
declare type ErrorEvent_2 = z.infer<typeof ErrorEventSchema>;
|
|
2279
|
-
|
|
2280
|
-
declare const ErrorEventSchema: z.ZodObject<{
|
|
2281
|
-
type: z.ZodLiteral<"error">;
|
|
2282
|
-
message: z.ZodString;
|
|
2283
|
-
code: z.ZodOptional<z.ZodString>;
|
|
2284
|
-
category: z.ZodOptional<z.ZodString>;
|
|
2285
|
-
errorCategory: z.ZodOptional<z.ZodString>;
|
|
2286
|
-
requestId: z.ZodOptional<z.ZodString>;
|
|
2287
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
2288
|
-
}, z.core.$strip>;
|
|
2289
|
-
|
|
2290
2831
|
export declare function extractTextFromStoredMessageContent(raw: string | ContentBlock[]): string;
|
|
2291
2832
|
|
|
2292
2833
|
export declare interface FileContent {
|
|
@@ -2304,39 +2845,6 @@ export declare interface FileContent {
|
|
|
2304
2845
|
_attachmentId?: string;
|
|
2305
2846
|
}
|
|
2306
2847
|
|
|
2307
|
-
declare type GenerationCancelledEvent = z.infer<typeof GenerationCancelledEventSchema>;
|
|
2308
|
-
|
|
2309
|
-
declare const GenerationCancelledEventSchema: z.ZodObject<{
|
|
2310
|
-
type: z.ZodLiteral<"generation_cancelled">;
|
|
2311
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
2312
|
-
}, z.core.$strip>;
|
|
2313
|
-
|
|
2314
|
-
declare type GenerationHandoffEvent = z.infer<typeof GenerationHandoffEventSchema>;
|
|
2315
|
-
|
|
2316
|
-
declare const GenerationHandoffEventSchema: z.ZodObject<{
|
|
2317
|
-
type: z.ZodLiteral<"generation_handoff">;
|
|
2318
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
2319
|
-
requestId: z.ZodOptional<z.ZodString>;
|
|
2320
|
-
queuedCount: z.ZodNumber;
|
|
2321
|
-
messageId: z.ZodOptional<z.ZodString>;
|
|
2322
|
-
attachments: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
2323
|
-
id: z.ZodOptional<z.ZodString>;
|
|
2324
|
-
filename: z.ZodString;
|
|
2325
|
-
mimeType: z.ZodString;
|
|
2326
|
-
data: z.ZodString;
|
|
2327
|
-
sourceType: z.ZodOptional<z.ZodEnum<{
|
|
2328
|
-
host_file: "host_file";
|
|
2329
|
-
sandbox_file: "sandbox_file";
|
|
2330
|
-
tool_block: "tool_block";
|
|
2331
|
-
}>>;
|
|
2332
|
-
sizeBytes: z.ZodOptional<z.ZodNumber>;
|
|
2333
|
-
thumbnailData: z.ZodOptional<z.ZodString>;
|
|
2334
|
-
fileBacked: z.ZodOptional<z.ZodBoolean>;
|
|
2335
|
-
filePath: z.ZodOptional<z.ZodString>;
|
|
2336
|
-
}, z.core.$strip>>>;
|
|
2337
|
-
attachmentWarnings: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
2338
|
-
}, z.core.$strip>;
|
|
2339
|
-
|
|
2340
2848
|
/** Read the assistant's name from IDENTITY.md for personalized responses. */
|
|
2341
2849
|
export declare function getAssistantName(): string | null;
|
|
2342
2850
|
|
|
@@ -2408,32 +2916,6 @@ declare interface GraphNodeSweepResult {
|
|
|
2408
2916
|
/** Whether the text tokenizes to at least one lexical search token. */
|
|
2409
2917
|
export declare function hasLexicalTokens(text: string): Promise<boolean>;
|
|
2410
2918
|
|
|
2411
|
-
declare type HeartbeatAlertEvent = z.infer<typeof HeartbeatAlertEventSchema>;
|
|
2412
|
-
|
|
2413
|
-
declare const HeartbeatAlertEventSchema: z.ZodObject<{
|
|
2414
|
-
type: z.ZodLiteral<"heartbeat_alert">;
|
|
2415
|
-
title: z.ZodString;
|
|
2416
|
-
body: z.ZodString;
|
|
2417
|
-
}, z.core.$strip>;
|
|
2418
|
-
|
|
2419
|
-
declare type HeartbeatConversationCreatedEvent = z.infer<typeof HeartbeatConversationCreatedEventSchema>;
|
|
2420
|
-
|
|
2421
|
-
declare const HeartbeatConversationCreatedEventSchema: z.ZodObject<{
|
|
2422
|
-
type: z.ZodLiteral<"heartbeat_conversation_created">;
|
|
2423
|
-
conversationId: z.ZodString;
|
|
2424
|
-
title: z.ZodString;
|
|
2425
|
-
}, z.core.$strip>;
|
|
2426
|
-
|
|
2427
|
-
declare type HomeFeedUpdatedEvent = z.infer<typeof HomeFeedUpdatedEventSchema>;
|
|
2428
|
-
|
|
2429
|
-
declare const HomeFeedUpdatedEventSchema: z.ZodObject<{
|
|
2430
|
-
type: z.ZodLiteral<"home_feed_updated">;
|
|
2431
|
-
updatedAt: z.ZodString;
|
|
2432
|
-
newItemCount: z.ZodNumber;
|
|
2433
|
-
}, z.core.$strip>;
|
|
2434
|
-
|
|
2435
|
-
declare type _HomeServerMessages = RelationshipStateUpdatedEvent | HomeFeedUpdatedEvent;
|
|
2436
|
-
|
|
2437
2919
|
/**
|
|
2438
2920
|
* Emit a `hook_event` to any UI watching the conversation the hook runs in —
|
|
2439
2921
|
* e.g. progress while the hook does work the user can feel (memory
|
|
@@ -2448,22 +2930,6 @@ declare type _HomeServerMessages = RelationshipStateUpdatedEvent | HomeFeedUpdat
|
|
|
2448
2930
|
*/
|
|
2449
2931
|
export declare type HookBroadcast = (detail: Record<string, unknown>) => void;
|
|
2450
2932
|
|
|
2451
|
-
declare type HookEvent = z.infer<typeof HookEventSchema>;
|
|
2452
|
-
|
|
2453
|
-
declare const HookEventSchema: z.ZodObject<{
|
|
2454
|
-
type: z.ZodLiteral<"hook_event">;
|
|
2455
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
2456
|
-
hookName: z.ZodString;
|
|
2457
|
-
owner: z.ZodObject<{
|
|
2458
|
-
kind: z.ZodEnum<{
|
|
2459
|
-
plugin: "plugin";
|
|
2460
|
-
workspace: "workspace";
|
|
2461
|
-
}>;
|
|
2462
|
-
id: z.ZodString;
|
|
2463
|
-
}, z.core.$strip>;
|
|
2464
|
-
detail: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
2465
|
-
}, z.core.$strip>;
|
|
2466
|
-
|
|
2467
2933
|
/**
|
|
2468
2934
|
* A plugin lifecycle hook. Receives a per-lifecycle context shape and may
|
|
2469
2935
|
* either mutate `ctx` in place (returning `void`) or return a *partial*
|
|
@@ -2524,280 +2990,24 @@ export declare const HOOKS: {
|
|
|
2524
2990
|
/** Fires once per run when the loop has committed to ending — the definitive terminal hook for teardown. Cannot continue the loop; reports how the turn ended via `exitReason`. */
|
|
2525
2991
|
readonly STOP: "stop";
|
|
2526
2992
|
/** Fires at every model-call outcome (finalized reply or provider rejection), before the message is persisted/streamed-final. A hook may transform the content and owns the continue/retry decision. */
|
|
2527
|
-
readonly POST_MODEL_CALL: "post-model-call";
|
|
2528
|
-
/** Fires after the loop successfully compacts a conversation mid-turn. */
|
|
2529
|
-
readonly POST_COMPACT: "post-compact";
|
|
2530
|
-
/** Fires once per deleted conversation, after its rows are removed. Fire-and-forget cleanup signal — hooks run async with no ordering guarantee relative to the caller. */
|
|
2531
|
-
readonly CONVERSATION_DELETED: "conversation-deleted";
|
|
2532
|
-
/** Fires once when every conversation is wiped at once (the clear-all reset), after the main tables are cleared. Carries no `conversationId`; cleanup hooks wipe their own per-conversation state wholesale. */
|
|
2533
|
-
readonly CONVERSATIONS_CLEARED: "conversations-cleared";
|
|
2534
|
-
};
|
|
2535
|
-
|
|
2536
|
-
/**
|
|
2537
|
-
* Host proxy capabilities that an interface can support. The macOS client
|
|
2538
|
-
* supports all of them; the chrome-extension interface only supports
|
|
2539
|
-
* host_browser (via the Chrome DevTools Protocol proxy).
|
|
2540
|
-
*/
|
|
2541
|
-
declare const HOST_PROXY_CAPABILITIES: readonly ["host_bash", "host_file", "host_cu", "host_browser", "host_app_control", "host_ui_snapshot"];
|
|
2542
|
-
|
|
2543
|
-
declare type HostAppControlCancelEvent = z.infer<typeof HostAppControlCancelEventSchema>;
|
|
2544
|
-
|
|
2545
|
-
declare const HostAppControlCancelEventSchema: z.ZodObject<{
|
|
2546
|
-
type: z.ZodLiteral<"host_app_control_cancel">;
|
|
2547
|
-
requestId: z.ZodString;
|
|
2548
|
-
conversationId: z.ZodString;
|
|
2549
|
-
}, z.core.$strip>;
|
|
2550
|
-
|
|
2551
|
-
declare type HostAppControlRequestEvent = z.infer<typeof HostAppControlRequestEventSchema>;
|
|
2552
|
-
|
|
2553
|
-
declare const HostAppControlRequestEventSchema: z.ZodObject<{
|
|
2554
|
-
type: z.ZodLiteral<"host_app_control_request">;
|
|
2555
|
-
requestId: z.ZodString;
|
|
2556
|
-
conversationId: z.ZodString;
|
|
2557
|
-
toolName: z.ZodString;
|
|
2558
|
-
input: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
2559
|
-
tool: z.ZodLiteral<"start">;
|
|
2560
|
-
app: z.ZodString;
|
|
2561
|
-
args: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
2562
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
2563
|
-
tool: z.ZodLiteral<"observe">;
|
|
2564
|
-
app: z.ZodString;
|
|
2565
|
-
settle_ms: z.ZodOptional<z.ZodNumber>;
|
|
2566
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
2567
|
-
tool: z.ZodLiteral<"press">;
|
|
2568
|
-
app: z.ZodString;
|
|
2569
|
-
key: z.ZodString;
|
|
2570
|
-
modifiers: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
2571
|
-
duration_ms: z.ZodOptional<z.ZodNumber>;
|
|
2572
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
2573
|
-
tool: z.ZodLiteral<"combo">;
|
|
2574
|
-
app: z.ZodString;
|
|
2575
|
-
keys: z.ZodArray<z.ZodString>;
|
|
2576
|
-
duration_ms: z.ZodOptional<z.ZodNumber>;
|
|
2577
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
2578
|
-
tool: z.ZodLiteral<"sequence">;
|
|
2579
|
-
app: z.ZodString;
|
|
2580
|
-
steps: z.ZodArray<z.ZodObject<{
|
|
2581
|
-
key: z.ZodString;
|
|
2582
|
-
modifiers: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
2583
|
-
duration_ms: z.ZodOptional<z.ZodNumber>;
|
|
2584
|
-
gap_ms: z.ZodOptional<z.ZodNumber>;
|
|
2585
|
-
}, z.core.$strip>>;
|
|
2586
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
2587
|
-
tool: z.ZodLiteral<"type">;
|
|
2588
|
-
app: z.ZodString;
|
|
2589
|
-
text: z.ZodString;
|
|
2590
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
2591
|
-
tool: z.ZodLiteral<"click">;
|
|
2592
|
-
app: z.ZodString;
|
|
2593
|
-
x: z.ZodNumber;
|
|
2594
|
-
y: z.ZodNumber;
|
|
2595
|
-
button: z.ZodOptional<z.ZodEnum<{
|
|
2596
|
-
left: "left";
|
|
2597
|
-
right: "right";
|
|
2598
|
-
middle: "middle";
|
|
2599
|
-
}>>;
|
|
2600
|
-
double: z.ZodOptional<z.ZodBoolean>;
|
|
2601
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
2602
|
-
tool: z.ZodLiteral<"drag">;
|
|
2603
|
-
app: z.ZodString;
|
|
2604
|
-
from_x: z.ZodNumber;
|
|
2605
|
-
from_y: z.ZodNumber;
|
|
2606
|
-
to_x: z.ZodNumber;
|
|
2607
|
-
to_y: z.ZodNumber;
|
|
2608
|
-
button: z.ZodOptional<z.ZodEnum<{
|
|
2609
|
-
left: "left";
|
|
2610
|
-
right: "right";
|
|
2611
|
-
middle: "middle";
|
|
2612
|
-
}>>;
|
|
2613
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
2614
|
-
tool: z.ZodLiteral<"stop">;
|
|
2615
|
-
app: z.ZodOptional<z.ZodString>;
|
|
2616
|
-
reason: z.ZodOptional<z.ZodString>;
|
|
2617
|
-
}, z.core.$strip>], "tool">;
|
|
2618
|
-
}, z.core.$strip>;
|
|
2619
|
-
|
|
2620
|
-
declare type _HostAppControlServerMessages = HostAppControlRequestEvent | HostAppControlCancelEvent;
|
|
2621
|
-
|
|
2622
|
-
declare type HostBashCancelEvent = z.infer<typeof HostBashCancelEventSchema>;
|
|
2623
|
-
|
|
2624
|
-
declare const HostBashCancelEventSchema: z.ZodObject<{
|
|
2625
|
-
type: z.ZodLiteral<"host_bash_cancel">;
|
|
2626
|
-
requestId: z.ZodString;
|
|
2627
|
-
conversationId: z.ZodString;
|
|
2628
|
-
targetClientId: z.ZodOptional<z.ZodString>;
|
|
2629
|
-
}, z.core.$strip>;
|
|
2630
|
-
|
|
2631
|
-
declare type HostBashRequestEvent = z.infer<typeof HostBashRequestEventSchema>;
|
|
2632
|
-
|
|
2633
|
-
declare const HostBashRequestEventSchema: z.ZodObject<{
|
|
2634
|
-
type: z.ZodLiteral<"host_bash_request">;
|
|
2635
|
-
requestId: z.ZodString;
|
|
2636
|
-
conversationId: z.ZodString;
|
|
2637
|
-
command: z.ZodString;
|
|
2638
|
-
working_dir: z.ZodOptional<z.ZodString>;
|
|
2639
|
-
timeout_seconds: z.ZodOptional<z.ZodNumber>;
|
|
2640
|
-
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
2641
|
-
targetClientId: z.ZodOptional<z.ZodString>;
|
|
2642
|
-
}, z.core.$strip>;
|
|
2643
|
-
|
|
2644
|
-
declare type _HostBashServerMessages = HostBashRequestEvent | HostBashCancelEvent;
|
|
2645
|
-
|
|
2646
|
-
declare type HostBrowserCancelEvent = z.infer<typeof HostBrowserCancelEventSchema>;
|
|
2647
|
-
|
|
2648
|
-
declare const HostBrowserCancelEventSchema: z.ZodObject<{
|
|
2649
|
-
type: z.ZodLiteral<"host_browser_cancel">;
|
|
2650
|
-
requestId: z.ZodString;
|
|
2651
|
-
}, z.core.$strip>;
|
|
2652
|
-
|
|
2653
|
-
declare type HostBrowserRequestEvent = z.infer<typeof HostBrowserRequestEventSchema>;
|
|
2654
|
-
|
|
2655
|
-
declare const HostBrowserRequestEventSchema: z.ZodObject<{
|
|
2656
|
-
type: z.ZodLiteral<"host_browser_request">;
|
|
2657
|
-
requestId: z.ZodString;
|
|
2658
|
-
conversationId: z.ZodString;
|
|
2659
|
-
cdpMethod: z.ZodString;
|
|
2660
|
-
cdpParams: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
2661
|
-
cdpSessionId: z.ZodOptional<z.ZodString>;
|
|
2662
|
-
timeout_seconds: z.ZodOptional<z.ZodNumber>;
|
|
2663
|
-
}, z.core.$strip>;
|
|
2664
|
-
|
|
2665
|
-
declare type _HostBrowserServerMessages = HostBrowserRequestEvent | HostBrowserCancelEvent;
|
|
2666
|
-
|
|
2667
|
-
declare type HostCuCancelEvent = z.infer<typeof HostCuCancelEventSchema>;
|
|
2668
|
-
|
|
2669
|
-
declare const HostCuCancelEventSchema: z.ZodObject<{
|
|
2670
|
-
type: z.ZodLiteral<"host_cu_cancel">;
|
|
2671
|
-
requestId: z.ZodString;
|
|
2672
|
-
conversationId: z.ZodString;
|
|
2673
|
-
targetClientId: z.ZodOptional<z.ZodString>;
|
|
2674
|
-
}, z.core.$strip>;
|
|
2675
|
-
|
|
2676
|
-
declare type HostCuRequestEvent = z.infer<typeof HostCuRequestEventSchema>;
|
|
2677
|
-
|
|
2678
|
-
declare const HostCuRequestEventSchema: z.ZodObject<{
|
|
2679
|
-
type: z.ZodLiteral<"host_cu_request">;
|
|
2680
|
-
requestId: z.ZodString;
|
|
2681
|
-
conversationId: z.ZodString;
|
|
2682
|
-
targetClientId: z.ZodOptional<z.ZodString>;
|
|
2683
|
-
toolName: z.ZodString;
|
|
2684
|
-
input: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
2685
|
-
stepNumber: z.ZodNumber;
|
|
2686
|
-
reasoning: z.ZodOptional<z.ZodString>;
|
|
2687
|
-
}, z.core.$strip>;
|
|
2688
|
-
|
|
2689
|
-
declare type _HostCuServerMessages = HostCuRequestEvent | HostCuCancelEvent;
|
|
2690
|
-
|
|
2691
|
-
declare type HostFileCancelEvent = z.infer<typeof HostFileCancelEventSchema>;
|
|
2692
|
-
|
|
2693
|
-
declare const HostFileCancelEventSchema: z.ZodObject<{
|
|
2694
|
-
type: z.ZodLiteral<"host_file_cancel">;
|
|
2695
|
-
requestId: z.ZodString;
|
|
2696
|
-
conversationId: z.ZodString;
|
|
2697
|
-
targetClientId: z.ZodOptional<z.ZodString>;
|
|
2698
|
-
}, z.core.$strip>;
|
|
2993
|
+
readonly POST_MODEL_CALL: "post-model-call";
|
|
2994
|
+
/** Fires after the loop successfully compacts a conversation mid-turn. */
|
|
2995
|
+
readonly POST_COMPACT: "post-compact";
|
|
2996
|
+
/** Fires once per deleted conversation, after its rows are removed. Fire-and-forget cleanup signal — hooks run async with no ordering guarantee relative to the caller. */
|
|
2997
|
+
readonly CONVERSATION_DELETED: "conversation-deleted";
|
|
2998
|
+
/** Fires once when every conversation is wiped at once (the clear-all reset), after the main tables are cleared. Carries no `conversationId`; cleanup hooks wipe their own per-conversation state wholesale. */
|
|
2999
|
+
readonly CONVERSATIONS_CLEARED: "conversations-cleared";
|
|
3000
|
+
};
|
|
2699
3001
|
|
|
2700
|
-
|
|
2701
|
-
|
|
2702
|
-
|
|
2703
|
-
|
|
2704
|
-
|
|
2705
|
-
|
|
2706
|
-
targetClientId: z.ZodOptional<z.ZodString>;
|
|
2707
|
-
operation: z.ZodLiteral<"read">;
|
|
2708
|
-
path: z.ZodString;
|
|
2709
|
-
offset: z.ZodOptional<z.ZodNumber>;
|
|
2710
|
-
limit: z.ZodOptional<z.ZodNumber>;
|
|
2711
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
2712
|
-
type: z.ZodLiteral<"host_file_request">;
|
|
2713
|
-
requestId: z.ZodString;
|
|
2714
|
-
conversationId: z.ZodString;
|
|
2715
|
-
targetClientId: z.ZodOptional<z.ZodString>;
|
|
2716
|
-
operation: z.ZodLiteral<"write">;
|
|
2717
|
-
path: z.ZodString;
|
|
2718
|
-
content: z.ZodString;
|
|
2719
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
2720
|
-
type: z.ZodLiteral<"host_file_request">;
|
|
2721
|
-
requestId: z.ZodString;
|
|
2722
|
-
conversationId: z.ZodString;
|
|
2723
|
-
targetClientId: z.ZodOptional<z.ZodString>;
|
|
2724
|
-
operation: z.ZodLiteral<"edit">;
|
|
2725
|
-
path: z.ZodString;
|
|
2726
|
-
old_string: z.ZodString;
|
|
2727
|
-
new_string: z.ZodString;
|
|
2728
|
-
replace_all: z.ZodOptional<z.ZodBoolean>;
|
|
2729
|
-
}, z.core.$strip>], "operation">;
|
|
2730
|
-
|
|
2731
|
-
declare type _HostFileServerMessages = HostFileRequestEvent | HostFileCancelEvent;
|
|
3002
|
+
/**
|
|
3003
|
+
* Host proxy capabilities that an interface can support. The macOS client
|
|
3004
|
+
* supports all of them; the chrome-extension interface only supports
|
|
3005
|
+
* host_browser (via the Chrome DevTools Protocol proxy).
|
|
3006
|
+
*/
|
|
3007
|
+
declare const HOST_PROXY_CAPABILITIES: readonly ["host_bash", "host_file", "host_cu", "host_browser", "host_app_control", "host_ui_snapshot"];
|
|
2732
3008
|
|
|
2733
3009
|
declare type HostProxyCapability = (typeof HOST_PROXY_CAPABILITIES)[number];
|
|
2734
3010
|
|
|
2735
|
-
declare type HostTransferCancelEvent = z.infer<typeof HostTransferCancelEventSchema>;
|
|
2736
|
-
|
|
2737
|
-
declare const HostTransferCancelEventSchema: z.ZodObject<{
|
|
2738
|
-
type: z.ZodLiteral<"host_transfer_cancel">;
|
|
2739
|
-
requestId: z.ZodString;
|
|
2740
|
-
conversationId: z.ZodString;
|
|
2741
|
-
targetClientId: z.ZodOptional<z.ZodString>;
|
|
2742
|
-
}, z.core.$strip>;
|
|
2743
|
-
|
|
2744
|
-
declare type HostTransferRequestEvent = z.infer<typeof HostTransferRequestEventSchema>;
|
|
2745
|
-
|
|
2746
|
-
declare const HostTransferRequestEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
2747
|
-
type: z.ZodLiteral<"host_transfer_request">;
|
|
2748
|
-
requestId: z.ZodString;
|
|
2749
|
-
conversationId: z.ZodString;
|
|
2750
|
-
targetClientId: z.ZodOptional<z.ZodString>;
|
|
2751
|
-
direction: z.ZodLiteral<"to_host">;
|
|
2752
|
-
transferId: z.ZodString;
|
|
2753
|
-
destPath: z.ZodString;
|
|
2754
|
-
sizeBytes: z.ZodNumber;
|
|
2755
|
-
sha256: z.ZodString;
|
|
2756
|
-
overwrite: z.ZodBoolean;
|
|
2757
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
2758
|
-
type: z.ZodLiteral<"host_transfer_request">;
|
|
2759
|
-
requestId: z.ZodString;
|
|
2760
|
-
conversationId: z.ZodString;
|
|
2761
|
-
targetClientId: z.ZodOptional<z.ZodString>;
|
|
2762
|
-
direction: z.ZodLiteral<"to_sandbox">;
|
|
2763
|
-
transferId: z.ZodString;
|
|
2764
|
-
sourcePath: z.ZodString;
|
|
2765
|
-
}, z.core.$strip>], "direction">;
|
|
2766
|
-
|
|
2767
|
-
declare type _HostTransferServerMessages = HostTransferRequestEvent | HostTransferCancelEvent;
|
|
2768
|
-
|
|
2769
|
-
declare type HostUiSnapshotCancelEvent = z.infer<typeof HostUiSnapshotCancelEventSchema>;
|
|
2770
|
-
|
|
2771
|
-
declare const HostUiSnapshotCancelEventSchema: z.ZodObject<{
|
|
2772
|
-
type: z.ZodLiteral<"host_ui_snapshot_cancel">;
|
|
2773
|
-
requestId: z.ZodString;
|
|
2774
|
-
}, z.core.$strip>;
|
|
2775
|
-
|
|
2776
|
-
declare type HostUiSnapshotRequestEvent = z.infer<typeof HostUiSnapshotRequestEventSchema>;
|
|
2777
|
-
|
|
2778
|
-
declare const HostUiSnapshotRequestEventSchema: z.ZodObject<{
|
|
2779
|
-
type: z.ZodLiteral<"host_ui_snapshot_request">;
|
|
2780
|
-
requestId: z.ZodString;
|
|
2781
|
-
view: z.ZodEnum<{
|
|
2782
|
-
sampler: "sampler";
|
|
2783
|
-
chat: "chat";
|
|
2784
|
-
}>;
|
|
2785
|
-
tokens: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
2786
|
-
}, z.core.$strip>;
|
|
2787
|
-
|
|
2788
|
-
declare type _HostUiSnapshotServerMessages = HostUiSnapshotRequestEvent | HostUiSnapshotCancelEvent;
|
|
2789
|
-
|
|
2790
|
-
declare type IdentityChangedEvent = z.infer<typeof IdentityChangedEventSchema>;
|
|
2791
|
-
|
|
2792
|
-
declare const IdentityChangedEventSchema: z.ZodObject<{
|
|
2793
|
-
type: z.ZodLiteral<"identity_changed">;
|
|
2794
|
-
name: z.ZodString;
|
|
2795
|
-
role: z.ZodString;
|
|
2796
|
-
personality: z.ZodString;
|
|
2797
|
-
emoji: z.ZodString;
|
|
2798
|
-
home: z.ZodString;
|
|
2799
|
-
}, z.core.$strip>;
|
|
2800
|
-
|
|
2801
3011
|
export declare interface ImageContent {
|
|
2802
3012
|
type: "image";
|
|
2803
3013
|
source: MediaSource_2;
|
|
@@ -2852,24 +3062,6 @@ declare interface InsertedMessage {
|
|
|
2852
3062
|
deduplicated: boolean;
|
|
2853
3063
|
}
|
|
2854
3064
|
|
|
2855
|
-
declare type _IntegrationsServerMessages = ChannelVerificationSessionResponse | OAuthConnectResultEvent | OpenUrlEvent | OpenPanelEvent | NavigateSettingsEvent | ShowPlatformLoginEvent | PlatformDisconnectedEvent;
|
|
2856
|
-
|
|
2857
|
-
declare type InteractionResolvedEvent = z.infer<typeof InteractionResolvedEventSchema>;
|
|
2858
|
-
|
|
2859
|
-
declare const InteractionResolvedEventSchema: z.ZodObject<{
|
|
2860
|
-
type: z.ZodLiteral<"interaction_resolved">;
|
|
2861
|
-
requestId: z.ZodString;
|
|
2862
|
-
conversationId: z.ZodString;
|
|
2863
|
-
state: z.ZodEnum<{
|
|
2864
|
-
cancelled: "cancelled";
|
|
2865
|
-
superseded: "superseded";
|
|
2866
|
-
approved: "approved";
|
|
2867
|
-
rejected: "rejected";
|
|
2868
|
-
answered: "answered";
|
|
2869
|
-
}>;
|
|
2870
|
-
kind: z.ZodString;
|
|
2871
|
-
}, z.core.$strip>;
|
|
2872
|
-
|
|
2873
3065
|
declare const INTERFACE_IDS: readonly ["macos", "ios", "cli", "telegram", "phone", "web", "whatsapp", "slack", "email", "chrome-extension", "a2a", "route"];
|
|
2874
3066
|
|
|
2875
3067
|
declare type InterfaceId = (typeof INTERFACE_IDS)[number];
|
|
@@ -3219,95 +3411,11 @@ declare const LLMCallSiteEnum: z.ZodEnum<{
|
|
|
3219
3411
|
|
|
3220
3412
|
declare type MediaSource_2 = Base64MediaSource | WorkspaceRefMediaSource;
|
|
3221
3413
|
|
|
3222
|
-
declare type MemoryRecalledEvent = z.infer<typeof MemoryRecalledEventSchema>;
|
|
3223
|
-
|
|
3224
|
-
declare const MemoryRecalledEventSchema: z.ZodObject<{
|
|
3225
|
-
type: z.ZodLiteral<"memory_recalled">;
|
|
3226
|
-
provider: z.ZodString;
|
|
3227
|
-
model: z.ZodString;
|
|
3228
|
-
degradation: z.ZodOptional<z.ZodObject<{
|
|
3229
|
-
semanticUnavailable: z.ZodBoolean;
|
|
3230
|
-
reason: z.ZodString;
|
|
3231
|
-
fallbackSources: z.ZodArray<z.ZodString>;
|
|
3232
|
-
}, z.core.$strip>>;
|
|
3233
|
-
semanticHits: z.ZodNumber;
|
|
3234
|
-
tier1Count: z.ZodNumber;
|
|
3235
|
-
tier2Count: z.ZodNumber;
|
|
3236
|
-
hybridSearchLatencyMs: z.ZodNumber;
|
|
3237
|
-
sparseVectorUsed: z.ZodBoolean;
|
|
3238
|
-
mergedCount: z.ZodNumber;
|
|
3239
|
-
selectedCount: z.ZodNumber;
|
|
3240
|
-
injectedTokens: z.ZodNumber;
|
|
3241
|
-
latencyMs: z.ZodNumber;
|
|
3242
|
-
topCandidates: z.ZodArray<z.ZodObject<{
|
|
3243
|
-
key: z.ZodString;
|
|
3244
|
-
type: z.ZodString;
|
|
3245
|
-
kind: z.ZodString;
|
|
3246
|
-
finalScore: z.ZodNumber;
|
|
3247
|
-
semantic: z.ZodNumber;
|
|
3248
|
-
recency: z.ZodNumber;
|
|
3249
|
-
}, z.core.$strip>>;
|
|
3250
|
-
}, z.core.$strip>;
|
|
3251
|
-
|
|
3252
|
-
declare type _MemoryServerMessages = MemoryRecalledEvent | MemoryStatusEvent;
|
|
3253
|
-
|
|
3254
|
-
declare type MemoryStatusEvent = z.infer<typeof MemoryStatusEventSchema>;
|
|
3255
|
-
|
|
3256
|
-
declare const MemoryStatusEventSchema: z.ZodObject<{
|
|
3257
|
-
type: z.ZodLiteral<"memory_status">;
|
|
3258
|
-
enabled: z.ZodBoolean;
|
|
3259
|
-
degraded: z.ZodBoolean;
|
|
3260
|
-
degradation: z.ZodOptional<z.ZodObject<{
|
|
3261
|
-
semanticUnavailable: z.ZodBoolean;
|
|
3262
|
-
reason: z.ZodString;
|
|
3263
|
-
fallbackSources: z.ZodArray<z.ZodString>;
|
|
3264
|
-
}, z.core.$strip>>;
|
|
3265
|
-
reason: z.ZodOptional<z.ZodString>;
|
|
3266
|
-
provider: z.ZodOptional<z.ZodString>;
|
|
3267
|
-
model: z.ZodOptional<z.ZodString>;
|
|
3268
|
-
}, z.core.$strip>;
|
|
3269
|
-
|
|
3270
3414
|
export declare interface Message {
|
|
3271
3415
|
role: "user" | "assistant";
|
|
3272
3416
|
content: ContentBlock[];
|
|
3273
3417
|
}
|
|
3274
3418
|
|
|
3275
|
-
declare type MessageCompleteEvent = z.infer<typeof MessageCompleteEventSchema>;
|
|
3276
|
-
|
|
3277
|
-
declare const MessageCompleteEventSchema: z.ZodObject<{
|
|
3278
|
-
type: z.ZodLiteral<"message_complete">;
|
|
3279
|
-
messageId: z.ZodOptional<z.ZodString>;
|
|
3280
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
3281
|
-
source: z.ZodOptional<z.ZodEnum<{
|
|
3282
|
-
main: "main";
|
|
3283
|
-
aux: "aux";
|
|
3284
|
-
}>>;
|
|
3285
|
-
attachments: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
3286
|
-
id: z.ZodOptional<z.ZodString>;
|
|
3287
|
-
filename: z.ZodString;
|
|
3288
|
-
mimeType: z.ZodString;
|
|
3289
|
-
data: z.ZodString;
|
|
3290
|
-
sourceType: z.ZodOptional<z.ZodEnum<{
|
|
3291
|
-
host_file: "host_file";
|
|
3292
|
-
sandbox_file: "sandbox_file";
|
|
3293
|
-
tool_block: "tool_block";
|
|
3294
|
-
}>>;
|
|
3295
|
-
sizeBytes: z.ZodOptional<z.ZodNumber>;
|
|
3296
|
-
thumbnailData: z.ZodOptional<z.ZodString>;
|
|
3297
|
-
fileBacked: z.ZodOptional<z.ZodBoolean>;
|
|
3298
|
-
filePath: z.ZodOptional<z.ZodString>;
|
|
3299
|
-
}, z.core.$strip>>>;
|
|
3300
|
-
attachmentWarnings: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
3301
|
-
}, z.core.$strip>;
|
|
3302
|
-
|
|
3303
|
-
declare type MessageDequeuedEvent = z.infer<typeof MessageDequeuedEventSchema>;
|
|
3304
|
-
|
|
3305
|
-
declare const MessageDequeuedEventSchema: z.ZodObject<{
|
|
3306
|
-
type: z.ZodLiteral<"message_dequeued">;
|
|
3307
|
-
conversationId: z.ZodString;
|
|
3308
|
-
requestId: z.ZodString;
|
|
3309
|
-
}, z.core.$strip>;
|
|
3310
|
-
|
|
3311
3419
|
declare type MessageLexicalSearchResult = Awaited<ReturnType<searchMessageIdsLexical_2>>[number];
|
|
3312
3420
|
|
|
3313
3421
|
declare interface MessageLexicalSearchResult_2 {
|
|
@@ -3428,32 +3536,6 @@ declare const messageMetadataSchema: z.ZodObject<{
|
|
|
3428
3536
|
nonInteractiveContextBlock: z.ZodOptional<z.ZodString>;
|
|
3429
3537
|
}, z.core.$loose>;
|
|
3430
3538
|
|
|
3431
|
-
declare type MessageQueuedDeletedEvent = z.infer<typeof MessageQueuedDeletedEventSchema>;
|
|
3432
|
-
|
|
3433
|
-
declare const MessageQueuedDeletedEventSchema: z.ZodObject<{
|
|
3434
|
-
type: z.ZodLiteral<"message_queued_deleted">;
|
|
3435
|
-
conversationId: z.ZodString;
|
|
3436
|
-
requestId: z.ZodString;
|
|
3437
|
-
}, z.core.$strip>;
|
|
3438
|
-
|
|
3439
|
-
declare type MessageQueuedEvent = z.infer<typeof MessageQueuedEventSchema>;
|
|
3440
|
-
|
|
3441
|
-
declare const MessageQueuedEventSchema: z.ZodObject<{
|
|
3442
|
-
type: z.ZodLiteral<"message_queued">;
|
|
3443
|
-
conversationId: z.ZodString;
|
|
3444
|
-
requestId: z.ZodString;
|
|
3445
|
-
position: z.ZodNumber;
|
|
3446
|
-
}, z.core.$strip>;
|
|
3447
|
-
|
|
3448
|
-
declare type MessageRequestCompleteEvent = z.infer<typeof MessageRequestCompleteEventSchema>;
|
|
3449
|
-
|
|
3450
|
-
declare const MessageRequestCompleteEventSchema: z.ZodObject<{
|
|
3451
|
-
type: z.ZodLiteral<"message_request_complete">;
|
|
3452
|
-
conversationId: z.ZodString;
|
|
3453
|
-
requestId: z.ZodString;
|
|
3454
|
-
runStillActive: z.ZodOptional<z.ZodBoolean>;
|
|
3455
|
-
}, z.core.$strip>;
|
|
3456
|
-
|
|
3457
3539
|
/** Allowed values for the `role` column on `messages`. */
|
|
3458
3540
|
declare type MessageRole = "user" | "assistant" | "system";
|
|
3459
3541
|
|
|
@@ -3475,41 +3557,6 @@ declare interface MessageRow {
|
|
|
3475
3557
|
finalized: number;
|
|
3476
3558
|
}
|
|
3477
3559
|
|
|
3478
|
-
declare type _MessagesServerMessages = UserMessageEchoEvent | AssistantTurnStartEvent | AssistantTextDeltaEvent | AssistantThinkingDeltaEvent | ToolUseStartEvent | ToolUsePreviewStartEvent | ToolOutputChunkEvent | ToolInputDeltaEvent | ToolResultEvent | ConfirmationRequestEvent | SecretRequestEvent | QuestionRequestEvent | MessageCompleteEvent | ErrorEvent_2 | MessageQueuedEvent | MessageDequeuedEvent | MessageRequestCompleteEvent | MessageQueuedDeletedEvent | MessageSteeredEvent | ConfirmationStateChangedEvent | AssistantActivityStateEvent | ConversationInferenceProfileUpdatedEvent | InteractionResolvedEvent;
|
|
3479
|
-
|
|
3480
|
-
declare type MessageSteeredEvent = z.infer<typeof MessageSteeredEventSchema>;
|
|
3481
|
-
|
|
3482
|
-
declare const MessageSteeredEventSchema: z.ZodObject<{
|
|
3483
|
-
type: z.ZodLiteral<"message_steered">;
|
|
3484
|
-
conversationId: z.ZodString;
|
|
3485
|
-
requestId: z.ZodString;
|
|
3486
|
-
}, z.core.$strip>;
|
|
3487
|
-
|
|
3488
|
-
declare type ModelInfoEvent = z.infer<typeof ModelInfoEventSchema>;
|
|
3489
|
-
|
|
3490
|
-
declare const ModelInfoEventSchema: z.ZodObject<{
|
|
3491
|
-
type: z.ZodLiteral<"model_info">;
|
|
3492
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
3493
|
-
model: z.ZodString;
|
|
3494
|
-
provider: z.ZodString;
|
|
3495
|
-
configuredProviders: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
3496
|
-
availableModels: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
3497
|
-
id: z.ZodString;
|
|
3498
|
-
displayName: z.ZodString;
|
|
3499
|
-
}, z.core.$strip>>>;
|
|
3500
|
-
allProviders: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
3501
|
-
id: z.ZodString;
|
|
3502
|
-
displayName: z.ZodString;
|
|
3503
|
-
models: z.ZodArray<z.ZodObject<{
|
|
3504
|
-
id: z.ZodString;
|
|
3505
|
-
displayName: z.ZodString;
|
|
3506
|
-
}, z.core.$strip>>;
|
|
3507
|
-
defaultModel: z.ZodString;
|
|
3508
|
-
apiKeyUrl: z.ZodOptional<z.ZodString>;
|
|
3509
|
-
apiKeyPlaceholder: z.ZodOptional<z.ZodString>;
|
|
3510
|
-
}, z.core.$strip>>>;
|
|
3511
|
-
}, z.core.$strip>;
|
|
3512
|
-
|
|
3513
3560
|
/**
|
|
3514
3561
|
* A workspace inference profile a plugin can route to. Returned by
|
|
3515
3562
|
* {@link getModelProfiles}; {@link key} is the value a `pre-model-call` hook
|
|
@@ -3539,72 +3586,6 @@ export declare interface ModelProfileInfo {
|
|
|
3539
3586
|
|
|
3540
3587
|
declare type MultimodalEmbeddingInput = TextEmbeddingInput | ImageEmbeddingInput | AudioEmbeddingInput | VideoEmbeddingInput;
|
|
3541
3588
|
|
|
3542
|
-
declare type NavigateSettingsEvent = z.infer<typeof NavigateSettingsEventSchema>;
|
|
3543
|
-
|
|
3544
|
-
declare const NavigateSettingsEventSchema: z.ZodObject<{
|
|
3545
|
-
type: z.ZodLiteral<"navigate_settings">;
|
|
3546
|
-
tab: z.ZodString;
|
|
3547
|
-
}, z.core.$strip>;
|
|
3548
|
-
|
|
3549
|
-
declare type NotificationConversationCreatedEvent = z.infer<typeof NotificationConversationCreatedEventSchema>;
|
|
3550
|
-
|
|
3551
|
-
declare const NotificationConversationCreatedEventSchema: z.ZodObject<{
|
|
3552
|
-
type: z.ZodLiteral<"notification_conversation_created">;
|
|
3553
|
-
conversationId: z.ZodString;
|
|
3554
|
-
title: z.ZodString;
|
|
3555
|
-
sourceEventName: z.ZodString;
|
|
3556
|
-
targetGuardianPrincipalId: z.ZodOptional<z.ZodString>;
|
|
3557
|
-
groupId: z.ZodOptional<z.ZodString>;
|
|
3558
|
-
source: z.ZodOptional<z.ZodString>;
|
|
3559
|
-
silent: z.ZodOptional<z.ZodBoolean>;
|
|
3560
|
-
}, z.core.$strip>;
|
|
3561
|
-
|
|
3562
|
-
declare type NotificationIntentEvent = z.infer<typeof NotificationIntentEventSchema>;
|
|
3563
|
-
|
|
3564
|
-
declare const NotificationIntentEventSchema: z.ZodObject<{
|
|
3565
|
-
type: z.ZodLiteral<"notification_intent">;
|
|
3566
|
-
sourceEventName: z.ZodString;
|
|
3567
|
-
title: z.ZodString;
|
|
3568
|
-
body: z.ZodString;
|
|
3569
|
-
deliveryId: z.ZodOptional<z.ZodString>;
|
|
3570
|
-
deepLinkMetadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
3571
|
-
targetGuardianPrincipalId: z.ZodOptional<z.ZodString>;
|
|
3572
|
-
silent: z.ZodOptional<z.ZodBoolean>;
|
|
3573
|
-
}, z.core.$strip>;
|
|
3574
|
-
|
|
3575
|
-
declare type _NotificationsServerMessages = NotificationIntentEvent | NotificationConversationCreatedEvent;
|
|
3576
|
-
|
|
3577
|
-
declare type OAuthConnectResultEvent = z.infer<typeof OAuthConnectResultEventSchema>;
|
|
3578
|
-
|
|
3579
|
-
declare const OAuthConnectResultEventSchema: z.ZodObject<{
|
|
3580
|
-
type: z.ZodLiteral<"oauth_connect_result">;
|
|
3581
|
-
success: z.ZodBoolean;
|
|
3582
|
-
service: z.ZodOptional<z.ZodString>;
|
|
3583
|
-
grantedScopes: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
3584
|
-
accountInfo: z.ZodOptional<z.ZodString>;
|
|
3585
|
-
error: z.ZodOptional<z.ZodString>;
|
|
3586
|
-
}, z.core.$strip>;
|
|
3587
|
-
|
|
3588
|
-
declare type OpenConversationEvent = z.infer<typeof OpenConversationEventSchema>;
|
|
3589
|
-
|
|
3590
|
-
declare const OpenConversationEventSchema: z.ZodObject<{
|
|
3591
|
-
type: z.ZodLiteral<"open_conversation">;
|
|
3592
|
-
conversationId: z.ZodString;
|
|
3593
|
-
title: z.ZodOptional<z.ZodString>;
|
|
3594
|
-
anchorMessageId: z.ZodOptional<z.ZodString>;
|
|
3595
|
-
focus: z.ZodOptional<z.ZodBoolean>;
|
|
3596
|
-
}, z.core.$strip>;
|
|
3597
|
-
|
|
3598
|
-
declare type OpenPanelEvent = z.infer<typeof OpenPanelEventSchema>;
|
|
3599
|
-
|
|
3600
|
-
declare const OpenPanelEventSchema: z.ZodObject<{
|
|
3601
|
-
type: z.ZodLiteral<"open_panel">;
|
|
3602
|
-
panelType: z.ZodString;
|
|
3603
|
-
data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
3604
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
3605
|
-
surfaceId: z.ZodOptional<z.ZodString>;
|
|
3606
|
-
}, z.core.$strip>;
|
|
3607
|
-
|
|
3608
3589
|
/**
|
|
3609
3590
|
* Open a streaming transcription session against the configured STT provider
|
|
3610
3591
|
* (`services.stt.provider`).
|
|
@@ -3626,15 +3607,6 @@ declare const OpenPanelEventSchema: z.ZodObject<{
|
|
|
3626
3607
|
*/
|
|
3627
3608
|
export declare function openTranscriptionSession(): Promise<StreamingTranscriber | null>;
|
|
3628
3609
|
|
|
3629
|
-
declare type OpenUrlEvent = z.infer<typeof OpenUrlEventSchema>;
|
|
3630
|
-
|
|
3631
|
-
declare const OpenUrlEventSchema: z.ZodObject<{
|
|
3632
|
-
type: z.ZodLiteral<"open_url">;
|
|
3633
|
-
url: z.ZodString;
|
|
3634
|
-
title: z.ZodOptional<z.ZodString>;
|
|
3635
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
3636
|
-
}, z.core.$strip>;
|
|
3637
|
-
|
|
3638
3610
|
/** Parse a stored message-metadata JSON string; undefined when absent/invalid. */
|
|
3639
3611
|
export declare function parseMessageMetadata(metadataJson: string | null): Promise<MessageMetadata>;
|
|
3640
3612
|
|
|
@@ -3648,12 +3620,6 @@ export declare function parseMessageMetadata(metadataJson: string | null): Promi
|
|
|
3648
3620
|
*/
|
|
3649
3621
|
declare function parseMessageMetadata_2(metadataJson: string | null): MessageMetadata_2 | undefined;
|
|
3650
3622
|
|
|
3651
|
-
declare type PlatformDisconnectedEvent = z.infer<typeof PlatformDisconnectedEventSchema>;
|
|
3652
|
-
|
|
3653
|
-
declare const PlatformDisconnectedEventSchema: z.ZodObject<{
|
|
3654
|
-
type: z.ZodLiteral<"platform_disconnected">;
|
|
3655
|
-
}, z.core.$strip>;
|
|
3656
|
-
|
|
3657
3623
|
/**
|
|
3658
3624
|
* The subset of {@link AssistantEventHub} workspace plugins may use. Picking
|
|
3659
3625
|
* method signatures off the class keeps the facade in sync with the hub while
|
|
@@ -4166,75 +4132,6 @@ export declare function quarantineRefusedExchanges(messages: Message[]): {
|
|
|
4166
4132
|
droppedExchanges: number;
|
|
4167
4133
|
};
|
|
4168
4134
|
|
|
4169
|
-
declare type QuestionRequestEvent = z.infer<typeof QuestionRequestEventSchema>;
|
|
4170
|
-
|
|
4171
|
-
declare const QuestionRequestEventSchema: z.ZodObject<{
|
|
4172
|
-
type: z.ZodLiteral<"question_request">;
|
|
4173
|
-
requestId: z.ZodString;
|
|
4174
|
-
questions: z.ZodArray<z.ZodObject<{
|
|
4175
|
-
id: z.ZodString;
|
|
4176
|
-
question: z.ZodString;
|
|
4177
|
-
description: z.ZodOptional<z.ZodString>;
|
|
4178
|
-
options: z.ZodArray<z.ZodObject<{
|
|
4179
|
-
id: z.ZodString;
|
|
4180
|
-
label: z.ZodString;
|
|
4181
|
-
description: z.ZodOptional<z.ZodString>;
|
|
4182
|
-
}, z.core.$strip>>;
|
|
4183
|
-
freeTextPlaceholder: z.ZodOptional<z.ZodString>;
|
|
4184
|
-
}, z.core.$strip>>;
|
|
4185
|
-
question: z.ZodString;
|
|
4186
|
-
description: z.ZodOptional<z.ZodString>;
|
|
4187
|
-
options: z.ZodArray<z.ZodObject<{
|
|
4188
|
-
id: z.ZodString;
|
|
4189
|
-
label: z.ZodString;
|
|
4190
|
-
description: z.ZodOptional<z.ZodString>;
|
|
4191
|
-
}, z.core.$strip>>;
|
|
4192
|
-
freeTextPlaceholder: z.ZodOptional<z.ZodString>;
|
|
4193
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
4194
|
-
toolUseId: z.ZodOptional<z.ZodString>;
|
|
4195
|
-
}, z.core.$strip>;
|
|
4196
|
-
|
|
4197
|
-
declare type RecordingPauseEvent = z.infer<typeof RecordingPauseEventSchema>;
|
|
4198
|
-
|
|
4199
|
-
declare const RecordingPauseEventSchema: z.ZodObject<{
|
|
4200
|
-
type: z.ZodLiteral<"recording_pause">;
|
|
4201
|
-
recordingId: z.ZodString;
|
|
4202
|
-
}, z.core.$strip>;
|
|
4203
|
-
|
|
4204
|
-
declare type RecordingResumeEvent = z.infer<typeof RecordingResumeEventSchema>;
|
|
4205
|
-
|
|
4206
|
-
declare const RecordingResumeEventSchema: z.ZodObject<{
|
|
4207
|
-
type: z.ZodLiteral<"recording_resume">;
|
|
4208
|
-
recordingId: z.ZodString;
|
|
4209
|
-
}, z.core.$strip>;
|
|
4210
|
-
|
|
4211
|
-
declare type RecordingStartEvent = z.infer<typeof RecordingStartEventSchema>;
|
|
4212
|
-
|
|
4213
|
-
declare const RecordingStartEventSchema: z.ZodObject<{
|
|
4214
|
-
type: z.ZodLiteral<"recording_start">;
|
|
4215
|
-
recordingId: z.ZodString;
|
|
4216
|
-
attachToConversationId: z.ZodOptional<z.ZodString>;
|
|
4217
|
-
options: z.ZodOptional<z.ZodObject<{
|
|
4218
|
-
captureScope: z.ZodOptional<z.ZodEnum<{
|
|
4219
|
-
display: "display";
|
|
4220
|
-
window: "window";
|
|
4221
|
-
}>>;
|
|
4222
|
-
displayId: z.ZodOptional<z.ZodString>;
|
|
4223
|
-
windowId: z.ZodOptional<z.ZodNumber>;
|
|
4224
|
-
includeAudio: z.ZodOptional<z.ZodBoolean>;
|
|
4225
|
-
includeMicrophone: z.ZodOptional<z.ZodBoolean>;
|
|
4226
|
-
promptForSource: z.ZodOptional<z.ZodBoolean>;
|
|
4227
|
-
}, z.core.$strip>>;
|
|
4228
|
-
operationToken: z.ZodOptional<z.ZodString>;
|
|
4229
|
-
}, z.core.$strip>;
|
|
4230
|
-
|
|
4231
|
-
declare type RecordingStopEvent = z.infer<typeof RecordingStopEventSchema>;
|
|
4232
|
-
|
|
4233
|
-
declare const RecordingStopEventSchema: z.ZodObject<{
|
|
4234
|
-
type: z.ZodLiteral<"recording_stop">;
|
|
4235
|
-
recordingId: z.ZodString;
|
|
4236
|
-
}, z.core.$strip>;
|
|
4237
|
-
|
|
4238
4135
|
export declare interface RedactedThinkingContent {
|
|
4239
4136
|
type: "redacted_thinking";
|
|
4240
4137
|
data: string;
|
|
@@ -4253,13 +4150,6 @@ export declare interface RedactedThinkingContent {
|
|
|
4253
4150
|
*/
|
|
4254
4151
|
export declare const REFUSAL_FALLBACK_TEXT = "Sorry \u2014 I wasn't able to generate a response to that. Please try rephrasing or asking in a different way.";
|
|
4255
4152
|
|
|
4256
|
-
declare type RelationshipStateUpdatedEvent = z.infer<typeof RelationshipStateUpdatedEventSchema>;
|
|
4257
|
-
|
|
4258
|
-
declare const RelationshipStateUpdatedEventSchema: z.ZodObject<{
|
|
4259
|
-
type: z.ZodLiteral<"relationship_state_updated">;
|
|
4260
|
-
updatedAt: z.ZodString;
|
|
4261
|
-
}, z.core.$strip>;
|
|
4262
|
-
|
|
4263
4153
|
declare type ResolutionFallbackReason = "missing" | "disabled" | "incomplete";
|
|
4264
4154
|
|
|
4265
4155
|
/**
|
|
@@ -4499,17 +4389,6 @@ export declare interface RunConversationTurnResult {
|
|
|
4499
4389
|
queued?: boolean;
|
|
4500
4390
|
}
|
|
4501
4391
|
|
|
4502
|
-
declare type ScheduleConversationCreatedEvent = z.infer<typeof ScheduleConversationCreatedEventSchema>;
|
|
4503
|
-
|
|
4504
|
-
declare const ScheduleConversationCreatedEventSchema: z.ZodObject<{
|
|
4505
|
-
type: z.ZodLiteral<"schedule_conversation_created">;
|
|
4506
|
-
conversationId: z.ZodString;
|
|
4507
|
-
scheduleJobId: z.ZodString;
|
|
4508
|
-
title: z.ZodString;
|
|
4509
|
-
}, z.core.$strip>;
|
|
4510
|
-
|
|
4511
|
-
declare type _SchedulesServerMessages = HeartbeatAlertEvent | HeartbeatConversationCreatedEvent;
|
|
4512
|
-
|
|
4513
4392
|
/** Sparse lexical search over stored message text; ranked message-id hits. */
|
|
4514
4393
|
export declare function searchMessageIdsLexical(query: string, limit: number, opts?: {
|
|
4515
4394
|
conversationId?: string;
|
|
@@ -4574,23 +4453,6 @@ declare interface SecretPromptResult {
|
|
|
4574
4453
|
collectionExpiresAt?: number;
|
|
4575
4454
|
}
|
|
4576
4455
|
|
|
4577
|
-
declare type SecretRequestEvent = z.infer<typeof SecretRequestEventSchema>;
|
|
4578
|
-
|
|
4579
|
-
declare const SecretRequestEventSchema: z.ZodObject<{
|
|
4580
|
-
type: z.ZodLiteral<"secret_request">;
|
|
4581
|
-
requestId: z.ZodString;
|
|
4582
|
-
service: z.ZodString;
|
|
4583
|
-
field: z.ZodString;
|
|
4584
|
-
label: z.ZodString;
|
|
4585
|
-
description: z.ZodOptional<z.ZodString>;
|
|
4586
|
-
placeholder: z.ZodOptional<z.ZodString>;
|
|
4587
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
4588
|
-
purpose: z.ZodOptional<z.ZodString>;
|
|
4589
|
-
allowedTools: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
4590
|
-
allowedDomains: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
4591
|
-
allowOneTimeSend: z.ZodOptional<z.ZodBoolean>;
|
|
4592
|
-
}, z.core.$strip>;
|
|
4593
|
-
|
|
4594
4456
|
/** Whether the active embedding backend handles multimodal inputs. */
|
|
4595
4457
|
export declare function selectedBackendSupportsMultimodal(): Promise<boolean>;
|
|
4596
4458
|
|
|
@@ -4712,8 +4574,6 @@ declare interface SensitiveOutputBinding {
|
|
|
4712
4574
|
|
|
4713
4575
|
declare type SensitiveOutputKind = "invite_code";
|
|
4714
4576
|
|
|
4715
|
-
declare type ServerMessage = _ConversationsServerMessages | _MessagesServerMessages | _SurfacesServerMessages | _SkillsServerMessages | _AppsServerMessages | _IntegrationsServerMessages | _ComputerUseServerMessages | _ContactsServerMessages | _SubagentsServerMessages | _DocumentsServerMessages | _DocumentCommentsServerMessages | _SyncInvalidationServerMessages | _HomeServerMessages | _HostAppControlServerMessages | _HostBashServerMessages | _HostBrowserServerMessages | _HostCuServerMessages | _HostFileServerMessages | _HostTransferServerMessages | _HostUiSnapshotServerMessages | _MemoryServerMessages | _WorkspaceServerMessages | _SchedulesServerMessages | _SettingsServerMessages | _NotificationsServerMessages | _UpgradesServerMessages | _AcpServerMessages | _BackgroundToolsServerMessages | _BookmarksServerMessages | _WorkflowsServerMessages | DiskPressureStatusChangedEvent | HookEvent | SubagentEventEvent;
|
|
4716
|
-
|
|
4717
4577
|
export declare interface ServerToolUseContent {
|
|
4718
4578
|
type: "server_tool_use";
|
|
4719
4579
|
id: string;
|
|
@@ -4721,38 +4581,6 @@ export declare interface ServerToolUseContent {
|
|
|
4721
4581
|
input: Record<string, unknown>;
|
|
4722
4582
|
}
|
|
4723
4583
|
|
|
4724
|
-
declare type ServiceGroupUpdateCompleteEvent = z.infer<typeof ServiceGroupUpdateCompleteEventSchema>;
|
|
4725
|
-
|
|
4726
|
-
declare const ServiceGroupUpdateCompleteEventSchema: z.ZodObject<{
|
|
4727
|
-
type: z.ZodLiteral<"service_group_update_complete">;
|
|
4728
|
-
installedVersion: z.ZodString;
|
|
4729
|
-
success: z.ZodBoolean;
|
|
4730
|
-
rolledBackToVersion: z.ZodOptional<z.ZodString>;
|
|
4731
|
-
}, z.core.$strip>;
|
|
4732
|
-
|
|
4733
|
-
declare type ServiceGroupUpdateProgressEvent = z.infer<typeof ServiceGroupUpdateProgressEventSchema>;
|
|
4734
|
-
|
|
4735
|
-
declare const ServiceGroupUpdateProgressEventSchema: z.ZodObject<{
|
|
4736
|
-
type: z.ZodLiteral<"service_group_update_progress">;
|
|
4737
|
-
statusMessage: z.ZodString;
|
|
4738
|
-
}, z.core.$strip>;
|
|
4739
|
-
|
|
4740
|
-
declare type ServiceGroupUpdateStartingEvent = z.infer<typeof ServiceGroupUpdateStartingEventSchema>;
|
|
4741
|
-
|
|
4742
|
-
declare const ServiceGroupUpdateStartingEventSchema: z.ZodObject<{
|
|
4743
|
-
type: z.ZodLiteral<"service_group_update_starting">;
|
|
4744
|
-
targetVersion: z.ZodString;
|
|
4745
|
-
expectedDowntimeSeconds: z.ZodNumber;
|
|
4746
|
-
}, z.core.$strip>;
|
|
4747
|
-
|
|
4748
|
-
declare type _SettingsServerMessages = ClientSettingsUpdateEvent | AvatarUpdatedEvent | ConfigChangedEvent | SoundsConfigUpdatedEvent;
|
|
4749
|
-
|
|
4750
|
-
declare type ShowPlatformLoginEvent = z.infer<typeof ShowPlatformLoginEventSchema>;
|
|
4751
|
-
|
|
4752
|
-
declare const ShowPlatformLoginEventSchema: z.ZodObject<{
|
|
4753
|
-
type: z.ZodLiteral<"show_platform_login">;
|
|
4754
|
-
}, z.core.$strip>;
|
|
4755
|
-
|
|
4756
4584
|
/**
|
|
4757
4585
|
* Context passed to the `shutdown` hook. Kept intentionally narrower than
|
|
4758
4586
|
* {@link InitContext} — teardown paths only need to know which assistant
|
|
@@ -4823,27 +4651,6 @@ declare interface SkillInstallMeta {
|
|
|
4823
4651
|
*/
|
|
4824
4652
|
declare type SkillSource = "bundled" | "managed" | "workspace" | "extra" | "plugin";
|
|
4825
4653
|
|
|
4826
|
-
declare type _SkillsServerMessages = SkillStateChangedEvent;
|
|
4827
|
-
|
|
4828
|
-
declare type SkillStateChangedEvent = z.infer<typeof SkillStateChangedEventSchema>;
|
|
4829
|
-
|
|
4830
|
-
declare const SkillStateChangedEventSchema: z.ZodObject<{
|
|
4831
|
-
type: z.ZodLiteral<"skills_state_changed">;
|
|
4832
|
-
name: z.ZodString;
|
|
4833
|
-
state: z.ZodEnum<{
|
|
4834
|
-
enabled: "enabled";
|
|
4835
|
-
disabled: "disabled";
|
|
4836
|
-
installed: "installed";
|
|
4837
|
-
uninstalled: "uninstalled";
|
|
4838
|
-
}>;
|
|
4839
|
-
}, z.core.$strip>;
|
|
4840
|
-
|
|
4841
|
-
declare type SoundsConfigUpdatedEvent = z.infer<typeof SoundsConfigUpdatedEventSchema>;
|
|
4842
|
-
|
|
4843
|
-
declare const SoundsConfigUpdatedEventSchema: z.ZodObject<{
|
|
4844
|
-
type: z.ZodLiteral<"sounds_config_updated">;
|
|
4845
|
-
}, z.core.$strip>;
|
|
4846
|
-
|
|
4847
4654
|
/**
|
|
4848
4655
|
* The full `stop` context a hook receives — the dispatching call site's
|
|
4849
4656
|
* {@link StopInputContext} plus the pipeline-stamped {@link BaseHookContext}
|
|
@@ -5075,60 +4882,6 @@ export declare interface SttStreamServerPartialEvent {
|
|
|
5075
4882
|
readonly confidence?: number;
|
|
5076
4883
|
}
|
|
5077
4884
|
|
|
5078
|
-
declare type SubagentEventEvent = z.infer<typeof SubagentEventEventSchema>;
|
|
5079
|
-
|
|
5080
|
-
declare const SubagentEventEventSchema: z.ZodObject<{
|
|
5081
|
-
type: z.ZodLiteral<"subagent_event">;
|
|
5082
|
-
conversationId: z.ZodString;
|
|
5083
|
-
subagentId: z.ZodString;
|
|
5084
|
-
event: z.ZodObject<{
|
|
5085
|
-
type: z.ZodString;
|
|
5086
|
-
content: z.ZodOptional<z.ZodString>;
|
|
5087
|
-
text: z.ZodOptional<z.ZodString>;
|
|
5088
|
-
result: z.ZodOptional<z.ZodString>;
|
|
5089
|
-
input: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
5090
|
-
toolName: z.ZodOptional<z.ZodString>;
|
|
5091
|
-
isError: z.ZodOptional<z.ZodBoolean>;
|
|
5092
|
-
toolUseId: z.ZodOptional<z.ZodString>;
|
|
5093
|
-
}, z.core.$loose>;
|
|
5094
|
-
}, z.core.$strict>;
|
|
5095
|
-
|
|
5096
|
-
declare type SubagentSpawnedEvent = z.infer<typeof SubagentSpawnedEventSchema>;
|
|
5097
|
-
|
|
5098
|
-
declare const SubagentSpawnedEventSchema: z.ZodObject<{
|
|
5099
|
-
type: z.ZodLiteral<"subagent_spawned">;
|
|
5100
|
-
subagentId: z.ZodString;
|
|
5101
|
-
parentConversationId: z.ZodString;
|
|
5102
|
-
label: z.ZodString;
|
|
5103
|
-
objective: z.ZodString;
|
|
5104
|
-
isFork: z.ZodOptional<z.ZodBoolean>;
|
|
5105
|
-
parentToolUseId: z.ZodOptional<z.ZodString>;
|
|
5106
|
-
}, z.core.$strict>;
|
|
5107
|
-
|
|
5108
|
-
declare type _SubagentsServerMessages = SubagentSpawnedEvent | SubagentStatusChangedEvent;
|
|
5109
|
-
|
|
5110
|
-
declare type SubagentStatusChangedEvent = z.infer<typeof SubagentStatusChangedEventSchema>;
|
|
5111
|
-
|
|
5112
|
-
declare const SubagentStatusChangedEventSchema: z.ZodObject<{
|
|
5113
|
-
type: z.ZodLiteral<"subagent_status_changed">;
|
|
5114
|
-
subagentId: z.ZodString;
|
|
5115
|
-
status: z.ZodEnum<{
|
|
5116
|
-
completed: "completed";
|
|
5117
|
-
failed: "failed";
|
|
5118
|
-
running: "running";
|
|
5119
|
-
pending: "pending";
|
|
5120
|
-
awaiting_input: "awaiting_input";
|
|
5121
|
-
aborted: "aborted";
|
|
5122
|
-
interrupted: "interrupted";
|
|
5123
|
-
}>;
|
|
5124
|
-
error: z.ZodOptional<z.ZodString>;
|
|
5125
|
-
usage: z.ZodOptional<z.ZodObject<{
|
|
5126
|
-
inputTokens: z.ZodNumber;
|
|
5127
|
-
outputTokens: z.ZodNumber;
|
|
5128
|
-
estimatedCost: z.ZodNumber;
|
|
5129
|
-
}, z.core.$strict>>;
|
|
5130
|
-
}, z.core.$strict>;
|
|
5131
|
-
|
|
5132
4885
|
declare type SubscriberEntry = ClientEntry | ProcessEntry;
|
|
5133
4886
|
|
|
5134
4887
|
/** Input shape for `subscribe()` — hub fills `active`, `connectedAt`, `lastActiveAt`, `connectionId` and defaults `filter`/`onEvict`. */
|
|
@@ -5137,8 +4890,6 @@ declare type SubscriberInput = DistributiveOmit<SubscriberEntry, "active" | "con
|
|
|
5137
4890
|
onEvict?: () => void;
|
|
5138
4891
|
};
|
|
5139
4892
|
|
|
5140
|
-
declare type _SurfacesServerMessages = UISurfaceShowEvent | UISurfaceUpdateEvent | UISurfaceDismissEvent | UISurfaceCompleteEvent | UISurfaceUndoResultEvent;
|
|
5141
|
-
|
|
5142
4893
|
/**
|
|
5143
4894
|
* Delete `graph_node` Qdrant points whose backing `memory_graph_nodes` row no
|
|
5144
4895
|
* longer exists.
|
|
@@ -5167,16 +4918,6 @@ declare type _SurfacesServerMessages = UISurfaceShowEvent | UISurfaceUpdateEvent
|
|
|
5167
4918
|
*/
|
|
5168
4919
|
export declare function sweepOrphanedGraphNodePoints(qdrant: GraphNodeSweepClient): Promise<GraphNodeSweepResult>;
|
|
5169
4920
|
|
|
5170
|
-
declare type SyncChangedEvent = z.infer<typeof SyncChangedEventSchema>;
|
|
5171
|
-
|
|
5172
|
-
declare const SyncChangedEventSchema: z.ZodObject<{
|
|
5173
|
-
type: z.ZodLiteral<"sync_changed">;
|
|
5174
|
-
tags: z.ZodArray<z.ZodString>;
|
|
5175
|
-
originClientId: z.ZodOptional<z.ZodString>;
|
|
5176
|
-
}, z.core.$strip>;
|
|
5177
|
-
|
|
5178
|
-
declare type _SyncInvalidationServerMessages = SyncChangedEvent;
|
|
5179
|
-
|
|
5180
4921
|
/** Re-sync one persisted message into the conversation's disk view. */
|
|
5181
4922
|
export declare function syncMessageToDisk(conversationId: string, messageId: string, createdAtMs: number): Promise<void>;
|
|
5182
4923
|
|
|
@@ -5650,36 +5391,6 @@ export declare interface ToolExecutionResult {
|
|
|
5650
5391
|
activityMetadata?: ToolActivityMetadata;
|
|
5651
5392
|
}
|
|
5652
5393
|
|
|
5653
|
-
declare type ToolInputDeltaEvent = z.infer<typeof ToolInputDeltaEventSchema>;
|
|
5654
|
-
|
|
5655
|
-
declare const ToolInputDeltaEventSchema: z.ZodObject<{
|
|
5656
|
-
type: z.ZodLiteral<"tool_input_delta">;
|
|
5657
|
-
toolName: z.ZodString;
|
|
5658
|
-
content: z.ZodString;
|
|
5659
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
5660
|
-
toolUseId: z.ZodOptional<z.ZodString>;
|
|
5661
|
-
messageId: z.ZodOptional<z.ZodString>;
|
|
5662
|
-
}, z.core.$strip>;
|
|
5663
|
-
|
|
5664
|
-
declare type ToolOutputChunkEvent = z.infer<typeof ToolOutputChunkEventSchema>;
|
|
5665
|
-
|
|
5666
|
-
declare const ToolOutputChunkEventSchema: z.ZodObject<{
|
|
5667
|
-
type: z.ZodLiteral<"tool_output_chunk">;
|
|
5668
|
-
chunk: z.ZodString;
|
|
5669
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
5670
|
-
toolUseId: z.ZodOptional<z.ZodString>;
|
|
5671
|
-
subType: z.ZodOptional<z.ZodEnum<{
|
|
5672
|
-
status: "status";
|
|
5673
|
-
tool_start: "tool_start";
|
|
5674
|
-
tool_complete: "tool_complete";
|
|
5675
|
-
}>>;
|
|
5676
|
-
subToolName: z.ZodOptional<z.ZodString>;
|
|
5677
|
-
subToolInput: z.ZodOptional<z.ZodString>;
|
|
5678
|
-
subToolIsError: z.ZodOptional<z.ZodBoolean>;
|
|
5679
|
-
subToolId: z.ZodOptional<z.ZodString>;
|
|
5680
|
-
messageId: z.ZodOptional<z.ZodString>;
|
|
5681
|
-
}, z.core.$strip>;
|
|
5682
|
-
|
|
5683
5394
|
export declare interface ToolResultContent {
|
|
5684
5395
|
type: "tool_result";
|
|
5685
5396
|
tool_use_id: string;
|
|
@@ -5689,94 +5400,6 @@ export declare interface ToolResultContent {
|
|
|
5689
5400
|
contentBlocks?: ContentBlock[];
|
|
5690
5401
|
}
|
|
5691
5402
|
|
|
5692
|
-
declare type ToolResultEvent = z.infer<typeof ToolResultEventSchema>;
|
|
5693
|
-
|
|
5694
|
-
declare const ToolResultEventSchema: z.ZodObject<{
|
|
5695
|
-
type: z.ZodLiteral<"tool_result">;
|
|
5696
|
-
toolName: z.ZodString;
|
|
5697
|
-
result: z.ZodString;
|
|
5698
|
-
isError: z.ZodOptional<z.ZodBoolean>;
|
|
5699
|
-
diff: z.ZodOptional<z.ZodObject<{
|
|
5700
|
-
filePath: z.ZodString;
|
|
5701
|
-
oldContent: z.ZodString;
|
|
5702
|
-
newContent: z.ZodString;
|
|
5703
|
-
isNewFile: z.ZodBoolean;
|
|
5704
|
-
}, z.core.$strip>>;
|
|
5705
|
-
status: z.ZodOptional<z.ZodString>;
|
|
5706
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
5707
|
-
imageData: z.ZodOptional<z.ZodString>;
|
|
5708
|
-
imageDataList: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
5709
|
-
toolUseId: z.ZodOptional<z.ZodString>;
|
|
5710
|
-
messageId: z.ZodOptional<z.ZodString>;
|
|
5711
|
-
riskLevel: z.ZodOptional<z.ZodString>;
|
|
5712
|
-
riskReason: z.ZodOptional<z.ZodString>;
|
|
5713
|
-
matchedTrustRuleId: z.ZodOptional<z.ZodString>;
|
|
5714
|
-
isContainerized: z.ZodOptional<z.ZodBoolean>;
|
|
5715
|
-
riskScopeOptions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
5716
|
-
pattern: z.ZodString;
|
|
5717
|
-
label: z.ZodString;
|
|
5718
|
-
}, z.core.$strip>>>;
|
|
5719
|
-
riskAllowlistOptions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
5720
|
-
label: z.ZodString;
|
|
5721
|
-
description: z.ZodString;
|
|
5722
|
-
pattern: z.ZodString;
|
|
5723
|
-
}, z.core.$strip>>>;
|
|
5724
|
-
riskDirectoryScopeOptions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
5725
|
-
label: z.ZodString;
|
|
5726
|
-
scope: z.ZodString;
|
|
5727
|
-
}, z.core.$strip>>>;
|
|
5728
|
-
approvalMode: z.ZodOptional<z.ZodString>;
|
|
5729
|
-
approvalReason: z.ZodOptional<z.ZodString>;
|
|
5730
|
-
riskThreshold: z.ZodOptional<z.ZodString>;
|
|
5731
|
-
activityMetadata: z.ZodOptional<z.ZodObject<{
|
|
5732
|
-
webSearch: z.ZodOptional<z.ZodObject<{
|
|
5733
|
-
query: z.ZodString;
|
|
5734
|
-
provider: z.ZodEnum<{
|
|
5735
|
-
"anthropic-native": "anthropic-native";
|
|
5736
|
-
brave: "brave";
|
|
5737
|
-
perplexity: "perplexity";
|
|
5738
|
-
tavily: "tavily";
|
|
5739
|
-
firecrawl: "firecrawl";
|
|
5740
|
-
}>;
|
|
5741
|
-
resultCount: z.ZodNumber;
|
|
5742
|
-
durationMs: z.ZodNumber;
|
|
5743
|
-
results: z.ZodArray<z.ZodObject<{
|
|
5744
|
-
rank: z.ZodNumber;
|
|
5745
|
-
title: z.ZodString;
|
|
5746
|
-
url: z.ZodString;
|
|
5747
|
-
domain: z.ZodString;
|
|
5748
|
-
faviconUrl: z.ZodOptional<z.ZodString>;
|
|
5749
|
-
snippet: z.ZodOptional<z.ZodString>;
|
|
5750
|
-
age: z.ZodOptional<z.ZodString>;
|
|
5751
|
-
score: z.ZodOptional<z.ZodNumber>;
|
|
5752
|
-
}, z.core.$strip>>;
|
|
5753
|
-
errorMessage: z.ZodOptional<z.ZodString>;
|
|
5754
|
-
}, z.core.$strip>>;
|
|
5755
|
-
webFetch: z.ZodOptional<z.ZodObject<{
|
|
5756
|
-
url: z.ZodString;
|
|
5757
|
-
finalUrl: z.ZodString;
|
|
5758
|
-
provider: z.ZodOptional<z.ZodEnum<{
|
|
5759
|
-
default: "default";
|
|
5760
|
-
firecrawl: "firecrawl";
|
|
5761
|
-
}>>;
|
|
5762
|
-
status: z.ZodNumber;
|
|
5763
|
-
contentType: z.ZodOptional<z.ZodString>;
|
|
5764
|
-
byteCount: z.ZodNumber;
|
|
5765
|
-
charCount: z.ZodNumber;
|
|
5766
|
-
truncated: z.ZodBoolean;
|
|
5767
|
-
title: z.ZodOptional<z.ZodString>;
|
|
5768
|
-
domain: z.ZodString;
|
|
5769
|
-
faviconUrl: z.ZodOptional<z.ZodString>;
|
|
5770
|
-
redirectCount: z.ZodNumber;
|
|
5771
|
-
durationMs: z.ZodNumber;
|
|
5772
|
-
errorMessage: z.ZodOptional<z.ZodString>;
|
|
5773
|
-
mayRequireJavaScript: z.ZodOptional<z.ZodBoolean>;
|
|
5774
|
-
}, z.core.$strip>>;
|
|
5775
|
-
}, z.core.$strip>>;
|
|
5776
|
-
errorCode: z.ZodOptional<z.ZodString>;
|
|
5777
|
-
completedAt: z.ZodOptional<z.ZodNumber>;
|
|
5778
|
-
}, z.core.$strip>;
|
|
5779
|
-
|
|
5780
5403
|
export declare interface ToolUseContent {
|
|
5781
5404
|
type: "tool_use";
|
|
5782
5405
|
id: string;
|
|
@@ -5789,30 +5412,6 @@ export declare interface ToolUseContent {
|
|
|
5789
5412
|
};
|
|
5790
5413
|
}
|
|
5791
5414
|
|
|
5792
|
-
declare type ToolUsePreviewStartEvent = z.infer<typeof ToolUsePreviewStartEventSchema>;
|
|
5793
|
-
|
|
5794
|
-
declare const ToolUsePreviewStartEventSchema: z.ZodObject<{
|
|
5795
|
-
type: z.ZodLiteral<"tool_use_preview_start">;
|
|
5796
|
-
toolUseId: z.ZodString;
|
|
5797
|
-
toolName: z.ZodString;
|
|
5798
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
5799
|
-
messageId: z.ZodOptional<z.ZodString>;
|
|
5800
|
-
previewStartedAt: z.ZodOptional<z.ZodNumber>;
|
|
5801
|
-
}, z.core.$strip>;
|
|
5802
|
-
|
|
5803
|
-
declare type ToolUseStartEvent = z.infer<typeof ToolUseStartEventSchema>;
|
|
5804
|
-
|
|
5805
|
-
declare const ToolUseStartEventSchema: z.ZodObject<{
|
|
5806
|
-
type: z.ZodLiteral<"tool_use_start">;
|
|
5807
|
-
toolName: z.ZodString;
|
|
5808
|
-
input: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
5809
|
-
toolUseId: z.ZodOptional<z.ZodString>;
|
|
5810
|
-
messageId: z.ZodOptional<z.ZodString>;
|
|
5811
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
5812
|
-
startedAt: z.ZodOptional<z.ZodNumber>;
|
|
5813
|
-
previewStartedAt: z.ZodOptional<z.ZodNumber>;
|
|
5814
|
-
}, z.core.$strip>;
|
|
5815
|
-
|
|
5816
5415
|
declare type TrustClass = z.infer<typeof trustClassSchema>;
|
|
5817
5416
|
|
|
5818
5417
|
declare const trustClassSchema: z.ZodEnum<{
|
|
@@ -5847,76 +5446,9 @@ declare type TtsUseCase =
|
|
|
5847
5446
|
/** In-app message playback — buffer-oriented, higher quality acceptable. */
|
|
5848
5447
|
| "message-playback";
|
|
5849
5448
|
|
|
5850
|
-
declare type UISurfaceCompleteEvent = z.infer<typeof UISurfaceCompleteEventSchema>;
|
|
5851
|
-
|
|
5852
|
-
declare const UISurfaceCompleteEventSchema: z.ZodObject<{
|
|
5853
|
-
type: z.ZodLiteral<"ui_surface_complete">;
|
|
5854
|
-
conversationId: z.ZodString;
|
|
5855
|
-
surfaceId: z.ZodString;
|
|
5856
|
-
summary: z.ZodString;
|
|
5857
|
-
submittedData: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
5858
|
-
}, z.core.$strip>;
|
|
5859
|
-
|
|
5860
|
-
declare type UISurfaceDismissEvent = z.infer<typeof UISurfaceDismissEventSchema>;
|
|
5861
|
-
|
|
5862
|
-
declare const UISurfaceDismissEventSchema: z.ZodObject<{
|
|
5863
|
-
type: z.ZodLiteral<"ui_surface_dismiss">;
|
|
5864
|
-
conversationId: z.ZodString;
|
|
5865
|
-
surfaceId: z.ZodString;
|
|
5866
|
-
}, z.core.$strip>;
|
|
5867
|
-
|
|
5868
|
-
declare type UISurfaceShowEvent = z.infer<typeof UISurfaceShowEventSchema>;
|
|
5869
|
-
|
|
5870
|
-
declare const UISurfaceShowEventSchema: z.ZodObject<{
|
|
5871
|
-
type: z.ZodLiteral<"ui_surface_show">;
|
|
5872
|
-
conversationId: z.ZodString;
|
|
5873
|
-
surfaceId: z.ZodString;
|
|
5874
|
-
surfaceType: z.ZodString;
|
|
5875
|
-
title: z.ZodOptional<z.ZodString>;
|
|
5876
|
-
data: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
5877
|
-
actions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
5878
|
-
id: z.ZodString;
|
|
5879
|
-
label: z.ZodString;
|
|
5880
|
-
style: z.ZodOptional<z.ZodEnum<{
|
|
5881
|
-
primary: "primary";
|
|
5882
|
-
secondary: "secondary";
|
|
5883
|
-
destructive: "destructive";
|
|
5884
|
-
}>>;
|
|
5885
|
-
data: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
5886
|
-
}, z.core.$strip>>>;
|
|
5887
|
-
display: z.ZodOptional<z.ZodEnum<{
|
|
5888
|
-
inline: "inline";
|
|
5889
|
-
panel: "panel";
|
|
5890
|
-
}>>;
|
|
5891
|
-
messageId: z.ZodOptional<z.ZodString>;
|
|
5892
|
-
persistent: z.ZodOptional<z.ZodBoolean>;
|
|
5893
|
-
toolCallId: z.ZodOptional<z.ZodString>;
|
|
5894
|
-
}, z.core.$strip>;
|
|
5895
|
-
|
|
5896
|
-
declare type UISurfaceUndoResultEvent = z.infer<typeof UISurfaceUndoResultEventSchema>;
|
|
5897
|
-
|
|
5898
|
-
declare const UISurfaceUndoResultEventSchema: z.ZodObject<{
|
|
5899
|
-
type: z.ZodLiteral<"ui_surface_undo_result">;
|
|
5900
|
-
conversationId: z.ZodString;
|
|
5901
|
-
surfaceId: z.ZodString;
|
|
5902
|
-
success: z.ZodBoolean;
|
|
5903
|
-
remainingUndos: z.ZodNumber;
|
|
5904
|
-
}, z.core.$strip>;
|
|
5905
|
-
|
|
5906
|
-
declare type UISurfaceUpdateEvent = z.infer<typeof UISurfaceUpdateEventSchema>;
|
|
5907
|
-
|
|
5908
|
-
declare const UISurfaceUpdateEventSchema: z.ZodObject<{
|
|
5909
|
-
type: z.ZodLiteral<"ui_surface_update">;
|
|
5910
|
-
conversationId: z.ZodString;
|
|
5911
|
-
surfaceId: z.ZodString;
|
|
5912
|
-
data: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
5913
|
-
}, z.core.$strip>;
|
|
5914
|
-
|
|
5915
5449
|
/** Merge the given keys into a message's metadata JSON. */
|
|
5916
5450
|
export declare function updateMessageMetadata(messageId: string, updates: Record<string, unknown>): Promise<void>;
|
|
5917
5451
|
|
|
5918
|
-
declare type _UpgradesServerMessages = ServiceGroupUpdateStartingEvent | ServiceGroupUpdateProgressEvent | ServiceGroupUpdateCompleteEvent;
|
|
5919
|
-
|
|
5920
5452
|
declare type UsageAttributionProfileSource = "call_site" | "conversation" | "active" | "default" | "unknown";
|
|
5921
5453
|
|
|
5922
5454
|
declare interface UsageAttributionSnapshot {
|
|
@@ -5936,45 +5468,6 @@ declare interface UsageAttributionSnapshot {
|
|
|
5936
5468
|
resolvedMixArm: string | null;
|
|
5937
5469
|
}
|
|
5938
5470
|
|
|
5939
|
-
declare type UsageProgressEvent = z.infer<typeof UsageProgressEventSchema>;
|
|
5940
|
-
|
|
5941
|
-
declare const UsageProgressEventSchema: z.ZodObject<{
|
|
5942
|
-
type: z.ZodLiteral<"usage_progress">;
|
|
5943
|
-
conversationId: z.ZodString;
|
|
5944
|
-
inputTokens: z.ZodNumber;
|
|
5945
|
-
outputTokens: z.ZodNumber;
|
|
5946
|
-
estimatedCost: z.ZodNumber;
|
|
5947
|
-
model: z.ZodString;
|
|
5948
|
-
}, z.core.$strip>;
|
|
5949
|
-
|
|
5950
|
-
declare type UsageUpdateEvent = z.infer<typeof UsageUpdateEventSchema>;
|
|
5951
|
-
|
|
5952
|
-
declare const UsageUpdateEventSchema: z.ZodObject<{
|
|
5953
|
-
type: z.ZodLiteral<"usage_update">;
|
|
5954
|
-
conversationId: z.ZodString;
|
|
5955
|
-
inputTokens: z.ZodNumber;
|
|
5956
|
-
outputTokens: z.ZodNumber;
|
|
5957
|
-
cacheCreationInputTokens: z.ZodOptional<z.ZodNumber>;
|
|
5958
|
-
cacheReadInputTokens: z.ZodOptional<z.ZodNumber>;
|
|
5959
|
-
totalInputTokens: z.ZodNumber;
|
|
5960
|
-
totalOutputTokens: z.ZodNumber;
|
|
5961
|
-
estimatedCost: z.ZodNumber;
|
|
5962
|
-
model: z.ZodString;
|
|
5963
|
-
contextWindowTokens: z.ZodOptional<z.ZodNumber>;
|
|
5964
|
-
contextWindowMaxTokens: z.ZodOptional<z.ZodNumber>;
|
|
5965
|
-
}, z.core.$strip>;
|
|
5966
|
-
|
|
5967
|
-
declare type UserMessageEchoEvent = z.infer<typeof UserMessageEchoEventSchema>;
|
|
5968
|
-
|
|
5969
|
-
declare const UserMessageEchoEventSchema: z.ZodObject<{
|
|
5970
|
-
type: z.ZodLiteral<"user_message_echo">;
|
|
5971
|
-
text: z.ZodString;
|
|
5972
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
5973
|
-
messageId: z.ZodOptional<z.ZodString>;
|
|
5974
|
-
requestId: z.ZodOptional<z.ZodString>;
|
|
5975
|
-
clientMessageId: z.ZodOptional<z.ZodString>;
|
|
5976
|
-
}, z.core.$strict>;
|
|
5977
|
-
|
|
5978
5471
|
/**
|
|
5979
5472
|
* The full `user-prompt-submit` context a hook receives — the dispatching
|
|
5980
5473
|
* call site's {@link UserPromptSubmitInputContext} plus the pipeline-stamped
|
|
@@ -6139,79 +5632,6 @@ export declare interface WebSearchToolResultContent {
|
|
|
6139
5632
|
content: unknown;
|
|
6140
5633
|
}
|
|
6141
5634
|
|
|
6142
|
-
declare type WorkflowCompletedEvent = z.infer<typeof WorkflowCompletedEventSchema>;
|
|
6143
|
-
|
|
6144
|
-
declare const WorkflowCompletedEventSchema: z.ZodObject<{
|
|
6145
|
-
type: z.ZodLiteral<"workflow_completed">;
|
|
6146
|
-
runId: z.ZodString;
|
|
6147
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
6148
|
-
status: z.ZodEnum<{
|
|
6149
|
-
completed: "completed";
|
|
6150
|
-
failed: "failed";
|
|
6151
|
-
running: "running";
|
|
6152
|
-
aborted: "aborted";
|
|
6153
|
-
interrupted: "interrupted";
|
|
6154
|
-
cap_exceeded: "cap_exceeded";
|
|
6155
|
-
}>;
|
|
6156
|
-
agentsSpawned: z.ZodNumber;
|
|
6157
|
-
inputTokens: z.ZodNumber;
|
|
6158
|
-
outputTokens: z.ZodNumber;
|
|
6159
|
-
summary: z.ZodOptional<z.ZodString>;
|
|
6160
|
-
}, z.core.$strict>;
|
|
6161
|
-
|
|
6162
|
-
declare type WorkflowLeafFinishedEvent = z.infer<typeof WorkflowLeafFinishedEventSchema>;
|
|
6163
|
-
|
|
6164
|
-
declare const WorkflowLeafFinishedEventSchema: z.ZodObject<{
|
|
6165
|
-
type: z.ZodLiteral<"workflow_leaf_finished">;
|
|
6166
|
-
runId: z.ZodString;
|
|
6167
|
-
conversationId: z.ZodString;
|
|
6168
|
-
seq: z.ZodNumber;
|
|
6169
|
-
status: z.ZodEnum<{
|
|
6170
|
-
completed: "completed";
|
|
6171
|
-
failed: "failed";
|
|
6172
|
-
}>;
|
|
6173
|
-
label: z.ZodOptional<z.ZodString>;
|
|
6174
|
-
inputTokens: z.ZodOptional<z.ZodNumber>;
|
|
6175
|
-
outputTokens: z.ZodOptional<z.ZodNumber>;
|
|
6176
|
-
resultSummary: z.ZodOptional<z.ZodString>;
|
|
6177
|
-
}, z.core.$strict>;
|
|
6178
|
-
|
|
6179
|
-
declare type WorkflowLeafStartedEvent = z.infer<typeof WorkflowLeafStartedEventSchema>;
|
|
6180
|
-
|
|
6181
|
-
declare const WorkflowLeafStartedEventSchema: z.ZodObject<{
|
|
6182
|
-
type: z.ZodLiteral<"workflow_leaf_started">;
|
|
6183
|
-
runId: z.ZodString;
|
|
6184
|
-
conversationId: z.ZodString;
|
|
6185
|
-
seq: z.ZodNumber;
|
|
6186
|
-
label: z.ZodOptional<z.ZodString>;
|
|
6187
|
-
phase: z.ZodOptional<z.ZodString>;
|
|
6188
|
-
promptSummary: z.ZodOptional<z.ZodString>;
|
|
6189
|
-
}, z.core.$strict>;
|
|
6190
|
-
|
|
6191
|
-
declare type WorkflowProgressEvent = z.infer<typeof WorkflowProgressEventSchema>;
|
|
6192
|
-
|
|
6193
|
-
declare const WorkflowProgressEventSchema: z.ZodObject<{
|
|
6194
|
-
type: z.ZodLiteral<"workflow_progress">;
|
|
6195
|
-
runId: z.ZodString;
|
|
6196
|
-
conversationId: z.ZodOptional<z.ZodString>;
|
|
6197
|
-
agentsSpawned: z.ZodNumber;
|
|
6198
|
-
phase: z.ZodOptional<z.ZodString>;
|
|
6199
|
-
label: z.ZodOptional<z.ZodString>;
|
|
6200
|
-
message: z.ZodOptional<z.ZodString>;
|
|
6201
|
-
}, z.core.$strict>;
|
|
6202
|
-
|
|
6203
|
-
declare type _WorkflowsServerMessages = WorkflowProgressEvent | WorkflowCompletedEvent | WorkflowStartedEvent | WorkflowLeafStartedEvent | WorkflowLeafFinishedEvent;
|
|
6204
|
-
|
|
6205
|
-
declare type WorkflowStartedEvent = z.infer<typeof WorkflowStartedEventSchema>;
|
|
6206
|
-
|
|
6207
|
-
declare const WorkflowStartedEventSchema: z.ZodObject<{
|
|
6208
|
-
type: z.ZodLiteral<"workflow_started">;
|
|
6209
|
-
runId: z.ZodString;
|
|
6210
|
-
conversationId: z.ZodString;
|
|
6211
|
-
toolUseId: z.ZodOptional<z.ZodString>;
|
|
6212
|
-
label: z.ZodOptional<z.ZodString>;
|
|
6213
|
-
}, z.core.$strict>;
|
|
6214
|
-
|
|
6215
5635
|
/**
|
|
6216
5636
|
* A reference to bytes stored in the workspace rather than inlined. The bytes
|
|
6217
5637
|
* live in the workspace attachment store, addressed by `attachmentId`, and are
|
|
@@ -6237,6 +5657,4 @@ declare interface WorkspaceRefMediaSource {
|
|
|
6237
5657
|
height?: number;
|
|
6238
5658
|
}
|
|
6239
5659
|
|
|
6240
|
-
declare type _WorkspaceServerMessages = IdentityChangedEvent;
|
|
6241
|
-
|
|
6242
5660
|
export { }
|