Package org.apache.tika.parser.ner
Interface NERecogniser
-
- All Known Implementing Classes:
CoreNLPNERecogniser
,GrobidNERecogniser
,MITIENERecogniser
,NLTKNERecogniser
,OpenNLPNameFinder
,OpenNLPNERecogniser
,RegexNERecogniser
public interface NERecogniser
Defines a contract for named entity recogniser. The NER contract includesisAvailable()
,getEntityTypes()
andrecognise( String )
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
DATE
static java.lang.String
LOCATION
static java.lang.String
MISCELLANEOUS
static java.lang.String
MONEY
static java.lang.String
ORGANIZATION
static java.lang.String
PERCENT
static java.lang.String
PERSON
static java.lang.String
TIME
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.Set<java.lang.String>
getEntityTypes()
gets a set of entity types whose names are recognisable by thisboolean
isAvailable()
checks if this Named Entity recogniser is available for servicejava.util.Map<java.lang.String,java.util.Set<java.lang.String>>
recognise(java.lang.String text)
call for name recognition action from text
-
-
-
Field Detail
-
LOCATION
static final java.lang.String LOCATION
- See Also:
- Constant Field Values
-
PERSON
static final java.lang.String PERSON
- See Also:
- Constant Field Values
-
ORGANIZATION
static final java.lang.String ORGANIZATION
- See Also:
- Constant Field Values
-
MISCELLANEOUS
static final java.lang.String MISCELLANEOUS
- See Also:
- Constant Field Values
-
TIME
static final java.lang.String TIME
- See Also:
- Constant Field Values
-
DATE
static final java.lang.String DATE
- See Also:
- Constant Field Values
-
PERCENT
static final java.lang.String PERCENT
- See Also:
- Constant Field Values
-
MONEY
static final java.lang.String MONEY
- See Also:
- Constant Field Values
-
-
Method Detail
-
isAvailable
boolean isAvailable()
checks if this Named Entity recogniser is available for service- Returns:
- true if this recogniser is ready to recognise, false otherwise
-
getEntityTypes
java.util.Set<java.lang.String> getEntityTypes()
gets a set of entity types whose names are recognisable by this- Returns:
- set of entity types/classes
-
recognise
java.util.Map<java.lang.String,java.util.Set<java.lang.String>> recognise(java.lang.String text)
call for name recognition action from text- Parameters:
text
- text with possibly contains names- Returns:
- map of entityType -> set of names
-
-