Search arXivSearch

arXiv · 2506.06157

Masked Language Models are Good Heterogeneous Graph Generalizers

Abstract

Heterogeneous graph neural networks (HGNNs) excel at capturing structural and semantic information in heterogeneous graphs (HGs), while struggling to generalize across domains and tasks. With the rapid advancement of large language models (LLMs), a recent study explored the integration of HGNNs with LLMs for generalizable heterogeneous graph learning. However, this approach typically encodes structural information as HG tokens using HGNNs, and disparities in embedding spaces between HGNNs and LLMs have been shown to bias the LLM's comprehension of HGs. Moreover, since these HG tokens are often derived from node-level tasks, the model's ability to generalize across tasks remains limited. To this end, we propose a simple yet effective Masked Language Modeling-based method, called MLM4HG. MLM4HG introduces metapath-based textual sequences instead of HG tokens to extract structural and semantic information inherent in HGs, and designs customized textual templates to unify different graph tasks into a coherent cloze-style 'mask' token prediction paradigm. Specifically,MLM4HG first converts HGs from various domains to texts based on metapaths, and subsequently combines them with the unified task texts to form a HG-based corpus. Moreover, the corpus is fed into a pretrained LM for fine-tuning with a constrained target vocabulary, enabling the fine-tuned LM to generalize to unseen target HGs. Extensive cross-domain and multi-task experiments on four real-world datasets demonstrate the superior generalization performance of MLM4HG over state-of-the-art methods in both few-shot and zero-shot scenarios. Our code is available at https://github.com/BUPT-GAMMA/MLM4HG.

Explore related subjects

Keep this discovery

Explore connections, maps & timelines

BibTeXRIS

Jinyu Yang, Cheng Yang, Shanyuan Cui, Zeyuan Guo, Liangwei Yang, Muhan Zhang, Zhiqiang Zhang, Chuan Shi. 2025-07-30. Masked Language Models are Good Heterogeneous Graph Generalizers. https://arxiv.org/abs/2506.06157

Cite the original work for its findings. Save a collection to share your selection of sources.

KEEP EXPLORING

Related papers

User Influence Analysis Based on Blogs

Rumor and word of mouth spread at the same speed as the highway of information diffusion in the age of the internet. Social networks play quite an important role in the huge internet. Nowadays, social networks have become indispensable in our lives, especially for the government and enterprises. A social network becomes a complex information diffusion network with users working as nodes and the relationships between users working as the vehicle. In this paper, we propose three kinds of algorithms for computing user influence based on the behavior of a user's forwarding microblogs and the symbol of @ in microblogs. We evaluate the effectiveness of the algorithms by comparing the results of our work with the training data in the dataset, and in the end, it proves that our algorithms work well.

cs.SI

Location transparency reduces activity by accounts misrepresenting their location on X

Concerns about inauthentic accounts, including foreign actors posing as domestic voices, are central to debates about online discourse. Yet, little is known about accounts with inaccurate location claims and how they behave when discrepancies between their claimed and actual locations become publicly visible. In November 2025, X introduced an "About this account" feature that discloses each account's platform-inferred location of operation. We leverage this intervention in a large-scale quasi-experimental study of 8,200 politically engaged accounts claiming a U.S. location, comparing accounts whose disclosed locations matched versus contradicted their claims across 1.3 million posts and 3.6 million replies over 21 weeks. Before disclosure, location-mismatched accounts posted more misleading, scam-related, and cryptocurrency-related content, but showed no distinctive partisan leaning. Difference-in-differences estimates show that disclosure reduced the posting activity of location-mismatched accounts by 13.1% with the largest declines among accounts revealed to be in Africa (29.2%) and Asia (24.4%), and among accounts with VPN flags, username changes, or scam- and crypto-heavy content. Additionally, the decline in their replies was concentrated in interactions with U.S.-based recipients (10.3%), whereas replies to non-U.S.-based recipients showed no statistically significant change. Conversely, there was no significant change in average audience engagement with their posts. Location transparency thus works primarily by inducing restraint among the disclosed accounts rather than by shifting audience behaviour, and the accounts it constrains look at least as much like cross-border fraud as foreign political influence.

cs.SI

The Benefit of Collective Intelligence in Community-Based Content Moderation is Limited by Overt Political Signalling

Social media platforms face increasing scrutiny over the rapid spread of misinformation. In response, many have adopted community-based content moderation systems, including Community Notes (formerly Birdwatch) on X (formerly Twitter), Community Notes on Meta, and Footnotes on TikTok. However, research shows that the current design of these systems can allow political biases to influence both the development of notes and the rating processes, reducing their overall effectiveness. We hypothesise that enabling users to collaborate on writing notes, rather than relying solely on individually authored notes, can enhance the overall quality of their notes. To test this idea, we conducted an online experiment in which participants jointly authored notes on politically misleading posts. We find that collaboration improves the helpfulness of notes, although the average effect depends on the interactional context. In particular, the benefits of collaboration decline when participants are made aware of one another's political affiliations. We also find that politically diverse teams improve note quality when evaluating Republican posts, while team composition does not meaningfully affect note quality for Democrat posts. These findings underscore the complexity of community-based content moderation and highlight the importance of understanding group dynamics and political diversity when designing more effective moderation systems.

cs.SI