Python Universe
1.99K subscribers
103 photos
1 video
1 file
55 links
Everything you need to know about Python programming.

Admin: @haraisen
Feedback: @pythontg_feedbackbot
Download Telegram
Language Detection

🔸Langdetect is a re-implementation of Google’s language-detection library from Java to Python, which allows you to determine the input language.

Simply pass your text to the detect() function and it will output the two-letter code of the language for which the model gave the highest confidence score. If you use detect_langs() instead, it will output a list of the top languages that the model has predicted, along with their probabilities.

⚙️Installation
pip install langdetect

🔗GitHub

#langdetect