Semantic Graph Decomposition for Robust and Fair LLM Content Moderation
Abstract
As Large Language Models (LLMs) are integrated into critical software infrastructure, defending against jailbreak attacks has become a paramount security imperative. Current guardrails treat prompts as flat text strings, making them vulnerable to surface-level lexical mutations and causing severe overblocking on benign technical queries. We introduce a structural paradigm that models prompts as directed semantic graphs (G=(V,E)), where nodes represent functional attack vectors from a 12-category taxonomy and edges capture logical dependencies. Using our novel benchmark, GraphJailbreakBench (GJB), we demonstrate that instruction-tuned parsers reliably extract semantic structures (F1 = 82.8%). Furthermore, our proposed Graph-Text Hybrid model outperforms text-only baselines (F1: 0.85 --> 0.92), maintains robustness under obfuscation (F1 = 0.884), and reduces false-positive disparity across benign demographic/domain subgroups by 64.3%.