CrediGraph
Graph-native counterparty credit risk and fraud intelligence engine evaluating 100,000 institutions across 4,002,354 relational exposure edges with GNN contagion propagation.
Signature: Graph-native contagion (SAGEConv) · 4-model ensemble · unsupervised isolation forest
Key Verified Performance Metrics
01 System Context & Problem
Traditional counterparty credit risk models evaluate balance sheets in isolation. If a counterparty maintains strong standalone financial ratios but its key debt partners or interbank lenders face default, distress propagates across the relational network invisibly. Concurrently, fraudulent shell entities mimic legitimate accounting ratios while accumulating extreme interbank exposures on minimal network connectivity.
02 Architecture & Implementation
Multi-tier Python system featuring an interactive Streamlit analytical shell, an asynchronous inference engine dispatching model evaluations in parallel via ThreadPoolExecutor, a localized NetworkX graph analysis layer extracting k-hop contagion subgraphs, and a standalone Flask microservice exposing the fraud detection pipeline.
Engineering Approach: Formulated counterparty risk as a graph representation and multi-model ensemble challenge across 100,000 counterparties and 4,002,354 weighted exposure edges. Built an inductive GraphSAGE neural network to aggregate neighbor default probabilities, ensembled it with gradient-boosted trees and linear baselines, and implemented an unsupervised Isolation Forest over 4 domain-engineered behavioral signals to flag financial implausibility.
03 Technical Decisions & Trade-offs
Core Architectural Decision
Adopted a soft-voting ensemble (XGBoost 40%, Random Forest 30%, GNN Contagion 20%, Logistic Regression 10%) calibrated to balance non-linear tabular precision with structural network contagion signals. Chose inductive SAGEConv layers with mean aggregation rather than transductive GCNs to permit real-time scoring of novel counterparty records without complete graph retraining.
Constraints & Incurred Trade-off
Executing full-graph convolutions across 100k nodes during interactive requests induces prohibitive latency and memory overhead. Resolved by precomputing global node embeddings and performing localized 1-hop and 2-hop neighborhood extractions during interactive What-if stress simulations.
04 Scalability, Throughput & Security
Graph and tabular datasets (132MB combined) are held in memory using vectorized NumPy score stores and lightweight edge adjacency structures. Inference requests leverage a thread-safe LRU-512 cache to achieve sub-millisecond response times on repeated evaluations, scaling smoothly across concurrent analyst sessions.
Cold-start pipeline initialization resolves in 516ms; warm concurrent inference across all 5 models executes in 133ms to 145ms; and interactive contagion subgraphs render at 60 FPS across 100+ localized relational nodes.
05 Verified Outcomes
- Engineered a graph-native credit risk platform evaluating 100,000 counterparties and 4,002,354 relational exposure edges, combining a 2-layer GraphSAGE network (0.952 AUC-ROC) with an ensemble of XGBoost, Random Forest, and Logistic Regression to quantify systemic contagion.
- Architected a parallel inference pipeline using ThreadPoolExecutor and thread-safe LRU caching to drop scoring latency to sub-150ms, complemented by an unsupervised Isolation Forest detector tracking 4 custom financial fraud anomalies.