|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectopennlp.tools.parser.AbstractBottomUpParser
opennlp.tools.parser.treeinsert.Parser
public class Parser
Built/attach parser. Nodes are built when their left-most child is encountered. Subsequent children are attached as daughters. Attachment is based on node in the right-frontier of the tree. After each attachment or building, nodes are assesed as either complete or incomplete. Complete nodes are no longer elligable for daughter attachment. Complex modifiers which produce additional node levels of the same type are attached with sister-adjunction. Attachment can not take place higher in the right-frontier than an incomplete node.
Field Summary | |
---|---|
static java.lang.String |
ATTACH_DAUGHTER
Outcome used when a node should be attached as a daughter to another node. |
static java.lang.String |
ATTACH_SISTER
Outcome used when a node should be attached as a sister to another node. |
static java.lang.String |
BUILT
Label used to distinguish build nodes from non-built nodes. |
static java.lang.String |
DONE
Outcome used when a constituent needs an no additional parent node/building. |
static java.lang.String |
NON_ATTACH
Outcome used when a node should not be attached to another node. |
Fields inherited from class opennlp.tools.parser.AbstractBottomUpParser |
---|
COMPLETE, CONT, defaultAdvancePercentage, defaultBeamSize, INC_NODE, INCOMPLETE, OTHER, START, TOK_NODE, TOP_NODE, ZERO |
Constructor Summary | |
---|---|
Parser(AbstractModel buildModel,
AbstractModel attachModel,
AbstractModel checkModel,
POSTagger tagger,
Chunker chunker,
HeadRules headRules)
Deprecated. |
|
Parser(AbstractModel buildModel,
AbstractModel attachModel,
AbstractModel checkModel,
POSTagger tagger,
Chunker chunker,
HeadRules headRules,
int beamSize,
double advancePercentage)
Deprecated. |
|
Parser(ParserModel model)
|
|
Parser(ParserModel model,
int beamSize,
double advancePercentage)
|
Method Summary | |
---|---|
static java.util.List<Parse> |
getRightFrontier(Parse root,
java.util.Set<java.lang.String> punctSet)
Returns the right frontier of the specified parse tree with nodes ordered from deepest to shallowest. |
static void |
main(java.lang.String[] args)
Deprecated. |
static AbstractModel |
train(EventStream es,
int iterations,
int cut)
Deprecated. |
static ParserModel |
train(java.lang.String languageCode,
ObjectStream<Parse> parseSamples,
HeadRules rules,
int iterations,
int cut)
|
Methods inherited from class opennlp.tools.parser.AbstractBottomUpParser |
---|
buildDictionary, collapsePunctuation, parse, parse, setErrorReporting, setParents |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String DONE
public static final java.lang.String ATTACH_SISTER
public static final java.lang.String ATTACH_DAUGHTER
public static final java.lang.String NON_ATTACH
public static final java.lang.String BUILT
Constructor Detail |
---|
public Parser(ParserModel model, int beamSize, double advancePercentage)
public Parser(ParserModel model)
@Deprecated public Parser(AbstractModel buildModel, AbstractModel attachModel, AbstractModel checkModel, POSTagger tagger, Chunker chunker, HeadRules headRules, int beamSize, double advancePercentage)
@Deprecated public Parser(AbstractModel buildModel, AbstractModel attachModel, AbstractModel checkModel, POSTagger tagger, Chunker chunker, HeadRules headRules)
Method Detail |
---|
public static java.util.List<Parse> getRightFrontier(Parse root, java.util.Set<java.lang.String> punctSet)
root
- The root of the parse tree.
public static ParserModel train(java.lang.String languageCode, ObjectStream<Parse> parseSamples, HeadRules rules, int iterations, int cut) throws java.io.IOException
java.io.IOException
@Deprecated public static AbstractModel train(EventStream es, int iterations, int cut) throws java.io.IOException
java.io.IOException
@Deprecated public static void main(java.lang.String[] args) throws java.io.IOException
java.io.IOException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |