@exulu/backend 1.45.1 → 1.46.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.cts CHANGED
@@ -2,9 +2,8 @@ import * as _opentelemetry_sdk_node from '@opentelemetry/sdk-node';
2
2
  import * as bullmq from 'bullmq';
3
3
  import { Queue } from 'bullmq';
4
4
  import { RedisClientType } from 'redis';
5
- import * as ai from 'ai';
6
- import { UIMessage, LanguageModel, Tool } from 'ai';
7
5
  import { z } from 'zod';
6
+ import { UIMessage, LanguageModel, Tool, streamText } from 'ai';
8
7
  import { Express, Request } from 'express';
9
8
  import { transport } from 'winston';
10
9
  import { Knex } from 'knex';
@@ -92,14 +91,16 @@ declare class ExuluApp {
92
91
  private _config?;
93
92
  private _evals;
94
93
  private _queues;
94
+ private _rerankers;
95
95
  private _contexts?;
96
96
  private _tools;
97
97
  private _expressApp;
98
98
  constructor();
99
- create: ({ contexts, agents, config, tools, evals, }: {
99
+ create: ({ contexts, agents, config, tools, evals, rerankers, }: {
100
100
  contexts?: Record<string, ExuluContext>;
101
101
  config: ExuluConfig;
102
102
  agents?: ExuluAgent[];
103
+ rerankers?: ExuluReranker[];
103
104
  evals?: ExuluEval[];
104
105
  tools?: ExuluTool[];
105
106
  }) => Promise<ExuluApp>;
@@ -167,6 +168,79 @@ declare const VectorMethodEnum: {
167
168
  };
168
169
  type VectorMethod = (typeof VectorMethodEnum)[keyof typeof VectorMethodEnum];
169
170
 
171
+ /**
172
+ * Base operator type with comparison operations
173
+ */
174
+ type BaseOperator<T> = {
175
+ /** Equals */
176
+ eq?: T;
177
+ /** Not equals */
178
+ ne?: T;
179
+ /** In array */
180
+ in?: T[];
181
+ /** AND conditions */
182
+ and?: BaseOperator<T>[];
183
+ /** OR conditions */
184
+ or?: BaseOperator<T>[];
185
+ };
186
+ /**
187
+ * String field filter operators
188
+ */
189
+ type StringOperator = BaseOperator<string> & {
190
+ /** Contains (case-insensitive substring match) */
191
+ contains?: string;
192
+ };
193
+ /**
194
+ * Number field filter operators
195
+ */
196
+ type NumberOperator = BaseOperator<number> & {
197
+ /** Less than or equal to */
198
+ lte?: number;
199
+ /** Greater than or equal to */
200
+ gte?: number;
201
+ };
202
+ /**
203
+ * Date field filter operators
204
+ */
205
+ type DateOperator = BaseOperator<Date | string> & {
206
+ /** Less than or equal to */
207
+ lte?: Date | string;
208
+ /** Greater than or equal to */
209
+ gte?: Date | string;
210
+ };
211
+ /**
212
+ * Boolean field filter operators
213
+ */
214
+ type BooleanOperator = BaseOperator<boolean>;
215
+ /**
216
+ * JSON field filter operators
217
+ */
218
+ type JsonOperator = BaseOperator<any> & {
219
+ /** Contains (PostgreSQL @> operator for JSON containment) */
220
+ contains?: any;
221
+ };
222
+ /**
223
+ * Filter operator type based on field type
224
+ */
225
+ type FilterOperator = BaseOperator<any> | StringOperator | NumberOperator | DateOperator | BooleanOperator | JsonOperator;
226
+ /**
227
+ * Single filter object - a record of field names to their filter operators
228
+ */
229
+ type Filter = Record<string, FilterOperator>;
230
+ /**
231
+ * Type for the filters parameter used throughout the codebase
232
+ * Filters is an array of filter objects, where each object contains field names mapped to their operators
233
+ *
234
+ * @example
235
+ * ```typescript
236
+ * const filters: Filters = [
237
+ * { name: { contains: "test" } },
238
+ * { age: { gte: 18, lte: 65 } },
239
+ * { status: { in: ["active", "pending"] } }
240
+ * ];
241
+ * ```
242
+ */
243
+ type SearchFilters = Filter[];
170
244
  type VectorSearchChunkResult = {
171
245
  chunk_content: string;
172
246
  chunk_index: number;
@@ -194,6 +268,8 @@ interface Agent {
194
268
  modelName?: string;
195
269
  providerName?: string;
196
270
  backend: string;
271
+ memory?: string;
272
+ welcomemessage?: string;
197
273
  type: "agent";
198
274
  name: string;
199
275
  image?: string;
@@ -224,6 +300,7 @@ interface Agent {
224
300
  config: {
225
301
  name: string;
226
302
  variable: string;
303
+ type: "boolean" | "string" | "number" | "variable";
227
304
  }[];
228
305
  name: string;
229
306
  description: string;
@@ -302,7 +379,7 @@ type ExuluAgentConfig = {
302
379
  };
303
380
  };
304
381
  type imageTypes = '.png' | '.jpg' | '.jpeg' | '.gif' | '.webp';
305
- type fileTypes = '.pdf' | '.docx' | '.xlsx' | '.xls' | '.csv' | '.pptx' | '.ppt' | '.txt' | '.md' | '.json';
382
+ type fileTypes = '.pdf' | '.docx' | '.doc' | '.xlsx' | '.xls' | '.csv' | '.pptx' | '.ppt' | '.txt' | '.md' | '.json' | '.srt' | '.html';
306
383
  type audioTypes = '.mp3' | '.wav' | '.m4a' | '.mp4' | '.mpeg';
307
384
  type videoTypes = '.mp4' | '.m4a' | '.mp3' | '.mpeg' | '.wav';
308
385
  type allFileTypes = imageTypes | fileTypes | audioTypes | videoTypes;
@@ -332,11 +409,31 @@ interface ExuluAgentToolConfig {
332
409
  type: string;
333
410
  config: {
334
411
  name: string;
335
- variable: string;
412
+ variable: string | boolean | number;
413
+ type: "boolean" | "string" | "number" | "variable";
336
414
  value?: any;
337
- default?: string;
415
+ default?: string | boolean | number;
338
416
  }[];
339
417
  }
418
+ declare class ExuluReranker {
419
+ id: string;
420
+ name: string;
421
+ description: string;
422
+ execute: (params: {
423
+ query: string;
424
+ chunks: VectorSearchChunkResult[];
425
+ }) => Promise<VectorSearchChunkResult[]>;
426
+ constructor({ id, name, description, execute }: {
427
+ id: string;
428
+ name: string;
429
+ description: string;
430
+ execute: (params: {
431
+ query: string;
432
+ chunks: VectorSearchChunkResult[];
433
+ }) => Promise<VectorSearchChunkResult[]>;
434
+ });
435
+ run(query: string, chunks: VectorSearchChunkResult[]): Promise<VectorSearchChunkResult[]>;
436
+ }
340
437
  type ExuluQueueConfig = {
341
438
  queue: Queue;
342
439
  ratelimit: number;
@@ -427,12 +524,13 @@ declare class ExuluAgent {
427
524
  constructor({ id, name, description, config, rateLimit, capabilities, type, maxContextLength, provider, queue, authenticationInformation, workflows }: ExuluAgentParams);
428
525
  get providerName(): string;
429
526
  get modelName(): string;
430
- tool: (instance: string, agents: ExuluAgent[]) => Promise<ExuluTool | null>;
431
- generateSync: ({ prompt, req, user, session, inputMessages, currentTools, allExuluTools, statistics, toolConfigs, providerapikey, contexts, exuluConfig, outputSchema, instructions }: {
527
+ tool: (instance: string, agents: ExuluAgent[], contexts: ExuluContext[], rerankers: ExuluReranker[]) => Promise<ExuluTool | null>;
528
+ generateSync: ({ prompt, req, user, session, inputMessages, currentTools, allExuluTools, statistics, toolConfigs, providerapikey, contexts, rerankers, exuluConfig, outputSchema, agentInstance, instructions }: {
432
529
  prompt?: string;
433
530
  user?: User;
434
531
  req?: Request;
435
532
  session?: string;
533
+ agentInstance?: Agent;
436
534
  inputMessages?: UIMessage[];
437
535
  currentTools?: ExuluTool[];
438
536
  allExuluTools?: ExuluTool[];
@@ -440,6 +538,7 @@ declare class ExuluAgent {
440
538
  toolConfigs?: ExuluAgentToolConfig[];
441
539
  providerapikey?: string | undefined;
442
540
  contexts?: ExuluContext[] | undefined;
541
+ rerankers?: ExuluReranker[] | undefined;
443
542
  exuluConfig?: ExuluConfig;
444
543
  instructions?: string;
445
544
  outputSchema?: z.ZodType;
@@ -452,23 +551,26 @@ declare class ExuluAgent {
452
551
  * - Image files -> image parts (which ARE supported by Responses API)
453
552
  */
454
553
  private processFilePartsInMessages;
455
- generateStream: ({ user, session, message, previousMessages, currentTools, allExuluTools, toolConfigs, providerapikey, contexts, exuluConfig, instructions, req, }: {
554
+ generateStream: ({ user, session, agentInstance, message, previousMessages, currentTools, approvedTools, allExuluTools, toolConfigs, providerapikey, contexts, rerankers, exuluConfig, instructions, req, }: {
456
555
  user?: User;
457
556
  session?: string;
557
+ agentInstance?: Agent;
458
558
  message?: UIMessage;
459
559
  previousMessages?: UIMessage[];
460
560
  currentTools?: ExuluTool[];
561
+ approvedTools?: string[];
461
562
  allExuluTools?: ExuluTool[];
462
563
  toolConfigs?: ExuluAgentToolConfig[];
463
564
  providerapikey?: string | undefined;
464
565
  contexts?: ExuluContext[] | undefined;
566
+ rerankers?: ExuluReranker[] | undefined;
465
567
  exuluConfig?: ExuluConfig;
466
568
  instructions?: string;
467
569
  req?: Request;
468
570
  }) => Promise<{
469
- stream: ai.StreamTextResult<Record<string, Tool>, never>;
470
- originalMessages: UIMessage<unknown, ai.UIDataTypes, ai.UITools>[];
471
- previousMessages: UIMessage<unknown, ai.UIDataTypes, ai.UITools>[];
571
+ stream: ReturnType<typeof streamText>;
572
+ originalMessages: UIMessage[];
573
+ previousMessages: UIMessage[];
472
574
  }>;
473
575
  }
474
576
  type VectorOperationResponse = Promise<{
@@ -540,12 +642,13 @@ declare class ExuluTool {
540
642
  description: string;
541
643
  category: string;
542
644
  inputSchema?: z.ZodType;
543
- type: "context" | "function" | "agent";
645
+ type: "context" | "function" | "agent" | "web_search";
544
646
  tool: Tool;
545
647
  config: {
546
648
  name: string;
547
649
  description: string;
548
- default?: string;
650
+ type: "boolean" | "string" | "number" | "variable";
651
+ default?: string | boolean | number | "variable";
549
652
  }[];
550
653
  constructor({ id, name, description, category, inputSchema, type, execute, config }: {
551
654
  id: string;
@@ -553,11 +656,12 @@ declare class ExuluTool {
553
656
  description: string;
554
657
  category?: string;
555
658
  inputSchema?: z.ZodType;
556
- type: "context" | "function" | "agent";
659
+ type: "context" | "function" | "agent" | "web_search";
557
660
  config: {
558
661
  name: string;
559
662
  description: string;
560
- default?: string;
663
+ type: "boolean" | "string" | "number" | "variable";
664
+ default?: string | boolean | number | "variable";
561
665
  }[];
562
666
  execute: (inputs: any) => Promise<{
563
667
  result?: string;
@@ -569,12 +673,13 @@ declare class ExuluTool {
569
673
  items?: Item[];
570
674
  }>;
571
675
  });
572
- execute: ({ agent, config, user, inputs, project }: {
676
+ execute: ({ agent, config, user, inputs, project, items }: {
573
677
  agent: string;
574
678
  config: ExuluConfig;
575
679
  user?: User;
576
680
  inputs: any;
577
681
  project?: string;
682
+ items?: string[];
578
683
  }) => Promise<any>;
579
684
  }
580
685
  type ExuluContextProcessor = {
@@ -608,6 +713,7 @@ type ExuluContextProcessor = {
608
713
  type ExuluContextFieldDefinition = {
609
714
  name: string;
610
715
  type: ExuluFieldTypes;
716
+ editable?: boolean;
611
717
  unique?: boolean;
612
718
  required?: boolean;
613
719
  default?: any;
@@ -733,8 +839,10 @@ declare class ExuluContext {
733
839
  job?: string;
734
840
  }>;
735
841
  search: (options: {
736
- query: string;
737
- filters: any[];
842
+ query?: string;
843
+ keywords?: string[];
844
+ itemFilters: SearchFilters;
845
+ chunkFilters: SearchFilters;
738
846
  user?: User;
739
847
  role?: string;
740
848
  method: VectorMethod;
@@ -752,8 +860,10 @@ declare class ExuluContext {
752
860
  after?: number;
753
861
  };
754
862
  }) => Promise<{
755
- filters: any[];
756
- query: string;
863
+ itemFilters: SearchFilters;
864
+ chunkFilters: SearchFilters;
865
+ query?: string;
866
+ keywords?: string[];
757
867
  method: VectorMethod;
758
868
  context: {
759
869
  name: string;
@@ -1774,8 +1884,14 @@ declare const ExuluDefaultAgents: {
1774
1884
  sonnet4: ExuluAgent;
1775
1885
  sonnet45: ExuluAgent;
1776
1886
  };
1887
+ cerebras: {
1888
+ gptOss120b: ExuluAgent;
1889
+ llama38b: ExuluAgent;
1890
+ llama3370b: ExuluAgent;
1891
+ };
1777
1892
  google: {
1778
1893
  vertexGemini25Flash: ExuluAgent;
1894
+ vertexGemini25Pro: ExuluAgent;
1779
1895
  vertexGemini3Pro: ExuluAgent;
1780
1896
  };
1781
1897
  openai: {
@@ -1838,4 +1954,4 @@ declare const ExuluChunkers: {
1838
1954
  };
1839
1955
  };
1840
1956
 
1841
- export { type JOB_STATUS as EXULU_JOB_STATUS, JOB_STATUS_ENUM as EXULU_JOB_STATUS_ENUM, type STATISTICS_TYPE as EXULU_STATISTICS_TYPE, STATISTICS_TYPE_ENUM as EXULU_STATISTICS_TYPE_ENUM, ExuluAgent, ExuluApp, authentication as ExuluAuthentication, ExuluChunkers, ExuluContext, ExuluDefaultAgents, ExuluEmbedder, ExuluEval, type ExuluEvalMetadata, type ExuluEvalTokenMetadata, type Item as ExuluItem, ExuluJobs, ExuluOtel, type ExuluQueueConfig, queues as ExuluQueues, ExuluStorage, ExuluTool, ExuluUtils, ExuluVariables, db, logMetadata };
1957
+ export { type JOB_STATUS as EXULU_JOB_STATUS, JOB_STATUS_ENUM as EXULU_JOB_STATUS_ENUM, type STATISTICS_TYPE as EXULU_STATISTICS_TYPE, STATISTICS_TYPE_ENUM as EXULU_STATISTICS_TYPE_ENUM, ExuluAgent, ExuluApp, authentication as ExuluAuthentication, ExuluChunkers, ExuluContext, ExuluDefaultAgents, ExuluEmbedder, ExuluEval, type ExuluEvalMetadata, type ExuluEvalTokenMetadata, type Item as ExuluItem, ExuluJobs, ExuluOtel, type ExuluQueueConfig, queues as ExuluQueues, ExuluReranker, ExuluStorage, ExuluTool, ExuluUtils, ExuluVariables, db, logMetadata };
package/dist/index.d.ts CHANGED
@@ -2,9 +2,8 @@ import * as _opentelemetry_sdk_node from '@opentelemetry/sdk-node';
2
2
  import * as bullmq from 'bullmq';
3
3
  import { Queue } from 'bullmq';
4
4
  import { RedisClientType } from 'redis';
5
- import * as ai from 'ai';
6
- import { UIMessage, LanguageModel, Tool } from 'ai';
7
5
  import { z } from 'zod';
6
+ import { UIMessage, LanguageModel, Tool, streamText } from 'ai';
8
7
  import { Express, Request } from 'express';
9
8
  import { transport } from 'winston';
10
9
  import { Knex } from 'knex';
@@ -92,14 +91,16 @@ declare class ExuluApp {
92
91
  private _config?;
93
92
  private _evals;
94
93
  private _queues;
94
+ private _rerankers;
95
95
  private _contexts?;
96
96
  private _tools;
97
97
  private _expressApp;
98
98
  constructor();
99
- create: ({ contexts, agents, config, tools, evals, }: {
99
+ create: ({ contexts, agents, config, tools, evals, rerankers, }: {
100
100
  contexts?: Record<string, ExuluContext>;
101
101
  config: ExuluConfig;
102
102
  agents?: ExuluAgent[];
103
+ rerankers?: ExuluReranker[];
103
104
  evals?: ExuluEval[];
104
105
  tools?: ExuluTool[];
105
106
  }) => Promise<ExuluApp>;
@@ -167,6 +168,79 @@ declare const VectorMethodEnum: {
167
168
  };
168
169
  type VectorMethod = (typeof VectorMethodEnum)[keyof typeof VectorMethodEnum];
169
170
 
171
+ /**
172
+ * Base operator type with comparison operations
173
+ */
174
+ type BaseOperator<T> = {
175
+ /** Equals */
176
+ eq?: T;
177
+ /** Not equals */
178
+ ne?: T;
179
+ /** In array */
180
+ in?: T[];
181
+ /** AND conditions */
182
+ and?: BaseOperator<T>[];
183
+ /** OR conditions */
184
+ or?: BaseOperator<T>[];
185
+ };
186
+ /**
187
+ * String field filter operators
188
+ */
189
+ type StringOperator = BaseOperator<string> & {
190
+ /** Contains (case-insensitive substring match) */
191
+ contains?: string;
192
+ };
193
+ /**
194
+ * Number field filter operators
195
+ */
196
+ type NumberOperator = BaseOperator<number> & {
197
+ /** Less than or equal to */
198
+ lte?: number;
199
+ /** Greater than or equal to */
200
+ gte?: number;
201
+ };
202
+ /**
203
+ * Date field filter operators
204
+ */
205
+ type DateOperator = BaseOperator<Date | string> & {
206
+ /** Less than or equal to */
207
+ lte?: Date | string;
208
+ /** Greater than or equal to */
209
+ gte?: Date | string;
210
+ };
211
+ /**
212
+ * Boolean field filter operators
213
+ */
214
+ type BooleanOperator = BaseOperator<boolean>;
215
+ /**
216
+ * JSON field filter operators
217
+ */
218
+ type JsonOperator = BaseOperator<any> & {
219
+ /** Contains (PostgreSQL @> operator for JSON containment) */
220
+ contains?: any;
221
+ };
222
+ /**
223
+ * Filter operator type based on field type
224
+ */
225
+ type FilterOperator = BaseOperator<any> | StringOperator | NumberOperator | DateOperator | BooleanOperator | JsonOperator;
226
+ /**
227
+ * Single filter object - a record of field names to their filter operators
228
+ */
229
+ type Filter = Record<string, FilterOperator>;
230
+ /**
231
+ * Type for the filters parameter used throughout the codebase
232
+ * Filters is an array of filter objects, where each object contains field names mapped to their operators
233
+ *
234
+ * @example
235
+ * ```typescript
236
+ * const filters: Filters = [
237
+ * { name: { contains: "test" } },
238
+ * { age: { gte: 18, lte: 65 } },
239
+ * { status: { in: ["active", "pending"] } }
240
+ * ];
241
+ * ```
242
+ */
243
+ type SearchFilters = Filter[];
170
244
  type VectorSearchChunkResult = {
171
245
  chunk_content: string;
172
246
  chunk_index: number;
@@ -194,6 +268,8 @@ interface Agent {
194
268
  modelName?: string;
195
269
  providerName?: string;
196
270
  backend: string;
271
+ memory?: string;
272
+ welcomemessage?: string;
197
273
  type: "agent";
198
274
  name: string;
199
275
  image?: string;
@@ -224,6 +300,7 @@ interface Agent {
224
300
  config: {
225
301
  name: string;
226
302
  variable: string;
303
+ type: "boolean" | "string" | "number" | "variable";
227
304
  }[];
228
305
  name: string;
229
306
  description: string;
@@ -302,7 +379,7 @@ type ExuluAgentConfig = {
302
379
  };
303
380
  };
304
381
  type imageTypes = '.png' | '.jpg' | '.jpeg' | '.gif' | '.webp';
305
- type fileTypes = '.pdf' | '.docx' | '.xlsx' | '.xls' | '.csv' | '.pptx' | '.ppt' | '.txt' | '.md' | '.json';
382
+ type fileTypes = '.pdf' | '.docx' | '.doc' | '.xlsx' | '.xls' | '.csv' | '.pptx' | '.ppt' | '.txt' | '.md' | '.json' | '.srt' | '.html';
306
383
  type audioTypes = '.mp3' | '.wav' | '.m4a' | '.mp4' | '.mpeg';
307
384
  type videoTypes = '.mp4' | '.m4a' | '.mp3' | '.mpeg' | '.wav';
308
385
  type allFileTypes = imageTypes | fileTypes | audioTypes | videoTypes;
@@ -332,11 +409,31 @@ interface ExuluAgentToolConfig {
332
409
  type: string;
333
410
  config: {
334
411
  name: string;
335
- variable: string;
412
+ variable: string | boolean | number;
413
+ type: "boolean" | "string" | "number" | "variable";
336
414
  value?: any;
337
- default?: string;
415
+ default?: string | boolean | number;
338
416
  }[];
339
417
  }
418
+ declare class ExuluReranker {
419
+ id: string;
420
+ name: string;
421
+ description: string;
422
+ execute: (params: {
423
+ query: string;
424
+ chunks: VectorSearchChunkResult[];
425
+ }) => Promise<VectorSearchChunkResult[]>;
426
+ constructor({ id, name, description, execute }: {
427
+ id: string;
428
+ name: string;
429
+ description: string;
430
+ execute: (params: {
431
+ query: string;
432
+ chunks: VectorSearchChunkResult[];
433
+ }) => Promise<VectorSearchChunkResult[]>;
434
+ });
435
+ run(query: string, chunks: VectorSearchChunkResult[]): Promise<VectorSearchChunkResult[]>;
436
+ }
340
437
  type ExuluQueueConfig = {
341
438
  queue: Queue;
342
439
  ratelimit: number;
@@ -427,12 +524,13 @@ declare class ExuluAgent {
427
524
  constructor({ id, name, description, config, rateLimit, capabilities, type, maxContextLength, provider, queue, authenticationInformation, workflows }: ExuluAgentParams);
428
525
  get providerName(): string;
429
526
  get modelName(): string;
430
- tool: (instance: string, agents: ExuluAgent[]) => Promise<ExuluTool | null>;
431
- generateSync: ({ prompt, req, user, session, inputMessages, currentTools, allExuluTools, statistics, toolConfigs, providerapikey, contexts, exuluConfig, outputSchema, instructions }: {
527
+ tool: (instance: string, agents: ExuluAgent[], contexts: ExuluContext[], rerankers: ExuluReranker[]) => Promise<ExuluTool | null>;
528
+ generateSync: ({ prompt, req, user, session, inputMessages, currentTools, allExuluTools, statistics, toolConfigs, providerapikey, contexts, rerankers, exuluConfig, outputSchema, agentInstance, instructions }: {
432
529
  prompt?: string;
433
530
  user?: User;
434
531
  req?: Request;
435
532
  session?: string;
533
+ agentInstance?: Agent;
436
534
  inputMessages?: UIMessage[];
437
535
  currentTools?: ExuluTool[];
438
536
  allExuluTools?: ExuluTool[];
@@ -440,6 +538,7 @@ declare class ExuluAgent {
440
538
  toolConfigs?: ExuluAgentToolConfig[];
441
539
  providerapikey?: string | undefined;
442
540
  contexts?: ExuluContext[] | undefined;
541
+ rerankers?: ExuluReranker[] | undefined;
443
542
  exuluConfig?: ExuluConfig;
444
543
  instructions?: string;
445
544
  outputSchema?: z.ZodType;
@@ -452,23 +551,26 @@ declare class ExuluAgent {
452
551
  * - Image files -> image parts (which ARE supported by Responses API)
453
552
  */
454
553
  private processFilePartsInMessages;
455
- generateStream: ({ user, session, message, previousMessages, currentTools, allExuluTools, toolConfigs, providerapikey, contexts, exuluConfig, instructions, req, }: {
554
+ generateStream: ({ user, session, agentInstance, message, previousMessages, currentTools, approvedTools, allExuluTools, toolConfigs, providerapikey, contexts, rerankers, exuluConfig, instructions, req, }: {
456
555
  user?: User;
457
556
  session?: string;
557
+ agentInstance?: Agent;
458
558
  message?: UIMessage;
459
559
  previousMessages?: UIMessage[];
460
560
  currentTools?: ExuluTool[];
561
+ approvedTools?: string[];
461
562
  allExuluTools?: ExuluTool[];
462
563
  toolConfigs?: ExuluAgentToolConfig[];
463
564
  providerapikey?: string | undefined;
464
565
  contexts?: ExuluContext[] | undefined;
566
+ rerankers?: ExuluReranker[] | undefined;
465
567
  exuluConfig?: ExuluConfig;
466
568
  instructions?: string;
467
569
  req?: Request;
468
570
  }) => Promise<{
469
- stream: ai.StreamTextResult<Record<string, Tool>, never>;
470
- originalMessages: UIMessage<unknown, ai.UIDataTypes, ai.UITools>[];
471
- previousMessages: UIMessage<unknown, ai.UIDataTypes, ai.UITools>[];
571
+ stream: ReturnType<typeof streamText>;
572
+ originalMessages: UIMessage[];
573
+ previousMessages: UIMessage[];
472
574
  }>;
473
575
  }
474
576
  type VectorOperationResponse = Promise<{
@@ -540,12 +642,13 @@ declare class ExuluTool {
540
642
  description: string;
541
643
  category: string;
542
644
  inputSchema?: z.ZodType;
543
- type: "context" | "function" | "agent";
645
+ type: "context" | "function" | "agent" | "web_search";
544
646
  tool: Tool;
545
647
  config: {
546
648
  name: string;
547
649
  description: string;
548
- default?: string;
650
+ type: "boolean" | "string" | "number" | "variable";
651
+ default?: string | boolean | number | "variable";
549
652
  }[];
550
653
  constructor({ id, name, description, category, inputSchema, type, execute, config }: {
551
654
  id: string;
@@ -553,11 +656,12 @@ declare class ExuluTool {
553
656
  description: string;
554
657
  category?: string;
555
658
  inputSchema?: z.ZodType;
556
- type: "context" | "function" | "agent";
659
+ type: "context" | "function" | "agent" | "web_search";
557
660
  config: {
558
661
  name: string;
559
662
  description: string;
560
- default?: string;
663
+ type: "boolean" | "string" | "number" | "variable";
664
+ default?: string | boolean | number | "variable";
561
665
  }[];
562
666
  execute: (inputs: any) => Promise<{
563
667
  result?: string;
@@ -569,12 +673,13 @@ declare class ExuluTool {
569
673
  items?: Item[];
570
674
  }>;
571
675
  });
572
- execute: ({ agent, config, user, inputs, project }: {
676
+ execute: ({ agent, config, user, inputs, project, items }: {
573
677
  agent: string;
574
678
  config: ExuluConfig;
575
679
  user?: User;
576
680
  inputs: any;
577
681
  project?: string;
682
+ items?: string[];
578
683
  }) => Promise<any>;
579
684
  }
580
685
  type ExuluContextProcessor = {
@@ -608,6 +713,7 @@ type ExuluContextProcessor = {
608
713
  type ExuluContextFieldDefinition = {
609
714
  name: string;
610
715
  type: ExuluFieldTypes;
716
+ editable?: boolean;
611
717
  unique?: boolean;
612
718
  required?: boolean;
613
719
  default?: any;
@@ -733,8 +839,10 @@ declare class ExuluContext {
733
839
  job?: string;
734
840
  }>;
735
841
  search: (options: {
736
- query: string;
737
- filters: any[];
842
+ query?: string;
843
+ keywords?: string[];
844
+ itemFilters: SearchFilters;
845
+ chunkFilters: SearchFilters;
738
846
  user?: User;
739
847
  role?: string;
740
848
  method: VectorMethod;
@@ -752,8 +860,10 @@ declare class ExuluContext {
752
860
  after?: number;
753
861
  };
754
862
  }) => Promise<{
755
- filters: any[];
756
- query: string;
863
+ itemFilters: SearchFilters;
864
+ chunkFilters: SearchFilters;
865
+ query?: string;
866
+ keywords?: string[];
757
867
  method: VectorMethod;
758
868
  context: {
759
869
  name: string;
@@ -1774,8 +1884,14 @@ declare const ExuluDefaultAgents: {
1774
1884
  sonnet4: ExuluAgent;
1775
1885
  sonnet45: ExuluAgent;
1776
1886
  };
1887
+ cerebras: {
1888
+ gptOss120b: ExuluAgent;
1889
+ llama38b: ExuluAgent;
1890
+ llama3370b: ExuluAgent;
1891
+ };
1777
1892
  google: {
1778
1893
  vertexGemini25Flash: ExuluAgent;
1894
+ vertexGemini25Pro: ExuluAgent;
1779
1895
  vertexGemini3Pro: ExuluAgent;
1780
1896
  };
1781
1897
  openai: {
@@ -1838,4 +1954,4 @@ declare const ExuluChunkers: {
1838
1954
  };
1839
1955
  };
1840
1956
 
1841
- export { type JOB_STATUS as EXULU_JOB_STATUS, JOB_STATUS_ENUM as EXULU_JOB_STATUS_ENUM, type STATISTICS_TYPE as EXULU_STATISTICS_TYPE, STATISTICS_TYPE_ENUM as EXULU_STATISTICS_TYPE_ENUM, ExuluAgent, ExuluApp, authentication as ExuluAuthentication, ExuluChunkers, ExuluContext, ExuluDefaultAgents, ExuluEmbedder, ExuluEval, type ExuluEvalMetadata, type ExuluEvalTokenMetadata, type Item as ExuluItem, ExuluJobs, ExuluOtel, type ExuluQueueConfig, queues as ExuluQueues, ExuluStorage, ExuluTool, ExuluUtils, ExuluVariables, db, logMetadata };
1957
+ export { type JOB_STATUS as EXULU_JOB_STATUS, JOB_STATUS_ENUM as EXULU_JOB_STATUS_ENUM, type STATISTICS_TYPE as EXULU_STATISTICS_TYPE, STATISTICS_TYPE_ENUM as EXULU_STATISTICS_TYPE_ENUM, ExuluAgent, ExuluApp, authentication as ExuluAuthentication, ExuluChunkers, ExuluContext, ExuluDefaultAgents, ExuluEmbedder, ExuluEval, type ExuluEvalMetadata, type ExuluEvalTokenMetadata, type Item as ExuluItem, ExuluJobs, ExuluOtel, type ExuluQueueConfig, queues as ExuluQueues, ExuluReranker, ExuluStorage, ExuluTool, ExuluUtils, ExuluVariables, db, logMetadata };