langdetect icon indicating copy to clipboard operation
langdetect copied to clipboard

detect confidence of a single language

Open negfrequency opened this issue 7 years ago • 1 comments

e.g. If I solely want the confidence of english detect(text,'en') is this possible?. May just fork and add this feature. I realize it is a non-deterministic, possibly softmax output but still extremely useful.

Thanks, Will

negfrequency avatar Sep 05 '17 19:09 negfrequency

Excellent! Probably this path can solve the problem in my issue. Portuguese and Spanish share a lot of words, but langdetect prefers Spanish and it`s common to receive "es" instead of "es" and "pt". Sending the desired language, it can evaluate the dictionary/model and turn back the true information. There is an registered issue #71 not equal, but that could use this idea.

eduamf avatar Apr 22 '20 23:04 eduamf