Package com.logicaldoc.ai.nlp
Class TokensDetector
java.lang.Object
com.logicaldoc.core.PersistentObject
com.logicaldoc.ai.AIModel<String,String>
 
com.logicaldoc.ai.nlp.NaturalLanguageModel
com.logicaldoc.ai.nlp.TokensDetector
- All Implemented Interfaces:
- Serializable
An 
NaturalLanguageModel specialized in recognizing tokens inside
 sentences. Must be trained with sentences with token specifications, eg:
 
 I am searching for the document with id <START:docid> 12356897 <END> , please send it me.
Here you go, this is the document <START:docid> 12356897 <END> as per your request.
- Since:
- 9.2
- Author:
- Marco Meschieri - LogicalDOC
- See Also:
- 
Field SummaryFields inherited from class com.logicaldoc.ai.AIModelAIQUERY, AIQUERY_HYPHENFields inherited from class com.logicaldoc.core.PersistentObjectDELETED_CODE_DEFAULT, DELETED_CODE_STRONG, id
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionGets the ordered list of feature namesConcrete implementations must give a prediction from a single sentenceMethods inherited from class com.logicaldoc.ai.nlp.NaturalLanguageModelequals, getCutoff, getLanguage, getNgramMax, getNgramMin, hashCode, setCutoff, setLanguage, setNgramMax, setNgramMinMethods inherited from class com.logicaldoc.ai.AIModelgetDescription, getLabel, getName, getTraining, newModel, query, setDescription, setLabel, setName, setTraining, toString, typesMethods inherited from class com.logicaldoc.core.PersistentObjectgetCreation, getDeleted, getId, getLastModified, getRecordVersion, getTenantId, setCreation, setDeleted, setId, setLastModified, setRecordVersion, setTenantId
- 
Constructor Details- 
TokensDetectorpublic TokensDetector()
- 
TokensDetector
- 
TokensDetector
 
- 
- 
Method Details- 
getFeaturesListDescription copied from class:AIModelGets the ordered list of feature names- Specified by:
- getFeaturesListin class- AIModel<String,- String> 
- Returns:
- list of feature names
 
- 
querypublic QueryResult<String> query(String sentence) throws IOException, com.logicaldoc.core.PersistenceException Description copied from class:NaturalLanguageModelConcrete implementations must give a prediction from a single sentence- Specified by:
- queryin class- NaturalLanguageModel
- Parameters:
- sentence- The sentence to process
- Returns:
- The prediction
- Throws:
- IOException- I/O error
- com.logicaldoc.core.PersistenceException- Error in the data layer
 
 
-