Open FLasH3r opened 3 years ago
Looks like this suffers from the same thing as the more popular https://github.com/patrickschur/language-detection
It does a good job with long texts but is borderless useless for short sentences.. getting it wrong at an alarmingly high rate
Still looking for a reliable language detector that works well with short sentences in case anyone finds one please share
ward
Still looking for a reliable language detector that works well with short sentences in case anyone finds one please share
@vesper8 https://github.com/fntlnz/cld2-php-ext works good for my use-cases also with rather short texts. It detects all the above cases as English
I have the following text with the corresponding language as detected by this package (all English) Only the bold text is correct.
besides using
composer install ...
I have done anythingThe text here is just an example, it's from github blog (title of the last 10 posts)
if I do
new \LanguageDetector\LanguageDetector(null,['en']);
it will work, but that is not the goal.the code looks like this: