Skip to content

Commit fe5420e

Browse files
authored
Merge pull request #624 from Hexastack/fix/nlu-helper-format
fix: nlu format return
2 parents 26c9470 + 43d63cf commit fe5420e

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

api/src/helper/lib/base-nlp-helper.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright © 2024 Hexastack. All rights reserved.
2+
* Copyright © 2025 Hexastack. All rights reserved.
33
*
44
* Licensed under the GNU Affero General Public License v3.0 (AGPLv3) with the following additional terms:
55
* 1. The name "Hexabot" is a trademark of Hexastack. You may not use this name in derivative works without express written permission.
@@ -120,7 +120,10 @@ export default abstract class BaseNlpHelper<
120120
*
121121
* @returns The formatted NLP training set
122122
*/
123-
async format(samples: NlpSampleFull[], entities: NlpEntityFull[]) {
123+
async format(
124+
samples: NlpSampleFull[],
125+
entities: NlpEntityFull[],
126+
): Promise<Record<string, any>[] | Record<string, any>> {
124127
const entityMap = NlpEntity.getEntityMap(entities);
125128
const valueMap = NlpValue.getValueMap(
126129
NlpValue.getValuesFromEntities(entities),

0 commit comments

Comments
 (0)