Skip to content

tuvya-algotar/FraudSense

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🛡️ FraudSense: Real-Time Fraud Detection System


👥 Team

  • Tuvya
  • Dhroova
  • Ammar
  • Swarnim

Built as part of a collaborative hackathon project.

FraudSense is a real-time fraud detection system designed to analyze transactions before completion and prevent high-risk activities using behavioral intelligence, machine learning, and rule-based logic.

🏆 HackUp 2026: Selected in the Top 45 teams out of 200 teams.


🚀 Current Status

  • ✅ Backend fully functional and tested
  • ⚠️ Frontend under reconstruction (v2.0 UI in progress)
  • ✅ API accessible via /docs

This version focuses on a complete redesign of the fraud detection engine with improved accuracy, stability, and system design.


🧠 Core System Design

🔍 Behavioral Fraud Detection

  • Amount deviation (z-score based)
  • Transaction velocity tracking
  • Time-based anomaly detection
  • Category-based behavior analysis

🤖 Machine Learning Layer

  • Random Forest model
  • Feature-aligned input pipeline
  • Integrated into real-time scoring

⚖️ Hybrid Scoring System

Final Score = 0.65 × ML Score + 0.35 × Rule Score

🧠 Decision Engine

  • APPROVE (low risk)
  • MFA_HOLD (medium risk)
  • BLOCK (high risk)

🚨 Safety Overrides

  • Critical fraud patterns trigger forced BLOCK
  • Velocity + anomaly triggers MFA

🔗 Network Risk Detection

  • Shared device detection
  • Merchant spike analysis
  • Fraud pattern linking

🏗️ Architecture

  • Backend: FastAPI (Python)
  • Frontend: React + Vite (Rebuilding UI v2.0)
  • ML Engine: Scikit-learn (Random Forest)
  • Database: SQLite

📂 Project Structure

backend/
frontend/
models/
main.py
requirements.txt
README.md

🛠️ Setup & Installation

Backend

pip install -r requirements.txt
uvicorn main:app --reload --port 8000

Frontend

cd frontend
npm install
npm run dev

⚠️ Note: Frontend is currently under development.


📡 API Endpoint

POST /api/transaction

Evaluates a transaction before execution.

Access interactive API via:

http://127.0.0.1:8000/docs

🎯 Key Highlights

  • Behavior-based fraud detection
  • Hybrid ML + rule scoring
  • Real-time decision engine
  • System-level architecture focus

🤝 Contributing

Contributions are welcome 🚀

  • Improve detection logic
  • Enhance frontend UI
  • Fix bugs
  • Improve documentation

© 2026 FraudSense Team

About

Transaction-level fraud detection system using behavioral profiling, ML scoring, and explainable decisioning

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors