Abstract
Social bot detection has become increasingly challenging as "chameleon" bots evolve to mimic human behavior, evading traditional Graph Neural Network (GNN) detectors that rely on homophily. This paper introduces SeBot, a framework that leverages structural entropy to uncover hidden hierarchical community structures within social networks. By integrating global structural insights with an adaptive relational encoder and multi-view contrastive learning, SeBot effectively distinguishes sophisticated bots from legitimate users. Experimental results on TwiBot-20 and MGTAB benchmarks demonstrate that SeBot achieves state-of-the-art performance, offering superior accuracy and robustness against adversarial bot strategies.
Introduction: The Challenge of Modern Social Bots
The landscape of social media is increasingly populated by automated accounts. Modern social bots have moved beyond simple "bot farms" to sophisticated "chameleon" strategies, where they intentionally interact with legitimate human accounts to blend into the social fabric. This evolution poses two significant challenges for current detection methods:
- The Homophily Trap: Standard GNNs operate on the assumption of homophily—that connected nodes share similar characteristics. When bots mimic humans, message-passing mechanisms can cause their representations to converge, making them nearly indistinguishable.
- Hidden Hierarchies: Social networks possess complex, multi-layered community structures. Most existing models focus on local neighborhoods, failing to capture the broader hierarchical context that often reveals coordinated bot activity.
Methodology: Structural Entropy and Multi-View Learning
SeBot addresses these challenges through a multi-view framework centered on structural entropy.
Structural Entropy Guided Encoding Trees
The core innovation of SeBot is the use of structural entropy—a metric for graph complexity—to construct "encoding trees." By minimizing this entropy, the model automatically identifies the most natural hierarchical divisions in the social graph. This process is applied at both the global graph level and the local subgraph level, providing a multi-scale view of the network's organization. This hierarchical approach allows the model to see the "big picture" of how accounts fit into broader social structures.
Relational Information Aggregation
To counter "adversarial heterophily" (bots mimicking humans), SeBot employs an encoder that does not assume neighbor similarity. Using the Gumbel-Max reparameterization trick, the model adaptively assigns positive or negative weights to edges. This allows the network to either aggregate similar features or highlight discrepancies between a node and its neighbors, effectively unmasking bots that attempt to hide among humans.
Multi-View Contrastive Learning
The framework integrates these insights through a multi-task learning approach. It maximizes mutual information across three views: node-level, subgraph-level, and relational. This ensures the final account representations capture both individual behavioral patterns and their structural positioning within the social hierarchy.
Experiments and Results
SeBot was evaluated on two major real-world benchmarks: TwiBot-20, a comprehensive Twitter dataset with over 229,000 accounts, and MGTAB, a multi-relational dataset featuring 7 distinct relationship types.
The model consistently outperformed 11 baseline methods, including state-of-the-art GNNs like BotRGCN and RGT. On the TwiBot-20 dataset, SeBot achieved an accuracy of 87.24% and an F1-score of 88.74%, marking a significant improvement over previous methods. Beyond raw performance, SeBot demonstrated significant robustness; it maintained high accuracy even when 50% of edges or features were removed during data efficiency studies. Visualization via T-SNE further confirmed that SeBot produces tighter, more distinct clusters for bots versus humans compared to traditional methods, which often produce overlapping representations.
Conclusion and Future Work
SeBot represents a significant advancement in social bot detection by moving beyond local neighborhood analysis to embrace the hierarchical complexity of social networks. By using structural entropy as a "stable anchor" for contrastive learning, the model avoids the noise associated with random graph augmentations.
While the computational cost of building encoding trees is higher than standard GNNs, the gains in accuracy and robustness against sophisticated "chameleon" bots make it a powerful tool for maintaining social media integrity. Future work may extend these principles to dynamic graphs to track evolving bot behaviors in real-time and further optimize the selection of hyperparameters like tree depth.
Summary updated