@robosystems/client 0.3.27 → 0.3.29

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.
@@ -1,4 +1,4 @@
1
- export interface AgentQueryRequest {
1
+ export interface OperatorQueryRequest {
2
2
  message: string;
3
3
  history?: Array<{
4
4
  role: string;
@@ -9,14 +9,14 @@ export interface AgentQueryRequest {
9
9
  enableRag?: boolean;
10
10
  forceExtendedAnalysis?: boolean;
11
11
  }
12
- export interface AgentOptions {
12
+ export interface OperatorOptions {
13
13
  mode?: 'auto' | 'sync' | 'async';
14
14
  maxWait?: number;
15
15
  onProgress?: (message: string, percentage?: number) => void;
16
16
  }
17
- export interface AgentResult {
17
+ export interface OperatorResult {
18
18
  content: string;
19
- agent_used: string;
19
+ operator_used: string;
20
20
  mode_used: 'quick' | 'standard' | 'extended' | 'streaming';
21
21
  metadata?: Record<string, any>;
22
22
  tokens_used?: {
@@ -28,13 +28,13 @@ export interface AgentResult {
28
28
  execution_time?: number;
29
29
  timestamp?: string;
30
30
  }
31
- export interface QueuedAgentResponse {
31
+ export interface QueuedOperatorResponse {
32
32
  status: 'queued';
33
33
  operation_id: string;
34
34
  message: string;
35
35
  sse_endpoint?: string;
36
36
  }
37
- export declare class AgentClient {
37
+ export declare class OperatorClient {
38
38
  private sseClient?;
39
39
  private config;
40
40
  constructor(config: {
@@ -44,30 +44,30 @@ export declare class AgentClient {
44
44
  token?: string;
45
45
  });
46
46
  /**
47
- * Execute agent query with automatic agent selection
47
+ * Execute operator query with automatic operator selection
48
48
  */
49
- executeQuery(graphId: string, request: AgentQueryRequest, options?: AgentOptions): Promise<AgentResult>;
49
+ executeQuery(graphId: string, request: OperatorQueryRequest, options?: OperatorOptions): Promise<OperatorResult>;
50
50
  /**
51
- * Execute specific agent type
51
+ * Execute specific operator type
52
52
  */
53
- executeAgent(graphId: string, agentType: string, request: AgentQueryRequest, options?: AgentOptions): Promise<AgentResult>;
54
- private waitForAgentCompletion;
53
+ executeOperator(graphId: string, operatorType: string, request: OperatorQueryRequest, options?: OperatorOptions): Promise<OperatorResult>;
54
+ private waitForOperatorCompletion;
55
55
  /**
56
56
  * Convenience method for simple agent queries with auto-selection
57
57
  */
58
- query(graphId: string, message: string, context?: Record<string, any>): Promise<AgentResult>;
58
+ query(graphId: string, message: string, context?: Record<string, any>): Promise<OperatorResult>;
59
59
  /**
60
60
  * Execute financial agent for financial analysis
61
61
  */
62
- analyzeFinancials(graphId: string, message: string, options?: AgentOptions): Promise<AgentResult>;
62
+ analyzeFinancials(graphId: string, message: string, options?: OperatorOptions): Promise<OperatorResult>;
63
63
  /**
64
64
  * Execute research agent for deep research
65
65
  */
66
- research(graphId: string, message: string, options?: AgentOptions): Promise<AgentResult>;
66
+ research(graphId: string, message: string, options?: OperatorOptions): Promise<OperatorResult>;
67
67
  /**
68
68
  * Execute RAG agent for fast retrieval
69
69
  */
70
- rag(graphId: string, message: string, options?: AgentOptions): Promise<AgentResult>;
70
+ rag(graphId: string, message: string, options?: OperatorOptions): Promise<OperatorResult>;
71
71
  /**
72
72
  * Cancel any active SSE connections
73
73
  */
@@ -76,7 +76,7 @@ export declare class AgentClient {
76
76
  /**
77
77
  * Error thrown when agent execution is queued and maxWait is 0
78
78
  */
79
- export declare class QueuedAgentError extends Error {
80
- queueInfo: QueuedAgentResponse;
81
- constructor(queueInfo: QueuedAgentResponse);
79
+ export declare class QueuedOperatorError extends Error {
80
+ queueInfo: QueuedOperatorResponse;
81
+ constructor(queueInfo: QueuedOperatorResponse);
82
82
  }
@@ -1,23 +1,23 @@
1
1
  'use client';
2
2
  "use strict";
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
- exports.QueuedAgentError = exports.AgentClient = void 0;
4
+ exports.QueuedOperatorError = exports.OperatorClient = void 0;
5
5
  /**
6
- * Enhanced Agent Client with SSE support
7
- * Provides intelligent agent execution with automatic strategy selection
6
+ * Enhanced AI Operator Client with SSE support
7
+ * Provides intelligent operator execution with automatic strategy selection
8
8
  */
9
9
  const sdk_gen_1 = require("../sdk.gen");
10
10
  const SSEClient_1 = require("./SSEClient");
11
- class AgentClient {
11
+ class OperatorClient {
12
12
  constructor(config) {
13
13
  this.config = config;
14
14
  }
15
15
  /**
16
- * Execute agent query with automatic agent selection
16
+ * Execute operator query with automatic operator selection
17
17
  */
18
18
  async executeQuery(graphId, request, options = {}) {
19
19
  const data = {
20
- url: '/v1/graphs/{graph_id}/agent',
20
+ url: '/v1/graphs/{graph_id}/operator',
21
21
  path: { graph_id: graphId },
22
22
  body: {
23
23
  message: request.message,
@@ -28,13 +28,13 @@ class AgentClient {
28
28
  force_extended_analysis: request.forceExtendedAnalysis,
29
29
  },
30
30
  };
31
- const response = await (0, sdk_gen_1.autoSelectAgent)(data);
31
+ const response = await (0, sdk_gen_1.autoSelectOperator)(data);
32
32
  const responseData = response.data;
33
33
  // Check if this is an immediate response (sync execution)
34
- if (responseData?.content !== undefined && responseData?.agent_used) {
34
+ if (responseData?.content !== undefined && responseData?.operator_used) {
35
35
  return {
36
36
  content: responseData.content,
37
- agent_used: responseData.agent_used,
37
+ operator_used: responseData.operator_used,
38
38
  mode_used: responseData.mode_used,
39
39
  metadata: responseData.metadata,
40
40
  tokens_used: responseData.tokens_used,
@@ -48,21 +48,21 @@ class AgentClient {
48
48
  const queuedResponse = responseData;
49
49
  // If user doesn't want to wait, throw with queue info
50
50
  if (options.maxWait === 0) {
51
- throw new QueuedAgentError(queuedResponse);
51
+ throw new QueuedOperatorError(queuedResponse);
52
52
  }
53
53
  // Use SSE to monitor the operation
54
- return this.waitForAgentCompletion(queuedResponse.operation_id, options);
54
+ return this.waitForOperatorCompletion(queuedResponse.operation_id, options);
55
55
  }
56
56
  // Unexpected response format
57
- throw new Error('Unexpected response format from agent endpoint');
57
+ throw new Error('Unexpected response format from operator endpoint');
58
58
  }
59
59
  /**
60
- * Execute specific agent type
60
+ * Execute specific operator type
61
61
  */
62
- async executeAgent(graphId, agentType, request, options = {}) {
62
+ async executeOperator(graphId, operatorType, request, options = {}) {
63
63
  const data = {
64
- url: '/v1/graphs/{graph_id}/agent/{agent_type}',
65
- path: { graph_id: graphId, agent_type: agentType },
64
+ url: '/v1/graphs/{graph_id}/operator/{operator_type}',
65
+ path: { graph_id: graphId, operator_type: operatorType },
66
66
  body: {
67
67
  message: request.message,
68
68
  history: request.history,
@@ -72,13 +72,13 @@ class AgentClient {
72
72
  force_extended_analysis: request.forceExtendedAnalysis,
73
73
  },
74
74
  };
75
- const response = await (0, sdk_gen_1.executeSpecificAgent)(data);
75
+ const response = await (0, sdk_gen_1.executeSpecificOperator)(data);
76
76
  const responseData = response.data;
77
77
  // Check if this is an immediate response (sync execution)
78
- if (responseData?.content !== undefined && responseData?.agent_used) {
78
+ if (responseData?.content !== undefined && responseData?.operator_used) {
79
79
  return {
80
80
  content: responseData.content,
81
- agent_used: responseData.agent_used,
81
+ operator_used: responseData.operator_used,
82
82
  mode_used: responseData.mode_used,
83
83
  metadata: responseData.metadata,
84
84
  tokens_used: responseData.tokens_used,
@@ -92,15 +92,15 @@ class AgentClient {
92
92
  const queuedResponse = responseData;
93
93
  // If user doesn't want to wait, throw with queue info
94
94
  if (options.maxWait === 0) {
95
- throw new QueuedAgentError(queuedResponse);
95
+ throw new QueuedOperatorError(queuedResponse);
96
96
  }
97
97
  // Use SSE to monitor the operation
98
- return this.waitForAgentCompletion(queuedResponse.operation_id, options);
98
+ return this.waitForOperatorCompletion(queuedResponse.operation_id, options);
99
99
  }
100
100
  // Unexpected response format
101
- throw new Error('Unexpected response format from agent endpoint');
101
+ throw new Error('Unexpected response format from operator endpoint');
102
102
  }
103
- async waitForAgentCompletion(operationId, options) {
103
+ async waitForOperatorCompletion(operationId, options) {
104
104
  return new Promise((resolve, reject) => {
105
105
  const sseClient = new SSEClient_1.SSEClient(this.config);
106
106
  sseClient
@@ -112,19 +112,19 @@ class AgentClient {
112
112
  options.onProgress?.(data.message, data.progress_percentage);
113
113
  });
114
114
  // Listen for agent-specific events
115
- sseClient.on('agent_started', (data) => {
116
- options.onProgress?.(`Agent ${data.agent_type} started`, 0);
115
+ sseClient.on('operator_started', (data) => {
116
+ options.onProgress?.(`Operator ${data.operator_type} started`, 0);
117
117
  });
118
- sseClient.on('agent_initialized', (data) => {
118
+ sseClient.on('operator_initialized', (data) => {
119
119
  options.onProgress?.(`${data.agent_name} initialized`, 10);
120
120
  });
121
121
  sseClient.on('progress', (data) => {
122
122
  options.onProgress?.(data.message, data.percentage);
123
123
  });
124
- sseClient.on('agent_completed', (data) => {
124
+ sseClient.on('operator_completed', (data) => {
125
125
  result = {
126
126
  content: data.content,
127
- agent_used: data.agent_used,
127
+ operator_used: data.operator_used,
128
128
  mode_used: data.mode_used,
129
129
  metadata: data.metadata,
130
130
  tokens_used: data.tokens_used,
@@ -138,16 +138,16 @@ class AgentClient {
138
138
  // Fallback to generic completion event
139
139
  sseClient.on(SSEClient_1.EventType.OPERATION_COMPLETED, (data) => {
140
140
  if (!result) {
141
- const agentResult = data.result || data;
141
+ const operatorResult = data.result || data;
142
142
  result = {
143
- content: agentResult.content || '',
144
- agent_used: agentResult.agent_used || 'unknown',
145
- mode_used: agentResult.mode_used || 'standard',
146
- metadata: agentResult.metadata,
147
- tokens_used: agentResult.tokens_used,
148
- confidence_score: agentResult.confidence_score,
149
- execution_time: agentResult.execution_time,
150
- timestamp: agentResult.timestamp || new Date().toISOString(),
143
+ content: operatorResult.content || '',
144
+ operator_used: operatorResult.operator_used || 'unknown',
145
+ mode_used: operatorResult.mode_used || 'standard',
146
+ metadata: operatorResult.metadata,
147
+ tokens_used: operatorResult.tokens_used,
148
+ confidence_score: operatorResult.confidence_score,
149
+ execution_time: operatorResult.execution_time,
150
+ timestamp: operatorResult.timestamp || new Date().toISOString(),
151
151
  };
152
152
  sseClient.close();
153
153
  resolve(result);
@@ -180,19 +180,19 @@ class AgentClient {
180
180
  * Execute financial agent for financial analysis
181
181
  */
182
182
  async analyzeFinancials(graphId, message, options = {}) {
183
- return this.executeAgent(graphId, 'financial', { message }, options);
183
+ return this.executeOperator(graphId, 'financial', { message }, options);
184
184
  }
185
185
  /**
186
186
  * Execute research agent for deep research
187
187
  */
188
188
  async research(graphId, message, options = {}) {
189
- return this.executeAgent(graphId, 'research', { message }, options);
189
+ return this.executeOperator(graphId, 'research', { message }, options);
190
190
  }
191
191
  /**
192
192
  * Execute RAG agent for fast retrieval
193
193
  */
194
194
  async rag(graphId, message, options = {}) {
195
- return this.executeAgent(graphId, 'rag', { message }, options);
195
+ return this.executeOperator(graphId, 'rag', { message }, options);
196
196
  }
197
197
  /**
198
198
  * Cancel any active SSE connections
@@ -204,15 +204,15 @@ class AgentClient {
204
204
  }
205
205
  }
206
206
  }
207
- exports.AgentClient = AgentClient;
207
+ exports.OperatorClient = OperatorClient;
208
208
  /**
209
209
  * Error thrown when agent execution is queued and maxWait is 0
210
210
  */
211
- class QueuedAgentError extends Error {
211
+ class QueuedOperatorError extends Error {
212
212
  constructor(queueInfo) {
213
- super('Agent execution was queued');
213
+ super('Operator execution was queued');
214
214
  this.queueInfo = queueInfo;
215
- this.name = 'QueuedAgentError';
215
+ this.name = 'QueuedOperatorError';
216
216
  }
217
217
  }
218
- exports.QueuedAgentError = QueuedAgentError;
218
+ exports.QueuedOperatorError = QueuedOperatorError;
@@ -1,15 +1,15 @@
1
1
  'use client'
2
2
 
3
3
  /**
4
- * Enhanced Agent Client with SSE support
5
- * Provides intelligent agent execution with automatic strategy selection
4
+ * Enhanced AI Operator Client with SSE support
5
+ * Provides intelligent operator execution with automatic strategy selection
6
6
  */
7
7
 
8
- import { autoSelectAgent, executeSpecificAgent } from '../sdk.gen'
9
- import type { AutoSelectAgentData, ExecuteSpecificAgentData } from '../types.gen'
8
+ import { autoSelectOperator, executeSpecificOperator } from '../sdk.gen'
9
+ import type { AutoSelectOperatorData, ExecuteSpecificOperatorData } from '../types.gen'
10
10
  import { EventType, SSEClient } from './SSEClient'
11
11
 
12
- export interface AgentQueryRequest {
12
+ export interface OperatorQueryRequest {
13
13
  message: string
14
14
  history?: Array<{ role: string; content: string }>
15
15
  context?: Record<string, any>
@@ -18,15 +18,15 @@ export interface AgentQueryRequest {
18
18
  forceExtendedAnalysis?: boolean
19
19
  }
20
20
 
21
- export interface AgentOptions {
21
+ export interface OperatorOptions {
22
22
  mode?: 'auto' | 'sync' | 'async'
23
23
  maxWait?: number
24
24
  onProgress?: (message: string, percentage?: number) => void
25
25
  }
26
26
 
27
- export interface AgentResult {
27
+ export interface OperatorResult {
28
28
  content: string
29
- agent_used: string
29
+ operator_used: string
30
30
  mode_used: 'quick' | 'standard' | 'extended' | 'streaming'
31
31
  metadata?: Record<string, any>
32
32
  tokens_used?: {
@@ -39,14 +39,14 @@ export interface AgentResult {
39
39
  timestamp?: string
40
40
  }
41
41
 
42
- export interface QueuedAgentResponse {
42
+ export interface QueuedOperatorResponse {
43
43
  status: 'queued'
44
44
  operation_id: string
45
45
  message: string
46
46
  sse_endpoint?: string
47
47
  }
48
48
 
49
- export class AgentClient {
49
+ export class OperatorClient {
50
50
  private sseClient?: SSEClient
51
51
  private config: {
52
52
  baseUrl: string
@@ -65,15 +65,15 @@ export class AgentClient {
65
65
  }
66
66
 
67
67
  /**
68
- * Execute agent query with automatic agent selection
68
+ * Execute operator query with automatic operator selection
69
69
  */
70
70
  async executeQuery(
71
71
  graphId: string,
72
- request: AgentQueryRequest,
73
- options: AgentOptions = {}
74
- ): Promise<AgentResult> {
75
- const data: AutoSelectAgentData = {
76
- url: '/v1/graphs/{graph_id}/agent' as const,
72
+ request: OperatorQueryRequest,
73
+ options: OperatorOptions = {}
74
+ ): Promise<OperatorResult> {
75
+ const data: AutoSelectOperatorData = {
76
+ url: '/v1/graphs/{graph_id}/operator' as const,
77
77
  path: { graph_id: graphId },
78
78
  body: {
79
79
  message: request.message,
@@ -85,14 +85,14 @@ export class AgentClient {
85
85
  },
86
86
  }
87
87
 
88
- const response = await autoSelectAgent(data)
88
+ const response = await autoSelectOperator(data)
89
89
  const responseData = response.data as any
90
90
 
91
91
  // Check if this is an immediate response (sync execution)
92
- if (responseData?.content !== undefined && responseData?.agent_used) {
92
+ if (responseData?.content !== undefined && responseData?.operator_used) {
93
93
  return {
94
94
  content: responseData.content,
95
- agent_used: responseData.agent_used,
95
+ operator_used: responseData.operator_used,
96
96
  mode_used: responseData.mode_used,
97
97
  metadata: responseData.metadata,
98
98
  tokens_used: responseData.tokens_used,
@@ -104,33 +104,33 @@ export class AgentClient {
104
104
 
105
105
  // Check if this is a queued response (async background task execution)
106
106
  if (responseData?.operation_id) {
107
- const queuedResponse = responseData as QueuedAgentResponse
107
+ const queuedResponse = responseData as QueuedOperatorResponse
108
108
 
109
109
  // If user doesn't want to wait, throw with queue info
110
110
  if (options.maxWait === 0) {
111
- throw new QueuedAgentError(queuedResponse)
111
+ throw new QueuedOperatorError(queuedResponse)
112
112
  }
113
113
 
114
114
  // Use SSE to monitor the operation
115
- return this.waitForAgentCompletion(queuedResponse.operation_id, options)
115
+ return this.waitForOperatorCompletion(queuedResponse.operation_id, options)
116
116
  }
117
117
 
118
118
  // Unexpected response format
119
- throw new Error('Unexpected response format from agent endpoint')
119
+ throw new Error('Unexpected response format from operator endpoint')
120
120
  }
121
121
 
122
122
  /**
123
- * Execute specific agent type
123
+ * Execute specific operator type
124
124
  */
125
- async executeAgent(
125
+ async executeOperator(
126
126
  graphId: string,
127
- agentType: string,
128
- request: AgentQueryRequest,
129
- options: AgentOptions = {}
130
- ): Promise<AgentResult> {
131
- const data: ExecuteSpecificAgentData = {
132
- url: '/v1/graphs/{graph_id}/agent/{agent_type}' as const,
133
- path: { graph_id: graphId, agent_type: agentType },
127
+ operatorType: string,
128
+ request: OperatorQueryRequest,
129
+ options: OperatorOptions = {}
130
+ ): Promise<OperatorResult> {
131
+ const data: ExecuteSpecificOperatorData = {
132
+ url: '/v1/graphs/{graph_id}/operator/{operator_type}' as const,
133
+ path: { graph_id: graphId, operator_type: operatorType },
134
134
  body: {
135
135
  message: request.message,
136
136
  history: request.history,
@@ -141,14 +141,14 @@ export class AgentClient {
141
141
  },
142
142
  }
143
143
 
144
- const response = await executeSpecificAgent(data)
144
+ const response = await executeSpecificOperator(data)
145
145
  const responseData = response.data as any
146
146
 
147
147
  // Check if this is an immediate response (sync execution)
148
- if (responseData?.content !== undefined && responseData?.agent_used) {
148
+ if (responseData?.content !== undefined && responseData?.operator_used) {
149
149
  return {
150
150
  content: responseData.content,
151
- agent_used: responseData.agent_used,
151
+ operator_used: responseData.operator_used,
152
152
  mode_used: responseData.mode_used,
153
153
  metadata: responseData.metadata,
154
154
  tokens_used: responseData.tokens_used,
@@ -160,32 +160,32 @@ export class AgentClient {
160
160
 
161
161
  // Check if this is a queued response (async background task execution)
162
162
  if (responseData?.operation_id) {
163
- const queuedResponse = responseData as QueuedAgentResponse
163
+ const queuedResponse = responseData as QueuedOperatorResponse
164
164
 
165
165
  // If user doesn't want to wait, throw with queue info
166
166
  if (options.maxWait === 0) {
167
- throw new QueuedAgentError(queuedResponse)
167
+ throw new QueuedOperatorError(queuedResponse)
168
168
  }
169
169
 
170
170
  // Use SSE to monitor the operation
171
- return this.waitForAgentCompletion(queuedResponse.operation_id, options)
171
+ return this.waitForOperatorCompletion(queuedResponse.operation_id, options)
172
172
  }
173
173
 
174
174
  // Unexpected response format
175
- throw new Error('Unexpected response format from agent endpoint')
175
+ throw new Error('Unexpected response format from operator endpoint')
176
176
  }
177
177
 
178
- private async waitForAgentCompletion(
178
+ private async waitForOperatorCompletion(
179
179
  operationId: string,
180
- options: AgentOptions
181
- ): Promise<AgentResult> {
180
+ options: OperatorOptions
181
+ ): Promise<OperatorResult> {
182
182
  return new Promise((resolve, reject) => {
183
183
  const sseClient = new SSEClient(this.config)
184
184
 
185
185
  sseClient
186
186
  .connect(operationId)
187
187
  .then(() => {
188
- let result: AgentResult | null = null
188
+ let result: OperatorResult | null = null
189
189
 
190
190
  // Listen for progress events
191
191
  sseClient.on(EventType.OPERATION_PROGRESS, (data) => {
@@ -193,11 +193,11 @@ export class AgentClient {
193
193
  })
194
194
 
195
195
  // Listen for agent-specific events
196
- sseClient.on('agent_started' as EventType, (data) => {
197
- options.onProgress?.(`Agent ${data.agent_type} started`, 0)
196
+ sseClient.on('operator_started' as EventType, (data) => {
197
+ options.onProgress?.(`Operator ${data.operator_type} started`, 0)
198
198
  })
199
199
 
200
- sseClient.on('agent_initialized' as EventType, (data) => {
200
+ sseClient.on('operator_initialized' as EventType, (data) => {
201
201
  options.onProgress?.(`${data.agent_name} initialized`, 10)
202
202
  })
203
203
 
@@ -205,10 +205,10 @@ export class AgentClient {
205
205
  options.onProgress?.(data.message, data.percentage)
206
206
  })
207
207
 
208
- sseClient.on('agent_completed' as EventType, (data) => {
208
+ sseClient.on('operator_completed' as EventType, (data) => {
209
209
  result = {
210
210
  content: data.content,
211
- agent_used: data.agent_used,
211
+ operator_used: data.operator_used,
212
212
  mode_used: data.mode_used,
213
213
  metadata: data.metadata,
214
214
  tokens_used: data.tokens_used,
@@ -223,16 +223,16 @@ export class AgentClient {
223
223
  // Fallback to generic completion event
224
224
  sseClient.on(EventType.OPERATION_COMPLETED, (data) => {
225
225
  if (!result) {
226
- const agentResult = data.result || data
226
+ const operatorResult = data.result || data
227
227
  result = {
228
- content: agentResult.content || '',
229
- agent_used: agentResult.agent_used || 'unknown',
230
- mode_used: agentResult.mode_used || 'standard',
231
- metadata: agentResult.metadata,
232
- tokens_used: agentResult.tokens_used,
233
- confidence_score: agentResult.confidence_score,
234
- execution_time: agentResult.execution_time,
235
- timestamp: agentResult.timestamp || new Date().toISOString(),
228
+ content: operatorResult.content || '',
229
+ operator_used: operatorResult.operator_used || 'unknown',
230
+ mode_used: operatorResult.mode_used || 'standard',
231
+ metadata: operatorResult.metadata,
232
+ tokens_used: operatorResult.tokens_used,
233
+ confidence_score: operatorResult.confidence_score,
234
+ execution_time: operatorResult.execution_time,
235
+ timestamp: operatorResult.timestamp || new Date().toISOString(),
236
236
  }
237
237
  sseClient.close()
238
238
  resolve(result)
@@ -266,7 +266,7 @@ export class AgentClient {
266
266
  graphId: string,
267
267
  message: string,
268
268
  context?: Record<string, any>
269
- ): Promise<AgentResult> {
269
+ ): Promise<OperatorResult> {
270
270
  return this.executeQuery(graphId, { message, context }, { mode: 'auto' })
271
271
  }
272
272
 
@@ -276,9 +276,9 @@ export class AgentClient {
276
276
  async analyzeFinancials(
277
277
  graphId: string,
278
278
  message: string,
279
- options: AgentOptions = {}
280
- ): Promise<AgentResult> {
281
- return this.executeAgent(graphId, 'financial', { message }, options)
279
+ options: OperatorOptions = {}
280
+ ): Promise<OperatorResult> {
281
+ return this.executeOperator(graphId, 'financial', { message }, options)
282
282
  }
283
283
 
284
284
  /**
@@ -287,16 +287,20 @@ export class AgentClient {
287
287
  async research(
288
288
  graphId: string,
289
289
  message: string,
290
- options: AgentOptions = {}
291
- ): Promise<AgentResult> {
292
- return this.executeAgent(graphId, 'research', { message }, options)
290
+ options: OperatorOptions = {}
291
+ ): Promise<OperatorResult> {
292
+ return this.executeOperator(graphId, 'research', { message }, options)
293
293
  }
294
294
 
295
295
  /**
296
296
  * Execute RAG agent for fast retrieval
297
297
  */
298
- async rag(graphId: string, message: string, options: AgentOptions = {}): Promise<AgentResult> {
299
- return this.executeAgent(graphId, 'rag', { message }, options)
298
+ async rag(
299
+ graphId: string,
300
+ message: string,
301
+ options: OperatorOptions = {}
302
+ ): Promise<OperatorResult> {
303
+ return this.executeOperator(graphId, 'rag', { message }, options)
300
304
  }
301
305
 
302
306
  /**
@@ -313,9 +317,9 @@ export class AgentClient {
313
317
  /**
314
318
  * Error thrown when agent execution is queued and maxWait is 0
315
319
  */
316
- export class QueuedAgentError extends Error {
317
- constructor(public queueInfo: QueuedAgentResponse) {
318
- super('Agent execution was queued')
319
- this.name = 'QueuedAgentError'
320
+ export class QueuedOperatorError extends Error {
321
+ constructor(public queueInfo: QueuedOperatorResponse) {
322
+ super('Operator execution was queued')
323
+ this.name = 'QueuedOperatorError'
320
324
  }
321
325
  }
@@ -1453,6 +1453,9 @@ export type QueryAccountRollupsArgs = {
1453
1453
  mappingId?: InputMaybe<Scalars['String']['input']>;
1454
1454
  startDate?: InputMaybe<Scalars['Date']['input']>;
1455
1455
  };
1456
+ export type QueryAccountTreeArgs = {
1457
+ includeInactive?: Scalars['Boolean']['input'];
1458
+ };
1456
1459
  export type QueryAccountsArgs = {
1457
1460
  classification?: InputMaybe<Scalars['String']['input']>;
1458
1461
  isActive?: InputMaybe<Scalars['Boolean']['input']>;
@@ -1502,6 +1502,10 @@ export type QueryAccountRollupsArgs = {
1502
1502
  startDate?: InputMaybe<Scalars['Date']['input']>
1503
1503
  }
1504
1504
 
1505
+ export type QueryAccountTreeArgs = {
1506
+ includeInactive?: Scalars['Boolean']['input']
1507
+ }
1508
+
1505
1509
  export type QueryAccountsArgs = {
1506
1510
  classification?: InputMaybe<Scalars['String']['input']>
1507
1511
  isActive?: InputMaybe<Scalars['Boolean']['input']>