class Intent::PatternMatchingModel
class Intent::PatternMatchingModel
: public Intent::LanguageUnderstandingModel
Represents a pattern matching model used for intent recognition.
Members
Intents
Syntax: public std::vector< PatternMatchingIntent > Intents;
This container of Intents is used to define all the Intents this model will look for.
Entities
Syntax: public std::vector< PatternMatchingEntity > Entities;
This container of Intents is used to define all the Intents this model will look for.
GetModelId
Syntax: public inline virtual std::string GetModelId ( ) const;
Returns id for this model.
Returns
A string representing the id of this model.
FromModelId
Syntax: public inline static std::shared_ptr< PatternMatchingModel > FromModelId ( const std::string & modelId );
Creates a pattern matching model using the specified model ID.
Parameters
modelId
A string that represents a unique Id for this model.
Returns
A shared pointer to pattern matching model.
FromJSONFile
Syntax: public inline static std::shared_ptr< PatternMatchingModel > FromJSONFile ( const std::string & filepath );
Creates a pattern matching model using the specified .json file. This should follow the Microsoft LUIS JSON export schema.
Parameters
filepath
A string that representing the path to a '.json' file.
Returns
A shared pointer to pattern matching model.
FromJSONFileStream
Syntax: public inline static std::shared_ptr< PatternMatchingModel > FromJSONFileStream ( std::istream & iStream );
Creates a PatternMatchingModel using the specified istream pointing to an .json file in the LUIS json format. This assumes the stream is already open and has permission to read.
Parameters
iStream
A stream that representing a '.json' file.
Returns
A shared pointer to pattern matching model.