Skip to content

guptasoumya26/ChartCraftAI

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

1 Commit
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿš€ ChartCraft AI

Transform Your Data into Stunning Visualizations with AI Power โœจ

๐ŸŽฏ Upload any CSV, get professional visualizations in seconds with AI-powered insights! ๐Ÿ“Š

๐ŸŽฏ What Makes ChartCraft AI Special?

๐Ÿš€ Transform your CSV data into professional, interactive dashboards with intelligent chart selection, AI-powered insights, and beautiful themes - all in seconds, with zero configuration required!


๐ŸŒŸ Key Features

Feature Description Power Level
๐Ÿค– AI Chat Assistant Ask natural language questions about your data and get precise answers โญโญโญโญโญ
๐ŸŽจ Smart Chart Builder Select columns โ†’ Get AI suggestions โ†’ Create beautiful charts instantly โญโญโญโญโญ
๐Ÿ“Š 10+ Chart Types From basic bars to advanced correlations and bubble charts โญโญโญโญ
๐ŸŽฏ Interactive Dashboards Real-time filters, professional themes, responsive design โญโญโญโญโญ
๐Ÿง  AI-Powered Insights Automated analysis, trend detection, business intelligence โญโญโญโญโญ
๐Ÿ“ค Export Everything PNG, PDF, Excel, CSV - professional reports and visuals โญโญโญโญ
๐ŸŽจ 6 Beautiful Themes Professional styling for every presentation need โญโญโญโญ
๐Ÿ“ฑ Mobile Friendly Works perfectly on desktop, tablet, and mobile โญโญโญโญ

๐Ÿค– AI Chat Assistant

๐Ÿ’ฌ You: "What's the highest expense and when did it occur?"
๐Ÿค– AI: "The highest expense was $215,000 which occurred on 2024-01-25"

๐Ÿ’ฌ You: "Show me sales trends by region"  
๐Ÿค– AI: "North America leads with $67,440 total revenue, showing 15.2% growth"

๐ŸŽฏ Smart Chart Builder

  1. โœ… Select Columns - Choose data with intuitive checkboxes
  2. ๐Ÿ” Get AI Suggestions - Intelligent chart recommendations
  3. ๐ŸŽจ Pick Your Favorites - Multiple chart types available
  4. ๐Ÿ“Š Show Charts - Beautiful visualizations in seconds!

๐ŸŒˆ Professional Themes

  • ๐ŸŽจ Plotly - Clean and modern
  • โšช Plotly White - Minimalist elegance
  • ๐ŸŒ™ Plotly Dark - Sleek dark mode
  • ๐Ÿ“Š GGPlot2 - Statistical styling
  • ๐ŸŒŠ Seaborn - Data science favorite
  • ๐Ÿค Simple White - Pure simplicity

๐Ÿš€ Supported Data Types

Data Type Examples Visualization Options
Sales Data Revenue, products, regions, time Time series, geographic maps, category comparisons
Customer Data Demographics, behavior, satisfaction Distribution analysis, segmentation charts
Marketing Data Campaigns, conversions, ROI Performance tracking, correlation analysis
Operations Data Productivity, costs, efficiency KPI dashboards, trend analysis
Survey Data Responses, ratings, demographics Distribution plots, satisfaction analysis
Financial Data Expenses, budgets, forecasts Time series, budget vs actual
HR Data Headcount, turnover, performance Workforce analytics, performance tracking
Web Analytics Traffic, conversions, sources Funnel analysis, source attribution

๐Ÿ“ˆ Intelligent Chart Types

Automatic Selection Based on Data Patterns

# The AI decides what charts to create:
Time Series Data โ†’ Line charts, area charts, trend analysis
Categorical Data โ†’ Bar charts, pie charts, donut charts
Geographic Data โ†’ Maps, heatmaps, choropleth
Correlation Data โ†’ Scatter plots, correlation matrices
Distribution Data โ†’ Histograms, box plots, violin plots
Comparison Data โ†’ Bar charts, radar charts, parallel coordinates
Part-to-Whole โ†’ Pie charts, treemaps, stacked bars
Ranking Data โ†’ Horizontal bars, lollipop charts

๐Ÿ› ๏ธ Installation & Setup

Prerequisites

  • Python 3.8 or higher
  • pip package manager

Quick Start

  1. Clone the Repository

    git clone https://github.com/yourusername/ChartCraft-AI.git
    cd ChartCraft-AI
  2. Create Virtual Environment

    python -m venv venv
    
    # Windows
    venv\Scripts\activate
    
    # macOS/Linux
    source venv/bin/activate
  3. Install Dependencies

    pip install -r requirements.txt
  4. Run the Application

    streamlit run app.py
  5. Open in Browser

    • The app will automatically open at http://localhost:8501
    • If not, navigate to the URL shown in the terminal

Alternative Installation (Using conda)

