Introduction
Many real-world graphs, such as citation networks and e-commerce product catalogs, exhibit a long-tailed distribution. In these scenarios, a few "head" classes contain the vast majority of examples, while numerous "tail" classes have very few samples. This imbalance poses a significant challenge for Graph Neural Networks (GNNs), which struggle to learn the distinct characteristics of minority classes.
Standard data augmentation techniques often rely on numeric interpolation (e.g., Mixup or SMOTE). While effective for tabular data, these methods are flawed for Text-Attributed Graphs (TAGs). Averaging high-dimensional text embeddings often results in synthetic points that fall "off-manifold," meaning they do not correspond to semantically coherent text. Furthermore, traditional methods frequently ignore the graph's underlying topology, introducing noise that can degrade model performance.
The SaVe-TAG Framework
To address these limitations, we introduce SaVe-TAG (Semantic-aware Vicinal Risk Minimization for Long-Tailed Text-Attributed Graphs). This framework leverages the semantic reasoning capabilities of Large Language Models (LLMs) to generate high-quality synthetic data for minority classes.
As illustrated above, SaVe-TAG consists of four primary stages:
- Vicinal Twin Identification: For each node in a minority (tail) class, the system identifies its nearest neighbors within the same class, termed "vicinal twins."
- LLM Synthesis: Instead of mathematical averaging, the framework prompts an LLM (such as Llama 3) to synthesize a new piece of text that blends the semantics of the two twins while preserving the class label. This ensures the synthetic data remains "on-manifold" and semantically plausible.
- Confidence-aware Edge Assignment: To prevent "hallucinated" or noisy outputs from negatively impacting the graph, a pre-trained confidence function evaluates the structural consistency of synthetic nodes. Only those with high consistency are integrated into the graph; poor generations remain isolated or "quarantined."
- GNN Training: A standard GNN is then trained on this augmented, balanced graph, benefiting from both the increased sample size and the preserved topological integrity.
Key Insights: Semantic vs. Numeric Interpolation
The core innovation of SaVe-TAG is the shift from linear algebra to semantic interpolation. While a numeric average of "Machine Learning" and "Deep Learning" might result in a meaningless vector, an LLM can generate a coherent paragraph that bridges both concepts.
As shown in the UMAP visualizations (Figure 3c), LLM-generated samples often fall near the decision boundaries between classes. This "boundary enrichment" (Figure 3b) effectively enlarges the known territory for minority classes, making the resulting model more robust. Furthermore, the graph structure itself acts as a natural filter; by only allowing well-aligned synthetic samples to influence their neighbors, the model mitigates the risks associated with LLM hallucinations.
Experimental Results
SaVe-TAG was evaluated across six benchmark datasets, including citation networks (Cora, PubMed, Citeseer) and Amazon product networks. To simulate real-world conditions, long-tailed distributions were manually induced via downsampling.
- Superior Performance: SaVe-TAG consistently outperformed traditional numeric interpolation (SMOTE/Mixup) and state-of-the-art long-tail graph baselines like LTE4G and HierTail.
- Significant Gains: On the PubMed dataset, SaVe-TAG achieved a 10.3% increase in average accuracy compared to numeric interpolation methods.
- Balanced Learning: The framework significantly improved Macro-F1 scores, narrowing the performance gap between over-represented "head" classes and under-represented "tail" classes.
- Model Efficiency: Experiments demonstrated that even smaller, open-source models (like Llama 3.2-1B) provide excellent results, making the method computationally accessible.
Conclusion and Future Work
SaVe-TAG demonstrates that LLMs can serve as powerful engines for data augmentation in graph machine learning by operating in the space of human language rather than raw vectors. While LLM inference is more costly than simple arithmetic, the use of augmentation as a pre-processing step makes it a viable solution for improving GNN performance on imbalanced datasets. Future research may explore incorporating local graph topology directly into LLM prompts to further refine the synthesis process.
Summary updated