GraphAttack: Exploiting Representational Blindspots in LLM Safety Mechanisms DOI: XXXXXXX.XXXXXXX Conference: Make sure to enter the correct conference title from your rights confirmation email; June 03–05, 2018; Woodstock, NY ISBN: 978-1-4503-XXXX-X/2018/06 CCS: Do Not Use This Code Generate the Co

Sinan He, An Wang · 2025

Read GraphAttack: Exploiting Representational Blindspots in LLM Safety Mechanisms DOI: XXXXXXX.XXXXXXX Conference: Make sure to enter the correct conference title from your rights confirmation email; June 03–05, 2018; Woodstock, NY ISBN: 978-1-4503-XXXX-X/2018/06 CCS: Do Not Use This Code Generate the Co by Sinan He, An Wang (2025) in the Tower of Babel, a free online library of public-domain works preserved in clean, searchable text. No sign-up. The full text is served as a plain-text file at a predictable URL, where text is present: https://antarctic-labs.com/tower-of-babel/arxiv-2504-13052.txt.

Introduction

Sinan He and An Wang map a structured way in 2025 to slip past the safety guards of large language models. Their method turns a harmful goal into a meaning graph, then reshapes that graph through linked steps so filters that scan surface words miss it. One strong route asks the model to write code that carries out the graphed intent.

That route reached success rates up to eighty-seven percent against leading commercial models, they report. Framing and abstraction did most of the evading, which shows current guards lean on surface patterns. The authors frame the work as a stress test: a shared method for finding guard gaps so builders can close them. Defenders get a map of where semantic reshaping beats word lists.

Catalog record

CREATORSinan He, An Wang
YEAR2025
COLLECTIONPAPERS
FORMATTXT
FILE SIZE66 KB
VERSION1.0
LICENSEhttp://creativecommons.org/licenses/by/4.0/
RIGHTSCC BY
SOURCEarXiv

Source: https://arxiv.org/abs/2504-13052

Browse the full library · About the Tower of Babel

Full text

The opening of the work, from the library's hosted text:

