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

标签 java stanford-nlp text-processing

我在看斯坦福NER并考虑使用 JAVA Apis it 从文本文档中提取邮政地址。该文档可以是任何包含邮政地址部分的文档,例如水电费、电费。

所以我的想法是,

  1. 使用 LOCATION 和其他原始命名实体将邮政地址定义为命名实体。
  2. 定义分割和其他子流程。

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

最佳答案

需要说明的是:所有功劳归功于 Raj Vardhan(和 John Bauer),他们在 [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.

不确定这是否对您有帮助,但我想提一下以防万一。同样,任何荣誉都应归功于 Raj Vardhan(和 John Bauer)。

关于java - 使用 Stanford NER 从文本文档中提取地址?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/34408340/

相关文章:

Java EE 对比。 Java 编程

java - 如何从字符串(不是斯坦福解析器的输出)形成一棵树(改编自斯坦福解析器)

java - 无法转换 opennlp Parse 的结果

nlp - 如何在 stanford CoreNLP 中使用实体提及注释器?

linux - 使用 bash 根据逗号分隔文件中的列标题提取值

ruby - 如何使用 Ruby 从包含撇号的字符串创建文件夹?

Java在操作系统中执行命令

java - 将 Youtube Data API V3 视频持续时间转换为 hh :mm:ss format in java?

python - 将 trigrams、bigrams 和 unigrams 与文本匹配;如果 unigram 或 bigram 是已经匹配的 trigram 的子串,则通过; Python

java - Android - 从 0,0 开始获取触摸位置