I am struggling with a problem for a while. Suppose you have a collection of typed dependencies (from edu.stanford.nlp.trees.TypedDependency
) and you want to convert them to a tree (from edu.stanford.nlp.trees.Tree
).
For instance:
// Suppose you get the typed dependencies from a grammatical structure object
Collection<TypedDependency> atd = gs.allTypedDependencies();
Tree t = null;
Now, how could I transform the object atd
into a tree (which could be stored in t
)?