An open API service indexing awesome lists of open source software.

https://github.com/timlrx/igcg


https://github.com/timlrx/igcg

Last synced: 8 months ago
JSON representation

Awesome Lists containing this project

README

          

# I-GCG
The official repository for [Improved Techniques for Optimization-Based Jailbreaking on Large Language Models](https://arxiv.org/abs/2405.21018).

Please feel free to contact jiaxiaojunqaq@gmail.com if you have any question.

## Quick Start
### 1. Generate suffix initialization
```python
python attack_llm_core_best_update_our_target.py --behaviors_config=behaviors_ours_config.json
```

### 2. Generate new json with the initialization
```python
python generate_our_config.py
```

### 3. Conduct jailbreaking attack
```python
python run_multiple_attack_our_target.py --behaviors_config=behaviours_gcss_config_init_v2_continued.json --output_path=gcss --model_path="/home/LLM/Llama-2-7b-chat-hf"
```

## Experiments

### Comparison results with SOTA jailbreak methods



### Transferable performance of jailbreak suffix



## Citation

Kindly include a reference to this paper in your publications if it helps your research:
```
@article{jia2024improved,
title={Improved Techniques for Optimization-Based Jailbreaking on Large Language Models},
author={Xiaojun Jia and Tianyu Pang and Chao Du and Yihao Huang and Jindong Gu and Yang Liu and Xiaochun Cao and Min Lin},
year={2024},
eprint={2405.21018}
}
```