GraphAttack: Exploiting Representational Blindspots in LLM Safety Mechanisms DOI: XXXXXXX.XXXXXXX Conference: Make sure to enter the correct conference title from your rights confirmation email; June 03–05, 2018; Woodstock, NY ISBN: 978-1-4503-XXXX-X/2018/06 CCS: Do Not Use This Code Generate the Correct Terms for Your Paper CCS: Do Not Use This Code Generate the Correct Terms for Your Paper CCS: Do Not Use This Code Generate the Correct Terms for Your Paper CCS: Do Not Use This Code Generate the Correct Terms for Your Paper Sinan He, An Wang Abstract . Large Language Models (LLMs) have been equipped with safety mechanisms to prevent harmful outputs, but these guardrails can often be bypassed through “jailbreak” prompts. This paper introduces a novel graph-based approach to systematically generate jailbreak prompts through semantic transformations. We represent malicious prompts as nodes in a graph structure with edges denoting different transformations, leveraging Abstract Meaning Representation (AMR) and Resource Description Framework (RDF) to parse user goals into semantic components that can be manipulated to evade safety filters. We demonstrate a particularly effective exploitation vector by instructing LLMs to generate code that realizes the intent described in these semantic graphs, achieving success rates of up to 87% against leading commercial LLMs. Our analysis reveals that contextual framing and abstraction are particularly effective at circumventing safety measures, highlighting critical gaps in current safety alignment techniques that focus primarily on surface-level patterns. These findings provide insights for developing more robust safeguards against structured semantic attacks. Our research contributes both a theoretical framework and practical methodology for systematically stress-testing LLM safety mechanisms. Disclaimer: This paper contains potentially disturbing and offensive content. 1. Introduction Large Language Models (LLMs) have demonstrated remarkable capabilities across a wide range of natural language tasks, from engaging in conversation to generating creative content and solving complex reasoning problems. The most popular models, such as GPT-4o ( OpenAI 2024 ) , Claude ( Anthropic 2025 ) , and Llama 3.3 ( Meta 2024 ) , can produce outputs that are increasingly difficult to distinguish from human-written text. However, this power comes with significant risks, as these models can potentially generate harmful, unethical, or dangerous content if prompted to do so. To mitigate these risks, developers of LLMs implement various safety mechanisms, including supervised fine-tuning with human feedback (SFT) ( Ouyang et al. 2022 ) , reinforcement learning from human feedback (RLHF) ( Christiano et al. 2017 ) , and constitutional AI approaches ( Bai et al. 2022a ) . These techniques aim to align models with human values and preferences, resulting in models that refuse to generate harmful content in response to malicious requests. However, these alignment mechanisms remain imperfect and vulnerable to carefully crafted “jailbreak” prompts that circumvent safety guardrails. Current jailbreaking methods typically rely on ad-hoc prompt engineering techniques, such as role-play scenarios ( Tang et al. 2025 ; Jin et al. 2023 ) , explicit instructions to ignore previous constraints ( Yu et al. 2024 ; Liu et al. [n. d.] ) , or encoded prompts that obfuscate malicious intent ( Huang et al. 2024 ; Zou et al. 2023 ) . While these approaches have shown varying degrees of success, they lack a systematic framework for exploring the potential attack space. This limitation makes it difficult to comprehensively evaluate model vulnerabilities or develop robust defenses against adversarial inputs. Recent automated approaches like PAIR ( Chao et al. 2023 ) and TAP ( Mehrotra et al. 2023 ) have improved jailbreaking efficiency, but still operate predominantly at the surface text level, missing deeper semantic vulnerabilities. In this paper, we introduce GraphAttack, a novel approach to jailbreaking LLMs through graph-based semantic representations. Our work is motivated by a compelling observation: safety alignment techniques appear to be more effective at identifying and filtering harmful content expressed in natural language than in formal semantic representations. This architectural vulnerability, combined with evidence from Geva et al. ( Geva et al. 2022 ) showing that transformer models process information hierarchically, creates an exploitable gap between surface-level pattern recognition and deeper semantic understanding. Unlike previous methods, GraphAttack operates at the semantic representation level, deconstructing harmful queries into their fundamental components and relationships. This approach enables us to identify and exploit invariant semantic structures that persist across transformations while evading detection by safety mechanisms focused on surface patterns. By formalizing jailbreaking as a graph traversal problem, we enable principled exploration of the semantic transformation space and provide deeper insights into LLM safety vulnerabilities. Our approach employs three complementary pathways to generate structured semantic representations: (1) Abstract Meaning Representation (AMR) parsing, which captures predicate-argument structures in a human-interpretable graph format; (2) Resource Description Framework (RDF) parsing, which represents semantic relationships as subject-predicate-object triples; and (3) template-based JSON knowledge graphs, which combine structural formalism with natural language flexibility. For the JSON pathway, we further apply systematic semantic transformations that modify the representation while preserving the underlying harmful intent. Building on these semantic representations, we demonstrate a particularly effective exploitation vector: instructing LLMs to generate code that realizes the intent described in the graph. This knowledge-to-code pathway leverages a fundamental vulnerability where models process semantic representations as technical challenges rather than recognizing their harmful implications, effectively bypassing intent-based safety filters. Our experimental results show that this approach achieves success rates of up to 84.62% against leading commercial LLMs — significantly outperforming state-of-the-art jailbreaking methods. The significance of our work extends beyond simply demonstrating new jailbreaking techniques. By formalizing the semantic transformation space, we provide a theoretical framework for understanding the fundamental limitations of current safety alignment approaches. Our findings reveal that contemporary safety mechanisms operate primarily as pattern recognition systems at the lexical and syntactic levels, with limited capability to evaluate semantic intent across different representational forms. This insight has profound implications for developing next-generation safety alignment techniques that must operate across the full depth of model processing hierarchies. Our key contributions in this work include: • A graph-based framework for systematically generating jailbreak prompts by representing malicious queries as semantic graphs where nodes represent concepts and edges represent transformations. • A methodology for leveraging AMR and RDF to parse malicious goals into semantic components that can be manipulated to evade detection. • A novel knowledge-to-code pathway that exploits the differential processing of semantic representations versus natural language inputs. • An empirical evaluation demonstrating that our approach achieves significantly higher attack success rates across multiple state-of-the-art LLMs compared to existing jailbreaking methods. • Analysis of which semantic transformations are most effective at bypassing safety mechanisms, providing insights for improving LLM safety. • A discussion of the implications for future safety alignment techniques and potential countermeasures against semantic transformation attacks. By formalizing jailbreaking as a graph-based semantic problem, our work advances beyond ad-hoc exploitation techniques toward a more systematic understanding of safety mechanism vulnerabilities. Moreover, our methodology provides a principled approach to red-teaming that enables comprehensive evaluation of model robustness across the semantic transformation space. This represents a significant advancement in adversarial testing methodologies for AI systems, moving from isolated examples toward structured exploration of the vulnerability landscape. 2. Related Work 2.1. Large Language Models and Safety Alignment Large Language Models (LLMs) like GPT-3.5, GPT-4, Claude, and the Llama series have demonstrated remarkable capabilities in conversation, text generation,

Read the complete text