I have been working on a language detection system. However, in Python, I could not find a package to detect British vs American English.
langdetect library to detect all other options. I also know that langdetect has a possibility to add new languages. However, I also could not make it work too.
I followed to documentation instructions from https://code.google.com/archive/p/language-detection/wikis/Tools.wiki
while trying this command
java -jar lib/langdetect.jar --genprofile-text -l gb-en english.txt
I am getting the following error:
Exception in thread "main" java.lang.NoClassDefFoundError: net/arnx/jsonic/JSONException
I have a
english.txt inside the same folder of lib. (Downloaded from the original source from the above link)
Am I doing something wrong? The documentation seems quite straightforward. (This approach would be my strongest preference, if possible)
I have also checked other libraries like
SpaCy, etc. They detect everything as
Another approach I tried is this: https://stackoverflow.com/a/42373173/7698983
However, this does not seem to be the best option. Does anyone have a solution to this problem?