public class CoordinationTransformer extends Object implements TreeTransformer
DependencyTreeTransformer
)
QPTreeTransformer
)
Constructor and Description |
---|
CoordinationTransformer(HeadFinder hf) |
Modifier and Type | Method and Description |
---|---|
static Tree |
CCtransform(Tree t)
Transforms t if it contains a coordination in a flat structure
|
static void |
main(String[] args) |
static Tree |
removeXOverX(Tree t) |
Tree |
SQflatten(Tree t)
Removes the SQ structure under a WHNP question, such as "Who am I
to judge?".
|
Tree |
transformTree(Tree t)
Transforms t if it contains a coordination in a flat structure (CCtransform)
and transforms UCP (UCPtransform).
|
static Tree |
UCPtransform(Tree t)
Transforms t if it contains an UCP, it will change the UCP tag
into the phrasal tag of the first word of the UCP
(UCP (JJ electronic) (, ,) (NN computer) (CC and) (NN building))
will become
(ADJP (JJ electronic) (, ,) (NN computer) (CC and) (NN building))
|
public CoordinationTransformer(HeadFinder hf)
public Tree transformTree(Tree t)
transformTree
in interface TreeTransformer
t
- a tree to be transformedpublic Tree SQflatten(Tree t)
public static Tree UCPtransform(Tree t)
t
- a tree to be transformedpublic static Tree CCtransform(Tree t)
t
- a tree to be transformedpublic static void main(String[] args)