Skip to content

About

Interactive business intelligence and data analytics dashboard built with Python, Streamlit, Pandas, SQLite, and Plotly.

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Latest commit

ย 

History

2 Commits

Folders and files

NameName
Last commit message
Last commit date
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿ“Š InsightFlow

Smart Business Analytics Platform

InsightFlow is an interactive business analytics platform that allows users to upload sales data, map their columns to the application's standard structure, and generate dashboards, customer insights, product analytics, and downloadable reports.

Open in Streamlit

๐Ÿš€ Live Demo: Go to InsightFlow


๐Ÿ› ๏ธ Built With

๐Ÿ Python โ€ข ๐Ÿ“บ Streamlit โ€ข ๐Ÿผ Pandas โ€ข ๐Ÿ—„๏ธ SQLite โ€ข ๐Ÿ“Š Plotly

๐Ÿš€ Features

๐Ÿ“ Dataset Upload and Column Mapping

  • Upload datasets in CSV or Excel format.
  • Map custom dataset column names to InsightFlow's required structure.
  • Prevent the same uploaded column from being mapped multiple times.
  • Automatically handle unavailable optional columns.
  • Validate uploaded data before inserting it into the database.
  • Detect invalid numeric and date values.
  • Detect duplicate order records.

๐Ÿ—„๏ธ SQLite Database Integration

InsightFlow uses SQLite as its backend database.

The application stores data across three related tables:

๐Ÿ‘ฅ Customers

Stores customer information including:

  • Customer ID
  • Customer Name
  • Region
  • City

๐Ÿ“ฆ Products

Stores product information including:

  • Product ID
  • Product Name
  • Category
  • Sub-Category

๐Ÿ›’ Sales

Stores transactional sales information including:

  • Order ID
  • Order Date
  • Customer ID
  • Product ID
  • Sales
  • Quantity
  • Discount
  • Profit

The tables are connected using primary keys and foreign keys.


๐Ÿ“ˆ Executive Dashboard

The Executive Dashboard provides an overall view of business performance.

Key Performance Indicators

  • ๐Ÿ›’ Total Orders
  • ๐Ÿ“ฆ Total Products
  • ๐Ÿ™Žโ€โ™‚๏ธ Total Customers
  • ๐Ÿ’ธ Total Sales
  • ๐Ÿ“ˆ Total Profit
  • ๐Ÿ“Š Average Order Value

Visualizations

  • Monthly Sales Trend
  • Monthly Profit Trend
  • Sales by Region
  • Profit by Region
  • Sales by Category
  • Profit by Category

๐Ÿ‘ฅ Customer Insights

The Customer Insights page helps analyze customer behavior and contribution.

Features

  • Total Customers
  • Repeat Customers
  • Most Frequent Customer
  • Customers Ranked by Number of Orders
  • Top 10 Customers by Revenue
  • Customer Segmentation

Customers are segmented into:

  • ๐Ÿ’Ž High Value
  • ๐Ÿ‘ฅ Regular
  • ๐Ÿ“‰ Low Value

A pie chart provides a visual overview of customer segmentation.


๐Ÿ“ฆ Product Performance

The Product Performance page provides insights into product-level business performance.

Features

  • Total Products
  • Best Selling Product
  • Most Profitable Product
  • Overall Product Summary
  • Top Selling Products
  • Least Selling Products
  • Top Profitable Products
  • Product Sales Treemap

The application uses interactive Plotly visualizations to explore product performance.


๐Ÿ“‘ Reports

The Reports page allows users to generate filtered business reports.

Available Filters

Users can filter data by:

  • Category
  • City
  • Month
  • Year

Available Reports

  • ๐Ÿ›’ Sales Table
  • ๐Ÿ‘ฅ Customer Table
  • ๐Ÿ“ฆ Product Table
  • ๐Ÿ“‹ Full Merged Table
  • ๐Ÿ“Š Business Summary Report
  • ๐Ÿ‘ฅ Customer Report
  • ๐Ÿ“ฆ Product Report

All reports can be downloaded as CSV files.


๐Ÿง  Trends and Predictions

The Trends and Predictions section is currently under development.

Future versions of InsightFlow may include:

  • Machine Learning Models
  • Sales Forecasting
  • Trend Prediction
  • AI-Powered Business Insights
  • Predictive Analytics

๐Ÿ› ๏ธ Technologies Used

Technology Purpose
๐Ÿ Python Core programming language
๐Ÿ“บ Streamlit Web application and user interface
๐Ÿผ Pandas Data cleaning and analysis
๐Ÿ”Œ SQLite Database management
๐Ÿ“Š Plotly Interactive visualizations

๐Ÿ—‚๏ธ Project Structure

