Skip to content

AlexanderPotiagalov/DeepScan-AI

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

20 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

DeepScan-AI

AI-powered DeepFake Detection using frame-by-frame video analysis

license last-commit top-language languages

Built with:

Next.js Tailwind CSS Node.js FastAPI TensorFlow Python Axios TypeScript React OpenCV Keras Express.js Multer Neural Networks



πŸ“œ Table of Contents

πŸ“– Overview

DeepScan-AI is a full-stack AI application for detecting deepfakes in videos. It leverages a custom-trained TensorFlow model to analyze individual frames and computes an overall verdict of authenticity.


πŸ“Έ UI Screenshots


✨ Features

βœ… Feature Description
πŸŽ₯ Video Upload Drag & drop or browse to upload video
πŸ“Έ Frame-by-Frame Scan Breaks video into frames and runs each through a trained model
🧠 Deep Learning Model TensorFlow CNN predicts manipulation score per frame
πŸ“Š Final Verdict Displays averaged score with verdict: βœ… Authentic / ⚠️ Deepfake
🌐 Fully Responsive Tailwind-powered sleek and modern interface
πŸš€ FastAPI + Express Lightweight backend infrastructure

🧠 Technology Stack

DeepScan-AI is built using a modular, full-stack architecture that combines modern web technologies with machine learning. Here's a breakdown of the stack:

🌐 Frontend

Technology Purpose
Next.js React-based framework for frontend pages
React Component-driven UI logic
Tailwind CSS Utility-first CSS for styling
Lucide Icons Clean, minimal icon set used in UI
Axios HTTP client for interacting with the API

πŸ–₯️ Backend (Upload & Routing)

Technology Purpose
Node.js Runtime environment
Express.js Upload route and form handling
Multer Middleware for handling file uploads

πŸ§ͺ AI/ML Inference Engine

Technology Purpose
Python Core language for analysis pipeline
FastAPI Fast and lightweight API server
TensorFlow ML framework for deepfake detection
Keras High-level neural networks API (CNN model usage)
OpenCV Frame extraction and image processing

🧱 Infrastructure

  • Local Development using localhost:3000 (frontend), 4000 (upload), and 8000 (inference)
  • Modular Folder Structure: /client, /server, /analyzer for separation of concerns
  • REST API communication between services

πŸ’‘ The stack was chosen to maximize performance, maintainability, and ease of integration between modern web and AI tools.


🧠 How It Works

  1. Upload a video from the client.
  2. The Express server handles file saving.
  3. FastAPI backend extracts frames using OpenCV.
  4. Each frame is evaluated using a CNN deepfake model.
  5. The average of frame scores determines the authenticity verdict.
  6. Results are sent back to the frontend for display.

πŸ“‚ Project Structure

DeepScan-AI/
β”œβ”€β”€ client/               # Next.js frontend
β”‚   └── pages/
β”‚       └── index.tsx     # Main UploadPage
β”œβ”€β”€ server/               # Node.js Express middleware
β”‚   └── index.js
β”œβ”€β”€ analyzer/             # Python FastAPI + TensorFlow backend
β”‚   β”œβ”€β”€ main.py
β”‚   β”œβ”€β”€ mesonet.py
β”‚   └── mesonet_model.h5  # Pretrained model
β”œβ”€β”€ README.md
β”œβ”€β”€ .gitignore

πŸš€ Getting Started

πŸ“‹ Prerequisites

Before getting started with DeepScan-AI, make sure you have the following installed:

  • Node.js (v18+)
  • npm or yarn
  • Python (3.8+)
  • pip and virtualenv

πŸ› οΈ Installation

Follow these steps to set up the full DeepScan-AI stack on your machine:


πŸ” 1. Clone the repository

git clone https://github.com/your-username/DeepScan-AI
cd DeepScan-AI

βš™οΈ 2. Set up the Deepfake Analysis Backend (FastAPI + TensorFlow)

cd analyzer
python -m venv venv
source venv/bin/activate  # On Windows: venv\Scripts\activate
pip install fastapi==0.95.2 uvicorn==0.22.0 numpy==1.24.4 opencv-python==4.8.0.76 tensorflow==2.11.0 python-multipart==0.0.6 pydantic==1.10.13
uvicorn main:app --reload

The backend will start at: http://localhost:8000

🌐 3. Start the Node.js Upload Server

cd ../server
npm install
node index.js

Upload server will run at: http://localhost:4000

πŸ–ΌοΈ 4. Start the Next.js Frontend

cd ../client
npm install
npm run dev

Frontend will be live at: http://localhost:3000

Contributing

πŸ§‘β€πŸ’» Author

Built by Alexander Potiagalov

Releases

No releases published

Packages

No packages published