@futdevpro/nts-dynamo 1.14.35 → 1.14.37
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/build/_modules/ai/_models/ai-input-interfaces.d.ts +20 -28
- package/build/_modules/ai/_models/ai-input-interfaces.d.ts.map +1 -1
- package/build/_modules/ai/_models/ai-input-interfaces.js +3 -0
- package/build/_modules/ai/_models/ai-input-interfaces.js.map +1 -1
- package/build/_modules/ai/_modules/open-ai/_services/oai-llm-chat.service-base.d.ts +14 -58
- package/build/_modules/ai/_modules/open-ai/_services/oai-llm-chat.service-base.d.ts.map +1 -1
- package/build/_modules/ai/_modules/open-ai/_services/oai-llm-chat.service-base.js +138 -147
- package/build/_modules/ai/_modules/open-ai/_services/oai-llm-chat.service-base.js.map +1 -1
- package/build/_modules/ai/_modules/open-ai/_services/oai-llm.service-base.d.ts +27 -180
- package/build/_modules/ai/_modules/open-ai/_services/oai-llm.service-base.d.ts.map +1 -1
- package/build/_modules/ai/_modules/open-ai/_services/oai-llm.service-base.js +147 -328
- package/build/_modules/ai/_modules/open-ai/_services/oai-llm.service-base.js.map +1 -1
- package/build/_modules/ai/_services/ai-llm-chat.service-base.d.ts +22 -14
- package/build/_modules/ai/_services/ai-llm-chat.service-base.d.ts.map +1 -1
- package/build/_modules/ai/_services/ai-llm-chat.service-base.js.map +1 -1
- package/build/_modules/ai/_services/ai-llm.service-base.d.ts +52 -21
- package/build/_modules/ai/_services/ai-llm.service-base.d.ts.map +1 -1
- package/build/_modules/ai/_services/ai-llm.service-base.js +171 -0
- package/build/_modules/ai/_services/ai-llm.service-base.js.map +1 -1
- package/build/_modules/ai/_services/ai-provider.service-base.d.ts +1 -1
- package/build/_modules/ai/_services/ai-provider.service-base.d.ts.map +1 -1
- package/build/_modules/assistant/_services/ass-io.control-service.js +2 -2
- package/build/_modules/assistant/_services/ass-io.control-service.js.map +1 -1
- package/build/_modules/bot/_models/bot-channel-wrapper.interface.d.ts +8 -2
- package/build/_modules/bot/_models/bot-channel-wrapper.interface.d.ts.map +1 -1
- package/build/_modules/bot/_models/bot-channel-wrapper.interface.js +31 -0
- package/build/_modules/bot/_models/bot-channel-wrapper.interface.js.map +1 -1
- package/build/_modules/bot/_models/bot-message-wrapper.interface.d.ts +6 -1
- package/build/_modules/bot/_models/bot-message-wrapper.interface.d.ts.map +1 -1
- package/build/_modules/bot/_models/bot-message-wrapper.interface.js +39 -0
- package/build/_modules/bot/_models/bot-message-wrapper.interface.js.map +1 -1
- package/build/_modules/bot/_models/bot-user-wrapper.interface.d.ts +2 -1
- package/build/_modules/bot/_models/bot-user-wrapper.interface.d.ts.map +1 -1
- package/build/_modules/bot/_models/bot-user-wrapper.interface.js +18 -0
- package/build/_modules/bot/_models/bot-user-wrapper.interface.js.map +1 -1
- package/build/_modules/bot/_modules/discord-bot/_services/dib-messaging-provider.control-service.js +9 -6
- package/build/_modules/bot/_modules/discord-bot/_services/dib-messaging-provider.control-service.js.map +1 -1
- package/build/_modules/bot/_modules/dynamo-bot/_services/dyb-messaging-provider.control-service.js +9 -6
- package/build/_modules/bot/_modules/dynamo-bot/_services/dyb-messaging-provider.control-service.js.map +1 -1
- package/build/_modules/discord-assistant/_services/dias-chunk.data-service.js +9 -9
- package/build/_modules/discord-assistant/_services/dias-chunk.data-service.js.map +1 -1
- package/build/_modules/discord-assistant/_services/dias-io.control-service.js +2 -2
- package/build/_modules/discord-assistant/_services/dias-io.control-service.js.map +1 -1
- package/package.json +1 -1
- package/src/_modules/ai/_models/ai-input-interfaces.ts +63 -26
- package/src/_modules/ai/_modules/open-ai/_services/oai-llm-chat.service-base.ts +99 -139
- package/src/_modules/ai/_modules/open-ai/_services/oai-llm.service-base.ts +246 -294
- package/src/_modules/ai/_services/ai-llm-chat.service-base.ts +36 -16
- package/src/_modules/ai/_services/ai-llm.service-base.ts +272 -28
- package/src/_modules/ai/_services/ai-provider.service-base.ts +1 -1
- package/src/_modules/assistant/_services/ass-io.control-service.ts +2 -2
- package/src/_modules/bot/_models/bot-channel-wrapper.interface.ts +30 -4
- package/src/_modules/bot/_models/bot-message-wrapper.interface.ts +24 -2
- package/src/_modules/bot/_models/bot-user-wrapper.interface.ts +8 -2
- package/src/_modules/bot/_modules/discord-bot/_services/dib-messaging-provider.control-service.ts +6 -6
- package/src/_modules/bot/_modules/dynamo-bot/_services/dyb-messaging-provider.control-service.ts +6 -6
- package/src/_modules/discord-assistant/_services/dias-chunk.data-service.ts +9 -9
- package/src/_modules/discord-assistant/_services/dias-io.control-service.ts +2 -2
|
@@ -1,61 +1,53 @@
|
|
|
1
1
|
import { DyFM_AI_Message } from '@futdevpro/fsm-dynamo/ai';
|
|
2
2
|
import { DyFM_AI_CallSettings } from '@futdevpro/fsm-dynamo/ai';
|
|
3
|
-
export interface DyFM_AI_Base_Input {
|
|
3
|
+
export interface DyFM_AI_Base_Input<T_AISettings extends DyFM_AI_CallSettings = DyFM_AI_CallSettings> {
|
|
4
4
|
issuer: string;
|
|
5
|
-
settings?:
|
|
5
|
+
settings?: T_AISettings;
|
|
6
6
|
debugLog?: boolean;
|
|
7
|
-
}
|
|
8
|
-
export interface DyFM_AI_Question_Input extends DyFM_AI_Base_Input {
|
|
9
|
-
question: string;
|
|
10
7
|
replaceThisInLog?: string;
|
|
8
|
+
getFullResponse?: boolean;
|
|
9
|
+
}
|
|
10
|
+
export interface DyFM_AI_Message_Input<T_AISettings extends DyFM_AI_CallSettings = DyFM_AI_CallSettings> extends DyFM_AI_Base_Input<T_AISettings> {
|
|
11
|
+
message: string;
|
|
11
12
|
}
|
|
12
|
-
export interface DyFM_AI_ListSelect_Input extends
|
|
13
|
+
export interface DyFM_AI_ListSelect_Input<T_AISettings extends DyFM_AI_CallSettings = DyFM_AI_CallSettings> extends DyFM_AI_Message_Input<T_AISettings> {
|
|
13
14
|
selectFrom: string[];
|
|
14
15
|
}
|
|
15
|
-
export interface DyFM_AI_GenericSelect_Input<T> extends
|
|
16
|
+
export interface DyFM_AI_GenericSelect_Input<T, T_AISettings extends DyFM_AI_CallSettings = DyFM_AI_CallSettings> extends DyFM_AI_Message_Input<T_AISettings> {
|
|
16
17
|
selectFrom: T[];
|
|
17
18
|
}
|
|
18
|
-
export interface DyFM_AI_MultiSelect_Input extends
|
|
19
|
+
export interface DyFM_AI_MultiSelect_Input<T_AISettings extends DyFM_AI_CallSettings = DyFM_AI_CallSettings> extends DyFM_AI_Message_Input<T_AISettings> {
|
|
19
20
|
options: string[];
|
|
20
21
|
}
|
|
21
|
-
export interface DyFM_AI_GenericMultiSelect_Input<T> extends
|
|
22
|
+
export interface DyFM_AI_GenericMultiSelect_Input<T, T_AISettings extends DyFM_AI_CallSettings = DyFM_AI_CallSettings> extends DyFM_AI_Message_Input<T_AISettings> {
|
|
22
23
|
options: T[];
|
|
23
24
|
}
|
|
24
|
-
export interface DyFM_AI_JSONKeysDescription_Input extends
|
|
25
|
+
export interface DyFM_AI_JSONKeysDescription_Input<T_AISettings extends DyFM_AI_CallSettings = DyFM_AI_CallSettings> extends DyFM_AI_Message_Input<T_AISettings> {
|
|
25
26
|
keysDescription: string;
|
|
26
27
|
}
|
|
27
|
-
export interface DyFM_AI_JSONExactKeys_Input extends
|
|
28
|
+
export interface DyFM_AI_JSONExactKeys_Input<T_AISettings extends DyFM_AI_CallSettings = DyFM_AI_CallSettings> extends DyFM_AI_Message_Input<T_AISettings> {
|
|
28
29
|
keys: string[];
|
|
29
30
|
}
|
|
30
|
-
export interface
|
|
31
|
-
message
|
|
32
|
-
}
|
|
33
|
-
export interface DyFM_AI_ConversationBase_Input extends DyFM_AI_Base_Input {
|
|
31
|
+
export interface DyFM_AI_ConversationBase_Input<T_AISettings extends DyFM_AI_CallSettings = DyFM_AI_CallSettings> extends DyFM_AI_Base_Input<T_AISettings> {
|
|
32
|
+
message?: string;
|
|
34
33
|
conversation: DyFM_AI_Message[];
|
|
35
|
-
replaceThisInLog?: string;
|
|
36
34
|
}
|
|
37
|
-
export interface
|
|
38
|
-
question: string;
|
|
39
|
-
}
|
|
40
|
-
export interface DyFM_AI_ConversationSelect_Input extends DyFM_AI_ConversationQuestion_Input {
|
|
35
|
+
export interface DyFM_AI_ConversationSelect_Input<T_AISettings extends DyFM_AI_CallSettings = DyFM_AI_CallSettings> extends DyFM_AI_ConversationBase_Input<T_AISettings> {
|
|
41
36
|
selectFrom: string[];
|
|
42
37
|
}
|
|
43
|
-
export interface DyFM_AI_ConversationGenericSelect_Input<T> extends
|
|
38
|
+
export interface DyFM_AI_ConversationGenericSelect_Input<T, T_AISettings extends DyFM_AI_CallSettings = DyFM_AI_CallSettings> extends DyFM_AI_ConversationBase_Input<T_AISettings> {
|
|
44
39
|
selectFrom: T[];
|
|
45
40
|
}
|
|
46
|
-
export interface DyFM_AI_ConversationMultiSelect_Input extends
|
|
41
|
+
export interface DyFM_AI_ConversationMultiSelect_Input<T_AISettings extends DyFM_AI_CallSettings = DyFM_AI_CallSettings> extends DyFM_AI_ConversationBase_Input<T_AISettings> {
|
|
47
42
|
options: string[];
|
|
48
43
|
}
|
|
49
|
-
export interface DyFM_AI_ConversationGenericMultiSelect_Input<T> extends
|
|
44
|
+
export interface DyFM_AI_ConversationGenericMultiSelect_Input<T, T_AISettings extends DyFM_AI_CallSettings = DyFM_AI_CallSettings> extends DyFM_AI_ConversationBase_Input<T_AISettings> {
|
|
50
45
|
options: T[];
|
|
51
46
|
}
|
|
52
|
-
export interface DyFM_AI_ConversationJSONKeysDescription_Input extends
|
|
47
|
+
export interface DyFM_AI_ConversationJSONKeysDescription_Input<T_AISettings extends DyFM_AI_CallSettings = DyFM_AI_CallSettings> extends DyFM_AI_ConversationBase_Input<T_AISettings> {
|
|
53
48
|
keysDescription: string;
|
|
54
49
|
}
|
|
55
|
-
export interface DyFM_AI_ConversationJSONExactKeys_Input extends
|
|
50
|
+
export interface DyFM_AI_ConversationJSONExactKeys_Input<T_AISettings extends DyFM_AI_CallSettings = DyFM_AI_CallSettings> extends DyFM_AI_ConversationBase_Input<T_AISettings> {
|
|
56
51
|
keys: string[];
|
|
57
52
|
}
|
|
58
|
-
export interface DyFM_AI_ConversationGetAnswer_Input extends DyFM_AI_ConversationBase_Input {
|
|
59
|
-
newMessage?: string;
|
|
60
|
-
}
|
|
61
53
|
//# sourceMappingURL=ai-input-interfaces.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ai-input-interfaces.d.ts","sourceRoot":"","sources":["../../../../src/_modules/ai/_models/ai-input-interfaces.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAC3D,OAAO,EAAE,oBAAoB,EAAE,MAAM,0BAA0B,CAAC;AAEhE,MAAM,WAAW,kBAAkB;
|
|
1
|
+
{"version":3,"file":"ai-input-interfaces.d.ts","sourceRoot":"","sources":["../../../../src/_modules/ai/_models/ai-input-interfaces.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAC3D,OAAO,EAAE,oBAAoB,EAAE,MAAM,0BAA0B,CAAC;AAEhE,MAAM,WAAW,kBAAkB,CACjC,YAAY,SAAS,oBAAoB,GAAG,oBAAoB;IAGhE,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,YAAY,CAAC;IACxB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,eAAe,CAAC,EAAE,OAAO,CAAC;CAC3B;AAED,MAAM,WAAW,qBAAqB,CACpC,YAAY,SAAS,oBAAoB,GAAG,oBAAoB,CAChE,SAAQ,kBAAkB,CAAC,YAAY,CAAC;IACxC,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,wBAAwB,CACvC,YAAY,SAAS,oBAAoB,GAAG,oBAAoB,CAChE,SAAQ,qBAAqB,CAAC,YAAY,CAAC;IAC3C,UAAU,EAAE,MAAM,EAAE,CAAC;CACtB;AAED,MAAM,WAAW,2BAA2B,CAC1C,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,MAAM,WAAW,qCAAqC,CACpD,YAAY,SAAS,oBAAoB,GAAG,oBAAoB,CAChE,SAAQ,8BAA8B,CAAC,YAAY,CAAC;IACpD,OAAO,EAAE,MAAM,EAAE,CAAC;CACnB;AAED,MAAM,WAAW,4CAA4C,CAC3D,CAAC,EACD,YAAY,SAAS,oBAAoB,GAAG,oBAAoB,CAChE,SAAQ,8BAA8B,CAAC,YAAY,CAAC;IACpD,OAAO,EAAE,CAAC,EAAE,CAAC;CACd;AAED,MAAM,WAAW,6CAA6C,CAC5D,YAAY,SAAS,oBAAoB,GAAG,oBAAoB,CAChE,SAAQ,8BAA8B,CAAC,YAAY,CAAC;IACpD,eAAe,EAAE,MAAM,CAAC;CACzB;AAED,MAAM,WAAW,uCAAuC,CACtD,YAAY,SAAS,oBAAoB,GAAG,oBAAoB,CAChE,SAAQ,8BAA8B,CAAC,YAAY,CAAC;IACpD,IAAI,EAAE,MAAM,EAAE,CAAC;CAChB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ai-input-interfaces.js","sourceRoot":"","sources":["../../../../src/_modules/ai/_models/ai-input-interfaces.ts"],"names":[],"mappings":""}
|
|
1
|
+
{"version":3,"file":"ai-input-interfaces.js","sourceRoot":"","sources":["../../../../src/_modules/ai/_models/ai-input-interfaces.ts"],"names":[],"mappings":";;AAiHA;;IAEI"}
|
|
@@ -3,7 +3,7 @@ import { DyFM_AI_Message } from '@futdevpro/fsm-dynamo/ai';
|
|
|
3
3
|
import { ChatCompletion } from 'openai/resources';
|
|
4
4
|
import { DyNTS_OAI_LLM_ServiceBase } from './oai-llm.service-base';
|
|
5
5
|
import { DyNTS_AI_LLMChat_ServiceBase } from '../../../_services/ai-llm-chat.service-base';
|
|
6
|
-
import {
|
|
6
|
+
import { DyFM_AI_ConversationBase_Input, DyFM_AI_ConversationGenericSelect_Input, DyFM_AI_ConversationGenericMultiSelect_Input, DyFM_AI_ConversationJSONKeysDescription_Input, DyFM_AI_ConversationJSONExactKeys_Input } from '../../../_models/ai-input-interfaces';
|
|
7
7
|
/**
|
|
8
8
|
* {
|
|
9
9
|
* organization: 'org-XY',
|
|
@@ -12,56 +12,52 @@ import { DyFM_AI_ConversationQuestion_Input, DyFM_AI_ConversationSelect_Input, D
|
|
|
12
12
|
* }
|
|
13
13
|
*/
|
|
14
14
|
export declare class DyNTS_OAI_LLMChat_ServiceBase extends DyNTS_OAI_LLM_ServiceBase implements DyNTS_AI_LLMChat_ServiceBase {
|
|
15
|
-
private conversationHistories;
|
|
16
15
|
/**
|
|
17
16
|
* Hozzáad egy üzenetet a conversation history-hoz
|
|
18
17
|
*
|
|
19
18
|
* Adds a message to conversation history
|
|
20
19
|
*/
|
|
21
|
-
addMessageToHistory(message: DyFM_AI_Message, issuer: string): void;
|
|
22
20
|
/**
|
|
23
21
|
* Törli a conversation history-t
|
|
24
22
|
*
|
|
25
23
|
* Clears conversation history
|
|
26
24
|
*/
|
|
27
|
-
clearHistory(issuer: string): void;
|
|
28
25
|
/**
|
|
29
26
|
* Visszaadja a conversation history-t
|
|
30
27
|
*
|
|
31
28
|
* Gets conversation history
|
|
32
29
|
*/
|
|
33
|
-
getHistory(issuer: string): DyFM_AI_Message[];
|
|
34
30
|
/**
|
|
35
31
|
* Converts generic AI messages to OpenAI-specific format
|
|
36
32
|
*
|
|
37
33
|
* Az generic AI üzeneteket OpenAI-specifikus formátumra alakítja át
|
|
38
34
|
*/
|
|
39
|
-
private convertToOAIMessages;
|
|
40
35
|
/**
|
|
41
36
|
* Asks the AI to answer a yes/no question
|
|
42
37
|
*
|
|
43
38
|
* Uses the {@link DyNTS_OAI_LLM_Predefined_Requests.yesNo.request} to ask the question,
|
|
44
39
|
* and the {@link DyNTS_OAI_LLM_Predefined_Requests.yesNo.upperCaseYes} to check the answer
|
|
45
40
|
*/
|
|
46
|
-
|
|
41
|
+
requestYesNoInConversation(set: DyFM_AI_ConversationBase_Input<DyFM_OAI_CallSettings>): Promise<boolean>;
|
|
47
42
|
/**
|
|
48
43
|
* Asks the AI to answer a simple question
|
|
49
44
|
*
|
|
50
45
|
* Uses the {@link DyNTS_OAI_LLM_Predefined_Requests.simpleQuestion} to ask the question
|
|
51
46
|
*/
|
|
52
|
-
simpleQuestionInConversation(set: DyFM_AI_ConversationQuestion_Input): Promise<string>;
|
|
53
47
|
/**
|
|
54
48
|
* Asks the AI to answer a percentage question
|
|
55
49
|
*
|
|
56
50
|
* Uses the {@link DyNTS_OAI_LLM_Predefined_Requests.percentageOnly} to ask the question
|
|
57
51
|
*/
|
|
58
|
-
|
|
52
|
+
requestPercentageInConversation(set: DyFM_AI_ConversationBase_Input<DyFM_OAI_CallSettings>): Promise<number>;
|
|
59
53
|
/**
|
|
60
54
|
* Asks the AI to select one of the options from the list
|
|
61
55
|
*
|
|
62
56
|
* Uses the {@link DyNTS_OAI_LLM_Predefined_Requests.selectRequest} to ask the question
|
|
63
57
|
*/
|
|
64
|
-
|
|
58
|
+
requestSelectInConversation<T>(set: DyFM_AI_ConversationGenericSelect_Input<T, DyFM_OAI_CallSettings>): Promise<T | {
|
|
59
|
+
unparsableResult: string;
|
|
60
|
+
}>;
|
|
65
61
|
/**
|
|
66
62
|
* Asks the AI to select one of the options from the list
|
|
67
63
|
* Similar to {@link askSelectQuestion},
|
|
@@ -69,15 +65,11 @@ export declare class DyNTS_OAI_LLMChat_ServiceBase extends DyNTS_OAI_LLM_Service
|
|
|
69
65
|
*
|
|
70
66
|
* Uses the {@link DyNTS_OAI_LLM_Predefined_Requests.selectRequest} to ask the question
|
|
71
67
|
*/
|
|
72
|
-
requestSelectInConversation<T>(set: DyFM_AI_ConversationGenericSelect_Input<T>): Promise<T | {
|
|
73
|
-
unparsableResult: string;
|
|
74
|
-
}>;
|
|
75
68
|
/**
|
|
76
69
|
* Asks the AI to select one or more of the options from the list
|
|
77
70
|
*
|
|
78
71
|
* Uses the {@link DyNTS_OAI_LLM_Predefined_Requests.multiselect} to ask the question
|
|
79
72
|
*/
|
|
80
|
-
multipleSelectQuestionInConversationWithOptions(set: DyFM_AI_ConversationMultiSelect_Input): Promise<string[]>;
|
|
81
73
|
/**
|
|
82
74
|
* Asks the AI to select one or more of the options from the list
|
|
83
75
|
* Similar to {@link askMultipleSelectQuestionWithOptions},
|
|
@@ -85,7 +77,7 @@ export declare class DyNTS_OAI_LLMChat_ServiceBase extends DyNTS_OAI_LLM_Service
|
|
|
85
77
|
*
|
|
86
78
|
* Uses the {@link DyNTS_OAI_LLM_Predefined_Requests.multiselect} to ask the question
|
|
87
79
|
*/
|
|
88
|
-
requestMultiselectInConversation<T>(set: DyFM_AI_ConversationGenericMultiSelect_Input<T>): Promise<T[]>;
|
|
80
|
+
requestMultiselectInConversation<T>(set: DyFM_AI_ConversationGenericMultiSelect_Input<T, DyFM_OAI_CallSettings>): Promise<T[]>;
|
|
89
81
|
/**
|
|
90
82
|
* Asks the AI to answer a question that must result a JSON object
|
|
91
83
|
*
|
|
@@ -95,7 +87,7 @@ export declare class DyNTS_OAI_LLMChat_ServiceBase extends DyNTS_OAI_LLM_Service
|
|
|
95
87
|
*
|
|
96
88
|
* (uses {@link DyFM_safeParseJSON})
|
|
97
89
|
*/
|
|
98
|
-
|
|
90
|
+
requestJSONInConversation<T = any>(set: DyFM_AI_ConversationBase_Input<DyFM_OAI_CallSettings>): Promise<T | {
|
|
99
91
|
unparsableResult: string;
|
|
100
92
|
}>;
|
|
101
93
|
/**
|
|
@@ -107,7 +99,6 @@ export declare class DyNTS_OAI_LLMChat_ServiceBase extends DyNTS_OAI_LLM_Service
|
|
|
107
99
|
*
|
|
108
100
|
* (uses {@link DyFM_safeParseJSON})
|
|
109
101
|
*/
|
|
110
|
-
JSONQuestionInConversationWithKeysDescription(set: DyFM_AI_ConversationJSONKeysDescription_Input): Promise<object>;
|
|
111
102
|
/**
|
|
112
103
|
* Asks the AI to answer a question that must result a JSON object with specific key descriptions
|
|
113
104
|
*
|
|
@@ -117,7 +108,7 @@ export declare class DyNTS_OAI_LLMChat_ServiceBase extends DyNTS_OAI_LLM_Service
|
|
|
117
108
|
*
|
|
118
109
|
* (uses {@link DyFM_safeParseJSON})
|
|
119
110
|
*/
|
|
120
|
-
|
|
111
|
+
requestJSONInConversationWithKeysDescription<T = any>(set: DyFM_AI_ConversationJSONKeysDescription_Input): Promise<T | {
|
|
121
112
|
unparsableResult: string;
|
|
122
113
|
}>;
|
|
123
114
|
/**
|
|
@@ -129,7 +120,6 @@ export declare class DyNTS_OAI_LLMChat_ServiceBase extends DyNTS_OAI_LLM_Service
|
|
|
129
120
|
*
|
|
130
121
|
* (uses {@link DyFM_safeParseJSON})
|
|
131
122
|
*/
|
|
132
|
-
JSONQuestionInConversationWithExactKeys(set: DyFM_AI_ConversationJSONExactKeys_Input): Promise<object>;
|
|
133
123
|
/**
|
|
134
124
|
* Asks the AI to answer a question that must result a JSON object with specific keys
|
|
135
125
|
*
|
|
@@ -139,7 +129,7 @@ export declare class DyNTS_OAI_LLMChat_ServiceBase extends DyNTS_OAI_LLM_Service
|
|
|
139
129
|
*
|
|
140
130
|
* (uses {@link DyFM_safeParseJSON})
|
|
141
131
|
*/
|
|
142
|
-
|
|
132
|
+
requestJSONInConversationWithExactKeys<T = any>(set: DyFM_AI_ConversationJSONExactKeys_Input): Promise<T | {
|
|
143
133
|
unparsableResult: string;
|
|
144
134
|
}>;
|
|
145
135
|
/**
|
|
@@ -151,13 +141,12 @@ export declare class DyNTS_OAI_LLMChat_ServiceBase extends DyNTS_OAI_LLM_Service
|
|
|
151
141
|
*
|
|
152
142
|
* (uses {@link DyFM_Object.safeParseList})
|
|
153
143
|
*/
|
|
154
|
-
|
|
144
|
+
requestListInConversation<T = any>(set: DyFM_AI_ConversationBase_Input<DyFM_OAI_CallSettings>): Promise<T[]>;
|
|
155
145
|
/**
|
|
156
146
|
* Asks the AI to answer a question
|
|
157
147
|
*
|
|
158
148
|
* Uses the {@link resolveSimpleUserMessage}
|
|
159
149
|
*/
|
|
160
|
-
getQuestionAnswerInConversation(set: DyFM_AI_ConversationQuestion_Input): Promise<string>;
|
|
161
150
|
/**
|
|
162
151
|
* Asks the AI to answer a question using the whole conversation
|
|
163
152
|
* (If you want to use only the conversation, without adding a new message,
|
|
@@ -165,46 +154,13 @@ export declare class DyNTS_OAI_LLMChat_ServiceBase extends DyNTS_OAI_LLM_Service
|
|
|
165
154
|
*
|
|
166
155
|
* Uses the {@link resolveConversation}
|
|
167
156
|
*/
|
|
168
|
-
|
|
169
|
-
resolveConversationMessage(set: {
|
|
170
|
-
conversation: DyFM_AI_Message[];
|
|
171
|
-
issuer: string;
|
|
172
|
-
settings?: DyFM_OAI_CallSettings;
|
|
173
|
-
getFullResponse?: boolean;
|
|
174
|
-
debugLog?: boolean;
|
|
175
|
-
/** this is used to readably replace too long contents to eg '...' in logs */
|
|
176
|
-
replaceThisInLog?: string;
|
|
177
|
-
}): Promise<string>;
|
|
157
|
+
requestSimpleMessageInConversation(set: DyFM_AI_ConversationBase_Input<DyFM_OAI_CallSettings>): Promise<string>;
|
|
178
158
|
/**
|
|
179
159
|
* Resolves a conversation
|
|
180
160
|
*
|
|
181
161
|
* Uses the {@link getMessageCreateInput}
|
|
182
162
|
*/
|
|
183
|
-
resolveConversation(set:
|
|
184
|
-
|
|
185
|
-
issuer: string;
|
|
186
|
-
settings?: DyFM_OAI_CallSettings;
|
|
187
|
-
getFullResponse?: boolean;
|
|
188
|
-
debugLog?: boolean;
|
|
189
|
-
/** this is used to readably replace too long contents to eg '...' in logs */
|
|
190
|
-
replaceThisInLog?: string;
|
|
191
|
-
}): Promise<string | ChatCompletion>;
|
|
192
|
-
protected shortenConversation(set: {
|
|
193
|
-
conversation: DyFM_AI_Message[];
|
|
194
|
-
issuer: string;
|
|
195
|
-
debugLog?: boolean;
|
|
196
|
-
}): DyFM_AI_Message[];
|
|
197
|
-
protected logConversation(set: {
|
|
198
|
-
conversation: DyFM_AI_Message[];
|
|
199
|
-
debugLog?: boolean;
|
|
200
|
-
/** this is used to readably replace too long contents to eg '...' in logs */
|
|
201
|
-
replaceThisInLog?: string;
|
|
202
|
-
}): void;
|
|
203
|
-
/**
|
|
204
|
-
* Kérdez egy kérdést és JSON választ vár exact keys-szel
|
|
205
|
-
*
|
|
206
|
-
* Asks a question and expects JSON response with exact keys
|
|
207
|
-
*/
|
|
208
|
-
requestJSONInConversationWithExactKeys<T>(set: DyFM_AI_ConversationJSONExactKeys_Input): Promise<T>;
|
|
163
|
+
resolveConversation(set: DyFM_AI_ConversationBase_Input<DyFM_OAI_CallSettings>): Promise<string | ChatCompletion>;
|
|
164
|
+
protected shortenConversation(set: DyFM_AI_ConversationBase_Input<DyFM_OAI_CallSettings>): DyFM_AI_Message[];
|
|
209
165
|
}
|
|
210
166
|
//# sourceMappingURL=oai-llm-chat.service-base.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"oai-llm-chat.service-base.d.ts","sourceRoot":"","sources":["../../../../../../src/_modules/ai/_modules/open-ai/_services/oai-llm-chat.service-base.ts"],"names":[],"mappings":"AAEA,OAAO,EAAqC,qBAAqB,EAAE,MAAM,kCAAkC,CAAC;AAE5G,OAAO,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAG3D,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAIlD,OAAO,EAAE,yBAAyB,EAAE,MAAM,wBAAwB,CAAC;AAEnE,OAAO,EAAE,4BAA4B,EAAE,MAAM,6CAA6C,CAAC;AAC3F,OAAO,EACL,
|
|
1
|
+
{"version":3,"file":"oai-llm-chat.service-base.d.ts","sourceRoot":"","sources":["../../../../../../src/_modules/ai/_modules/open-ai/_services/oai-llm-chat.service-base.ts"],"names":[],"mappings":"AAEA,OAAO,EAAqC,qBAAqB,EAAE,MAAM,kCAAkC,CAAC;AAE5G,OAAO,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAG3D,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAIlD,OAAO,EAAE,yBAAyB,EAAE,MAAM,wB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