[
https://issues.apache.org/jira/browse/OPENNLP-176?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16474462#comment-16474462
]
ASF GitHub Bot commented on OPENNLP-176:
----------------------------------------
sarowe commented on issue #114: [WIP] OPENNLP-176: Switch language codes to
ISO-639-3
URL: https://github.com/apache/opennlp/pull/114#issuecomment-388886273
Here's how I handled alpha-3 to alpha-1 conversion for Apache Solr's OpenNLP
language identification integration: from
https://git-wip-us.apache.org/repos/asf?p=lucene-solr.git;a=blob;f=solr/contrib/langid/src/java/org/apache/solr/update/processor/OpenNLPLangDetectUpdateProcessor.java;h=83f4fe4cdaf4ebdbc1e3bda005c8eae4125bb764;hb=refs/heads/master#l72
:
```
private static Map<String,String> make_ISO639_map() {
Map<String,String> map = new HashMap<>();
for (String lang : Locale.getISOLanguages()) {
Locale locale = new Locale(lang);
map.put(locale.getISO3Language(), locale.getLanguage());
}
return map;
}
```
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
> Switch language codes to ISO 639-3 codes
> ----------------------------------------
>
> Key: OPENNLP-176
> URL: https://issues.apache.org/jira/browse/OPENNLP-176
> Project: OpenNLP
> Issue Type: Improvement
> Reporter: Joern Kottmann
> Priority: Major
> Fix For: 1.8.0
>
>
> To cover more languages than with our two letters codes and to make
> understanding the codes easier OpenNLP should use ISO 639-3 codes.
> This change will break backward compatibility and could be done with a bigger
> changes, e.g. for 1.6.0.
> We discussed the switch in this thread:
> http://mail-archives.apache.org/mod_mbox/incubator-opennlp-dev/201105.mbox/%[email protected]%3E
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)