有 Java 编程相关的问题?

你可以在下面搜索框中键入要查询的问题!

java使用Stanford NER从文本文档中提取地址?

我正在寻找StanfordNER,并考虑使用JavaAPI it从文本文档中提取邮政地址。该文件可以是有邮政地址部分的任何文件,例如水电费账单、电费账单

所以我认为,作为一种方法

  1. 使用位置和其他原语命名实体将邮政地址定义为命名实体
  2. 定义分段和其他子流程

我试图找到一个同样的示例管道(需要哪些详细步骤),以前有人这样做过吗?欢迎提出建议


共 (1) 个答案

  1. # 1 楼答案

    要明确的是:所有的功劳都归于拉吉·瓦尔丹(和约翰·鲍尔),他在[java-nlp-user]邮件列表上有过互动

    拉吉·瓦尔丹(Raj Vardhan)写到了“在一句话中找到街道地址”的工作计划:

    Here is an approach I have thought of:

    1. Find the event-anchor in a sentence
    2. Select outgoing-edges in the SemanticGraph from that event-node with relations such as *"prep-in" *or "prep-at".
    3. IF the dependent value in the relation has POS tag as NNP

    a) Find outgoing-edges from dependent value's node with relations such as "nn"

    b) Connect all such nodes in increasing order of occurrence in the sentence.

    c) PRINT resulting value as Location where the event occurred

    This is obviously with certain assumptions such as direct dependency between the event-anchor and location in a sentence.

    我不确定这是否能帮到你,但我想提一下以防万一。同样,任何功劳都应该归于拉杰·瓦尔丹(和约翰·鲍尔)