@sinequa/assistant 3.6.2 → 3.7.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/chat/chat-message/chat-message.component.d.ts +4 -2
- package/chat/chat.component.d.ts +137 -18
- package/chat/chat.service.d.ts +23 -1
- package/chat/rest-chat.service.d.ts +1 -0
- package/chat/saved-chats/saved-chats.component.d.ts +2 -2
- package/chat/styles/assistant.scss +5 -0
- package/chat/types.d.ts +189 -3
- package/chat/websocket-chat.service.d.ts +6 -6
- package/esm2020/chat/chat-message/chat-message.component.mjs +9 -4
- package/esm2020/chat/chat-reference/chat-reference.component.mjs +3 -3
- package/esm2020/chat/chat.component.mjs +361 -62
- package/esm2020/chat/chat.service.mjs +49 -3
- package/esm2020/chat/debug-message/debug-message.component.mjs +3 -3
- package/esm2020/chat/instance-manager.service.mjs +2 -2
- package/esm2020/chat/rest-chat.service.mjs +8 -3
- package/esm2020/chat/saved-chats/saved-chats.component.mjs +16 -5
- package/esm2020/chat/token-progress-bar/token-progress-bar.component.mjs +3 -3
- package/esm2020/chat/types.mjs +18 -4
- package/esm2020/chat/websocket-chat.service.mjs +191 -99
- package/fesm2015/sinequa-assistant-chat.mjs +660 -182
- package/fesm2015/sinequa-assistant-chat.mjs.map +1 -1
- package/fesm2020/sinequa-assistant-chat.mjs +649 -179
- package/fesm2020/sinequa-assistant-chat.mjs.map +1 -1
- package/package.json +1 -1
package/chat/types.d.ts
CHANGED
|
@@ -29,6 +29,7 @@ export interface ChatMessage extends RawMessage {
|
|
|
29
29
|
$suggestedAction?: SuggestedAction[];
|
|
30
30
|
$debug?: DebugMessage[];
|
|
31
31
|
forcedWorkflow?: string;
|
|
32
|
+
forcedWorkflowProperties?: any;
|
|
32
33
|
query?: Query;
|
|
33
34
|
isUserInput?: boolean;
|
|
34
35
|
usageMetrics?: ChatUsageMetrics;
|
|
@@ -71,7 +72,7 @@ export interface ChatContextAttachment extends RawAttachment {
|
|
|
71
72
|
*/
|
|
72
73
|
export interface RawResponse {
|
|
73
74
|
history: RawMessage[];
|
|
74
|
-
executionTime: string;
|
|
75
|
+
executionTime: string | undefined;
|
|
75
76
|
}
|
|
76
77
|
/**
|
|
77
78
|
* Enriched response of the chat API
|
|
@@ -126,30 +127,35 @@ export declare const connectionSettingsSchema: z.ZodEffects<z.ZodObject<{
|
|
|
126
127
|
websocketEndpoint: z.ZodOptional<z.ZodString>;
|
|
127
128
|
signalRTransport: z.ZodEnum<["WebSockets", "ServerSentEvents", "LongPolling", "None"]>;
|
|
128
129
|
signalRLogLevel: z.ZodEnum<["Critical", "Debug", "Error", "Information", "None", "Trace", "Warning"]>;
|
|
130
|
+
signalRServerTimeoutInMilliseconds: z.ZodOptional<z.ZodNumber>;
|
|
129
131
|
}, "strip", z.ZodTypeAny, {
|
|
130
132
|
connectionErrorMessage: string;
|
|
131
133
|
signalRTransport: "None" | "WebSockets" | "ServerSentEvents" | "LongPolling";
|
|
132
134
|
signalRLogLevel: "None" | "Critical" | "Debug" | "Error" | "Information" | "Trace" | "Warning";
|
|
133
135
|
restEndpoint?: string | undefined;
|
|
134
136
|
websocketEndpoint?: string | undefined;
|
|
137
|
+
signalRServerTimeoutInMilliseconds?: number | undefined;
|
|
135
138
|
}, {
|
|
136
139
|
connectionErrorMessage: string;
|
|
137
140
|
signalRTransport: "None" | "WebSockets" | "ServerSentEvents" | "LongPolling";
|
|
138
141
|
signalRLogLevel: "None" | "Critical" | "Debug" | "Error" | "Information" | "Trace" | "Warning";
|
|
139
142
|
restEndpoint?: string | undefined;
|
|
140
143
|
websocketEndpoint?: string | undefined;
|
|
144
|
+
signalRServerTimeoutInMilliseconds?: number | undefined;
|
|
141
145
|
}>, {
|
|
142
146
|
connectionErrorMessage: string;
|
|
143
147
|
signalRTransport: "None" | "WebSockets" | "ServerSentEvents" | "LongPolling";
|
|
144
148
|
signalRLogLevel: "None" | "Critical" | "Debug" | "Error" | "Information" | "Trace" | "Warning";
|
|
145
149
|
restEndpoint?: string | undefined;
|
|
146
150
|
websocketEndpoint?: string | undefined;
|
|
151
|
+
signalRServerTimeoutInMilliseconds?: number | undefined;
|
|
147
152
|
}, {
|
|
148
153
|
connectionErrorMessage: string;
|
|
149
154
|
signalRTransport: "None" | "WebSockets" | "ServerSentEvents" | "LongPolling";
|
|
150
155
|
signalRLogLevel: "None" | "Critical" | "Debug" | "Error" | "Information" | "Trace" | "Warning";
|
|
151
156
|
restEndpoint?: string | undefined;
|
|
152
157
|
websocketEndpoint?: string | undefined;
|
|
158
|
+
signalRServerTimeoutInMilliseconds?: number | undefined;
|
|
153
159
|
}>;
|
|
154
160
|
export declare type ConnectionSettings = z.infer<typeof connectionSettingsSchema>;
|
|
155
161
|
declare const serviceSettingsSchema: z.ZodObject<{
|
|
@@ -260,7 +266,16 @@ declare const defaultValuesSchema: z.ZodObject<{
|
|
|
260
266
|
}>;
|
|
261
267
|
export interface DefaultValues extends z.infer<typeof defaultValuesSchema> {
|
|
262
268
|
}
|
|
263
|
-
declare const
|
|
269
|
+
declare const chatStarterSchema: z.ZodObject<{
|
|
270
|
+
text: z.ZodString;
|
|
271
|
+
}, "strip", z.ZodTypeAny, {
|
|
272
|
+
text: string;
|
|
273
|
+
}, {
|
|
274
|
+
text: string;
|
|
275
|
+
}>;
|
|
276
|
+
export interface ChatStarter extends z.infer<typeof chatStarterSchema> {
|
|
277
|
+
}
|
|
278
|
+
declare const modeSettingsSchema: z.ZodEffects<z.ZodObject<{
|
|
264
279
|
enabledUserInput: z.ZodBoolean;
|
|
265
280
|
displayUserPrompt: z.ZodBoolean;
|
|
266
281
|
sendUserPrompt: z.ZodBoolean;
|
|
@@ -268,23 +283,52 @@ declare const modeSettingsSchema: z.ZodObject<{
|
|
|
268
283
|
event: z.ZodEnum<["Query", "Prompt"]>;
|
|
269
284
|
forcedWorkflow: z.ZodOptional<z.ZodString>;
|
|
270
285
|
displayUserQuery: z.ZodOptional<z.ZodBoolean>;
|
|
286
|
+
chatStarters: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
287
|
+
text: z.ZodString;
|
|
288
|
+
}, "strip", z.ZodTypeAny, {
|
|
289
|
+
text: string;
|
|
290
|
+
}, {
|
|
291
|
+
text: string;
|
|
292
|
+
}>, "many">>;
|
|
271
293
|
}, "strip", z.ZodTypeAny, {
|
|
272
294
|
event: "Query" | "Prompt";
|
|
273
295
|
forcedWorkflow?: string | undefined;
|
|
274
296
|
displayUserQuery?: boolean | undefined;
|
|
297
|
+
chatStarters?: {
|
|
298
|
+
text: string;
|
|
299
|
+
}[] | undefined;
|
|
275
300
|
}, {
|
|
276
301
|
event: "Query" | "Prompt";
|
|
277
302
|
forcedWorkflow?: string | undefined;
|
|
278
303
|
displayUserQuery?: boolean | undefined;
|
|
304
|
+
chatStarters?: {
|
|
305
|
+
text: string;
|
|
306
|
+
}[] | undefined;
|
|
279
307
|
}>, {
|
|
280
308
|
event: "Query" | "Prompt";
|
|
281
309
|
forcedWorkflow?: string | undefined;
|
|
282
310
|
displayUserQuery?: boolean | undefined;
|
|
311
|
+
chatStarters?: {
|
|
312
|
+
text: string;
|
|
313
|
+
}[] | undefined;
|
|
283
314
|
}, {
|
|
284
315
|
event: "Query" | "Prompt";
|
|
285
316
|
forcedWorkflow?: string | undefined;
|
|
286
317
|
displayUserQuery?: boolean | undefined;
|
|
318
|
+
chatStarters?: {
|
|
319
|
+
text: string;
|
|
320
|
+
}[] | undefined;
|
|
287
321
|
}>;
|
|
322
|
+
actions: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
323
|
+
forcedWorkflow: z.ZodString;
|
|
324
|
+
forcedWorkflowProperties: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
325
|
+
}, "strip", z.ZodTypeAny, {
|
|
326
|
+
forcedWorkflow: string;
|
|
327
|
+
forcedWorkflowProperties?: globalThis.Record<string, unknown> | undefined;
|
|
328
|
+
}, {
|
|
329
|
+
forcedWorkflow: string;
|
|
330
|
+
forcedWorkflowProperties?: globalThis.Record<string, unknown> | undefined;
|
|
331
|
+
}>>>;
|
|
288
332
|
}, "strip", z.ZodTypeAny, {
|
|
289
333
|
displayUserPrompt: boolean;
|
|
290
334
|
enabledUserInput: boolean;
|
|
@@ -293,7 +337,14 @@ declare const modeSettingsSchema: z.ZodObject<{
|
|
|
293
337
|
event: "Query" | "Prompt";
|
|
294
338
|
forcedWorkflow?: string | undefined;
|
|
295
339
|
displayUserQuery?: boolean | undefined;
|
|
340
|
+
chatStarters?: {
|
|
341
|
+
text: string;
|
|
342
|
+
}[] | undefined;
|
|
296
343
|
};
|
|
344
|
+
actions?: globalThis.Record<string, {
|
|
345
|
+
forcedWorkflow: string;
|
|
346
|
+
forcedWorkflowProperties?: globalThis.Record<string, unknown> | undefined;
|
|
347
|
+
}> | undefined;
|
|
297
348
|
}, {
|
|
298
349
|
displayUserPrompt: boolean;
|
|
299
350
|
enabledUserInput: boolean;
|
|
@@ -302,7 +353,46 @@ declare const modeSettingsSchema: z.ZodObject<{
|
|
|
302
353
|
event: "Query" | "Prompt";
|
|
303
354
|
forcedWorkflow?: string | undefined;
|
|
304
355
|
displayUserQuery?: boolean | undefined;
|
|
356
|
+
chatStarters?: {
|
|
357
|
+
text: string;
|
|
358
|
+
}[] | undefined;
|
|
305
359
|
};
|
|
360
|
+
actions?: globalThis.Record<string, {
|
|
361
|
+
forcedWorkflow: string;
|
|
362
|
+
forcedWorkflowProperties?: globalThis.Record<string, unknown> | undefined;
|
|
363
|
+
}> | undefined;
|
|
364
|
+
}>, {
|
|
365
|
+
displayUserPrompt: boolean;
|
|
366
|
+
enabledUserInput: boolean;
|
|
367
|
+
sendUserPrompt: boolean;
|
|
368
|
+
initialization: {
|
|
369
|
+
event: "Query" | "Prompt";
|
|
370
|
+
forcedWorkflow?: string | undefined;
|
|
371
|
+
displayUserQuery?: boolean | undefined;
|
|
372
|
+
chatStarters?: {
|
|
373
|
+
text: string;
|
|
374
|
+
}[] | undefined;
|
|
375
|
+
};
|
|
376
|
+
actions?: globalThis.Record<string, {
|
|
377
|
+
forcedWorkflow: string;
|
|
378
|
+
forcedWorkflowProperties?: globalThis.Record<string, unknown> | undefined;
|
|
379
|
+
}> | undefined;
|
|
380
|
+
}, {
|
|
381
|
+
displayUserPrompt: boolean;
|
|
382
|
+
enabledUserInput: boolean;
|
|
383
|
+
sendUserPrompt: boolean;
|
|
384
|
+
initialization: {
|
|
385
|
+
event: "Query" | "Prompt";
|
|
386
|
+
forcedWorkflow?: string | undefined;
|
|
387
|
+
displayUserQuery?: boolean | undefined;
|
|
388
|
+
chatStarters?: {
|
|
389
|
+
text: string;
|
|
390
|
+
}[] | undefined;
|
|
391
|
+
};
|
|
392
|
+
actions?: globalThis.Record<string, {
|
|
393
|
+
forcedWorkflow: string;
|
|
394
|
+
forcedWorkflowProperties?: globalThis.Record<string, unknown> | undefined;
|
|
395
|
+
}> | undefined;
|
|
306
396
|
}>;
|
|
307
397
|
export interface ModeSettings extends z.infer<typeof modeSettingsSchema> {
|
|
308
398
|
}
|
|
@@ -327,30 +417,35 @@ export declare const chatConfigSchema: z.ZodObject<{
|
|
|
327
417
|
websocketEndpoint: z.ZodOptional<z.ZodString>;
|
|
328
418
|
signalRTransport: z.ZodEnum<["WebSockets", "ServerSentEvents", "LongPolling", "None"]>;
|
|
329
419
|
signalRLogLevel: z.ZodEnum<["Critical", "Debug", "Error", "Information", "None", "Trace", "Warning"]>;
|
|
420
|
+
signalRServerTimeoutInMilliseconds: z.ZodOptional<z.ZodNumber>;
|
|
330
421
|
}, "strip", z.ZodTypeAny, {
|
|
331
422
|
connectionErrorMessage: string;
|
|
332
423
|
signalRTransport: "None" | "WebSockets" | "ServerSentEvents" | "LongPolling";
|
|
333
424
|
signalRLogLevel: "None" | "Critical" | "Debug" | "Error" | "Information" | "Trace" | "Warning";
|
|
334
425
|
restEndpoint?: string | undefined;
|
|
335
426
|
websocketEndpoint?: string | undefined;
|
|
427
|
+
signalRServerTimeoutInMilliseconds?: number | undefined;
|
|
336
428
|
}, {
|
|
337
429
|
connectionErrorMessage: string;
|
|
338
430
|
signalRTransport: "None" | "WebSockets" | "ServerSentEvents" | "LongPolling";
|
|
339
431
|
signalRLogLevel: "None" | "Critical" | "Debug" | "Error" | "Information" | "Trace" | "Warning";
|
|
340
432
|
restEndpoint?: string | undefined;
|
|
341
433
|
websocketEndpoint?: string | undefined;
|
|
434
|
+
signalRServerTimeoutInMilliseconds?: number | undefined;
|
|
342
435
|
}>, {
|
|
343
436
|
connectionErrorMessage: string;
|
|
344
437
|
signalRTransport: "None" | "WebSockets" | "ServerSentEvents" | "LongPolling";
|
|
345
438
|
signalRLogLevel: "None" | "Critical" | "Debug" | "Error" | "Information" | "Trace" | "Warning";
|
|
346
439
|
restEndpoint?: string | undefined;
|
|
347
440
|
websocketEndpoint?: string | undefined;
|
|
441
|
+
signalRServerTimeoutInMilliseconds?: number | undefined;
|
|
348
442
|
}, {
|
|
349
443
|
connectionErrorMessage: string;
|
|
350
444
|
signalRTransport: "None" | "WebSockets" | "ServerSentEvents" | "LongPolling";
|
|
351
445
|
signalRLogLevel: "None" | "Critical" | "Debug" | "Error" | "Information" | "Trace" | "Warning";
|
|
352
446
|
restEndpoint?: string | undefined;
|
|
353
447
|
websocketEndpoint?: string | undefined;
|
|
448
|
+
signalRServerTimeoutInMilliseconds?: number | undefined;
|
|
354
449
|
}>;
|
|
355
450
|
defaultValues: z.ZodObject<{
|
|
356
451
|
service_id: z.ZodString;
|
|
@@ -398,7 +493,7 @@ export declare const chatConfigSchema: z.ZodObject<{
|
|
|
398
493
|
systemPrompt: string;
|
|
399
494
|
userPrompt: string;
|
|
400
495
|
}>;
|
|
401
|
-
modeSettings: z.ZodObject<{
|
|
496
|
+
modeSettings: z.ZodEffects<z.ZodObject<{
|
|
402
497
|
enabledUserInput: z.ZodBoolean;
|
|
403
498
|
displayUserPrompt: z.ZodBoolean;
|
|
404
499
|
sendUserPrompt: z.ZodBoolean;
|
|
@@ -406,23 +501,52 @@ export declare const chatConfigSchema: z.ZodObject<{
|
|
|
406
501
|
event: z.ZodEnum<["Query", "Prompt"]>;
|
|
407
502
|
forcedWorkflow: z.ZodOptional<z.ZodString>;
|
|
408
503
|
displayUserQuery: z.ZodOptional<z.ZodBoolean>;
|
|
504
|
+
chatStarters: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
505
|
+
text: z.ZodString;
|
|
506
|
+
}, "strip", z.ZodTypeAny, {
|
|
507
|
+
text: string;
|
|
508
|
+
}, {
|
|
509
|
+
text: string;
|
|
510
|
+
}>, "many">>;
|
|
409
511
|
}, "strip", z.ZodTypeAny, {
|
|
410
512
|
event: "Query" | "Prompt";
|
|
411
513
|
forcedWorkflow?: string | undefined;
|
|
412
514
|
displayUserQuery?: boolean | undefined;
|
|
515
|
+
chatStarters?: {
|
|
516
|
+
text: string;
|
|
517
|
+
}[] | undefined;
|
|
413
518
|
}, {
|
|
414
519
|
event: "Query" | "Prompt";
|
|
415
520
|
forcedWorkflow?: string | undefined;
|
|
416
521
|
displayUserQuery?: boolean | undefined;
|
|
522
|
+
chatStarters?: {
|
|
523
|
+
text: string;
|
|
524
|
+
}[] | undefined;
|
|
417
525
|
}>, {
|
|
418
526
|
event: "Query" | "Prompt";
|
|
419
527
|
forcedWorkflow?: string | undefined;
|
|
420
528
|
displayUserQuery?: boolean | undefined;
|
|
529
|
+
chatStarters?: {
|
|
530
|
+
text: string;
|
|
531
|
+
}[] | undefined;
|
|
421
532
|
}, {
|
|
422
533
|
event: "Query" | "Prompt";
|
|
423
534
|
forcedWorkflow?: string | undefined;
|
|
424
535
|
displayUserQuery?: boolean | undefined;
|
|
536
|
+
chatStarters?: {
|
|
537
|
+
text: string;
|
|
538
|
+
}[] | undefined;
|
|
425
539
|
}>;
|
|
540
|
+
actions: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
541
|
+
forcedWorkflow: z.ZodString;
|
|
542
|
+
forcedWorkflowProperties: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
543
|
+
}, "strip", z.ZodTypeAny, {
|
|
544
|
+
forcedWorkflow: string;
|
|
545
|
+
forcedWorkflowProperties?: globalThis.Record<string, unknown> | undefined;
|
|
546
|
+
}, {
|
|
547
|
+
forcedWorkflow: string;
|
|
548
|
+
forcedWorkflowProperties?: globalThis.Record<string, unknown> | undefined;
|
|
549
|
+
}>>>;
|
|
426
550
|
}, "strip", z.ZodTypeAny, {
|
|
427
551
|
displayUserPrompt: boolean;
|
|
428
552
|
enabledUserInput: boolean;
|
|
@@ -431,7 +555,46 @@ export declare const chatConfigSchema: z.ZodObject<{
|
|
|
431
555
|
event: "Query" | "Prompt";
|
|
432
556
|
forcedWorkflow?: string | undefined;
|
|
433
557
|
displayUserQuery?: boolean | undefined;
|
|
558
|
+
chatStarters?: {
|
|
559
|
+
text: string;
|
|
560
|
+
}[] | undefined;
|
|
561
|
+
};
|
|
562
|
+
actions?: globalThis.Record<string, {
|
|
563
|
+
forcedWorkflow: string;
|
|
564
|
+
forcedWorkflowProperties?: globalThis.Record<string, unknown> | undefined;
|
|
565
|
+
}> | undefined;
|
|
566
|
+
}, {
|
|
567
|
+
displayUserPrompt: boolean;
|
|
568
|
+
enabledUserInput: boolean;
|
|
569
|
+
sendUserPrompt: boolean;
|
|
570
|
+
initialization: {
|
|
571
|
+
event: "Query" | "Prompt";
|
|
572
|
+
forcedWorkflow?: string | undefined;
|
|
573
|
+
displayUserQuery?: boolean | undefined;
|
|
574
|
+
chatStarters?: {
|
|
575
|
+
text: string;
|
|
576
|
+
}[] | undefined;
|
|
577
|
+
};
|
|
578
|
+
actions?: globalThis.Record<string, {
|
|
579
|
+
forcedWorkflow: string;
|
|
580
|
+
forcedWorkflowProperties?: globalThis.Record<string, unknown> | undefined;
|
|
581
|
+
}> | undefined;
|
|
582
|
+
}>, {
|
|
583
|
+
displayUserPrompt: boolean;
|
|
584
|
+
enabledUserInput: boolean;
|
|
585
|
+
sendUserPrompt: boolean;
|
|
586
|
+
initialization: {
|
|
587
|
+
event: "Query" | "Prompt";
|
|
588
|
+
forcedWorkflow?: string | undefined;
|
|
589
|
+
displayUserQuery?: boolean | undefined;
|
|
590
|
+
chatStarters?: {
|
|
591
|
+
text: string;
|
|
592
|
+
}[] | undefined;
|
|
434
593
|
};
|
|
594
|
+
actions?: globalThis.Record<string, {
|
|
595
|
+
forcedWorkflow: string;
|
|
596
|
+
forcedWorkflowProperties?: globalThis.Record<string, unknown> | undefined;
|
|
597
|
+
}> | undefined;
|
|
435
598
|
}, {
|
|
436
599
|
displayUserPrompt: boolean;
|
|
437
600
|
enabledUserInput: boolean;
|
|
@@ -440,7 +603,14 @@ export declare const chatConfigSchema: z.ZodObject<{
|
|
|
440
603
|
event: "Query" | "Prompt";
|
|
441
604
|
forcedWorkflow?: string | undefined;
|
|
442
605
|
displayUserQuery?: boolean | undefined;
|
|
606
|
+
chatStarters?: {
|
|
607
|
+
text: string;
|
|
608
|
+
}[] | undefined;
|
|
443
609
|
};
|
|
610
|
+
actions?: globalThis.Record<string, {
|
|
611
|
+
forcedWorkflow: string;
|
|
612
|
+
forcedWorkflowProperties?: globalThis.Record<string, unknown> | undefined;
|
|
613
|
+
}> | undefined;
|
|
444
614
|
}>;
|
|
445
615
|
uiSettings: z.ZodObject<{
|
|
446
616
|
display: z.ZodBoolean;
|
|
@@ -519,6 +689,7 @@ export declare const chatConfigSchema: z.ZodObject<{
|
|
|
519
689
|
signalRLogLevel: "None" | "Critical" | "Debug" | "Error" | "Information" | "Trace" | "Warning";
|
|
520
690
|
restEndpoint?: string | undefined;
|
|
521
691
|
websocketEndpoint?: string | undefined;
|
|
692
|
+
signalRServerTimeoutInMilliseconds?: number | undefined;
|
|
522
693
|
};
|
|
523
694
|
defaultValues: {
|
|
524
695
|
debug: boolean;
|
|
@@ -542,7 +713,14 @@ export declare const chatConfigSchema: z.ZodObject<{
|
|
|
542
713
|
event: "Query" | "Prompt";
|
|
543
714
|
forcedWorkflow?: string | undefined;
|
|
544
715
|
displayUserQuery?: boolean | undefined;
|
|
716
|
+
chatStarters?: {
|
|
717
|
+
text: string;
|
|
718
|
+
}[] | undefined;
|
|
545
719
|
};
|
|
720
|
+
actions?: globalThis.Record<string, {
|
|
721
|
+
forcedWorkflow: string;
|
|
722
|
+
forcedWorkflowProperties?: globalThis.Record<string, unknown> | undefined;
|
|
723
|
+
}> | undefined;
|
|
546
724
|
};
|
|
547
725
|
uiSettings: {
|
|
548
726
|
display: boolean;
|
|
@@ -578,6 +756,7 @@ export declare const chatConfigSchema: z.ZodObject<{
|
|
|
578
756
|
signalRLogLevel: "None" | "Critical" | "Debug" | "Error" | "Information" | "Trace" | "Warning";
|
|
579
757
|
restEndpoint?: string | undefined;
|
|
580
758
|
websocketEndpoint?: string | undefined;
|
|
759
|
+
signalRServerTimeoutInMilliseconds?: number | undefined;
|
|
581
760
|
};
|
|
582
761
|
defaultValues: {
|
|
583
762
|
debug: boolean;
|
|
@@ -601,7 +780,14 @@ export declare const chatConfigSchema: z.ZodObject<{
|
|
|
601
780
|
event: "Query" | "Prompt";
|
|
602
781
|
forcedWorkflow?: string | undefined;
|
|
603
782
|
displayUserQuery?: boolean | undefined;
|
|
783
|
+
chatStarters?: {
|
|
784
|
+
text: string;
|
|
785
|
+
}[] | undefined;
|
|
604
786
|
};
|
|
787
|
+
actions?: globalThis.Record<string, {
|
|
788
|
+
forcedWorkflow: string;
|
|
789
|
+
forcedWorkflowProperties?: globalThis.Record<string, unknown> | undefined;
|
|
790
|
+
}> | undefined;
|
|
605
791
|
};
|
|
606
792
|
uiSettings: {
|
|
607
793
|
display: boolean;
|
|
@@ -9,12 +9,11 @@ import * as i0 from "@angular/core";
|
|
|
9
9
|
export declare class WebSocketChatService extends ChatService {
|
|
10
10
|
connection: HubConnection | undefined;
|
|
11
11
|
private _messageHandlers;
|
|
12
|
+
private _response;
|
|
12
13
|
private _actionMap;
|
|
13
14
|
private _progress;
|
|
14
|
-
private _content;
|
|
15
15
|
private _executionTime;
|
|
16
16
|
private _attachments;
|
|
17
|
-
private _suggestedActions;
|
|
18
17
|
private _debugMessages;
|
|
19
18
|
signalRService: SignalRWebService;
|
|
20
19
|
authenticationService: AuthenticationService;
|
|
@@ -34,6 +33,7 @@ export declare class WebSocketChatService extends ChatService {
|
|
|
34
33
|
listModels(): Observable<GllmModelDescription[] | undefined>;
|
|
35
34
|
listFunctions(): Observable<GllmFunction[] | undefined>;
|
|
36
35
|
fetch(messages: ChatMessage[], query: Query): Observable<ChatResponse>;
|
|
36
|
+
stopGeneration(): Observable<boolean>;
|
|
37
37
|
listSavedChat(): void;
|
|
38
38
|
getSavedChat(id: string): Observable<SavedChatHistory | undefined>;
|
|
39
39
|
addSavedChat(messages: ChatMessage[]): Observable<SavedChat>;
|
|
@@ -41,7 +41,7 @@ export declare class WebSocketChatService extends ChatService {
|
|
|
41
41
|
deleteSavedChat(ids: string[]): Observable<number>;
|
|
42
42
|
/**
|
|
43
43
|
* Initialize out-of-the-box handlers
|
|
44
|
-
* It is a placeholder for non-streaming scenarios, where you invoke a specific hub method, and the server responds with
|
|
44
|
+
* It is a placeholder for non-streaming scenarios, where you invoke a specific hub method, and the server responds with frame message(s)
|
|
45
45
|
*/
|
|
46
46
|
initMessageHandlers(): void;
|
|
47
47
|
/**
|
|
@@ -52,7 +52,7 @@ export declare class WebSocketChatService extends ChatService {
|
|
|
52
52
|
/**
|
|
53
53
|
* Add a listener for a specific event.
|
|
54
54
|
* If a listener for this same event already exists, it will be overridden.
|
|
55
|
-
* If the listener has "
|
|
55
|
+
* If the listener has "isGlobalHandler" set to true, it will be registered to the hub connection.
|
|
56
56
|
* @param eventName Name of the event to register a listener for
|
|
57
57
|
* @param eventHandler The handler to be called when the event is received
|
|
58
58
|
*/
|
|
@@ -93,8 +93,8 @@ export declare class WebSocketChatService extends ChatService {
|
|
|
93
93
|
* @returns Promise that resolves when the connection is stopped
|
|
94
94
|
*/
|
|
95
95
|
stopConnection(): Promise<void>;
|
|
96
|
-
private
|
|
97
|
-
private
|
|
96
|
+
private _getTransports;
|
|
97
|
+
private _getLogLevel;
|
|
98
98
|
get defaultOptions(): ConnectionOptions;
|
|
99
99
|
static ɵfac: i0.ɵɵFactoryDeclaration<WebSocketChatService, never>;
|
|
100
100
|
static ɵprov: i0.ɵɵInjectableDeclaration<WebSocketChatService>;
|