Project_InsightFlow/
โ”‚
โ”œโ”€โ”€ app.py
โ”œโ”€โ”€ main.py
โ”œโ”€โ”€ database_functions.py
โ”œโ”€โ”€ UI_customization.py
โ”œโ”€โ”€ insightflow.db
โ”œโ”€โ”€ requirements.txt
โ”œโ”€โ”€ .gitignore
โ”œโ”€โ”€ README.md
โ”‚
โ”œโ”€โ”€ pages/
โ”‚   โ”œโ”€โ”€ customer_feedback.py
โ”‚   โ”œโ”€โ”€ executive_dashboard.py
โ”‚   โ”œโ”€โ”€ product_performance.py
โ”‚   โ”œโ”€โ”€ reports.py
โ”‚   โ”œโ”€โ”€ trends_and_forecast.py
โ”‚   โ””โ”€โ”€ upload_dataset.py
โ”‚
โ”œโ”€โ”€ logos/
โ”‚   โ””โ”€โ”€ Project_logo.png
โ”‚
โ””โ”€โ”€ screenshots/
    โ”œโ”€โ”€ customer_insight_bottom.png
    โ”œโ”€โ”€ customer_insight_top.png
    โ”œโ”€โ”€ dashboard_bottom.png
    โ”œโ”€โ”€ dashboard_top.png
    โ”œโ”€โ”€ home_bottom.png
    โ”œโ”€โ”€ home_top.png
    โ”œโ”€โ”€ product_performance_bottom.png
    โ”œโ”€โ”€ product_performance_top.png
    โ”œโ”€โ”€ reports_bottom.png
    โ”œโ”€โ”€ reports_top.png
    โ”œโ”€โ”€ upload_dataset_initial.png
    โ””โ”€โ”€ upload_dataset_second.png

โš™๏ธ Installation

1. Clone the Repository

git clone https://github.com/arjumand547/InsightFlow.git

2. Navigate to the Project Folder

cd Project_InsightFlow

3. Create a Virtual Environment

python -m venv .venv

Activate the Virtual Environment

Windows

.venv\Scripts\activate

macOS / Linux

source .venv/bin/activate

4. Install Required Libraries

pip install -r requirements.txt

โ–ถ๏ธ Run the Application

Run the following command:

streamlit run main.py

The application will start locally in your browser.


๐Ÿ“ธ Application Screenshots

๐Ÿ  Home Page

Home Page

Home Page


๐Ÿ“ˆ Executive Dashboard

Executive Dashboard

Executive Dashboard


๐Ÿ‘ฅ Customer Insights

Customer Insights

Customer Insights


๐Ÿ“ฆ Product Performance

Product Performance

Product Performance


๐Ÿ“‘ Reports

Reports

Reports


๐Ÿ“ Upload Dataset

Upload Dataset

Upload Dataset


๐Ÿ”„ Application Workflow

Upload Dataset
      โ†“
Map Dataset Columns
      โ†“
Validate Data Types
      โ†“
Clean and Prepare Data
      โ†“
Insert Customers into SQLite
      โ†“
Insert Products into SQLite
      โ†“
Map Customer and Product IDs
      โ†“
Insert Sales into SQLite
      โ†“
Analyze Data
      โ†“
Generate Dashboards and Reports

๐Ÿ“Š Database Design

InsightFlow follows a relational database structure.

CUSTOMERS
โ”‚
โ”œโ”€โ”€ Customer_ID (Primary Key)
โ”œโ”€โ”€ Customer_Name
โ”œโ”€โ”€ Region
โ””โ”€โ”€ City

        โ”‚
        โ”‚
        โ–ผ

SALES
โ”‚
โ”œโ”€โ”€ Sales_ID (Primary Key)
โ”œโ”€โ”€ Order_ID
โ”œโ”€โ”€ Order_Date
โ”œโ”€โ”€ Customer_ID (Foreign Key)
โ”œโ”€โ”€ Product_ID (Foreign Key)
โ”œโ”€โ”€ Sales
โ”œโ”€โ”€ Quantity
โ”œโ”€โ”€ Discount
โ””โ”€โ”€ Profit

        โ–ฒ
        โ”‚
        โ”‚

PRODUCTS
โ”‚
โ”œโ”€โ”€ Product_ID (Primary Key)
โ”œโ”€โ”€ Product_Name
โ”œโ”€โ”€ Category
โ””โ”€โ”€ Sub_Category

๐ŸŽฏ Key Concepts Demonstrated

This project demonstrates practical experience with:

  • Data Cleaning
  • Data Validation
  • Data Type Conversion
  • Missing Value Handling
  • Duplicate Detection
  • Relational Databases
  • SQLite CRUD Operations
  • Primary and Foreign Keys
  • Pandas Data Analysis
  • Data Merging
  • GroupBy Operations
  • Pivot Tables
  • Customer Segmentation
  • KPI Calculations
  • Interactive Data Visualization
  • Streamlit Session State
  • File Upload Handling
  • CSV Report Generation
  • Git and GitHub

๐Ÿ”ฎ Future Improvements

Possible future improvements include:

  • ๐Ÿค– Machine Learning Sales Forecasting
  • ๐Ÿง  AI-powered insights
  • ๐Ÿ“ˆ Advanced predictive analytics
  • ๐Ÿ” User authentication
  • โ˜๏ธ Cloud database integration
  • ๐Ÿ“Š More advanced dashboard filtering
  • ๐Ÿ“ง Automated report sharing

๐Ÿ‘จโ€๐Ÿ’ป Developer

Syed Arjumand Haider Shah

Aspiring Data Analyst | BS Artificial Intelligence Student | Dashboard Developer

๐Ÿ”— Connect With Me


โญ About This Project

InsightFlow was built as a portfolio project to demonstrate practical skills in data analytics, dashboard development, database management, and interactive data visualization.

The project focuses on building a complete analytics workflow where users can upload raw business data and transform it into meaningful insights through dashboards and downloadable reports.


โญ If you find this project interesting, consider giving the repository a star!

About

Interactive business intelligence and data analytics dashboard built with Python, Streamlit, Pandas, SQLite, and Plotly.

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages