From 60d3a1c2aaa03afd58df34898ca49570280d2344 Mon Sep 17 00:00:00 2001 From: hankcs Date: Sat, 11 Aug 2018 08:47:24 -0400 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=20MaxEntDependencyParser=20f?= =?UTF-8?q?ix=20https://github.com/hankcs/HanLP/issues/914?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/com/hankcs/hanlp/dependency/common/Node.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/hankcs/hanlp/dependency/common/Node.java b/src/main/java/com/hankcs/hanlp/dependency/common/Node.java index 1b55cb168..fb93e035e 100644 --- a/src/main/java/com/hankcs/hanlp/dependency/common/Node.java +++ b/src/main/java/com/hankcs/hanlp/dependency/common/Node.java @@ -25,11 +25,9 @@ */ public class Node { - public final static Node NULL = new Node(new Term(CoNLLWord.NULL.NAME, Nature.n), -1); private final static Map natureConverter = new TreeMap(); static { - NULL.label = "null"; natureConverter.put("begin", "root"); natureConverter.put("bg", "b"); natureConverter.put("e", "y"); @@ -101,6 +99,11 @@ public class Node natureConverter.put("yg", "y"); natureConverter.put("zg", "z"); } + public final static Node NULL = new Node(new Term(CoNLLWord.NULL.NAME, Nature.n), -1); + static + { + NULL.label = "null"; + } public String word; public String compiledWord; public String label;