-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
6 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
package edu.stanford.nlp.pipeline; | ||
import edu.stanford.nlp.util.logging.Redwood; | ||
|
||
import java.util.*; | ||
|
||
|
@@ -20,18 +19,19 @@ | |
import edu.stanford.nlp.util.ArraySet; | ||
import edu.stanford.nlp.util.CoreMap; | ||
import edu.stanford.nlp.util.StringUtils; | ||
import edu.stanford.nlp.util.logging.Redwood; | ||
|
||
/** | ||
* Annotating relations between entities produced by the NER system. | ||
* @author Sonal Gupta ([email protected]) | ||
* | ||
* @author Sonal Gupta ([email protected]) | ||
*/ | ||
|
||
public class RelationExtractorAnnotator implements Annotator { | ||
|
||
/** A logger for this class */ | ||
private static Redwood.RedwoodChannels log = Redwood.channels(RelationExtractorAnnotator.class); | ||
MachineReading mr; | ||
private static final Redwood.RedwoodChannels log = Redwood.channels(RelationExtractorAnnotator.class); | ||
private final MachineReading mr; | ||
private static boolean verbose = false; | ||
|
||
static boolean getVerbose(Properties props) { | ||
|
@@ -128,8 +128,8 @@ public Set<Class<? extends CoreAnnotation>> requirementsSatisfied() { | |
))); | ||
} | ||
|
||
public static void main(String[] args){ | ||
try{ | ||
public static void main(String[] args) { | ||
try { | ||
Properties props = StringUtils.argsToProperties(args); | ||
props.setProperty("annotators", "tokenize,ssplit,lemma,pos,parse,ner"); | ||
StanfordCoreNLP pipeline = new StanfordCoreNLP(); | ||
|