@botonic/plugin-contentful
Version:
Botonic Plugin Contentful is one of the **[available](https://github.com/hubtype/botonic/tree/master/packages)** plugins for Botonic. **[Contentful](http://www.contentful.com)** is a CMS (Content Management System) which manages contents of a great variet
17 lines (16 loc) • 702 B
TypeScript
import { Locale, MatchType } from '../nlp';
import BotonicPluginContentful from '../plugin';
export type SearchEvaluator = (
/** Starting with 0. Undefined if not found */
matchPosition: number | undefined, numResults: number) => number;
export declare class GroundTruth {
readonly utterance: string;
readonly contentId: string;
constructor(utterance: string, contentId: string);
}
export declare class SearchRegression {
readonly plugin: BotonicPluginContentful;
readonly evaluator: SearchEvaluator;
constructor(plugin: BotonicPluginContentful, evaluator: SearchEvaluator);
run(matchType: MatchType, groundTruths: Iterable<GroundTruth>, locale: Locale): Promise<number>;
}