Package it.uniroma1.lcl.kb
Interface Sense
-
- All Superinterfaces:
Taggable
- All Known Implementing Classes:
BabelSense
,WordNetSense
public interface Sense extends Taggable
General interface for a sense for aSynset
.- Author:
- navigli
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Deprecated Methods Modifier and Type Method Description String
getFullLemma()
Gets the full lemma of thisSense
(which might include annotations, such as labels in Wikipedia page titles).Collection<BabelGloss>
getGlosses()
Returns theBabelGloss
es associated to thisSense
.it.uniroma1.lcl.jlt.util.Language
getLanguage()
Gets theLanguage
of thisSense
Lemma
getLemma()
Gets the lemma of thisSense
.String
getNormalizedLemma()
Gets the normalized lemma of thisSense
.it.uniroma1.lcl.jlt.util.POS
getPOS()
Gets the part of speech of thisSense
.String
getSimpleLemma()
Deprecated.SenseSource
getSource()
Gets theBabelSenseSource
of thisSense
.BabelSynset
getSynset()
Gets theBabelSynset
thisSense
belongs to.SynsetID
getSynsetID()
Returns the id of theSynset
the sense belongs toboolean
isKeySense()
Returns true if it is a key sensedefault Optional<String>
toURI(ExternalResource resource)
Returns the URI of the sense for a givenExternalResource
-
Methods inherited from interface it.uniroma1.lcl.babelnet.data.Taggable
getTags, getTags, isTaggedAs, isTaggedAs, isTaggedAs
-
-
-
-
Method Detail
-
isKeySense
boolean isKeySense()
Returns true if it is a key sense- Returns:
- true if it is a key sense, false otherwise
-
getFullLemma
String getFullLemma()
Gets the full lemma of thisSense
(which might include annotations, such as labels in Wikipedia page titles). UsegetNormalizedLemma()
to retrieve plain lemmas lower case orgetLemma()
.- Returns:
- the lemma of this
Sense
.
-
getSimpleLemma
@Deprecated String getSimpleLemma()
Deprecated.Gets the simple lemma of thisSense
. This corresponds to the lemma itself, if the lemma comes from WordNet, or the lemma possibly without sense labels (i.e. parentheses) if it comes from Wikipedia.- Returns:
- the simple lemma of this
Sense
.
-
getNormalizedLemma
String getNormalizedLemma()
Gets the normalized lemma of thisSense
. This corresponds to the lower case lemma itself, if the lemma comes from WordNet, or the lower case lemma possibly without sense labels (i.e. parentheses) if it comes from Wikipedia.- Returns:
- the normalized lemma of this
Sense
.
-
getPOS
it.uniroma1.lcl.jlt.util.POS getPOS()
Gets the part of speech of thisSense
.- Returns:
- the part of speech of this
Sense
.
-
getSource
SenseSource getSource()
Gets theBabelSenseSource
of thisSense
.- Returns:
- the
BabelSenseSource
of thisSense
.
-
getLanguage
it.uniroma1.lcl.jlt.util.Language getLanguage()
Gets theLanguage
of thisSense
- Returns:
- the
Language
of thisSense
.
-
getSynset
BabelSynset getSynset()
Gets theBabelSynset
thisSense
belongs to.- Returns:
- the
BabelSynset
of thisSense
.
-
getSynsetID
SynsetID getSynsetID()
Returns the id of theSynset
the sense belongs to- Returns:
- SynsetID the id of the
Synset
the sense belongs to
-
getGlosses
Collection<BabelGloss> getGlosses()
Returns theBabelGloss
es associated to thisSense
.- Returns:
- the
BabelGloss
es of thisSense
-
toURI
default Optional<String> toURI(ExternalResource resource)
Returns the URI of the sense for a givenExternalResource
- Parameters:
resource
- the external resource- Returns:
- the URI to the external resource
-
-