Skip to content

vinay-030/YT-lytics

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

9 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿ“Š YT-lytics

License React Vite Flask TailwindCSS

An advanced YouTube channel analytics dashboard providing deep insights, competitor comparison, and AI-driven recommendations using Gemini AI.


โœจ Features

  • ๐Ÿ“ˆ Comprehensive Dashboard Analytics: Visualize channel performance, views, subscribers, and engagement metrics over time.
  • ๐Ÿค– AI Insights: Leverage Google's Gemini AI to analyze your YouTube data and generate actionable recommendations for growth and content strategy.
  • โš”๏ธ Competitor Comparison: Compare key metrics between multiple YouTube channels side-by-side to identify industry trends and gaps.
  • โšก Real-time Data: Integrated directly with the YouTube Data API v3 for up-to-date and accurate statistics.
  • ๐ŸŽจ Modern UI/UX: A responsive, beautifully designed interface built with TailwindCSS, featuring smooth animations via Framer Motion and interactive charts with Chart.js.

๐Ÿ“ธ Screenshots

Logo

Logo

Overview Page

(Placeholder: Add a screenshot of the general overview page here)

Overview

Dashboard Analytics

(Placeholder: Add a screenshot of the main dashboard here)

Dashboard Dashboard Dashboard

Compare Section

(Placeholder: Add a screenshot of the channel comparison feature here)

Compare Section Compare Section

Analysis

Analysis Analysis

AI Insights Section

(Placeholder: Add a screenshot of the Gemini AI generated insights here)

AI Insights


๐Ÿ› ๏ธ Tech Stack

Frontend Backend APIs
React + Vite Flask (Python) YouTube Data API v3
TailwindCSS Google Gemini AI API
Chart.js
Framer Motion

๐Ÿ—๏ธ Architecture Overview

The application follows a modern client-server architecture:

  1. Client (React + Vite): Handles the user interface, routing, state management, and data visualization. It makes RESTful API calls to the backend to fetch channel data and AI insights.
  2. Server (Flask): Acts as a secure middleman and processor. It securely communicates with the YouTube Data API to fetch channel statistics, processes the data, and passes relevant metrics to the Gemini AI API to generate intelligent insights. It then formats and serves this data to the frontend application.

๐Ÿ“ Folder Structure

YT-lytics/
โ”œโ”€โ”€ backend/               # Flask backend application
โ”‚   โ”œโ”€โ”€ app.py             # Main entry point
โ”‚   โ”œโ”€โ”€ requirements.txt   # Python dependencies
โ”‚   โ””โ”€โ”€ ...
โ”œโ”€โ”€ frontend/              # React + Vite frontend application
โ”‚   โ”œโ”€โ”€ src/               # Source code
โ”‚   โ”‚   โ”œโ”€โ”€ components/    # Reusable UI components
โ”‚   โ”‚   โ”œโ”€โ”€ pages/         # Page layouts
โ”‚   โ”‚   โ”œโ”€โ”€ App.jsx        # Main React component
โ”‚   โ”‚   โ””โ”€โ”€ main.jsx       # Entry point
โ”‚   โ”œโ”€โ”€ package.json       # Node dependencies
โ”‚   โ”œโ”€โ”€ tailwind.config.js # Tailwind CSS configuration
โ”‚   โ””โ”€โ”€ ...
โ””โ”€โ”€ README.md              # Project documentation

๐Ÿš€ Installation & Setup

Follow these steps to get the project running locally on your machine.

Prerequisites

  • Node.js (v16 or higher)
  • Python (3.8 or higher)
  • A Google Cloud Console project with YouTube Data API v3 enabled.
  • A Google AI Studio API Key for Gemini integration.

1. Clone the Repository

git clone https://github.com/YOUR_USERNAME/YT-lytics.git
cd YT-lytics

2. Backend Setup (Flask)

Open a terminal and navigate to the backend directory:

cd backend

Create a virtual environment: Windows:

python -m venv venv
venv\Scripts\activate

macOS/Linux:

python3 -m venv venv
source venv/bin/activate

Install the required Python packages:

pip install -r requirements.txt

3. Frontend Setup (React + Vite)

Open a new terminal window and navigate to the frontend directory:

cd frontend

Install the required Node packages:

npm install

โš™๏ธ Environment Variables & API Setup

You need to set up environment variables for the backend to communicate with the APIs.

Backend .env

Create a .env file in the backend/ directory and add your API keys:

# backend/.env
YOUTUBE_API_KEY=your_youtube_data_api_v3_key_here
GEMINI_API_KEY=your_google_gemini_api_key_here

Frontend .env (Optional)

If your frontend needs specific environment variables (e.g., overriding the API base URL), create a .env file in the frontend/ directory:

# frontend/.env
VITE_API_BASE_URL=http://localhost:5000

๐Ÿƒ Running the Application Locally

You will need two separate terminal windows running simultaneously to start both the frontend and backend servers.

1. Start the Backend Server

Ensure your virtual environment is activated, then run:

# In the backend/ directory
flask run
# OR
python app.py

The Flask server should now be running, typically on http://localhost:5000 or http://127.0.0.1:5000.

2. Start the Frontend Development Server

In your second terminal window, run:

# In the frontend/ directory
npm run dev

Vite will start the development server, usually accessible at http://localhost:5173. Open this URL in your browser to view the application.


๐Ÿ”ฎ Future Improvements

  • Implement user authentication to save favorite channels and personal notes.
  • Add export functionality (PDF/CSV) for dashboard reports.
  • Integrate YouTube OAuth for users to view their own private channel analytics.
  • Expand AI capabilities for video title and thumbnail generation.
  • Implement caching (e.g., Redis) to reduce API calls and improve loading times.

๐Ÿ“„ License

This project is licensed under the MIT License.


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

Your Name


If you find this project interesting or helpful, please consider leaving a โญ on the repository!

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors