SimGuard: Context-Aware Anomaly Filtering via Similarity-Guided Error Detection
Abstract
Given millions of invoices flagged daily by en- terprise anomaly detectors, how can we reliably separate genuine errors from benign anomalies without drowning human investigators, when a single missed error can cost millions and vendor- specific retraining is infeasible? We present Sim- Guard, a context-aware error-detection frame- work built on two ideas: asymmetric tempera- ture decoupling in the InfoNCE loss, which pre- vents feature suppression on heterogeneous tab- ular data, and a curriculum over the denomina- tor temperature τdenom and corruption rate pcorr that sharpens hard-negative discrimination with- out losing rare-error sensitivity. At inference, SimGuard retrieves the k most similar histori- cal cases within a vendor partition and filters anomalies that match known benign patterns via a similarity-weighted vote over investigator-verified labels. SimGuard operates as a post-hoc filtering layer downstream of foundation-model classifiers such as TabPFN (Hollmann et al., 2025), whose high recall (0.92) generates excessive false posi- tives that domain-specific filtering must resolve. On enterprise-scale invoice datasets SimGuard re- duces flagged anomalies by 15% while keeping recall loss below 1%; paired with TabPFN on public fraud benchmarks it achieves Santander F1 of 0.53 (vs. TabPFN alone 0.51) and Credit Card Fraud F1 of 0.77 to 0.78 (vs. 0.73) at volume reductions of 9.4% to 31.0%. Each SimGuard prediction comes with its retrieved neighbors as case-level explanations, and the system absorbs new error patterns by adding investigator-labeled cases to the repository, with no retraining required (full results in App. D)