See: Description
Class | Description |
---|---|
SemanticGraph |
Represents a semantic graph of a sentence or document, with IndexedWord
objects for nodes.
|
SemanticGraphEdge |
Represents an edge in the dependency graph.
|
SemanticGraphFactory |
Refactoring of static makers of SemanticGraphs in order to simplify
the SemanticGraph class.
|
SemanticGraphFormatter |
Defines a class for pretty-printing SemanticGraphs.
|
Enum | Description |
---|---|
SemanticGraph.OutputFormat | |
SemanticGraphFactory.Mode |
This package provides a representation of dependency graphs (normally the collapsed Stanford Dependencies representation) as a graph (backed by the jgrapht graph library.
To create a typed dependency graph, a SemanticGraph
from a parse tree,
import edu.stanford.nlp.trees.semgraph.*; ... Tree treeParse = processSentence(sentence); SemanticGraph depGraph = SemanticGraphFactory.allTypedDependencies(treeParse, true);