本地计算机上的结果与corenlp.run上的结果不同,但使用相同的注释器
就这个问题: 我在本地机器依赖关系图上看到的结果与在corenlp.run上看到的结果仍然不同。我使用的是3.7.0版本和以下代码:本地计算机上的结果与corenlp.run上的结果不同,但使用相同的注释器,nlp,stanford-nlp,Nlp,Stanford Nlp,就这个问题: 我在本地机器依赖关系图上看到的结果与在corenlp.run上看到的结果仍然不同。我使用的是3.7.0版本和以下代码: Properties props = new Properties(); props.setProperty("annotators", "tokenize,ssplit,pos,lemma,ner,depparse"); StanfordCoreNLP pipeline = new StanfordCoreNLP(props); An
Properties props = new Properties();
props.setProperty("annotators", "tokenize,ssplit,pos,lemma,ner,depparse");
StanfordCoreNLP pipeline = new StanfordCoreNLP(props);
Annotation document = new Annotation(text);
pipeline.annotate(document);
List<CoreMap> sentences = document.get(CoreAnnotations.SentencesAnnotation.class);
CoreMap sentence = sentences.get(0);
graph = sentence.get(SemanticGraphCoreAnnotations.EnhancedPlusPlusDependenciesAnnotation.class);
Properties=newproperties();
props.setProperty(“注释器”、“标记化、ssplit、pos、引理、ner、depparse”);
StanfordCoreNLP管道=新的StanfordCoreNLP(道具);
注释文档=新注释(文本);
管道注释(文件);
列出句子=document.get(coreanotations.SentencesAnnotation.class);
CoreMap语句=语句。获取(0);
graph=句子.get(SemanticGraphCoreAnnotations.EnhancedPlusDependenceAnnotation.class);
你能提供一个例子吗?“ASCL信息服务增长较慢”我的依赖项是:[service/NN->ASCL/NN(复合),service/NN->info/NN(复合),growing/VBG->service/NN(nsubj),growing/VBG->is/VBZ(aux),growing/VBG->sleer/JJR(xcomp)],所以例如growing->sleer is(xcomp),而crenlp.run是(advmod)你能提供一个例子句子吗?“ASCL信息服务增长较慢”我的依赖项是:[service/NN->ASCL/NN(复合),service/NN->info/NN(复合),growing/VBG->service/NN(nsubj),growing/VBG->is/VBZ(aux),growing/VBG->sleer/JJR(xcomp)],所以例如growing->sleer is(xcomp),而crenlp.run是(advmod)