Ahmed Doghri Logo Image
Ahmed Doghri

graphpulse

Degree is a lazy anomaly detector. graphpulse looks at neighborhood disagreement instead and lifts AUC from 0.196 to 0.938.

graphpulse, a heterophily-aware graph anomaly detector

The Weird Node Is Not Always Loud

A lot of anomaly detectors chase degree. That catches hubs and isolates. It misses the quieter failure: a node with ordinary degree connected to the wrong kind of neighbors.

graphpulse plants exactly that kind of anomaly. The graph has communities, features, and nodes that look normal by degree while their neighborhood tells a different story.

Score The Disagreement

The detector compares each node feature to its neighborhood average, adds a small cross-community signal, and keeps the score simple enough to audit.

This is not a GNN trying to win a leaderboard. It is a sharp baseline for heterophilous anomaly structure, the kind of baseline you want before you add a bigger model.

The Number

Degree baseline AUC is 0.196. graphpulse AUC is 0.938, a 0.741 gain on a graph with 96 nodes and 394 edges.

3 tests pass locally and on GitHub Actions across Python 3.9, 3.11, and 3.13.

Tools Used

Python
Graph Learning
Anomaly Detection
Heterophily
AUC
pytest
GitHub Actions CI