This is a direct fork from Nakatani Shuyo's language-detection library.