oc-p07-sentiment-api/README.md
Grégoire Mureau 772e10693d docs: clone HTTPS only, language banner at the top
Public READMEs now expose a single git.gregoiremureau.com clone URL.
The Tailscale SSH form only works on the homelab network and leaked the
NAS address. The language switcher sits right under the title so an
English speaker landing on the French page can leave without reading French.
2026-09-10 14:42:28 +02:00

70 lines
No EOL
2.6 KiB
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Air Paradis Project – Sentiment Analysis
📘 Ce projet est également disponible en [français 🇫🇷](./README.fr.md)
This repository contains the notebooks and source code for the sentiment analysis project on tweets, conducted as part of the OpenClassrooms **"Air Paradis"** program.
**Source of truth** : [Forgejo](https://git.gregoiremureau.com/openclassroom-ai/oc-p07-sentiment-api) (self-hosted). GitHub, when mirrored, is the public shop window.
```bash
git clone https://git.gregoiremureau.com/openclassroom-ai/oc-p07-sentiment-api.git
```
---
## Business Context
The objective is to predict whether a tweet (or short written expression) is perceived as **positive or negative**, in the context of an airline company.
The project is based on the public **Sentiment140** dataset.
---
## Project Description
The project aims to develop a complete sentiment analysis system, including:
- Exploratory analysis of textual data,
- Rigorous comparison of 10+ classification models (classical ML, LSTM + word embeddings, DistilBERT),
- Deployment of a FastAPI REST API exposing the best advanced model (LSTM + Word2Vec),
- Implementation of a complete MLOps pipeline: MLFlow, CI/CD (GitHub Actions), monitoring,
- Local hosting on NAS server to ensure data sovereignty.
📖 **For detailed information on experiments conducted and results obtained, see [docs/blog.md](./docs/blog.md).**
---
## Repository Structure
- `notebooks/`: exploratory analysis and modeling notebooks,
- `deployment/`: FastAPI API code, unit tests, Dockerfile and deployment configuration,
- `docs/`: detailed documentation (blog.md), diagrams, screenshots,
- `presentation/`: project presentation slides (PDF),
- `.github/workflows/`: CI (Forgejo Actions on the homelab runner; same YAML on GitHub),
- `fetch-data.sh`: where to get Sentiment140 (dataset **not** in git).
---
## Model Training
Training phases were primarily conducted on **Google Colab** to leverage GPU resources required for deep learning models.
---
## Usage
Notebooks detail the analysis and training steps.
The API is available in the `deployment/api` folder with Streamlit testing interface.
To test the production API: https://api.gregoiremureau.com/ml/sentiment/
---
## Notes
- The `requirements.txt` files in `notebooks/` come from Google Colab environments and may contain dependencies not optimized for local use.
- The `.env` file, excluded from the repository, contains necessary environment variables (MLFlow, MinIO, alerting configuration).
- Training data: run `./fetch-data.sh` (Sentiment140 is **not** stored in git).
---
**Project completed as part of OpenClassrooms "Data Scientist – Project 7" program**