# Create conda environment
conda create -n chartcraft python=3.8
conda activate chartcraft

# Install dependencies
pip install -r requirements.txt

# Run application
streamlit run app.py

๐ŸŽฎ Usage Guide

Step 1: Upload Your Data

  • Drag and drop your CSV file into the upload area
  • Or click "Browse files" to select your CSV
  • The app automatically detects column types and data patterns

Step 2: Explore Auto-Generated Dashboard

  • View automatically generated visualizations in the "Dashboard" tab
  • Charts are intelligently selected based on your data characteristics
  • Key metrics are displayed at the top of the dashboard

Step 3: Apply Filters (Optional)

  • Use the sidebar filters to focus on specific data subsets
  • Numeric filters: Range sliders for continuous variables
  • Categorical filters: Multi-select dropdowns for categories
  • Charts update automatically when filters are applied

Step 4: Customize Visualizations

  • Choose different themes from the sidebar
  • Override automatic chart selection with manual choices
  • Use the "Generate Smart Charts" button to refresh visualizations

Step 5: Generate Insights

  • Visit the "Insights" tab for AI-powered data analysis
  • Get automated observations about data quality, patterns, and recommendations
  • Understand your data story through natural language explanations

Step 6: Export Results

  • Charts: Export as PNG ZIP or comprehensive PDF reports
  • Data: Download filtered data as CSV or Excel with multiple sheets
  • Reports: Generate professional reports with charts and insights

๐Ÿ—๏ธ Architecture

Core Modules

ChartCraftAI/
โ”œโ”€โ”€ app.py                 # Main Streamlit application
โ”œโ”€โ”€ data_analyzer.py       # Intelligent data analysis engine
โ”œโ”€โ”€ chart_selector.py      # Smart chart selection algorithm
โ”œโ”€โ”€ insights_generator.py  # AI-powered insights generation
โ”œโ”€โ”€ export_handler.py      # Multi-format export functionality
โ””โ”€โ”€ requirements.txt       # Python dependencies

Key Components

  1. DataAnalyzer: Intelligent data type detection, pattern recognition, quality assessment
  2. ChartSelector: Algorithm for optimal chart selection based on data characteristics
  3. InsightsGenerator: AI-powered analysis for business intelligence and recommendations
  4. ExportHandler: Multi-format export capabilities (PNG, PDF, Excel, CSV)

๐ŸŽจ Customization

Adding New Chart Types

# In chart_selector.py, add your custom chart method
def _create_custom_chart(self, theme: str) -> List[Dict[str, Any]]:
    # Your custom visualization logic
    pass

# Register in generate_smart_charts method
charts.extend(self._create_custom_chart(theme))

Custom Themes

# Add new themes to the theme selector in app.py
available_themes = [
    "plotly", "plotly_white", "plotly_dark", 
    "ggplot2", "seaborn", "simple_white",
    "your_custom_theme"  # Add here
]

Adding New Insight Types

# In insights_generator.py, add new insight methods
def _generate_custom_insights(self):
    insights = []
    # Your custom insight logic
    self.insights.append({
        'category': '๐Ÿ”ฅ Custom Analysis',
        'points': insights
    })

๐Ÿ“Š Example Use Cases

Sales Analytics

date,revenue,product,region,sales_rep
2024-01-01,15000,Product A,North,John
2024-01-02,12000,Product B,South,Jane

Auto-Generated Charts: Time series revenue, product comparison, regional analysis

Customer Survey

age,satisfaction,category,purchase_intent,location
25,4,Premium,Yes,Urban
34,3,Standard,No,Suburban

Auto-Generated Charts: Satisfaction distribution, age demographics, intent analysis

Marketing Campaign

campaign,impressions,clicks,conversions,cost,channel
Campaign A,10000,500,50,1000,Google
Campaign B,8000,400,60,800,Facebook

Auto-Generated Charts: ROI analysis, channel comparison, funnel visualization

๐Ÿ”ง Troubleshooting

Common Issues

1. Installation Problems

# If you get permission errors
pip install --user -r requirements.txt

# If specific packages fail
pip install streamlit plotly pandas numpy matplotlib seaborn

2. Memory Issues with Large Files

  • Files >100MB may cause performance issues
  • Consider sampling your data for exploration
  • Use filters to reduce data size for analysis

3. Chart Generation Failures

  • Check for special characters in column names
  • Ensure data types are consistent
  • Remove completely empty columns

4. Export Issues

# Install additional dependencies for PDF export
pip install reportlab python-pptx kaleido

# For geographic visualizations
pip install folium geopandas

Performance Optimization

  • Large Datasets: Use sampling or filtering for datasets >50,000 rows
  • Many Columns: Focus analysis on most relevant columns
  • Memory Usage: Close browser tabs and restart Streamlit if memory issues occur

๐Ÿ“ License

This project is licensed under the MIT License - see the LICENSE file for details.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages