Spaces:
Sleeping
Sleeping
| title: SmartSeg AI | |
| emoji: π€ | |
| colorFrom: blue | |
| colorTo: green | |
| sdk: gradio | |
| sdk_version: 5.9.1 | |
| python_version: 3.11 | |
| app_file: app.py | |
| # π€ SmartSeg AI β Advanced Customer Segmentation Dashboard | |
| SmartSeg AI is a professional machine learning application that uses K-Means clustering to segment customers based on their demographic and spending behavior. It provides real-time predictions and interactive visualizations to help businesses understand their customer base better. | |
| ## π Features | |
| - **K-Means Clustering:** Robust segmentation using industry-standard algorithms. | |
| - **Real-time Prediction:** Instant classification of new customer data. | |
| - **Interactive Dashboards:** Visualized using Plotly and Gradio. | |
| - **PCA Analysis:** 2D projection of high-dimensional data for better cluster visibility. | |
| - **Business Insights:** Actionable advice based on customer segments. | |
| ## π Dataset | |
| The project uses the **Mall Customer Segmentation** dataset, which includes: | |
| - Gender | |
| - Age | |
| - Annual Income (k$) | |
| - Spending Score (1-100) | |
| ## π οΈ Installation & Local Setup | |
| 1. **Clone the repository:** | |
| ```bash | |
| git clone https://huggingface.co/spaces/your-username/smartseg-ai | |
| cd smartseg-ai | |
| ``` | |
| 2. **Install dependencies:** | |
| ```bash | |
| pip install -r requirements.txt | |
| ``` | |
| 3. **Train the model (Optional):** | |
| ```bash | |
| python train.py | |
| ``` | |
| 4. **Run the App:** | |
| ```bash | |
| python app.py | |
| ``` | |
| ## π Project Structure | |
| ```text | |
| smartseg-ai/ | |
| β | |
| βββ data/ | |
| β βββ Mall_Customers.csv # Raw dataset | |
| β βββ clustered_customers.csv # Data with cluster labels | |
| βββ model/ | |
| β βββ kmeans.pkl # Trained K-Means model | |
| β βββ scaler.pkl # StandardScaler object | |
| β βββ label_encoder.pkl # LabelEncoder for Gender | |
| βββ outputs/ | |
| β βββ elbow_plot.png # Elbow method visualization | |
| βββ train.py # Model training script | |
| βββ app.py # Gradio dashboard application | |
| βββ requirements.txt # Python dependencies | |
| βββ README.md # Project documentation | |
| ``` | |
| ## π€ Hugging Face Deployment | |
| The live version of this app is hosted on [Hugging Face Spaces](https://huggingface.co/spaces/mallelamanoj75/SmartSeg-AI). | |
| **View the Live Demo:** [https://huggingface.co/spaces/mallelamanoj75/SmartSeg-AI](https://huggingface.co/spaces/mallelamanoj75/SmartSeg-AI) | |
| ### How to Deploy Your Own | |
| 1. Create a new Space with the **Gradio** SDK. | |
| 2. Upload all files (including `model/` and `data/` directories). | |
| 3. The app will automatically build and run. | |
| ## πΈ Screenshots | |
| *(Add screenshots here after running the app)* | |
| --- | |
| Built with β€οΈ by Manojkumar | |