Language detector trained with 12 languages, takes in a text and return the language through API
The languages:
- English: en
- Danish: da
- French: fr
- German: ge
- Hindi: hi
- Italian: it
- Portugeese: po
- Russian: ru
- Spanish: sp
- Sweedish: sw
- Turkish: tu
- Arabic: ar
build the project using docker, and give it a tag "language_detector"
docker build -t language_detector:latest .
run the image built previously using the tag "language_detector"
docker run -p 5005:5005 language_detector:latest
send a text to the model for classification using post request:
requests.post("http://localhost:5005/predict", json={"sender": "amr", "message': "text"})
the reply of the post request containing the detected language
{ "sender": sender, "lang": language }