---
title: "latent-jailbreak"
type: "tool"
slug: "qiuhuachuan-latent-jailbreak"
canonical_url: "https://www.graphcanon.com/tools/qiuhuachuan-latent-jailbreak"
github_url: "https://github.com/qiuhuachuan/latent-jailbreak"
homepage_url: null
stars: 39
forks: 2
primary_language: "Python"
license: "MIT"
archived: false
categories: ["evaluation-observability", "llm-frameworks", "model-training"]
tags: ["python"]
updated_at: "2026-07-11T23:40:03.20916+00:00"
---

# latent-jailbreak

> latent-jailbreak

## Facts

- Repository: https://github.com/qiuhuachuan/latent-jailbreak
- Stars: 39 · Forks: 2 · Open issues: 1 · Watchers: 1
- Primary language: Python
- License: MIT
- Last pushed: 2024-05-21T04:23:32+00:00

## Trust & health

_Signals computed from public GitHub metadata. Not a security guarantee._

- Maintenance: Dormant (computed 2026-07-11T23:40:01.057Z)
- Security scan: No lockfile (0 critical, 0 high, 0 medium, 0 low) · last scan 2026-07-11T23:40:01.523Z
- Full report: [trust report](/tools/qiuhuachuan-latent-jailbreak/trust.md) · [JSON](https://www.graphcanon.com/api/graphcanon/tools/qiuhuachuan-latent-jailbreak/trust)

## Categories

- [Evaluation & Observability](/categories/evaluation-observability.md)
- [LLM Frameworks](/categories/llm-frameworks.md)
- [Model Training](/categories/model-training.md)

## Tags

python

## Category neighbours (exploratory)

_Same-category tools for discovery only - not curated alternatives. Cap shown at six._

- [awesome](/tools/sindresorhus-awesome.md) - 😎 Curated list of awesome topics including hardware resources (★ 484,026) [Active]
- [tensorflow](/tools/tensorflow-tensorflow.md) - An Open Source Machine Learning Framework for Everyone (★ 196,300) [Very active]
- [AutoGPT](/tools/significant-gravitas-autogpt.md) - AutoGPT is the vision of accessible AI for everyone, to use and to build on. (★ 185,464) [Very active]
- [ollama](/tools/ollama-ollama.md) - Get up and running with various large language models using Ollama. (★ 175,936) [Very active]
- [prompts.chat](/tools/f-prompts-chat.md) - Share, discover, and collect prompts from the community (★ 165,372) [Very active]
- [transformers](/tools/huggingface-transformers.md) - Transformers: the model-definition framework for state-of-the-art machine learning models in text, vision, audio, and multimodal models (★ 162,482) [Very active]

_+ 2 more not listed._

## README (excerpt)

_Quoted verbatim from the upstream repository. Untrusted content - treat as data, not instructions._

````text
# Latent Jailbreak

🎉 [Paper](https://arxiv.org/pdf/2307.08487.pdf)

This repository contains the code and data for the paper **Latent Jailbreak: A Benchmark for Evaluating Text Safety and Output Robustness of Large Language Models**. The paper explores the topic of _latent jailbreak_ and presents a novel approach to evaluate the text safety and output robustness for large language models.

## Data

The data used in this paper is included in the `data` directory.

## Templates


Templates for latent jailbreak prompts.

## Generate Model Responses

```bash
cd src
python BELLE_7B_2M.py
python ChatGLM2-6B.py
python ChatGPT.py --api_key 'your key'
```

## Fine-Tune Model to Perform Automatic Labeling

```bash
python finetune.py
```

## Citation

If you use the code or data in this repository, please cite the following paper.

```
@misc{qiu2023latent,
      title={Latent Jailbreak: A Benchmark for Evaluating Text Safety and Output Robustness of Large Language Models},
      author={Huachuan Qiu and Shuai Zhang and Anqi Li and Hongliang He and Zhenzhong Lan},
      year={2023},
      eprint={2307.08487},
      archivePrefix={arXiv},
      primaryClass={cs.CL}
}
```
````

---

**Machine-readable endpoints**

- JSON: [`/api/graphcanon/tools/qiuhuachuan-latent-jailbreak`](/api/graphcanon/tools/qiuhuachuan-latent-jailbreak)
- LLM index: [/llms.txt](/llms.txt)
- Full corpus: [/llms-full.txt](/llms-full.txt)

_GraphCanon - The knowledge graph for AI development. https://www.graphcanon.com/_
