AI RESEARCH

A Lightweight Explainable Guardrail for Prompt Safety

arXiv CS.AI

ArXi:2602.15853v2 Announce Type: replace-cross We propose a lightweight explainable guardrail (LEG) method to detect unsafe prompts. LEG uses a multi-task learning architecture to jointly learn a prompt classifier and an explanation classifier, where the latter labels prompt words that explain the safe/unsafe overall decision. LEG is trained on synthetic explanation data, which is generated using a novel strategy that counteracts the confirmation biases of LLMs. Lastly, LEG's