{"id":25077725,"url":"https://github.com/dagiteferi/sales-prediction-model","last_synced_at":"2026-02-08T19:01:38.219Z","repository":{"id":270611715,"uuid":"910796702","full_name":"dagiteferi/sales-Prediction-model","owner":"dagiteferi","description":"An end-to-end machine learning solution for forecasting sales across all stores of Rossmann Pharmaceuticals in several cities, six weeks ahead. Accurate sales predictions will assist the finance team in better planning and decision-making","archived":false,"fork":false,"pushed_at":"2025-01-15T04:51:51.000Z","size":785,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-01T00:48:18.638Z","etag":null,"topics":["flask","ml","salce-prediction","xgboost"],"latest_commit_sha":null,"homepage":"https://sales-prediction-model.vercel.app","language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dagiteferi.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-01-01T13:06:55.000Z","updated_at":"2025-01-30T11:51:46.000Z","dependencies_parsed_at":null,"dependency_job_id":"4b7323b4-1e39-412a-b678-1932a0471b94","html_url":"https://github.com/dagiteferi/sales-Prediction-model","commit_stats":null,"previous_names":["dagiteferi/sales-prediction-model"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dagiteferi%2Fsales-Prediction-model","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dagiteferi%2Fsales-Prediction-model/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dagiteferi%2Fsales-Prediction-model/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dagiteferi%2Fsales-Prediction-model/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dagiteferi","download_url":"https://codeload.github.com/dagiteferi/sales-Prediction-model/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253786371,"owners_count":21964149,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["flask","ml","salce-prediction","xgboost"],"created_at":"2025-02-07T02:35:56.494Z","updated_at":"2026-02-08T19:01:33.190Z","avatar_url":"https://github.com/dagiteferi.png","language":"Jupyter Notebook","funding_links":[],"categories":[],"sub_categories":[],"readme":"# sales-Prediction-model\n\n## Table of Contents\n\n1. [Project Objectives](#project-objectives)\n   1. [Data Cleaning and Preparation](#data-cleaning-and-preparation)\n   2. [Exploratory Data Analysis (EDA)](#exploratory-data-analysis-eda)\n   3. [Sales Prediction](#sales-prediction)\n   4. [Deep Learning](#deep-learning)\n   5. [Model Deployment](#model-deployment)\n2. [Data and Features](#data-and-features)\n3. [Tasks Breakdown](#tasks-breakdown)\n   1. [Task 1 - Exploration of Customer Purchasing Behavior](#task-1---exploration-of-customer-purchasing-behavior)\n   2. [Task 2 - Prediction of Store Sales](#task-2---prediction-of-store-sales)\n      1. [Preprocessing](#preprocessing)\n      2. [Building Models with sklearn Pipelines](#building-models-with-sklearn-pipelines)\n      3. [Choosing a Loss Function](#choosing-a-loss-function)\n      4. [Post Prediction Analysis](#post-prediction-analysis)\n      5. [Serialize Models](#serialize-models)\n      6. [Deep Learning Model](#deep-learning-model)\n   3. [Task 3 - Model Serving API Call](#task-3---model-serving-api-call)\n\n### Overview\n\nThis project aims to develop an end-to-end machine learning solution for forecasting sales across all stores of Rossmann Pharmaceuticals in several cities, six weeks ahead. Accurate sales predictions will assist the finance team in better planning and decision-making.\n\n## Project Objectives\n\n### Data Cleaning and Preparation:\n\nHandle outliers, missing data, and preprocess the dataset for analysis.\n\n### Exploratory Data Analysis (EDA):\n\nAnalyze and visualize data to understand customer purchasing behavior and the impact of various factors on sales.\n\n### Sales Prediction:\n\nBuild and fine-tune machine learning models using sklearn pipelines and tree-based algorithms to forecast daily sales.\n\n### Deep Learning:\n\nImplement a Long Short-Term Memory (LSTM) model to improve prediction accuracy.\n\n### Model Deployment:\n\nCreate a REST API to serve the trained models for real-time predictions using frameworks like Flask, FastAPI, or Django REST framework.\n\n## Data and Features\n\nThe dataset includes fields such as store IDs, sales, customers, indicators for store openings, holidays, promotions, assortment levels, competition details, and more. Key features for predicting sales include promotions, holidays, seasonality, competition, locality, and customer numbers.\n\n## Tasks Breakdown\n\n### Task 1 - Exploration of Customer Purchasing Behavior\n\n. Data cleaning and preparation.\n\n. Exploratory Data Analysis (EDA) with visualizations.\n\n. Addressing key questions about promotions, holiday sales behavior, seasonal patterns, and more.\n\n### Task 2 - Prediction of Store Sales\n\n#### Preprocessing:\n\nConvert non-numeric columns, handle NaN values, and generate new features from datetime columns.\n\n#### Building Models with sklearn Pipelines:\n\nStart with tree-based algorithms like Random Forests.\n\n#### Choosing a Loss Function:\n\nSelect and justify the appropriate loss function.\n\n#### Post Prediction Analysis:\nExplore feature importance and estimate confidence intervals.\n\n#### Serialize Models:\nSave models with timestamps for tracking.\n\n#### Deep Learning Model:\n\nImplement an LSTM model using TensorFlow or PyTorch.\n\n### Task 3 - Model Serving API Call\n\nCreate a REST API for real-time predictions.\n\nLoad the serialized model and define API endpoints.\n\nPreprocess input data, make predictions, and format the results.\n\nDeploy the API to a web server or cloud platform.\n\n## Setup\n\nTo get started with this project, follow these steps:\n\n1. **Clone the repository:**\n\n   ```sh\n   git clone https://github.com/dagiteferi/sales-Prediction-model.git\n   cd sales-Prediction-model\n   ```\n\n2. **Create and activate a virtual environment:**\n\n   ```sh\n   python -m venv env\n   source env/bin/activate  # On Windows use `env\\Scripts\\activate`\n   ```\n\n3. **Install the required packages:**\n\n   ```sh\n   pip install -r requirements.txt\n   ```\n\n4. **Run the Jupyter Notebook:**\n\n   ```sh\n   jupyter notebook\n   ```\n\n5. **Run the Flask application:**\n   ```sh\n   flask run\n   ```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdagiteferi%2Fsales-prediction-model","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdagiteferi%2Fsales-prediction-model","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdagiteferi%2Fsales-prediction-model/lists"}