NTKeywordSpottingSearch Class Reference
Inherits from | NTSpeechSearch : NSObject |
---|---|
Declared in | NTKeywordSpottingSearch.h NTKeywordSpottingSearch.m |
Other Methods
keywords
Keyword / Threshold pairs
@property (nonatomic, strong, readonly) NSDictionary<NSString*NSNumber*> *keywords
Discussion
Keyword / Threshold pairs
Declared In
NTKeywordSpottingSearch.h
– initWithName:keywords:
Creates new KWS search with the given name and the keywors.
- (instancetype)initWithName:(NSString *)name keywords:(NSDictionary<NSString*,NSNumber*> *)keywords
Parameters
name |
Name |
---|---|
keywords |
Keyword/Threshold pairs |
Return Value
instance
Discussion
Creates new KWS search with the given name and the keywors.
Declared In
NTKeywordSpottingSearch.h
– addKeyword:
Adds a keyword with the default threshold 1. If the keyword already is in the list threshold 1 is set.
- (void)addKeyword:(NSString *)keyword
Parameters
keyword |
Keyword |
---|
Discussion
Adds a keyword with the default threshold 1. If the keyword already is in the list threshold 1 is set.
Declared In
NTKeywordSpottingSearch.h
– addKeyword:withThreshold:
Adds the keyword with the given threshold. If the keyword already is in the list the new threshold is set.
- (void)addKeyword:(NSString *)keyword withThreshold:(double)threshold
Parameters
keyword |
Keyword |
---|---|
threshold |
Threshold |
Discussion
Adds the keyword with the given threshold. If the keyword already is in the list the new threshold is set.
Declared In
NTKeywordSpottingSearch.h
– addKeywords:
Add keywords from array with default threshold 1. Same as calling addKeyword for all keywords in the array.
- (void)addKeywords:(NSArray<NSString*> *)keywords
Parameters
keywords |
List of keywords |
---|
Discussion
Add keywords from array with default threshold 1. Same as calling addKeyword for all keywords in the array.
Declared In
NTKeywordSpottingSearch.h
– addKeywordsFromDictionary:
Add keywords with thresholds from dictionary. Same as calling addKeyword:withThreshold for all pairs in the dictionary.
- (void)addKeywordsFromDictionary:(NSDictionary<NSString*,NSNumber*> *)keywords
Parameters
keywords |
Keyword/Threshold pairs |
---|
Discussion
Add keywords with thresholds from dictionary. Same as calling addKeyword:withThreshold for all pairs in the dictionary.
Declared In
NTKeywordSpottingSearch.h
– removeKeyword:
Removes the given keyword.
- (void)removeKeyword:(NSString *)keyword
Parameters
keyword |
Keyword to remove |
---|
Discussion
Removes the given keyword.
Declared In
NTKeywordSpottingSearch.h
+ parseKeywordsFromFileAtPath:
Parses keywords and optionaly thresholds from file
+ (NSDictionary<NSString*,NSNumber*> *)parseKeywordsFromFileAtPath:(NSString *)path
Parameters
path |
Path |
---|
Return Value
keyword/threshold pairs
Declared In
NTKeywordSpottingSearch.h
+ searchWithName:keyword:
Create a search with a single keyword.
+ (NTKeywordSpottingSearch *)searchWithName:(NSString *)name keyword:(NSString *)keyword
Parameters
keyword |
Keyword |
---|
Return Value
instance
Discussion
Create a search with a single keyword.
Declared In
NTKeywordSpottingSearch.h
+ searchWithName:keyword:threshold:
Create a search with a single keyword and a threshold.
+ (NTKeywordSpottingSearch *)searchWithName:(NSString *)name keyword:(NSString *)keyword threshold:(double)threshold
Parameters
keyword |
Keyword |
---|---|
threshold |
Threshold |
Return Value
instance
Discussion
Create a search with a single keyword and a threshold.
Declared In
NTKeywordSpottingSearch.h
+ searchWithName:keywordsAndThresholds:
Create a search with keywords and thresholds from a dictionary.
+ (NTKeywordSpottingSearch *)searchWithName:(NSString *)name keywordsAndThresholds:(NSDictionary<NSString*,NSNumber*> *)keywords
Parameters
keywords |
Keyword/Threshold pairs |
---|
Return Value
instance
Discussion
Create a search with keywords and thresholds from a dictionary.
Declared In
NTKeywordSpottingSearch.h
Other Methods
+ parseKeywordsFromString:
+ (NSDictionary<NSString*,NSNumber*> *)parseKeywordsFromString:(NSString *)keywordString