TriNetra is a comprehensive Anti-Money Laundering (AML) platform that combines advanced network visualization, behavioral profiling, and AI-powered risk assessment to detect money mule operations and financial crime patterns. Built for financial institutions and compliance teams.
- Timeline-based event tracking and analysis
- Temporal data visualization with quantum selection (1m, 6m, 1y, 3y)
- Transaction pattern detection
- Event correlation and anomaly identification
- Adversarial pattern generation and detection
- Simulated attack scenarios
- Real-time pattern recognition
- Enhanced fraud detection capabilities
- Suspicious Activity Report automation
- FATF-compliant reporting
- Template-based report generation
- Location-based risk mapping
- β Transaction velocity analysis (tx/hour)
- β In/out ratio tracking
- β Account age monitoring
- β Dormant activation detection (60+ day gaps)
- β Small-to-large transaction patterns
- β High throughput flagging
- β Rapid in-out detection (<1 hour window)
- β NetworkX-powered transaction graphs
- β Centrality metrics (degree, betweenness, PageRank)
- β Community detection (Louvain algorithm)
- β Hub-and-spoke pattern identification
- β Funnel account detection
- β D3.js visualization export
- β Multi-hop path detection (3+ hops, 24h window)
- β Circular flow identification (AβBβCβA)
- β Structuring/smurfing detection (threshold avoidance)
- β Time-based pattern correlation
- β Complex laundering chain tracking
- β Weighted risk formula: Behavioral (40%) + Network (30%) + Layering (20%) + Velocity (10%)
- β 0-100 risk scale with CRITICAL/HIGH/MEDIUM/LOW levels
- β Automatic recalculation on new transactions
- β Database-backed risk score caching
- β Batch processing capabilities
- β SHAP-based risk explanations
- β Feature importance ranking
- β Human-readable reason generation
- β Mule-specific SAR generation
- β FATF red flag mapping (6 categories)
- β Evidence-rich reporting (JSON/PDF)
- Framework: Vite + JavaScript
- Styling: Tailwind CSS 4.x
- Visualization: D3.js + Custom canvas rendering
- Real-time: WebSocket integration
- Build: Modern ES modules with HMR
- Language: Python 3.8+
- Framework: Flask 2.3.3
- Database: SQLite (production-ready for PostgreSQL)
- ML/AI:
- scikit-learn 1.3.0 (Machine Learning)
- SHAP 0.42.1 (Explainable AI)
- NetworkX 3.1 (Graph Analysis)
- Data Processing: Pandas 2.1.0, NumPy
- APIs: RESTful architecture with Flask blueprints
IOB-HACK/
βββ TriNetra/
β βββ frontend/ # Web UI (Vite + Tailwind)
β β βββ js/ # Application logic
β β βββ css/ # Stylesheets
β β βββ index.html # Main page
β βββ backend/ # Python Flask Backend
β βββ api/ # API Blueprints
β β βββ chronos_api.py # Timeline API
β β βββ hydra_api.py # GAN API
β β βββ autosar_api.py # SAR API
β β βββ mule_api.py # Mule Detection API β
β βββ services/ # Business Logic β
β β βββ mule_behavior_engine.py
β β βββ network_engine.py
β β βββ layering_engine.py
β β βββ risk_scoring_engine.py
β β βββ explainability_engine.py
β β βββ auto_sar.py
β βββ data/ # Data Layer
β βββ models/ # Data Models
β βββ app.py # Main Application
β βββ config.py # Configuration
β βββ test_mule_features.py # Test Suite
βββ SETUP.md # Installation Guide β
βββ MULE_DETECTION_IMPLEMENTATION.md # Feature Docs β
βββ README.md # This file
See SETUP.md for detailed installation instructions.
- Python 3.8+ (3.12 recommended)
- pip (Python package manager)
- Git
# 1. Clone repository
git clone https://github.com/YOUR_USERNAME/IOB-HACK.git
cd IOB-HACK/TriNetra/backend
# 2. Create virtual environment
python3 -m venv venv
source venv/bin/activate # Windows: venv\Scripts\activate
# 3. Install dependencies
pip install -r ../requirements.txt
# 4. Run the application
python app.py
# 5. Access application
# Open: http://localhost:5001# Run test suite
cd TriNetra/backend
source venv/bin/activate
python test_mule_features.py
# Test API
curl http://localhost:5001/api/health
curl http://localhost:5001/api/mule/statistics- Frontend: See
TriNetra/frontend/vite.config.js - Backend: See
TriNetra/backend/config.py - Deployment: See
vercel.jsonfor Vercel deployment config
| Document | Description |
|---|---|
| SETUP.md | Complete installation and setup guide |
| MULE_DETECTION_IMPLEMENTATION.md | Detailed feature documentation |
| MULE_DETECTION_QUICK_START.md | Developer quick reference |
| ARCHITECTURE_EXPLANATION.md | System architecture overview |
| Hackathon_Analysis_Report.md | Initial analysis report |
| VisuLaundNet_Technical_Architecture.md | Technical architecture |
- β 5 Core Detection Engines - Behavioral, Network, Layering, Risk, Explainability
- β 11 API Endpoints - Complete mule detection API
- β 8 Pattern Types - Comprehensive detection coverage
- β SHAP Integration - Explainable AI for risk decisions
- β FATF Compliance - Automatic red flag mapping
- β Real-Time Scoring - 0-100 risk scale with auto-updates
- β WebSocket integration for real-time updates
- β Tailwind CSS 4.x design system
- β Enhanced UX and button visibility
- β Network topology visualization improvements
- β Chronos timeline animation enhancements
- β Database schema extensions
npm run devnpm run buildConfigured for Vercel. Push to main branch to deploy automatically.
GET /api/chronos/timeline # Transaction timeline
GET /api/chronos/patterns # Pattern detection
GET /api/hydra/simulation # GAN simulation
POST /api/hydra/generate # Generate patterns
GET /api/autosar/templates # SAR templates
POST /api/autosar/generate # Generate SAR
GET /api/mule/mule-risk/<account_id> # Complete risk assessment
GET /api/mule/network-metrics/<account_id> # Network analysis
GET /api/mule/layering-detection/<account_id> # Layering patterns
GET /api/mule/explain-risk/<account_id> # AI explanations
POST /api/mule/generate-mule-sar/<account_id> # Generate SAR
GET /api/mule/high-risk-accounts # High-risk list
GET /api/mule/detect-patterns # Pattern detection
GET /api/mule/statistics # Overall stats
GET /api/mule/network-visualization # D3.js graph data
POST /api/mule/batch-risk-update # Batch operations
GET /api/mule/behavioral-profile/<account_id> # Behavioral features
See SETUP.md for detailed API documentation with examples.
- Rapid Pass-Through - Inbound/outbound within 1 hour
- Hub-and-Spoke - Central node with 10+ spokes
- Funnel Account - Many inbound, few outbound
- Multi-Hop Layering - 3+ hop chains in 24h
- Circular Flows - Round-trip money movements
- Structuring - Multiple transactions near threshold
- Dormant Activation - Long gap then sudden activity
- SmallβLarge - 5 small inbound β 1 large outbound
- β Structuring/Smurfing
- β Rapid pass-through
- β Funnel account behavior
- β Complex layering
- β Circular transactions
- β Account anomalies
- Code Base: 2,581 lines of production code
- Services: 7 independent detection engines
- API Endpoints: 20 total (9 existing + 11 new)
- Detection Patterns: 8 mule-specific patterns
- Test Coverage: Comprehensive test suite included
- Performance: <200ms risk scoring, handles 10k+ transactions
# Run comprehensive test suite
cd TriNetra/backend
source venv/bin/activate
python test_mule_features.py
# Expected output:
# β Mule Behavioral Profiling Engine
# β Graph-Based Network Analysis
# β Layering & Multi-Hop Detection
# β Real-Time Risk Scoring
# β Explainability Engine
# β Mule-Specific Auto-SARContributions are welcome! Please:
- Fork the repository
- Create a feature branch (
git checkout -b feature/AmazingFeature) - Commit changes (
git commit -m 'Add AmazingFeature') - Push to branch (
git push origin feature/AmazingFeature) - Open a Pull Request
See SETUP.md for detailed guidelines.
This project is licensed under the MIT License - see the LICENSE file for details.
- FATF guidelines for AML compliance framework
- NetworkX team for graph analysis capabilities
- SHAP library for explainable AI
- Flask community for the robust web framework
- Open-source AML community
- Check SETUP.md
- Review Troubleshooting Guide
- Check server logs for errors
- Open an issue on GitHub
- Issues: GitHub Issues
- Discussions: GitHub Discussions
- Frontend integration for mule detection UI
- D3.js network visualization page
- PDF SAR export functionality
- PostgreSQL migration for production
- Real-time alerting system
- Docker containerization
- Kubernetes deployment configs
If you find TriNetra useful, please consider giving it a β star on GitHub!
Status: β
Production Ready
Version: 1.0.0
Last Updated: February 15, 2026
Built with β€οΈ for the AML community