Detecting advanced web bots by combining server logs with mouse-movement biometrics, and explaining every decision.
Team project — 5 contributors.
Simple bots are easy to spot: they hammer endpoints, ignore CSS, and request pages in implausible orders. Advanced bots aren't. They throttle themselves, load assets, and follow believable navigation paths — and log-based detection stops working.
What they're much worse at is moving a mouse like a person. Human pointer motion has characteristic velocity curves, pauses, corrections and jitter. Synthetic motion tends to be too smooth, too linear, or too regular.
BotSight combines both signals, and then explains itself — because a security control that outputs "bot: 0.87" with no reasoning doesn't survive review, and can't be tuned when it starts producing false positives on real users.
client/collector.js browser-side capture of pointer events
translator.py raw event stream -> behavioural feature vectors
train_rf.py random-forest classifier over the combined feature set
explainer.py per-prediction feature attribution
validate_session.py score a single captured session end to end
client/demo.html gives you a page to move your mouse on and see it classified live.
Trained on the web-bot detection dataset from:
Christos Iliou, Theodoros Kostoulas, Theodora Tsikrika, Vasilis Katos, Stefanos Vrochidis, Ioannis Kompatsiaris. Detection of Advanced Web Bots by Combining Web Logs with Mouse Behavioural Biometrics. Digital Threats: Research and Practice 2, 3, Article 24 (2021). https://doi.org/10.1145/3447815
Download: https://m4d.iti.gr/wp-content/uploads/2024/04/web_bot_detection_dataset.zip
Unzip it into the project root and keep the directory structure intact.
pip install -r requirements.txt
python train_rf.py # trains and saves the classifier
python validate_session.py # score a captured sessionTests:
python -m pytest test_component2.py test_server.py test_xai_integration.pyPython · scikit-learn · explainable AI · JavaScript