Skip to content

AyushSingh360/Misinformation-Detection

Repository files navigation

AI-Powered Fake News Detection System

Deployed on Vercel License: MIT

A sophisticated AI-powered system for detecting fake news and misinformation using advanced natural language processing, fact verification, and source reliability analysis.

🌟 Features

Core Detection Capabilities

  • Content Analysis Engine: Advanced NLP analysis detecting manipulative language patterns, emotional manipulation, and suspicious content structures
  • Fact Verification System: Cross-references claims against trusted databases and knowledge sources
  • Source Reliability Checker: Evaluates domain reputation, technical indicators, and bias detection
  • Comprehensive Scoring Algorithm: Weighted credibility assessment combining all analysis components

User Experience

  • Professional Interface: Clean, trustworthy design with intuitive tabbed results layout
  • Dark/Light Mode: Seamless theme switching with animated starfall background effects
  • Real-time Analysis: Instant credibility assessment with detailed breakdowns
  • Visual Indicators: Clear credibility scores, confidence intervals, and risk assessments

API Integration

  • RESTful API: Complete programmatic access to all detection capabilities
  • Batch Processing: Analyze multiple texts simultaneously
  • Individual Components: Access specific analysis modules independently
  • Comprehensive Documentation: Built-in API documentation and health monitoring

πŸš€ Quick Start

Prerequisites

  • Node.js 18+
  • npm or yarn package manager

Installation

  1. Clone the repository ```bash git clone https://github.com/AyushSingh360/misinformation-detection.git cd misinformation-detection ```

  2. Install dependencies ```bash npm install

    or

    yarn install ```

  3. Run the development server ```bash npm run dev

    or

    yarn dev ```

  4. Open your browser Navigate to http://localhost:3000

πŸ“– Usage

Web Interface

  1. Text Analysis: Paste or type content into the main input area
  2. URL Analysis: Enter a URL to analyze web content directly
  3. View Results: Explore detailed analysis across multiple tabs:
    • Overview: Overall credibility score and classification
    • Content Analysis: NLP insights and pattern detection
    • Fact Check: Claim verification and evidence assessment
    • Source Check: Domain reliability and technical analysis

API Usage

Comprehensive Analysis

```bash curl -X POST http://localhost:3000/api/analyze
-H "Content-Type: application/json"
-d '{"text": "Your content to analyze", "url": "optional-source-url"}' ```

Individual Components

```bash

Content Analysis Only

curl -X POST http://localhost:3000/api/content-analysis
-H "Content-Type: application/json"
-d '{"text": "Content to analyze"}'

Fact Checking Only

curl -X POST http://localhost:3000/api/fact-check
-H "Content-Type: application/json"
-d '{"text": "Claims to verify"}'

Source Checking Only

curl -X POST http://localhost:3000/api/source-check
-H "Content-Type: application/json"
-d '{"url": "https://example.com"}' ```

Batch Processing

```bash curl -X POST http://localhost:3000/api/batch
-H "Content-Type: application/json"
-d '{"items": [{"text": "First text"}, {"text": "Second text"}]}' ```

πŸ—οΈ Architecture

Frontend Components

  • Next.js 14: React framework with App Router
  • Tailwind CSS: Utility-first styling with custom design system
  • Custom Theme System: Light/dark mode with animated backgrounds
  • Responsive Design: Mobile-first approach with professional UI

Backend Services

  • API Routes: RESTful endpoints for all detection services
  • Analysis Engines: Modular NLP and verification systems
  • Scoring Algorithm: Weighted credibility assessment
  • Health Monitoring: System status and performance tracking

Key Technologies

  • Natural Language Processing: Advanced text analysis and pattern detection
  • Fact Verification: Knowledge base integration and claim validation
  • Source Analysis: Domain reputation and technical assessment
  • Real-time Processing: Instant analysis with comprehensive results

🎨 Design System

Color Palette

  • Primary: Professional blue (#2563eb)
  • Success: Reliable green (#059669)
  • Warning: Caution amber (#d97706)
  • Danger: Alert red (#dc2626)
  • Neutrals: Sophisticated grays with proper contrast ratios

Typography

  • Headings: Inter font family with multiple weights
  • Body: Optimized for readability with proper line heights
  • Accessibility: WCAG AA compliant contrast ratios

πŸ”§ Configuration

Environment Variables

```env

Add any required environment variables here

NEXT_PUBLIC_APP_URL=http://localhost:3000 ```

Customization

  • Scoring Weights: Modify components/credibility-scorer.tsx
  • Analysis Parameters: Update individual analysis components
  • UI Themes: Customize app/globals.css color variables
  • API Endpoints: Extend app/api/ directory

πŸ§ͺ Testing

```bash

Run tests

npm test

Run with coverage

npm run test:coverage

E2E tests

npm run test:e2e ```

πŸ“Š Performance

  • Analysis Speed: < 2 seconds for typical content
  • API Response: < 500ms average response time
  • Accuracy: High precision with multi-layered verification
  • Scalability: Designed for concurrent analysis requests

🀝 Contributing

We welcome contributions! Please see our Contributing Guidelines for details.

Development Workflow

  1. Fork the repository
  2. Create a feature branch
  3. Make your changes
  4. Add tests if applicable
  5. Submit a pull request

πŸ“„ License

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

πŸ™ Acknowledgments

  • Deployed on Vercel - The platform for frontend developers
  • Inspired by the need for reliable information in the digital age

πŸ”§ Support

πŸ”— Links


Built with ❀️ for a more informed world

About

AI-powered fake news detection system using advanced NLP, fact verification, and source reliability analysis. Built with Next.js 14, featuring real-time credibility assessment, comprehensive RESTful API, and professional dark/light mode interface for combating misinformation.

Topics

Resources

License

Contributing

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors