|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcsli.dialog.app.calo.parse.Phrase
public class Phrase
represents the syntactic and semantic features of a phrase found by the Gemini parser. Includes semantic logical form and parse features.
| Field Summary | |
|---|---|
LFTerm |
LF
|
String |
rule
|
double |
score
|
long |
segment
|
String |
wcn
|
Term |
yield
|
| Constructor Summary | |
|---|---|
Phrase()
|
|
Phrase(double Score,
long Segment,
String Rule,
String Yield,
String LF,
String wcn)
Creates a Phrase with initial values for the Score, Segment, Rule, Yield, and LF fields |
|
| Method Summary | |
|---|---|
long |
getAcousticLengthFeature()
returns the number of words in this phrase (in the yield) |
double |
getAcousticProbabilityFeature()
returns the acoustic probability (as a log probability from 0 - negative infinity) Acoustic probabilities are provided by Decipher, and derived directly from the WCN |
String |
getAgentNounClassFeature()
returns the semantic class for the entity filling the agent thematic role, if any Semantic classes are derived from WordNet synsets |
long |
getEndIndexFeature()
returns the index for the end point of this phrase Indicies are related to indicies in the original WCN, but additional indicies are inserted to allow for contracted forms ("i'll" gets split into "i" and "'ll"). |
double |
getEndPercentageFeature()
returns the end point of the phrase, expressed as a percentage. |
String |
getId()
|
LFTerm |
getLF()
|
Map<String,Object> |
getMap()
|
String |
getNounClassFeature()
returns the semantic class of the head noun for NP and PP phrases Semantic classes are aligned to the corresponding WordNet synsets. |
String |
getNounFeature()
returns the head noun for this NP or PP phrase. |
long |
getNumFilledRolesFeature()
returns the number of thematic roles that are filled in the logical form for this phrase. |
double |
getParseProbabilityFeature()
returns the parseProbability assigned by Gemini. |
String |
getPassiveFeature()
returns "yes" if the this sentence is in the passive voice |
String |
getPhraseTypeFeature()
returns the phrase type of this phrase, one of s, np, vp, pp |
String |
getRule()
|
double |
getScore()
Deprecated. replaced by getAcousticProbabilityFeature() |
long |
getSegment()
|
double |
getSegmentShortFallFeature()
returns the segmentShortFall segmentShortFall is the difference between the acoustic score for this phrase, and the score assigned to the one-best path in the WCN between the same indicies. |
long |
getStartIndexFeature()
sets the index for the start point of this phrase Indicies are related to indicies in the original WCN, but additional indicies are inserted to allow for contracted forms ("i'll" gets split into "i" and "'ll"). |
double |
getStartPercentageFeature()
returns the start point of the phrase, expressed as a percentage. |
String |
getTenseFeature()
return the tense of the phrase, for S and VP phrases, one of past, present, or future. |
String |
getVerbClassFeature()
returns the verb class for main verb of this phrase, if any. |
String |
getVerbFeature()
returns the base form of the main verb for this phrase, if any |
String |
getWcn()
|
Term |
getYield()
Deprecated. replaced by getYieldFeature() |
String |
getYieldFeature()
returns the yield of the phrase, as a String |
boolean |
isNominalizationFeature()
returns true if the the head noun in this noun phrase expresses an event. |
boolean |
isPerfectFeature()
returns true if this phrase has perfect aspect. |
boolean |
isProgressiveFeature()
returns true if this phrase has progressive aspect. |
void |
setAcousticLengthFeature(long acousticLengthFeature)
sets the number of words in this phrase |
void |
setAcousticProbabilityFeature(double acousticProbabilityFeature)
sets the acoustic probability (as a log probability from 0 - negative infinity) Acoustic probabilities are provided by Decipher, and derived directly from the WCN |
void |
setAgentNounClassFeature(String agentNounClassFeature)
sets the semantic class for the entity filling the agent thematic role, if any Semantic classes are derived from WordNet synsets |
void |
setEndIndexFeature(long endIndexFeature)
sets the index for the end point of this phrase Indicies are related to indicies in the original WCN, but additional indicies are inserted to allow for contracted forms ("i'll" gets split into "i" and "'ll"). |
void |
setEndPercentageFeature(double endPercentageFeature)
sets the end point of the phrase, expressed as a percentage. |
void |
setLF(LFTerm lf)
|
void |
setNominalizationFeature(boolean nominalizationFeature)
set to true if the head noun in this noun phrase expresses an event. |
void |
setNounClassFeature(String nounClassFeature)
sets the semantic class of the head noun for NP and PP phrases Semantic classes are aligned to the corresponding WordNet synsets. |
void |
setNounFeature(String nounFeature)
sets the head noun for this NP or PP phrase |
void |
setNumFilledRolesFeature(long numFilledRolesFeature)
sets the number of thematic roles that are filled in the logical form for this phrase |
void |
setParseProbabilityFeature(double parseProbabilityFeature)
sets the parseProbability parseProbabilites are expressed as log probabilities from 0 to negative infinity. |
void |
setPassiveFeature(String passiveFeature)
set to "yes" if this sentence is in the passive voice |
void |
setPerfectFeature(boolean perfectFeature)
set to true if this phrase has perfect aspect. |
void |
setPhraseTypeFeature(String phraseTypeFeature)
sets the phrase type of this phrase, one of s, np, vp, pp |
void |
setProgressiveFeature(boolean progressiveFeature)
set to true if this phrase has progressive aspect. |
void |
setRule(String rule)
|
void |
setScore(double score)
Deprecated. replaced by setAcousticProbabilityFeature(double) |
void |
setSegment(long segment)
|
void |
setSegmentShortFallFeature(double segmentShortFallFeature)
sets the segmentShortFall segmentShortFall is the difference between the acoustic score for this phrase, and the score assigned to the one-best path in the WCN between the same indicies. |
void |
setStartIndexFeature(long startIndexFeature)
sets the index for the start point of this phrase Indicies are related to indicies in the original WCN, but additional indicies are inserted to allow for contracted forms ("i'll" gets split into "i" and "'ll"). |
void |
setStartPercentageFeature(double startPercentageFeature)
sets the start point of the phrase, expressed as a percentage. |
void |
setTenseFeature(String tenseFeature)
set the tense of the phrase, for S and VP phrasees, one of past, present, or future |
void |
setVerbClassFeature(String verbClassFeature)
sets the verb class for main verb of this phrase, if any. |
void |
setVerbFeature(String verbFeature)
set to the base form of the main verb for this phrase, if any |
void |
setWcn(String wcn)
|
void |
setYield(Term yield)
Deprecated. replaced by setYieldFeature(String) |
void |
setYieldFeature(String yieldFeature)
set to the yield of the phrase, as a String |
String |
toPrologString()
Generates a String encoding of key elements of this Phrase as a Prolog Term |
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public double score
public long segment
public String rule
public Term yield
public LFTerm LF
public String wcn
| Constructor Detail |
|---|
public Phrase(double Score,
long Segment,
String Rule,
String Yield,
String LF,
String wcn)
Score - -
the acoustic probability (log prob) assigned by Decipher for this phraseSegment - -
an encoding of the span (from-to) of this phraseRule - -
the name of the syntactic rule for the top-level non-terminal of this phraseYield - -
the word string that makes up this phraseLF - -
the full Logical Form for this phrasewcn - -
the wcnpublic Phrase()
| Method Detail |
|---|
public double getScore()
getAcousticProbabilityFeature()
public void setScore(double score)
setAcousticProbabilityFeature(double)
score - The score to set.public long getSegment()
public void setSegment(long segment)
segment - The segment to set.public String getRule()
public void setRule(String rule)
rule - The rule to set.public Term getYield()
getYieldFeature()
public void setYield(Term yield)
setYieldFeature(String)
yield - The yield to set.public LFTerm getLF()
public void setLF(LFTerm lf)
lf - The LogicalForm to set.public String getWcn()
public void setWcn(String wcn)
wcn - The wcn to set.public String toPrologString()
public String toString()
toString in class Objectpublic String getId()
public long getAcousticLengthFeature()
public void setAcousticLengthFeature(long acousticLengthFeature)
acousticLengthFeature - The acousticLengthFeature to set.public double getAcousticProbabilityFeature()
public void setAcousticProbabilityFeature(double acousticProbabilityFeature)
acousticProbabilityFeature - The acousticProbabilityFeature to set.public String getAgentNounClassFeature()
public void setAgentNounClassFeature(String agentNounClassFeature)
agentNounClassFeature - The agentNounClassFeature to set.public long getEndIndexFeature()
public void setEndIndexFeature(long endIndexFeature)
endIndexFeature - The endIndexFeature to set.public double getEndPercentageFeature()
public void setEndPercentageFeature(double endPercentageFeature)
endPercentageFeature - The endPercentageFeature to set.public boolean isNominalizationFeature()
public void setNominalizationFeature(boolean nominalizationFeature)
nominalizationFeature - The nominalizationFeature to set.public String getNounClassFeature()
public void setNounClassFeature(String nounClassFeature)
nounClassFeature - The nounClassFeature to set.public String getNounFeature()
public void setNounFeature(String nounFeature)
nounFeature - The nounFeature to set.public long getNumFilledRolesFeature()
public void setNumFilledRolesFeature(long numFilledRolesFeature)
numFilledRolesFeature - The numFilledRolesFeature to set.public double getParseProbabilityFeature()
public void setParseProbabilityFeature(double parseProbabilityFeature)
parseProbabilityFeature - The parseProbabilityFeature to set.public String getPassiveFeature()
public void setPassiveFeature(String passiveFeature)
passiveFeature - The passiveFeature to set.public boolean isPerfectFeature()
public void setPerfectFeature(boolean perfectFeature)
perfectFeature - The perfectFeature to set.public String getPhraseTypeFeature()
public void setPhraseTypeFeature(String phraseTypeFeature)
phraseTypeFeature - The phraseTypeFeature to set.public boolean isProgressiveFeature()
public void setProgressiveFeature(boolean progressiveFeature)
progressiveFeature - The progressiveFeature to set.public double getSegmentShortFallFeature()
public void setSegmentShortFallFeature(double segmentShortFallFeature)
segmentShortFallFeature - The segmentShortFallFeature to set.public long getStartIndexFeature()
public void setStartIndexFeature(long startIndexFeature)
startIndexFeature - The startIndexFeature to set.public double getStartPercentageFeature()
public void setStartPercentageFeature(double startPercentageFeature)
startPercentageFeature - The startPercentageFeature to set.public String getTenseFeature()
public void setTenseFeature(String tenseFeature)
tenseFeature - The tenseFeature to set.public String getVerbClassFeature()
public void setVerbClassFeature(String verbClassFeature)
verbClassFeature - The verbClassFeature to set.public String getVerbFeature()
public void setVerbFeature(String verbFeature)
verbFeature - The verbFeature to set.public String getYieldFeature()
public void setYieldFeature(String yieldFeature)
yieldFeature - The yieldFeature to set.public Map<String,Object> getMap()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||