【问题标题】:Can't use OLLIE open information extraction method in Stanford Core NLP OpenIE在 Stanford Core NLP OpenIE 中无法使用 OLLIE 开放信息提取方法
【发布时间】:2018-10-10 20:45:36
【问题描述】:

我正在尝试使用 OLLIE 和 Stanford Core NLP 的 OpenIE 工具来提取三元组。

我已经安装了 stanford-corenlp-3.9.1stanford-corenlp-3.9.2 来尝试从文本中提取三元组。

对于 stanford-corenlp-3.9.1

  • 只能使用默认方法提取信息,尽管添加了标志“-format ollie”或“-openie.format ollie”
  • 我用这句话测试过

    有人说巴拉克奥巴马不是在美国出生的。

    应该产生这个:

    (巴拉克·奥巴马;不是出生在;美国)[attrib=有人说]

    这是测试 OpenIE 方法是否确实是 ollie 的示例。但我没有得到三倍。但是,它确实适用于其他句子,但输出是默认方法的输出。

对于 stanford-corenlp-3.9.2

  • 我根本无法提取任何三元组,而是得到了这个错误。

    'java.lang.IllegalArgumentException: annotator "openie" requires annotation "CorefChainAnnotation". The usual requirements for this annotator are: tokenize,ssplit,pos,lemma,depparse,natlog'
    

编辑:

  1. 事实证明,Stanford OpenIE 不支持 OLLIE,并且这些标志只是将输出更改为 OLLIE 的格式。
  2. 能够运行3.9.2版本(见下方回复)。

【问题讨论】:

    标签: nlp stanford-nlp


    【解决方案1】:

    所以,Stanford OpenIE 和 Ollie 不一样;它只是可以选择以类似于 Ollie 格式(技术上是其子集)的格式输出。

    Angeli et al. "Leveraging Linguistic Structure For Open Domain Information Extraction" 中描述了斯坦福 OpenIE 系统。奥利在Mausam et al. "Open Language Learning for Information Extraction" 中描述。

    RE 遗漏的提取:斯坦福的系统将否定和错误陈述建模为一阶现象,它不会提取否定的事实。这是为了避免下游应用程序必须在否定关系和非否定关系之间消除歧义的情况(例如,如果关系处于双重否定上下文中怎么办?)。因此,由于“有人说”修饰语和否定,系统都没有返回任何东西。

    RE 例外:您在注释器列表中缺少 mention,coref 作为注释器。您是从命令行还是从注释管道调用它?如果从命令行,你能包括你用来运行程序的命令吗?

    【讨论】:

    • 感谢您澄清这一点,我一直有一种误解,即斯坦福 OpenIE 提供了 3 种不同的 Open IE 执行方法。
    • 至于 3.9.2,我能够运行它: java -cp "*" edu.stanford.nlp.pipeline.StanfordCoreNLP -annotators tokenize,ssplit,pos,depparse,lemma,natlog ,openie -openie.format ollie
    • 嗯好的,所以对于 3.9.2,您可以添加 -openie.resolve_coref false 或添加 mention,coref 到注释器列表中。希望其中任何一个都可以解决问题!
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2017-07-19
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多