Explore how scrolling patterns can help detect scraper bots using burstiness and memory metrics.
The web has become an intricate landscape where human users and automated agents coexist, often leading to challenges in distinguishing between the two. As organizations strive to protect their digital assets, detecting scraper bots has emerged as a pressing concern. Recent research into scrolling behavior offers promising insights into identifying these bots with greater accuracy.
Understanding surveillance-s-impact-on-care/">human interaction with technology relies heavily on patterns of behavior. In the realm of communication, Kwang-Il Goh’s paper, "Burstiness and Memory in Complex Systems," introduces critical concepts that have implications well beyond its primary focus. Burstiness (B) details how events cluster over time rather than showing uniform distribution, while memory (M) captures how past events influence current actions.
These principles can be particularly illuminating when analyzing how users interact with digital platforms. For instance, when users send messages or scroll through a webpage, their behavior often reflects a random burst of activity rather than a steady stream. This non-linear interaction is a hallmark of human behavior.
In past research, I have leveraged these two concepts (B and M) to differentiate between human-generated sessions and those from bots, focusing primarily on the timing of requests. However, this method often falls short, particularly when facing sophisticated bots employing headless browsers to mimic human interaction.
Many developers appear to overlook a key human tendency: the way individuals scroll through content. When scrolling, instead of a straightforward vertical line, human actions create a more complex, bursty pattern. Scraper bots, on the other hand, might lack this variability, making scrolling a potential focal point in bot detection efforts.
The foundation for evaluating the efficacy of scrolling patterns as a means of distinguishing humans from bots comes from Ethan Wang et al.'s research, which resulted in the "FP-Agent: Fingerprinting AI Browsing Agents" paper. This study provides a dataset that comprises navigation records from various AI agents interacting with a testing environment designed specifically for this purpose.
With access to this dataset, I endeavored to extract and calculate the burstiness and memory values for JavaScript "scroll" events associated with each agent across different pages. Each page interaction offers the potential to identify nuances between human and automated behavior.
The analysis revealed that human engagement metrics typically showcased superior burstiness coefficients with minimal memory attributes. The only exception was the ChatGPT agent, which occasionally mirrored human scrolling patterns. These observations pointed to a remarkable distinction between the actions of human users and automated browsers.
To validate the hypothesis that scrolling behavior could serve as an effective discriminator, I utilized a LightGBM model—a decision tree gradient boosting algorithm. This model incorporated the two critical features, burstiness and memory, to predict the identity of the agent undertaking the interactions.
A notable outcome of training this model was an overall accuracy of 73.4%. While this result is promising, distinguishing between humans and the ChatGPT agent remained challenging, often leading to classification errors. The limited scope, stemming from merely 150 data points per agent, underscores the need for a broader dataset to enhance classification accuracy.
While the initial results are encouraging, they also indicate that scrolling behavior alone cannot comprehensively protect websites against scraper bots. Future implementations should consider integrating additional features, such as mouse movements and typing dynamics. This multifaceted approach could lead to the development of a robust model, capable of offering substantial protection against scraping activities and providing a better user experience.
As the research continues to evolve, the next area of focus will be the examination of mouse movement patterns, promising to illuminate further aspects of human and bot behavior.
Keep an eye on upcoming posts as we delve deeper into these fascinating topics and further our understanding of the complex interactions between humans and automated systems.
Author: Niki A, a privacy-centric programmer passionate about machine learning.