How to find if a word in a sentence is pointing to

2019-06-07 15:34发布

How to find if a word in a sentence is pointing to a city

I live in San Francisco I work in San Jose I was born in New York

Is there a way to find that "San Francisco" is a city in the above sentence.

1条回答
祖国的老花朵
2楼-- · 2019-06-07 16:11

The task of recognising possibly multi-word expressions that reference individuals of various specific types (locations, but also organisations, dates, etc.) is called named-entity recognition (NER).

For a simple task such as yours, existing freely available tools and models are sufficient. You could try the Stanford Named Entity Recognizer, which is free software. Try analysing your sentence using their online demo.

查看更多
登录 后发表回答