@dataclouder/ngx-agent-cards 0.1.20 → 0.1.22
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/fesm2022/dataclouder-ngx-agent-cards.mjs +99 -58
- package/fesm2022/dataclouder-ngx-agent-cards.mjs.map +1 -1
- package/lib/components/chat-container/chat-container.component.d.ts +2 -0
- package/lib/components/dc-agent-card-lists/dc-agent-card-lists.component.d.ts +1 -1
- package/lib/components/dc-agent-form/dc-agent-card-form.component.d.ts +2 -1
- package/lib/components/dc-agent-form/dc-do-action-form/dc-do-action-form.component.d.ts +3 -2
- package/lib/components/dc-agent-form/dc-dynamic-conditions-form/dc-dynamic-conditions-form.component.d.ts +1 -1
- package/lib/components/dc-agent-form/form-group.utils.d.ts +1 -0
- package/lib/models/agent.models.d.ts +6 -6
- package/lib/models/conversation-ai.class.d.ts +4 -3
- package/lib/services/conversation.service.d.ts +1 -1
- package/lib/services/default-agent-service.d.ts +4 -3
- package/lib/services/dynamic-flow.service.d.ts +1 -1
- package/package.json +1 -1
|
@@ -5,6 +5,7 @@ import { EvaluationService } from '../../services/evaluation.service';
|
|
|
5
5
|
import { ChatEvent } from '../../models/agent.models';
|
|
6
6
|
import { ChatUserSettings } from '@dataclouder/ngx-core';
|
|
7
7
|
import { MessagesStateService } from '../../services/messages-state.service';
|
|
8
|
+
import { DynamicFlowService } from '../../services/dynamic-flow.service';
|
|
8
9
|
import * as i0 from "@angular/core";
|
|
9
10
|
export declare class DCChatComponent implements OnInit, OnDestroy {
|
|
10
11
|
private dialogService;
|
|
@@ -12,6 +13,7 @@ export declare class DCChatComponent implements OnInit, OnDestroy {
|
|
|
12
13
|
evaluationService: EvaluationService;
|
|
13
14
|
private userDataExchange;
|
|
14
15
|
messageStateService: MessagesStateService;
|
|
16
|
+
dynamicFlowService: DynamicFlowService;
|
|
15
17
|
private chatFooterComponent;
|
|
16
18
|
chatUserSettings: ChatUserSettings;
|
|
17
19
|
conversationSettings: IConversationSettings;
|
|
@@ -17,7 +17,7 @@ export declare class AgentCardListComponent extends PaginationBase implements On
|
|
|
17
17
|
readonly getCustomButtons: import("@angular/core").InputSignal<(card: IAgentCard) => MenuItem[]>;
|
|
18
18
|
outlets: QueryList<NgComponentOutlet>;
|
|
19
19
|
protected columns: PColumn[];
|
|
20
|
-
agentCards: IAgentCard[]
|
|
20
|
+
agentCards: import("@angular/core").WritableSignal<IAgentCard[]>;
|
|
21
21
|
private cardEventSubs;
|
|
22
22
|
cardComponent: Type<DCConversationCardUIComponent>;
|
|
23
23
|
filterBarOptions: ListFilterBarOptions;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { OnInit } from '@angular/core';
|
|
2
2
|
import { FormArray, FormGroup } from '@angular/forms';
|
|
3
3
|
import { AudioSpeed } from '@dataclouder/ngx-core';
|
|
4
|
-
import { StorageImageSettings } from '@dataclouder/ngx-cloud-storage';
|
|
4
|
+
import { StorageImageSettings, CloudStorageData } from '@dataclouder/ngx-cloud-storage';
|
|
5
5
|
import { ConversationType, TextEngines } from '../../models/conversation-enums';
|
|
6
6
|
import { EAccountsPlatform, IAgentCard, ConversationEvents } from '../../models/agent.models';
|
|
7
7
|
import * as i0 from "@angular/core";
|
|
@@ -111,6 +111,7 @@ export declare class DCAgentCardFormComponent implements OnInit {
|
|
|
111
111
|
generateMainImage(): Promise<void>;
|
|
112
112
|
openVoiceSelector(primary?: boolean): void;
|
|
113
113
|
openConversationTypeDialog(): void;
|
|
114
|
+
onMotionUploaded(event: CloudStorageData): Promise<void>;
|
|
114
115
|
static ɵfac: i0.ɵɵFactoryDeclaration<DCAgentCardFormComponent, never>;
|
|
115
116
|
static ɵcmp: i0.ɵɵComponentDeclaration<DCAgentCardFormComponent, "dc-agent-form", never, { "storageSettings": { "alias": "storageSettings"; "required": false; "isSignal": true; }; "bannerImgSettings": { "alias": "bannerImgSettings"; "required": false; "isSignal": true; }; "imageStorageSettings": { "alias": "imageStorageSettings"; "required": false; "isSignal": true; }; }, { "onImageLoaded": "onImageLoaded"; "onSave": "onSave"; "onGoDetails": "onGoDetails"; "onTranslate": "onTranslate"; }, never, never, true, never>;
|
|
116
117
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { EventEmitter } from '@angular/core';
|
|
2
|
-
import { DoActionFormGroup } from '../form-group.utils';
|
|
2
|
+
import { DoActionFormGroup, EDoActionType } from '../form-group.utils';
|
|
3
3
|
import { SystemPromptType } from '../form-group.utils';
|
|
4
4
|
import * as i0 from "@angular/core";
|
|
5
5
|
export declare class DcDoActionFormComponent {
|
|
@@ -16,8 +16,9 @@ export declare class DcDoActionFormComponent {
|
|
|
16
16
|
}>;
|
|
17
17
|
doActionTypeOptions: {
|
|
18
18
|
label: string;
|
|
19
|
-
value:
|
|
19
|
+
value: EDoActionType;
|
|
20
20
|
}[];
|
|
21
|
+
EDoActionType: typeof EDoActionType;
|
|
21
22
|
onRemoveItem(): void;
|
|
22
23
|
static ɵfac: i0.ɵɵFactoryDeclaration<DcDoActionFormComponent, never>;
|
|
23
24
|
static ɵcmp: i0.ɵɵComponentDeclaration<DcDoActionFormComponent, "dc-do-action-form", never, { "formGroup": { "alias": "formGroup"; "required": true; }; "conditionIndex": { "alias": "conditionIndex"; "required": true; }; "doItemIndex": { "alias": "doItemIndex"; "required": true; }; "systemPromptTypeOptions": { "alias": "systemPromptTypeOptions"; "required": true; }; }, { "removeItem": "removeItem"; }, never, never, true, never>;
|
|
@@ -17,7 +17,7 @@ export declare class DcDynamicConditionsFormComponent {
|
|
|
17
17
|
getDoArray(conditionIndex: number): FormArray<DoActionFormGroup>;
|
|
18
18
|
getDoControls(conditionIndex: number): AbstractControl[];
|
|
19
19
|
getDoItemFormGroup(conditionIndex: number, doItemIndex: number): DoActionFormGroup;
|
|
20
|
-
|
|
20
|
+
addDoControl(doArray: FormArray<DoActionFormGroup>): void;
|
|
21
21
|
removeDoItem(conditionIndex: number, doItemIndex: number): void;
|
|
22
22
|
getFormControl(control: AbstractControl | null | undefined): FormControl;
|
|
23
23
|
static ɵfac: i0.ɵɵFactoryDeclaration<DcDynamicConditionsFormComponent, never>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { CloudStorageData } from '@dataclouder/ngx-cloud-storage';
|
|
1
|
+
import { CloudStorageData, ImgStorageData } from '@dataclouder/ngx-cloud-storage';
|
|
2
2
|
import { AudioSpeed, ConversationType, TextEngines } from './conversation-enums';
|
|
3
3
|
import { IAIModel, EModelQuality } from '@dataclouder/ngx-core';
|
|
4
4
|
import { EDoActionType, SystemPromptType } from '../components/dc-agent-form/form-group.utils';
|
|
@@ -56,7 +56,6 @@ export interface IConversationSettings {
|
|
|
56
56
|
secondaryVoice?: string;
|
|
57
57
|
repeatRecording?: boolean;
|
|
58
58
|
model?: IAIModel;
|
|
59
|
-
modelQuality?: EModelQuality;
|
|
60
59
|
}
|
|
61
60
|
export type IConversationSettingsDTO = Partial<IConversationSettings> & {
|
|
62
61
|
returnJson?: boolean;
|
|
@@ -67,9 +66,10 @@ export interface IAgentResponseDTO {
|
|
|
67
66
|
metadata: any;
|
|
68
67
|
}
|
|
69
68
|
export interface IAgentAssets {
|
|
70
|
-
image?:
|
|
71
|
-
|
|
72
|
-
|
|
69
|
+
image?: ImgStorageData;
|
|
70
|
+
motion?: CloudStorageData;
|
|
71
|
+
bannerImg?: ImgStorageData;
|
|
72
|
+
stickers?: Array<ImgStorageData>;
|
|
73
73
|
}
|
|
74
74
|
export declare enum EntityWhat {
|
|
75
75
|
Goal = "goal",
|
|
@@ -122,7 +122,7 @@ export interface IAgentCard {
|
|
|
122
122
|
description?: string;
|
|
123
123
|
lang?: string;
|
|
124
124
|
assets?: IAgentAssets;
|
|
125
|
-
image?:
|
|
125
|
+
image?: ImgStorageData;
|
|
126
126
|
characterCard?: ICharacterCardDC;
|
|
127
127
|
conversationSettings?: IConversationSettings;
|
|
128
128
|
metaApp?: IAgentMetadata;
|
|
@@ -5,7 +5,7 @@ import { ChatUserSettings, FiltersConfig, IFilterQueryResponse } from '@dataclou
|
|
|
5
5
|
export declare const CONVERSATION_AI_TOKEN: InjectionToken<AgentCardsAbstractService>;
|
|
6
6
|
export declare abstract class AgentCardsAbstractService {
|
|
7
7
|
abstract callChatCompletion(conversation: IConversationSettingsDTO): Promise<IAgentResponseDTO>;
|
|
8
|
-
abstract
|
|
8
|
+
abstract findAgentCardByID(id: string): Promise<IAgentCard>;
|
|
9
9
|
abstract filterConversationCards(filters: FiltersConfig): Promise<{
|
|
10
10
|
rows: IAgentCard[];
|
|
11
11
|
count: number;
|
|
@@ -14,8 +14,9 @@ export declare abstract class AgentCardsAbstractService {
|
|
|
14
14
|
abstract getAllConversationCards(): Promise<IAgentCard[]>;
|
|
15
15
|
abstract findFilteredAgentCards(paginator: FiltersConfig): Promise<IFilterQueryResponse<IAgentCard>>;
|
|
16
16
|
abstract findAgentCardByTitle(title: string): Promise<IAgentCard>;
|
|
17
|
-
abstract
|
|
18
|
-
abstract
|
|
17
|
+
abstract saveAgentCard(conversation: IAgentCard): Promise<IAgentCard>;
|
|
18
|
+
abstract partialUpdateAgentCard(partialAgentCard: IAgentCard): Promise<IAgentCard>;
|
|
19
|
+
abstract deleteAgentCard(id: string): Promise<IAgentCard>;
|
|
19
20
|
abstract getTextAudioFile(tts: TTSRequest): Promise<AudioGenerated>;
|
|
20
21
|
abstract getConversationUserChatSettings(): Promise<ChatUserSettings>;
|
|
21
22
|
abstract getListModels(provider: string): Promise<ModelName[]>;
|
|
@@ -19,7 +19,7 @@ export declare class ConversationService {
|
|
|
19
19
|
private isThinkingSignal;
|
|
20
20
|
private conversationSettingsState;
|
|
21
21
|
private isDestroyedSignal;
|
|
22
|
-
micStatusSignal: import("@angular/core").WritableSignal<"
|
|
22
|
+
micStatusSignal: import("@angular/core").WritableSignal<"ready" | "recording" | "listening" | "initializing" | "inactive" | "error" | "paused">;
|
|
23
23
|
currentAudioStatus: import("@angular/core").WritableSignal<{
|
|
24
24
|
message: MessageContent;
|
|
25
25
|
completed: boolean;
|
|
@@ -3,17 +3,18 @@ import { IConversationSettingsDTO, IAgentResponseDTO, IAgentCard, TTSRequest, Au
|
|
|
3
3
|
import { FiltersConfig, IFilterQueryResponse, ChatUserSettings, IAIModel } from '@dataclouder/ngx-core';
|
|
4
4
|
import * as i0 from "@angular/core";
|
|
5
5
|
export declare class DefaultAgentCardsService implements AgentCardsAbstractService {
|
|
6
|
+
partialUpdateAgentCard(agentCard: IAgentCard): Promise<IAgentCard>;
|
|
6
7
|
private httpService;
|
|
7
8
|
generateMainImage(idCard: string): Promise<any>;
|
|
8
9
|
completeAgentCard(idCard: string): Promise<any>;
|
|
9
10
|
callChatCompletion(conversation: IConversationSettingsDTO): Promise<IAgentResponseDTO>;
|
|
10
|
-
|
|
11
|
+
findAgentCardByID(id: string): Promise<IAgentCard>;
|
|
11
12
|
filterConversationCards(filters: FiltersConfig): Promise<IFilterQueryResponse<IAgentCard>>;
|
|
12
13
|
getAllConversationCards(): Promise<IAgentCard[]>;
|
|
13
14
|
findFilteredAgentCards(paginator: FiltersConfig): Promise<IFilterQueryResponse<IAgentCard>>;
|
|
14
15
|
findAgentCardByTitle(title: string): Promise<IAgentCard>;
|
|
15
|
-
|
|
16
|
-
|
|
16
|
+
saveAgentCard(conversation: IAgentCard): Promise<IAgentCard>;
|
|
17
|
+
deleteAgentCard(id: string): Promise<IAgentCard>;
|
|
17
18
|
getTextAudioFile(tts: TTSRequest): Promise<AudioGenerated>;
|
|
18
19
|
getConversationUserChatSettings(): Promise<ChatUserSettings>;
|
|
19
20
|
getListModels(provider: string): Promise<ModelName[]>;
|
|
@@ -5,7 +5,7 @@ export declare class DynamicFlowService {
|
|
|
5
5
|
conversationFlowState: import("@angular/core").WritableSignal<IConversationFlow>;
|
|
6
6
|
setConversationFlow(conversationFlow: IConversationFlow): void;
|
|
7
7
|
changePrompt(): void;
|
|
8
|
-
|
|
8
|
+
applyConditionChange(condition: IDynamicCondition): void;
|
|
9
9
|
doActionPrompt(action: DoAction): void;
|
|
10
10
|
removeSystemPrompts(): void;
|
|
11
11
|
checkDynamicConditions(previousScore: number, currentScore: number): void;
|