fraudoo / README.md
obaes's picture
Upload 10 files
71680bc verified

A newer version of the Gradio SDK is available: 6.12.0

Upgrade
metadata
title: fraudoo
emoji: 🐒
colorFrom: green
colorTo: purple
sdk: gradio
sdk_version: 6.3.0
app_file: app.py
pinned: false
license: apache-2.0
short_description: fraudoo

πŸ›‘οΈ Documentary Fraud Management MCP Service

A robust documentary fraud detection service using LLM Services 3 Flash and Nano Banana Pro, integrated with a Gradio UI and serving as an MCP (Model Context Protocol) server.

✨ Features

  • Dual-Model Analysis:
    • LLM Services 3 Flash: Handles complex reasoning, entity extraction (Names, Dates, IDs), and overall fraud scoring.
    • LLM Services Nano Banana Pro: Performs critical visual analysis to detect clones, font mismatches, and retouching.
  • Support for Images & PDFs: Automatically converts PDF pages to images for visual manipulation detection.
  • Dynamic Context: Prompts include real-time date/time (currently 2026-01-21) for accurate expiration and inconsistency checks.
  • Historical Explorer:
    • List View: Browse past analyses with labels, amounts, and fraud scores (X/100).
    • Persistence: Local storage of uploaded files in uploads/ for persistent previews.
    • Deletion: Remove unwanted analysis records and associated raw files.
  • Duplicate Detection: Uses SHA-256 for exact matches and ChromaDB for semantic similarity checks.
  • Native MCP Server: Exposes analysis tools directly to MCP-compatible clients.

πŸš€ Getting Started

Prerequisites

  • Python 3.10+
  • Google API Key (LLM Services)

Installation

  1. Clone the repository and navigate to the directory.
  2. Create and activate a virtual environment:
    python3 -m venv venv
    source venv/bin/activate
    
  3. Install dependencies:
    pip install -r requirements.txt
    

Running the Service

  1. Set your Google API Key:
    export GOOGLE_API_KEY="your_api_key_here"
    
  2. Enable MCP functionality:
    export GRADIO_MCP_SERVER=True
    
  3. Launch the app:
    python app.py
    
  4. Open the UI at http://127.0.0.1:7864.

πŸ› οΈ Architecture

  • app.py: Gradio interface, session management, and persistent file handling.
  • fraud_analyzer.py: Core logic for LLM Services integration, PDF conversion, and metadata extraction.
  • vector_service.py: Fingerprinting and history storage using ChromaDB.
  • uploads/: Persistent storage for analyzed documents.
  • chroma_db/: Vector database storage.

πŸ”Œ MCP Integration

The Gradio app natively serves as an MCP server. You can access the protocol at: http://127.0.0.1:7864/gradio_api/mcp/