Skip to content

word1.3 Word类的getPartOfSpeech()方法始终返回null #76

Description

@CBM1014

word版本1.3
复现可以试试下面的代码。

String msg = "今晚不能摸鱼了,要好好努力哦";
List<Word> words = WordSegmenter.segWithStopWords(msg);
            StringBuilder sb = new StringBuilder("你刚才说的词有:");
            for(Word x:words){
                sb.append(x.toString()+"("+x.getPartOfSpeech()+"),");
            }
System.out.println(sb.toString());

返回的结果是
你刚才说的词有:今晚(null),不能(null),摸鱼(null),了(null),要(null),好好(null),努力(null),哦(null),
不知是使用上还是方法内部出了问题...getPartOfSpeech()方法始终返回了null。

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions