Abstract
Knowledge Graph Embeddings (KGEs) are critical for tasks like link prediction but remain highly susceptible to adversarial data poisoning. Existing black-box attack methods often function as uninterpretable "oracles," providing no insight into why specific triples are targeted. This paper presents LLMAtKGE, a framework that utilizes Large Language Models (LLMs) to perform effective black-box attacks while generating human-readable explanations. By integrating structured prompting, multi-stage candidate filtering, and High-order Adjacency (HoA) tuning, LLMAtKGE achieves state-of-the-art performance and offers a transparent view into KGE vulnerabilities.
Introduction
Knowledge Graph Embeddings (KGEs) map entities and relations into low-dimensional vector spaces, facilitating downstream applications such as question answering and semantic search. Despite their utility, KGEs are vulnerable to data poisoning, where the addition or deletion of a single triple in the training set can significantly degrade a model's ability to predict target links. While white-box attacks require access to model gradients, black-box attacks rely on heuristics or language models to find vulnerabilities. However, current black-box methods act as uninterpretable oracles, making it difficult for researchers to understand and mitigate these vulnerabilities.
The Challenge of LLM-based Attacks
Directly applying LLMs to find attack targets in large Knowledge Graphs (KGs) presents significant hurdles. Large graphs often exceed the context window of standard LLMs, leading to "overflow." Furthermore, presenting an LLM with too many options can cause "hesitation," where the model fails to provide a clear, reasoned choice or diverges into irrelevant reasoning paths.
The LLMAtKGE Framework
To turn LLMs into explainable, highly effective attackers, the authors propose the LLMAtKGE framework, which relies on three main pillars:
- Structured Prompting: Formulating the attack as a multiple-choice question (MCQ) constrains the LLM's decision space. By providing a target triple, factual KG evidence, and a small list of candidate triples, the model is forced to choose one and explain its reasoning, preventing hallucinations.
- Candidate Filtering: The framework aggressively reduces the search space to prevent context overflow. For deletion attacks, it uses a semantics-based filter (cosine similarity of embeddings). For addition attacks, it employs centrality-based filters (PageRank, Betweenness, Closeness) on the target's local subgraph.
- High-order Adjacency (HoA) Tuning: This is the framework's primary innovation. Because LLMs natively struggle with multi-hop graph topology, the authors precompute HoA matrices to capture deep structural signals. They use a lightweight adapter and LoRA (Low-Rank Adaptation) to fine-tune the LLM on a triple classification task, efficiently injecting multi-hop graph structure directly into the LLM's semantic space.
Experimental Evaluation and Key Results
The framework was evaluated on two standard benchmarks: WN18RR (lexical relations) and FB15k-237 (open-domain facts). LLMAtKGE was tested against four classic KGE models: DistMult, ComplEx, ConvE, and TransE.
- State-of-the-Art Performance: LLMAtKGE consistently outperformed the strongest black-box baseline (PLM-Attack). For instance, on WN18RR against the ConvE model, it dropped the Mean Reciprocal Rank (MRR) to 0.14, compared to PLM-Attack's 0.20. In many scenarios, it even rivaled white-box attacks that have access to model gradients.
- Structural Insights: The framework proved that text semantics alone are insufficient for attacking KGs. Explicitly injecting multi-hop structural data via HoA tuning was critical for identifying "load-bearing" triples.
- Explainability: The model successfully generated logical explanations for its attacks. It frequently targeted bidirectional or inverse relations (e.g., removing "A is a hypernym of B" to break "B is a hyponym of A"), revealing that KGEs often rely on these symmetric structural crutches.
Conclusion
LLMAtKGE represents a significant step toward explainable AI in graph security. By combining the semantic power of LLMs with structural graph awareness, the framework not only identifies critical vulnerabilities but also explains the logic behind them. Future work may address the performance gap in addition attacks and improve generalization to denser, more complex graph structures like FB15k-237.
Summary updated