BotTrans: A Multi-source Graph Domain Adaptation Approach for Social Bot Detection

Boshen Shi, Yongqing Wang, Fangda Guo, Jiangli Shao, Huawei Shen, Xueqi Cheng

Introduction

Social media platforms have become a primary battleground for information integrity, as sophisticated social bots increasingly mimic human behavior to spread misinformation and manipulate public discourse. Detecting these bots is a complex "cat-and-mouse" game. Modern bots are no longer simple automated scripts; they act as "chameleons," blending into human networks to evade detection. This behavior creates a phenomenon known as network heterophily, where anomalous nodes (bots) are surrounded by normal nodes (humans).

Traditional Graph Neural Networks (GNNs) typically operate under the assumption of homophily—the idea that connected nodes share similar characteristics. In the presence of heterophily, standard GNNs tend to "smooth out" the distinct features of a bot into its human neighborhood, rendering the bot invisible. Furthermore, while transfer learning offers a solution for platforms lacking labeled data, most existing methods rely on a single source domain. If the source and target domains are poorly aligned, the transfer can fail or even degrade performance. To address these challenges, we present BotTrans, a multi-source graph domain adaptation framework designed for robust social bot detection.

The BotTrans Framework

BotTrans is designed to overcome the limitations of single-source transfer and network heterophily through three integrated modules: Cross Source Domain Message-Passing, Selective Multi-Source Transfer, and Anomaly Refinement.

1. Cross Source Domain Message-Passing (CSD-MP)

To combat heterophily, BotTrans looks beyond the immediate, noisy neighborhood of a node. Instead of relying solely on local connections that might link a bot to humans, the CSD-MP module identifies the Top-K most similar nodes across all available source domains to construct a new, more homophilous topology.

Rather than comparing raw features, which bots can easily fake, the model employs a graphlet kernel to measure structural similarity. By analyzing the "ego-network" (the local structural pattern) of a node, the model identifies "friends" across different networks that share similar social roles. This allows the GNN to learn from a "cleaner" signal by connecting a bot in one domain to similar bots in others, bypassing the deceptive human neighbors in its local graph.

2. Selective Multi-Source Transfer (SMST)

In multi-source domain adaptation, not all source networks provide equally relevant information. Forcing a model to learn from an irrelevant source can lead to "negative transfer," where the model's accuracy on the target task actually decreases.

BotTrans implements a selective weighting strategy. It calculates a domain-level weight for each source-target pair based on both semantic (latent embedding) and structural similarity. During adversarial training—utilizing Wasserstein-1 distance—the model prioritizes knowledge from source domains that most closely resemble the target. This ensures that the most relevant patterns are transferred while irrelevant or conflicting data is effectively "muted."

3. Anomaly Refinement (AR)

During the final inference stage, BotTrans leverages "free" information from the target domain to polish its predictions. The Anomaly Refinement module calculates a node-level heterophily score based on raw features. If a node’s features are significantly different from its neighbors, its probability of being a bot is boosted. This acts as a final filter to catch bots that might have been under-fitted during the primary training phase.

Experimental Evaluation

The researchers evaluated BotTrans using three major real-world Twitter-based datasets: TwiBot-22, TwiBot-20, and MGTAB. From these, they constructed ten distinct domains representing different social interests and structures. This setup allowed for testing across both "High-relevance" and "Low-relevance" transfer scenarios.

Key Results

  • State-of-the-Art Performance: BotTrans consistently outperformed established baselines, including GCN, GraphSAGE, and specialized domain adaptation models like AdaGCN, by approximately 3% in both F1-score and AUC.
  • Robustness to Dissimilar Sources: In scenarios where source domains were intentionally chosen to be less relevant to the target, BotTrans maintained stable performance. While other models saw performance drops of up to 8%, BotTrans’s selective weighting (SMST) successfully mitigated the risks of negative transfer.
  • Superiority over Unsupervised Methods: When compared to unsupervised anomaly detectors (such as DGI+LOF), BotTrans showed a massive performance gain of 18% to 36%. This demonstrates that even "distant" labeled data, when transferred correctly, is significantly more valuable than no labels at all.

Conclusion and Future Directions

BotTrans represents a significant step forward in social bot detection by moving beyond the constraints of local graph homophily and single-source transfer learning. By focusing on structural similarity through graphlet kernels and selectively weighting source knowledge, the framework provides a robust defense against sophisticated bot tactics.

Future work will focus on addressing the current requirement for a shared feature space across domains, which can be a limitation when transferring knowledge between different platforms (e.g., Twitter to Reddit). Additionally, the team plans to explore the integration of Large Language Models (LLMs) to better capture the semantic nuances of bot-generated content across diverse languages and social contexts.

Summary updated

Abstract

Transferring extensive knowledge from relevant social networks has emerged as a promising solution to overcome label scarcity in detecting social bots and other anomalies with GNN-based models. However, effective transfer faces two critical challenges. Firstly, the network heterophily problem, which is caused by bots hiding malicious behaviors via indiscriminately interacting with human users, hinders the model’s ability to learn sufficient and accurate bot-related knowledge from source domains. Secondly, single-source transfer might lead to inferior and unstable results, as the source network may embody weak relevance to the task and provide limited knowledge. To address these challenges, we explore multiple source domains and propose a multi-source graph domain adaptation model named BotTrans. We initially leverage the labeling knowledge shared across multiple source networks to establish a cross-source-domain topology with increased network homophily. We then aggregate cross-domain neighbor information to enhance the discriminability of source node embeddings. Subsequently, we integrate the relevance between each source-target pair with model optimization, which facilitates knowledge transfer from source networks that are more relevant to the detection task. Additionally, we propose a refinement strategy to improve detection performance by utilizing semantic knowledge within the target domain. Extensive experiments on real-world datasets demonstrate that BotTrans outperforms the existing state-of-the-art methods, revealing its efficacy in leveraging multi-source knowledge when the target detection task is unlabeled.
BibTeX
@inproceedings{shi2025bottrans,
  author = {Boshen Shi and Yongqing Wang and Fangda Guo and Jiangli Shao and Huawei Shen and Xueqi Cheng},
  title = {{BotTrans: A Multi-source Graph Domain Adaptation Approach for Social Bot Detection}},
  booktitle = {ECML/PKDD},
  year = {2025},
  url = {https://openreview.net/forum?id=HA5PK3p0mt},
}
Figure