@dataclouder/ngx-agent-cards 0.1.65 → 0.1.67
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.
|
@@ -1958,6 +1958,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.6", ngImpor
|
|
|
1958
1958
|
|
|
1959
1959
|
class MessageProcessingService {
|
|
1960
1960
|
processMessage(message, conversationSettings) {
|
|
1961
|
+
console.log('processMessage conversation data', conversationSettings);
|
|
1961
1962
|
const processedMessage = {
|
|
1962
1963
|
...message,
|
|
1963
1964
|
messageId: message.messageId || nanoid(),
|
|
@@ -1971,6 +1972,7 @@ class MessageProcessingService {
|
|
|
1971
1972
|
if (processedMessage.role === ChatRole.Assistant) {
|
|
1972
1973
|
return this.processAssistantMessage(processedMessage, conversationSettings);
|
|
1973
1974
|
}
|
|
1975
|
+
console.log('processMessage processedMessage', processedMessage);
|
|
1974
1976
|
return processedMessage;
|
|
1975
1977
|
}
|
|
1976
1978
|
processAssistantMessage(message, settings) {
|
|
@@ -2739,8 +2741,10 @@ class ConversationService {
|
|
|
2739
2741
|
return this.wordClickedSignal;
|
|
2740
2742
|
}
|
|
2741
2743
|
createNewUserMessage() {
|
|
2744
|
+
debugger;
|
|
2742
2745
|
const message = { content: '...', role: ChatRole.User };
|
|
2743
2746
|
const processedMessage = this.messageProcessingService.processMessage(message, this.conversationSettingsState());
|
|
2747
|
+
console.log('processedMessage before add to state', processedMessage);
|
|
2744
2748
|
this.messagesStateService.addMessage(processedMessage);
|
|
2745
2749
|
return processedMessage.messageId;
|
|
2746
2750
|
}
|
|
@@ -2794,6 +2798,7 @@ class ConversationService {
|
|
|
2794
2798
|
if (!conversationSettings.avatarImages?.user) {
|
|
2795
2799
|
conversationSettings.avatarImages.user = this.userService.user().urlPicture || DEFUALT_USER_AVATAR;
|
|
2796
2800
|
}
|
|
2801
|
+
console.log('initConversationWithSettings final antes de set', conversationSettings);
|
|
2797
2802
|
this.conversationSettingsState.set(conversationSettings);
|
|
2798
2803
|
this.dynamicFlowService.setConversationFlow(conversationFlow);
|
|
2799
2804
|
await this.initConversation();
|
|
@@ -2817,6 +2822,7 @@ class ConversationService {
|
|
|
2817
2822
|
const firstAssistantMsg = conversationSettings.messages.find((message) => message.role === ChatRole.Assistant);
|
|
2818
2823
|
if (firstAssistantMsg) {
|
|
2819
2824
|
// Process the first assistant message
|
|
2825
|
+
debugger;
|
|
2820
2826
|
const processedMessage = this.messageProcessingService.processMessage(firstAssistantMsg, this.conversationSettingsState());
|
|
2821
2827
|
this.messagesStateService.updateMessage(firstAssistantMsg.messageId, processedMessage);
|
|
2822
2828
|
// Find the index of the message with the matching ID
|
|
@@ -4395,6 +4401,7 @@ class DCChatComponent {
|
|
|
4395
4401
|
this.conversationService.setDestroyed(false);
|
|
4396
4402
|
this.chatMonitorService.isConversationActive.set(true);
|
|
4397
4403
|
if (this.conversationSettings) {
|
|
4404
|
+
console.log('iniciando conversación', this.conversationSettings);
|
|
4398
4405
|
await this.conversationService.initConversationWithSettings(this.conversationSettings, this.conversationFlow);
|
|
4399
4406
|
}
|
|
4400
4407
|
else {
|