This repository contains code for a language detection model based on machine learning. The model is built using scikit-learn and deployed as a FastAPI web application using Docker.
- Predicts the language of a given text using a pre-trained language detection model.
- Supports multiple languages including Arabic, Danish, Dutch, English, French, German, Greek, Hindi, Italian, Kannada, Malayalam, Portuguese, Russian, Spanish, Swedish, Tamil, and Turkish.
- Provides a user-friendly API interface for making predictions.
To run the language detection model locally, follow these steps:
- Clone this repository:
git clone https://github.com/Hk669/language-detection-model.git
- Install Docker on your machine: https://docs.docker.com/get-docker/
- Build the Docker image:
docker build -t language-detection-app .
- Run the Docker container:
docker run -p 80:80 language-detection-app
- Access the API at
http://localhost:80
orhttp://127.0.0.1:80
Make a POST request to the /predict
endpoint with the following JSON payload:
Contributions are welcome! If you find any issues or have suggestions for improvement, please open an issue or submit a pull request.
This project is licensed under the MIT License.