Fraud detection is a critical challenge for large-scale online platforms, where even a small fraction of fraudulent users can cause millions of dollars in financial losses. In practice, graph structures are commonly adopted to model interactions, such as transactions and user behaviors. However, fraudsters deliberately camouflage their behaviors to mimic legitimate users, introducing both label noise and structural noise into the graph-based models. To this end, we develop iQ-Guard, an effective and noise-resistant framework for graph fraud detection that has been fully deployed on iQIYI, one of China’s largest online video and social platforms.
iQ-Guard proposes two novel components: (i) Dynamic Contrastive Learning, which adaptively augments data for each sample, enabling the model to resist noisy labels while preserving meaningful representation information gradually, and (ii) Structure-aware Noise-resistant Training, which leverages edge relations and robust loss functions to mitigate both label and structural noise. Extensive experiments on five datasets, including large-scale industrial data, show that iQ-Guard outperforms 14 state-of-the-art methods. Since its deployment, iQ-Guard has detected an average of 36 fraud cases per day, preventing over $1.12 million in financial losses.
- Install required packages:
pip install -r requirements.txt
- Dataset resources:
- For Amazon and YelpChi, we use the built-in datasets in the DGL package https://docs.dgl.ai/en/0.8.x/api/python/dgl.data.html.
- For T-Finance and T-Social, we download the datasets from https://github.com/squareRoot3/Rethinking-Anomaly-Detection.
- Please download and unzip all the files in the
data/folder.
- Hyper-parameter settings for all datasets are put into the
config/folder. - To run the model, use
--configto specify hyper-parameters and--runsthe number of running times. - If you want to run the Amazon dataset 5 times, please execute this command:
python main.py --config 'config/amazon.yml' --runs 5.