本文介绍了使用Stanford NLP检测语言的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想知道是否可以使用Stanford CoreNLP来检测句子所用的语言?如果是这样,这些算法的精确度如何?

I'm wondering if it is possible to use Stanford CoreNLP to detect which language a sentence is written in? If so, how precise can those algorithms be?

推荐答案

几乎可以确定,斯坦福大学COreNLP目前没有语言标识. '几乎'-因为不存在很难证明.

Almost certainly there is no language identification in Stanford COreNLP at this moment. 'almost' - because nonexistence is much harder to prove.

不过,以下是间接证据:

Nevertheless, below are circumstantial evidences:

  1. 主要页,也没有 CoreNLP页,也没有在常见问题解答(尽管有问题如何在其他语言上运行CoreNLP?")或 2014CoreNLP作者的论文
  2. 结合了多个NLP库的
  3. 工具包括Stanford CoreNLP,请使用另一个lib作为语言标识,例如 DKPro Core ASL ;还其他谈论语言识别和CoreNLP的用户没有提及此功能
  4. CoreNLP的源文件包含Language类,但与语言识别无关-您可以手动检查所有84个出现的语言"单词此处
  1. there is no mention of language identification neither on mainpage, nor CoreNLP page, nor in FAQ (although there isa question 'How do I run CoreNLP on other languages?'), nor in 2014paper of CoreNLP's authors;
  2. tools that combine several NLP libsincluding Stanford CoreNLP use another lib for languageidentification, for example DKPro Core ASL; also otherusers talking about language identification and CoreNLP don't mention this capability
  3. source file of CoreNLP contains Languageclasses, but nothing related to language identification - you cancheck manually for all 84 occurrence of 'language' word here

尝试 TIKA TextCat Java语言检测库(他们报告"53种语言的精度提高了99%").

Try TIKA, or TextCat, or Language Detection Library for Java (they report "99% over precision for 53 languages").

通常,质量取决于输入文本的大小:如果输入文本足够长(例如,至少几个单词并且没有特别选择),则精度可以很好-约为95%.

In general, quality depends on the size of input text: if it is long enough (say, at least several words and not specially chosen), then precision can be pretty good - about 95%.

这篇关于使用Stanford NLP检测语言的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-12 16:21