🌍 TechieMike Sentiment Translator
A simple Streamlit web app that takes English text, translates it into French, and runs sentiment analysis (Positive / Negative / Neutral) — powered by Hugging Face’s M2M100 and RoBERTa models.
✨ Features
✅ Translate English text → French (default, can extend to other languages).
✅ Detect sentiment (Positive / Negative / Neutral).
✅ Clean and interactive Streamlit UI.
✅ Returns results in neat JSON format.
⚙️ Tech Stack
Streamlit → UI framework.
Hugging Face Transformers → NLP models.
facebook/m2m100_418M → Multilingual translation.
cardiffnlp/twitter-xlm-roberta-base-sentiment → Sentiment analysis.
Python 3.9+
📂 Project Structure . ├── app.py # Streamlit UI ├── translator.py # Translation + Sentiment functions ├── requirements.txt # Python dependencies ├── images/ # Screenshots │ ├── capture1.png │ └── capture2.png └── README.md # Documentation
🚀 Installation & Setup
Clone the repo
git clone https://github.com/techieemike/Sentiment-Language-Translator.git cd Sentiment-Language-Translator
Create a virtual environment (recommended)
python -m venv venv source venv/bin/activate # macOS/Linux venv\Scripts\activate # Windows
Install dependencies
pip install -r requirements.txt
Run the app
streamlit run app.py
or
python -m streamlit run app.py
Open in browser Usually available at 👉 http://localhost:8501/
📝 Example Usage
Input:
I love programming!
Output (JSON):
{ "original_text": "I love programming!", "translated_text": "J'adore la programmation!", "sentiment": "Positive" }
Screenshots
📜 License
This project is licensed under the MIT License – see the LICENSE file for details.
🔮 Future Improvements
Add support for other target languages (not just French).
Allow batch translation & sentiment on multiple sentences.
Export results as CSV/Excel for analysis.
Deploy to Streamlit Cloud / Hugging Face Spaces.
👨💻 Author
Built by Abikale Michael Raymond (TechieMike) ✨
📬 Connect with Me

