LLM-Enhanced Heterogeneous Graph Learning with Business Semantics for Financial Fraud Detection
Organizations: HKUST-GZ & Jilin University · The Hong Kong University of Science and Technology (Guangzhou) · Ant International · HKUST-GZ & HKUST
Abstract
Financial fraud detection increasingly relies on heterogeneous transaction graphs, in which entities such as cards and merchants play distinct business roles and the risk meaning of an attribute depends on the entity's role: a high transaction volume may be routine for a merchant but unusual for a card. Heterogeneous graph neural networks preserve typed entities and relations but typically treat these attributes as role-agnostic inputs and leave their business meaning implicit. Meanwhile, most existing methods integrating large language models (LLMs) with graphs focus on homogeneous graphs or heterogeneous graphs with naturally available textual attributes, leaving their use on transaction graphs with structured attributes underexplored. To address this issue, we propose SemHGT, an LLM-enhanced framework that interprets structured attributes according to entity roles and makes the business semantics explicit in three stages: (1) role-aware prompts elicit risk-related business descriptions from node attributes, and a text encoder maps them to semantic vectors that enrich node representations; (2) semantic similarity guides multi-round sampling of target-specific path instances under transaction-to-transaction schemas; (3) schema-level tokens that combine local path evidence with global neighbor summaries are processed together with the target transaction by a unified transformer. Across three benchmark datasets, SemHGT leads the evaluated baselines on most dataset--metric comparisons. Further analyses provide additional evidence for the effectiveness of SemHGT's design and clarify how its semantic modeling and evidence selection contribute to fraud detection. Code is available at https://anonymous.4open.science/r/SemHGT-528A/.
Figures & tables
| Dataset | Nodes | Edges | Metapaths |
|---|---|---|---|
| CreditCard | # node types: 6 # nodes: 1,860,300 Transaction: 1,852,394 Fraud: 9,651 (0.52%) Customer: 2,817 Card: 2,817 Merchant: 2,079 Category: 42 Location: 151 | # edge types: 14 # edges: 18,535,208 | –Customer– –Card– –Merchant– –Category– –Location– |
| BankTrans | # node types: 6 # nodes: 8,987,098 Transaction: 8,914,963 Fraud: 13,332 (0.15%) Customer: 1,219 Card: 4,070 Merchant: 66,537 Category: 109 Location: 200 | # edge types: 14 # edges: 89,227,542 | –Customer– –Card– –Merchant– –Category– –Location– |
| Elliptic++ | # node types: 2 # nodes: 110,857 Transaction: 46,564 Fraud: 4,545 (9.76%) Wallet: 64,293 | # edge types: 8 # edges: 402,882 | – – – – – – – – – – |
| Dataset | Max epochs (patience) | Batch size | Learning rate |
|---|---|---|---|
| CreditCard | 40 (10) | 256 | (constant) |
| BankTrans | 50 (10) | 128 | (cosine) |
| Elliptic++ | 40 (10) | 128 | (constant) |
| Method | CreditCard | BankTrans | Elliptic++ | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Macro-F1 | Fraud-F1 | AUPRC | AUROC | Macro-F1 | Fraud-F1 | AUPRC | AUROC | Macro-F1 | Fraud-F1 | AUPRC | AUROC | |
| MLP | 72.41 0.15 | 44.99 0.31 | 40.83 0.24 | 94.29 0.14 | 54.47 0.67 | 9.17 1.41 | 3.76 0.02 | 92.75 0.02 | 79.10 0.61 | 60.31 1.20 | 59.57 0.59 | 84.49 0.41 |
| SlotGAT ( Zhou et al., 2023 ) | 76.62 0.47 | 53.43 0.93 | 47.68 1.01 | 94.46 0.51 | 86.64 0.61 | 73.32 1.21 | 67.95 1.83 | 96.82 0.11 | 74.25 3.15 | 51.08 6.06 | 49.82 7.35 | 86.20 2.23 |
| SimpleHGN ( Lv et al., 2021 ) | 63.31 0.89 | 26.89 1.78 | 14.75 0.40 | 84.80 0.14 | 83.93 0.65 | 67.92 1.29 | 55.35 6.37 | 96.02 0.20 | 74.29 0.49 | 51.55 0.91 | 52.30 0.74 | 87.56 0.35 |
| FastGTN ( Yun et al., 2022 ) | 73.91 0.34 | 48.02 0.68 | 47.72 0.70 | 93.76 0.12 | 57.31 1.59 | 14.84 3.06 | 6.45 1.59 | 94.76 0.40 | 77.23 0.41 | 56.56 0.80 | 60.20 0.77 | 84.99 0.34 |
| HAN ( Wang et al., 2019 ) | 83.34 0.88 | 66.81 1.75 | 70.29 1.72 | 96.97 0.34 | 80.25 0.42 | 60.55 0.84 | 54.74 2.47 | 94.35 0.41 | 71.71 0.22 | 47.58 0.42 | 55.34 1.37 | 85.30 0.21 |
| Dataset | Metric | |||||
|---|---|---|---|---|---|---|
| CreditCard | Macro-F1 | 88.10 | 87.83 | 87.58 | 87.24 | 87.02 |
| CreditCard | Fraud-F1 | 86.73 | 86.39 | 86.09 | 85.65 | 85.38 |
| Elliptic++ | Macro-F1 | 78.80 | 78.24 | 77.28 | 74.54 | 70.17 |
| Elliptic++ | Fraud-F1 | 74.64 | 73.81 | 72.50 | 68.62 | 62.22 |
Appendix figures & tables5 assets
Supplementary material from the paper’s appendix.
Appendix
| Dataset | Split | Transactions | Fraud | Non-fraud |
|---|---|---|---|---|
| CreditCard | Train | 1,111,436 | 6,401 | 1,105,035 |
| Validation | 185,240 | 1,105 | 184,135 | |
| Test | 555,718 | 2,145 | 553,573 | |
| BankTrans | Train | 891,496 | 1,333 | 890,163 |
| Validation | 891,496 | 1,333 | 890,163 | |
| Test | 7,131,971 | 10,666 | 7,121,305 |
| Dataset | Full validation | Subset (fraud / non-fraud) | Neg. weight |
|---|---|---|---|
| CreditCard | 185,240 | 2,210 (1,105 / 1,105) | 166.6380 |
| BankTrans | 891,496 | 22,661 (1,333 / 21,328) | 41.7368 |
| Elliptic++ | 4,005 | 550 (275 / 275) | 13.5636 |
| Dataset | Non-fraud | Fraud | Total |
|---|---|---|---|
| CreditCard | 2,145 | 2,145 | 4,290 |
| BankTrans | 1,000 | 1,000 | 2,000 |
| Elliptic++ | 868 | 868 | 1,736 |
| Dataset | Schema | Per-round path quota | Max. context nodes |
|---|---|---|---|
| CreditCard | –Customer– | 8 | 112 |
| –Card– | 8 | ||
| –Merchant– | 8 | ||
| –Category– | 1 | ||
| –Location– | 1 | ||
| BankTrans | –Customer– | 8 | 128 |
| Target label | Schema | Semantic | Uniform | |
|---|---|---|---|---|
| CreditCard | ||||
| Benign | same customer | 0.179 | 0.371 | -0.192 |
| Benign | same card | 0.173 | 0.371 | -0.198 |
| Benign | same merchant | 0.207 | 0.386 | -0.179 |
| Benign | same category | 0.245 | 0.379 | -0.135 |
| Benign | same location | 0.193 | 0.423 | -0.230 |
Financial Fraud Detection
Financial fraud detection identifies suspicious transactions, accounts, claims, and behavior to prevent losses and guide investigation.
See all 137 papers