A Causal Explainable Guardrails for Large Language Models

Zhixuan Chu, Yan Wang, Longfei Li, Zhibo Wang, Zhan Qin +1 more
5/7/2024
cs.CL

No confident code implementation found for this paper. 3 possible matches can be shown below.

Abstract

Large Language Models (LLMs) have shown impressive performance in natural language tasks, but their outputs can exhibit undesirable attributes or biases. Existing methods for steering LLMs toward desired attributes often assume unbiased representations and rely solely on steering prompts. However, the representations learned from pre-training can introduce semantic biases that influence the steering process, leading to suboptimal results. We propose LLMGuardrail, a novel framework that incorporates causal analysis and adversarial learning to obtain unbiased steering representations in LLMs. LLMGuardrail systematically identifies and blocks the confounding effects of biases, enabling the extraction of unbiased steering representations. Additionally, it includes an explainable component that provides insights into the alignment between the generated output and the desired direction. Experiments demonstrate LLMGuardrail's effectiveness in steering LLMs toward desired attributes while mitigating biases. Our work contributes to the development of safe and reliable LLMs that align with desired attributes.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. 3 weaker matches are hidden by default — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{chu2024causal,
  title  = {A Causal Explainable Guardrails for Large Language Models},
  author = {Zhixuan Chu and Yan Wang and Longfei Li and Zhibo Wang and Zhan Qin and Kui Ren},
  year   = {2024},
  eprint = {2405.04160},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2405.04160v2}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2405.04160.svg)](https://codeofpaper.com/paper/2405.04160)

Discussion