问题在于专有名词的解析。举个例子: s = "The Night's Watch is a joke to you, is it? Is that what we are, Lannister?以下是示例代码: import spacy[token.lemma_ for token in nlp(s) if not token.is_stop我真的希望Night's Watch被识别为
我使用斯坦福大学CoreNlp进行命名实体识别(NER)。我注意到,在某些情况下,这并不是100%,这是好的,也不令人惊讶。然而,即使单个词命名实体不被识别(即标签是O),它也有标记NNP (专有名词)。例如,给定示例句“纽约的RestautantName是最好的出口”,nerTags()产生的[O, O, O, LOCATION, LOCATION, O, O, O, O, O]只能正确地识别“纽约”这个句子的解析