@bavard/agent-config
Advanced tools
Comparing version 0.1.44 to 0.1.45
@@ -40,2 +40,3 @@ import { ESentiment, ITagValue } from "../../dialogue-manager/services"; | ||
attachments?: IFileAttachment[]; | ||
gifUrl?: string; | ||
} | ||
@@ -42,0 +43,0 @@ export interface IUserEmailAction extends IUserActionBase { |
@@ -16,2 +16,3 @@ import { BaseUserAction, IBaseUserActionOptions } from "./base-action"; | ||
attachments?: IFileAttachment[]; | ||
gifUrl?: string; | ||
} | ||
@@ -29,2 +30,3 @@ export declare class UserUtteranceAction extends BaseUserAction { | ||
attachments?: IFileAttachment[]; | ||
gifUrl?: string; | ||
constructor(options: IOptions); | ||
@@ -31,0 +33,0 @@ toJsonObj(): IUserUtteranceAction; |
@@ -26,2 +26,3 @@ "use strict"; | ||
this.attachments = options.attachments; | ||
this.gifUrl = options.gifUrl; | ||
} | ||
@@ -45,2 +46,3 @@ toJsonObj() { | ||
attachments: (_a = this.attachments) === null || _a === void 0 ? void 0 : _a.slice(0, constants_1.MAX_FILE_ATTACHMENTS), | ||
gifUrl: this.gifUrl, | ||
}; | ||
@@ -62,2 +64,3 @@ } | ||
attachments: userAction.attachments, | ||
gifUrl: userAction.gifUrl, | ||
name: userAction.name, | ||
@@ -64,0 +67,0 @@ nodeId: userAction.nodeId, |
@@ -30,2 +30,3 @@ export declare const UserEmailActionSchema: import("yup/lib/object").default<import("yup/lib/object").Assign<import("yup/lib/object").ObjectShape, { | ||
attachments: any; | ||
gifUrl: import("yup/lib/string").default<string | undefined, import("yup/lib/types").AnyObject, string | undefined>; | ||
}>, import("yup/lib/object").AnyObject, import("yup/lib/object").TypeOfShape<import("yup/lib/object").Assign<import("yup/lib/object").ObjectShape, { | ||
@@ -38,2 +39,3 @@ name: import("yup/lib/string").default<string | undefined, import("yup/lib/types").AnyObject, string | undefined>; | ||
attachments: any; | ||
gifUrl: import("yup/lib/string").default<string | undefined, import("yup/lib/types").AnyObject, string | undefined>; | ||
}>>, import("yup/lib/object").AssertsShape<import("yup/lib/object").Assign<import("yup/lib/object").ObjectShape, { | ||
@@ -46,2 +48,3 @@ name: import("yup/lib/string").default<string | undefined, import("yup/lib/types").AnyObject, string | undefined>; | ||
attachments: any; | ||
gifUrl: import("yup/lib/string").default<string | undefined, import("yup/lib/types").AnyObject, string | undefined>; | ||
}>>>; | ||
@@ -48,0 +51,0 @@ export declare const UserOptionActionSchema: import("yup/lib/object").default<import("yup/lib/object").Assign<import("yup/lib/object").ObjectShape, { |
@@ -21,2 +21,3 @@ "use strict"; | ||
attachments: (0, yup_1.array)().of((0, yup_1.object)()).max(3).optional(), | ||
gifUrl: (0, yup_1.string)().optional(), | ||
}); | ||
@@ -23,0 +24,0 @@ exports.UserOptionActionSchema = (0, yup_1.object)().shape({ |
@@ -37,3 +37,2 @@ import { IIntent, IAgentConfig, IIntentExample, IFallbackStrategy } from "./types"; | ||
intentConfidenceThreshold: number; | ||
intentOODConfidenceThreshold?: number; | ||
/** | ||
@@ -40,0 +39,0 @@ * Knowledge-base predictions with confidence values above this threshold are accepted. |
@@ -47,5 +47,2 @@ "use strict"; | ||
this.intentConfidenceThreshold = constants_1.DEFAULT_INTENT_CONFIDENCE_THRESHOLD; | ||
// TODO: Delete this field once we switch over to using `intentConfidenceThreshold` in CWA. | ||
// Its needed here for now so we know what value it has when setting `intentConfidenceThreshold`. | ||
this.intentOODConfidenceThreshold = undefined; | ||
/** | ||
@@ -637,3 +634,2 @@ * Knowledge-base predictions with confidence values above this threshold are accepted. | ||
intentConfidenceThreshold: this.intentConfidenceThreshold, | ||
intentOODConfidenceThreshold: this.intentOODConfidenceThreshold, | ||
kbConfidenceThreshold: this.kbConfidenceThreshold, | ||
@@ -674,3 +670,2 @@ dpConfidenceThreshold: this.dpConfidenceThreshold, | ||
jsonObj.intentConfidenceThreshold || constants_1.DEFAULT_INTENT_CONFIDENCE_THRESHOLD; | ||
config.intentOODConfidenceThreshold = jsonObj.intentOODConfidenceThreshold; | ||
config.kbConfidenceThreshold = | ||
@@ -677,0 +672,0 @@ jsonObj.kbConfidenceThreshold || constants_1.DEFAULT_KB_CONFIDENCE_THRESHOLD; |
@@ -389,3 +389,3 @@ "use strict"; | ||
: ""} | ||
</div> | ||
@@ -681,3 +681,4 @@ `, | ||
(0, lodash_1.isEmpty)(action.intent) && | ||
(0, lodash_1.isEmpty)(action.attachments)); | ||
(0, lodash_1.isEmpty)(action.attachments) && | ||
(0, lodash_1.isEmpty)(action.gifUrl)); | ||
} | ||
@@ -684,0 +685,0 @@ return false; |
@@ -50,3 +50,2 @@ import { ISlot } from "./slots"; | ||
intentConfidenceThreshold: number; | ||
intentOODConfidenceThreshold?: number; | ||
kbConfidenceThreshold: number; | ||
@@ -53,0 +52,0 @@ dpConfidenceThreshold: number; |
{ | ||
"name": "@bavard/agent-config", | ||
"version": "0.1.44", | ||
"version": "0.1.45", | ||
"description": "Shared code and single source of truth for Bavard data models.", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
544371
8696