public class SentenceFragment extends Object
| Modifier and Type | Field and Description |
|---|---|
boolean |
assumedTruth
The assumed truth of this fragment; this is relevant for what entailments are supported
|
SemanticGraph |
parseTree
The parse tree for this sentence fragment.
|
double |
score
A score for this fragment.
|
List<CoreLabel> |
words
The words in this sentence fragment (e.g., for use as the gloss of the fragment).
|
| Constructor and Description |
|---|
SentenceFragment(SemanticGraph tree,
boolean assumedTruth,
boolean copy) |
| Modifier and Type | Method and Description |
|---|---|
SentenceFragment |
changeScore(double score)
Changes the score of this fragment in place.
|
boolean |
equals(Object o) |
int |
hashCode() |
int |
length()
The length of this fragment, in words
|
List<CoreLabel> |
paddedWords()
Return the tokens in this fragment, but padded with null so that the index in this
sentence matches the index of the parse tree.
|
String |
toString() |
public final List<CoreLabel> words
public final SemanticGraph parseTree
public final boolean assumedTruth
public double score
public SentenceFragment(SemanticGraph tree, boolean assumedTruth, boolean copy)
public int length()
public SentenceFragment changeScore(double score)
score - The new score of the fragmentpublic List<CoreLabel> paddedWords()