art-framework 0.3.9 → 0.4.1
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/LICENSE +21 -0
- package/README.md +3 -4
- package/dist/index.cjs +76 -126
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +407 -108
- package/dist/index.d.ts +407 -108
- package/dist/index.js +76 -126
- package/dist/index.js.map +1 -1
- package/package.json +21 -5
package/dist/index.d.ts
CHANGED
|
@@ -437,6 +437,47 @@ declare class LLMStreamSocket extends TypedSocket<StreamEvent, StreamEventTypeFi
|
|
|
437
437
|
notifyStreamEvent(event: StreamEvent): void;
|
|
438
438
|
}
|
|
439
439
|
|
|
440
|
+
declare enum TodoItemStatus {
|
|
441
|
+
PENDING = "pending",
|
|
442
|
+
IN_PROGRESS = "in_progress",
|
|
443
|
+
COMPLETED = "completed",
|
|
444
|
+
FAILED = "failed",
|
|
445
|
+
CANCELLED = "cancelled",
|
|
446
|
+
WAITING = "waiting"
|
|
447
|
+
}
|
|
448
|
+
interface TodoItem {
|
|
449
|
+
id: string;
|
|
450
|
+
description: string;
|
|
451
|
+
status: TodoItemStatus;
|
|
452
|
+
dependencies?: string[];
|
|
453
|
+
result?: any;
|
|
454
|
+
thoughts?: string[];
|
|
455
|
+
toolCalls?: ParsedToolCall[];
|
|
456
|
+
toolResults?: ToolResult[];
|
|
457
|
+
createdTimestamp: number;
|
|
458
|
+
updatedTimestamp: number;
|
|
459
|
+
}
|
|
460
|
+
interface PESAgentStateData {
|
|
461
|
+
threadId: string;
|
|
462
|
+
intent: string;
|
|
463
|
+
title: string;
|
|
464
|
+
plan: string;
|
|
465
|
+
todoList: TodoItem[];
|
|
466
|
+
currentStepId: string | null;
|
|
467
|
+
isPaused: boolean;
|
|
468
|
+
}
|
|
469
|
+
interface ExecutionOutput {
|
|
470
|
+
thoughts?: string;
|
|
471
|
+
content?: string;
|
|
472
|
+
toolCalls?: ParsedToolCall[];
|
|
473
|
+
nextStepDecision?: 'continue' | 'wait' | 'complete_item' | 'update_plan';
|
|
474
|
+
updatedPlan?: {
|
|
475
|
+
intent?: string;
|
|
476
|
+
plan?: string;
|
|
477
|
+
todoList?: TodoItem[];
|
|
478
|
+
};
|
|
479
|
+
}
|
|
480
|
+
|
|
440
481
|
/**
|
|
441
482
|
* @module types/schemas
|
|
442
483
|
* This module defines Zod schemas for validating the core data structures of the ART framework,
|
|
@@ -972,37 +1013,88 @@ interface ConversationMessage {
|
|
|
972
1013
|
}
|
|
973
1014
|
/**
|
|
974
1015
|
* Represents the type of an observation record, capturing significant events during agent execution.
|
|
1016
|
+
* Observations are the primary mechanism for the agent to report its internal state and actions to the outside world (UI, logs, etc.).
|
|
975
1017
|
*
|
|
976
1018
|
* @enum {string}
|
|
977
1019
|
*/
|
|
978
1020
|
declare enum ObservationType {
|
|
979
|
-
/**
|
|
1021
|
+
/**
|
|
1022
|
+
* The user's inferred intent.
|
|
1023
|
+
* Generated during the planning phase to signal understanding of the user's goal.
|
|
1024
|
+
*/
|
|
980
1025
|
INTENT = "INTENT",
|
|
981
|
-
/**
|
|
1026
|
+
/**
|
|
1027
|
+
* The generated concise thread title.
|
|
1028
|
+
* Usually generated once at the start of a new conversation.
|
|
1029
|
+
*/
|
|
982
1030
|
TITLE = "TITLE",
|
|
983
|
-
/**
|
|
1031
|
+
/**
|
|
1032
|
+
* The agent's step-by-step plan to address the intent.
|
|
1033
|
+
* Contains the initial or updated TodoList.
|
|
1034
|
+
*/
|
|
984
1035
|
PLAN = "PLAN",
|
|
985
|
-
/**
|
|
1036
|
+
/**
|
|
1037
|
+
* The agent's internal monologue or reasoning process.
|
|
1038
|
+
* Often captures the 'thinking' blocks from reasoning models.
|
|
1039
|
+
*/
|
|
986
1040
|
THOUGHTS = "THOUGHTS",
|
|
987
|
-
/**
|
|
1041
|
+
/**
|
|
1042
|
+
* Records the LLM's decision to call one or more tools (part of the plan).
|
|
1043
|
+
* Contains the tool name and arguments.
|
|
1044
|
+
*/
|
|
988
1045
|
TOOL_CALL = "TOOL_CALL",
|
|
989
|
-
/**
|
|
1046
|
+
/**
|
|
1047
|
+
* Records the actual execution attempt and result of a specific tool call.
|
|
1048
|
+
* Contains the result payload or error message.
|
|
1049
|
+
*/
|
|
990
1050
|
TOOL_EXECUTION = "TOOL_EXECUTION",
|
|
991
|
-
/**
|
|
1051
|
+
/**
|
|
1052
|
+
* Records events specifically related to the synthesis phase (e.g., the LLM call).
|
|
1053
|
+
*/
|
|
992
1054
|
SYNTHESIS = "SYNTHESIS",
|
|
993
|
-
/**
|
|
1055
|
+
/**
|
|
1056
|
+
* Records an error encountered during any phase of execution.
|
|
1057
|
+
* Contains error details and stack traces.
|
|
1058
|
+
*/
|
|
994
1059
|
ERROR = "ERROR",
|
|
995
|
-
/**
|
|
1060
|
+
/**
|
|
1061
|
+
* Records the final AI response message generated by the agent.
|
|
1062
|
+
* This signals the completion of a turn.
|
|
1063
|
+
*/
|
|
996
1064
|
FINAL_RESPONSE = "FINAL_RESPONSE",
|
|
997
|
-
/**
|
|
1065
|
+
/**
|
|
1066
|
+
* Records changes made to the agent's persistent state.
|
|
1067
|
+
* Useful for debugging state transitions.
|
|
1068
|
+
*/
|
|
998
1069
|
STATE_UPDATE = "STATE_UPDATE",
|
|
999
|
-
/**
|
|
1070
|
+
/**
|
|
1071
|
+
* Records updates to the plan structure (intent, title, or list changes).
|
|
1072
|
+
* Triggered when the agent refines its plan during execution.
|
|
1073
|
+
*/
|
|
1074
|
+
PLAN_UPDATE = "PLAN_UPDATE",
|
|
1075
|
+
/**
|
|
1076
|
+
* Records status changes of a specific todo item (e.g., PENDING -> IN_PROGRESS -> COMPLETED).
|
|
1077
|
+
*/
|
|
1078
|
+
ITEM_STATUS_CHANGE = "ITEM_STATUS_CHANGE",
|
|
1079
|
+
/**
|
|
1080
|
+
* Logged by Agent Core when LLM stream consumption begins.
|
|
1081
|
+
* Signals the UI to prepare for incoming tokens.
|
|
1082
|
+
*/
|
|
1000
1083
|
LLM_STREAM_START = "LLM_STREAM_START",
|
|
1001
|
-
/**
|
|
1084
|
+
/**
|
|
1085
|
+
* Logged by Agent Core upon receiving a METADATA stream event.
|
|
1086
|
+
* Content contains LLMMetadata (token counts, latency).
|
|
1087
|
+
*/
|
|
1002
1088
|
LLM_STREAM_METADATA = "LLM_STREAM_METADATA",
|
|
1003
|
-
/**
|
|
1089
|
+
/**
|
|
1090
|
+
* Logged by Agent Core upon receiving an END stream event.
|
|
1091
|
+
* Signals the end of a streaming response.
|
|
1092
|
+
*/
|
|
1004
1093
|
LLM_STREAM_END = "LLM_STREAM_END",
|
|
1005
|
-
/**
|
|
1094
|
+
/**
|
|
1095
|
+
* Logged by Agent Core upon receiving an ERROR stream event.
|
|
1096
|
+
* Content contains the Error object or message.
|
|
1097
|
+
*/
|
|
1006
1098
|
LLM_STREAM_ERROR = "LLM_STREAM_ERROR"
|
|
1007
1099
|
}
|
|
1008
1100
|
/**
|
|
@@ -1029,6 +1121,7 @@ declare enum ModelCapability {
|
|
|
1029
1121
|
}
|
|
1030
1122
|
/**
|
|
1031
1123
|
* Represents a recorded event during the agent's execution.
|
|
1124
|
+
* Observations provide a granular log of the agent's internal state, decisions, and interactions.
|
|
1032
1125
|
*
|
|
1033
1126
|
* @interface Observation
|
|
1034
1127
|
*/
|
|
@@ -1043,6 +1136,12 @@ interface Observation {
|
|
|
1043
1136
|
* @property {string} threadId
|
|
1044
1137
|
*/
|
|
1045
1138
|
threadId: string;
|
|
1139
|
+
/**
|
|
1140
|
+
* An optional identifier for the parent object (e.g., a TodoItem ID) to which this observation belongs.
|
|
1141
|
+
* This allows differentiation between primary (user query) and secondary (sub-task) observations.
|
|
1142
|
+
* @property {string} [parentId]
|
|
1143
|
+
*/
|
|
1144
|
+
parentId?: string;
|
|
1046
1145
|
/**
|
|
1047
1146
|
* An optional identifier for tracing a request across multiple systems or components.
|
|
1048
1147
|
* @property {string} [traceId]
|
|
@@ -1142,7 +1241,7 @@ interface StreamEvent {
|
|
|
1142
1241
|
*/
|
|
1143
1242
|
traceId: string;
|
|
1144
1243
|
/**
|
|
1145
|
-
* Optional identifier linking the event to a specific UI
|
|
1244
|
+
* Optional identifier linking the event to a specific UI session/window.
|
|
1146
1245
|
* @property {string} [sessionId]
|
|
1147
1246
|
*/
|
|
1148
1247
|
sessionId?: string;
|
|
@@ -1415,27 +1514,32 @@ interface ParsedToolCall {
|
|
|
1415
1514
|
}
|
|
1416
1515
|
/**
|
|
1417
1516
|
* Configuration specific to a conversation thread.
|
|
1517
|
+
* Controls behavior, tools, and provider settings for a particular interaction context.
|
|
1418
1518
|
*
|
|
1419
1519
|
* @interface ThreadConfig
|
|
1420
1520
|
*/
|
|
1421
1521
|
interface ThreadConfig {
|
|
1422
1522
|
/**
|
|
1423
1523
|
* Default provider configuration for this thread.
|
|
1524
|
+
* Determines which LLM and model will be used for reasoning.
|
|
1424
1525
|
* @property {RuntimeProviderConfig} providerConfig
|
|
1425
1526
|
*/
|
|
1426
1527
|
providerConfig: RuntimeProviderConfig;
|
|
1427
1528
|
/**
|
|
1428
1529
|
* An array of tool names (matching `ToolSchema.name`) that are permitted for use within this thread.
|
|
1530
|
+
* Allows for scoping capabilities per conversation.
|
|
1429
1531
|
* @property {string[]} enabledTools
|
|
1430
1532
|
*/
|
|
1431
1533
|
enabledTools: string[];
|
|
1432
1534
|
/**
|
|
1433
1535
|
* The maximum number of past messages (`ConversationMessage` objects) to retrieve for context.
|
|
1536
|
+
* Helps manage context window limits.
|
|
1434
1537
|
* @property {number} historyLimit
|
|
1435
1538
|
*/
|
|
1436
1539
|
historyLimit: number;
|
|
1437
1540
|
/**
|
|
1438
1541
|
* Optional system prompt override to be used for this thread, overriding instance or agent defaults.
|
|
1542
|
+
* Allows for thread-specific role instructions.
|
|
1439
1543
|
* @property {string | SystemPromptOverride} [systemPrompt]
|
|
1440
1544
|
*/
|
|
1441
1545
|
systemPrompt?: string | SystemPromptOverride;
|
|
@@ -1448,13 +1552,15 @@ interface ThreadConfig {
|
|
|
1448
1552
|
}
|
|
1449
1553
|
/**
|
|
1450
1554
|
* Represents non-configuration state associated with an agent or thread.
|
|
1451
|
-
*
|
|
1555
|
+
* This is the persistent memory of the agent, used to store planning progress,
|
|
1556
|
+
* variables, and other dynamic data across execution cycles.
|
|
1452
1557
|
*
|
|
1453
1558
|
* @interface AgentState
|
|
1454
1559
|
*/
|
|
1455
1560
|
interface AgentState {
|
|
1456
1561
|
/**
|
|
1457
|
-
* The primary data payload of the agent's state.
|
|
1562
|
+
* The primary data payload of the agent's state.
|
|
1563
|
+
* Structure is application-defined but typically includes the current plan, todo list, etc.
|
|
1458
1564
|
* @property {any} data
|
|
1459
1565
|
*/
|
|
1460
1566
|
data: any;
|
|
@@ -1470,7 +1576,8 @@ interface AgentState {
|
|
|
1470
1576
|
[key: string]: any;
|
|
1471
1577
|
}
|
|
1472
1578
|
/**
|
|
1473
|
-
* Encapsulates the
|
|
1579
|
+
* Encapsulates the complete context for a specific thread, combining configuration and state.
|
|
1580
|
+
* This object represents the full snapshot of a thread's environment.
|
|
1474
1581
|
*
|
|
1475
1582
|
* @interface ThreadContext
|
|
1476
1583
|
*/
|
|
@@ -1487,7 +1594,7 @@ interface ThreadContext {
|
|
|
1487
1594
|
state: AgentState | null;
|
|
1488
1595
|
}
|
|
1489
1596
|
/**
|
|
1490
|
-
* Properties required to initiate an agent processing cycle.
|
|
1597
|
+
* Properties required to initiate an agent processing cycle via `agent.process()`.
|
|
1491
1598
|
*
|
|
1492
1599
|
* @interface AgentProps
|
|
1493
1600
|
*/
|
|
@@ -1503,7 +1610,7 @@ interface AgentProps {
|
|
|
1503
1610
|
*/
|
|
1504
1611
|
threadId: string;
|
|
1505
1612
|
/**
|
|
1506
|
-
* An optional identifier for the specific UI session, useful for targeting UI updates.
|
|
1613
|
+
* An optional identifier for the specific UI session, useful for targeting UI updates via sockets.
|
|
1507
1614
|
* @property {string} [sessionId]
|
|
1508
1615
|
*/
|
|
1509
1616
|
sessionId?: string;
|
|
@@ -1524,7 +1631,7 @@ interface AgentProps {
|
|
|
1524
1631
|
options?: AgentOptions;
|
|
1525
1632
|
}
|
|
1526
1633
|
/**
|
|
1527
|
-
* Options to override agent behavior at runtime.
|
|
1634
|
+
* Options to override agent behavior at runtime during a `process` call.
|
|
1528
1635
|
*
|
|
1529
1636
|
* @interface AgentOptions
|
|
1530
1637
|
*/
|
|
@@ -2632,24 +2739,46 @@ declare class A2ATaskSocket extends TypedSocket<A2ATaskEvent, A2ATaskFilter> {
|
|
|
2632
2739
|
}
|
|
2633
2740
|
|
|
2634
2741
|
/**
|
|
2635
|
-
* A specialized TypedSocket for handling Observation data.
|
|
2636
|
-
*
|
|
2637
|
-
*
|
|
2742
|
+
* A specialized `TypedSocket` designed for handling `Observation` data streams.
|
|
2743
|
+
*
|
|
2744
|
+
* @remarks
|
|
2745
|
+
* This socket acts as the bridge between the agent's internal `ObservationManager` and the external UI or monitoring systems.
|
|
2746
|
+
* It extends the generic `TypedSocket` to provide:
|
|
2747
|
+
* 1. **Type-Safe Notification**: Specifically handles `Observation` objects.
|
|
2748
|
+
* 2. **Specialized Filtering**: Allows subscribers to filter events by `ObservationType` (e.g., only subscribe to 'TOOL_EXECUTION' or 'THOUGHTS').
|
|
2749
|
+
* 3. **Historical Access**: Provides a `getHistory` method that leverages the `IObservationRepository` to fetch past observations, enabling UIs to populate initial state.
|
|
2750
|
+
*
|
|
2751
|
+
* This class is a key component of the `UISystem`.
|
|
2638
2752
|
*/
|
|
2639
2753
|
declare class ObservationSocket extends TypedSocket<Observation, ObservationType | ObservationType[]> {
|
|
2640
2754
|
private observationRepository?;
|
|
2755
|
+
/**
|
|
2756
|
+
* Creates an instance of ObservationSocket.
|
|
2757
|
+
* @param observationRepository - Optional repository for fetching observation history. If not provided, `getHistory` will return empty arrays.
|
|
2758
|
+
*/
|
|
2641
2759
|
constructor(observationRepository?: IObservationRepository);
|
|
2642
2760
|
/**
|
|
2643
|
-
* Notifies subscribers about a new observation.
|
|
2644
|
-
*
|
|
2761
|
+
* Notifies all eligible subscribers about a new observation.
|
|
2762
|
+
*
|
|
2763
|
+
* @remarks
|
|
2764
|
+
* This method is called by the `ObservationManager` whenever a new observation is recorded.
|
|
2765
|
+
* It iterates through all active subscriptions and invokes their callbacks if:
|
|
2766
|
+
* 1. The subscriber's `targetThreadId` (if any) matches the observation's `threadId`.
|
|
2767
|
+
* 2. The subscriber's `filter` (if any) matches the observation's `type`.
|
|
2768
|
+
*
|
|
2769
|
+
* @param observation - The new `Observation` object to broadcast.
|
|
2645
2770
|
*/
|
|
2646
2771
|
notifyObservation(observation: Observation): void;
|
|
2647
2772
|
/**
|
|
2648
|
-
* Retrieves historical observations
|
|
2649
|
-
*
|
|
2650
|
-
* @
|
|
2651
|
-
*
|
|
2652
|
-
*
|
|
2773
|
+
* Retrieves historical observations from the underlying repository.
|
|
2774
|
+
*
|
|
2775
|
+
* @remarks
|
|
2776
|
+
* This is typically used by UIs when they first connect to a thread to backfill the event log.
|
|
2777
|
+
* It translates the socket's filter criteria into an `ObservationFilter` compatible with the repository.
|
|
2778
|
+
*
|
|
2779
|
+
* @param filter - Optional `ObservationType` or array of types to filter the history by.
|
|
2780
|
+
* @param options - Required object containing `threadId` and optional `limit`.
|
|
2781
|
+
* @returns A promise resolving to an array of `Observation` objects matching the criteria.
|
|
2653
2782
|
*/
|
|
2654
2783
|
getHistory(filter?: ObservationType | ObservationType[], options?: {
|
|
2655
2784
|
threadId?: string;
|
|
@@ -2829,7 +2958,14 @@ interface OutputParser {
|
|
|
2829
2958
|
plan?: string;
|
|
2830
2959
|
toolCalls?: ParsedToolCall[];
|
|
2831
2960
|
thoughts?: string;
|
|
2961
|
+
todoList?: TodoItem[];
|
|
2832
2962
|
}>;
|
|
2963
|
+
/**
|
|
2964
|
+
* Parses the raw string output from the execution LLM call (per todo item).
|
|
2965
|
+
* @param output - The raw string response from the execution LLM call.
|
|
2966
|
+
* @returns A promise resolving to the structured execution output.
|
|
2967
|
+
*/
|
|
2968
|
+
parseExecutionOutput(output: string): Promise<ExecutionOutput>;
|
|
2833
2969
|
/**
|
|
2834
2970
|
* Parses the raw string output from the synthesis LLM call to extract the final, user-facing response content.
|
|
2835
2971
|
* This might involve removing extraneous tags or formatting.
|
|
@@ -3442,6 +3578,76 @@ declare class McpManager {
|
|
|
3442
3578
|
uninstallServer(serverId: string): Promise<void>;
|
|
3443
3579
|
}
|
|
3444
3580
|
|
|
3581
|
+
/**
|
|
3582
|
+
* Configuration object required by the AgentFactory and createArtInstance function.
|
|
3583
|
+
* This will now use ArtInstanceConfig from types.ts which includes stateSavingStrategy.
|
|
3584
|
+
*/
|
|
3585
|
+
/**
|
|
3586
|
+
* Handles the instantiation and wiring of all core ART framework components based on provided configuration.
|
|
3587
|
+
* This class performs the dependency injection needed to create a functional `ArtInstance`.
|
|
3588
|
+
* It's typically used internally by the `createArtInstance` function.
|
|
3589
|
+
*/
|
|
3590
|
+
declare class AgentFactory {
|
|
3591
|
+
private config;
|
|
3592
|
+
private storageAdapter;
|
|
3593
|
+
private uiSystem;
|
|
3594
|
+
private conversationRepository;
|
|
3595
|
+
private observationRepository;
|
|
3596
|
+
private stateRepository;
|
|
3597
|
+
private a2aTaskRepository;
|
|
3598
|
+
private conversationManager;
|
|
3599
|
+
private stateManager;
|
|
3600
|
+
private observationManager;
|
|
3601
|
+
private toolRegistry;
|
|
3602
|
+
private providerManager;
|
|
3603
|
+
private reasoningEngine;
|
|
3604
|
+
private outputParser;
|
|
3605
|
+
private systemPromptResolver;
|
|
3606
|
+
private toolSystem;
|
|
3607
|
+
private authManager;
|
|
3608
|
+
private mcpManager;
|
|
3609
|
+
private agentDiscoveryService;
|
|
3610
|
+
private taskDelegationService;
|
|
3611
|
+
/**
|
|
3612
|
+
* Creates a new AgentFactory instance.
|
|
3613
|
+
* @param config - The configuration specifying which adapters and components to use.
|
|
3614
|
+
*/
|
|
3615
|
+
constructor(config: ArtInstanceConfig);
|
|
3616
|
+
/**
|
|
3617
|
+
* Asynchronously initializes all core components based on the configuration.
|
|
3618
|
+
* This includes setting up the storage adapter, repositories, managers, tool registry,
|
|
3619
|
+
* reasoning engine, and UI system.
|
|
3620
|
+
* This method MUST be called before `createAgent()`.
|
|
3621
|
+
* @returns A promise that resolves when initialization is complete.
|
|
3622
|
+
* @throws {Error} If configuration is invalid or initialization fails for a component.
|
|
3623
|
+
*/
|
|
3624
|
+
initialize(): Promise<void>;
|
|
3625
|
+
/**
|
|
3626
|
+
* Creates an instance of the configured Agent Core (e.g., `PESAgent`) and injects
|
|
3627
|
+
* all necessary initialized dependencies (managers, systems, etc.).
|
|
3628
|
+
* Requires `initialize()` to have been successfully called beforehand.
|
|
3629
|
+
* @returns An instance implementing the `IAgentCore` interface.
|
|
3630
|
+
* @throws {Error} If `initialize()` was not called or if essential components failed to initialize.
|
|
3631
|
+
*/
|
|
3632
|
+
createAgent(): IAgentCore;
|
|
3633
|
+
/** Gets the initialized Storage Adapter instance. */
|
|
3634
|
+
getStorageAdapter(): StorageAdapter | null;
|
|
3635
|
+
/** Gets the initialized UI System instance. */
|
|
3636
|
+
getUISystem(): UISystem$1 | null;
|
|
3637
|
+
/** Gets the initialized Tool Registry instance. */
|
|
3638
|
+
getToolRegistry(): ToolRegistry$1 | null;
|
|
3639
|
+
/** Gets the initialized State Manager instance. */
|
|
3640
|
+
getStateManager(): StateManager$1 | null;
|
|
3641
|
+
/** Gets the initialized Conversation Manager instance. */
|
|
3642
|
+
getConversationManager(): ConversationManager | null;
|
|
3643
|
+
/** Gets the initialized Observation Manager instance. */
|
|
3644
|
+
getObservationManager(): ObservationManager | null;
|
|
3645
|
+
/** Gets the initialized Auth Manager instance. */
|
|
3646
|
+
getAuthManager(): AuthManager | null;
|
|
3647
|
+
/** Gets the initialized MCP Manager instance. */
|
|
3648
|
+
getMcpManager(): McpManager | null;
|
|
3649
|
+
}
|
|
3650
|
+
|
|
3445
3651
|
/**
|
|
3446
3652
|
* High-level factory function to create and initialize a complete ART framework instance.
|
|
3447
3653
|
* This simplifies the setup process by handling the instantiation and wiring of all
|
|
@@ -3683,91 +3889,167 @@ interface PESAgentDependencies {
|
|
|
3683
3889
|
}
|
|
3684
3890
|
/**
|
|
3685
3891
|
* Implements the Plan-Execute-Synthesize (PES) agent orchestration logic.
|
|
3686
|
-
*
|
|
3687
|
-
* 1. **Plan:** Understand the user query, determine intent, and create a plan (potentially involving tool calls).
|
|
3688
|
-
* 2. **Execute:** Run any necessary tools identified in the planning phase.
|
|
3689
|
-
* 3. **Synthesize:** Generate a final response based on the query, plan, and tool results.
|
|
3690
|
-
*
|
|
3691
|
-
* It constructs standardized prompts (`ArtStandardPrompt`) directly as JavaScript objects
|
|
3692
|
-
* for the `ReasoningEngine`. It processes the `StreamEvent` output from the reasoning engine for both planning and synthesis.
|
|
3892
|
+
* Refactored to support persistent TodoList execution and iterative refinement.
|
|
3693
3893
|
*/
|
|
3694
3894
|
declare class PESAgent implements IAgentCore {
|
|
3695
3895
|
private readonly deps;
|
|
3696
3896
|
private readonly persona;
|
|
3697
|
-
/**
|
|
3698
|
-
* Creates an instance of the PESAgent.
|
|
3699
|
-
* @param {module:core/agents/pes-agent.PESAgentDependencies} dependencies - An object containing instances of all required subsystems (managers, registries, etc.).
|
|
3700
|
-
*/
|
|
3701
3897
|
constructor(dependencies: PESAgentDependencies);
|
|
3702
3898
|
/**
|
|
3703
|
-
*
|
|
3899
|
+
* Processes a user query through the PES (Plan-Execute-Synthesize) reasoning loop.
|
|
3900
|
+
* This is the main entry point for the agent's execution logic.
|
|
3704
3901
|
*
|
|
3705
|
-
*
|
|
3706
|
-
* 1.
|
|
3707
|
-
* 2.
|
|
3708
|
-
* 3.
|
|
3709
|
-
*
|
|
3710
|
-
*
|
|
3711
|
-
*
|
|
3712
|
-
* - **Observation:** Results are fed back into the next iteration.
|
|
3713
|
-
* 4. **Synthesis:** LLM call for final response generation including all results
|
|
3714
|
-
* 5. **Finalization:** Saves messages and cleanup
|
|
3902
|
+
* The process involves:
|
|
3903
|
+
* 1. **Configuration**: Loading thread context, resolving system prompts, and determining the active persona.
|
|
3904
|
+
* 2. **Context Gathering**: Retrieving conversation history and available tools.
|
|
3905
|
+
* 3. **Planning**: Generating a new plan (Todo List) or refining an existing one based on the new query.
|
|
3906
|
+
* 4. **Execution**: Iterating through the Todo List, executing tasks, calling tools, and managing dependencies.
|
|
3907
|
+
* 5. **Synthesis**: Aggregating results to generate a final, coherent response for the user.
|
|
3908
|
+
* 6. **Finalization**: Saving the response and updating the conversation history.
|
|
3715
3909
|
*
|
|
3716
|
-
* @param
|
|
3717
|
-
* @returns
|
|
3718
|
-
* @throws {ARTError} If a critical error occurs that prevents the agent from completing the process.
|
|
3910
|
+
* @param props - The input properties for the agent execution, including the user query, thread ID, and optional configuration overrides.
|
|
3911
|
+
* @returns A promise that resolves with the final agent response and detailed execution metadata.
|
|
3719
3912
|
*/
|
|
3720
3913
|
process(props: AgentProps): Promise<AgentFinalResponse>;
|
|
3721
3914
|
/**
|
|
3722
|
-
*
|
|
3723
|
-
* @
|
|
3915
|
+
* Persists the current agent state to the StateManager.
|
|
3916
|
+
* @param threadId - The unique identifier of the thread.
|
|
3917
|
+
* @param pesState - The current state of the PES agent.
|
|
3724
3918
|
*/
|
|
3725
|
-
private
|
|
3919
|
+
private _saveState;
|
|
3726
3920
|
/**
|
|
3727
|
-
*
|
|
3728
|
-
*
|
|
3921
|
+
* Records observations related to the planning phase.
|
|
3922
|
+
* Emits events for INTENT, TITLE (if new), and PLAN.
|
|
3923
|
+
* @param threadId - The thread ID.
|
|
3924
|
+
* @param traceId - The trace ID for correlation.
|
|
3925
|
+
* @param planningOutput - The structured output from the planning LLM.
|
|
3926
|
+
* @param rawText - The raw text output from the LLM (for debugging/audit).
|
|
3729
3927
|
*/
|
|
3730
|
-
private
|
|
3928
|
+
private _recordPlanObservations;
|
|
3731
3929
|
/**
|
|
3732
|
-
*
|
|
3733
|
-
*
|
|
3930
|
+
* Executes the initial planning phase using the LLM.
|
|
3931
|
+
* Generates the initial Todo List based on the user's query and available tools.
|
|
3932
|
+
* @param props - Agent execution properties.
|
|
3933
|
+
* @param systemPrompt - The resolved system prompt for planning.
|
|
3934
|
+
* @param formattedHistory - The conversation history formatted for the LLM.
|
|
3935
|
+
* @param availableTools - List of tools available for the plan.
|
|
3936
|
+
* @param runtimeProviderConfig - Configuration for the LLM provider.
|
|
3937
|
+
* @param traceId - Trace ID for logging and observations.
|
|
3938
|
+
* @returns The structured planning output and metadata.
|
|
3734
3939
|
*/
|
|
3735
|
-
private
|
|
3940
|
+
private _performPlanning;
|
|
3736
3941
|
/**
|
|
3737
|
-
*
|
|
3738
|
-
*
|
|
3942
|
+
* Refines an existing plan based on new user input (follow-up).
|
|
3943
|
+
* Updates the Todo List to accommodate the new request while preserving context.
|
|
3944
|
+
* @param props - Agent execution properties.
|
|
3945
|
+
* @param systemPrompt - The resolved system prompt.
|
|
3946
|
+
* @param formattedHistory - Conversation history.
|
|
3947
|
+
* @param currentState - The current agent state (including the existing plan).
|
|
3948
|
+
* @param availableTools - Available tools.
|
|
3949
|
+
* @param runtimeProviderConfig - LLM provider config.
|
|
3950
|
+
* @param traceId - Trace ID.
|
|
3951
|
+
* @returns The updated planning output.
|
|
3952
|
+
*/
|
|
3953
|
+
private _performPlanRefinement;
|
|
3954
|
+
/**
|
|
3955
|
+
* Common internal method to call the LLM for planning or refinement.
|
|
3956
|
+
* Handles streaming, observation recording, and output parsing.
|
|
3957
|
+
* @param prompt - The constructed prompt.
|
|
3958
|
+
* @param props - Agent properties.
|
|
3959
|
+
* @param runtimeProviderConfig - Provider config.
|
|
3960
|
+
* @param traceId - Trace ID.
|
|
3961
|
+
* @returns Parsed output and metadata.
|
|
3962
|
+
*/
|
|
3963
|
+
private _callPlanningLLM;
|
|
3964
|
+
/**
|
|
3965
|
+
* Orchestrates the execution of the Todo List.
|
|
3966
|
+
* Loops through pending items, checks dependencies, and executes them.
|
|
3967
|
+
* @param props - Agent properties.
|
|
3968
|
+
* @param pesState - The current state containing the Todo List.
|
|
3969
|
+
* @param availableTools - Tools available for execution.
|
|
3970
|
+
* @param runtimeProviderConfig - Provider config.
|
|
3971
|
+
* @param traceId - Trace ID.
|
|
3972
|
+
* @returns Execution statistics (LLM calls, tool calls) and metadata.
|
|
3973
|
+
*/
|
|
3974
|
+
private _executeTodoList;
|
|
3975
|
+
/**
|
|
3976
|
+
* Processes a single Todo Item.
|
|
3977
|
+
* This involves calling the LLM to execute the step, potentially using tools, and updating the plan if necessary.
|
|
3978
|
+
* @param props - Agent properties.
|
|
3979
|
+
* @param item - The Todo Item to execute.
|
|
3980
|
+
* @param state - Current agent state.
|
|
3981
|
+
* @param availableTools - Available tools.
|
|
3982
|
+
* @param runtimeProviderConfig - Provider config.
|
|
3983
|
+
* @param traceId - Trace ID.
|
|
3984
|
+
* @returns Result of the item execution (status, output, usage metrics).
|
|
3985
|
+
*/
|
|
3986
|
+
private _processTodoItem;
|
|
3987
|
+
/**
|
|
3988
|
+
* Synthesizes the final response based on the completed tasks and the user's original query.
|
|
3989
|
+
* @param props - Agent properties.
|
|
3990
|
+
* @param systemPrompt - Synthesis system prompt.
|
|
3991
|
+
* @param formattedHistory - Conversation history.
|
|
3992
|
+
* @param state - Final agent state.
|
|
3993
|
+
* @param runtimeProviderConfig - Provider config.
|
|
3994
|
+
* @param traceId - Trace ID.
|
|
3995
|
+
* @param finalPersona - The persona to use for synthesis.
|
|
3996
|
+
* @returns The final response content and metadata.
|
|
3739
3997
|
*/
|
|
3740
|
-
private
|
|
3998
|
+
private _performSynthesis;
|
|
3741
3999
|
/**
|
|
3742
|
-
*
|
|
3743
|
-
* @
|
|
4000
|
+
* Loads the initial configuration, thread context, and resolves prompts.
|
|
4001
|
+
* @param props - Agent properties.
|
|
4002
|
+
* @param traceId - Trace ID.
|
|
4003
|
+
* @returns Loaded configuration and context.
|
|
4004
|
+
* @throws {ARTError} If context or config is missing.
|
|
3744
4005
|
*/
|
|
3745
|
-
private
|
|
4006
|
+
private _loadConfiguration;
|
|
3746
4007
|
/**
|
|
3747
|
-
*
|
|
3748
|
-
* @
|
|
4008
|
+
* Retrieves the conversation history for the thread.
|
|
4009
|
+
* @param threadId - The thread ID.
|
|
4010
|
+
* @param threadContext - The loaded thread context.
|
|
4011
|
+
* @returns Formatted conversation history.
|
|
3749
4012
|
*/
|
|
3750
|
-
private
|
|
4013
|
+
private _gatherHistory;
|
|
3751
4014
|
/**
|
|
3752
|
-
*
|
|
3753
|
-
* @
|
|
4015
|
+
* Retrieves available tools for the thread.
|
|
4016
|
+
* @param threadId - The thread ID.
|
|
4017
|
+
* @returns Array of available tool schemas.
|
|
3754
4018
|
*/
|
|
3755
|
-
private
|
|
4019
|
+
private _gatherTools;
|
|
3756
4020
|
/**
|
|
3757
|
-
*
|
|
3758
|
-
*
|
|
4021
|
+
* Delegates tasks to other agents (Agent-to-Agent).
|
|
4022
|
+
* Discovers agents and sends task requests.
|
|
4023
|
+
* @param planningOutput - Output from the planning phase containing potential delegation calls.
|
|
4024
|
+
* @param threadId - Current thread ID.
|
|
4025
|
+
* @param traceId - Trace ID.
|
|
4026
|
+
* @returns Array of created A2A tasks.
|
|
3759
4027
|
*/
|
|
3760
|
-
private
|
|
4028
|
+
private _delegateA2ATasks;
|
|
3761
4029
|
/**
|
|
3762
|
-
*
|
|
3763
|
-
*
|
|
4030
|
+
* Waits for delegated A2A tasks to complete.
|
|
4031
|
+
* Polls the repository until all tasks are in a terminal state or timeout is reached.
|
|
4032
|
+
* @param a2aTasks - The tasks to wait for.
|
|
4033
|
+
* @param threadId - Thread ID.
|
|
4034
|
+
* @param traceId - Trace ID.
|
|
4035
|
+
* @param maxWaitTimeMs - Maximum time to wait in milliseconds.
|
|
4036
|
+
* @param pollIntervalMs - Polling interval.
|
|
4037
|
+
* @returns The updated list of tasks.
|
|
4038
|
+
*/
|
|
4039
|
+
private _waitForA2ACompletion;
|
|
4040
|
+
/**
|
|
4041
|
+
* Finalizes the agent execution by saving the AI response and recording the final observation.
|
|
4042
|
+
* @param props - Agent properties.
|
|
4043
|
+
* @param finalResponseContent - The content of the final AI message.
|
|
4044
|
+
* @param traceId - Trace ID.
|
|
4045
|
+
* @param uiMetadata - Optional UI metadata extracted from the response.
|
|
4046
|
+
* @returns The created ConversationMessage object.
|
|
3764
4047
|
*/
|
|
3765
4048
|
private _finalize;
|
|
3766
4049
|
/**
|
|
3767
|
-
*
|
|
3768
|
-
*
|
|
3769
|
-
* @
|
|
3770
|
-
* @returns Array of messages suitable for ArtStandardPrompt.
|
|
4050
|
+
* Helper to format internal conversation messages into the standard prompt format required by the LLM.
|
|
4051
|
+
* @param history - Array of ConversationMessages.
|
|
4052
|
+
* @returns Array of formatted prompt messages.
|
|
3771
4053
|
*/
|
|
3772
4054
|
private formatHistoryForPrompt;
|
|
3773
4055
|
}
|
|
@@ -4081,7 +4363,7 @@ declare class SupabaseStorageAdapter implements StorageAdapter {
|
|
|
4081
4363
|
interface GeminiAdapterOptions {
|
|
4082
4364
|
/** Your Google AI API key (e.g., from Google AI Studio). Handle securely. */
|
|
4083
4365
|
apiKey: string;
|
|
4084
|
-
/** The default Gemini model ID to use (e.g., 'gemini-
|
|
4366
|
+
/** The default Gemini model ID to use (e.g., 'gemini-3-flash', 'gemini-pro'). Defaults to 'gemini-3-flash' if not provided. */
|
|
4085
4367
|
model?: string;
|
|
4086
4368
|
/** Optional: Override the base URL for the Google Generative AI API. */
|
|
4087
4369
|
apiBaseUrl?: string;
|
|
@@ -4109,10 +4391,11 @@ declare class GeminiAdapter implements ProviderAdapter {
|
|
|
4109
4391
|
* Handles both streaming and non-streaming requests based on `options.stream`.
|
|
4110
4392
|
*
|
|
4111
4393
|
* Thinking tokens (Gemini):
|
|
4112
|
-
* - On supported Gemini models (e.g., `gemini-
|
|
4394
|
+
* - On supported Gemini models (e.g., `gemini-3-*`), you can enable thought output via `config.thinkingConfig`.
|
|
4113
4395
|
* - This adapter reads provider-specific flags from the call options:
|
|
4114
4396
|
* - `options.gemini.thinking.includeThoughts: boolean` — when `true`, requests thought (reasoning) output.
|
|
4115
4397
|
* - `options.gemini.thinking.thinkingBudget?: number` — optional token budget for thinking.
|
|
4398
|
+
* - `options.gemini.thinking.thinkingLevel?: 'low' | 'minimal' | 'medium' | 'high'` — optional thinking level (Gemini 3+).
|
|
4116
4399
|
* - When enabled and supported, the adapter will attempt to differentiate thought vs response parts and set
|
|
4117
4400
|
* `StreamEvent.tokenType` accordingly:
|
|
4118
4401
|
* - For planning calls (`callContext === 'AGENT_THOUGHT'`): `AGENT_THOUGHT_LLM_THINKING` or `AGENT_THOUGHT_LLM_RESPONSE`.
|
|
@@ -4154,22 +4437,20 @@ declare class GeminiAdapter implements ProviderAdapter {
|
|
|
4154
4437
|
*/
|
|
4155
4438
|
call(prompt: ArtStandardPrompt, options: CallOptions): Promise<AsyncIterable<StreamEvent>>;
|
|
4156
4439
|
/**
|
|
4157
|
-
* Translates the provider-agnostic `ArtStandardPrompt` into the Gemini API's `Content[]` format
|
|
4440
|
+
* Translates the provider-agnostic `ArtStandardPrompt` into the Gemini API's `Content[]` format
|
|
4441
|
+
* and extracts any system instructions.
|
|
4158
4442
|
*
|
|
4159
4443
|
* Key translations:
|
|
4160
|
-
* - `system` role:
|
|
4444
|
+
* - `system` role: Extracted to `systemInstruction`.
|
|
4161
4445
|
* - `user` role: Maps to Gemini's `user` role.
|
|
4162
4446
|
* - `assistant` role: Maps to Gemini's `model` role. Handles text content and `tool_calls` (mapped to `functionCall`).
|
|
4163
4447
|
* - `tool_result` role: Maps to Gemini's `user` role with a `functionResponse` part.
|
|
4164
4448
|
* - `tool_request` role: Skipped (implicitly handled by `assistant`'s `tool_calls`).
|
|
4165
4449
|
*
|
|
4166
|
-
* Adds validation to ensure the conversation doesn't start with a 'model' role.
|
|
4167
|
-
*
|
|
4168
4450
|
* @private
|
|
4169
4451
|
* @param {ArtStandardPrompt} artPrompt - The input `ArtStandardPrompt` array.
|
|
4170
|
-
* @returns {
|
|
4171
|
-
* @throws {ARTError} If translation encounters an issue
|
|
4172
|
-
* @see https://ai.google.dev/api/rest/v1beta/Content
|
|
4452
|
+
* @returns {{ contents: Content[], systemInstruction?: string }} The Gemini formatted payload.
|
|
4453
|
+
* @throws {ARTError} If translation encounters an issue.
|
|
4173
4454
|
*/
|
|
4174
4455
|
private translateToGemini;
|
|
4175
4456
|
}
|
|
@@ -4180,7 +4461,7 @@ declare class GeminiAdapter implements ProviderAdapter {
|
|
|
4180
4461
|
interface OpenAIAdapterOptions {
|
|
4181
4462
|
/** Your OpenAI API key. Handle securely. */
|
|
4182
4463
|
apiKey: string;
|
|
4183
|
-
/** The default OpenAI model ID to use (e.g., 'gpt-
|
|
4464
|
+
/** The default OpenAI model ID to use (e.g., 'gpt-5.2-instant', 'gpt-5.2-thinking', 'gpt-5.2-pro'). */
|
|
4184
4465
|
model?: string;
|
|
4185
4466
|
/** Optional: Override the base URL for the OpenAI API (e.g., for Azure OpenAI or custom proxies). */
|
|
4186
4467
|
apiBaseUrl?: string;
|
|
@@ -4259,7 +4540,7 @@ declare class OpenAIAdapter implements ProviderAdapter {
|
|
|
4259
4540
|
interface AnthropicAdapterOptions {
|
|
4260
4541
|
/** Your Anthropic API key. Handle securely. */
|
|
4261
4542
|
apiKey: string;
|
|
4262
|
-
/** The default Anthropic model ID to use (e.g., '
|
|
4543
|
+
/** The default Anthropic model ID to use (e.g., 'claude_4.5_sonnet', 'claude_4.5_opus'). */
|
|
4263
4544
|
model?: string;
|
|
4264
4545
|
/** Optional: Override the base URL for the Anthropic API. */
|
|
4265
4546
|
apiBaseUrl?: string;
|
|
@@ -4948,7 +5229,17 @@ declare class McpProxyTool implements IToolExecutor {
|
|
|
4948
5229
|
|
|
4949
5230
|
/**
|
|
4950
5231
|
* Manages thread-specific configuration (ThreadConfig) and state (AgentState)
|
|
4951
|
-
* using an underlying StateRepository.
|
|
5232
|
+
* using an underlying StateRepository.
|
|
5233
|
+
*
|
|
5234
|
+
* This class serves as the central point for accessing and modifying the persistent context
|
|
5235
|
+
* of a conversation thread. It supports two state saving strategies:
|
|
5236
|
+
*
|
|
5237
|
+
* 1. **Explicit**: The agent is responsible for calling `setAgentState()` whenever it wants to persist changes.
|
|
5238
|
+
* `saveStateIfModified()` is a no-op. This gives fine-grained control but requires discipline.
|
|
5239
|
+
*
|
|
5240
|
+
* 2. **Implicit**: State is loaded via `loadThreadContext()` and cached. The agent modifies the state object in-memory.
|
|
5241
|
+
* Calls to `saveStateIfModified()` (typically at the end of an execution cycle) compare the current state
|
|
5242
|
+
* against the initial snapshot and persist only if changes are detected. This simplifies agent logic.
|
|
4952
5243
|
*/
|
|
4953
5244
|
declare class StateManager implements StateManager$1 {
|
|
4954
5245
|
private repository;
|
|
@@ -4962,8 +5253,12 @@ declare class StateManager implements StateManager$1 {
|
|
|
4962
5253
|
constructor(stateRepository: IStateRepository, strategy?: StateSavingStrategy);
|
|
4963
5254
|
/**
|
|
4964
5255
|
* Loads the complete context (`ThreadConfig` and `AgentState`) for a specific thread.
|
|
4965
|
-
*
|
|
4966
|
-
*
|
|
5256
|
+
*
|
|
5257
|
+
* - In **Implicit** mode: Caches the loaded context and creates a snapshot of the `AgentState`.
|
|
5258
|
+
* This snapshot is used later by `saveStateIfModified` to detect changes. Subsequent loads
|
|
5259
|
+
* within the same lifecycle might return the cached object to maintain reference consistency.
|
|
5260
|
+
* - In **Explicit** mode: Simply fetches data from the repository.
|
|
5261
|
+
*
|
|
4967
5262
|
* @param {string} threadId - The unique identifier for the thread.
|
|
4968
5263
|
* @param {string} [_userId] - Optional user identifier (currently unused).
|
|
4969
5264
|
* @returns {Promise<ThreadContext>} A promise resolving to the `ThreadContext` object.
|
|
@@ -4989,11 +5284,13 @@ declare class StateManager implements StateManager$1 {
|
|
|
4989
5284
|
getThreadConfigValue<T>(threadId: string, key: string): Promise<T | undefined>;
|
|
4990
5285
|
/**
|
|
4991
5286
|
* Persists the thread's `AgentState` if it has been modified.
|
|
5287
|
+
*
|
|
4992
5288
|
* Behavior depends on the `stateSavingStrategy`:
|
|
4993
|
-
* - 'explicit'
|
|
4994
|
-
* - 'implicit'
|
|
4995
|
-
*
|
|
4996
|
-
*
|
|
5289
|
+
* - **'explicit'**: This method is a no-op for `AgentState` persistence and logs a warning. State must be saved manually via `setAgentState`.
|
|
5290
|
+
* - **'implicit'**: Compares the current `AgentState` (from the cached `ThreadContext` modified by the agent)
|
|
5291
|
+
* with the snapshot taken during `loadThreadContext`. If different, saves the state
|
|
5292
|
+
* to the repository and updates the snapshot.
|
|
5293
|
+
*
|
|
4997
5294
|
* @param {string} threadId - The ID of the thread whose state might need saving.
|
|
4998
5295
|
* @returns {Promise<void>} A promise that resolves when the state is saved or the operation is skipped.
|
|
4999
5296
|
*/
|
|
@@ -5008,8 +5305,10 @@ declare class StateManager implements StateManager$1 {
|
|
|
5008
5305
|
setThreadConfig(threadId: string, config: ThreadConfig): Promise<void>;
|
|
5009
5306
|
/**
|
|
5010
5307
|
* Explicitly sets or updates the AgentState for a specific thread by calling the underlying state repository.
|
|
5011
|
-
*
|
|
5012
|
-
*
|
|
5308
|
+
*
|
|
5309
|
+
* - If in **Implicit** mode: This also updates the cached snapshot to prevent `saveStateIfModified`
|
|
5310
|
+
* from re-saving the same state immediately (optimizing writes).
|
|
5311
|
+
*
|
|
5013
5312
|
* @param {string} threadId - The unique identifier of the thread.
|
|
5014
5313
|
* @param {AgentState} state - The AgentState object to save. Must not be undefined or null.
|
|
5015
5314
|
* @returns {Promise<void>} A promise that resolves when the state is saved.
|
|
@@ -5202,6 +5501,6 @@ declare const generateUUID: () => string;
|
|
|
5202
5501
|
/**
|
|
5203
5502
|
* The current version of the ART Framework package.
|
|
5204
5503
|
*/
|
|
5205
|
-
declare const VERSION = "0.
|
|
5504
|
+
declare const VERSION = "0.4.1";
|
|
5206
5505
|
|
|
5207
|
-
export { type A2AAgentInfo, type A2ATask, type A2ATaskEvent, type A2ATaskFilter, type A2ATaskMetadata, A2ATaskPriority, type A2ATaskResult, A2ATaskSocket, A2ATaskStatus, ARTError, AdapterInstantiationError, type AgentDiscoveryConfig, AgentDiscoveryService, type AgentFinalResponse, type AgentOptions, type AgentPersona, type AgentProps, type AgentState, AnthropicAdapter, type AnthropicAdapterOptions, ApiKeyStrategy, ApiQueueTimeoutError, type ArtInstance, type ArtInstanceConfig, type ArtStandardMessage, type ArtStandardMessageRole, ArtStandardMessageSchema, type ArtStandardPrompt, ArtStandardPromptSchema, AuthManager, type AvailableProviderEntry, CalculatorTool, type CallOptions, type ConversationManager, type ConversationMessage, ConversationSocket, type CreateA2ATaskRequest, DeepSeekAdapter, type DeepSeekAdapterOptions, ErrorCode, type ExecutionContext, type ExecutionMetadata, type FilterOptions, type FormattedPrompt, GeminiAdapter, type GeminiAdapterOptions, GenericOAuthStrategy, type IA2ATaskRepository, type IAgentCore, type IAuthStrategy, type IConversationRepository, type IObservationRepository, type IProviderManager, type IStateRepository, type IToolExecutor, type ITypedSocket, InMemoryStorageAdapter, IndexedDBStorageAdapter, type JsonObjectSchema, type JsonSchema, type LLMMetadata, LLMStreamSocket, LocalInstanceBusyError, LocalProviderConflictError, LogLevel, Logger, type LoggerConfig, type ManagedAdapterAccessor, McpClientController, McpManager, type McpManagerConfig, McpProxyTool, type McpResource, type McpResourceTemplate, type McpServerConfig, type McpServerStatus, type McpToolDefinition, type MessageOptions, MessageRole, ModelCapability, type OAuthConfig, type Observation, type ObservationFilter, type ObservationManager, ObservationSocket, ObservationType, OllamaAdapter, type OllamaAdapterOptions, OpenAIAdapter, type OpenAIAdapterOptions, OpenRouterAdapter, type OpenRouterAdapterOptions, type OutputParser, PESAgent, type PKCEOAuthConfig, PKCEOAuthStrategy, type ParsedToolCall, type PromptBlueprint, type PromptContext, type ProviderAdapter, type ProviderManagerConfig, ProviderManagerImpl, type ReasoningEngine, type RuntimeProviderConfig, type StageSpecificPrompts, StateManager, type StateSavingStrategy, type StorageAdapter, type StreamEvent, type StreamEventTypeFilter, SupabaseStorageAdapter, type SystemPromptMergeStrategy, type SystemPromptOverride, type SystemPromptResolver, type SystemPromptSpec, type SystemPromptsRegistry, type TaskDelegationConfig, TaskDelegationService, type TaskStatusResponse, type ThreadConfig, type ThreadContext, ToolRegistry, type ToolResult, type ToolSchema, type ToolSystem, TypedSocket, UISystem, UnknownProviderError, type UnsubscribeFunction, type UpdateA2ATaskRequest, VERSION, type ZyntopiaOAuthConfig, ZyntopiaOAuthStrategy, createArtInstance, generateUUID };
|
|
5506
|
+
export { type A2AAgentInfo, type A2ATask, type A2ATaskEvent, type A2ATaskFilter, type A2ATaskMetadata, A2ATaskPriority, type A2ATaskResult, A2ATaskSocket, A2ATaskStatus, ARTError, AdapterInstantiationError, type AgentDiscoveryConfig, AgentDiscoveryService, AgentFactory, type AgentFinalResponse, type AgentOptions, type AgentPersona, type AgentProps, type AgentState, AnthropicAdapter, type AnthropicAdapterOptions, ApiKeyStrategy, ApiQueueTimeoutError, type ArtInstance, type ArtInstanceConfig, type ArtStandardMessage, type ArtStandardMessageRole, ArtStandardMessageSchema, type ArtStandardPrompt, ArtStandardPromptSchema, AuthManager, type AvailableProviderEntry, CalculatorTool, type CallOptions, type ConversationManager, type ConversationMessage, ConversationSocket, type CreateA2ATaskRequest, DeepSeekAdapter, type DeepSeekAdapterOptions, ErrorCode, type ExecutionContext, type ExecutionMetadata, type ExecutionOutput, type FilterOptions, type FormattedPrompt, GeminiAdapter, type GeminiAdapterOptions, GenericOAuthStrategy, type IA2ATaskRepository, type IAgentCore, type IAuthStrategy, type IConversationRepository, type IObservationRepository, type IProviderManager, type IStateRepository, type IToolExecutor, type ITypedSocket, InMemoryStorageAdapter, IndexedDBStorageAdapter, type JsonObjectSchema, type JsonSchema, type LLMMetadata, LLMStreamSocket, LocalInstanceBusyError, LocalProviderConflictError, LogLevel, Logger, type LoggerConfig, type ManagedAdapterAccessor, McpClientController, McpManager, type McpManagerConfig, McpProxyTool, type McpResource, type McpResourceTemplate, type McpServerConfig, type McpServerStatus, type McpToolDefinition, type MessageOptions, MessageRole, ModelCapability, type OAuthConfig, type Observation, type ObservationFilter, type ObservationManager, ObservationSocket, ObservationType, OllamaAdapter, type OllamaAdapterOptions, OpenAIAdapter, type OpenAIAdapterOptions, OpenRouterAdapter, type OpenRouterAdapterOptions, type OutputParser, PESAgent, type PESAgentStateData, type PKCEOAuthConfig, PKCEOAuthStrategy, type ParsedToolCall, type PromptBlueprint, type PromptContext, type ProviderAdapter, type ProviderManagerConfig, ProviderManagerImpl, type ReasoningEngine, type RuntimeProviderConfig, type StageSpecificPrompts, StateManager, type StateSavingStrategy, type StorageAdapter, type StreamEvent, type StreamEventTypeFilter, SupabaseStorageAdapter, type SystemPromptMergeStrategy, type SystemPromptOverride, type SystemPromptResolver, type SystemPromptSpec, type SystemPromptsRegistry, type TaskDelegationConfig, TaskDelegationService, type TaskStatusResponse, type ThreadConfig, type ThreadContext, type TodoItem, TodoItemStatus, ToolRegistry, type ToolResult, type ToolSchema, type ToolSystem, TypedSocket, UISystem, UnknownProviderError, type UnsubscribeFunction, type UpdateA2ATaskRequest, VERSION, type ZyntopiaOAuthConfig, ZyntopiaOAuthStrategy, createArtInstance, generateUUID };
|