@ag-ui/core 0.0.40-alpha.3 → 0.0.40-alpha.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +727 -0
- package/dist/index.d.ts +727 -0
- package/dist/index.js +4 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +4 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -339,6 +339,7 @@ declare const ToolSchema: z.ZodObject<{
|
|
|
339
339
|
declare const RunAgentInputSchema: z.ZodObject<{
|
|
340
340
|
threadId: z.ZodString;
|
|
341
341
|
runId: z.ZodString;
|
|
342
|
+
parentRunId: z.ZodOptional<z.ZodString>;
|
|
342
343
|
state: z.ZodAny;
|
|
343
344
|
messages: z.ZodArray<z.ZodDiscriminatedUnion<"role", [z.ZodObject<{
|
|
344
345
|
id: z.ZodString;
|
|
@@ -538,6 +539,7 @@ declare const RunAgentInputSchema: z.ZodObject<{
|
|
|
538
539
|
value: string;
|
|
539
540
|
description: string;
|
|
540
541
|
}[];
|
|
542
|
+
parentRunId?: string | undefined;
|
|
541
543
|
state?: any;
|
|
542
544
|
forwardedProps?: any;
|
|
543
545
|
}, {
|
|
@@ -587,6 +589,7 @@ declare const RunAgentInputSchema: z.ZodObject<{
|
|
|
587
589
|
value: string;
|
|
588
590
|
description: string;
|
|
589
591
|
}[];
|
|
592
|
+
parentRunId?: string | undefined;
|
|
590
593
|
state?: any;
|
|
591
594
|
forwardedProps?: any;
|
|
592
595
|
}>;
|
|
@@ -1213,18 +1216,380 @@ declare const RunStartedEventSchema: z.ZodObject<{
|
|
|
1213
1216
|
type: z.ZodLiteral<EventType.RUN_STARTED>;
|
|
1214
1217
|
threadId: z.ZodString;
|
|
1215
1218
|
runId: z.ZodString;
|
|
1219
|
+
parentRunId: z.ZodOptional<z.ZodString>;
|
|
1220
|
+
input: z.ZodOptional<z.ZodObject<{
|
|
1221
|
+
threadId: z.ZodString;
|
|
1222
|
+
runId: z.ZodString;
|
|
1223
|
+
parentRunId: z.ZodOptional<z.ZodString>;
|
|
1224
|
+
state: z.ZodAny;
|
|
1225
|
+
messages: z.ZodArray<z.ZodDiscriminatedUnion<"role", [z.ZodObject<{
|
|
1226
|
+
id: z.ZodString;
|
|
1227
|
+
name: z.ZodOptional<z.ZodString>;
|
|
1228
|
+
} & {
|
|
1229
|
+
role: z.ZodLiteral<"developer">;
|
|
1230
|
+
content: z.ZodString;
|
|
1231
|
+
}, "strip", z.ZodTypeAny, {
|
|
1232
|
+
id: string;
|
|
1233
|
+
role: "developer";
|
|
1234
|
+
content: string;
|
|
1235
|
+
name?: string | undefined;
|
|
1236
|
+
}, {
|
|
1237
|
+
id: string;
|
|
1238
|
+
role: "developer";
|
|
1239
|
+
content: string;
|
|
1240
|
+
name?: string | undefined;
|
|
1241
|
+
}>, z.ZodObject<{
|
|
1242
|
+
id: z.ZodString;
|
|
1243
|
+
name: z.ZodOptional<z.ZodString>;
|
|
1244
|
+
} & {
|
|
1245
|
+
role: z.ZodLiteral<"system">;
|
|
1246
|
+
content: z.ZodString;
|
|
1247
|
+
}, "strip", z.ZodTypeAny, {
|
|
1248
|
+
id: string;
|
|
1249
|
+
role: "system";
|
|
1250
|
+
content: string;
|
|
1251
|
+
name?: string | undefined;
|
|
1252
|
+
}, {
|
|
1253
|
+
id: string;
|
|
1254
|
+
role: "system";
|
|
1255
|
+
content: string;
|
|
1256
|
+
name?: string | undefined;
|
|
1257
|
+
}>, z.ZodObject<{
|
|
1258
|
+
id: z.ZodString;
|
|
1259
|
+
name: z.ZodOptional<z.ZodString>;
|
|
1260
|
+
} & {
|
|
1261
|
+
role: z.ZodLiteral<"assistant">;
|
|
1262
|
+
content: z.ZodOptional<z.ZodString>;
|
|
1263
|
+
toolCalls: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1264
|
+
id: z.ZodString;
|
|
1265
|
+
type: z.ZodLiteral<"function">;
|
|
1266
|
+
function: z.ZodObject<{
|
|
1267
|
+
name: z.ZodString;
|
|
1268
|
+
arguments: z.ZodString;
|
|
1269
|
+
}, "strip", z.ZodTypeAny, {
|
|
1270
|
+
name: string;
|
|
1271
|
+
arguments: string;
|
|
1272
|
+
}, {
|
|
1273
|
+
name: string;
|
|
1274
|
+
arguments: string;
|
|
1275
|
+
}>;
|
|
1276
|
+
}, "strip", z.ZodTypeAny, {
|
|
1277
|
+
function: {
|
|
1278
|
+
name: string;
|
|
1279
|
+
arguments: string;
|
|
1280
|
+
};
|
|
1281
|
+
type: "function";
|
|
1282
|
+
id: string;
|
|
1283
|
+
}, {
|
|
1284
|
+
function: {
|
|
1285
|
+
name: string;
|
|
1286
|
+
arguments: string;
|
|
1287
|
+
};
|
|
1288
|
+
type: "function";
|
|
1289
|
+
id: string;
|
|
1290
|
+
}>, "many">>;
|
|
1291
|
+
}, "strip", z.ZodTypeAny, {
|
|
1292
|
+
id: string;
|
|
1293
|
+
role: "assistant";
|
|
1294
|
+
name?: string | undefined;
|
|
1295
|
+
content?: string | undefined;
|
|
1296
|
+
toolCalls?: {
|
|
1297
|
+
function: {
|
|
1298
|
+
name: string;
|
|
1299
|
+
arguments: string;
|
|
1300
|
+
};
|
|
1301
|
+
type: "function";
|
|
1302
|
+
id: string;
|
|
1303
|
+
}[] | undefined;
|
|
1304
|
+
}, {
|
|
1305
|
+
id: string;
|
|
1306
|
+
role: "assistant";
|
|
1307
|
+
name?: string | undefined;
|
|
1308
|
+
content?: string | undefined;
|
|
1309
|
+
toolCalls?: {
|
|
1310
|
+
function: {
|
|
1311
|
+
name: string;
|
|
1312
|
+
arguments: string;
|
|
1313
|
+
};
|
|
1314
|
+
type: "function";
|
|
1315
|
+
id: string;
|
|
1316
|
+
}[] | undefined;
|
|
1317
|
+
}>, z.ZodObject<{
|
|
1318
|
+
id: z.ZodString;
|
|
1319
|
+
name: z.ZodOptional<z.ZodString>;
|
|
1320
|
+
} & {
|
|
1321
|
+
role: z.ZodLiteral<"user">;
|
|
1322
|
+
content: z.ZodString;
|
|
1323
|
+
}, "strip", z.ZodTypeAny, {
|
|
1324
|
+
id: string;
|
|
1325
|
+
role: "user";
|
|
1326
|
+
content: string;
|
|
1327
|
+
name?: string | undefined;
|
|
1328
|
+
}, {
|
|
1329
|
+
id: string;
|
|
1330
|
+
role: "user";
|
|
1331
|
+
content: string;
|
|
1332
|
+
name?: string | undefined;
|
|
1333
|
+
}>, z.ZodObject<{
|
|
1334
|
+
id: z.ZodString;
|
|
1335
|
+
content: z.ZodString;
|
|
1336
|
+
role: z.ZodLiteral<"tool">;
|
|
1337
|
+
toolCallId: z.ZodString;
|
|
1338
|
+
error: z.ZodOptional<z.ZodString>;
|
|
1339
|
+
}, "strip", z.ZodTypeAny, {
|
|
1340
|
+
id: string;
|
|
1341
|
+
role: "tool";
|
|
1342
|
+
content: string;
|
|
1343
|
+
toolCallId: string;
|
|
1344
|
+
error?: string | undefined;
|
|
1345
|
+
}, {
|
|
1346
|
+
id: string;
|
|
1347
|
+
role: "tool";
|
|
1348
|
+
content: string;
|
|
1349
|
+
toolCallId: string;
|
|
1350
|
+
error?: string | undefined;
|
|
1351
|
+
}>]>, "many">;
|
|
1352
|
+
tools: z.ZodArray<z.ZodObject<{
|
|
1353
|
+
name: z.ZodString;
|
|
1354
|
+
description: z.ZodString;
|
|
1355
|
+
parameters: z.ZodAny;
|
|
1356
|
+
}, "strip", z.ZodTypeAny, {
|
|
1357
|
+
name: string;
|
|
1358
|
+
description: string;
|
|
1359
|
+
parameters?: any;
|
|
1360
|
+
}, {
|
|
1361
|
+
name: string;
|
|
1362
|
+
description: string;
|
|
1363
|
+
parameters?: any;
|
|
1364
|
+
}>, "many">;
|
|
1365
|
+
context: z.ZodArray<z.ZodObject<{
|
|
1366
|
+
description: z.ZodString;
|
|
1367
|
+
value: z.ZodString;
|
|
1368
|
+
}, "strip", z.ZodTypeAny, {
|
|
1369
|
+
value: string;
|
|
1370
|
+
description: string;
|
|
1371
|
+
}, {
|
|
1372
|
+
value: string;
|
|
1373
|
+
description: string;
|
|
1374
|
+
}>, "many">;
|
|
1375
|
+
forwardedProps: z.ZodAny;
|
|
1376
|
+
}, "strip", z.ZodTypeAny, {
|
|
1377
|
+
threadId: string;
|
|
1378
|
+
runId: string;
|
|
1379
|
+
messages: ({
|
|
1380
|
+
id: string;
|
|
1381
|
+
role: "developer";
|
|
1382
|
+
content: string;
|
|
1383
|
+
name?: string | undefined;
|
|
1384
|
+
} | {
|
|
1385
|
+
id: string;
|
|
1386
|
+
role: "system";
|
|
1387
|
+
content: string;
|
|
1388
|
+
name?: string | undefined;
|
|
1389
|
+
} | {
|
|
1390
|
+
id: string;
|
|
1391
|
+
role: "assistant";
|
|
1392
|
+
name?: string | undefined;
|
|
1393
|
+
content?: string | undefined;
|
|
1394
|
+
toolCalls?: {
|
|
1395
|
+
function: {
|
|
1396
|
+
name: string;
|
|
1397
|
+
arguments: string;
|
|
1398
|
+
};
|
|
1399
|
+
type: "function";
|
|
1400
|
+
id: string;
|
|
1401
|
+
}[] | undefined;
|
|
1402
|
+
} | {
|
|
1403
|
+
id: string;
|
|
1404
|
+
role: "user";
|
|
1405
|
+
content: string;
|
|
1406
|
+
name?: string | undefined;
|
|
1407
|
+
} | {
|
|
1408
|
+
id: string;
|
|
1409
|
+
role: "tool";
|
|
1410
|
+
content: string;
|
|
1411
|
+
toolCallId: string;
|
|
1412
|
+
error?: string | undefined;
|
|
1413
|
+
})[];
|
|
1414
|
+
tools: {
|
|
1415
|
+
name: string;
|
|
1416
|
+
description: string;
|
|
1417
|
+
parameters?: any;
|
|
1418
|
+
}[];
|
|
1419
|
+
context: {
|
|
1420
|
+
value: string;
|
|
1421
|
+
description: string;
|
|
1422
|
+
}[];
|
|
1423
|
+
parentRunId?: string | undefined;
|
|
1424
|
+
state?: any;
|
|
1425
|
+
forwardedProps?: any;
|
|
1426
|
+
}, {
|
|
1427
|
+
threadId: string;
|
|
1428
|
+
runId: string;
|
|
1429
|
+
messages: ({
|
|
1430
|
+
id: string;
|
|
1431
|
+
role: "developer";
|
|
1432
|
+
content: string;
|
|
1433
|
+
name?: string | undefined;
|
|
1434
|
+
} | {
|
|
1435
|
+
id: string;
|
|
1436
|
+
role: "system";
|
|
1437
|
+
content: string;
|
|
1438
|
+
name?: string | undefined;
|
|
1439
|
+
} | {
|
|
1440
|
+
id: string;
|
|
1441
|
+
role: "assistant";
|
|
1442
|
+
name?: string | undefined;
|
|
1443
|
+
content?: string | undefined;
|
|
1444
|
+
toolCalls?: {
|
|
1445
|
+
function: {
|
|
1446
|
+
name: string;
|
|
1447
|
+
arguments: string;
|
|
1448
|
+
};
|
|
1449
|
+
type: "function";
|
|
1450
|
+
id: string;
|
|
1451
|
+
}[] | undefined;
|
|
1452
|
+
} | {
|
|
1453
|
+
id: string;
|
|
1454
|
+
role: "user";
|
|
1455
|
+
content: string;
|
|
1456
|
+
name?: string | undefined;
|
|
1457
|
+
} | {
|
|
1458
|
+
id: string;
|
|
1459
|
+
role: "tool";
|
|
1460
|
+
content: string;
|
|
1461
|
+
toolCallId: string;
|
|
1462
|
+
error?: string | undefined;
|
|
1463
|
+
})[];
|
|
1464
|
+
tools: {
|
|
1465
|
+
name: string;
|
|
1466
|
+
description: string;
|
|
1467
|
+
parameters?: any;
|
|
1468
|
+
}[];
|
|
1469
|
+
context: {
|
|
1470
|
+
value: string;
|
|
1471
|
+
description: string;
|
|
1472
|
+
}[];
|
|
1473
|
+
parentRunId?: string | undefined;
|
|
1474
|
+
state?: any;
|
|
1475
|
+
forwardedProps?: any;
|
|
1476
|
+
}>>;
|
|
1216
1477
|
}, "strip", z.ZodTypeAny, {
|
|
1217
1478
|
type: EventType.RUN_STARTED;
|
|
1218
1479
|
threadId: string;
|
|
1219
1480
|
runId: string;
|
|
1481
|
+
parentRunId?: string | undefined;
|
|
1220
1482
|
timestamp?: number | undefined;
|
|
1221
1483
|
rawEvent?: any;
|
|
1484
|
+
input?: {
|
|
1485
|
+
threadId: string;
|
|
1486
|
+
runId: string;
|
|
1487
|
+
messages: ({
|
|
1488
|
+
id: string;
|
|
1489
|
+
role: "developer";
|
|
1490
|
+
content: string;
|
|
1491
|
+
name?: string | undefined;
|
|
1492
|
+
} | {
|
|
1493
|
+
id: string;
|
|
1494
|
+
role: "system";
|
|
1495
|
+
content: string;
|
|
1496
|
+
name?: string | undefined;
|
|
1497
|
+
} | {
|
|
1498
|
+
id: string;
|
|
1499
|
+
role: "assistant";
|
|
1500
|
+
name?: string | undefined;
|
|
1501
|
+
content?: string | undefined;
|
|
1502
|
+
toolCalls?: {
|
|
1503
|
+
function: {
|
|
1504
|
+
name: string;
|
|
1505
|
+
arguments: string;
|
|
1506
|
+
};
|
|
1507
|
+
type: "function";
|
|
1508
|
+
id: string;
|
|
1509
|
+
}[] | undefined;
|
|
1510
|
+
} | {
|
|
1511
|
+
id: string;
|
|
1512
|
+
role: "user";
|
|
1513
|
+
content: string;
|
|
1514
|
+
name?: string | undefined;
|
|
1515
|
+
} | {
|
|
1516
|
+
id: string;
|
|
1517
|
+
role: "tool";
|
|
1518
|
+
content: string;
|
|
1519
|
+
toolCallId: string;
|
|
1520
|
+
error?: string | undefined;
|
|
1521
|
+
})[];
|
|
1522
|
+
tools: {
|
|
1523
|
+
name: string;
|
|
1524
|
+
description: string;
|
|
1525
|
+
parameters?: any;
|
|
1526
|
+
}[];
|
|
1527
|
+
context: {
|
|
1528
|
+
value: string;
|
|
1529
|
+
description: string;
|
|
1530
|
+
}[];
|
|
1531
|
+
parentRunId?: string | undefined;
|
|
1532
|
+
state?: any;
|
|
1533
|
+
forwardedProps?: any;
|
|
1534
|
+
} | undefined;
|
|
1222
1535
|
}, {
|
|
1223
1536
|
type: EventType.RUN_STARTED;
|
|
1224
1537
|
threadId: string;
|
|
1225
1538
|
runId: string;
|
|
1539
|
+
parentRunId?: string | undefined;
|
|
1226
1540
|
timestamp?: number | undefined;
|
|
1227
1541
|
rawEvent?: any;
|
|
1542
|
+
input?: {
|
|
1543
|
+
threadId: string;
|
|
1544
|
+
runId: string;
|
|
1545
|
+
messages: ({
|
|
1546
|
+
id: string;
|
|
1547
|
+
role: "developer";
|
|
1548
|
+
content: string;
|
|
1549
|
+
name?: string | undefined;
|
|
1550
|
+
} | {
|
|
1551
|
+
id: string;
|
|
1552
|
+
role: "system";
|
|
1553
|
+
content: string;
|
|
1554
|
+
name?: string | undefined;
|
|
1555
|
+
} | {
|
|
1556
|
+
id: string;
|
|
1557
|
+
role: "assistant";
|
|
1558
|
+
name?: string | undefined;
|
|
1559
|
+
content?: string | undefined;
|
|
1560
|
+
toolCalls?: {
|
|
1561
|
+
function: {
|
|
1562
|
+
name: string;
|
|
1563
|
+
arguments: string;
|
|
1564
|
+
};
|
|
1565
|
+
type: "function";
|
|
1566
|
+
id: string;
|
|
1567
|
+
}[] | undefined;
|
|
1568
|
+
} | {
|
|
1569
|
+
id: string;
|
|
1570
|
+
role: "user";
|
|
1571
|
+
content: string;
|
|
1572
|
+
name?: string | undefined;
|
|
1573
|
+
} | {
|
|
1574
|
+
id: string;
|
|
1575
|
+
role: "tool";
|
|
1576
|
+
content: string;
|
|
1577
|
+
toolCallId: string;
|
|
1578
|
+
error?: string | undefined;
|
|
1579
|
+
})[];
|
|
1580
|
+
tools: {
|
|
1581
|
+
name: string;
|
|
1582
|
+
description: string;
|
|
1583
|
+
parameters?: any;
|
|
1584
|
+
}[];
|
|
1585
|
+
context: {
|
|
1586
|
+
value: string;
|
|
1587
|
+
description: string;
|
|
1588
|
+
}[];
|
|
1589
|
+
parentRunId?: string | undefined;
|
|
1590
|
+
state?: any;
|
|
1591
|
+
forwardedProps?: any;
|
|
1592
|
+
} | undefined;
|
|
1228
1593
|
}>;
|
|
1229
1594
|
declare const RunFinishedEventSchema: z.ZodObject<{
|
|
1230
1595
|
timestamp: z.ZodOptional<z.ZodNumber>;
|
|
@@ -1847,18 +2212,380 @@ declare const EventSchemas: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
|
1847
2212
|
type: z.ZodLiteral<EventType.RUN_STARTED>;
|
|
1848
2213
|
threadId: z.ZodString;
|
|
1849
2214
|
runId: z.ZodString;
|
|
2215
|
+
parentRunId: z.ZodOptional<z.ZodString>;
|
|
2216
|
+
input: z.ZodOptional<z.ZodObject<{
|
|
2217
|
+
threadId: z.ZodString;
|
|
2218
|
+
runId: z.ZodString;
|
|
2219
|
+
parentRunId: z.ZodOptional<z.ZodString>;
|
|
2220
|
+
state: z.ZodAny;
|
|
2221
|
+
messages: z.ZodArray<z.ZodDiscriminatedUnion<"role", [z.ZodObject<{
|
|
2222
|
+
id: z.ZodString;
|
|
2223
|
+
name: z.ZodOptional<z.ZodString>;
|
|
2224
|
+
} & {
|
|
2225
|
+
role: z.ZodLiteral<"developer">;
|
|
2226
|
+
content: z.ZodString;
|
|
2227
|
+
}, "strip", z.ZodTypeAny, {
|
|
2228
|
+
id: string;
|
|
2229
|
+
role: "developer";
|
|
2230
|
+
content: string;
|
|
2231
|
+
name?: string | undefined;
|
|
2232
|
+
}, {
|
|
2233
|
+
id: string;
|
|
2234
|
+
role: "developer";
|
|
2235
|
+
content: string;
|
|
2236
|
+
name?: string | undefined;
|
|
2237
|
+
}>, z.ZodObject<{
|
|
2238
|
+
id: z.ZodString;
|
|
2239
|
+
name: z.ZodOptional<z.ZodString>;
|
|
2240
|
+
} & {
|
|
2241
|
+
role: z.ZodLiteral<"system">;
|
|
2242
|
+
content: z.ZodString;
|
|
2243
|
+
}, "strip", z.ZodTypeAny, {
|
|
2244
|
+
id: string;
|
|
2245
|
+
role: "system";
|
|
2246
|
+
content: string;
|
|
2247
|
+
name?: string | undefined;
|
|
2248
|
+
}, {
|
|
2249
|
+
id: string;
|
|
2250
|
+
role: "system";
|
|
2251
|
+
content: string;
|
|
2252
|
+
name?: string | undefined;
|
|
2253
|
+
}>, z.ZodObject<{
|
|
2254
|
+
id: z.ZodString;
|
|
2255
|
+
name: z.ZodOptional<z.ZodString>;
|
|
2256
|
+
} & {
|
|
2257
|
+
role: z.ZodLiteral<"assistant">;
|
|
2258
|
+
content: z.ZodOptional<z.ZodString>;
|
|
2259
|
+
toolCalls: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
2260
|
+
id: z.ZodString;
|
|
2261
|
+
type: z.ZodLiteral<"function">;
|
|
2262
|
+
function: z.ZodObject<{
|
|
2263
|
+
name: z.ZodString;
|
|
2264
|
+
arguments: z.ZodString;
|
|
2265
|
+
}, "strip", z.ZodTypeAny, {
|
|
2266
|
+
name: string;
|
|
2267
|
+
arguments: string;
|
|
2268
|
+
}, {
|
|
2269
|
+
name: string;
|
|
2270
|
+
arguments: string;
|
|
2271
|
+
}>;
|
|
2272
|
+
}, "strip", z.ZodTypeAny, {
|
|
2273
|
+
function: {
|
|
2274
|
+
name: string;
|
|
2275
|
+
arguments: string;
|
|
2276
|
+
};
|
|
2277
|
+
type: "function";
|
|
2278
|
+
id: string;
|
|
2279
|
+
}, {
|
|
2280
|
+
function: {
|
|
2281
|
+
name: string;
|
|
2282
|
+
arguments: string;
|
|
2283
|
+
};
|
|
2284
|
+
type: "function";
|
|
2285
|
+
id: string;
|
|
2286
|
+
}>, "many">>;
|
|
2287
|
+
}, "strip", z.ZodTypeAny, {
|
|
2288
|
+
id: string;
|
|
2289
|
+
role: "assistant";
|
|
2290
|
+
name?: string | undefined;
|
|
2291
|
+
content?: string | undefined;
|
|
2292
|
+
toolCalls?: {
|
|
2293
|
+
function: {
|
|
2294
|
+
name: string;
|
|
2295
|
+
arguments: string;
|
|
2296
|
+
};
|
|
2297
|
+
type: "function";
|
|
2298
|
+
id: string;
|
|
2299
|
+
}[] | undefined;
|
|
2300
|
+
}, {
|
|
2301
|
+
id: string;
|
|
2302
|
+
role: "assistant";
|
|
2303
|
+
name?: string | undefined;
|
|
2304
|
+
content?: string | undefined;
|
|
2305
|
+
toolCalls?: {
|
|
2306
|
+
function: {
|
|
2307
|
+
name: string;
|
|
2308
|
+
arguments: string;
|
|
2309
|
+
};
|
|
2310
|
+
type: "function";
|
|
2311
|
+
id: string;
|
|
2312
|
+
}[] | undefined;
|
|
2313
|
+
}>, z.ZodObject<{
|
|
2314
|
+
id: z.ZodString;
|
|
2315
|
+
name: z.ZodOptional<z.ZodString>;
|
|
2316
|
+
} & {
|
|
2317
|
+
role: z.ZodLiteral<"user">;
|
|
2318
|
+
content: z.ZodString;
|
|
2319
|
+
}, "strip", z.ZodTypeAny, {
|
|
2320
|
+
id: string;
|
|
2321
|
+
role: "user";
|
|
2322
|
+
content: string;
|
|
2323
|
+
name?: string | undefined;
|
|
2324
|
+
}, {
|
|
2325
|
+
id: string;
|
|
2326
|
+
role: "user";
|
|
2327
|
+
content: string;
|
|
2328
|
+
name?: string | undefined;
|
|
2329
|
+
}>, z.ZodObject<{
|
|
2330
|
+
id: z.ZodString;
|
|
2331
|
+
content: z.ZodString;
|
|
2332
|
+
role: z.ZodLiteral<"tool">;
|
|
2333
|
+
toolCallId: z.ZodString;
|
|
2334
|
+
error: z.ZodOptional<z.ZodString>;
|
|
2335
|
+
}, "strip", z.ZodTypeAny, {
|
|
2336
|
+
id: string;
|
|
2337
|
+
role: "tool";
|
|
2338
|
+
content: string;
|
|
2339
|
+
toolCallId: string;
|
|
2340
|
+
error?: string | undefined;
|
|
2341
|
+
}, {
|
|
2342
|
+
id: string;
|
|
2343
|
+
role: "tool";
|
|
2344
|
+
content: string;
|
|
2345
|
+
toolCallId: string;
|
|
2346
|
+
error?: string | undefined;
|
|
2347
|
+
}>]>, "many">;
|
|
2348
|
+
tools: z.ZodArray<z.ZodObject<{
|
|
2349
|
+
name: z.ZodString;
|
|
2350
|
+
description: z.ZodString;
|
|
2351
|
+
parameters: z.ZodAny;
|
|
2352
|
+
}, "strip", z.ZodTypeAny, {
|
|
2353
|
+
name: string;
|
|
2354
|
+
description: string;
|
|
2355
|
+
parameters?: any;
|
|
2356
|
+
}, {
|
|
2357
|
+
name: string;
|
|
2358
|
+
description: string;
|
|
2359
|
+
parameters?: any;
|
|
2360
|
+
}>, "many">;
|
|
2361
|
+
context: z.ZodArray<z.ZodObject<{
|
|
2362
|
+
description: z.ZodString;
|
|
2363
|
+
value: z.ZodString;
|
|
2364
|
+
}, "strip", z.ZodTypeAny, {
|
|
2365
|
+
value: string;
|
|
2366
|
+
description: string;
|
|
2367
|
+
}, {
|
|
2368
|
+
value: string;
|
|
2369
|
+
description: string;
|
|
2370
|
+
}>, "many">;
|
|
2371
|
+
forwardedProps: z.ZodAny;
|
|
2372
|
+
}, "strip", z.ZodTypeAny, {
|
|
2373
|
+
threadId: string;
|
|
2374
|
+
runId: string;
|
|
2375
|
+
messages: ({
|
|
2376
|
+
id: string;
|
|
2377
|
+
role: "developer";
|
|
2378
|
+
content: string;
|
|
2379
|
+
name?: string | undefined;
|
|
2380
|
+
} | {
|
|
2381
|
+
id: string;
|
|
2382
|
+
role: "system";
|
|
2383
|
+
content: string;
|
|
2384
|
+
name?: string | undefined;
|
|
2385
|
+
} | {
|
|
2386
|
+
id: string;
|
|
2387
|
+
role: "assistant";
|
|
2388
|
+
name?: string | undefined;
|
|
2389
|
+
content?: string | undefined;
|
|
2390
|
+
toolCalls?: {
|
|
2391
|
+
function: {
|
|
2392
|
+
name: string;
|
|
2393
|
+
arguments: string;
|
|
2394
|
+
};
|
|
2395
|
+
type: "function";
|
|
2396
|
+
id: string;
|
|
2397
|
+
}[] | undefined;
|
|
2398
|
+
} | {
|
|
2399
|
+
id: string;
|
|
2400
|
+
role: "user";
|
|
2401
|
+
content: string;
|
|
2402
|
+
name?: string | undefined;
|
|
2403
|
+
} | {
|
|
2404
|
+
id: string;
|
|
2405
|
+
role: "tool";
|
|
2406
|
+
content: string;
|
|
2407
|
+
toolCallId: string;
|
|
2408
|
+
error?: string | undefined;
|
|
2409
|
+
})[];
|
|
2410
|
+
tools: {
|
|
2411
|
+
name: string;
|
|
2412
|
+
description: string;
|
|
2413
|
+
parameters?: any;
|
|
2414
|
+
}[];
|
|
2415
|
+
context: {
|
|
2416
|
+
value: string;
|
|
2417
|
+
description: string;
|
|
2418
|
+
}[];
|
|
2419
|
+
parentRunId?: string | undefined;
|
|
2420
|
+
state?: any;
|
|
2421
|
+
forwardedProps?: any;
|
|
2422
|
+
}, {
|
|
2423
|
+
threadId: string;
|
|
2424
|
+
runId: string;
|
|
2425
|
+
messages: ({
|
|
2426
|
+
id: string;
|
|
2427
|
+
role: "developer";
|
|
2428
|
+
content: string;
|
|
2429
|
+
name?: string | undefined;
|
|
2430
|
+
} | {
|
|
2431
|
+
id: string;
|
|
2432
|
+
role: "system";
|
|
2433
|
+
content: string;
|
|
2434
|
+
name?: string | undefined;
|
|
2435
|
+
} | {
|
|
2436
|
+
id: string;
|
|
2437
|
+
role: "assistant";
|
|
2438
|
+
name?: string | undefined;
|
|
2439
|
+
content?: string | undefined;
|
|
2440
|
+
toolCalls?: {
|
|
2441
|
+
function: {
|
|
2442
|
+
name: string;
|
|
2443
|
+
arguments: string;
|
|
2444
|
+
};
|
|
2445
|
+
type: "function";
|
|
2446
|
+
id: string;
|
|
2447
|
+
}[] | undefined;
|
|
2448
|
+
} | {
|
|
2449
|
+
id: string;
|
|
2450
|
+
role: "user";
|
|
2451
|
+
content: string;
|
|
2452
|
+
name?: string | undefined;
|
|
2453
|
+
} | {
|
|
2454
|
+
id: string;
|
|
2455
|
+
role: "tool";
|
|
2456
|
+
content: string;
|
|
2457
|
+
toolCallId: string;
|
|
2458
|
+
error?: string | undefined;
|
|
2459
|
+
})[];
|
|
2460
|
+
tools: {
|
|
2461
|
+
name: string;
|
|
2462
|
+
description: string;
|
|
2463
|
+
parameters?: any;
|
|
2464
|
+
}[];
|
|
2465
|
+
context: {
|
|
2466
|
+
value: string;
|
|
2467
|
+
description: string;
|
|
2468
|
+
}[];
|
|
2469
|
+
parentRunId?: string | undefined;
|
|
2470
|
+
state?: any;
|
|
2471
|
+
forwardedProps?: any;
|
|
2472
|
+
}>>;
|
|
1850
2473
|
}, "strip", z.ZodTypeAny, {
|
|
1851
2474
|
type: EventType.RUN_STARTED;
|
|
1852
2475
|
threadId: string;
|
|
1853
2476
|
runId: string;
|
|
2477
|
+
parentRunId?: string | undefined;
|
|
1854
2478
|
timestamp?: number | undefined;
|
|
1855
2479
|
rawEvent?: any;
|
|
2480
|
+
input?: {
|
|
2481
|
+
threadId: string;
|
|
2482
|
+
runId: string;
|
|
2483
|
+
messages: ({
|
|
2484
|
+
id: string;
|
|
2485
|
+
role: "developer";
|
|
2486
|
+
content: string;
|
|
2487
|
+
name?: string | undefined;
|
|
2488
|
+
} | {
|
|
2489
|
+
id: string;
|
|
2490
|
+
role: "system";
|
|
2491
|
+
content: string;
|
|
2492
|
+
name?: string | undefined;
|
|
2493
|
+
} | {
|
|
2494
|
+
id: string;
|
|
2495
|
+
role: "assistant";
|
|
2496
|
+
name?: string | undefined;
|
|
2497
|
+
content?: string | undefined;
|
|
2498
|
+
toolCalls?: {
|
|
2499
|
+
function: {
|
|
2500
|
+
name: string;
|
|
2501
|
+
arguments: string;
|
|
2502
|
+
};
|
|
2503
|
+
type: "function";
|
|
2504
|
+
id: string;
|
|
2505
|
+
}[] | undefined;
|
|
2506
|
+
} | {
|
|
2507
|
+
id: string;
|
|
2508
|
+
role: "user";
|
|
2509
|
+
content: string;
|
|
2510
|
+
name?: string | undefined;
|
|
2511
|
+
} | {
|
|
2512
|
+
id: string;
|
|
2513
|
+
role: "tool";
|
|
2514
|
+
content: string;
|
|
2515
|
+
toolCallId: string;
|
|
2516
|
+
error?: string | undefined;
|
|
2517
|
+
})[];
|
|
2518
|
+
tools: {
|
|
2519
|
+
name: string;
|
|
2520
|
+
description: string;
|
|
2521
|
+
parameters?: any;
|
|
2522
|
+
}[];
|
|
2523
|
+
context: {
|
|
2524
|
+
value: string;
|
|
2525
|
+
description: string;
|
|
2526
|
+
}[];
|
|
2527
|
+
parentRunId?: string | undefined;
|
|
2528
|
+
state?: any;
|
|
2529
|
+
forwardedProps?: any;
|
|
2530
|
+
} | undefined;
|
|
1856
2531
|
}, {
|
|
1857
2532
|
type: EventType.RUN_STARTED;
|
|
1858
2533
|
threadId: string;
|
|
1859
2534
|
runId: string;
|
|
2535
|
+
parentRunId?: string | undefined;
|
|
1860
2536
|
timestamp?: number | undefined;
|
|
1861
2537
|
rawEvent?: any;
|
|
2538
|
+
input?: {
|
|
2539
|
+
threadId: string;
|
|
2540
|
+
runId: string;
|
|
2541
|
+
messages: ({
|
|
2542
|
+
id: string;
|
|
2543
|
+
role: "developer";
|
|
2544
|
+
content: string;
|
|
2545
|
+
name?: string | undefined;
|
|
2546
|
+
} | {
|
|
2547
|
+
id: string;
|
|
2548
|
+
role: "system";
|
|
2549
|
+
content: string;
|
|
2550
|
+
name?: string | undefined;
|
|
2551
|
+
} | {
|
|
2552
|
+
id: string;
|
|
2553
|
+
role: "assistant";
|
|
2554
|
+
name?: string | undefined;
|
|
2555
|
+
content?: string | undefined;
|
|
2556
|
+
toolCalls?: {
|
|
2557
|
+
function: {
|
|
2558
|
+
name: string;
|
|
2559
|
+
arguments: string;
|
|
2560
|
+
};
|
|
2561
|
+
type: "function";
|
|
2562
|
+
id: string;
|
|
2563
|
+
}[] | undefined;
|
|
2564
|
+
} | {
|
|
2565
|
+
id: string;
|
|
2566
|
+
role: "user";
|
|
2567
|
+
content: string;
|
|
2568
|
+
name?: string | undefined;
|
|
2569
|
+
} | {
|
|
2570
|
+
id: string;
|
|
2571
|
+
role: "tool";
|
|
2572
|
+
content: string;
|
|
2573
|
+
toolCallId: string;
|
|
2574
|
+
error?: string | undefined;
|
|
2575
|
+
})[];
|
|
2576
|
+
tools: {
|
|
2577
|
+
name: string;
|
|
2578
|
+
description: string;
|
|
2579
|
+
parameters?: any;
|
|
2580
|
+
}[];
|
|
2581
|
+
context: {
|
|
2582
|
+
value: string;
|
|
2583
|
+
description: string;
|
|
2584
|
+
}[];
|
|
2585
|
+
parentRunId?: string | undefined;
|
|
2586
|
+
state?: any;
|
|
2587
|
+
forwardedProps?: any;
|
|
2588
|
+
} | undefined;
|
|
1862
2589
|
}>, z.ZodObject<{
|
|
1863
2590
|
timestamp: z.ZodOptional<z.ZodNumber>;
|
|
1864
2591
|
rawEvent: z.ZodOptional<z.ZodAny>;
|